vendor.js 901 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539454045414542454345444545454645474548454945504551455245534554455545564557455845594560456145624563456445654566456745684569457045714572457345744575457645774578457945804581458245834584458545864587458845894590459145924593459445954596459745984599460046014602460346044605460646074608460946104611461246134614461546164617461846194620462146224623462446254626462746284629463046314632463346344635463646374638463946404641464246434644464546464647464846494650465146524653465446554656465746584659466046614662466346644665466646674668466946704671467246734674467546764677467846794680468146824683468446854686468746884689469046914692469346944695469646974698469947004701470247034704470547064707470847094710471147124713471447154716471747184719472047214722472347244725472647274728472947304731473247334734473547364737473847394740474147424743474447454746474747484749475047514752475347544755475647574758475947604761476247634764476547664767476847694770477147724773477447754776477747784779478047814782478347844785478647874788478947904791479247934794479547964797479847994800480148024803480448054806480748084809481048114812481348144815481648174818481948204821482248234824482548264827482848294830483148324833483448354836483748384839484048414842484348444845484648474848484948504851485248534854485548564857485848594860486148624863486448654866486748684869487048714872487348744875487648774878487948804881488248834884488548864887488848894890489148924893489448954896489748984899490049014902490349044905490649074908490949104911491249134914491549164917491849194920492149224923492449254926492749284929493049314932493349344935493649374938493949404941494249434944494549464947494849494950495149524953495449554956495749584959496049614962496349644965496649674968496949704971497249734974497549764977497849794980498149824983498449854986498749884989499049914992499349944995499649974998499950005001500250035004500550065007500850095010501150125013501450155016501750185019502050215022502350245025502650275028502950305031503250335034503550365037503850395040504150425043504450455046504750485049505050515052505350545055505650575058505950605061506250635064506550665067506850695070507150725073507450755076507750785079508050815082508350845085508650875088508950905091509250935094509550965097509850995100510151025103510451055106510751085109511051115112511351145115511651175118511951205121512251235124512551265127512851295130513151325133513451355136513751385139514051415142514351445145514651475148514951505151515251535154515551565157515851595160516151625163516451655166516751685169517051715172517351745175517651775178517951805181518251835184518551865187518851895190519151925193519451955196519751985199520052015202520352045205520652075208520952105211521252135214521552165217521852195220522152225223522452255226522752285229523052315232523352345235523652375238523952405241524252435244524552465247524852495250525152525253525452555256525752585259526052615262526352645265526652675268526952705271527252735274527552765277527852795280528152825283528452855286528752885289529052915292529352945295529652975298529953005301530253035304530553065307530853095310531153125313531453155316531753185319532053215322532353245325532653275328532953305331533253335334533553365337533853395340534153425343534453455346534753485349535053515352535353545355535653575358535953605361536253635364536553665367536853695370537153725373537453755376537753785379538053815382538353845385538653875388538953905391539253935394539553965397539853995400540154025403540454055406540754085409541054115412541354145415541654175418541954205421542254235424542554265427542854295430543154325433543454355436543754385439544054415442544354445445544654475448544954505451545254535454545554565457545854595460546154625463546454655466546754685469547054715472547354745475547654775478547954805481548254835484548554865487548854895490549154925493549454955496549754985499550055015502550355045505550655075508550955105511551255135514551555165517551855195520552155225523552455255526552755285529553055315532553355345535553655375538553955405541554255435544554555465547554855495550555155525553555455555556555755585559556055615562556355645565556655675568556955705571557255735574557555765577557855795580558155825583558455855586558755885589559055915592559355945595559655975598559956005601560256035604560556065607560856095610561156125613561456155616561756185619562056215622562356245625562656275628562956305631563256335634563556365637563856395640564156425643564456455646564756485649565056515652565356545655565656575658565956605661566256635664566556665667566856695670567156725673567456755676567756785679568056815682568356845685568656875688568956905691569256935694569556965697569856995700570157025703570457055706570757085709571057115712571357145715571657175718571957205721572257235724572557265727572857295730573157325733573457355736573757385739574057415742574357445745574657475748574957505751575257535754575557565757575857595760576157625763576457655766576757685769577057715772577357745775577657775778577957805781578257835784578557865787578857895790579157925793579457955796579757985799580058015802580358045805580658075808580958105811581258135814581558165817581858195820582158225823582458255826582758285829583058315832583358345835583658375838583958405841584258435844584558465847584858495850585158525853585458555856585758585859586058615862586358645865586658675868586958705871587258735874587558765877587858795880588158825883588458855886588758885889589058915892589358945895589658975898589959005901590259035904590559065907590859095910591159125913591459155916591759185919592059215922592359245925592659275928592959305931593259335934593559365937593859395940594159425943594459455946594759485949595059515952595359545955595659575958595959605961596259635964596559665967596859695970597159725973597459755976597759785979598059815982598359845985598659875988598959905991599259935994599559965997599859996000600160026003600460056006600760086009601060116012601360146015601660176018601960206021602260236024602560266027602860296030603160326033603460356036603760386039604060416042604360446045604660476048604960506051605260536054605560566057605860596060606160626063606460656066606760686069607060716072607360746075607660776078607960806081608260836084608560866087608860896090609160926093609460956096609760986099610061016102610361046105610661076108610961106111611261136114611561166117611861196120612161226123612461256126612761286129613061316132613361346135613661376138613961406141614261436144614561466147614861496150615161526153615461556156615761586159616061616162616361646165616661676168616961706171617261736174617561766177617861796180618161826183618461856186618761886189619061916192619361946195619661976198619962006201620262036204620562066207620862096210621162126213621462156216621762186219622062216222622362246225622662276228622962306231623262336234623562366237623862396240624162426243624462456246624762486249625062516252625362546255625662576258625962606261626262636264626562666267626862696270627162726273627462756276627762786279628062816282628362846285628662876288628962906291629262936294629562966297629862996300630163026303630463056306630763086309631063116312631363146315631663176318631963206321632263236324632563266327632863296330633163326333633463356336633763386339634063416342634363446345634663476348634963506351635263536354635563566357635863596360636163626363636463656366636763686369637063716372637363746375637663776378637963806381638263836384638563866387638863896390639163926393639463956396639763986399640064016402640364046405640664076408640964106411641264136414641564166417641864196420642164226423642464256426642764286429643064316432643364346435643664376438643964406441644264436444644564466447644864496450645164526453645464556456645764586459646064616462646364646465646664676468646964706471647264736474647564766477647864796480648164826483648464856486648764886489649064916492649364946495649664976498649965006501650265036504650565066507650865096510651165126513651465156516651765186519652065216522652365246525652665276528652965306531653265336534653565366537653865396540654165426543654465456546654765486549655065516552655365546555655665576558655965606561656265636564656565666567656865696570657165726573657465756576657765786579658065816582658365846585658665876588658965906591659265936594659565966597659865996600660166026603660466056606660766086609661066116612661366146615661666176618661966206621662266236624662566266627662866296630663166326633663466356636663766386639664066416642664366446645664666476648664966506651665266536654665566566657665866596660666166626663666466656666666766686669667066716672667366746675667666776678667966806681668266836684668566866687668866896690669166926693669466956696669766986699670067016702670367046705670667076708670967106711671267136714671567166717671867196720672167226723672467256726672767286729673067316732673367346735673667376738673967406741674267436744674567466747674867496750675167526753675467556756675767586759676067616762676367646765676667676768676967706771677267736774677567766777677867796780678167826783678467856786678767886789679067916792679367946795679667976798679968006801680268036804680568066807680868096810681168126813681468156816681768186819682068216822682368246825682668276828682968306831683268336834683568366837683868396840684168426843684468456846684768486849685068516852685368546855685668576858685968606861686268636864686568666867686868696870687168726873687468756876687768786879688068816882688368846885688668876888688968906891689268936894689568966897689868996900690169026903690469056906690769086909691069116912691369146915691669176918691969206921692269236924692569266927692869296930693169326933693469356936693769386939694069416942694369446945694669476948694969506951695269536954695569566957695869596960696169626963696469656966696769686969697069716972697369746975697669776978697969806981698269836984698569866987698869896990699169926993699469956996699769986999700070017002700370047005700670077008700970107011701270137014701570167017701870197020702170227023702470257026702770287029703070317032703370347035703670377038703970407041704270437044704570467047704870497050705170527053705470557056705770587059706070617062706370647065706670677068706970707071707270737074707570767077707870797080708170827083708470857086708770887089709070917092709370947095709670977098709971007101710271037104710571067107710871097110711171127113711471157116711771187119712071217122712371247125712671277128712971307131713271337134713571367137713871397140714171427143714471457146714771487149715071517152715371547155715671577158715971607161716271637164716571667167716871697170717171727173717471757176717771787179718071817182718371847185718671877188718971907191719271937194719571967197719871997200720172027203720472057206720772087209721072117212721372147215721672177218721972207221722272237224722572267227722872297230723172327233723472357236723772387239724072417242724372447245724672477248724972507251725272537254725572567257725872597260726172627263726472657266726772687269727072717272727372747275727672777278727972807281728272837284728572867287728872897290729172927293729472957296729772987299730073017302730373047305730673077308730973107311731273137314731573167317731873197320732173227323732473257326732773287329733073317332733373347335733673377338733973407341734273437344734573467347734873497350735173527353735473557356735773587359736073617362736373647365736673677368736973707371737273737374737573767377737873797380738173827383738473857386738773887389739073917392739373947395739673977398739974007401740274037404740574067407740874097410741174127413741474157416741774187419742074217422742374247425742674277428742974307431743274337434743574367437743874397440744174427443744474457446744774487449745074517452745374547455745674577458745974607461746274637464746574667467746874697470747174727473747474757476747774787479748074817482748374847485748674877488748974907491749274937494749574967497749874997500750175027503750475057506750775087509751075117512751375147515751675177518751975207521752275237524752575267527752875297530753175327533753475357536753775387539754075417542754375447545754675477548754975507551755275537554755575567557755875597560756175627563756475657566756775687569757075717572757375747575757675777578757975807581758275837584758575867587758875897590759175927593759475957596759775987599760076017602760376047605760676077608760976107611761276137614761576167617761876197620762176227623762476257626762776287629763076317632763376347635763676377638763976407641764276437644764576467647764876497650765176527653765476557656765776587659766076617662766376647665766676677668766976707671767276737674767576767677767876797680768176827683768476857686768776887689769076917692769376947695769676977698769977007701770277037704770577067707770877097710771177127713771477157716771777187719772077217722772377247725772677277728772977307731773277337734773577367737773877397740774177427743774477457746774777487749775077517752775377547755775677577758775977607761776277637764776577667767776877697770777177727773777477757776777777787779778077817782778377847785778677877788778977907791779277937794779577967797779877997800780178027803780478057806780778087809781078117812781378147815781678177818781978207821782278237824782578267827782878297830783178327833783478357836783778387839784078417842784378447845784678477848784978507851785278537854785578567857785878597860786178627863786478657866786778687869787078717872787378747875787678777878787978807881788278837884788578867887788878897890789178927893789478957896789778987899790079017902790379047905790679077908790979107911791279137914791579167917791879197920792179227923792479257926792779287929793079317932793379347935793679377938793979407941794279437944794579467947794879497950795179527953795479557956795779587959796079617962796379647965796679677968796979707971797279737974797579767977797879797980798179827983798479857986798779887989799079917992799379947995799679977998799980008001800280038004800580068007800880098010801180128013801480158016801780188019802080218022802380248025802680278028802980308031803280338034803580368037803880398040804180428043804480458046804780488049805080518052805380548055805680578058805980608061806280638064806580668067806880698070807180728073807480758076807780788079808080818082808380848085808680878088808980908091809280938094809580968097809880998100810181028103810481058106810781088109811081118112811381148115811681178118811981208121812281238124812581268127812881298130813181328133813481358136813781388139814081418142814381448145814681478148814981508151815281538154815581568157815881598160816181628163816481658166816781688169817081718172817381748175817681778178817981808181818281838184818581868187818881898190819181928193819481958196819781988199820082018202820382048205820682078208820982108211821282138214821582168217821882198220822182228223822482258226822782288229823082318232823382348235823682378238823982408241824282438244824582468247824882498250825182528253825482558256825782588259826082618262826382648265826682678268826982708271827282738274827582768277827882798280828182828283828482858286828782888289829082918292829382948295829682978298829983008301830283038304830583068307830883098310831183128313831483158316831783188319832083218322832383248325832683278328832983308331833283338334833583368337833883398340834183428343834483458346834783488349835083518352835383548355835683578358835983608361836283638364836583668367836883698370837183728373837483758376837783788379838083818382838383848385838683878388838983908391839283938394839583968397839883998400840184028403840484058406840784088409841084118412841384148415841684178418841984208421842284238424842584268427842884298430843184328433843484358436843784388439844084418442844384448445844684478448844984508451845284538454845584568457845884598460846184628463846484658466846784688469847084718472847384748475847684778478847984808481848284838484848584868487848884898490849184928493849484958496849784988499850085018502850385048505850685078508850985108511851285138514851585168517851885198520852185228523852485258526852785288529853085318532853385348535853685378538853985408541854285438544854585468547854885498550855185528553855485558556855785588559856085618562856385648565856685678568856985708571857285738574857585768577857885798580858185828583858485858586858785888589859085918592859385948595859685978598859986008601860286038604860586068607860886098610861186128613861486158616861786188619862086218622862386248625862686278628862986308631863286338634863586368637863886398640864186428643864486458646864786488649865086518652865386548655865686578658865986608661866286638664866586668667866886698670867186728673867486758676867786788679868086818682868386848685868686878688868986908691869286938694869586968697869886998700870187028703870487058706870787088709871087118712871387148715871687178718871987208721872287238724872587268727872887298730873187328733873487358736873787388739874087418742874387448745874687478748874987508751875287538754875587568757875887598760876187628763876487658766876787688769877087718772877387748775877687778778877987808781878287838784878587868787878887898790879187928793879487958796879787988799880088018802880388048805880688078808880988108811881288138814881588168817881888198820882188228823882488258826882788288829883088318832883388348835883688378838883988408841884288438844884588468847884888498850885188528853885488558856885788588859886088618862886388648865886688678868886988708871887288738874887588768877887888798880888188828883888488858886888788888889889088918892889388948895889688978898889989008901890289038904890589068907890889098910891189128913891489158916891789188919892089218922892389248925892689278928892989308931893289338934893589368937893889398940894189428943894489458946894789488949895089518952895389548955895689578958895989608961896289638964896589668967896889698970897189728973897489758976897789788979898089818982898389848985898689878988898989908991899289938994899589968997899889999000900190029003900490059006900790089009901090119012901390149015901690179018901990209021902290239024902590269027902890299030903190329033903490359036903790389039904090419042904390449045904690479048904990509051905290539054905590569057905890599060906190629063906490659066906790689069907090719072907390749075907690779078907990809081908290839084908590869087908890899090909190929093909490959096909790989099910091019102910391049105910691079108910991109111911291139114911591169117911891199120912191229123912491259126912791289129913091319132913391349135913691379138913991409141914291439144914591469147914891499150915191529153915491559156915791589159916091619162916391649165916691679168916991709171917291739174917591769177917891799180918191829183918491859186918791889189919091919192919391949195919691979198919992009201920292039204920592069207920892099210921192129213921492159216921792189219922092219222922392249225922692279228922992309231923292339234923592369237923892399240924192429243924492459246924792489249925092519252925392549255925692579258925992609261926292639264926592669267926892699270927192729273927492759276927792789279928092819282928392849285928692879288928992909291929292939294929592969297929892999300930193029303930493059306930793089309931093119312931393149315931693179318931993209321932293239324932593269327932893299330933193329333933493359336933793389339934093419342934393449345934693479348934993509351935293539354935593569357935893599360936193629363936493659366936793689369937093719372937393749375937693779378937993809381938293839384938593869387938893899390939193929393939493959396939793989399940094019402940394049405940694079408940994109411941294139414941594169417941894199420942194229423942494259426942794289429943094319432943394349435943694379438943994409441944294439444944594469447944894499450945194529453945494559456945794589459946094619462946394649465946694679468946994709471947294739474947594769477947894799480948194829483948494859486948794889489949094919492949394949495949694979498949995009501950295039504950595069507950895099510951195129513951495159516951795189519952095219522952395249525952695279528952995309531953295339534953595369537953895399540954195429543954495459546954795489549955095519552955395549555955695579558955995609561956295639564956595669567956895699570957195729573957495759576957795789579958095819582958395849585958695879588958995909591959295939594959595969597959895999600960196029603960496059606960796089609961096119612961396149615961696179618961996209621962296239624962596269627962896299630963196329633963496359636963796389639964096419642964396449645964696479648964996509651965296539654965596569657965896599660966196629663966496659666966796689669967096719672967396749675967696779678967996809681968296839684968596869687968896899690969196929693969496959696969796989699970097019702970397049705970697079708970997109711971297139714971597169717971897199720972197229723972497259726972797289729973097319732973397349735973697379738973997409741974297439744974597469747974897499750975197529753975497559756975797589759976097619762976397649765976697679768976997709771977297739774977597769777977897799780978197829783978497859786978797889789979097919792979397949795979697979798979998009801980298039804980598069807980898099810981198129813981498159816981798189819982098219822982398249825982698279828982998309831983298339834983598369837983898399840984198429843984498459846984798489849985098519852985398549855985698579858985998609861986298639864986598669867986898699870987198729873987498759876987798789879988098819882988398849885988698879888988998909891989298939894989598969897989898999900990199029903990499059906990799089909991099119912991399149915991699179918991999209921992299239924992599269927992899299930993199329933993499359936993799389939994099419942994399449945994699479948994999509951995299539954995599569957995899599960996199629963996499659966996799689969997099719972997399749975997699779978997999809981998299839984998599869987998899899990999199929993999499959996999799989999100001000110002100031000410005100061000710008100091001010011100121001310014100151001610017100181001910020100211002210023100241002510026100271002810029100301003110032100331003410035100361003710038100391004010041100421004310044100451004610047100481004910050100511005210053100541005510056100571005810059100601006110062100631006410065100661006710068100691007010071100721007310074100751007610077100781007910080100811008210083100841008510086100871008810089100901009110092100931009410095100961009710098100991010010101101021010310104101051010610107101081010910110101111011210113101141011510116101171011810119101201012110122101231012410125101261012710128101291013010131101321013310134101351013610137101381013910140101411014210143101441014510146101471014810149101501015110152101531015410155101561015710158101591016010161101621016310164101651016610167101681016910170101711017210173101741017510176101771017810179101801018110182101831018410185101861018710188101891019010191101921019310194101951019610197101981019910200102011020210203102041020510206102071020810209102101021110212102131021410215102161021710218102191022010221102221022310224102251022610227102281022910230102311023210233102341023510236102371023810239102401024110242102431024410245102461024710248102491025010251102521025310254102551025610257102581025910260102611026210263102641026510266102671026810269102701027110272102731027410275102761027710278102791028010281102821028310284102851028610287102881028910290102911029210293102941029510296102971029810299103001030110302103031030410305103061030710308103091031010311103121031310314103151031610317103181031910320103211032210323103241032510326103271032810329103301033110332103331033410335103361033710338103391034010341103421034310344103451034610347103481034910350103511035210353103541035510356103571035810359103601036110362103631036410365103661036710368103691037010371103721037310374103751037610377103781037910380103811038210383103841038510386103871038810389103901039110392103931039410395103961039710398103991040010401104021040310404104051040610407104081040910410104111041210413104141041510416104171041810419104201042110422104231042410425104261042710428104291043010431104321043310434104351043610437104381043910440104411044210443104441044510446104471044810449104501045110452104531045410455104561045710458104591046010461104621046310464104651046610467104681046910470104711047210473104741047510476104771047810479104801048110482104831048410485104861048710488104891049010491104921049310494104951049610497104981049910500105011050210503105041050510506105071050810509105101051110512105131051410515105161051710518105191052010521105221052310524105251052610527105281052910530105311053210533105341053510536105371053810539105401054110542105431054410545105461054710548105491055010551105521055310554105551055610557105581055910560105611056210563105641056510566105671056810569105701057110572105731057410575105761057710578105791058010581105821058310584105851058610587105881058910590105911059210593105941059510596105971059810599106001060110602106031060410605106061060710608106091061010611106121061310614106151061610617106181061910620106211062210623106241062510626106271062810629106301063110632106331063410635106361063710638106391064010641106421064310644106451064610647106481064910650106511065210653106541065510656106571065810659106601066110662106631066410665106661066710668106691067010671106721067310674106751067610677106781067910680106811068210683106841068510686106871068810689106901069110692106931069410695106961069710698106991070010701107021070310704107051070610707107081070910710107111071210713107141071510716107171071810719107201072110722107231072410725107261072710728107291073010731107321073310734107351073610737107381073910740107411074210743107441074510746107471074810749107501075110752107531075410755107561075710758107591076010761107621076310764107651076610767107681076910770107711077210773107741077510776107771077810779107801078110782107831078410785107861078710788107891079010791107921079310794107951079610797107981079910800108011080210803108041080510806108071080810809108101081110812108131081410815108161081710818108191082010821108221082310824108251082610827108281082910830108311083210833108341083510836108371083810839108401084110842108431084410845108461084710848108491085010851108521085310854108551085610857108581085910860108611086210863108641086510866108671086810869108701087110872108731087410875108761087710878108791088010881108821088310884108851088610887108881088910890108911089210893108941089510896108971089810899109001090110902109031090410905109061090710908109091091010911109121091310914109151091610917109181091910920109211092210923109241092510926109271092810929109301093110932109331093410935109361093710938109391094010941109421094310944109451094610947109481094910950109511095210953109541095510956109571095810959109601096110962109631096410965109661096710968109691097010971109721097310974109751097610977109781097910980109811098210983109841098510986109871098810989109901099110992109931099410995109961099710998109991100011001110021100311004110051100611007110081100911010110111101211013110141101511016110171101811019110201102111022110231102411025110261102711028110291103011031110321103311034110351103611037110381103911040110411104211043110441104511046110471104811049110501105111052110531105411055110561105711058110591106011061110621106311064110651106611067110681106911070110711107211073110741107511076110771107811079110801108111082110831108411085110861108711088110891109011091110921109311094110951109611097110981109911100111011110211103111041110511106111071110811109111101111111112111131111411115111161111711118111191112011121111221112311124111251112611127111281112911130111311113211133111341113511136111371113811139111401114111142111431114411145111461114711148111491115011151111521115311154111551115611157111581115911160111611116211163111641116511166111671116811169111701117111172111731117411175111761117711178111791118011181111821118311184111851118611187111881118911190111911119211193111941119511196111971119811199112001120111202112031120411205112061120711208112091121011211112121121311214112151121611217112181121911220112211122211223112241122511226112271122811229112301123111232112331123411235112361123711238112391124011241112421124311244112451124611247112481124911250112511125211253112541125511256112571125811259112601126111262112631126411265112661126711268112691127011271112721127311274112751127611277112781127911280112811128211283112841128511286112871128811289112901129111292112931129411295112961129711298112991130011301113021130311304113051130611307113081130911310113111131211313113141131511316113171131811319113201132111322113231132411325113261132711328113291133011331113321133311334113351133611337113381133911340113411134211343113441134511346113471134811349113501135111352113531135411355113561135711358113591136011361113621136311364113651136611367113681136911370113711137211373113741137511376113771137811379113801138111382113831138411385113861138711388113891139011391113921139311394113951139611397113981139911400114011140211403114041140511406114071140811409114101141111412114131141411415114161141711418114191142011421114221142311424114251142611427114281142911430114311143211433114341143511436114371143811439114401144111442114431144411445114461144711448114491145011451114521145311454114551145611457114581145911460114611146211463114641146511466114671146811469114701147111472114731147411475114761147711478114791148011481114821148311484114851148611487114881148911490114911149211493114941149511496114971149811499115001150111502115031150411505115061150711508115091151011511115121151311514115151151611517115181151911520115211152211523115241152511526115271152811529115301153111532115331153411535115361153711538115391154011541115421154311544115451154611547115481154911550115511155211553115541155511556115571155811559115601156111562115631156411565115661156711568115691157011571115721157311574115751157611577115781157911580115811158211583115841158511586115871158811589115901159111592115931159411595115961159711598115991160011601116021160311604116051160611607116081160911610116111161211613116141161511616116171161811619116201162111622116231162411625116261162711628116291163011631116321163311634116351163611637116381163911640116411164211643116441164511646116471164811649116501165111652116531165411655116561165711658116591166011661116621166311664116651166611667116681166911670116711167211673116741167511676116771167811679116801168111682116831168411685116861168711688116891169011691116921169311694116951169611697116981169911700117011170211703117041170511706117071170811709117101171111712117131171411715117161171711718117191172011721117221172311724117251172611727117281172911730117311173211733117341173511736117371173811739117401174111742117431174411745117461174711748117491175011751117521175311754117551175611757117581175911760117611176211763117641176511766117671176811769117701177111772117731177411775117761177711778117791178011781117821178311784117851178611787117881178911790117911179211793117941179511796117971179811799118001180111802118031180411805118061180711808118091181011811118121181311814118151181611817118181181911820118211182211823118241182511826118271182811829118301183111832118331183411835118361183711838118391184011841118421184311844118451184611847118481184911850118511185211853118541185511856118571185811859118601186111862118631186411865118661186711868118691187011871118721187311874118751187611877118781187911880118811188211883118841188511886118871188811889118901189111892118931189411895118961189711898118991190011901119021190311904119051190611907119081190911910119111191211913119141191511916119171191811919119201192111922119231192411925119261192711928119291193011931119321193311934119351193611937119381193911940119411194211943119441194511946119471194811949119501195111952119531195411955119561195711958119591196011961119621196311964119651196611967119681196911970119711197211973119741197511976119771197811979119801198111982119831198411985119861198711988119891199011991119921199311994119951199611997119981199912000120011200212003120041200512006120071200812009120101201112012120131201412015120161201712018120191202012021120221202312024120251202612027120281202912030120311203212033120341203512036120371203812039120401204112042120431204412045120461204712048120491205012051120521205312054120551205612057120581205912060120611206212063120641206512066120671206812069120701207112072120731207412075120761207712078120791208012081120821208312084120851208612087120881208912090120911209212093120941209512096120971209812099121001210112102121031210412105121061210712108121091211012111121121211312114121151211612117121181211912120121211212212123121241212512126121271212812129121301213112132121331213412135121361213712138121391214012141121421214312144121451214612147121481214912150121511215212153121541215512156121571215812159121601216112162121631216412165121661216712168121691217012171121721217312174121751217612177121781217912180121811218212183121841218512186121871218812189121901219112192121931219412195121961219712198121991220012201122021220312204122051220612207122081220912210122111221212213122141221512216122171221812219122201222112222122231222412225122261222712228122291223012231122321223312234122351223612237122381223912240122411224212243122441224512246122471224812249122501225112252122531225412255122561225712258122591226012261122621226312264122651226612267122681226912270122711227212273122741227512276122771227812279122801228112282122831228412285122861228712288122891229012291122921229312294122951229612297122981229912300123011230212303123041230512306123071230812309123101231112312123131231412315123161231712318123191232012321123221232312324123251232612327123281232912330123311233212333123341233512336123371233812339123401234112342123431234412345123461234712348123491235012351123521235312354123551235612357123581235912360123611236212363123641236512366123671236812369123701237112372123731237412375123761237712378123791238012381123821238312384123851238612387123881238912390123911239212393123941239512396123971239812399124001240112402124031240412405124061240712408124091241012411124121241312414124151241612417124181241912420124211242212423124241242512426124271242812429124301243112432124331243412435124361243712438124391244012441124421244312444124451244612447124481244912450124511245212453124541245512456124571245812459124601246112462124631246412465124661246712468124691247012471124721247312474124751247612477124781247912480124811248212483124841248512486124871248812489124901249112492124931249412495124961249712498124991250012501125021250312504125051250612507125081250912510125111251212513125141251512516125171251812519125201252112522125231252412525125261252712528125291253012531125321253312534125351253612537125381253912540125411254212543125441254512546125471254812549125501255112552125531255412555125561255712558125591256012561125621256312564125651256612567125681256912570125711257212573125741257512576125771257812579125801258112582125831258412585125861258712588125891259012591125921259312594125951259612597125981259912600126011260212603126041260512606126071260812609126101261112612126131261412615126161261712618126191262012621126221262312624126251262612627126281262912630126311263212633126341263512636126371263812639126401264112642126431264412645126461264712648126491265012651126521265312654126551265612657126581265912660126611266212663126641266512666126671266812669126701267112672126731267412675126761267712678126791268012681126821268312684126851268612687126881268912690126911269212693126941269512696126971269812699127001270112702127031270412705127061270712708127091271012711127121271312714127151271612717127181271912720127211272212723127241272512726127271272812729127301273112732127331273412735127361273712738127391274012741127421274312744127451274612747127481274912750127511275212753127541275512756127571275812759127601276112762127631276412765127661276712768127691277012771127721277312774127751277612777127781277912780127811278212783127841278512786127871278812789127901279112792127931279412795127961279712798127991280012801128021280312804128051280612807128081280912810128111281212813128141281512816128171281812819128201282112822128231282412825128261282712828128291283012831128321283312834128351283612837128381283912840128411284212843128441284512846128471284812849128501285112852128531285412855128561285712858128591286012861128621286312864128651286612867128681286912870128711287212873128741287512876128771287812879128801288112882128831288412885128861288712888128891289012891128921289312894128951289612897128981289912900129011290212903129041290512906129071290812909129101291112912129131291412915129161291712918129191292012921129221292312924129251292612927129281292912930129311293212933129341293512936129371293812939129401294112942129431294412945129461294712948129491295012951129521295312954129551295612957129581295912960129611296212963129641296512966129671296812969129701297112972129731297412975129761297712978129791298012981129821298312984129851298612987129881298912990129911299212993129941299512996129971299812999130001300113002130031300413005130061300713008130091301013011130121301313014130151301613017130181301913020130211302213023130241302513026130271302813029130301303113032130331303413035130361303713038130391304013041130421304313044130451304613047130481304913050130511305213053130541305513056130571305813059130601306113062130631306413065130661306713068130691307013071130721307313074130751307613077130781307913080130811308213083130841308513086130871308813089130901309113092130931309413095130961309713098130991310013101131021310313104131051310613107131081310913110131111311213113131141311513116131171311813119131201312113122131231312413125131261312713128131291313013131131321313313134131351313613137131381313913140131411314213143131441314513146131471314813149131501315113152131531315413155131561315713158131591316013161131621316313164131651316613167131681316913170131711317213173131741317513176131771317813179131801318113182131831318413185131861318713188131891319013191131921319313194131951319613197131981319913200132011320213203132041320513206132071320813209132101321113212132131321413215132161321713218132191322013221132221322313224132251322613227132281322913230132311323213233132341323513236132371323813239132401324113242132431324413245132461324713248132491325013251132521325313254132551325613257132581325913260132611326213263132641326513266132671326813269132701327113272132731327413275132761327713278132791328013281132821328313284132851328613287132881328913290132911329213293132941329513296132971329813299133001330113302133031330413305133061330713308133091331013311133121331313314133151331613317133181331913320133211332213323133241332513326133271332813329133301333113332133331333413335133361333713338133391334013341133421334313344133451334613347133481334913350133511335213353133541335513356133571335813359133601336113362133631336413365133661336713368133691337013371133721337313374133751337613377133781337913380133811338213383133841338513386133871338813389133901339113392133931339413395133961339713398133991340013401134021340313404134051340613407134081340913410134111341213413134141341513416134171341813419134201342113422134231342413425134261342713428134291343013431134321343313434134351343613437134381343913440134411344213443134441344513446134471344813449134501345113452134531345413455134561345713458134591346013461134621346313464134651346613467134681346913470134711347213473134741347513476134771347813479134801348113482134831348413485134861348713488134891349013491134921349313494134951349613497134981349913500135011350213503135041350513506135071350813509135101351113512135131351413515135161351713518135191352013521135221352313524135251352613527135281352913530135311353213533135341353513536135371353813539135401354113542135431354413545135461354713548135491355013551135521355313554135551355613557135581355913560135611356213563135641356513566135671356813569135701357113572135731357413575135761357713578135791358013581135821358313584135851358613587135881358913590135911359213593135941359513596135971359813599136001360113602136031360413605136061360713608136091361013611136121361313614136151361613617136181361913620136211362213623136241362513626136271362813629136301363113632136331363413635136361363713638136391364013641136421364313644136451364613647136481364913650136511365213653136541365513656136571365813659136601366113662136631366413665136661366713668136691367013671136721367313674136751367613677136781367913680136811368213683136841368513686136871368813689136901369113692136931369413695136961369713698136991370013701137021370313704137051370613707137081370913710137111371213713137141371513716137171371813719137201372113722137231372413725137261372713728137291373013731137321373313734137351373613737137381373913740137411374213743137441374513746137471374813749137501375113752137531375413755137561375713758137591376013761137621376313764137651376613767137681376913770137711377213773137741377513776137771377813779137801378113782137831378413785137861378713788137891379013791137921379313794137951379613797137981379913800138011380213803138041380513806138071380813809138101381113812138131381413815138161381713818138191382013821138221382313824138251382613827138281382913830138311383213833138341383513836138371383813839138401384113842138431384413845138461384713848138491385013851138521385313854138551385613857138581385913860138611386213863138641386513866138671386813869138701387113872138731387413875138761387713878138791388013881138821388313884138851388613887138881388913890138911389213893138941389513896138971389813899139001390113902139031390413905139061390713908139091391013911139121391313914139151391613917139181391913920139211392213923139241392513926139271392813929139301393113932139331393413935139361393713938139391394013941139421394313944139451394613947139481394913950139511395213953139541395513956139571395813959139601396113962139631396413965139661396713968139691397013971139721397313974139751397613977139781397913980139811398213983139841398513986139871398813989139901399113992139931399413995139961399713998139991400014001140021400314004140051400614007140081400914010140111401214013140141401514016140171401814019140201402114022140231402414025140261402714028140291403014031140321403314034140351403614037140381403914040140411404214043140441404514046140471404814049140501405114052140531405414055140561405714058140591406014061140621406314064140651406614067140681406914070140711407214073140741407514076140771407814079140801408114082140831408414085140861408714088140891409014091140921409314094140951409614097140981409914100141011410214103141041410514106141071410814109141101411114112141131411414115141161411714118141191412014121141221412314124141251412614127141281412914130141311413214133141341413514136141371413814139141401414114142141431414414145141461414714148141491415014151141521415314154141551415614157141581415914160141611416214163141641416514166141671416814169141701417114172141731417414175141761417714178141791418014181141821418314184141851418614187141881418914190141911419214193141941419514196141971419814199142001420114202142031420414205142061420714208142091421014211142121421314214142151421614217142181421914220142211422214223142241422514226142271422814229142301423114232142331423414235142361423714238142391424014241142421424314244142451424614247142481424914250142511425214253142541425514256142571425814259142601426114262142631426414265142661426714268142691427014271142721427314274142751427614277142781427914280142811428214283142841428514286142871428814289142901429114292142931429414295142961429714298142991430014301143021430314304143051430614307143081430914310143111431214313143141431514316143171431814319143201432114322143231432414325143261432714328143291433014331143321433314334143351433614337143381433914340143411434214343143441434514346143471434814349143501435114352143531435414355143561435714358143591436014361143621436314364143651436614367143681436914370143711437214373143741437514376143771437814379143801438114382143831438414385143861438714388143891439014391143921439314394143951439614397143981439914400144011440214403144041440514406144071440814409144101441114412144131441414415144161441714418144191442014421144221442314424144251442614427144281442914430144311443214433144341443514436144371443814439144401444114442144431444414445144461444714448144491445014451144521445314454144551445614457144581445914460144611446214463144641446514466144671446814469144701447114472144731447414475144761447714478144791448014481144821448314484144851448614487144881448914490144911449214493144941449514496144971449814499145001450114502145031450414505145061450714508145091451014511145121451314514145151451614517145181451914520145211452214523145241452514526145271452814529145301453114532145331453414535145361453714538145391454014541145421454314544145451454614547145481454914550145511455214553145541455514556145571455814559145601456114562145631456414565145661456714568145691457014571145721457314574145751457614577145781457914580145811458214583145841458514586145871458814589145901459114592145931459414595145961459714598145991460014601146021460314604146051460614607146081460914610146111461214613146141461514616146171461814619146201462114622146231462414625146261462714628146291463014631146321463314634146351463614637146381463914640146411464214643146441464514646146471464814649146501465114652146531465414655146561465714658146591466014661146621466314664146651466614667146681466914670146711467214673146741467514676146771467814679146801468114682146831468414685146861468714688146891469014691146921469314694146951469614697146981469914700147011470214703147041470514706147071470814709147101471114712147131471414715147161471714718147191472014721147221472314724147251472614727147281472914730147311473214733147341473514736147371473814739147401474114742147431474414745147461474714748147491475014751147521475314754147551475614757147581475914760147611476214763147641476514766147671476814769147701477114772147731477414775147761477714778147791478014781147821478314784147851478614787147881478914790147911479214793147941479514796147971479814799148001480114802148031480414805148061480714808148091481014811148121481314814148151481614817148181481914820148211482214823148241482514826148271482814829148301483114832148331483414835148361483714838148391484014841148421484314844148451484614847148481484914850148511485214853148541485514856148571485814859148601486114862148631486414865148661486714868148691487014871148721487314874148751487614877148781487914880148811488214883148841488514886148871488814889148901489114892148931489414895148961489714898148991490014901149021490314904149051490614907149081490914910149111491214913149141491514916149171491814919149201492114922149231492414925149261492714928149291493014931149321493314934149351493614937149381493914940149411494214943149441494514946149471494814949149501495114952149531495414955149561495714958149591496014961149621496314964149651496614967149681496914970149711497214973149741497514976149771497814979149801498114982149831498414985149861498714988149891499014991149921499314994149951499614997149981499915000150011500215003150041500515006150071500815009150101501115012150131501415015150161501715018150191502015021150221502315024150251502615027150281502915030150311503215033150341503515036150371503815039150401504115042150431504415045150461504715048150491505015051150521505315054150551505615057150581505915060150611506215063150641506515066150671506815069150701507115072150731507415075150761507715078150791508015081150821508315084150851508615087150881508915090150911509215093150941509515096150971509815099151001510115102151031510415105151061510715108151091511015111151121511315114151151511615117151181511915120151211512215123151241512515126151271512815129151301513115132151331513415135151361513715138151391514015141151421514315144151451514615147151481514915150151511515215153151541515515156151571515815159151601516115162151631516415165151661516715168151691517015171151721517315174151751517615177151781517915180151811518215183151841518515186151871518815189151901519115192151931519415195151961519715198151991520015201152021520315204152051520615207152081520915210152111521215213152141521515216152171521815219152201522115222152231522415225152261522715228152291523015231152321523315234152351523615237152381523915240152411524215243152441524515246152471524815249152501525115252152531525415255152561525715258152591526015261152621526315264152651526615267152681526915270152711527215273152741527515276152771527815279152801528115282152831528415285152861528715288152891529015291152921529315294152951529615297152981529915300153011530215303153041530515306153071530815309153101531115312153131531415315153161531715318153191532015321153221532315324153251532615327153281532915330153311533215333153341533515336153371533815339153401534115342153431534415345153461534715348153491535015351153521535315354153551535615357153581535915360153611536215363153641536515366153671536815369153701537115372153731537415375153761537715378153791538015381153821538315384153851538615387153881538915390153911539215393153941539515396153971539815399154001540115402154031540415405154061540715408154091541015411154121541315414154151541615417154181541915420154211542215423154241542515426154271542815429154301543115432154331543415435154361543715438154391544015441154421544315444154451544615447154481544915450154511545215453154541545515456154571545815459154601546115462154631546415465154661546715468154691547015471154721547315474154751547615477154781547915480154811548215483154841548515486154871548815489154901549115492154931549415495154961549715498154991550015501155021550315504155051550615507155081550915510155111551215513155141551515516155171551815519155201552115522155231552415525155261552715528155291553015531155321553315534155351553615537155381553915540155411554215543155441554515546155471554815549155501555115552155531555415555155561555715558155591556015561155621556315564155651556615567155681556915570155711557215573155741557515576155771557815579155801558115582155831558415585155861558715588155891559015591155921559315594155951559615597155981559915600156011560215603156041560515606156071560815609156101561115612156131561415615156161561715618156191562015621156221562315624156251562615627156281562915630156311563215633156341563515636156371563815639156401564115642156431564415645156461564715648156491565015651156521565315654156551565615657156581565915660156611566215663156641566515666156671566815669156701567115672156731567415675156761567715678156791568015681156821568315684156851568615687156881568915690156911569215693156941569515696156971569815699157001570115702157031570415705157061570715708157091571015711157121571315714157151571615717157181571915720157211572215723157241572515726157271572815729157301573115732157331573415735157361573715738157391574015741157421574315744157451574615747157481574915750157511575215753157541575515756157571575815759157601576115762157631576415765157661576715768157691577015771157721577315774157751577615777157781577915780157811578215783157841578515786157871578815789157901579115792157931579415795157961579715798157991580015801158021580315804158051580615807158081580915810158111581215813158141581515816158171581815819158201582115822158231582415825158261582715828158291583015831158321583315834158351583615837158381583915840158411584215843158441584515846158471584815849158501585115852158531585415855158561585715858158591586015861158621586315864158651586615867158681586915870158711587215873158741587515876158771587815879158801588115882158831588415885158861588715888158891589015891158921589315894158951589615897158981589915900159011590215903159041590515906159071590815909159101591115912159131591415915159161591715918159191592015921159221592315924159251592615927159281592915930159311593215933159341593515936159371593815939159401594115942159431594415945159461594715948159491595015951159521595315954159551595615957159581595915960159611596215963159641596515966159671596815969159701597115972159731597415975159761597715978159791598015981159821598315984159851598615987159881598915990159911599215993159941599515996159971599815999160001600116002160031600416005160061600716008160091601016011160121601316014160151601616017160181601916020160211602216023160241602516026160271602816029160301603116032160331603416035160361603716038160391604016041160421604316044160451604616047160481604916050160511605216053160541605516056160571605816059160601606116062160631606416065160661606716068160691607016071160721607316074160751607616077160781607916080160811608216083160841608516086160871608816089160901609116092160931609416095160961609716098160991610016101161021610316104161051610616107161081610916110161111611216113161141611516116161171611816119161201612116122161231612416125161261612716128161291613016131161321613316134161351613616137161381613916140161411614216143161441614516146161471614816149161501615116152161531615416155161561615716158161591616016161161621616316164161651616616167161681616916170161711617216173161741617516176161771617816179161801618116182161831618416185161861618716188161891619016191161921619316194161951619616197161981619916200162011620216203162041620516206162071620816209162101621116212162131621416215162161621716218162191622016221162221622316224162251622616227162281622916230162311623216233162341623516236162371623816239162401624116242162431624416245162461624716248162491625016251162521625316254162551625616257162581625916260162611626216263162641626516266162671626816269162701627116272162731627416275162761627716278162791628016281162821628316284162851628616287162881628916290162911629216293162941629516296162971629816299163001630116302163031630416305163061630716308163091631016311163121631316314163151631616317163181631916320163211632216323163241632516326163271632816329163301633116332163331633416335163361633716338163391634016341163421634316344163451634616347163481634916350163511635216353163541635516356163571635816359163601636116362163631636416365163661636716368163691637016371163721637316374163751637616377163781637916380163811638216383163841638516386163871638816389163901639116392163931639416395163961639716398163991640016401164021640316404164051640616407164081640916410164111641216413164141641516416164171641816419164201642116422164231642416425164261642716428164291643016431164321643316434164351643616437164381643916440164411644216443164441644516446164471644816449164501645116452164531645416455164561645716458164591646016461164621646316464164651646616467164681646916470164711647216473164741647516476164771647816479164801648116482164831648416485164861648716488164891649016491164921649316494164951649616497164981649916500165011650216503165041650516506165071650816509165101651116512165131651416515165161651716518165191652016521165221652316524165251652616527165281652916530165311653216533165341653516536165371653816539165401654116542165431654416545165461654716548165491655016551165521655316554165551655616557165581655916560165611656216563165641656516566165671656816569165701657116572165731657416575165761657716578165791658016581165821658316584165851658616587165881658916590165911659216593165941659516596165971659816599166001660116602166031660416605166061660716608166091661016611166121661316614166151661616617166181661916620166211662216623166241662516626166271662816629166301663116632166331663416635166361663716638166391664016641166421664316644166451664616647166481664916650166511665216653166541665516656166571665816659166601666116662166631666416665166661666716668166691667016671166721667316674166751667616677166781667916680166811668216683166841668516686166871668816689166901669116692166931669416695166961669716698166991670016701167021670316704167051670616707167081670916710167111671216713167141671516716167171671816719167201672116722167231672416725167261672716728167291673016731167321673316734167351673616737167381673916740167411674216743167441674516746167471674816749167501675116752167531675416755167561675716758167591676016761167621676316764167651676616767167681676916770167711677216773167741677516776167771677816779167801678116782167831678416785167861678716788167891679016791167921679316794167951679616797167981679916800168011680216803168041680516806168071680816809168101681116812168131681416815168161681716818168191682016821168221682316824168251682616827168281682916830168311683216833168341683516836168371683816839168401684116842168431684416845168461684716848168491685016851168521685316854168551685616857168581685916860168611686216863168641686516866168671686816869168701687116872168731687416875168761687716878168791688016881168821688316884168851688616887168881688916890168911689216893168941689516896168971689816899169001690116902169031690416905169061690716908169091691016911169121691316914169151691616917169181691916920169211692216923169241692516926169271692816929169301693116932169331693416935169361693716938169391694016941169421694316944169451694616947169481694916950169511695216953169541695516956169571695816959169601696116962169631696416965169661696716968169691697016971169721697316974169751697616977169781697916980169811698216983169841698516986169871698816989169901699116992169931699416995169961699716998169991700017001170021700317004170051700617007170081700917010170111701217013170141701517016170171701817019170201702117022170231702417025170261702717028170291703017031170321703317034170351703617037170381703917040170411704217043170441704517046170471704817049170501705117052170531705417055170561705717058170591706017061170621706317064170651706617067170681706917070170711707217073170741707517076170771707817079170801708117082170831708417085170861708717088170891709017091170921709317094170951709617097170981709917100171011710217103171041710517106171071710817109171101711117112171131711417115171161711717118171191712017121171221712317124171251712617127171281712917130171311713217133171341713517136171371713817139171401714117142171431714417145171461714717148171491715017151171521715317154171551715617157171581715917160171611716217163171641716517166171671716817169171701717117172171731717417175171761717717178171791718017181171821718317184171851718617187171881718917190171911719217193171941719517196171971719817199172001720117202172031720417205172061720717208172091721017211172121721317214172151721617217172181721917220172211722217223172241722517226172271722817229172301723117232172331723417235172361723717238172391724017241172421724317244172451724617247172481724917250172511725217253172541725517256172571725817259172601726117262172631726417265172661726717268172691727017271172721727317274172751727617277172781727917280172811728217283172841728517286172871728817289172901729117292172931729417295172961729717298172991730017301173021730317304173051730617307173081730917310173111731217313173141731517316173171731817319173201732117322173231732417325173261732717328173291733017331173321733317334173351733617337173381733917340173411734217343173441734517346173471734817349173501735117352173531735417355173561735717358173591736017361173621736317364173651736617367173681736917370173711737217373173741737517376173771737817379173801738117382173831738417385173861738717388173891739017391173921739317394173951739617397173981739917400174011740217403174041740517406174071740817409174101741117412174131741417415174161741717418174191742017421174221742317424174251742617427174281742917430174311743217433174341743517436174371743817439174401744117442174431744417445174461744717448174491745017451174521745317454174551745617457174581745917460174611746217463174641746517466174671746817469174701747117472174731747417475174761747717478174791748017481174821748317484174851748617487174881748917490174911749217493174941749517496174971749817499175001750117502175031750417505175061750717508175091751017511175121751317514175151751617517175181751917520175211752217523175241752517526175271752817529175301753117532175331753417535175361753717538175391754017541175421754317544175451754617547175481754917550175511755217553175541755517556175571755817559175601756117562175631756417565175661756717568175691757017571175721757317574175751757617577175781757917580175811758217583175841758517586175871758817589175901759117592175931759417595175961759717598175991760017601176021760317604176051760617607176081760917610176111761217613176141761517616176171761817619176201762117622176231762417625176261762717628176291763017631176321763317634176351763617637176381763917640176411764217643176441764517646176471764817649176501765117652176531765417655176561765717658176591766017661176621766317664176651766617667176681766917670176711767217673176741767517676176771767817679176801768117682176831768417685176861768717688176891769017691176921769317694176951769617697176981769917700177011770217703177041770517706177071770817709177101771117712177131771417715177161771717718177191772017721177221772317724177251772617727177281772917730177311773217733177341773517736177371773817739177401774117742177431774417745177461774717748177491775017751177521775317754177551775617757177581775917760177611776217763177641776517766177671776817769177701777117772177731777417775177761777717778177791778017781177821778317784177851778617787177881778917790177911779217793177941779517796177971779817799178001780117802178031780417805178061780717808178091781017811178121781317814178151781617817178181781917820178211782217823178241782517826178271782817829178301783117832178331783417835178361783717838178391784017841178421784317844178451784617847178481784917850178511785217853178541785517856178571785817859178601786117862178631786417865178661786717868178691787017871178721787317874178751787617877178781787917880178811788217883178841788517886178871788817889178901789117892178931789417895178961789717898178991790017901179021790317904179051790617907179081790917910179111791217913179141791517916179171791817919179201792117922179231792417925179261792717928179291793017931179321793317934179351793617937179381793917940179411794217943179441794517946179471794817949179501795117952179531795417955179561795717958179591796017961179621796317964179651796617967179681796917970179711797217973179741797517976179771797817979179801798117982179831798417985179861798717988179891799017991179921799317994179951799617997179981799918000180011800218003180041800518006180071800818009180101801118012180131801418015180161801718018180191802018021180221802318024180251802618027180281802918030180311803218033180341803518036180371803818039180401804118042180431804418045180461804718048180491805018051180521805318054180551805618057180581805918060180611806218063180641806518066180671806818069180701807118072180731807418075180761807718078180791808018081180821808318084180851808618087180881808918090180911809218093180941809518096180971809818099181001810118102181031810418105181061810718108181091811018111181121811318114181151811618117181181811918120181211812218123181241812518126181271812818129181301813118132181331813418135181361813718138181391814018141181421814318144181451814618147181481814918150181511815218153181541815518156181571815818159181601816118162181631816418165181661816718168181691817018171181721817318174181751817618177181781817918180181811818218183181841818518186181871818818189181901819118192181931819418195181961819718198181991820018201182021820318204182051820618207182081820918210182111821218213182141821518216182171821818219182201822118222182231822418225182261822718228182291823018231182321823318234182351823618237182381823918240182411824218243182441824518246182471824818249182501825118252182531825418255182561825718258182591826018261182621826318264182651826618267182681826918270182711827218273182741827518276182771827818279182801828118282182831828418285182861828718288182891829018291182921829318294182951829618297182981829918300183011830218303183041830518306183071830818309183101831118312183131831418315183161831718318183191832018321183221832318324183251832618327183281832918330183311833218333183341833518336183371833818339183401834118342183431834418345183461834718348183491835018351183521835318354183551835618357183581835918360183611836218363183641836518366183671836818369183701837118372183731837418375183761837718378183791838018381183821838318384183851838618387183881838918390183911839218393183941839518396183971839818399184001840118402184031840418405184061840718408184091841018411184121841318414184151841618417184181841918420184211842218423184241842518426184271842818429184301843118432184331843418435184361843718438184391844018441184421844318444184451844618447184481844918450184511845218453184541845518456184571845818459184601846118462184631846418465184661846718468184691847018471184721847318474184751847618477184781847918480184811848218483184841848518486184871848818489184901849118492184931849418495184961849718498184991850018501185021850318504185051850618507185081850918510185111851218513185141851518516185171851818519185201852118522185231852418525185261852718528185291853018531185321853318534185351853618537185381853918540185411854218543185441854518546185471854818549185501855118552185531855418555185561855718558185591856018561185621856318564185651856618567185681856918570185711857218573185741857518576185771857818579185801858118582185831858418585185861858718588185891859018591185921859318594185951859618597185981859918600186011860218603186041860518606186071860818609186101861118612186131861418615186161861718618186191862018621186221862318624186251862618627186281862918630186311863218633186341863518636186371863818639186401864118642186431864418645186461864718648186491865018651186521865318654186551865618657186581865918660186611866218663186641866518666186671866818669186701867118672186731867418675186761867718678186791868018681186821868318684186851868618687186881868918690186911869218693186941869518696186971869818699187001870118702187031870418705187061870718708187091871018711187121871318714187151871618717187181871918720187211872218723187241872518726187271872818729187301873118732187331873418735187361873718738187391874018741187421874318744187451874618747187481874918750187511875218753187541875518756187571875818759187601876118762187631876418765187661876718768187691877018771187721877318774187751877618777187781877918780187811878218783187841878518786187871878818789187901879118792187931879418795187961879718798187991880018801188021880318804188051880618807188081880918810188111881218813188141881518816188171881818819188201882118822188231882418825188261882718828188291883018831188321883318834188351883618837188381883918840188411884218843188441884518846188471884818849188501885118852188531885418855188561885718858188591886018861188621886318864188651886618867188681886918870188711887218873188741887518876188771887818879188801888118882188831888418885188861888718888188891889018891188921889318894188951889618897188981889918900189011890218903189041890518906189071890818909189101891118912189131891418915189161891718918189191892018921189221892318924189251892618927189281892918930189311893218933189341893518936189371893818939189401894118942189431894418945189461894718948189491895018951189521895318954189551895618957189581895918960189611896218963189641896518966189671896818969189701897118972189731897418975189761897718978189791898018981189821898318984189851898618987189881898918990189911899218993189941899518996189971899818999190001900119002190031900419005190061900719008190091901019011190121901319014190151901619017190181901919020190211902219023190241902519026190271902819029190301903119032190331903419035190361903719038190391904019041190421904319044190451904619047190481904919050190511905219053190541905519056190571905819059190601906119062190631906419065190661906719068190691907019071190721907319074190751907619077190781907919080190811908219083190841908519086190871908819089190901909119092190931909419095190961909719098190991910019101191021910319104191051910619107191081910919110191111911219113191141911519116191171911819119191201912119122191231912419125191261912719128191291913019131191321913319134191351913619137191381913919140191411914219143191441914519146191471914819149191501915119152191531915419155191561915719158191591916019161191621916319164191651916619167191681916919170191711917219173191741917519176191771917819179191801918119182191831918419185191861918719188191891919019191191921919319194191951919619197191981919919200192011920219203192041920519206192071920819209192101921119212192131921419215192161921719218192191922019221192221922319224192251922619227192281922919230192311923219233192341923519236192371923819239192401924119242192431924419245192461924719248192491925019251192521925319254192551925619257192581925919260192611926219263192641926519266192671926819269192701927119272192731927419275192761927719278192791928019281192821928319284192851928619287192881928919290192911929219293192941929519296192971929819299193001930119302193031930419305193061930719308193091931019311193121931319314193151931619317193181931919320193211932219323193241932519326193271932819329193301933119332193331933419335193361933719338193391934019341193421934319344193451934619347193481934919350193511935219353193541935519356193571935819359193601936119362193631936419365193661936719368193691937019371193721937319374193751937619377193781937919380193811938219383193841938519386193871938819389193901939119392193931939419395193961939719398193991940019401194021940319404194051940619407194081940919410194111941219413194141941519416194171941819419194201942119422194231942419425194261942719428194291943019431194321943319434194351943619437194381943919440194411944219443194441944519446194471944819449194501945119452194531945419455194561945719458194591946019461194621946319464194651946619467194681946919470194711947219473194741947519476194771947819479194801948119482194831948419485194861948719488194891949019491194921949319494194951949619497194981949919500195011950219503195041950519506195071950819509195101951119512195131951419515195161951719518195191952019521195221952319524195251952619527195281952919530195311953219533195341953519536195371953819539195401954119542195431954419545195461954719548195491955019551195521955319554195551955619557195581955919560195611956219563195641956519566195671956819569195701957119572195731957419575195761957719578195791958019581195821958319584195851958619587195881958919590195911959219593195941959519596195971959819599196001960119602196031960419605196061960719608196091961019611196121961319614196151961619617196181961919620196211962219623196241962519626196271962819629196301963119632196331963419635196361963719638196391964019641196421964319644196451964619647196481964919650196511965219653196541965519656196571965819659196601966119662196631966419665196661966719668196691967019671196721967319674196751967619677196781967919680196811968219683196841968519686196871968819689196901969119692196931969419695196961969719698196991970019701197021970319704197051970619707197081970919710197111971219713197141971519716197171971819719197201972119722197231972419725197261972719728197291973019731197321973319734197351973619737197381973919740197411974219743197441974519746197471974819749197501975119752197531975419755197561975719758197591976019761197621976319764197651976619767197681976919770197711977219773197741977519776197771977819779197801978119782197831978419785197861978719788197891979019791197921979319794197951979619797197981979919800198011980219803198041980519806198071980819809198101981119812198131981419815198161981719818198191982019821198221982319824198251982619827198281982919830198311983219833198341983519836198371983819839198401984119842198431984419845198461984719848198491985019851198521985319854198551985619857198581985919860198611986219863198641986519866198671986819869198701987119872198731987419875198761987719878198791988019881198821988319884198851988619887198881988919890198911989219893198941989519896198971989819899199001990119902199031990419905199061990719908199091991019911199121991319914199151991619917199181991919920199211992219923199241992519926199271992819929199301993119932199331993419935199361993719938199391994019941199421994319944199451994619947199481994919950199511995219953199541995519956199571995819959199601996119962199631996419965199661996719968199691997019971199721997319974199751997619977199781997919980199811998219983199841998519986199871998819989199901999119992199931999419995199961999719998199992000020001200022000320004200052000620007200082000920010200112001220013200142001520016200172001820019200202002120022200232002420025200262002720028200292003020031200322003320034200352003620037200382003920040200412004220043200442004520046200472004820049200502005120052200532005420055200562005720058200592006020061200622006320064200652006620067200682006920070200712007220073200742007520076200772007820079200802008120082200832008420085200862008720088200892009020091200922009320094200952009620097200982009920100201012010220103201042010520106201072010820109201102011120112201132011420115201162011720118201192012020121201222012320124201252012620127201282012920130201312013220133201342013520136201372013820139201402014120142201432014420145201462014720148201492015020151201522015320154201552015620157201582015920160201612016220163201642016520166201672016820169201702017120172201732017420175201762017720178201792018020181201822018320184201852018620187201882018920190201912019220193201942019520196201972019820199202002020120202202032020420205202062020720208202092021020211202122021320214202152021620217202182021920220202212022220223202242022520226202272022820229202302023120232202332023420235202362023720238202392024020241202422024320244202452024620247202482024920250202512025220253202542025520256202572025820259202602026120262202632026420265202662026720268202692027020271202722027320274202752027620277202782027920280202812028220283202842028520286202872028820289202902029120292202932029420295202962029720298202992030020301203022030320304203052030620307203082030920310203112031220313203142031520316203172031820319203202032120322203232032420325203262032720328203292033020331203322033320334203352033620337203382033920340203412034220343203442034520346203472034820349203502035120352203532035420355203562035720358203592036020361203622036320364203652036620367203682036920370203712037220373203742037520376203772037820379203802038120382203832038420385203862038720388203892039020391203922039320394203952039620397203982039920400204012040220403204042040520406204072040820409204102041120412204132041420415204162041720418204192042020421204222042320424204252042620427204282042920430204312043220433204342043520436204372043820439204402044120442204432044420445204462044720448204492045020451204522045320454204552045620457204582045920460204612046220463204642046520466204672046820469204702047120472204732047420475204762047720478204792048020481204822048320484204852048620487204882048920490204912049220493204942049520496204972049820499205002050120502205032050420505205062050720508205092051020511205122051320514205152051620517205182051920520205212052220523205242052520526205272052820529205302053120532205332053420535205362053720538205392054020541205422054320544205452054620547205482054920550205512055220553205542055520556205572055820559205602056120562205632056420565205662056720568205692057020571205722057320574205752057620577205782057920580205812058220583205842058520586205872058820589205902059120592205932059420595205962059720598205992060020601206022060320604206052060620607206082060920610206112061220613206142061520616206172061820619206202062120622206232062420625206262062720628206292063020631206322063320634206352063620637206382063920640206412064220643206442064520646206472064820649206502065120652206532065420655206562065720658206592066020661206622066320664206652066620667206682066920670206712067220673206742067520676206772067820679206802068120682206832068420685206862068720688206892069020691206922069320694206952069620697206982069920700207012070220703207042070520706207072070820709207102071120712207132071420715207162071720718207192072020721207222072320724207252072620727207282072920730207312073220733207342073520736207372073820739207402074120742207432074420745207462074720748207492075020751207522075320754207552075620757207582075920760207612076220763207642076520766207672076820769207702077120772207732077420775207762077720778207792078020781207822078320784207852078620787207882078920790207912079220793207942079520796207972079820799208002080120802208032080420805208062080720808208092081020811208122081320814208152081620817208182081920820208212082220823208242082520826208272082820829208302083120832208332083420835208362083720838208392084020841208422084320844208452084620847208482084920850208512085220853208542085520856208572085820859208602086120862208632086420865208662086720868208692087020871208722087320874208752087620877208782087920880208812088220883208842088520886208872088820889208902089120892208932089420895208962089720898208992090020901209022090320904209052090620907209082090920910209112091220913209142091520916209172091820919209202092120922209232092420925209262092720928209292093020931209322093320934209352093620937209382093920940209412094220943209442094520946209472094820949209502095120952209532095420955209562095720958209592096020961209622096320964209652096620967209682096920970209712097220973209742097520976209772097820979209802098120982209832098420985209862098720988209892099020991209922099320994209952099620997209982099921000210012100221003210042100521006210072100821009210102101121012210132101421015210162101721018210192102021021210222102321024210252102621027210282102921030210312103221033210342103521036210372103821039210402104121042210432104421045210462104721048210492105021051210522105321054210552105621057210582105921060210612106221063210642106521066210672106821069210702107121072210732107421075210762107721078210792108021081210822108321084210852108621087210882108921090210912109221093210942109521096210972109821099211002110121102211032110421105211062110721108211092111021111211122111321114211152111621117211182111921120211212112221123211242112521126211272112821129211302113121132211332113421135211362113721138211392114021141211422114321144211452114621147211482114921150211512115221153211542115521156211572115821159211602116121162211632116421165211662116721168211692117021171211722117321174211752117621177211782117921180211812118221183211842118521186211872118821189211902119121192211932119421195211962119721198211992120021201212022120321204212052120621207212082120921210212112121221213212142121521216212172121821219212202122121222212232122421225212262122721228212292123021231212322123321234212352123621237212382123921240212412124221243212442124521246212472124821249212502125121252212532125421255212562125721258212592126021261212622126321264212652126621267212682126921270212712127221273212742127521276212772127821279212802128121282212832128421285212862128721288212892129021291212922129321294212952129621297212982129921300213012130221303213042130521306213072130821309213102131121312213132131421315213162131721318213192132021321213222132321324213252132621327213282132921330213312133221333213342133521336213372133821339213402134121342213432134421345213462134721348213492135021351213522135321354213552135621357213582135921360213612136221363213642136521366213672136821369213702137121372213732137421375213762137721378213792138021381213822138321384213852138621387213882138921390213912139221393213942139521396213972139821399214002140121402214032140421405214062140721408214092141021411214122141321414214152141621417214182141921420214212142221423214242142521426214272142821429214302143121432214332143421435214362143721438214392144021441214422144321444214452144621447214482144921450214512145221453214542145521456214572145821459214602146121462214632146421465214662146721468214692147021471214722147321474214752147621477214782147921480214812148221483214842148521486214872148821489214902149121492214932149421495214962149721498214992150021501215022150321504215052150621507215082150921510215112151221513215142151521516215172151821519215202152121522215232152421525215262152721528215292153021531215322153321534215352153621537215382153921540215412154221543215442154521546215472154821549215502155121552215532155421555215562155721558215592156021561215622156321564215652156621567215682156921570215712157221573215742157521576215772157821579215802158121582215832158421585215862158721588215892159021591215922159321594215952159621597215982159921600216012160221603216042160521606216072160821609216102161121612216132161421615216162161721618216192162021621216222162321624216252162621627216282162921630216312163221633216342163521636216372163821639216402164121642216432164421645216462164721648216492165021651216522165321654216552165621657216582165921660216612166221663216642166521666216672166821669216702167121672216732167421675216762167721678216792168021681216822168321684216852168621687216882168921690216912169221693216942169521696216972169821699217002170121702217032170421705217062170721708217092171021711217122171321714217152171621717217182171921720217212172221723217242172521726217272172821729217302173121732217332173421735217362173721738217392174021741217422174321744217452174621747217482174921750217512175221753217542175521756217572175821759217602176121762217632176421765217662176721768217692177021771217722177321774217752177621777217782177921780217812178221783217842178521786217872178821789217902179121792217932179421795217962179721798217992180021801218022180321804218052180621807218082180921810218112181221813218142181521816218172181821819218202182121822218232182421825218262182721828218292183021831218322183321834218352183621837218382183921840218412184221843218442184521846218472184821849218502185121852218532185421855218562185721858218592186021861218622186321864218652186621867218682186921870218712187221873218742187521876218772187821879218802188121882218832188421885218862188721888218892189021891218922189321894218952189621897218982189921900219012190221903219042190521906219072190821909219102191121912219132191421915219162191721918219192192021921219222192321924219252192621927219282192921930219312193221933219342193521936219372193821939219402194121942219432194421945219462194721948219492195021951219522195321954219552195621957219582195921960219612196221963219642196521966219672196821969219702197121972219732197421975219762197721978219792198021981219822198321984219852198621987219882198921990219912199221993219942199521996219972199821999220002200122002220032200422005220062200722008220092201022011220122201322014220152201622017220182201922020220212202222023220242202522026220272202822029220302203122032220332203422035220362203722038220392204022041220422204322044220452204622047220482204922050220512205222053220542205522056220572205822059220602206122062220632206422065220662206722068220692207022071220722207322074220752207622077220782207922080220812208222083220842208522086220872208822089220902209122092220932209422095220962209722098220992210022101221022210322104221052210622107221082210922110221112211222113221142211522116221172211822119221202212122122221232212422125221262212722128221292213022131221322213322134221352213622137221382213922140221412214222143221442214522146221472214822149221502215122152221532215422155221562215722158221592216022161221622216322164221652216622167221682216922170221712217222173221742217522176221772217822179221802218122182221832218422185221862218722188221892219022191221922219322194221952219622197221982219922200222012220222203222042220522206222072220822209222102221122212222132221422215222162221722218222192222022221222222222322224222252222622227222282222922230222312223222233222342223522236222372223822239222402224122242222432224422245222462224722248222492225022251222522225322254222552225622257222582225922260222612226222263222642226522266222672226822269222702227122272222732227422275222762227722278222792228022281222822228322284222852228622287222882228922290222912229222293222942229522296222972229822299223002230122302223032230422305223062230722308223092231022311223122231322314223152231622317223182231922320223212232222323223242232522326223272232822329223302233122332223332233422335223362233722338223392234022341223422234322344223452234622347223482234922350223512235222353223542235522356223572235822359223602236122362223632236422365223662236722368223692237022371223722237322374223752237622377223782237922380223812238222383223842238522386223872238822389223902239122392223932239422395223962239722398223992240022401224022240322404224052240622407224082240922410224112241222413224142241522416224172241822419224202242122422224232242422425224262242722428224292243022431224322243322434224352243622437224382243922440224412244222443224442244522446224472244822449224502245122452224532245422455224562245722458224592246022461224622246322464224652246622467224682246922470224712247222473224742247522476224772247822479224802248122482224832248422485224862248722488224892249022491224922249322494224952249622497224982249922500225012250222503225042250522506225072250822509225102251122512225132251422515225162251722518225192252022521225222252322524225252252622527225282252922530225312253222533225342253522536225372253822539225402254122542225432254422545225462254722548225492255022551225522255322554225552255622557225582255922560225612256222563225642256522566225672256822569225702257122572225732257422575225762257722578225792258022581225822258322584225852258622587225882258922590225912259222593225942259522596225972259822599226002260122602226032260422605226062260722608226092261022611226122261322614226152261622617226182261922620226212262222623226242262522626226272262822629226302263122632226332263422635226362263722638226392264022641226422264322644226452264622647226482264922650226512265222653226542265522656226572265822659226602266122662226632266422665226662266722668226692267022671226722267322674226752267622677226782267922680226812268222683226842268522686226872268822689226902269122692226932269422695226962269722698226992270022701227022270322704227052270622707227082270922710227112271222713227142271522716227172271822719227202272122722227232272422725227262272722728227292273022731227322273322734227352273622737227382273922740227412274222743227442274522746227472274822749227502275122752227532275422755227562275722758227592276022761227622276322764227652276622767227682276922770227712277222773227742277522776227772277822779227802278122782227832278422785227862278722788227892279022791227922279322794227952279622797227982279922800228012280222803228042280522806228072280822809228102281122812228132281422815228162281722818228192282022821228222282322824228252282622827228282282922830228312283222833228342283522836228372283822839228402284122842228432284422845228462284722848228492285022851228522285322854228552285622857228582285922860228612286222863228642286522866228672286822869228702287122872228732287422875228762287722878228792288022881228822288322884228852288622887228882288922890228912289222893228942289522896228972289822899229002290122902229032290422905229062290722908229092291022911229122291322914229152291622917229182291922920229212292222923229242292522926229272292822929229302293122932229332293422935229362293722938229392294022941229422294322944229452294622947229482294922950229512295222953229542295522956229572295822959229602296122962229632296422965229662296722968229692297022971229722297322974229752297622977229782297922980229812298222983229842298522986229872298822989229902299122992229932299422995229962299722998229992300023001230022300323004230052300623007230082300923010230112301223013230142301523016230172301823019230202302123022230232302423025230262302723028230292303023031230322303323034230352303623037230382303923040230412304223043230442304523046230472304823049230502305123052230532305423055230562305723058230592306023061230622306323064230652306623067230682306923070230712307223073230742307523076230772307823079230802308123082230832308423085230862308723088230892309023091230922309323094230952309623097230982309923100231012310223103231042310523106231072310823109231102311123112231132311423115231162311723118231192312023121231222312323124231252312623127231282312923130231312313223133231342313523136231372313823139231402314123142231432314423145231462314723148231492315023151231522315323154231552315623157231582315923160231612316223163231642316523166231672316823169231702317123172231732317423175231762317723178231792318023181231822318323184231852318623187231882318923190231912319223193231942319523196231972319823199232002320123202232032320423205232062320723208232092321023211232122321323214232152321623217232182321923220232212322223223232242322523226232272322823229232302323123232232332323423235232362323723238232392324023241232422324323244232452324623247232482324923250232512325223253232542325523256232572325823259232602326123262232632326423265232662326723268232692327023271232722327323274232752327623277232782327923280232812328223283232842328523286232872328823289232902329123292232932329423295232962329723298232992330023301233022330323304233052330623307233082330923310233112331223313233142331523316233172331823319233202332123322233232332423325233262332723328233292333023331233322333323334233352333623337233382333923340233412334223343233442334523346233472334823349233502335123352233532335423355233562335723358233592336023361233622336323364233652336623367233682336923370233712337223373233742337523376233772337823379233802338123382233832338423385233862338723388233892339023391233922339323394233952339623397233982339923400234012340223403234042340523406234072340823409234102341123412234132341423415234162341723418234192342023421234222342323424234252342623427234282342923430234312343223433234342343523436234372343823439234402344123442234432344423445234462344723448234492345023451234522345323454234552345623457234582345923460234612346223463234642346523466234672346823469234702347123472234732347423475234762347723478234792348023481234822348323484234852348623487234882348923490234912349223493234942349523496234972349823499235002350123502235032350423505235062350723508235092351023511235122351323514235152351623517235182351923520235212352223523235242352523526235272352823529235302353123532235332353423535235362353723538235392354023541235422354323544235452354623547235482354923550235512355223553235542355523556235572355823559235602356123562235632356423565235662356723568235692357023571235722357323574235752357623577235782357923580235812358223583235842358523586235872358823589235902359123592235932359423595235962359723598235992360023601236022360323604236052360623607236082360923610236112361223613236142361523616236172361823619236202362123622236232362423625236262362723628236292363023631236322363323634236352363623637236382363923640236412364223643236442364523646236472364823649236502365123652236532365423655236562365723658236592366023661236622366323664236652366623667236682366923670236712367223673236742367523676236772367823679236802368123682236832368423685236862368723688236892369023691236922369323694236952369623697236982369923700237012370223703237042370523706237072370823709237102371123712237132371423715237162371723718237192372023721237222372323724237252372623727237282372923730237312373223733237342373523736237372373823739237402374123742237432374423745237462374723748237492375023751237522375323754237552375623757237582375923760237612376223763237642376523766237672376823769237702377123772237732377423775237762377723778237792378023781237822378323784237852378623787237882378923790237912379223793237942379523796237972379823799238002380123802238032380423805238062380723808238092381023811238122381323814238152381623817238182381923820238212382223823238242382523826238272382823829238302383123832238332383423835238362383723838238392384023841238422384323844238452384623847238482384923850238512385223853238542385523856238572385823859238602386123862238632386423865238662386723868238692387023871238722387323874238752387623877238782387923880238812388223883238842388523886238872388823889238902389123892238932389423895238962389723898238992390023901239022390323904239052390623907239082390923910239112391223913239142391523916239172391823919239202392123922239232392423925239262392723928239292393023931239322393323934239352393623937239382393923940239412394223943239442394523946239472394823949239502395123952239532395423955239562395723958239592396023961239622396323964239652396623967239682396923970239712397223973239742397523976239772397823979239802398123982239832398423985239862398723988239892399023991239922399323994239952399623997239982399924000240012400224003240042400524006240072400824009240102401124012240132401424015240162401724018240192402024021240222402324024240252402624027240282402924030240312403224033240342403524036240372403824039240402404124042240432404424045240462404724048240492405024051240522405324054240552405624057240582405924060240612406224063240642406524066240672406824069240702407124072240732407424075240762407724078240792408024081240822408324084240852408624087240882408924090240912409224093240942409524096240972409824099241002410124102241032410424105241062410724108241092411024111241122411324114241152411624117241182411924120241212412224123241242412524126241272412824129241302413124132241332413424135241362413724138241392414024141241422414324144241452414624147241482414924150241512415224153241542415524156241572415824159241602416124162241632416424165241662416724168241692417024171241722417324174241752417624177241782417924180241812418224183241842418524186241872418824189241902419124192241932419424195241962419724198241992420024201242022420324204242052420624207242082420924210242112421224213242142421524216242172421824219242202422124222242232422424225242262422724228242292423024231242322423324234242352423624237242382423924240242412424224243242442424524246242472424824249242502425124252242532425424255242562425724258242592426024261242622426324264242652426624267242682426924270242712427224273242742427524276242772427824279242802428124282242832428424285242862428724288242892429024291242922429324294242952429624297242982429924300243012430224303243042430524306243072430824309243102431124312243132431424315243162431724318243192432024321243222432324324243252432624327243282432924330243312433224333243342433524336243372433824339243402434124342243432434424345243462434724348243492435024351243522435324354243552435624357243582435924360243612436224363243642436524366243672436824369243702437124372243732437424375243762437724378243792438024381243822438324384243852438624387243882438924390243912439224393243942439524396243972439824399244002440124402244032440424405244062440724408244092441024411244122441324414244152441624417244182441924420244212442224423244242442524426244272442824429244302443124432244332443424435244362443724438244392444024441244422444324444244452444624447244482444924450244512445224453244542445524456244572445824459244602446124462244632446424465244662446724468244692447024471244722447324474244752447624477244782447924480244812448224483244842448524486244872448824489244902449124492244932449424495244962449724498244992450024501245022450324504245052450624507245082450924510245112451224513245142451524516245172451824519245202452124522245232452424525245262452724528245292453024531245322453324534245352453624537245382453924540245412454224543245442454524546245472454824549245502455124552245532455424555245562455724558245592456024561245622456324564245652456624567245682456924570245712457224573245742457524576245772457824579245802458124582245832458424585245862458724588245892459024591245922459324594245952459624597245982459924600246012460224603246042460524606246072460824609246102461124612246132461424615246162461724618246192462024621246222462324624246252462624627246282462924630246312463224633246342463524636246372463824639246402464124642246432464424645246462464724648246492465024651246522465324654246552465624657246582465924660246612466224663246642466524666246672466824669246702467124672246732467424675246762467724678246792468024681246822468324684246852468624687246882468924690246912469224693246942469524696246972469824699247002470124702247032470424705247062470724708247092471024711247122471324714247152471624717247182471924720247212472224723247242472524726247272472824729247302473124732247332473424735247362473724738247392474024741247422474324744247452474624747247482474924750247512475224753247542475524756247572475824759247602476124762247632476424765247662476724768247692477024771247722477324774247752477624777247782477924780247812478224783247842478524786247872478824789247902479124792247932479424795247962479724798247992480024801248022480324804248052480624807248082480924810248112481224813248142481524816248172481824819248202482124822248232482424825248262482724828248292483024831248322483324834248352483624837248382483924840248412484224843248442484524846248472484824849248502485124852248532485424855248562485724858248592486024861248622486324864248652486624867248682486924870248712487224873248742487524876248772487824879248802488124882248832488424885248862488724888248892489024891248922489324894248952489624897248982489924900249012490224903249042490524906249072490824909249102491124912249132491424915249162491724918249192492024921249222492324924249252492624927249282492924930249312493224933249342493524936249372493824939249402494124942249432494424945249462494724948249492495024951249522495324954249552495624957249582495924960249612496224963249642496524966249672496824969249702497124972249732497424975249762497724978249792498024981249822498324984249852498624987249882498924990249912499224993249942499524996249972499824999250002500125002250032500425005250062500725008250092501025011250122501325014250152501625017250182501925020250212502225023250242502525026250272502825029250302503125032250332503425035250362503725038250392504025041250422504325044250452504625047250482504925050250512505225053250542505525056250572505825059250602506125062250632506425065250662506725068250692507025071250722507325074250752507625077250782507925080250812508225083250842508525086250872508825089250902509125092250932509425095250962509725098250992510025101251022510325104251052510625107251082510925110251112511225113251142511525116251172511825119251202512125122251232512425125251262512725128251292513025131251322513325134251352513625137251382513925140251412514225143251442514525146251472514825149251502515125152251532515425155251562515725158251592516025161251622516325164251652516625167251682516925170251712517225173251742517525176251772517825179251802518125182251832518425185251862518725188251892519025191251922519325194251952519625197251982519925200252012520225203252042520525206252072520825209252102521125212252132521425215252162521725218252192522025221252222522325224252252522625227252282522925230252312523225233252342523525236252372523825239252402524125242252432524425245252462524725248252492525025251252522525325254252552525625257252582525925260252612526225263252642526525266252672526825269252702527125272252732527425275252762527725278252792528025281252822528325284252852528625287252882528925290252912529225293252942529525296252972529825299253002530125302253032530425305253062530725308253092531025311253122531325314253152531625317253182531925320253212532225323253242532525326253272532825329253302533125332253332533425335253362533725338253392534025341253422534325344253452534625347253482534925350253512535225353253542535525356253572535825359253602536125362253632536425365253662536725368253692537025371253722537325374253752537625377253782537925380253812538225383253842538525386253872538825389253902539125392253932539425395253962539725398253992540025401254022540325404254052540625407254082540925410254112541225413254142541525416254172541825419254202542125422254232542425425254262542725428254292543025431254322543325434254352543625437254382543925440254412544225443254442544525446254472544825449254502545125452254532545425455254562545725458254592546025461254622546325464254652546625467254682546925470254712547225473254742547525476254772547825479254802548125482254832548425485254862548725488254892549025491254922549325494254952549625497254982549925500255012550225503255042550525506255072550825509255102551125512255132551425515255162551725518255192552025521255222552325524255252552625527255282552925530255312553225533255342553525536255372553825539255402554125542255432554425545255462554725548255492555025551255522555325554255552555625557255582555925560255612556225563255642556525566255672556825569255702557125572255732557425575255762557725578255792558025581255822558325584255852558625587255882558925590255912559225593255942559525596255972559825599256002560125602256032560425605256062560725608256092561025611256122561325614256152561625617256182561925620256212562225623256242562525626256272562825629256302563125632256332563425635256362563725638256392564025641256422564325644256452564625647256482564925650256512565225653256542565525656256572565825659256602566125662256632566425665256662566725668256692567025671256722567325674256752567625677256782567925680256812568225683256842568525686256872568825689256902569125692256932569425695256962569725698256992570025701257022570325704257052570625707257082570925710257112571225713257142571525716257172571825719257202572125722257232572425725257262572725728257292573025731257322573325734257352573625737257382573925740257412574225743257442574525746257472574825749257502575125752257532575425755257562575725758257592576025761257622576325764257652576625767257682576925770257712577225773257742577525776257772577825779257802578125782257832578425785257862578725788257892579025791257922579325794257952579625797257982579925800258012580225803258042580525806258072580825809258102581125812258132581425815258162581725818258192582025821258222582325824258252582625827258282582925830258312583225833258342583525836258372583825839258402584125842258432584425845258462584725848258492585025851258522585325854258552585625857258582585925860258612586225863258642586525866258672586825869258702587125872258732587425875258762587725878258792588025881258822588325884258852588625887258882588925890258912589225893258942589525896258972589825899259002590125902259032590425905259062590725908259092591025911259122591325914259152591625917259182591925920259212592225923259242592525926259272592825929259302593125932259332593425935259362593725938259392594025941259422594325944259452594625947259482594925950259512595225953259542595525956259572595825959259602596125962259632596425965259662596725968259692597025971259722597325974259752597625977259782597925980259812598225983259842598525986259872598825989259902599125992259932599425995259962599725998259992600026001260022600326004260052600626007260082600926010260112601226013260142601526016260172601826019260202602126022260232602426025260262602726028260292603026031260322603326034260352603626037260382603926040260412604226043260442604526046260472604826049260502605126052260532605426055260562605726058260592606026061260622606326064260652606626067260682606926070260712607226073260742607526076260772607826079260802608126082260832608426085260862608726088260892609026091260922609326094260952609626097260982609926100261012610226103261042610526106261072610826109261102611126112261132611426115261162611726118261192612026121261222612326124261252612626127261282612926130261312613226133261342613526136261372613826139261402614126142261432614426145261462614726148261492615026151261522615326154261552615626157261582615926160261612616226163261642616526166261672616826169261702617126172261732617426175261762617726178261792618026181261822618326184261852618626187261882618926190261912619226193261942619526196261972619826199262002620126202262032620426205262062620726208262092621026211262122621326214262152621626217262182621926220262212622226223262242622526226262272622826229262302623126232262332623426235262362623726238262392624026241262422624326244262452624626247262482624926250262512625226253262542625526256262572625826259262602626126262262632626426265262662626726268262692627026271262722627326274262752627626277262782627926280262812628226283262842628526286262872628826289262902629126292262932629426295262962629726298262992630026301263022630326304263052630626307263082630926310263112631226313263142631526316263172631826319263202632126322263232632426325263262632726328263292633026331263322633326334263352633626337263382633926340263412634226343263442634526346263472634826349263502635126352263532635426355263562635726358263592636026361263622636326364263652636626367263682636926370263712637226373263742637526376263772637826379263802638126382263832638426385263862638726388263892639026391263922639326394263952639626397263982639926400264012640226403264042640526406264072640826409264102641126412264132641426415264162641726418264192642026421264222642326424264252642626427264282642926430264312643226433264342643526436264372643826439264402644126442264432644426445264462644726448264492645026451264522645326454264552645626457264582645926460
  1. (global["webpackJsonp"] = global["webpackJsonp"] || []).push([["common/vendor"],[
  2. /* 0 */,
  3. /* 1 */
  4. /*!*************************************************************!*\
  5. !*** ./node_modules/@dcloudio/uni-mp-toutiao/dist/index.js ***!
  6. \*************************************************************/
  7. /*! no static exports found */
  8. /***/ (function(module, exports, __webpack_require__) {
  9. "use strict";
  10. /* WEBPACK VAR INJECTION */(function(global) {
  11. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  12. Object.defineProperty(exports, "__esModule", {
  13. value: true
  14. });
  15. exports.createApp = createApp;
  16. exports.createComponent = createComponent;
  17. exports.createPage = createPage;
  18. exports.createPlugin = createPlugin;
  19. exports.createSubpackageApp = createSubpackageApp;
  20. exports.default = void 0;
  21. var _slicedToArray2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/slicedToArray */ 4));
  22. var _defineProperty2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/defineProperty */ 10));
  23. var _construct2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/construct */ 14));
  24. var _classCallCheck2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/classCallCheck */ 17));
  25. var _createClass2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/createClass */ 18));
  26. var _toConsumableArray2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/toConsumableArray */ 19));
  27. var _typeof2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/typeof */ 12));
  28. var _uniI18n = __webpack_require__(/*! @dcloudio/uni-i18n */ 23);
  29. var _vue = _interopRequireDefault(__webpack_require__(/*! vue */ 24));
  30. function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
  31. function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { (0, _defineProperty2.default)(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
  32. var realAtob;
  33. var b64 = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=';
  34. var b64re = /^(?:[A-Za-z\d+/]{4})*?(?:[A-Za-z\d+/]{2}(?:==)?|[A-Za-z\d+/]{3}=?)?$/;
  35. if (typeof atob !== 'function') {
  36. realAtob = function realAtob(str) {
  37. str = String(str).replace(/[\t\n\f\r ]+/g, '');
  38. if (!b64re.test(str)) {
  39. throw new Error("Failed to execute 'atob' on 'Window': The string to be decoded is not correctly encoded.");
  40. }
  41. // Adding the padding if missing, for semplicity
  42. str += '=='.slice(2 - (str.length & 3));
  43. var bitmap;
  44. var result = '';
  45. var r1;
  46. var r2;
  47. var i = 0;
  48. for (; i < str.length;) {
  49. bitmap = b64.indexOf(str.charAt(i++)) << 18 | b64.indexOf(str.charAt(i++)) << 12 | (r1 = b64.indexOf(str.charAt(i++))) << 6 | (r2 = b64.indexOf(str.charAt(i++)));
  50. result += r1 === 64 ? String.fromCharCode(bitmap >> 16 & 255) : r2 === 64 ? String.fromCharCode(bitmap >> 16 & 255, bitmap >> 8 & 255) : String.fromCharCode(bitmap >> 16 & 255, bitmap >> 8 & 255, bitmap & 255);
  51. }
  52. return result;
  53. };
  54. } else {
  55. // 注意atob只能在全局对象上调用,例如:`const Base64 = {atob};Base64.atob('xxxx')`是错误的用法
  56. realAtob = atob;
  57. }
  58. function b64DecodeUnicode(str) {
  59. return decodeURIComponent(realAtob(str).split('').map(function (c) {
  60. return '%' + ('00' + c.charCodeAt(0).toString(16)).slice(-2);
  61. }).join(''));
  62. }
  63. function getCurrentUserInfo() {
  64. var token = tt.getStorageSync('uni_id_token') || '';
  65. var tokenArr = token.split('.');
  66. if (!token || tokenArr.length !== 3) {
  67. return {
  68. uid: null,
  69. role: [],
  70. permission: [],
  71. tokenExpired: 0
  72. };
  73. }
  74. var userInfo;
  75. try {
  76. userInfo = JSON.parse(b64DecodeUnicode(tokenArr[1]));
  77. } catch (error) {
  78. throw new Error('获取当前用户信息出错,详细错误信息为:' + error.message);
  79. }
  80. userInfo.tokenExpired = userInfo.exp * 1000;
  81. delete userInfo.exp;
  82. delete userInfo.iat;
  83. return userInfo;
  84. }
  85. function uniIdMixin(Vue) {
  86. Vue.prototype.uniIDHasRole = function (roleId) {
  87. var _getCurrentUserInfo = getCurrentUserInfo(),
  88. role = _getCurrentUserInfo.role;
  89. return role.indexOf(roleId) > -1;
  90. };
  91. Vue.prototype.uniIDHasPermission = function (permissionId) {
  92. var _getCurrentUserInfo2 = getCurrentUserInfo(),
  93. permission = _getCurrentUserInfo2.permission;
  94. return this.uniIDHasRole('admin') || permission.indexOf(permissionId) > -1;
  95. };
  96. Vue.prototype.uniIDTokenValid = function () {
  97. var _getCurrentUserInfo3 = getCurrentUserInfo(),
  98. tokenExpired = _getCurrentUserInfo3.tokenExpired;
  99. return tokenExpired > Date.now();
  100. };
  101. }
  102. var _toString = Object.prototype.toString;
  103. var hasOwnProperty = Object.prototype.hasOwnProperty;
  104. function isFn(fn) {
  105. return typeof fn === 'function';
  106. }
  107. function isStr(str) {
  108. return typeof str === 'string';
  109. }
  110. function isObject(obj) {
  111. return obj !== null && (0, _typeof2.default)(obj) === 'object';
  112. }
  113. function isPlainObject(obj) {
  114. return _toString.call(obj) === '[object Object]';
  115. }
  116. function hasOwn(obj, key) {
  117. return hasOwnProperty.call(obj, key);
  118. }
  119. function noop() {}
  120. /**
  121. * Create a cached version of a pure function.
  122. */
  123. function cached(fn) {
  124. var cache = Object.create(null);
  125. return function cachedFn(str) {
  126. var hit = cache[str];
  127. return hit || (cache[str] = fn(str));
  128. };
  129. }
  130. /**
  131. * Camelize a hyphen-delimited string.
  132. */
  133. var camelizeRE = /-(\w)/g;
  134. var camelize = cached(function (str) {
  135. return str.replace(camelizeRE, function (_, c) {
  136. return c ? c.toUpperCase() : '';
  137. });
  138. });
  139. var HOOKS = ['invoke', 'success', 'fail', 'complete', 'returnValue'];
  140. var globalInterceptors = {};
  141. var scopedInterceptors = {};
  142. function mergeHook(parentVal, childVal) {
  143. var res = childVal ? parentVal ? parentVal.concat(childVal) : Array.isArray(childVal) ? childVal : [childVal] : parentVal;
  144. return res ? dedupeHooks(res) : res;
  145. }
  146. function dedupeHooks(hooks) {
  147. var res = [];
  148. for (var i = 0; i < hooks.length; i++) {
  149. if (res.indexOf(hooks[i]) === -1) {
  150. res.push(hooks[i]);
  151. }
  152. }
  153. return res;
  154. }
  155. function removeHook(hooks, hook) {
  156. var index = hooks.indexOf(hook);
  157. if (index !== -1) {
  158. hooks.splice(index, 1);
  159. }
  160. }
  161. function mergeInterceptorHook(interceptor, option) {
  162. Object.keys(option).forEach(function (hook) {
  163. if (HOOKS.indexOf(hook) !== -1 && isFn(option[hook])) {
  164. interceptor[hook] = mergeHook(interceptor[hook], option[hook]);
  165. }
  166. });
  167. }
  168. function removeInterceptorHook(interceptor, option) {
  169. if (!interceptor || !option) {
  170. return;
  171. }
  172. Object.keys(option).forEach(function (hook) {
  173. if (HOOKS.indexOf(hook) !== -1 && isFn(option[hook])) {
  174. removeHook(interceptor[hook], option[hook]);
  175. }
  176. });
  177. }
  178. function addInterceptor(method, option) {
  179. if (typeof method === 'string' && isPlainObject(option)) {
  180. mergeInterceptorHook(scopedInterceptors[method] || (scopedInterceptors[method] = {}), option);
  181. } else if (isPlainObject(method)) {
  182. mergeInterceptorHook(globalInterceptors, method);
  183. }
  184. }
  185. function removeInterceptor(method, option) {
  186. if (typeof method === 'string') {
  187. if (isPlainObject(option)) {
  188. removeInterceptorHook(scopedInterceptors[method], option);
  189. } else {
  190. delete scopedInterceptors[method];
  191. }
  192. } else if (isPlainObject(method)) {
  193. removeInterceptorHook(globalInterceptors, method);
  194. }
  195. }
  196. function wrapperHook(hook, params) {
  197. return function (data) {
  198. return hook(data, params) || data;
  199. };
  200. }
  201. function isPromise(obj) {
  202. return !!obj && ((0, _typeof2.default)(obj) === 'object' || typeof obj === 'function') && typeof obj.then === 'function';
  203. }
  204. function queue(hooks, data, params) {
  205. var promise = false;
  206. for (var i = 0; i < hooks.length; i++) {
  207. var hook = hooks[i];
  208. if (promise) {
  209. promise = Promise.resolve(wrapperHook(hook, params));
  210. } else {
  211. var res = hook(data, params);
  212. if (isPromise(res)) {
  213. promise = Promise.resolve(res);
  214. }
  215. if (res === false) {
  216. return {
  217. then: function then() {}
  218. };
  219. }
  220. }
  221. }
  222. return promise || {
  223. then: function then(callback) {
  224. return callback(data);
  225. }
  226. };
  227. }
  228. function wrapperOptions(interceptor) {
  229. var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
  230. ['success', 'fail', 'complete'].forEach(function (name) {
  231. if (Array.isArray(interceptor[name])) {
  232. var oldCallback = options[name];
  233. options[name] = function callbackInterceptor(res) {
  234. queue(interceptor[name], res, options).then(function (res) {
  235. /* eslint-disable no-mixed-operators */
  236. return isFn(oldCallback) && oldCallback(res) || res;
  237. });
  238. };
  239. }
  240. });
  241. return options;
  242. }
  243. function wrapperReturnValue(method, returnValue) {
  244. var returnValueHooks = [];
  245. if (Array.isArray(globalInterceptors.returnValue)) {
  246. returnValueHooks.push.apply(returnValueHooks, (0, _toConsumableArray2.default)(globalInterceptors.returnValue));
  247. }
  248. var interceptor = scopedInterceptors[method];
  249. if (interceptor && Array.isArray(interceptor.returnValue)) {
  250. returnValueHooks.push.apply(returnValueHooks, (0, _toConsumableArray2.default)(interceptor.returnValue));
  251. }
  252. returnValueHooks.forEach(function (hook) {
  253. returnValue = hook(returnValue) || returnValue;
  254. });
  255. return returnValue;
  256. }
  257. function getApiInterceptorHooks(method) {
  258. var interceptor = Object.create(null);
  259. Object.keys(globalInterceptors).forEach(function (hook) {
  260. if (hook !== 'returnValue') {
  261. interceptor[hook] = globalInterceptors[hook].slice();
  262. }
  263. });
  264. var scopedInterceptor = scopedInterceptors[method];
  265. if (scopedInterceptor) {
  266. Object.keys(scopedInterceptor).forEach(function (hook) {
  267. if (hook !== 'returnValue') {
  268. interceptor[hook] = (interceptor[hook] || []).concat(scopedInterceptor[hook]);
  269. }
  270. });
  271. }
  272. return interceptor;
  273. }
  274. function invokeApi(method, api, options) {
  275. for (var _len = arguments.length, params = new Array(_len > 3 ? _len - 3 : 0), _key = 3; _key < _len; _key++) {
  276. params[_key - 3] = arguments[_key];
  277. }
  278. var interceptor = getApiInterceptorHooks(method);
  279. if (interceptor && Object.keys(interceptor).length) {
  280. if (Array.isArray(interceptor.invoke)) {
  281. var res = queue(interceptor.invoke, options);
  282. return res.then(function (options) {
  283. // 重新访问 getApiInterceptorHooks, 允许 invoke 中再次调用 addInterceptor,removeInterceptor
  284. return api.apply(void 0, [wrapperOptions(getApiInterceptorHooks(method), options)].concat(params));
  285. });
  286. } else {
  287. return api.apply(void 0, [wrapperOptions(interceptor, options)].concat(params));
  288. }
  289. }
  290. return api.apply(void 0, [options].concat(params));
  291. }
  292. var promiseInterceptor = {
  293. returnValue: function returnValue(res) {
  294. if (!isPromise(res)) {
  295. return res;
  296. }
  297. return new Promise(function (resolve, reject) {
  298. res.then(function (res) {
  299. if (!res) {
  300. resolve(res);
  301. return;
  302. }
  303. if (res[0]) {
  304. reject(res[0]);
  305. } else {
  306. resolve(res[1]);
  307. }
  308. });
  309. });
  310. }
  311. };
  312. var SYNC_API_RE = /^\$|__f__|Window$|WindowStyle$|sendHostEvent|sendNativeEvent|restoreGlobal|requireGlobal|getCurrentSubNVue|getMenuButtonBoundingClientRect|^report|interceptors|Interceptor$|getSubNVueById|requireNativePlugin|rpx2px|upx2px|hideKeyboard|canIUse|^create|Sync$|Manager$|base64ToArrayBuffer|arrayBufferToBase64|getLocale|setLocale|invokePushCallback|getWindowInfo|getDeviceInfo|getAppBaseInfo|getSystemSetting|getAppAuthorizeSetting|initUTS|requireUTS|registerUTS|getFacialRecognitionMetaInfo/;
  313. var CONTEXT_API_RE = /^create|Manager$/;
  314. // Context例外情况
  315. var CONTEXT_API_RE_EXC = ['createBLEConnection'];
  316. // 同步例外情况
  317. var ASYNC_API = ['createBLEConnection', 'createPushMessage'];
  318. var CALLBACK_API_RE = /^on|^off/;
  319. function isContextApi(name) {
  320. return CONTEXT_API_RE.test(name) && CONTEXT_API_RE_EXC.indexOf(name) === -1;
  321. }
  322. function isSyncApi(name) {
  323. return SYNC_API_RE.test(name) && ASYNC_API.indexOf(name) === -1;
  324. }
  325. function isCallbackApi(name) {
  326. return CALLBACK_API_RE.test(name) && name !== 'onPush';
  327. }
  328. function handlePromise(promise) {
  329. return promise.then(function (data) {
  330. return [null, data];
  331. }).catch(function (err) {
  332. return [err];
  333. });
  334. }
  335. function shouldPromise(name) {
  336. if (isContextApi(name) || isSyncApi(name) || isCallbackApi(name)) {
  337. return false;
  338. }
  339. return true;
  340. }
  341. /* eslint-disable no-extend-native */
  342. if (!Promise.prototype.finally) {
  343. Promise.prototype.finally = function (callback) {
  344. var promise = this.constructor;
  345. return this.then(function (value) {
  346. return promise.resolve(callback()).then(function () {
  347. return value;
  348. });
  349. }, function (reason) {
  350. return promise.resolve(callback()).then(function () {
  351. throw reason;
  352. });
  353. });
  354. };
  355. }
  356. function promisify(name, api) {
  357. if (!shouldPromise(name) || !isFn(api)) {
  358. return api;
  359. }
  360. return function promiseApi() {
  361. var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
  362. for (var _len2 = arguments.length, params = new Array(_len2 > 1 ? _len2 - 1 : 0), _key2 = 1; _key2 < _len2; _key2++) {
  363. params[_key2 - 1] = arguments[_key2];
  364. }
  365. if (isFn(options.success) || isFn(options.fail) || isFn(options.complete)) {
  366. return wrapperReturnValue(name, invokeApi.apply(void 0, [name, api, Object.assign({}, options)].concat(params)));
  367. }
  368. return wrapperReturnValue(name, handlePromise(new Promise(function (resolve, reject) {
  369. invokeApi.apply(void 0, [name, api, Object.assign({}, options, {
  370. success: resolve,
  371. fail: reject
  372. })].concat(params));
  373. })));
  374. };
  375. }
  376. var EPS = 1e-4;
  377. var BASE_DEVICE_WIDTH = 750;
  378. var isIOS = false;
  379. var deviceWidth = 0;
  380. var deviceDPR = 0;
  381. function checkDeviceWidth() {
  382. var windowWidth, pixelRatio, platform;
  383. {
  384. var baseInfo = tt.getSystemInfoSync();
  385. windowWidth = baseInfo.windowWidth;
  386. pixelRatio = baseInfo.pixelRatio;
  387. platform = baseInfo.platform;
  388. }
  389. deviceWidth = windowWidth;
  390. deviceDPR = pixelRatio;
  391. isIOS = platform === 'ios';
  392. }
  393. function upx2px(number, newDeviceWidth) {
  394. if (deviceWidth === 0) {
  395. checkDeviceWidth();
  396. }
  397. number = Number(number);
  398. if (number === 0) {
  399. return 0;
  400. }
  401. var result = number / BASE_DEVICE_WIDTH * (newDeviceWidth || deviceWidth);
  402. if (result < 0) {
  403. result = -result;
  404. }
  405. result = Math.floor(result + EPS);
  406. if (result === 0) {
  407. if (deviceDPR === 1 || !isIOS) {
  408. result = 1;
  409. } else {
  410. result = 0.5;
  411. }
  412. }
  413. return number < 0 ? -result : result;
  414. }
  415. var LOCALE_ZH_HANS = 'zh-Hans';
  416. var LOCALE_ZH_HANT = 'zh-Hant';
  417. var LOCALE_EN = 'en';
  418. var LOCALE_FR = 'fr';
  419. var LOCALE_ES = 'es';
  420. var messages = {};
  421. function getLocaleLanguage() {
  422. var localeLanguage = '';
  423. {
  424. localeLanguage = normalizeLocale(tt.getSystemInfoSync().language) || LOCALE_EN;
  425. }
  426. return localeLanguage;
  427. }
  428. var locale;
  429. {
  430. locale = getLocaleLanguage();
  431. }
  432. function initI18nMessages() {
  433. if (!isEnableLocale()) {
  434. return;
  435. }
  436. var localeKeys = Object.keys(__uniConfig.locales);
  437. if (localeKeys.length) {
  438. localeKeys.forEach(function (locale) {
  439. var curMessages = messages[locale];
  440. var userMessages = __uniConfig.locales[locale];
  441. if (curMessages) {
  442. Object.assign(curMessages, userMessages);
  443. } else {
  444. messages[locale] = userMessages;
  445. }
  446. });
  447. }
  448. }
  449. initI18nMessages();
  450. var i18n = (0, _uniI18n.initVueI18n)(locale, {});
  451. var t = i18n.t;
  452. var i18nMixin = i18n.mixin = {
  453. beforeCreate: function beforeCreate() {
  454. var _this = this;
  455. var unwatch = i18n.i18n.watchLocale(function () {
  456. _this.$forceUpdate();
  457. });
  458. this.$once('hook:beforeDestroy', function () {
  459. unwatch();
  460. });
  461. },
  462. methods: {
  463. $$t: function $$t(key, values) {
  464. return t(key, values);
  465. }
  466. }
  467. };
  468. var setLocale = i18n.setLocale;
  469. var getLocale = i18n.getLocale;
  470. function initAppLocale(Vue, appVm, locale) {
  471. var state = Vue.observable({
  472. locale: locale || i18n.getLocale()
  473. });
  474. var localeWatchers = [];
  475. appVm.$watchLocale = function (fn) {
  476. localeWatchers.push(fn);
  477. };
  478. Object.defineProperty(appVm, '$locale', {
  479. get: function get() {
  480. return state.locale;
  481. },
  482. set: function set(v) {
  483. state.locale = v;
  484. localeWatchers.forEach(function (watch) {
  485. return watch(v);
  486. });
  487. }
  488. });
  489. }
  490. function isEnableLocale() {
  491. return typeof __uniConfig !== 'undefined' && __uniConfig.locales && !!Object.keys(__uniConfig.locales).length;
  492. }
  493. function include(str, parts) {
  494. return !!parts.find(function (part) {
  495. return str.indexOf(part) !== -1;
  496. });
  497. }
  498. function startsWith(str, parts) {
  499. return parts.find(function (part) {
  500. return str.indexOf(part) === 0;
  501. });
  502. }
  503. function normalizeLocale(locale, messages) {
  504. if (!locale) {
  505. return;
  506. }
  507. locale = locale.trim().replace(/_/g, '-');
  508. if (messages && messages[locale]) {
  509. return locale;
  510. }
  511. locale = locale.toLowerCase();
  512. if (locale === 'chinese') {
  513. // 支付宝
  514. return LOCALE_ZH_HANS;
  515. }
  516. if (locale.indexOf('zh') === 0) {
  517. if (locale.indexOf('-hans') > -1) {
  518. return LOCALE_ZH_HANS;
  519. }
  520. if (locale.indexOf('-hant') > -1) {
  521. return LOCALE_ZH_HANT;
  522. }
  523. if (include(locale, ['-tw', '-hk', '-mo', '-cht'])) {
  524. return LOCALE_ZH_HANT;
  525. }
  526. return LOCALE_ZH_HANS;
  527. }
  528. var lang = startsWith(locale, [LOCALE_EN, LOCALE_FR, LOCALE_ES]);
  529. if (lang) {
  530. return lang;
  531. }
  532. }
  533. // export function initI18n() {
  534. // const localeKeys = Object.keys(__uniConfig.locales || {})
  535. // if (localeKeys.length) {
  536. // localeKeys.forEach((locale) =>
  537. // i18n.add(locale, __uniConfig.locales[locale])
  538. // )
  539. // }
  540. // }
  541. function getLocale$1() {
  542. // 优先使用 $locale
  543. if (isFn(getApp)) {
  544. var app = getApp({
  545. allowDefault: true
  546. });
  547. if (app && app.$vm) {
  548. return app.$vm.$locale;
  549. }
  550. }
  551. return getLocaleLanguage();
  552. }
  553. function setLocale$1(locale) {
  554. var app = isFn(getApp) ? getApp() : false;
  555. if (!app) {
  556. return false;
  557. }
  558. var oldLocale = app.$vm.$locale;
  559. if (oldLocale !== locale) {
  560. app.$vm.$locale = locale;
  561. onLocaleChangeCallbacks.forEach(function (fn) {
  562. return fn({
  563. locale: locale
  564. });
  565. });
  566. return true;
  567. }
  568. return false;
  569. }
  570. var onLocaleChangeCallbacks = [];
  571. function onLocaleChange(fn) {
  572. if (onLocaleChangeCallbacks.indexOf(fn) === -1) {
  573. onLocaleChangeCallbacks.push(fn);
  574. }
  575. }
  576. if (typeof global !== 'undefined') {
  577. global.getLocale = getLocale$1;
  578. }
  579. var interceptors = {
  580. promiseInterceptor: promiseInterceptor
  581. };
  582. var baseApi = /*#__PURE__*/Object.freeze({
  583. __proto__: null,
  584. upx2px: upx2px,
  585. rpx2px: upx2px,
  586. getLocale: getLocale$1,
  587. setLocale: setLocale$1,
  588. onLocaleChange: onLocaleChange,
  589. addInterceptor: addInterceptor,
  590. removeInterceptor: removeInterceptor,
  591. interceptors: interceptors
  592. });
  593. var EventChannel = /*#__PURE__*/function () {
  594. function EventChannel(id, events) {
  595. var _this2 = this;
  596. (0, _classCallCheck2.default)(this, EventChannel);
  597. this.id = id;
  598. this.listener = {};
  599. this.emitCache = {};
  600. if (events) {
  601. Object.keys(events).forEach(function (name) {
  602. _this2.on(name, events[name]);
  603. });
  604. }
  605. }
  606. (0, _createClass2.default)(EventChannel, [{
  607. key: "emit",
  608. value: function emit(eventName) {
  609. for (var _len3 = arguments.length, args = new Array(_len3 > 1 ? _len3 - 1 : 0), _key3 = 1; _key3 < _len3; _key3++) {
  610. args[_key3 - 1] = arguments[_key3];
  611. }
  612. var fns = this.listener[eventName];
  613. if (!fns) {
  614. return (this.emitCache[eventName] || (this.emitCache[eventName] = [])).push(args);
  615. }
  616. fns.forEach(function (opt) {
  617. opt.fn.apply(opt.fn, args);
  618. });
  619. this.listener[eventName] = fns.filter(function (opt) {
  620. return opt.type !== 'once';
  621. });
  622. }
  623. }, {
  624. key: "on",
  625. value: function on(eventName, fn) {
  626. this._addListener(eventName, 'on', fn);
  627. this._clearCache(eventName);
  628. }
  629. }, {
  630. key: "once",
  631. value: function once(eventName, fn) {
  632. this._addListener(eventName, 'once', fn);
  633. this._clearCache(eventName);
  634. }
  635. }, {
  636. key: "off",
  637. value: function off(eventName, fn) {
  638. var fns = this.listener[eventName];
  639. if (!fns) {
  640. return;
  641. }
  642. if (fn) {
  643. for (var i = 0; i < fns.length;) {
  644. if (fns[i].fn === fn) {
  645. fns.splice(i, 1);
  646. i--;
  647. }
  648. i++;
  649. }
  650. } else {
  651. delete this.listener[eventName];
  652. }
  653. }
  654. }, {
  655. key: "_clearCache",
  656. value: function _clearCache(eventName) {
  657. var cacheArgs = this.emitCache[eventName];
  658. if (cacheArgs) {
  659. for (; cacheArgs.length > 0;) {
  660. this.emit.apply(this, [eventName].concat(cacheArgs.shift()));
  661. }
  662. }
  663. }
  664. }, {
  665. key: "_addListener",
  666. value: function _addListener(eventName, type, fn) {
  667. (this.listener[eventName] || (this.listener[eventName] = [])).push({
  668. fn: fn,
  669. type: type
  670. });
  671. }
  672. }]);
  673. return EventChannel;
  674. }();
  675. var eventChannels = {};
  676. var id = 0;
  677. function initEventChannel(events) {
  678. var cache = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
  679. id++;
  680. var eventChannel = new EventChannel(id, events);
  681. if (cache) {
  682. eventChannels[id] = eventChannel;
  683. }
  684. return eventChannel;
  685. }
  686. function getEventChannel(id) {
  687. var eventChannel = eventChannels[id];
  688. delete eventChannels[id];
  689. return eventChannel;
  690. }
  691. function navigateTo() {
  692. var eventChannel;
  693. return {
  694. args: function args(fromArgs, toArgs) {
  695. eventChannel = initEventChannel(fromArgs.events);
  696. if (fromArgs.url) {
  697. fromArgs.url = fromArgs.url + (fromArgs.url.indexOf('?') === -1 ? '?' : '&') + '__id__=' + eventChannel.id;
  698. }
  699. },
  700. returnValue: function returnValue(fromRes, toRes) {
  701. fromRes.eventChannel = eventChannel;
  702. }
  703. };
  704. }
  705. function findExistsPageIndex(url) {
  706. var pages = getCurrentPages();
  707. var len = pages.length;
  708. while (len--) {
  709. var page = pages[len];
  710. if (page.$page && page.$page.fullPath === url) {
  711. return len;
  712. }
  713. }
  714. return -1;
  715. }
  716. var redirectTo = {
  717. name: function name(fromArgs) {
  718. if (fromArgs.exists === 'back' && fromArgs.delta) {
  719. return 'navigateBack';
  720. }
  721. return 'redirectTo';
  722. },
  723. args: function args(fromArgs) {
  724. if (fromArgs.exists === 'back' && fromArgs.url) {
  725. var existsPageIndex = findExistsPageIndex(fromArgs.url);
  726. if (existsPageIndex !== -1) {
  727. var delta = getCurrentPages().length - 1 - existsPageIndex;
  728. if (delta > 0) {
  729. fromArgs.delta = delta;
  730. }
  731. }
  732. }
  733. }
  734. };
  735. var previewImage = {
  736. args: function args(fromArgs) {
  737. var currentIndex = parseInt(fromArgs.current);
  738. if (isNaN(currentIndex)) {
  739. return;
  740. }
  741. var urls = fromArgs.urls;
  742. if (!Array.isArray(urls)) {
  743. return;
  744. }
  745. var len = urls.length;
  746. if (!len) {
  747. return;
  748. }
  749. if (currentIndex < 0) {
  750. currentIndex = 0;
  751. } else if (currentIndex >= len) {
  752. currentIndex = len - 1;
  753. }
  754. if (currentIndex > 0) {
  755. fromArgs.current = urls[currentIndex];
  756. fromArgs.urls = urls.filter(function (item, index) {
  757. return index < currentIndex ? item !== urls[currentIndex] : true;
  758. });
  759. } else {
  760. fromArgs.current = urls[0];
  761. }
  762. return {
  763. indicator: false,
  764. loop: false
  765. };
  766. }
  767. };
  768. var UUID_KEY = '__DC_STAT_UUID';
  769. var deviceId;
  770. function useDeviceId(result) {
  771. deviceId = deviceId || tt.getStorageSync(UUID_KEY);
  772. if (!deviceId) {
  773. deviceId = Date.now() + '' + Math.floor(Math.random() * 1e7);
  774. tt.setStorage({
  775. key: UUID_KEY,
  776. data: deviceId
  777. });
  778. }
  779. result.deviceId = deviceId;
  780. }
  781. function addSafeAreaInsets(result) {
  782. if (result.safeArea) {
  783. var safeArea = result.safeArea;
  784. result.safeAreaInsets = {
  785. top: safeArea.top,
  786. left: safeArea.left,
  787. right: result.windowWidth - safeArea.right,
  788. bottom: result.screenHeight - safeArea.bottom
  789. };
  790. }
  791. }
  792. function getOSInfo(system, platform) {
  793. var osName = '';
  794. var osVersion = '';
  795. if (platform && "mp-toutiao" === 'mp-baidu') {
  796. osName = platform;
  797. osVersion = system;
  798. } else {
  799. osName = system.split(' ')[0] || platform;
  800. osVersion = system.split(' ')[1] || '';
  801. }
  802. osName = osName.toLocaleLowerCase();
  803. switch (osName) {
  804. case 'harmony': // alipay
  805. case 'ohos': // weixin
  806. case 'openharmony':
  807. // feishu
  808. osName = 'harmonyos';
  809. break;
  810. case 'iphone os':
  811. // alipay
  812. osName = 'ios';
  813. break;
  814. case 'mac': // weixin qq
  815. case 'darwin':
  816. // feishu
  817. osName = 'macos';
  818. break;
  819. case 'windows_nt':
  820. // feishu
  821. osName = 'windows';
  822. break;
  823. }
  824. return {
  825. osName: osName,
  826. osVersion: osVersion
  827. };
  828. }
  829. function populateParameters(result) {
  830. var _result$brand = result.brand,
  831. brand = _result$brand === void 0 ? '' : _result$brand,
  832. _result$model = result.model,
  833. model = _result$model === void 0 ? '' : _result$model,
  834. _result$system = result.system,
  835. system = _result$system === void 0 ? '' : _result$system,
  836. _result$language = result.language,
  837. language = _result$language === void 0 ? '' : _result$language,
  838. theme = result.theme,
  839. version = result.version,
  840. platform = result.platform,
  841. fontSizeSetting = result.fontSizeSetting,
  842. SDKVersion = result.SDKVersion,
  843. pixelRatio = result.pixelRatio,
  844. deviceOrientation = result.deviceOrientation;
  845. // const isQuickApp = "mp-toutiao".indexOf('quickapp-webview') !== -1
  846. var extraParam = {};
  847. // osName osVersion
  848. var _getOSInfo = getOSInfo(system, platform),
  849. osName = _getOSInfo.osName,
  850. osVersion = _getOSInfo.osVersion;
  851. var hostVersion = version;
  852. // deviceType
  853. var deviceType = getGetDeviceType(result, model);
  854. // deviceModel
  855. var deviceBrand = getDeviceBrand(brand);
  856. // hostName
  857. var _hostName = getHostName(result);
  858. // deviceOrientation
  859. var _deviceOrientation = deviceOrientation; // 仅 微信 百度 支持
  860. // devicePixelRatio
  861. var _devicePixelRatio = pixelRatio;
  862. // SDKVersion
  863. var _SDKVersion = SDKVersion;
  864. // hostLanguage
  865. var hostLanguage = (language || '').replace(/_/g, '-');
  866. // wx.getAccountInfoSync
  867. var parameters = {
  868. appId: "__UNI__9C28A0C",
  869. appName: "核销工具DY",
  870. appVersion: "1.0.0",
  871. appVersionCode: "100",
  872. appLanguage: getAppLanguage(hostLanguage),
  873. uniCompileVersion: "4.85",
  874. uniCompilerVersion: "4.85",
  875. uniRuntimeVersion: "4.85",
  876. uniPlatform: undefined || "mp-toutiao",
  877. deviceBrand: deviceBrand,
  878. deviceModel: model,
  879. deviceType: deviceType,
  880. devicePixelRatio: _devicePixelRatio,
  881. deviceOrientation: _deviceOrientation,
  882. osName: osName.toLocaleLowerCase(),
  883. osVersion: osVersion,
  884. hostTheme: theme,
  885. hostVersion: hostVersion,
  886. hostLanguage: hostLanguage,
  887. hostName: _hostName,
  888. hostSDKVersion: _SDKVersion,
  889. hostFontSizeSetting: fontSizeSetting,
  890. windowTop: 0,
  891. windowBottom: 0,
  892. // TODO
  893. osLanguage: undefined,
  894. osTheme: undefined,
  895. ua: undefined,
  896. hostPackageName: undefined,
  897. browserName: undefined,
  898. browserVersion: undefined,
  899. isUniAppX: false
  900. };
  901. Object.assign(result, parameters, extraParam);
  902. }
  903. function getGetDeviceType(result, model) {
  904. var deviceType = result.deviceType || 'phone';
  905. {
  906. var deviceTypeMaps = {
  907. ipad: 'pad',
  908. windows: 'pc',
  909. mac: 'pc'
  910. };
  911. var deviceTypeMapsKeys = Object.keys(deviceTypeMaps);
  912. var _model = model.toLocaleLowerCase();
  913. for (var index = 0; index < deviceTypeMapsKeys.length; index++) {
  914. var _m = deviceTypeMapsKeys[index];
  915. if (_model.indexOf(_m) !== -1) {
  916. deviceType = deviceTypeMaps[_m];
  917. break;
  918. }
  919. }
  920. }
  921. return deviceType;
  922. }
  923. function getDeviceBrand(brand) {
  924. var deviceBrand = brand;
  925. if (deviceBrand) {
  926. deviceBrand = brand.toLocaleLowerCase();
  927. }
  928. return deviceBrand;
  929. }
  930. function getAppLanguage(defaultLanguage) {
  931. return getLocale$1 ? getLocale$1() : defaultLanguage;
  932. }
  933. function getHostName(result) {
  934. var _platform = "mp-toutiao".split('-')[1];
  935. var _hostName = result.hostName || _platform; // mp-jd
  936. {
  937. _hostName = result.appName;
  938. }
  939. return _hostName;
  940. }
  941. var getSystemInfo = {
  942. returnValue: function returnValue(result) {
  943. useDeviceId(result);
  944. addSafeAreaInsets(result);
  945. populateParameters(result);
  946. }
  947. };
  948. var oName = 'getUserInfo';
  949. var nName = 'getUserProfile';
  950. var getUserProfile = {
  951. name: tt.canIUse(nName) ? nName : oName
  952. };
  953. // 不支持的 API 列表
  954. var todos = ['preloadPage', 'unPreloadPage', 'loadSubPackage'
  955. // 'createCameraContext',
  956. // 'createLivePlayerContext',
  957. // 'getSavedFileInfo',
  958. // 'createMapContext',
  959. // 'onMemoryWarning',
  960. // 'onGyroscopeChange',
  961. // 'startGyroscope',
  962. // 'stopGyroscope',
  963. // 'setScreenBrightness',
  964. // 'getScreenBrightness',
  965. // 'addPhoneContact',
  966. // 'openBluetoothAdapter',
  967. // 'startBluetoothDevicesDiscovery',
  968. // 'onBluetoothDeviceFound',
  969. // 'stopBluetoothDevicesDiscovery',
  970. // 'onBluetoothAdapterStateChange',
  971. // 'getConnectedBluetoothDevices',
  972. // 'getBluetoothDevices',
  973. // 'getBluetoothAdapterState',
  974. // 'closeBluetoothAdapter',
  975. // 'writeBLECharacteristicValue',
  976. // 'readBLECharacteristicValue',
  977. // 'onBLEConnectionStateChange',
  978. // 'onBLECharacteristicValueChange',
  979. // 'notifyBLECharacteristicValueChange',
  980. // 'getBLEDeviceServices',
  981. // 'getBLEDeviceCharacteristics',
  982. // 'createBLEConnection',
  983. // 'closeBLEConnection',
  984. // 'onBeaconServiceChange',
  985. // 'onBeaconUpdate',
  986. // 'getBeacons',
  987. // 'startBeaconDiscovery',
  988. // 'stopBeaconDiscovery',
  989. // 'showNavigationBarLoading',
  990. // 'hideNavigationBarLoading',
  991. // 'setTabBarItem',
  992. // 'setTabBarStyle',
  993. // 'hideTabBar',
  994. // 'showTabBar',
  995. // 'setTabBarBadge',
  996. // 'removeTabBarBadge',
  997. // 'showTabBarRedDot',
  998. // 'hideTabBarRedDot',
  999. // 'setBackgroundColor',
  1000. // 'setBackgroundTextStyle',
  1001. // 'chooseInvoiceTitle',
  1002. // 'addTemplate',
  1003. // 'deleteTemplate',
  1004. // 'getTemplateLibraryById',
  1005. // 'getTemplateLibraryList',
  1006. // 'getTemplateList',
  1007. // 'sendTemplateMessage',
  1008. // 'setEnableDebug',
  1009. // 'onWindowResize',
  1010. // 'offWindowResize',
  1011. // 'createOffscreenCanvas',
  1012. // 'vibrate'
  1013. ];
  1014. // 存在兼容性的 API 列表
  1015. // 头条小程序自1.35.0+支持canIUses
  1016. var canIUses = [
  1017. // 'createIntersectionObserver',
  1018. // 'getSavedFileList',
  1019. // 'removeSavedFile',
  1020. // 'hideKeyboard',
  1021. // 'getImageInfo',
  1022. // 'createVideoContext',
  1023. // 'onSocketOpen',
  1024. // 'onSocketError',
  1025. // 'sendSocketMessage',
  1026. // 'onSocketMessage',
  1027. // 'closeSocket',
  1028. // 'onSocketClose',
  1029. // 'getExtConfig',
  1030. // 'getExtConfigSync',
  1031. // 'navigateToMiniProgram',
  1032. // 'navigateBackMiniProgram',
  1033. // 'compressImage',
  1034. // 'chooseLocation',
  1035. // 'openDocument',
  1036. // 'onUserCaptureScreen',
  1037. // 'getBackgroundAudioManager',
  1038. // 'setNavigationBarColor',
  1039. ];
  1040. // 需要做转换的 API 列表
  1041. var protocols = {
  1042. navigateTo: navigateTo(),
  1043. redirectTo: redirectTo,
  1044. previewImage: previewImage,
  1045. getSystemInfo: getSystemInfo,
  1046. getSystemInfoSync: getSystemInfo,
  1047. getUserProfile: getUserProfile,
  1048. connectSocket: {
  1049. args: {
  1050. method: false
  1051. }
  1052. },
  1053. scanCode: {
  1054. args: {
  1055. onlyFromCamera: false,
  1056. scanType: false
  1057. }
  1058. },
  1059. startAccelerometer: {
  1060. args: {
  1061. interval: false
  1062. }
  1063. },
  1064. login: {
  1065. args: {
  1066. scopes: false,
  1067. timeout: false
  1068. }
  1069. },
  1070. getUserInfo: {
  1071. args: {
  1072. lang: false,
  1073. timeout: false
  1074. }
  1075. },
  1076. requestPayment: {
  1077. name: tt.pay ? 'pay' : 'requestPayment',
  1078. args: {
  1079. orderInfo: tt.pay ? 'orderInfo' : 'data'
  1080. }
  1081. }
  1082. };
  1083. var CALLBACKS = ['success', 'fail', 'cancel', 'complete'];
  1084. function processCallback(methodName, method, returnValue) {
  1085. return function (res) {
  1086. return method(processReturnValue(methodName, res, returnValue));
  1087. };
  1088. }
  1089. function processArgs(methodName, fromArgs) {
  1090. var argsOption = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
  1091. var returnValue = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : {};
  1092. var keepFromArgs = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : false;
  1093. if (isPlainObject(fromArgs)) {
  1094. // 一般 api 的参数解析
  1095. var toArgs = keepFromArgs === true ? fromArgs : {}; // returnValue 为 false 时,说明是格式化返回值,直接在返回值对象上修改赋值
  1096. if (isFn(argsOption)) {
  1097. argsOption = argsOption(fromArgs, toArgs) || {};
  1098. }
  1099. for (var key in fromArgs) {
  1100. if (hasOwn(argsOption, key)) {
  1101. var keyOption = argsOption[key];
  1102. if (isFn(keyOption)) {
  1103. keyOption = keyOption(fromArgs[key], fromArgs, toArgs);
  1104. }
  1105. if (!keyOption) {
  1106. // 不支持的参数
  1107. console.warn("The '".concat(methodName, "' method of platform '\u5934\u6761\u5C0F\u7A0B\u5E8F' does not support option '").concat(key, "'"));
  1108. } else if (isStr(keyOption)) {
  1109. // 重写参数 key
  1110. toArgs[keyOption] = fromArgs[key];
  1111. } else if (isPlainObject(keyOption)) {
  1112. // {name:newName,value:value}可重新指定参数 key:value
  1113. toArgs[keyOption.name ? keyOption.name : key] = keyOption.value;
  1114. }
  1115. } else if (CALLBACKS.indexOf(key) !== -1) {
  1116. if (isFn(fromArgs[key])) {
  1117. toArgs[key] = processCallback(methodName, fromArgs[key], returnValue);
  1118. }
  1119. } else {
  1120. if (!keepFromArgs) {
  1121. toArgs[key] = fromArgs[key];
  1122. }
  1123. }
  1124. }
  1125. return toArgs;
  1126. } else if (isFn(fromArgs)) {
  1127. fromArgs = processCallback(methodName, fromArgs, returnValue);
  1128. }
  1129. return fromArgs;
  1130. }
  1131. function processReturnValue(methodName, res, returnValue) {
  1132. var keepReturnValue = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : false;
  1133. if (isFn(protocols.returnValue)) {
  1134. // 处理通用 returnValue
  1135. res = protocols.returnValue(methodName, res);
  1136. }
  1137. return processArgs(methodName, res, returnValue, {}, keepReturnValue);
  1138. }
  1139. function wrapper(methodName, method) {
  1140. if (hasOwn(protocols, methodName)) {
  1141. var protocol = protocols[methodName];
  1142. if (!protocol) {
  1143. // 暂不支持的 api
  1144. return function () {
  1145. console.error("Platform '\u5934\u6761\u5C0F\u7A0B\u5E8F' does not support '".concat(methodName, "'."));
  1146. };
  1147. }
  1148. return function (arg1, arg2) {
  1149. // 目前 api 最多两个参数
  1150. var options = protocol;
  1151. if (isFn(protocol)) {
  1152. options = protocol(arg1);
  1153. }
  1154. arg1 = processArgs(methodName, arg1, options.args, options.returnValue);
  1155. var args = [arg1];
  1156. if (typeof arg2 !== 'undefined') {
  1157. args.push(arg2);
  1158. }
  1159. if (isFn(options.name)) {
  1160. methodName = options.name(arg1);
  1161. } else if (isStr(options.name)) {
  1162. methodName = options.name;
  1163. }
  1164. var returnValue = tt[methodName].apply(tt, args);
  1165. if (isSyncApi(methodName)) {
  1166. // 同步 api
  1167. return processReturnValue(methodName, returnValue, options.returnValue, isContextApi(methodName));
  1168. }
  1169. return returnValue;
  1170. };
  1171. }
  1172. return method;
  1173. }
  1174. var todoApis = Object.create(null);
  1175. var TODOS = ['onTabBarMidButtonTap', 'subscribePush', 'unsubscribePush', 'onPush', 'offPush', 'share'];
  1176. function createTodoApi(name) {
  1177. return function todoApi(_ref) {
  1178. var fail = _ref.fail,
  1179. complete = _ref.complete;
  1180. var res = {
  1181. errMsg: "".concat(name, ":fail method '").concat(name, "' not supported")
  1182. };
  1183. isFn(fail) && fail(res);
  1184. isFn(complete) && complete(res);
  1185. };
  1186. }
  1187. TODOS.forEach(function (name) {
  1188. todoApis[name] = createTodoApi(name);
  1189. });
  1190. var providers = {
  1191. oauth: ['toutiao'],
  1192. share: ['toutiao'],
  1193. payment: ['toutiao'],
  1194. push: ['toutiao']
  1195. };
  1196. function getProvider(_ref2) {
  1197. var service = _ref2.service,
  1198. success = _ref2.success,
  1199. fail = _ref2.fail,
  1200. complete = _ref2.complete;
  1201. var res = false;
  1202. if (providers[service]) {
  1203. res = {
  1204. errMsg: 'getProvider:ok',
  1205. service: service,
  1206. provider: providers[service]
  1207. };
  1208. isFn(success) && success(res);
  1209. } else {
  1210. res = {
  1211. errMsg: 'getProvider:fail service not found'
  1212. };
  1213. isFn(fail) && fail(res);
  1214. }
  1215. isFn(complete) && complete(res);
  1216. }
  1217. var extraApi = /*#__PURE__*/Object.freeze({
  1218. __proto__: null,
  1219. getProvider: getProvider
  1220. });
  1221. var getEmitter = function () {
  1222. var Emitter;
  1223. return function getUniEmitter() {
  1224. if (!Emitter) {
  1225. Emitter = new _vue.default();
  1226. }
  1227. return Emitter;
  1228. };
  1229. }();
  1230. function apply(ctx, method, args) {
  1231. return ctx[method].apply(ctx, args);
  1232. }
  1233. function $on() {
  1234. return apply(getEmitter(), '$on', Array.prototype.slice.call(arguments));
  1235. }
  1236. function $off() {
  1237. return apply(getEmitter(), '$off', Array.prototype.slice.call(arguments));
  1238. }
  1239. function $once() {
  1240. return apply(getEmitter(), '$once', Array.prototype.slice.call(arguments));
  1241. }
  1242. function $emit() {
  1243. return apply(getEmitter(), '$emit', Array.prototype.slice.call(arguments));
  1244. }
  1245. var eventApi = /*#__PURE__*/Object.freeze({
  1246. __proto__: null,
  1247. $on: $on,
  1248. $off: $off,
  1249. $once: $once,
  1250. $emit: $emit
  1251. });
  1252. function createMediaQueryObserver() {
  1253. var mediaQueryObserver = {};
  1254. var _tt$getSystemInfoSync = tt.getSystemInfoSync(),
  1255. windowWidth = _tt$getSystemInfoSync.windowWidth,
  1256. windowHeight = _tt$getSystemInfoSync.windowHeight;
  1257. var orientation = windowWidth < windowHeight ? 'portrait' : 'landscape';
  1258. mediaQueryObserver.observe = function (options, callback) {
  1259. var matches = true;
  1260. for (var item in options) {
  1261. var itemValue = item === 'orientation' ? options[item] : Number(options[item]);
  1262. if (options[item] !== '') {
  1263. if (item === 'width') {
  1264. if (itemValue === windowWidth) {
  1265. matches = true;
  1266. } else {
  1267. matches = false;
  1268. callback(matches);
  1269. return matches;
  1270. }
  1271. }
  1272. if (item === 'minWidth') {
  1273. if (windowWidth >= itemValue) {
  1274. matches = true;
  1275. } else {
  1276. matches = false;
  1277. callback(matches);
  1278. return matches;
  1279. }
  1280. }
  1281. if (item === 'maxWidth') {
  1282. if (windowWidth <= itemValue) {
  1283. matches = true;
  1284. } else {
  1285. matches = false;
  1286. callback(matches);
  1287. return matches;
  1288. }
  1289. }
  1290. if (item === 'height') {
  1291. if (itemValue === windowHeight) {
  1292. matches = true;
  1293. } else {
  1294. matches = false;
  1295. callback(matches);
  1296. return matches;
  1297. }
  1298. }
  1299. if (item === 'minHeight') {
  1300. if (windowHeight >= itemValue) {
  1301. matches = true;
  1302. } else {
  1303. matches = false;
  1304. callback(matches);
  1305. return matches;
  1306. }
  1307. }
  1308. if (item === 'maxHeight') {
  1309. if (windowHeight <= itemValue) {
  1310. matches = true;
  1311. } else {
  1312. matches = false;
  1313. callback(matches);
  1314. return matches;
  1315. }
  1316. }
  1317. if (item === 'orientation') {
  1318. if (options[item] === orientation) {
  1319. matches = true;
  1320. } else {
  1321. matches = false;
  1322. callback(matches);
  1323. return matches;
  1324. }
  1325. }
  1326. }
  1327. }
  1328. callback(matches);
  1329. return matches;
  1330. };
  1331. mediaQueryObserver.disconnect = function () {};
  1332. return mediaQueryObserver;
  1333. }
  1334. /**
  1335. * 框架内 try-catch
  1336. */
  1337. /**
  1338. * 开发者 try-catch
  1339. */
  1340. function tryCatch(fn) {
  1341. return function () {
  1342. try {
  1343. return fn.apply(fn, arguments);
  1344. } catch (e) {
  1345. // TODO
  1346. console.error(e);
  1347. }
  1348. };
  1349. }
  1350. function getApiCallbacks(params) {
  1351. var apiCallbacks = {};
  1352. for (var name in params) {
  1353. var param = params[name];
  1354. if (isFn(param)) {
  1355. apiCallbacks[name] = tryCatch(param);
  1356. delete params[name];
  1357. }
  1358. }
  1359. return apiCallbacks;
  1360. }
  1361. var cid;
  1362. var cidErrMsg;
  1363. var enabled;
  1364. function normalizePushMessage(message) {
  1365. try {
  1366. return JSON.parse(message);
  1367. } catch (e) {}
  1368. return message;
  1369. }
  1370. function invokePushCallback(args) {
  1371. if (args.type === 'enabled') {
  1372. enabled = true;
  1373. } else if (args.type === 'clientId') {
  1374. cid = args.cid;
  1375. cidErrMsg = args.errMsg;
  1376. invokeGetPushCidCallbacks(cid, args.errMsg);
  1377. } else if (args.type === 'pushMsg') {
  1378. var message = {
  1379. type: 'receive',
  1380. data: normalizePushMessage(args.message)
  1381. };
  1382. for (var i = 0; i < onPushMessageCallbacks.length; i++) {
  1383. var callback = onPushMessageCallbacks[i];
  1384. callback(message);
  1385. // 该消息已被阻止
  1386. if (message.stopped) {
  1387. break;
  1388. }
  1389. }
  1390. } else if (args.type === 'click') {
  1391. onPushMessageCallbacks.forEach(function (callback) {
  1392. callback({
  1393. type: 'click',
  1394. data: normalizePushMessage(args.message)
  1395. });
  1396. });
  1397. }
  1398. }
  1399. var getPushCidCallbacks = [];
  1400. function invokeGetPushCidCallbacks(cid, errMsg) {
  1401. getPushCidCallbacks.forEach(function (callback) {
  1402. callback(cid, errMsg);
  1403. });
  1404. getPushCidCallbacks.length = 0;
  1405. }
  1406. function getPushClientId(args) {
  1407. if (!isPlainObject(args)) {
  1408. args = {};
  1409. }
  1410. var _getApiCallbacks = getApiCallbacks(args),
  1411. success = _getApiCallbacks.success,
  1412. fail = _getApiCallbacks.fail,
  1413. complete = _getApiCallbacks.complete;
  1414. var hasSuccess = isFn(success);
  1415. var hasFail = isFn(fail);
  1416. var hasComplete = isFn(complete);
  1417. Promise.resolve().then(function () {
  1418. if (typeof enabled === 'undefined') {
  1419. enabled = false;
  1420. cid = '';
  1421. cidErrMsg = 'uniPush is not enabled';
  1422. }
  1423. getPushCidCallbacks.push(function (cid, errMsg) {
  1424. var res;
  1425. if (cid) {
  1426. res = {
  1427. errMsg: 'getPushClientId:ok',
  1428. cid: cid
  1429. };
  1430. hasSuccess && success(res);
  1431. } else {
  1432. res = {
  1433. errMsg: 'getPushClientId:fail' + (errMsg ? ' ' + errMsg : '')
  1434. };
  1435. hasFail && fail(res);
  1436. }
  1437. hasComplete && complete(res);
  1438. });
  1439. if (typeof cid !== 'undefined') {
  1440. invokeGetPushCidCallbacks(cid, cidErrMsg);
  1441. }
  1442. });
  1443. }
  1444. var onPushMessageCallbacks = [];
  1445. // 不使用 defineOnApi 实现,是因为 defineOnApi 依赖 UniServiceJSBridge ,该对象目前在小程序上未提供,故简单实现
  1446. var onPushMessage = function onPushMessage(fn) {
  1447. if (onPushMessageCallbacks.indexOf(fn) === -1) {
  1448. onPushMessageCallbacks.push(fn);
  1449. }
  1450. };
  1451. var offPushMessage = function offPushMessage(fn) {
  1452. if (!fn) {
  1453. onPushMessageCallbacks.length = 0;
  1454. } else {
  1455. var index = onPushMessageCallbacks.indexOf(fn);
  1456. if (index > -1) {
  1457. onPushMessageCallbacks.splice(index, 1);
  1458. }
  1459. }
  1460. };
  1461. function __f__(type) {
  1462. for (var _len4 = arguments.length, args = new Array(_len4 > 1 ? _len4 - 1 : 0), _key4 = 1; _key4 < _len4; _key4++) {
  1463. args[_key4 - 1] = arguments[_key4];
  1464. }
  1465. console[type].apply(console, args);
  1466. }
  1467. var api = /*#__PURE__*/Object.freeze({
  1468. __proto__: null,
  1469. createMediaQueryObserver: createMediaQueryObserver,
  1470. getPushClientId: getPushClientId,
  1471. onPushMessage: onPushMessage,
  1472. offPushMessage: offPushMessage,
  1473. invokePushCallback: invokePushCallback,
  1474. __f__: __f__
  1475. });
  1476. function findVmByVueId(vm, vuePid) {
  1477. var $children = vm.$children;
  1478. // 优先查找直属(反向查找:https://github.com/dcloudio/uni-app/issues/1200)
  1479. for (var i = $children.length - 1; i >= 0; i--) {
  1480. var childVm = $children[i];
  1481. if (childVm.$scope._$vueId === vuePid) {
  1482. return childVm;
  1483. }
  1484. }
  1485. // 反向递归查找
  1486. var parentVm;
  1487. for (var _i = $children.length - 1; _i >= 0; _i--) {
  1488. parentVm = findVmByVueId($children[_i], vuePid);
  1489. if (parentVm) {
  1490. return parentVm;
  1491. }
  1492. }
  1493. }
  1494. function initBehavior(options) {
  1495. return Behavior(options);
  1496. }
  1497. function selectAllComponents(mpInstance, selector, $refs) {
  1498. var components = mpInstance.selectAllComponents(selector) || [];
  1499. components.forEach(function (component) {
  1500. var ref = component.dataset.ref;
  1501. $refs[ref] = component.$vm || toSkip(component);
  1502. });
  1503. }
  1504. function syncRefs(refs, newRefs) {
  1505. var oldKeys = (0, _construct2.default)(Set, (0, _toConsumableArray2.default)(Object.keys(refs)));
  1506. var newKeys = Object.keys(newRefs);
  1507. newKeys.forEach(function (key) {
  1508. var oldValue = refs[key];
  1509. var newValue = newRefs[key];
  1510. if (Array.isArray(oldValue) && Array.isArray(newValue) && oldValue.length === newValue.length && newValue.every(function (value) {
  1511. return oldValue.includes(value);
  1512. })) {
  1513. return;
  1514. }
  1515. refs[key] = newValue;
  1516. oldKeys.delete(key);
  1517. });
  1518. oldKeys.forEach(function (key) {
  1519. delete refs[key];
  1520. });
  1521. return refs;
  1522. }
  1523. function initRefs(vm) {
  1524. var mpInstance = vm.$scope;
  1525. var refs = {};
  1526. Object.defineProperty(vm, '$refs', {
  1527. get: function get() {
  1528. var $refs = {};
  1529. selectAllComponents(mpInstance, '.vue-ref', $refs);
  1530. // TODO 暂不考虑 for 中的 scoped
  1531. var forComponents = mpInstance.selectAllComponents('.vue-ref-in-for') || [];
  1532. forComponents.forEach(function (component) {
  1533. var ref = component.dataset.ref;
  1534. if (!$refs[ref]) {
  1535. $refs[ref] = [];
  1536. }
  1537. $refs[ref].push(component.$vm || toSkip(component));
  1538. });
  1539. return syncRefs(refs, $refs);
  1540. }
  1541. });
  1542. }
  1543. function handleLink(event) {
  1544. var _ref3 = event.detail || event.value,
  1545. vuePid = _ref3.vuePid,
  1546. vueOptions = _ref3.vueOptions; // detail 是微信,value 是百度(dipatch)
  1547. var parentVm;
  1548. if (vuePid) {
  1549. parentVm = findVmByVueId(this.$vm, vuePid);
  1550. }
  1551. if (!parentVm) {
  1552. parentVm = this.$vm;
  1553. }
  1554. vueOptions.parent = parentVm;
  1555. }
  1556. function markMPComponent(component) {
  1557. // 在 Vue 中标记为小程序组件
  1558. var IS_MP = '__v_isMPComponent';
  1559. Object.defineProperty(component, IS_MP, {
  1560. configurable: true,
  1561. enumerable: false,
  1562. value: true
  1563. });
  1564. return component;
  1565. }
  1566. function toSkip(obj) {
  1567. var OB = '__ob__';
  1568. var SKIP = '__v_skip';
  1569. if (isObject(obj) && Object.isExtensible(obj)) {
  1570. // 避免被 @vue/composition-api 观测
  1571. Object.defineProperty(obj, OB, {
  1572. configurable: true,
  1573. enumerable: false,
  1574. value: (0, _defineProperty2.default)({}, SKIP, true)
  1575. });
  1576. }
  1577. return obj;
  1578. }
  1579. var MPPage = Page;
  1580. var MPComponent = Component;
  1581. var customizeRE = /:/g;
  1582. var customize = cached(function (str) {
  1583. return camelize(str.replace(customizeRE, '-'));
  1584. });
  1585. function initTriggerEvent(mpInstance) {
  1586. var oldTriggerEvent = mpInstance.triggerEvent;
  1587. var newTriggerEvent = function newTriggerEvent(event) {
  1588. // 事件名统一转驼峰格式,仅处理:当前组件为 vue 组件、当前组件为 vue 组件子组件
  1589. if (this.$vm || this.dataset && this.dataset.comType) {
  1590. event = customize(event);
  1591. }
  1592. for (var _len5 = arguments.length, args = new Array(_len5 > 1 ? _len5 - 1 : 0), _key5 = 1; _key5 < _len5; _key5++) {
  1593. args[_key5 - 1] = arguments[_key5];
  1594. }
  1595. return oldTriggerEvent.apply(this, [event].concat(args));
  1596. };
  1597. try {
  1598. // 京东小程序 triggerEvent 为只读
  1599. mpInstance.triggerEvent = newTriggerEvent;
  1600. } catch (error) {
  1601. mpInstance._triggerEvent = newTriggerEvent;
  1602. }
  1603. }
  1604. function initHook(name, options, isComponent) {
  1605. {
  1606. // fix by Lxh 字节自定义组件Component构造器文档上写有created,但是实测只触发了lifetimes上的created
  1607. isComponent && options.lifetimes && options.lifetimes[name] && (options = options.lifetimes);
  1608. }
  1609. var oldHook = options[name];
  1610. options[name] = function () {
  1611. markMPComponent(this);
  1612. initTriggerEvent(this);
  1613. if (oldHook) {
  1614. for (var _len6 = arguments.length, args = new Array(_len6), _key6 = 0; _key6 < _len6; _key6++) {
  1615. args[_key6] = arguments[_key6];
  1616. }
  1617. return oldHook.apply(this, args);
  1618. }
  1619. };
  1620. }
  1621. if (!MPPage.__$wrappered) {
  1622. MPPage.__$wrappered = true;
  1623. Page = function Page() {
  1624. var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
  1625. initHook('onLoad', options);
  1626. return MPPage(options);
  1627. };
  1628. Page.after = MPPage.after;
  1629. Component = function Component() {
  1630. var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
  1631. initHook('created', options, true);
  1632. return MPComponent(options);
  1633. };
  1634. }
  1635. var PAGE_EVENT_HOOKS = ['onPullDownRefresh', 'onReachBottom', 'onAddToFavorites', 'onShareTimeline', 'onShareAppMessage', 'onPageScroll', 'onResize', 'onTabItemTap'];
  1636. function initMocks(vm, mocks) {
  1637. var mpInstance = vm.$mp[vm.mpType];
  1638. mocks.forEach(function (mock) {
  1639. if (hasOwn(mpInstance, mock)) {
  1640. vm[mock] = mpInstance[mock];
  1641. }
  1642. });
  1643. }
  1644. function hasHook(hook, vueOptions) {
  1645. if (!vueOptions) {
  1646. return true;
  1647. }
  1648. if (_vue.default.options && Array.isArray(_vue.default.options[hook])) {
  1649. return true;
  1650. }
  1651. vueOptions = vueOptions.default || vueOptions;
  1652. if (isFn(vueOptions)) {
  1653. if (isFn(vueOptions.extendOptions[hook])) {
  1654. return true;
  1655. }
  1656. if (vueOptions.super && vueOptions.super.options && Array.isArray(vueOptions.super.options[hook])) {
  1657. return true;
  1658. }
  1659. return false;
  1660. }
  1661. if (isFn(vueOptions[hook]) || Array.isArray(vueOptions[hook])) {
  1662. return true;
  1663. }
  1664. var mixins = vueOptions.mixins;
  1665. if (Array.isArray(mixins)) {
  1666. return !!mixins.find(function (mixin) {
  1667. return hasHook(hook, mixin);
  1668. });
  1669. }
  1670. }
  1671. function initHooks(mpOptions, hooks, vueOptions) {
  1672. hooks.forEach(function (hook) {
  1673. if (hasHook(hook, vueOptions)) {
  1674. mpOptions[hook] = function (args) {
  1675. return this.$vm && this.$vm.__call_hook(hook, args);
  1676. };
  1677. }
  1678. });
  1679. }
  1680. function initUnknownHooks(mpOptions, vueOptions) {
  1681. var excludes = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : [];
  1682. findHooks(vueOptions).forEach(function (hook) {
  1683. return initHook$1(mpOptions, hook, excludes);
  1684. });
  1685. }
  1686. function findHooks(vueOptions) {
  1687. var hooks = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [];
  1688. if (vueOptions) {
  1689. Object.keys(vueOptions).forEach(function (name) {
  1690. if (name.indexOf('on') === 0 && isFn(vueOptions[name])) {
  1691. hooks.push(name);
  1692. }
  1693. });
  1694. }
  1695. return hooks;
  1696. }
  1697. function initHook$1(mpOptions, hook, excludes) {
  1698. if (excludes.indexOf(hook) === -1 && !hasOwn(mpOptions, hook)) {
  1699. mpOptions[hook] = function (args) {
  1700. return this.$vm && this.$vm.__call_hook(hook, args);
  1701. };
  1702. }
  1703. }
  1704. function initVueComponent(Vue, vueOptions) {
  1705. vueOptions = vueOptions.default || vueOptions;
  1706. var VueComponent;
  1707. if (isFn(vueOptions)) {
  1708. VueComponent = vueOptions;
  1709. } else {
  1710. VueComponent = Vue.extend(vueOptions);
  1711. }
  1712. vueOptions = VueComponent.options;
  1713. return [VueComponent, vueOptions];
  1714. }
  1715. function initSlots(vm, vueSlots) {
  1716. if (Array.isArray(vueSlots) && vueSlots.length) {
  1717. var $slots = Object.create(null);
  1718. vueSlots.forEach(function (slotName) {
  1719. $slots[slotName] = true;
  1720. });
  1721. vm.$scopedSlots = vm.$slots = $slots;
  1722. }
  1723. }
  1724. function initVueIds(vueIds, mpInstance) {
  1725. vueIds = (vueIds || '').split(',');
  1726. var len = vueIds.length;
  1727. if (len === 1) {
  1728. mpInstance._$vueId = vueIds[0];
  1729. } else if (len === 2) {
  1730. mpInstance._$vueId = vueIds[0];
  1731. mpInstance._$vuePid = vueIds[1];
  1732. }
  1733. }
  1734. function initData(vueOptions, context) {
  1735. var data = vueOptions.data || {};
  1736. var methods = vueOptions.methods || {};
  1737. if (typeof data === 'function') {
  1738. try {
  1739. data = data.call(context); // 支持 Vue.prototype 上挂的数据
  1740. } catch (e) {
  1741. if (Object({"NODE_ENV":"development","VUE_APP_DARK_MODE":"false","VUE_APP_NAME":"核销工具DY","VUE_APP_PLATFORM":"mp-toutiao","BASE_URL":"/"}).VUE_APP_DEBUG) {
  1742. console.warn('根据 Vue 的 data 函数初始化小程序 data 失败,请尽量确保 data 函数中不访问 vm 对象,否则可能影响首次数据渲染速度。', data);
  1743. }
  1744. }
  1745. } else {
  1746. try {
  1747. // 对 data 格式化
  1748. data = JSON.parse(JSON.stringify(data));
  1749. } catch (e) {}
  1750. }
  1751. if (!isPlainObject(data)) {
  1752. data = {};
  1753. }
  1754. Object.keys(methods).forEach(function (methodName) {
  1755. if (context.__lifecycle_hooks__.indexOf(methodName) === -1 && !hasOwn(data, methodName)) {
  1756. data[methodName] = methods[methodName];
  1757. }
  1758. });
  1759. return data;
  1760. }
  1761. var PROP_TYPES = [String, Number, Boolean, Object, Array, null];
  1762. function createObserver(name) {
  1763. return function observer(newVal, oldVal) {
  1764. if (this.$vm) {
  1765. this.$vm[name] = newVal; // 为了触发其他非 render watcher
  1766. }
  1767. };
  1768. }
  1769. function initBehaviors(vueOptions, initBehavior) {
  1770. var vueBehaviors = vueOptions.behaviors;
  1771. var vueExtends = vueOptions.extends;
  1772. var vueMixins = vueOptions.mixins;
  1773. var vueProps = vueOptions.props;
  1774. if (!vueProps) {
  1775. vueOptions.props = vueProps = [];
  1776. }
  1777. var behaviors = [];
  1778. if (Array.isArray(vueBehaviors)) {
  1779. vueBehaviors.forEach(function (behavior) {
  1780. behaviors.push(behavior.replace('uni://', "tt".concat("://")));
  1781. if (behavior === 'uni://form-field') {
  1782. if (Array.isArray(vueProps)) {
  1783. vueProps.push('name');
  1784. vueProps.push('value');
  1785. } else {
  1786. vueProps.name = {
  1787. type: String,
  1788. default: ''
  1789. };
  1790. vueProps.value = {
  1791. type: [String, Number, Boolean, Array, Object, Date],
  1792. default: ''
  1793. };
  1794. }
  1795. }
  1796. });
  1797. }
  1798. if (isPlainObject(vueExtends) && vueExtends.props) {
  1799. behaviors.push(initBehavior({
  1800. properties: initProperties(vueExtends.props, true)
  1801. }));
  1802. }
  1803. if (Array.isArray(vueMixins)) {
  1804. vueMixins.forEach(function (vueMixin) {
  1805. if (isPlainObject(vueMixin) && vueMixin.props) {
  1806. behaviors.push(initBehavior({
  1807. properties: initProperties(vueMixin.props, true)
  1808. }));
  1809. }
  1810. });
  1811. }
  1812. return behaviors;
  1813. }
  1814. function parsePropType(key, type, defaultValue, file) {
  1815. // [String]=>String
  1816. if (Array.isArray(type) && type.length === 1) {
  1817. return type[0];
  1818. }
  1819. return type;
  1820. }
  1821. function initProperties(props) {
  1822. var isBehavior = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
  1823. var file = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : '';
  1824. var options = arguments.length > 3 ? arguments[3] : undefined;
  1825. var properties = {};
  1826. if (!isBehavior) {
  1827. properties.vueId = {
  1828. type: String,
  1829. value: ''
  1830. };
  1831. {
  1832. // 用于字节跳动小程序模拟抽象节点
  1833. properties.generic = {
  1834. type: Object,
  1835. value: null
  1836. };
  1837. }
  1838. {
  1839. if (options.virtualHost) {
  1840. {
  1841. options.applyFragment = true;
  1842. }
  1843. properties.virtualHostStyle = {
  1844. type: null,
  1845. value: ''
  1846. };
  1847. properties.virtualHostClass = {
  1848. type: null,
  1849. value: ''
  1850. };
  1851. }
  1852. }
  1853. // scopedSlotsCompiler auto
  1854. properties.scopedSlotsCompiler = {
  1855. type: String,
  1856. value: ''
  1857. };
  1858. properties.vueSlots = {
  1859. // 小程序不能直接定义 $slots 的 props,所以通过 vueSlots 转换到 $slots
  1860. type: null,
  1861. value: [],
  1862. observer: function observer(newVal, oldVal) {
  1863. var $slots = Object.create(null);
  1864. newVal.forEach(function (slotName) {
  1865. $slots[slotName] = true;
  1866. });
  1867. this.setData({
  1868. $slots: $slots
  1869. });
  1870. }
  1871. };
  1872. }
  1873. if (Array.isArray(props)) {
  1874. // ['title']
  1875. props.forEach(function (key) {
  1876. properties[key] = {
  1877. type: null,
  1878. observer: createObserver(key)
  1879. };
  1880. });
  1881. } else if (isPlainObject(props)) {
  1882. // {title:{type:String,default:''},content:String}
  1883. Object.keys(props).forEach(function (key) {
  1884. var opts = props[key];
  1885. if (isPlainObject(opts)) {
  1886. // title:{type:String,default:''}
  1887. var value = opts.default;
  1888. if (isFn(value)) {
  1889. value = value();
  1890. }
  1891. opts.type = parsePropType(key, opts.type);
  1892. properties[key] = {
  1893. type: PROP_TYPES.indexOf(opts.type) !== -1 ? opts.type : null,
  1894. value: value,
  1895. observer: createObserver(key)
  1896. };
  1897. } else {
  1898. // content:String
  1899. var type = parsePropType(key, opts);
  1900. properties[key] = {
  1901. type: PROP_TYPES.indexOf(type) !== -1 ? type : null,
  1902. observer: createObserver(key)
  1903. };
  1904. }
  1905. });
  1906. }
  1907. return properties;
  1908. }
  1909. function wrapper$1(event) {
  1910. // TODO 又得兼容 mpvue 的 mp 对象
  1911. try {
  1912. event.mp = JSON.parse(JSON.stringify(event));
  1913. } catch (e) {}
  1914. event.stopPropagation = noop;
  1915. event.preventDefault = noop;
  1916. event.target = event.target || {};
  1917. if (!hasOwn(event, 'detail')) {
  1918. event.detail = {};
  1919. }
  1920. if (hasOwn(event, 'markerId')) {
  1921. event.detail = (0, _typeof2.default)(event.detail) === 'object' ? event.detail : {};
  1922. event.detail.markerId = event.markerId;
  1923. }
  1924. if (isPlainObject(event.detail)) {
  1925. event.target = Object.assign({}, event.target, event.detail);
  1926. }
  1927. return event;
  1928. }
  1929. function getExtraValue(vm, dataPathsArray) {
  1930. var context = vm;
  1931. dataPathsArray.forEach(function (dataPathArray) {
  1932. var dataPath = dataPathArray[0];
  1933. var value = dataPathArray[2];
  1934. if (dataPath || typeof value !== 'undefined') {
  1935. // ['','',index,'disable']
  1936. var propPath = dataPathArray[1];
  1937. var valuePath = dataPathArray[3];
  1938. var vFor;
  1939. if (Number.isInteger(dataPath)) {
  1940. vFor = dataPath;
  1941. } else if (!dataPath) {
  1942. vFor = context;
  1943. } else if (typeof dataPath === 'string' && dataPath) {
  1944. if (dataPath.indexOf('#s#') === 0) {
  1945. vFor = dataPath.substr(3);
  1946. } else {
  1947. vFor = vm.__get_value(dataPath, context);
  1948. }
  1949. }
  1950. if (Number.isInteger(vFor)) {
  1951. context = value;
  1952. } else if (!propPath) {
  1953. context = vFor[value];
  1954. } else {
  1955. if (Array.isArray(vFor)) {
  1956. context = vFor.find(function (vForItem) {
  1957. return vm.__get_value(propPath, vForItem) === value;
  1958. });
  1959. } else if (isPlainObject(vFor)) {
  1960. context = Object.keys(vFor).find(function (vForKey) {
  1961. return vm.__get_value(propPath, vFor[vForKey]) === value;
  1962. });
  1963. } else {
  1964. console.error('v-for 暂不支持循环数据:', vFor);
  1965. }
  1966. }
  1967. if (valuePath) {
  1968. context = vm.__get_value(valuePath, context);
  1969. }
  1970. }
  1971. });
  1972. return context;
  1973. }
  1974. function processEventExtra(vm, extra, event, __args__) {
  1975. var extraObj = {};
  1976. if (Array.isArray(extra) && extra.length) {
  1977. /**
  1978. *[
  1979. * ['data.items', 'data.id', item.data.id],
  1980. * ['metas', 'id', meta.id]
  1981. *],
  1982. *[
  1983. * ['data.items', 'data.id', item.data.id],
  1984. * ['metas', 'id', meta.id]
  1985. *],
  1986. *'test'
  1987. */
  1988. extra.forEach(function (dataPath, index) {
  1989. if (typeof dataPath === 'string') {
  1990. if (!dataPath) {
  1991. // model,prop.sync
  1992. extraObj['$' + index] = vm;
  1993. } else {
  1994. if (dataPath === '$event') {
  1995. // $event
  1996. extraObj['$' + index] = event;
  1997. } else if (dataPath === 'arguments') {
  1998. extraObj['$' + index] = event.detail ? event.detail.__args__ || __args__ : __args__;
  1999. } else if (dataPath.indexOf('$event.') === 0) {
  2000. // $event.target.value
  2001. extraObj['$' + index] = vm.__get_value(dataPath.replace('$event.', ''), event);
  2002. } else {
  2003. extraObj['$' + index] = vm.__get_value(dataPath);
  2004. }
  2005. }
  2006. } else {
  2007. extraObj['$' + index] = getExtraValue(vm, dataPath);
  2008. }
  2009. });
  2010. }
  2011. return extraObj;
  2012. }
  2013. function getObjByArray(arr) {
  2014. var obj = {};
  2015. for (var i = 1; i < arr.length; i++) {
  2016. var element = arr[i];
  2017. obj[element[0]] = element[1];
  2018. }
  2019. return obj;
  2020. }
  2021. function processEventArgs(vm, event) {
  2022. var args = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : [];
  2023. var extra = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : [];
  2024. var isCustom = arguments.length > 4 ? arguments[4] : undefined;
  2025. var methodName = arguments.length > 5 ? arguments[5] : undefined;
  2026. var isCustomMPEvent = false; // wxcomponent 组件,传递原始 event 对象
  2027. // fixed 用户直接触发 mpInstance.triggerEvent
  2028. var __args__ = isPlainObject(event.detail) ? event.detail.__args__ || [event.detail] : [event.detail];
  2029. if (isCustom) {
  2030. // 自定义事件
  2031. isCustomMPEvent = event.currentTarget && event.currentTarget.dataset && event.currentTarget.dataset.comType === 'wx';
  2032. if (!args.length) {
  2033. // 无参数,直接传入 event 或 detail 数组
  2034. if (isCustomMPEvent) {
  2035. return [event];
  2036. }
  2037. return __args__;
  2038. }
  2039. }
  2040. var extraObj = processEventExtra(vm, extra, event, __args__);
  2041. var ret = [];
  2042. args.forEach(function (arg) {
  2043. if (arg === '$event') {
  2044. if (methodName === '__set_model' && !isCustom) {
  2045. // input v-model value
  2046. ret.push(event.target.value);
  2047. } else {
  2048. if (isCustom && !isCustomMPEvent) {
  2049. ret.push(__args__[0]);
  2050. } else {
  2051. // wxcomponent 组件或内置组件
  2052. ret.push(event);
  2053. }
  2054. }
  2055. } else {
  2056. if (Array.isArray(arg) && arg[0] === 'o') {
  2057. ret.push(getObjByArray(arg));
  2058. } else if (typeof arg === 'string' && hasOwn(extraObj, arg)) {
  2059. ret.push(extraObj[arg]);
  2060. } else {
  2061. ret.push(arg);
  2062. }
  2063. }
  2064. });
  2065. return ret;
  2066. }
  2067. var ONCE = '~';
  2068. var CUSTOM = '^';
  2069. function isMatchEventType(eventType, optType) {
  2070. return eventType === optType || optType === 'regionchange' && (eventType === 'begin' || eventType === 'end');
  2071. }
  2072. function getContextVm(vm) {
  2073. var $parent = vm.$parent;
  2074. // 父组件是 scoped slots 或者其他自定义组件时继续查找
  2075. while ($parent && $parent.$parent && ($parent.$options.generic || $parent.$parent.$options.generic || $parent.$scope._$vuePid)) {
  2076. $parent = $parent.$parent;
  2077. }
  2078. return $parent && $parent.$parent;
  2079. }
  2080. function handleEvent(event) {
  2081. var _this3 = this;
  2082. event = wrapper$1(event);
  2083. // [['tap',[['handle',[1,2,a]],['handle1',[1,2,a]]]]]
  2084. var dataset = (event.currentTarget || event.target).dataset;
  2085. if (!dataset) {
  2086. return console.warn('事件信息不存在');
  2087. }
  2088. var eventOpts = dataset.eventOpts || dataset['event-opts']; // 支付宝 web-view 组件 dataset 非驼峰
  2089. if (!eventOpts) {
  2090. return console.warn('事件信息不存在');
  2091. }
  2092. // [['handle',[1,2,a]],['handle1',[1,2,a]]]
  2093. var eventType = event.type;
  2094. var ret = [];
  2095. eventOpts.forEach(function (eventOpt) {
  2096. var type = eventOpt[0];
  2097. var eventsArray = eventOpt[1];
  2098. var isCustom = type.charAt(0) === CUSTOM;
  2099. type = isCustom ? type.slice(1) : type;
  2100. var isOnce = type.charAt(0) === ONCE;
  2101. type = isOnce ? type.slice(1) : type;
  2102. if (eventsArray && isMatchEventType(eventType, type)) {
  2103. eventsArray.forEach(function (eventArray) {
  2104. var methodName = eventArray[0];
  2105. if (methodName) {
  2106. var handlerCtx = _this3.$vm;
  2107. if (handlerCtx.$options.generic) {
  2108. // mp-weixin,mp-toutiao 抽象节点模拟 scoped slots
  2109. handlerCtx = getContextVm(handlerCtx) || handlerCtx;
  2110. }
  2111. if (methodName === '$emit') {
  2112. handlerCtx.$emit.apply(handlerCtx, processEventArgs(_this3.$vm, event, eventArray[1], eventArray[2], isCustom, methodName));
  2113. return;
  2114. }
  2115. var handler = handlerCtx[methodName];
  2116. if (!isFn(handler)) {
  2117. var _type = _this3.$vm.mpType === 'page' ? 'Page' : 'Component';
  2118. var path = _this3.route || _this3.is;
  2119. throw new Error("".concat(_type, " \"").concat(path, "\" does not have a method \"").concat(methodName, "\""));
  2120. }
  2121. if (isOnce) {
  2122. if (handler.once) {
  2123. return;
  2124. }
  2125. handler.once = true;
  2126. }
  2127. var params = processEventArgs(_this3.$vm, event, eventArray[1], eventArray[2], isCustom, methodName);
  2128. params = Array.isArray(params) ? params : [];
  2129. // 参数尾部增加原始事件对象用于复杂表达式内获取额外数据
  2130. if (/=\s*\S+\.eventParams\s*\|\|\s*\S+\[['"]event-params['"]\]/.test(handler.toString())) {
  2131. // eslint-disable-next-line no-sparse-arrays
  2132. params = params.concat([,,,,,,,,,, event]);
  2133. }
  2134. ret.push(handler.apply(handlerCtx, params));
  2135. }
  2136. });
  2137. }
  2138. });
  2139. if (eventType === 'input' && ret.length === 1 && typeof ret[0] !== 'undefined') {
  2140. return ret[0];
  2141. }
  2142. }
  2143. var hooks = ['onShow', 'onHide', 'onError', 'onPageNotFound', 'onThemeChange', 'onUnhandledRejection'];
  2144. function initEventChannel$1() {
  2145. _vue.default.prototype.getOpenerEventChannel = function () {
  2146. if (!this.__eventChannel__) {
  2147. this.__eventChannel__ = new EventChannel();
  2148. }
  2149. return this.__eventChannel__;
  2150. };
  2151. var callHook = _vue.default.prototype.__call_hook;
  2152. _vue.default.prototype.__call_hook = function (hook, args) {
  2153. if (hook === 'onLoad' && args && args.__id__) {
  2154. this.__eventChannel__ = getEventChannel(args.__id__);
  2155. delete args.__id__;
  2156. }
  2157. return callHook.call(this, hook, args);
  2158. };
  2159. }
  2160. function initScopedSlotsParams() {
  2161. var center = {};
  2162. var parents = {};
  2163. function currentId(fn) {
  2164. var vueIds = this.$options.propsData.vueId;
  2165. if (vueIds) {
  2166. var vueId = vueIds.split(',')[0];
  2167. fn(vueId);
  2168. }
  2169. }
  2170. _vue.default.prototype.$hasSSP = function (vueId) {
  2171. var slot = center[vueId];
  2172. if (!slot) {
  2173. parents[vueId] = this;
  2174. this.$on('hook:destroyed', function () {
  2175. delete parents[vueId];
  2176. });
  2177. }
  2178. return slot;
  2179. };
  2180. _vue.default.prototype.$getSSP = function (vueId, name, needAll) {
  2181. var slot = center[vueId];
  2182. if (slot) {
  2183. var params = slot[name] || [];
  2184. if (needAll) {
  2185. return params;
  2186. }
  2187. return params[0];
  2188. }
  2189. };
  2190. _vue.default.prototype.$setSSP = function (name, value) {
  2191. var index = 0;
  2192. currentId.call(this, function (vueId) {
  2193. var slot = center[vueId];
  2194. var params = slot[name] = slot[name] || [];
  2195. params.push(value);
  2196. index = params.length - 1;
  2197. });
  2198. return index;
  2199. };
  2200. _vue.default.prototype.$initSSP = function () {
  2201. currentId.call(this, function (vueId) {
  2202. center[vueId] = {};
  2203. });
  2204. };
  2205. _vue.default.prototype.$callSSP = function () {
  2206. currentId.call(this, function (vueId) {
  2207. if (parents[vueId]) {
  2208. parents[vueId].$forceUpdate();
  2209. }
  2210. });
  2211. };
  2212. _vue.default.mixin({
  2213. destroyed: function destroyed() {
  2214. var propsData = this.$options.propsData;
  2215. var vueId = propsData && propsData.vueId;
  2216. if (vueId) {
  2217. delete center[vueId];
  2218. delete parents[vueId];
  2219. }
  2220. }
  2221. });
  2222. }
  2223. function parseBaseApp(vm, _ref4) {
  2224. var mocks = _ref4.mocks,
  2225. initRefs = _ref4.initRefs;
  2226. initEventChannel$1();
  2227. {
  2228. initScopedSlotsParams();
  2229. }
  2230. if (vm.$options.store) {
  2231. _vue.default.prototype.$store = vm.$options.store;
  2232. }
  2233. uniIdMixin(_vue.default);
  2234. _vue.default.prototype.mpHost = "mp-toutiao";
  2235. _vue.default.mixin({
  2236. beforeCreate: function beforeCreate() {
  2237. if (!this.$options.mpType) {
  2238. return;
  2239. }
  2240. this.mpType = this.$options.mpType;
  2241. this.$mp = (0, _defineProperty2.default)({
  2242. data: {}
  2243. }, this.mpType, this.$options.mpInstance);
  2244. this.$scope = this.$options.mpInstance;
  2245. delete this.$options.mpType;
  2246. delete this.$options.mpInstance;
  2247. if (this.mpType !== 'app' && typeof getApp === 'function') {
  2248. // hack vue-i18n
  2249. var app = getApp();
  2250. if (app.$vm && app.$vm.$i18n) {
  2251. this._i18n = app.$vm.$i18n;
  2252. }
  2253. }
  2254. if (this.mpType !== 'app') {
  2255. initRefs(this);
  2256. initMocks(this, mocks);
  2257. }
  2258. }
  2259. });
  2260. var appOptions = {
  2261. onLaunch: function onLaunch(args) {
  2262. if (this.$vm) {
  2263. // 已经初始化过了,主要是为了百度,百度 onShow 在 onLaunch 之前
  2264. return;
  2265. }
  2266. this.$vm = vm;
  2267. this.$vm.$mp = {
  2268. app: this
  2269. };
  2270. this.$vm.$scope = this;
  2271. // vm 上也挂载 globalData
  2272. this.$vm.globalData = this.globalData;
  2273. this.$vm._isMounted = true;
  2274. this.$vm.__call_hook('mounted', args);
  2275. this.$vm.__call_hook('onLaunch', args);
  2276. }
  2277. };
  2278. // 兼容旧版本 globalData
  2279. appOptions.globalData = vm.$options.globalData || {};
  2280. // 将 methods 中的方法挂在 getApp() 中
  2281. var methods = vm.$options.methods;
  2282. if (methods) {
  2283. Object.keys(methods).forEach(function (name) {
  2284. appOptions[name] = methods[name];
  2285. });
  2286. }
  2287. initAppLocale(_vue.default, vm, getLocaleLanguage$1());
  2288. initHooks(appOptions, hooks);
  2289. initUnknownHooks(appOptions, vm.$options);
  2290. return appOptions;
  2291. }
  2292. function getLocaleLanguage$1() {
  2293. var localeLanguage = '';
  2294. {
  2295. localeLanguage = normalizeLocale(tt.getSystemInfoSync().language) || LOCALE_EN;
  2296. }
  2297. return localeLanguage;
  2298. }
  2299. var mocks = ['__route__', '__webviewId__', '__nodeid__', '__nodeId__'];
  2300. function isPage() {
  2301. return this.__nodeid__ === 0 || this.__nodeId__ === 0;
  2302. }
  2303. function initRefs$1(vm) {
  2304. var mpInstance = vm.$scope;
  2305. /* eslint-disable no-undef */
  2306. var _tt$getSystemInfoSync2 = tt.getSystemInfoSync().SDKVersion.split('.'),
  2307. _tt$getSystemInfoSync3 = (0, _slicedToArray2.default)(_tt$getSystemInfoSync2, 2),
  2308. _tt$getSystemInfoSync4 = _tt$getSystemInfoSync3[0],
  2309. majorVersion = _tt$getSystemInfoSync4 === void 0 ? '' : _tt$getSystemInfoSync4,
  2310. _tt$getSystemInfoSync5 = _tt$getSystemInfoSync3[1],
  2311. minorVersion = _tt$getSystemInfoSync5 === void 0 ? '' : _tt$getSystemInfoSync5;
  2312. if (parseInt(majorVersion) > 1 || parseInt(minorVersion) > 16) {
  2313. initRefs(vm);
  2314. } else {
  2315. mpInstance.selectAllComponents('.vue-ref', function (components) {
  2316. components.forEach(function (component) {
  2317. var ref = component.dataset.ref;
  2318. vm.$refs[ref] = component.$vm || toSkip(component);
  2319. });
  2320. });
  2321. mpInstance.selectAllComponents('.vue-ref-in-for', function (forComponents) {
  2322. forComponents.forEach(function (component) {
  2323. var ref = component.dataset.ref;
  2324. if (!vm.$refs[ref]) {
  2325. vm.$refs[ref] = [];
  2326. }
  2327. vm.$refs[ref].push(component.$vm || toSkip(component));
  2328. });
  2329. });
  2330. }
  2331. }
  2332. var instances = Object.create(null);
  2333. var components = Object.create(null);
  2334. function initRelation(_ref5) {
  2335. var vuePid = _ref5.vuePid,
  2336. mpInstance = _ref5.mpInstance;
  2337. // 头条 triggerEvent 后,接收事件时机特别晚,已经到了 ready 之后
  2338. var nodeId = (mpInstance.__nodeId__ || mpInstance.__nodeid__) + '';
  2339. var webviewId = mpInstance.__webviewId__ + '';
  2340. instances[webviewId + '_' + nodeId] = mpInstance.$vm;
  2341. this.triggerEvent('__l', {
  2342. vuePid: vuePid,
  2343. nodeId: nodeId,
  2344. webviewId: webviewId
  2345. });
  2346. }
  2347. function handleLink$1(_ref6) {
  2348. var _ref6$detail = _ref6.detail,
  2349. vuePid = _ref6$detail.vuePid,
  2350. nodeId = _ref6$detail.nodeId,
  2351. webviewId = _ref6$detail.webviewId;
  2352. var vm = instances[webviewId + '_' + nodeId];
  2353. if (!vm) {
  2354. return;
  2355. }
  2356. var parentVm;
  2357. if (vuePid) {
  2358. parentVm = findVmByVueId(this.$vm, vuePid);
  2359. }
  2360. if (!parentVm) {
  2361. parentVm = this.$vm;
  2362. }
  2363. vm.$parent = parentVm;
  2364. vm.$root = parentVm.$root;
  2365. parentVm.$children.push(vm);
  2366. vm.__call_hook('created');
  2367. vm.__call_hook('beforeMount');
  2368. vm._isMounted = true;
  2369. vm.__call_hook('mounted');
  2370. vm.__call_hook('onReady');
  2371. }
  2372. function parseApp(vm) {
  2373. _vue.default.prototype._$fallback = true; // 降级(调整原 vue 的部分生命周期,如 created,beforeMount,inject,provide)
  2374. _vue.default.mixin({
  2375. created: function created() {
  2376. // 处理 injections,头条 triggerEvent 是异步,且触发时机很慢,故延迟 relation 设置
  2377. if (this.mpType !== 'app') {
  2378. if (this.mpType === 'page' && !this.$scope.route && this.$scope.__route__) {
  2379. this.$scope.route = this.$scope.__route__;
  2380. }
  2381. initRefs$1(this);
  2382. this.__init_injections(this);
  2383. this.__init_provide(this);
  2384. }
  2385. }
  2386. });
  2387. return parseBaseApp(vm, {
  2388. mocks: mocks,
  2389. initRefs: function initRefs() {} // attached 时,可能查询不到
  2390. });
  2391. }
  2392. function createApp(vm) {
  2393. App(parseApp(vm));
  2394. return vm;
  2395. }
  2396. var encodeReserveRE = /[!'()*]/g;
  2397. var encodeReserveReplacer = function encodeReserveReplacer(c) {
  2398. return '%' + c.charCodeAt(0).toString(16);
  2399. };
  2400. var commaRE = /%2C/g;
  2401. // fixed encodeURIComponent which is more conformant to RFC3986:
  2402. // - escapes [!'()*]
  2403. // - preserve commas
  2404. var encode = function encode(str) {
  2405. return encodeURIComponent(str).replace(encodeReserveRE, encodeReserveReplacer).replace(commaRE, ',');
  2406. };
  2407. function stringifyQuery(obj) {
  2408. var encodeStr = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : encode;
  2409. var res = obj ? Object.keys(obj).map(function (key) {
  2410. var val = obj[key];
  2411. if (val === undefined) {
  2412. return '';
  2413. }
  2414. if (val === null) {
  2415. return encodeStr(key);
  2416. }
  2417. if (Array.isArray(val)) {
  2418. var result = [];
  2419. val.forEach(function (val2) {
  2420. if (val2 === undefined) {
  2421. return;
  2422. }
  2423. if (val2 === null) {
  2424. result.push(encodeStr(key));
  2425. } else {
  2426. result.push(encodeStr(key) + '=' + encodeStr(val2));
  2427. }
  2428. });
  2429. return result.join('&');
  2430. }
  2431. return encodeStr(key) + '=' + encodeStr(val);
  2432. }).filter(function (x) {
  2433. return x.length > 0;
  2434. }).join('&') : null;
  2435. return res ? "?".concat(res) : '';
  2436. }
  2437. function parseBaseComponent(vueComponentOptions) {
  2438. var _ref7 = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {},
  2439. isPage = _ref7.isPage,
  2440. initRelation = _ref7.initRelation;
  2441. var needVueOptions = arguments.length > 2 ? arguments[2] : undefined;
  2442. var _initVueComponent = initVueComponent(_vue.default, vueComponentOptions),
  2443. _initVueComponent2 = (0, _slicedToArray2.default)(_initVueComponent, 2),
  2444. VueComponent = _initVueComponent2[0],
  2445. vueOptions = _initVueComponent2[1];
  2446. var options = _objectSpread({
  2447. multipleSlots: true,
  2448. // styleIsolation: 'apply-shared',
  2449. addGlobalClass: true
  2450. }, vueOptions.options || {});
  2451. var componentOptions = {
  2452. options: options,
  2453. data: initData(vueOptions, _vue.default.prototype),
  2454. behaviors: initBehaviors(vueOptions, initBehavior),
  2455. properties: initProperties(vueOptions.props, false, vueOptions.__file, options),
  2456. lifetimes: {
  2457. attached: function attached() {
  2458. var properties = this.properties;
  2459. var options = {
  2460. mpType: isPage.call(this) ? 'page' : 'component',
  2461. mpInstance: this,
  2462. propsData: properties
  2463. };
  2464. initVueIds(properties.vueId, this);
  2465. // 处理父子关系
  2466. initRelation.call(this, {
  2467. vuePid: this._$vuePid,
  2468. vueOptions: options
  2469. });
  2470. // 初始化 vue 实例
  2471. this.$vm = new VueComponent(options);
  2472. // 处理$slots,$scopedSlots(暂不支持动态变化$slots)
  2473. initSlots(this.$vm, properties.vueSlots);
  2474. // 触发首次 setData
  2475. this.$vm.$mount();
  2476. },
  2477. ready: function ready() {
  2478. // 当组件 props 默认值为 true,初始化时传入 false 会导致 created,ready 触发, 但 attached 不触发
  2479. // https://developers.weixin.qq.com/community/develop/doc/00066ae2844cc0f8eb883e2a557800
  2480. if (this.$vm) {
  2481. this.$vm._isMounted = true;
  2482. this.$vm.__call_hook('mounted');
  2483. this.$vm.__call_hook('onReady');
  2484. }
  2485. },
  2486. detached: function detached() {
  2487. this.$vm && this.$vm.$destroy();
  2488. }
  2489. },
  2490. pageLifetimes: {
  2491. show: function show(args) {
  2492. this.$vm && this.$vm.__call_hook('onPageShow', args);
  2493. },
  2494. hide: function hide() {
  2495. this.$vm && this.$vm.__call_hook('onPageHide');
  2496. },
  2497. resize: function resize(size) {
  2498. this.$vm && this.$vm.__call_hook('onPageResize', size);
  2499. }
  2500. },
  2501. methods: {
  2502. __l: handleLink,
  2503. __e: handleEvent
  2504. }
  2505. };
  2506. // externalClasses
  2507. if (vueOptions.externalClasses) {
  2508. componentOptions.externalClasses = vueOptions.externalClasses;
  2509. }
  2510. if (Array.isArray(vueOptions.wxsCallMethods)) {
  2511. vueOptions.wxsCallMethods.forEach(function (callMethod) {
  2512. componentOptions.methods[callMethod] = function (args) {
  2513. return this.$vm[callMethod](args);
  2514. };
  2515. });
  2516. }
  2517. if (needVueOptions) {
  2518. return [componentOptions, vueOptions, VueComponent];
  2519. }
  2520. if (isPage) {
  2521. return componentOptions;
  2522. }
  2523. return [componentOptions, VueComponent];
  2524. }
  2525. function currentComponents(mpInstance, callback) {
  2526. var webviewId = mpInstance.__webviewId__;
  2527. var currentComponents = components[webviewId];
  2528. if (currentComponents) {
  2529. callback(currentComponents);
  2530. }
  2531. }
  2532. function parseComponent(vueComponentOptions, needVueOptions) {
  2533. var _parseBaseComponent = parseBaseComponent(vueComponentOptions, {
  2534. isPage: isPage,
  2535. initRelation: initRelation
  2536. }, true),
  2537. _parseBaseComponent2 = (0, _slicedToArray2.default)(_parseBaseComponent, 3),
  2538. componentOptions = _parseBaseComponent2[0],
  2539. vueOptions = _parseBaseComponent2[1],
  2540. VueComponent = _parseBaseComponent2[2];
  2541. var lifetimes = componentOptions.lifetimes;
  2542. // 基础库 2.0 以上 attached 顺序错乱,按照 created 顺序强制纠正
  2543. lifetimes.created = function created() {
  2544. var _this4 = this;
  2545. currentComponents(this, function (components) {
  2546. components.push(_this4);
  2547. });
  2548. };
  2549. lifetimes.attached = function attached() {
  2550. var _this5 = this;
  2551. this.__lifetimes_attached = function () {
  2552. var properties = this.properties;
  2553. var options = {
  2554. mpType: isPage.call(this) ? 'page' : 'component',
  2555. mpInstance: this,
  2556. propsData: properties
  2557. };
  2558. initVueIds(properties.vueId, this);
  2559. // 初始化 vue 实例
  2560. this.$vm = new VueComponent(options);
  2561. // 处理$slots,$scopedSlots(暂不支持动态变化$slots)
  2562. initSlots(this.$vm, properties.vueSlots);
  2563. // 处理父子关系
  2564. initRelation.call(this, {
  2565. vuePid: this._$vuePid,
  2566. mpInstance: this
  2567. });
  2568. // 触发首次 setData
  2569. this.$vm.$mount();
  2570. };
  2571. currentComponents(this, function (components) {
  2572. var component = _this5;
  2573. while (component && component.__lifetimes_attached && components[0] && component === components[0]) {
  2574. components.shift();
  2575. component.__lifetimes_attached();
  2576. delete component.__lifetimes_attached;
  2577. component = components[0];
  2578. }
  2579. });
  2580. };
  2581. var oldDetached = lifetimes.detached;
  2582. lifetimes.detached = function detached() {
  2583. var _this6 = this;
  2584. if (typeof oldDetached === 'function') {
  2585. oldDetached.call(this);
  2586. }
  2587. currentComponents(this, function (components) {
  2588. var index = components.indexOf(_this6);
  2589. if (index >= 0) {
  2590. components.splice(index, 1);
  2591. }
  2592. });
  2593. };
  2594. // ready 比 handleLink 还早,初始化逻辑放到 handleLink 中
  2595. delete lifetimes.ready;
  2596. componentOptions.methods.__l = handleLink$1;
  2597. return needVueOptions ? [componentOptions, vueOptions] : componentOptions;
  2598. }
  2599. var hooks$1 = ['onShow', 'onHide', 'onUnload'];
  2600. hooks$1.push.apply(hooks$1, PAGE_EVENT_HOOKS);
  2601. function parseBasePage(vuePageOptions) {
  2602. var _parseComponent = parseComponent(vuePageOptions, true),
  2603. _parseComponent2 = (0, _slicedToArray2.default)(_parseComponent, 2),
  2604. pageOptions = _parseComponent2[0],
  2605. vueOptions = _parseComponent2[1];
  2606. initHooks(pageOptions.methods, hooks$1, vueOptions);
  2607. pageOptions.methods.onLoad = function (query) {
  2608. this.options = query;
  2609. var copyQuery = Object.assign({}, query);
  2610. delete copyQuery.__id__;
  2611. this.$page = {
  2612. fullPath: '/' + (this.route || this.is) + stringifyQuery(copyQuery)
  2613. };
  2614. this.$vm.$mp.query = query; // 兼容 mpvue
  2615. this.$vm.__call_hook('onLoad', query);
  2616. };
  2617. {
  2618. initUnknownHooks(pageOptions.methods, vuePageOptions, ['onReady']);
  2619. }
  2620. return pageOptions;
  2621. }
  2622. function parsePage(vuePageOptions) {
  2623. var pageOptions = parseBasePage(vuePageOptions);
  2624. var lifetimes = pageOptions.lifetimes;
  2625. var oldCreated = lifetimes.created;
  2626. lifetimes.created = function created() {
  2627. var webviewId = this.__webviewId__;
  2628. components[webviewId] = [];
  2629. if (typeof oldCreated === 'function') {
  2630. oldCreated.call(this);
  2631. }
  2632. };
  2633. // 页面需要在 ready 中触发,其他组件是在 handleLink 中触发
  2634. lifetimes.ready = function ready() {
  2635. if (this.$vm && this.$vm.mpType === 'page') {
  2636. this.$vm.__call_hook('created');
  2637. this.$vm.__call_hook('beforeMount');
  2638. this.$vm._isMounted = true;
  2639. this.$vm.__call_hook('mounted');
  2640. this.$vm.__call_hook('onReady');
  2641. } else {
  2642. this.is && console.warn(this.is + ' is not ready');
  2643. }
  2644. };
  2645. var oldDetached = lifetimes.detached;
  2646. lifetimes.detached = function detached() {
  2647. if (typeof oldDetached === 'function') {
  2648. oldDetached.call(this);
  2649. }
  2650. // 清理
  2651. var webviewId = this.__webviewId__;
  2652. webviewId && Object.keys(instances).forEach(function (key) {
  2653. if (key.indexOf(webviewId + '_') === 0) {
  2654. delete instances[key];
  2655. }
  2656. });
  2657. delete components[webviewId];
  2658. };
  2659. return pageOptions;
  2660. }
  2661. function createPage(vuePageOptions) {
  2662. {
  2663. return Component(parsePage(vuePageOptions));
  2664. }
  2665. }
  2666. function createComponent(vueOptions) {
  2667. {
  2668. return Component(parseComponent(vueOptions));
  2669. }
  2670. }
  2671. function createSubpackageApp(vm) {
  2672. var appOptions = parseApp(vm);
  2673. var app = getApp({
  2674. allowDefault: true
  2675. });
  2676. vm.$scope = app;
  2677. var globalData = app.globalData;
  2678. if (globalData) {
  2679. Object.keys(appOptions.globalData).forEach(function (name) {
  2680. if (!hasOwn(globalData, name)) {
  2681. globalData[name] = appOptions.globalData[name];
  2682. }
  2683. });
  2684. }
  2685. Object.keys(appOptions).forEach(function (name) {
  2686. if (!hasOwn(app, name)) {
  2687. app[name] = appOptions[name];
  2688. }
  2689. });
  2690. if (isFn(appOptions.onShow) && tt.onAppShow) {
  2691. tt.onAppShow(function () {
  2692. for (var _len7 = arguments.length, args = new Array(_len7), _key7 = 0; _key7 < _len7; _key7++) {
  2693. args[_key7] = arguments[_key7];
  2694. }
  2695. vm.__call_hook('onShow', args);
  2696. });
  2697. }
  2698. if (isFn(appOptions.onHide) && tt.onAppHide) {
  2699. tt.onAppHide(function () {
  2700. for (var _len8 = arguments.length, args = new Array(_len8), _key8 = 0; _key8 < _len8; _key8++) {
  2701. args[_key8] = arguments[_key8];
  2702. }
  2703. vm.__call_hook('onHide', args);
  2704. });
  2705. }
  2706. if (isFn(appOptions.onLaunch)) {
  2707. var args = tt.getLaunchOptionsSync && tt.getLaunchOptionsSync();
  2708. vm.__call_hook('onLaunch', args);
  2709. }
  2710. return vm;
  2711. }
  2712. function createPlugin(vm) {
  2713. var appOptions = parseApp(vm);
  2714. if (isFn(appOptions.onShow) && tt.onAppShow) {
  2715. tt.onAppShow(function () {
  2716. for (var _len9 = arguments.length, args = new Array(_len9), _key9 = 0; _key9 < _len9; _key9++) {
  2717. args[_key9] = arguments[_key9];
  2718. }
  2719. vm.__call_hook('onShow', args);
  2720. });
  2721. }
  2722. if (isFn(appOptions.onHide) && tt.onAppHide) {
  2723. tt.onAppHide(function () {
  2724. for (var _len10 = arguments.length, args = new Array(_len10), _key10 = 0; _key10 < _len10; _key10++) {
  2725. args[_key10] = arguments[_key10];
  2726. }
  2727. vm.__call_hook('onHide', args);
  2728. });
  2729. }
  2730. if (isFn(appOptions.onLaunch)) {
  2731. var args = tt.getLaunchOptionsSync && tt.getLaunchOptionsSync();
  2732. vm.__call_hook('onLaunch', args);
  2733. }
  2734. return vm;
  2735. }
  2736. todos.forEach(function (todoApi) {
  2737. protocols[todoApi] = false;
  2738. });
  2739. canIUses.forEach(function (canIUseApi) {
  2740. var apiName = protocols[canIUseApi] && protocols[canIUseApi].name ? protocols[canIUseApi].name : canIUseApi;
  2741. if (!tt.canIUse(apiName)) {
  2742. protocols[canIUseApi] = false;
  2743. }
  2744. });
  2745. var uni = {};
  2746. if (typeof Proxy !== 'undefined' && "mp-toutiao" !== 'app-plus') {
  2747. uni = new Proxy({}, {
  2748. get: function get(target, name) {
  2749. if (hasOwn(target, name)) {
  2750. return target[name];
  2751. }
  2752. if (baseApi[name]) {
  2753. return baseApi[name];
  2754. }
  2755. if (api[name]) {
  2756. return promisify(name, api[name]);
  2757. }
  2758. {
  2759. if (extraApi[name]) {
  2760. return promisify(name, extraApi[name]);
  2761. }
  2762. if (todoApis[name]) {
  2763. return promisify(name, todoApis[name]);
  2764. }
  2765. }
  2766. if (eventApi[name]) {
  2767. return eventApi[name];
  2768. }
  2769. return promisify(name, wrapper(name, tt[name]));
  2770. },
  2771. set: function set(target, name, value) {
  2772. target[name] = value;
  2773. return true;
  2774. }
  2775. });
  2776. } else {
  2777. Object.keys(baseApi).forEach(function (name) {
  2778. uni[name] = baseApi[name];
  2779. });
  2780. {
  2781. Object.keys(todoApis).forEach(function (name) {
  2782. uni[name] = promisify(name, todoApis[name]);
  2783. });
  2784. Object.keys(extraApi).forEach(function (name) {
  2785. uni[name] = promisify(name, extraApi[name]);
  2786. });
  2787. }
  2788. Object.keys(eventApi).forEach(function (name) {
  2789. uni[name] = eventApi[name];
  2790. });
  2791. Object.keys(api).forEach(function (name) {
  2792. uni[name] = promisify(name, api[name]);
  2793. });
  2794. Object.keys(tt).forEach(function (name) {
  2795. if (hasOwn(tt, name) || hasOwn(protocols, name)) {
  2796. uni[name] = promisify(name, wrapper(name, tt[name]));
  2797. }
  2798. });
  2799. }
  2800. tt.createApp = createApp;
  2801. tt.createPage = createPage;
  2802. tt.createComponent = createComponent;
  2803. tt.createSubpackageApp = createSubpackageApp;
  2804. tt.createPlugin = createPlugin;
  2805. var uni$1 = uni;
  2806. var _default = uni$1;
  2807. exports.default = _default;
  2808. /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./../../../webpack/buildin/global.js */ 2)))
  2809. /***/ }),
  2810. /* 2 */
  2811. /*!***********************************!*\
  2812. !*** (webpack)/buildin/global.js ***!
  2813. \***********************************/
  2814. /*! no static exports found */
  2815. /***/ (function(module, exports) {
  2816. var g;
  2817. // This works in non-strict mode
  2818. g = (function() {
  2819. return this;
  2820. })();
  2821. try {
  2822. // This works if eval is allowed (see CSP)
  2823. g = g || new Function("return this")();
  2824. } catch (e) {
  2825. // This works if the window reference is available
  2826. if (typeof window === "object") g = window;
  2827. }
  2828. // g can still be undefined, but nothing to do about it...
  2829. // We return undefined, instead of nothing here, so it's
  2830. // easier to handle this case. if(!global) { ...}
  2831. module.exports = g;
  2832. /***/ }),
  2833. /* 3 */
  2834. /*!**********************************************************************!*\
  2835. !*** ./node_modules/@babel/runtime/helpers/interopRequireDefault.js ***!
  2836. \**********************************************************************/
  2837. /*! no static exports found */
  2838. /***/ (function(module, exports) {
  2839. function _interopRequireDefault(obj) {
  2840. return obj && obj.__esModule ? obj : {
  2841. "default": obj
  2842. };
  2843. }
  2844. module.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports["default"] = module.exports;
  2845. /***/ }),
  2846. /* 4 */
  2847. /*!**************************************************************!*\
  2848. !*** ./node_modules/@babel/runtime/helpers/slicedToArray.js ***!
  2849. \**************************************************************/
  2850. /*! no static exports found */
  2851. /***/ (function(module, exports, __webpack_require__) {
  2852. var arrayWithHoles = __webpack_require__(/*! ./arrayWithHoles.js */ 5);
  2853. var iterableToArrayLimit = __webpack_require__(/*! ./iterableToArrayLimit.js */ 6);
  2854. var unsupportedIterableToArray = __webpack_require__(/*! ./unsupportedIterableToArray.js */ 7);
  2855. var nonIterableRest = __webpack_require__(/*! ./nonIterableRest.js */ 9);
  2856. function _slicedToArray(arr, i) {
  2857. return arrayWithHoles(arr) || iterableToArrayLimit(arr, i) || unsupportedIterableToArray(arr, i) || nonIterableRest();
  2858. }
  2859. module.exports = _slicedToArray, module.exports.__esModule = true, module.exports["default"] = module.exports;
  2860. /***/ }),
  2861. /* 5 */
  2862. /*!***************************************************************!*\
  2863. !*** ./node_modules/@babel/runtime/helpers/arrayWithHoles.js ***!
  2864. \***************************************************************/
  2865. /*! no static exports found */
  2866. /***/ (function(module, exports) {
  2867. function _arrayWithHoles(arr) {
  2868. if (Array.isArray(arr)) return arr;
  2869. }
  2870. module.exports = _arrayWithHoles, module.exports.__esModule = true, module.exports["default"] = module.exports;
  2871. /***/ }),
  2872. /* 6 */
  2873. /*!*********************************************************************!*\
  2874. !*** ./node_modules/@babel/runtime/helpers/iterableToArrayLimit.js ***!
  2875. \*********************************************************************/
  2876. /*! no static exports found */
  2877. /***/ (function(module, exports) {
  2878. function _iterableToArrayLimit(r, l) {
  2879. var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"];
  2880. if (null != t) {
  2881. var e,
  2882. n,
  2883. i,
  2884. u,
  2885. a = [],
  2886. f = !0,
  2887. o = !1;
  2888. try {
  2889. if (i = (t = t.call(r)).next, 0 === l) {
  2890. if (Object(t) !== t) return;
  2891. f = !1;
  2892. } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0) {
  2893. ;
  2894. }
  2895. } catch (r) {
  2896. o = !0, n = r;
  2897. } finally {
  2898. try {
  2899. if (!f && null != t["return"] && (u = t["return"](), Object(u) !== u)) return;
  2900. } finally {
  2901. if (o) throw n;
  2902. }
  2903. }
  2904. return a;
  2905. }
  2906. }
  2907. module.exports = _iterableToArrayLimit, module.exports.__esModule = true, module.exports["default"] = module.exports;
  2908. /***/ }),
  2909. /* 7 */
  2910. /*!***************************************************************************!*\
  2911. !*** ./node_modules/@babel/runtime/helpers/unsupportedIterableToArray.js ***!
  2912. \***************************************************************************/
  2913. /*! no static exports found */
  2914. /***/ (function(module, exports, __webpack_require__) {
  2915. var arrayLikeToArray = __webpack_require__(/*! ./arrayLikeToArray.js */ 8);
  2916. function _unsupportedIterableToArray(o, minLen) {
  2917. if (!o) return;
  2918. if (typeof o === "string") return arrayLikeToArray(o, minLen);
  2919. var n = Object.prototype.toString.call(o).slice(8, -1);
  2920. if (n === "Object" && o.constructor) n = o.constructor.name;
  2921. if (n === "Map" || n === "Set") return Array.from(o);
  2922. if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return arrayLikeToArray(o, minLen);
  2923. }
  2924. module.exports = _unsupportedIterableToArray, module.exports.__esModule = true, module.exports["default"] = module.exports;
  2925. /***/ }),
  2926. /* 8 */
  2927. /*!*****************************************************************!*\
  2928. !*** ./node_modules/@babel/runtime/helpers/arrayLikeToArray.js ***!
  2929. \*****************************************************************/
  2930. /*! no static exports found */
  2931. /***/ (function(module, exports) {
  2932. function _arrayLikeToArray(arr, len) {
  2933. if (len == null || len > arr.length) len = arr.length;
  2934. for (var i = 0, arr2 = new Array(len); i < len; i++) {
  2935. arr2[i] = arr[i];
  2936. }
  2937. return arr2;
  2938. }
  2939. module.exports = _arrayLikeToArray, module.exports.__esModule = true, module.exports["default"] = module.exports;
  2940. /***/ }),
  2941. /* 9 */
  2942. /*!****************************************************************!*\
  2943. !*** ./node_modules/@babel/runtime/helpers/nonIterableRest.js ***!
  2944. \****************************************************************/
  2945. /*! no static exports found */
  2946. /***/ (function(module, exports) {
  2947. function _nonIterableRest() {
  2948. throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
  2949. }
  2950. module.exports = _nonIterableRest, module.exports.__esModule = true, module.exports["default"] = module.exports;
  2951. /***/ }),
  2952. /* 10 */
  2953. /*!***************************************************************!*\
  2954. !*** ./node_modules/@babel/runtime/helpers/defineProperty.js ***!
  2955. \***************************************************************/
  2956. /*! no static exports found */
  2957. /***/ (function(module, exports, __webpack_require__) {
  2958. var toPropertyKey = __webpack_require__(/*! ./toPropertyKey.js */ 11);
  2959. function _defineProperty(obj, key, value) {
  2960. key = toPropertyKey(key);
  2961. if (key in obj) {
  2962. Object.defineProperty(obj, key, {
  2963. value: value,
  2964. enumerable: true,
  2965. configurable: true,
  2966. writable: true
  2967. });
  2968. } else {
  2969. obj[key] = value;
  2970. }
  2971. return obj;
  2972. }
  2973. module.exports = _defineProperty, module.exports.__esModule = true, module.exports["default"] = module.exports;
  2974. /***/ }),
  2975. /* 11 */
  2976. /*!**************************************************************!*\
  2977. !*** ./node_modules/@babel/runtime/helpers/toPropertyKey.js ***!
  2978. \**************************************************************/
  2979. /*! no static exports found */
  2980. /***/ (function(module, exports, __webpack_require__) {
  2981. var _typeof = __webpack_require__(/*! ./typeof.js */ 12)["default"];
  2982. var toPrimitive = __webpack_require__(/*! ./toPrimitive.js */ 13);
  2983. function toPropertyKey(t) {
  2984. var i = toPrimitive(t, "string");
  2985. return "symbol" == _typeof(i) ? i : i + "";
  2986. }
  2987. module.exports = toPropertyKey, module.exports.__esModule = true, module.exports["default"] = module.exports;
  2988. /***/ }),
  2989. /* 12 */
  2990. /*!*******************************************************!*\
  2991. !*** ./node_modules/@babel/runtime/helpers/typeof.js ***!
  2992. \*******************************************************/
  2993. /*! no static exports found */
  2994. /***/ (function(module, exports) {
  2995. function _typeof(o) {
  2996. "@babel/helpers - typeof";
  2997. return (module.exports = _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) {
  2998. return typeof o;
  2999. } : function (o) {
  3000. return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o;
  3001. }, module.exports.__esModule = true, module.exports["default"] = module.exports), _typeof(o);
  3002. }
  3003. module.exports = _typeof, module.exports.__esModule = true, module.exports["default"] = module.exports;
  3004. /***/ }),
  3005. /* 13 */
  3006. /*!************************************************************!*\
  3007. !*** ./node_modules/@babel/runtime/helpers/toPrimitive.js ***!
  3008. \************************************************************/
  3009. /*! no static exports found */
  3010. /***/ (function(module, exports, __webpack_require__) {
  3011. var _typeof = __webpack_require__(/*! ./typeof.js */ 12)["default"];
  3012. function toPrimitive(t, r) {
  3013. if ("object" != _typeof(t) || !t) return t;
  3014. var e = t[Symbol.toPrimitive];
  3015. if (void 0 !== e) {
  3016. var i = e.call(t, r || "default");
  3017. if ("object" != _typeof(i)) return i;
  3018. throw new TypeError("@@toPrimitive must return a primitive value.");
  3019. }
  3020. return ("string" === r ? String : Number)(t);
  3021. }
  3022. module.exports = toPrimitive, module.exports.__esModule = true, module.exports["default"] = module.exports;
  3023. /***/ }),
  3024. /* 14 */
  3025. /*!**********************************************************!*\
  3026. !*** ./node_modules/@babel/runtime/helpers/construct.js ***!
  3027. \**********************************************************/
  3028. /*! no static exports found */
  3029. /***/ (function(module, exports, __webpack_require__) {
  3030. var setPrototypeOf = __webpack_require__(/*! ./setPrototypeOf.js */ 15);
  3031. var isNativeReflectConstruct = __webpack_require__(/*! ./isNativeReflectConstruct.js */ 16);
  3032. function _construct(t, e, r) {
  3033. if (isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments);
  3034. var o = [null];
  3035. o.push.apply(o, e);
  3036. var p = new (t.bind.apply(t, o))();
  3037. return r && setPrototypeOf(p, r.prototype), p;
  3038. }
  3039. module.exports = _construct, module.exports.__esModule = true, module.exports["default"] = module.exports;
  3040. /***/ }),
  3041. /* 15 */
  3042. /*!***************************************************************!*\
  3043. !*** ./node_modules/@babel/runtime/helpers/setPrototypeOf.js ***!
  3044. \***************************************************************/
  3045. /*! no static exports found */
  3046. /***/ (function(module, exports) {
  3047. function _setPrototypeOf(o, p) {
  3048. module.exports = _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {
  3049. o.__proto__ = p;
  3050. return o;
  3051. }, module.exports.__esModule = true, module.exports["default"] = module.exports;
  3052. return _setPrototypeOf(o, p);
  3053. }
  3054. module.exports = _setPrototypeOf, module.exports.__esModule = true, module.exports["default"] = module.exports;
  3055. /***/ }),
  3056. /* 16 */
  3057. /*!*************************************************************************!*\
  3058. !*** ./node_modules/@babel/runtime/helpers/isNativeReflectConstruct.js ***!
  3059. \*************************************************************************/
  3060. /*! no static exports found */
  3061. /***/ (function(module, exports) {
  3062. function _isNativeReflectConstruct() {
  3063. try {
  3064. var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {}));
  3065. } catch (t) {}
  3066. return (module.exports = _isNativeReflectConstruct = function _isNativeReflectConstruct() {
  3067. return !!t;
  3068. }, module.exports.__esModule = true, module.exports["default"] = module.exports)();
  3069. }
  3070. module.exports = _isNativeReflectConstruct, module.exports.__esModule = true, module.exports["default"] = module.exports;
  3071. /***/ }),
  3072. /* 17 */
  3073. /*!***************************************************************!*\
  3074. !*** ./node_modules/@babel/runtime/helpers/classCallCheck.js ***!
  3075. \***************************************************************/
  3076. /*! no static exports found */
  3077. /***/ (function(module, exports) {
  3078. function _classCallCheck(instance, Constructor) {
  3079. if (!(instance instanceof Constructor)) {
  3080. throw new TypeError("Cannot call a class as a function");
  3081. }
  3082. }
  3083. module.exports = _classCallCheck, module.exports.__esModule = true, module.exports["default"] = module.exports;
  3084. /***/ }),
  3085. /* 18 */
  3086. /*!************************************************************!*\
  3087. !*** ./node_modules/@babel/runtime/helpers/createClass.js ***!
  3088. \************************************************************/
  3089. /*! no static exports found */
  3090. /***/ (function(module, exports, __webpack_require__) {
  3091. var toPropertyKey = __webpack_require__(/*! ./toPropertyKey.js */ 11);
  3092. function _defineProperties(target, props) {
  3093. for (var i = 0; i < props.length; i++) {
  3094. var descriptor = props[i];
  3095. descriptor.enumerable = descriptor.enumerable || false;
  3096. descriptor.configurable = true;
  3097. if ("value" in descriptor) descriptor.writable = true;
  3098. Object.defineProperty(target, toPropertyKey(descriptor.key), descriptor);
  3099. }
  3100. }
  3101. function _createClass(Constructor, protoProps, staticProps) {
  3102. if (protoProps) _defineProperties(Constructor.prototype, protoProps);
  3103. if (staticProps) _defineProperties(Constructor, staticProps);
  3104. Object.defineProperty(Constructor, "prototype", {
  3105. writable: false
  3106. });
  3107. return Constructor;
  3108. }
  3109. module.exports = _createClass, module.exports.__esModule = true, module.exports["default"] = module.exports;
  3110. /***/ }),
  3111. /* 19 */
  3112. /*!******************************************************************!*\
  3113. !*** ./node_modules/@babel/runtime/helpers/toConsumableArray.js ***!
  3114. \******************************************************************/
  3115. /*! no static exports found */
  3116. /***/ (function(module, exports, __webpack_require__) {
  3117. var arrayWithoutHoles = __webpack_require__(/*! ./arrayWithoutHoles.js */ 20);
  3118. var iterableToArray = __webpack_require__(/*! ./iterableToArray.js */ 21);
  3119. var unsupportedIterableToArray = __webpack_require__(/*! ./unsupportedIterableToArray.js */ 7);
  3120. var nonIterableSpread = __webpack_require__(/*! ./nonIterableSpread.js */ 22);
  3121. function _toConsumableArray(arr) {
  3122. return arrayWithoutHoles(arr) || iterableToArray(arr) || unsupportedIterableToArray(arr) || nonIterableSpread();
  3123. }
  3124. module.exports = _toConsumableArray, module.exports.__esModule = true, module.exports["default"] = module.exports;
  3125. /***/ }),
  3126. /* 20 */
  3127. /*!******************************************************************!*\
  3128. !*** ./node_modules/@babel/runtime/helpers/arrayWithoutHoles.js ***!
  3129. \******************************************************************/
  3130. /*! no static exports found */
  3131. /***/ (function(module, exports, __webpack_require__) {
  3132. var arrayLikeToArray = __webpack_require__(/*! ./arrayLikeToArray.js */ 8);
  3133. function _arrayWithoutHoles(arr) {
  3134. if (Array.isArray(arr)) return arrayLikeToArray(arr);
  3135. }
  3136. module.exports = _arrayWithoutHoles, module.exports.__esModule = true, module.exports["default"] = module.exports;
  3137. /***/ }),
  3138. /* 21 */
  3139. /*!****************************************************************!*\
  3140. !*** ./node_modules/@babel/runtime/helpers/iterableToArray.js ***!
  3141. \****************************************************************/
  3142. /*! no static exports found */
  3143. /***/ (function(module, exports) {
  3144. function _iterableToArray(iter) {
  3145. if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter);
  3146. }
  3147. module.exports = _iterableToArray, module.exports.__esModule = true, module.exports["default"] = module.exports;
  3148. /***/ }),
  3149. /* 22 */
  3150. /*!******************************************************************!*\
  3151. !*** ./node_modules/@babel/runtime/helpers/nonIterableSpread.js ***!
  3152. \******************************************************************/
  3153. /*! no static exports found */
  3154. /***/ (function(module, exports) {
  3155. function _nonIterableSpread() {
  3156. throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
  3157. }
  3158. module.exports = _nonIterableSpread, module.exports.__esModule = true, module.exports["default"] = module.exports;
  3159. /***/ }),
  3160. /* 23 */
  3161. /*!*************************************************************!*\
  3162. !*** ./node_modules/@dcloudio/uni-i18n/dist/uni-i18n.es.js ***!
  3163. \*************************************************************/
  3164. /*! no static exports found */
  3165. /***/ (function(module, exports, __webpack_require__) {
  3166. "use strict";
  3167. /* WEBPACK VAR INJECTION */(function(uni, global) {
  3168. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  3169. Object.defineProperty(exports, "__esModule", {
  3170. value: true
  3171. });
  3172. exports.LOCALE_ZH_HANT = exports.LOCALE_ZH_HANS = exports.LOCALE_FR = exports.LOCALE_ES = exports.LOCALE_EN = exports.I18n = exports.Formatter = void 0;
  3173. exports.compileI18nJsonStr = compileI18nJsonStr;
  3174. exports.hasI18nJson = hasI18nJson;
  3175. exports.initVueI18n = initVueI18n;
  3176. exports.isI18nStr = isI18nStr;
  3177. exports.isString = void 0;
  3178. exports.normalizeLocale = normalizeLocale;
  3179. exports.parseI18nJson = parseI18nJson;
  3180. exports.resolveLocale = resolveLocale;
  3181. var _slicedToArray2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/slicedToArray */ 4));
  3182. var _classCallCheck2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/classCallCheck */ 17));
  3183. var _createClass2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/createClass */ 18));
  3184. var _typeof2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/typeof */ 12));
  3185. var isObject = function isObject(val) {
  3186. return val !== null && (0, _typeof2.default)(val) === 'object';
  3187. };
  3188. var defaultDelimiters = ['{', '}'];
  3189. var BaseFormatter = /*#__PURE__*/function () {
  3190. function BaseFormatter() {
  3191. (0, _classCallCheck2.default)(this, BaseFormatter);
  3192. this._caches = Object.create(null);
  3193. }
  3194. (0, _createClass2.default)(BaseFormatter, [{
  3195. key: "interpolate",
  3196. value: function interpolate(message, values) {
  3197. var delimiters = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : defaultDelimiters;
  3198. if (!values) {
  3199. return [message];
  3200. }
  3201. var tokens = this._caches[message];
  3202. if (!tokens) {
  3203. tokens = parse(message, delimiters);
  3204. this._caches[message] = tokens;
  3205. }
  3206. return compile(tokens, values);
  3207. }
  3208. }]);
  3209. return BaseFormatter;
  3210. }();
  3211. exports.Formatter = BaseFormatter;
  3212. var RE_TOKEN_LIST_VALUE = /^(?:\d)+/;
  3213. var RE_TOKEN_NAMED_VALUE = /^(?:\w)+/;
  3214. function parse(format, _ref) {
  3215. var _ref2 = (0, _slicedToArray2.default)(_ref, 2),
  3216. startDelimiter = _ref2[0],
  3217. endDelimiter = _ref2[1];
  3218. var tokens = [];
  3219. var position = 0;
  3220. var text = '';
  3221. while (position < format.length) {
  3222. var char = format[position++];
  3223. if (char === startDelimiter) {
  3224. if (text) {
  3225. tokens.push({
  3226. type: 'text',
  3227. value: text
  3228. });
  3229. }
  3230. text = '';
  3231. var sub = '';
  3232. char = format[position++];
  3233. while (char !== undefined && char !== endDelimiter) {
  3234. sub += char;
  3235. char = format[position++];
  3236. }
  3237. var isClosed = char === endDelimiter;
  3238. var type = RE_TOKEN_LIST_VALUE.test(sub) ? 'list' : isClosed && RE_TOKEN_NAMED_VALUE.test(sub) ? 'named' : 'unknown';
  3239. tokens.push({
  3240. value: sub,
  3241. type: type
  3242. });
  3243. }
  3244. // else if (char === '%') {
  3245. // // when found rails i18n syntax, skip text capture
  3246. // if (format[position] !== '{') {
  3247. // text += char
  3248. // }
  3249. // }
  3250. else {
  3251. text += char;
  3252. }
  3253. }
  3254. text && tokens.push({
  3255. type: 'text',
  3256. value: text
  3257. });
  3258. return tokens;
  3259. }
  3260. function compile(tokens, values) {
  3261. var compiled = [];
  3262. var index = 0;
  3263. var mode = Array.isArray(values) ? 'list' : isObject(values) ? 'named' : 'unknown';
  3264. if (mode === 'unknown') {
  3265. return compiled;
  3266. }
  3267. while (index < tokens.length) {
  3268. var token = tokens[index];
  3269. switch (token.type) {
  3270. case 'text':
  3271. compiled.push(token.value);
  3272. break;
  3273. case 'list':
  3274. compiled.push(values[parseInt(token.value, 10)]);
  3275. break;
  3276. case 'named':
  3277. if (mode === 'named') {
  3278. compiled.push(values[token.value]);
  3279. } else {
  3280. if (true) {
  3281. console.warn("Type of token '".concat(token.type, "' and format of value '").concat(mode, "' don't match!"));
  3282. }
  3283. }
  3284. break;
  3285. case 'unknown':
  3286. if (true) {
  3287. console.warn("Detect 'unknown' type of token!");
  3288. }
  3289. break;
  3290. }
  3291. index++;
  3292. }
  3293. return compiled;
  3294. }
  3295. var LOCALE_ZH_HANS = 'zh-Hans';
  3296. exports.LOCALE_ZH_HANS = LOCALE_ZH_HANS;
  3297. var LOCALE_ZH_HANT = 'zh-Hant';
  3298. exports.LOCALE_ZH_HANT = LOCALE_ZH_HANT;
  3299. var LOCALE_EN = 'en';
  3300. exports.LOCALE_EN = LOCALE_EN;
  3301. var LOCALE_FR = 'fr';
  3302. exports.LOCALE_FR = LOCALE_FR;
  3303. var LOCALE_ES = 'es';
  3304. exports.LOCALE_ES = LOCALE_ES;
  3305. var hasOwnProperty = Object.prototype.hasOwnProperty;
  3306. var hasOwn = function hasOwn(val, key) {
  3307. return hasOwnProperty.call(val, key);
  3308. };
  3309. var defaultFormatter = new BaseFormatter();
  3310. function include(str, parts) {
  3311. return !!parts.find(function (part) {
  3312. return str.indexOf(part) !== -1;
  3313. });
  3314. }
  3315. function startsWith(str, parts) {
  3316. return parts.find(function (part) {
  3317. return str.indexOf(part) === 0;
  3318. });
  3319. }
  3320. function normalizeLocale(locale, messages) {
  3321. if (!locale) {
  3322. return;
  3323. }
  3324. locale = locale.trim().replace(/_/g, '-');
  3325. if (messages && messages[locale]) {
  3326. return locale;
  3327. }
  3328. locale = locale.toLowerCase();
  3329. if (locale === 'chinese') {
  3330. // 支付宝
  3331. return LOCALE_ZH_HANS;
  3332. }
  3333. if (locale.indexOf('zh') === 0) {
  3334. if (locale.indexOf('-hans') > -1) {
  3335. return LOCALE_ZH_HANS;
  3336. }
  3337. if (locale.indexOf('-hant') > -1) {
  3338. return LOCALE_ZH_HANT;
  3339. }
  3340. if (include(locale, ['-tw', '-hk', '-mo', '-cht'])) {
  3341. return LOCALE_ZH_HANT;
  3342. }
  3343. return LOCALE_ZH_HANS;
  3344. }
  3345. var locales = [LOCALE_EN, LOCALE_FR, LOCALE_ES];
  3346. if (messages && Object.keys(messages).length > 0) {
  3347. locales = Object.keys(messages);
  3348. }
  3349. var lang = startsWith(locale, locales);
  3350. if (lang) {
  3351. return lang;
  3352. }
  3353. }
  3354. var I18n = /*#__PURE__*/function () {
  3355. function I18n(_ref3) {
  3356. var locale = _ref3.locale,
  3357. fallbackLocale = _ref3.fallbackLocale,
  3358. messages = _ref3.messages,
  3359. watcher = _ref3.watcher,
  3360. formater = _ref3.formater;
  3361. (0, _classCallCheck2.default)(this, I18n);
  3362. this.locale = LOCALE_EN;
  3363. this.fallbackLocale = LOCALE_EN;
  3364. this.message = {};
  3365. this.messages = {};
  3366. this.watchers = [];
  3367. if (fallbackLocale) {
  3368. this.fallbackLocale = fallbackLocale;
  3369. }
  3370. this.formater = formater || defaultFormatter;
  3371. this.messages = messages || {};
  3372. this.setLocale(locale || LOCALE_EN);
  3373. if (watcher) {
  3374. this.watchLocale(watcher);
  3375. }
  3376. }
  3377. (0, _createClass2.default)(I18n, [{
  3378. key: "setLocale",
  3379. value: function setLocale(locale) {
  3380. var _this = this;
  3381. var oldLocale = this.locale;
  3382. this.locale = normalizeLocale(locale, this.messages) || this.fallbackLocale;
  3383. if (!this.messages[this.locale]) {
  3384. // 可能初始化时不存在
  3385. this.messages[this.locale] = {};
  3386. }
  3387. this.message = this.messages[this.locale];
  3388. // 仅发生变化时,通知
  3389. if (oldLocale !== this.locale) {
  3390. this.watchers.forEach(function (watcher) {
  3391. watcher(_this.locale, oldLocale);
  3392. });
  3393. }
  3394. }
  3395. }, {
  3396. key: "getLocale",
  3397. value: function getLocale() {
  3398. return this.locale;
  3399. }
  3400. }, {
  3401. key: "watchLocale",
  3402. value: function watchLocale(fn) {
  3403. var _this2 = this;
  3404. var index = this.watchers.push(fn) - 1;
  3405. return function () {
  3406. _this2.watchers.splice(index, 1);
  3407. };
  3408. }
  3409. }, {
  3410. key: "add",
  3411. value: function add(locale, message) {
  3412. var override = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : true;
  3413. var curMessages = this.messages[locale];
  3414. if (curMessages) {
  3415. if (override) {
  3416. Object.assign(curMessages, message);
  3417. } else {
  3418. Object.keys(message).forEach(function (key) {
  3419. if (!hasOwn(curMessages, key)) {
  3420. curMessages[key] = message[key];
  3421. }
  3422. });
  3423. }
  3424. } else {
  3425. this.messages[locale] = message;
  3426. }
  3427. }
  3428. }, {
  3429. key: "f",
  3430. value: function f(message, values, delimiters) {
  3431. return this.formater.interpolate(message, values, delimiters).join('');
  3432. }
  3433. }, {
  3434. key: "t",
  3435. value: function t(key, locale, values) {
  3436. var message = this.message;
  3437. if (typeof locale === 'string') {
  3438. locale = normalizeLocale(locale, this.messages);
  3439. locale && (message = this.messages[locale]);
  3440. } else {
  3441. values = locale;
  3442. }
  3443. if (!hasOwn(message, key)) {
  3444. console.warn("Cannot translate the value of keypath ".concat(key, ". Use the value of keypath as default."));
  3445. return key;
  3446. }
  3447. return this.formater.interpolate(message[key], values).join('');
  3448. }
  3449. }]);
  3450. return I18n;
  3451. }();
  3452. exports.I18n = I18n;
  3453. function watchAppLocale(appVm, i18n) {
  3454. // 需要保证 watch 的触发在组件渲染之前
  3455. if (appVm.$watchLocale) {
  3456. // vue2
  3457. appVm.$watchLocale(function (newLocale) {
  3458. i18n.setLocale(newLocale);
  3459. });
  3460. } else {
  3461. appVm.$watch(function () {
  3462. return appVm.$locale;
  3463. }, function (newLocale) {
  3464. i18n.setLocale(newLocale);
  3465. });
  3466. }
  3467. }
  3468. function getDefaultLocale() {
  3469. if (typeof uni !== 'undefined' && uni.getLocale) {
  3470. return uni.getLocale();
  3471. }
  3472. // 小程序平台,uni 和 uni-i18n 互相引用,导致访问不到 uni,故在 global 上挂了 getLocale
  3473. if (typeof global !== 'undefined' && global.getLocale) {
  3474. return global.getLocale();
  3475. }
  3476. return LOCALE_EN;
  3477. }
  3478. function initVueI18n(locale) {
  3479. var messages = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
  3480. var fallbackLocale = arguments.length > 2 ? arguments[2] : undefined;
  3481. var watcher = arguments.length > 3 ? arguments[3] : undefined;
  3482. // 兼容旧版本入参
  3483. if (typeof locale !== 'string') {
  3484. var _ref4 = [messages, locale];
  3485. locale = _ref4[0];
  3486. messages = _ref4[1];
  3487. }
  3488. if (typeof locale !== 'string') {
  3489. // 因为小程序平台,uni-i18n 和 uni 互相引用,导致此时访问 uni 时,为 undefined
  3490. locale = getDefaultLocale();
  3491. }
  3492. if (typeof fallbackLocale !== 'string') {
  3493. fallbackLocale = typeof __uniConfig !== 'undefined' && __uniConfig.fallbackLocale || LOCALE_EN;
  3494. }
  3495. var i18n = new I18n({
  3496. locale: locale,
  3497. fallbackLocale: fallbackLocale,
  3498. messages: messages,
  3499. watcher: watcher
  3500. });
  3501. var _t = function t(key, values) {
  3502. if (typeof getApp !== 'function') {
  3503. // app view
  3504. /* eslint-disable no-func-assign */
  3505. _t = function t(key, values) {
  3506. return i18n.t(key, values);
  3507. };
  3508. } else {
  3509. var isWatchedAppLocale = false;
  3510. _t = function t(key, values) {
  3511. var appVm = getApp().$vm;
  3512. // 可能$vm还不存在,比如在支付宝小程序中,组件定义较早,在props的default里使用了t()函数(如uni-goods-nav),此时app还未初始化
  3513. // options: {
  3514. // type: Array,
  3515. // default () {
  3516. // return [{
  3517. // icon: 'shop',
  3518. // text: t("uni-goods-nav.options.shop"),
  3519. // }, {
  3520. // icon: 'cart',
  3521. // text: t("uni-goods-nav.options.cart")
  3522. // }]
  3523. // }
  3524. // },
  3525. if (appVm) {
  3526. // 触发响应式
  3527. appVm.$locale;
  3528. if (!isWatchedAppLocale) {
  3529. isWatchedAppLocale = true;
  3530. watchAppLocale(appVm, i18n);
  3531. }
  3532. }
  3533. return i18n.t(key, values);
  3534. };
  3535. }
  3536. return _t(key, values);
  3537. };
  3538. return {
  3539. i18n: i18n,
  3540. f: function f(message, values, delimiters) {
  3541. return i18n.f(message, values, delimiters);
  3542. },
  3543. t: function t(key, values) {
  3544. return _t(key, values);
  3545. },
  3546. add: function add(locale, message) {
  3547. var override = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : true;
  3548. return i18n.add(locale, message, override);
  3549. },
  3550. watch: function watch(fn) {
  3551. return i18n.watchLocale(fn);
  3552. },
  3553. getLocale: function getLocale() {
  3554. return i18n.getLocale();
  3555. },
  3556. setLocale: function setLocale(newLocale) {
  3557. return i18n.setLocale(newLocale);
  3558. }
  3559. };
  3560. }
  3561. var isString = function isString(val) {
  3562. return typeof val === 'string';
  3563. };
  3564. exports.isString = isString;
  3565. var formater;
  3566. function hasI18nJson(jsonObj, delimiters) {
  3567. if (!formater) {
  3568. formater = new BaseFormatter();
  3569. }
  3570. return walkJsonObj(jsonObj, function (jsonObj, key) {
  3571. var value = jsonObj[key];
  3572. if (isString(value)) {
  3573. if (isI18nStr(value, delimiters)) {
  3574. return true;
  3575. }
  3576. } else {
  3577. return hasI18nJson(value, delimiters);
  3578. }
  3579. });
  3580. }
  3581. function parseI18nJson(jsonObj, values, delimiters) {
  3582. if (!formater) {
  3583. formater = new BaseFormatter();
  3584. }
  3585. walkJsonObj(jsonObj, function (jsonObj, key) {
  3586. var value = jsonObj[key];
  3587. if (isString(value)) {
  3588. if (isI18nStr(value, delimiters)) {
  3589. jsonObj[key] = compileStr(value, values, delimiters);
  3590. }
  3591. } else {
  3592. parseI18nJson(value, values, delimiters);
  3593. }
  3594. });
  3595. return jsonObj;
  3596. }
  3597. function compileI18nJsonStr(jsonStr, _ref5) {
  3598. var locale = _ref5.locale,
  3599. locales = _ref5.locales,
  3600. delimiters = _ref5.delimiters;
  3601. if (!isI18nStr(jsonStr, delimiters)) {
  3602. return jsonStr;
  3603. }
  3604. if (!formater) {
  3605. formater = new BaseFormatter();
  3606. }
  3607. var localeValues = [];
  3608. Object.keys(locales).forEach(function (name) {
  3609. if (name !== locale) {
  3610. localeValues.push({
  3611. locale: name,
  3612. values: locales[name]
  3613. });
  3614. }
  3615. });
  3616. localeValues.unshift({
  3617. locale: locale,
  3618. values: locales[locale]
  3619. });
  3620. try {
  3621. return JSON.stringify(compileJsonObj(JSON.parse(jsonStr), localeValues, delimiters), null, 2);
  3622. } catch (e) {}
  3623. return jsonStr;
  3624. }
  3625. function isI18nStr(value, delimiters) {
  3626. return value.indexOf(delimiters[0]) > -1;
  3627. }
  3628. function compileStr(value, values, delimiters) {
  3629. return formater.interpolate(value, values, delimiters).join('');
  3630. }
  3631. function compileValue(jsonObj, key, localeValues, delimiters) {
  3632. var value = jsonObj[key];
  3633. if (isString(value)) {
  3634. // 存在国际化
  3635. if (isI18nStr(value, delimiters)) {
  3636. jsonObj[key] = compileStr(value, localeValues[0].values, delimiters);
  3637. if (localeValues.length > 1) {
  3638. // 格式化国际化语言
  3639. var valueLocales = jsonObj[key + 'Locales'] = {};
  3640. localeValues.forEach(function (localValue) {
  3641. valueLocales[localValue.locale] = compileStr(value, localValue.values, delimiters);
  3642. });
  3643. }
  3644. }
  3645. } else {
  3646. compileJsonObj(value, localeValues, delimiters);
  3647. }
  3648. }
  3649. function compileJsonObj(jsonObj, localeValues, delimiters) {
  3650. walkJsonObj(jsonObj, function (jsonObj, key) {
  3651. compileValue(jsonObj, key, localeValues, delimiters);
  3652. });
  3653. return jsonObj;
  3654. }
  3655. function walkJsonObj(jsonObj, walk) {
  3656. if (Array.isArray(jsonObj)) {
  3657. for (var i = 0; i < jsonObj.length; i++) {
  3658. if (walk(jsonObj, i)) {
  3659. return true;
  3660. }
  3661. }
  3662. } else if (isObject(jsonObj)) {
  3663. for (var key in jsonObj) {
  3664. if (walk(jsonObj, key)) {
  3665. return true;
  3666. }
  3667. }
  3668. }
  3669. return false;
  3670. }
  3671. function resolveLocale(locales) {
  3672. return function (locale) {
  3673. if (!locale) {
  3674. return locale;
  3675. }
  3676. locale = normalizeLocale(locale) || locale;
  3677. return resolveLocaleChain(locale).find(function (locale) {
  3678. return locales.indexOf(locale) > -1;
  3679. });
  3680. };
  3681. }
  3682. function resolveLocaleChain(locale) {
  3683. var chain = [];
  3684. var tokens = locale.split('-');
  3685. while (tokens.length) {
  3686. chain.push(tokens.join('-'));
  3687. tokens.pop();
  3688. }
  3689. return chain;
  3690. }
  3691. /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./node_modules/@dcloudio/uni-mp-toutiao/dist/index.js */ 1)["default"], __webpack_require__(/*! ./../../../webpack/buildin/global.js */ 2)))
  3692. /***/ }),
  3693. /* 24 */
  3694. /*!******************************************************************************************!*\
  3695. !*** ./node_modules/@dcloudio/vue-cli-plugin-uni/packages/mp-vue/dist/mp.runtime.esm.js ***!
  3696. \******************************************************************************************/
  3697. /*! exports provided: default */
  3698. /***/ (function(module, __webpack_exports__, __webpack_require__) {
  3699. "use strict";
  3700. __webpack_require__.r(__webpack_exports__);
  3701. /* WEBPACK VAR INJECTION */(function(global) {/*!
  3702. * Vue.js v2.6.11
  3703. * (c) 2014-2024 Evan You
  3704. * Released under the MIT License.
  3705. */
  3706. /* */
  3707. var emptyObject = Object.freeze({});
  3708. // These helpers produce better VM code in JS engines due to their
  3709. // explicitness and function inlining.
  3710. function isUndef (v) {
  3711. return v === undefined || v === null
  3712. }
  3713. function isDef (v) {
  3714. return v !== undefined && v !== null
  3715. }
  3716. function isTrue (v) {
  3717. return v === true
  3718. }
  3719. function isFalse (v) {
  3720. return v === false
  3721. }
  3722. /**
  3723. * Check if value is primitive.
  3724. */
  3725. function isPrimitive (value) {
  3726. return (
  3727. typeof value === 'string' ||
  3728. typeof value === 'number' ||
  3729. // $flow-disable-line
  3730. typeof value === 'symbol' ||
  3731. typeof value === 'boolean'
  3732. )
  3733. }
  3734. /**
  3735. * Quick object check - this is primarily used to tell
  3736. * Objects from primitive values when we know the value
  3737. * is a JSON-compliant type.
  3738. */
  3739. function isObject (obj) {
  3740. return obj !== null && typeof obj === 'object'
  3741. }
  3742. /**
  3743. * Get the raw type string of a value, e.g., [object Object].
  3744. */
  3745. var _toString = Object.prototype.toString;
  3746. function toRawType (value) {
  3747. return _toString.call(value).slice(8, -1)
  3748. }
  3749. /**
  3750. * Strict object type check. Only returns true
  3751. * for plain JavaScript objects.
  3752. */
  3753. function isPlainObject (obj) {
  3754. return _toString.call(obj) === '[object Object]'
  3755. }
  3756. function isRegExp (v) {
  3757. return _toString.call(v) === '[object RegExp]'
  3758. }
  3759. /**
  3760. * Check if val is a valid array index.
  3761. */
  3762. function isValidArrayIndex (val) {
  3763. var n = parseFloat(String(val));
  3764. return n >= 0 && Math.floor(n) === n && isFinite(val)
  3765. }
  3766. function isPromise (val) {
  3767. return (
  3768. isDef(val) &&
  3769. typeof val.then === 'function' &&
  3770. typeof val.catch === 'function'
  3771. )
  3772. }
  3773. /**
  3774. * Convert a value to a string that is actually rendered.
  3775. */
  3776. function toString (val) {
  3777. return val == null
  3778. ? ''
  3779. : Array.isArray(val) || (isPlainObject(val) && val.toString === _toString)
  3780. ? JSON.stringify(val, null, 2)
  3781. : String(val)
  3782. }
  3783. /**
  3784. * Convert an input value to a number for persistence.
  3785. * If the conversion fails, return original string.
  3786. */
  3787. function toNumber (val) {
  3788. var n = parseFloat(val);
  3789. return isNaN(n) ? val : n
  3790. }
  3791. /**
  3792. * Make a map and return a function for checking if a key
  3793. * is in that map.
  3794. */
  3795. function makeMap (
  3796. str,
  3797. expectsLowerCase
  3798. ) {
  3799. var map = Object.create(null);
  3800. var list = str.split(',');
  3801. for (var i = 0; i < list.length; i++) {
  3802. map[list[i]] = true;
  3803. }
  3804. return expectsLowerCase
  3805. ? function (val) { return map[val.toLowerCase()]; }
  3806. : function (val) { return map[val]; }
  3807. }
  3808. /**
  3809. * Check if a tag is a built-in tag.
  3810. */
  3811. var isBuiltInTag = makeMap('slot,component', true);
  3812. /**
  3813. * Check if an attribute is a reserved attribute.
  3814. */
  3815. var isReservedAttribute = makeMap('key,ref,slot,slot-scope,is');
  3816. /**
  3817. * Remove an item from an array.
  3818. */
  3819. function remove (arr, item) {
  3820. if (arr.length) {
  3821. var index = arr.indexOf(item);
  3822. if (index > -1) {
  3823. return arr.splice(index, 1)
  3824. }
  3825. }
  3826. }
  3827. /**
  3828. * Check whether an object has the property.
  3829. */
  3830. var hasOwnProperty = Object.prototype.hasOwnProperty;
  3831. function hasOwn (obj, key) {
  3832. return hasOwnProperty.call(obj, key)
  3833. }
  3834. /**
  3835. * Create a cached version of a pure function.
  3836. */
  3837. function cached (fn) {
  3838. var cache = Object.create(null);
  3839. return (function cachedFn (str) {
  3840. var hit = cache[str];
  3841. return hit || (cache[str] = fn(str))
  3842. })
  3843. }
  3844. /**
  3845. * Camelize a hyphen-delimited string.
  3846. */
  3847. var camelizeRE = /-(\w)/g;
  3848. var camelize = cached(function (str) {
  3849. return str.replace(camelizeRE, function (_, c) { return c ? c.toUpperCase() : ''; })
  3850. });
  3851. /**
  3852. * Capitalize a string.
  3853. */
  3854. var capitalize = cached(function (str) {
  3855. return str.charAt(0).toUpperCase() + str.slice(1)
  3856. });
  3857. /**
  3858. * Hyphenate a camelCase string.
  3859. */
  3860. var hyphenateRE = /\B([A-Z])/g;
  3861. var hyphenate = cached(function (str) {
  3862. return str.replace(hyphenateRE, '-$1').toLowerCase()
  3863. });
  3864. /**
  3865. * Simple bind polyfill for environments that do not support it,
  3866. * e.g., PhantomJS 1.x. Technically, we don't need this anymore
  3867. * since native bind is now performant enough in most browsers.
  3868. * But removing it would mean breaking code that was able to run in
  3869. * PhantomJS 1.x, so this must be kept for backward compatibility.
  3870. */
  3871. /* istanbul ignore next */
  3872. function polyfillBind (fn, ctx) {
  3873. function boundFn (a) {
  3874. var l = arguments.length;
  3875. return l
  3876. ? l > 1
  3877. ? fn.apply(ctx, arguments)
  3878. : fn.call(ctx, a)
  3879. : fn.call(ctx)
  3880. }
  3881. boundFn._length = fn.length;
  3882. return boundFn
  3883. }
  3884. function nativeBind (fn, ctx) {
  3885. return fn.bind(ctx)
  3886. }
  3887. var bind = Function.prototype.bind
  3888. ? nativeBind
  3889. : polyfillBind;
  3890. /**
  3891. * Convert an Array-like object to a real Array.
  3892. */
  3893. function toArray (list, start) {
  3894. start = start || 0;
  3895. var i = list.length - start;
  3896. var ret = new Array(i);
  3897. while (i--) {
  3898. ret[i] = list[i + start];
  3899. }
  3900. return ret
  3901. }
  3902. /**
  3903. * Mix properties into target object.
  3904. */
  3905. function extend (to, _from) {
  3906. for (var key in _from) {
  3907. to[key] = _from[key];
  3908. }
  3909. return to
  3910. }
  3911. /**
  3912. * Merge an Array of Objects into a single Object.
  3913. */
  3914. function toObject (arr) {
  3915. var res = {};
  3916. for (var i = 0; i < arr.length; i++) {
  3917. if (arr[i]) {
  3918. extend(res, arr[i]);
  3919. }
  3920. }
  3921. return res
  3922. }
  3923. /* eslint-disable no-unused-vars */
  3924. /**
  3925. * Perform no operation.
  3926. * Stubbing args to make Flow happy without leaving useless transpiled code
  3927. * with ...rest (https://flow.org/blog/2017/05/07/Strict-Function-Call-Arity/).
  3928. */
  3929. function noop (a, b, c) {}
  3930. /**
  3931. * Always return false.
  3932. */
  3933. var no = function (a, b, c) { return false; };
  3934. /* eslint-enable no-unused-vars */
  3935. /**
  3936. * Return the same value.
  3937. */
  3938. var identity = function (_) { return _; };
  3939. /**
  3940. * Check if two values are loosely equal - that is,
  3941. * if they are plain objects, do they have the same shape?
  3942. */
  3943. function looseEqual (a, b) {
  3944. if (a === b) { return true }
  3945. var isObjectA = isObject(a);
  3946. var isObjectB = isObject(b);
  3947. if (isObjectA && isObjectB) {
  3948. try {
  3949. var isArrayA = Array.isArray(a);
  3950. var isArrayB = Array.isArray(b);
  3951. if (isArrayA && isArrayB) {
  3952. return a.length === b.length && a.every(function (e, i) {
  3953. return looseEqual(e, b[i])
  3954. })
  3955. } else if (a instanceof Date && b instanceof Date) {
  3956. return a.getTime() === b.getTime()
  3957. } else if (!isArrayA && !isArrayB) {
  3958. var keysA = Object.keys(a);
  3959. var keysB = Object.keys(b);
  3960. return keysA.length === keysB.length && keysA.every(function (key) {
  3961. return looseEqual(a[key], b[key])
  3962. })
  3963. } else {
  3964. /* istanbul ignore next */
  3965. return false
  3966. }
  3967. } catch (e) {
  3968. /* istanbul ignore next */
  3969. return false
  3970. }
  3971. } else if (!isObjectA && !isObjectB) {
  3972. return String(a) === String(b)
  3973. } else {
  3974. return false
  3975. }
  3976. }
  3977. /**
  3978. * Return the first index at which a loosely equal value can be
  3979. * found in the array (if value is a plain object, the array must
  3980. * contain an object of the same shape), or -1 if it is not present.
  3981. */
  3982. function looseIndexOf (arr, val) {
  3983. for (var i = 0; i < arr.length; i++) {
  3984. if (looseEqual(arr[i], val)) { return i }
  3985. }
  3986. return -1
  3987. }
  3988. /**
  3989. * Ensure a function is called only once.
  3990. */
  3991. function once (fn) {
  3992. var called = false;
  3993. return function () {
  3994. if (!called) {
  3995. called = true;
  3996. fn.apply(this, arguments);
  3997. }
  3998. }
  3999. }
  4000. var ASSET_TYPES = [
  4001. 'component',
  4002. 'directive',
  4003. 'filter'
  4004. ];
  4005. var LIFECYCLE_HOOKS = [
  4006. 'beforeCreate',
  4007. 'created',
  4008. 'beforeMount',
  4009. 'mounted',
  4010. 'beforeUpdate',
  4011. 'updated',
  4012. 'beforeDestroy',
  4013. 'destroyed',
  4014. 'activated',
  4015. 'deactivated',
  4016. 'errorCaptured',
  4017. 'serverPrefetch'
  4018. ];
  4019. /* */
  4020. var config = ({
  4021. /**
  4022. * Option merge strategies (used in core/util/options)
  4023. */
  4024. // $flow-disable-line
  4025. optionMergeStrategies: Object.create(null),
  4026. /**
  4027. * Whether to suppress warnings.
  4028. */
  4029. silent: false,
  4030. /**
  4031. * Show production mode tip message on boot?
  4032. */
  4033. productionTip: "development" !== 'production',
  4034. /**
  4035. * Whether to enable devtools
  4036. */
  4037. devtools: "development" !== 'production',
  4038. /**
  4039. * Whether to record perf
  4040. */
  4041. performance: false,
  4042. /**
  4043. * Error handler for watcher errors
  4044. */
  4045. errorHandler: null,
  4046. /**
  4047. * Warn handler for watcher warns
  4048. */
  4049. warnHandler: null,
  4050. /**
  4051. * Ignore certain custom elements
  4052. */
  4053. ignoredElements: [],
  4054. /**
  4055. * Custom user key aliases for v-on
  4056. */
  4057. // $flow-disable-line
  4058. keyCodes: Object.create(null),
  4059. /**
  4060. * Check if a tag is reserved so that it cannot be registered as a
  4061. * component. This is platform-dependent and may be overwritten.
  4062. */
  4063. isReservedTag: no,
  4064. /**
  4065. * Check if an attribute is reserved so that it cannot be used as a component
  4066. * prop. This is platform-dependent and may be overwritten.
  4067. */
  4068. isReservedAttr: no,
  4069. /**
  4070. * Check if a tag is an unknown element.
  4071. * Platform-dependent.
  4072. */
  4073. isUnknownElement: no,
  4074. /**
  4075. * Get the namespace of an element
  4076. */
  4077. getTagNamespace: noop,
  4078. /**
  4079. * Parse the real tag name for the specific platform.
  4080. */
  4081. parsePlatformTagName: identity,
  4082. /**
  4083. * Check if an attribute must be bound using property, e.g. value
  4084. * Platform-dependent.
  4085. */
  4086. mustUseProp: no,
  4087. /**
  4088. * Perform updates asynchronously. Intended to be used by Vue Test Utils
  4089. * This will significantly reduce performance if set to false.
  4090. */
  4091. async: true,
  4092. /**
  4093. * Exposed for legacy reasons
  4094. */
  4095. _lifecycleHooks: LIFECYCLE_HOOKS
  4096. });
  4097. /* */
  4098. /**
  4099. * unicode letters used for parsing html tags, component names and property paths.
  4100. * using https://www.w3.org/TR/html53/semantics-scripting.html#potentialcustomelementname
  4101. * skipping \u10000-\uEFFFF due to it freezing up PhantomJS
  4102. */
  4103. var unicodeRegExp = /a-zA-Z\u00B7\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u037D\u037F-\u1FFF\u200C-\u200D\u203F-\u2040\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD/;
  4104. /**
  4105. * Check if a string starts with $ or _
  4106. */
  4107. function isReserved (str) {
  4108. var c = (str + '').charCodeAt(0);
  4109. return c === 0x24 || c === 0x5F
  4110. }
  4111. /**
  4112. * Define a property.
  4113. */
  4114. function def (obj, key, val, enumerable) {
  4115. Object.defineProperty(obj, key, {
  4116. value: val,
  4117. enumerable: !!enumerable,
  4118. writable: true,
  4119. configurable: true
  4120. });
  4121. }
  4122. /**
  4123. * Parse simple path.
  4124. */
  4125. var bailRE = new RegExp(("[^" + (unicodeRegExp.source) + ".$_\\d]"));
  4126. function parsePath (path) {
  4127. if (bailRE.test(path)) {
  4128. return
  4129. }
  4130. var segments = path.split('.');
  4131. return function (obj) {
  4132. for (var i = 0; i < segments.length; i++) {
  4133. if (!obj) { return }
  4134. obj = obj[segments[i]];
  4135. }
  4136. return obj
  4137. }
  4138. }
  4139. /* */
  4140. // can we use __proto__?
  4141. var hasProto = '__proto__' in {};
  4142. // Browser environment sniffing
  4143. var inBrowser = typeof window !== 'undefined';
  4144. var inWeex = typeof WXEnvironment !== 'undefined' && !!WXEnvironment.platform;
  4145. var weexPlatform = inWeex && WXEnvironment.platform.toLowerCase();
  4146. var UA = inBrowser && window.navigator && window.navigator.userAgent.toLowerCase();
  4147. var isIE = UA && /msie|trident/.test(UA);
  4148. var isIE9 = UA && UA.indexOf('msie 9.0') > 0;
  4149. var isEdge = UA && UA.indexOf('edge/') > 0;
  4150. var isAndroid = (UA && UA.indexOf('android') > 0) || (weexPlatform === 'android');
  4151. var isIOS = (UA && /iphone|ipad|ipod|ios/.test(UA)) || (weexPlatform === 'ios');
  4152. var isChrome = UA && /chrome\/\d+/.test(UA) && !isEdge;
  4153. var isPhantomJS = UA && /phantomjs/.test(UA);
  4154. var isFF = UA && UA.match(/firefox\/(\d+)/);
  4155. // Firefox has a "watch" function on Object.prototype...
  4156. var nativeWatch = ({}).watch;
  4157. if (inBrowser) {
  4158. try {
  4159. var opts = {};
  4160. Object.defineProperty(opts, 'passive', ({
  4161. get: function get () {
  4162. }
  4163. })); // https://github.com/facebook/flow/issues/285
  4164. window.addEventListener('test-passive', null, opts);
  4165. } catch (e) {}
  4166. }
  4167. // this needs to be lazy-evaled because vue may be required before
  4168. // vue-server-renderer can set VUE_ENV
  4169. var _isServer;
  4170. var isServerRendering = function () {
  4171. if (_isServer === undefined) {
  4172. /* istanbul ignore if */
  4173. if (!inBrowser && !inWeex && typeof global !== 'undefined') {
  4174. // detect presence of vue-server-renderer and avoid
  4175. // Webpack shimming the process
  4176. _isServer = global['process'] && global['process'].env.VUE_ENV === 'server';
  4177. } else {
  4178. _isServer = false;
  4179. }
  4180. }
  4181. return _isServer
  4182. };
  4183. // detect devtools
  4184. var devtools = inBrowser && window.__VUE_DEVTOOLS_GLOBAL_HOOK__;
  4185. /* istanbul ignore next */
  4186. function isNative (Ctor) {
  4187. return typeof Ctor === 'function' && /native code/.test(Ctor.toString())
  4188. }
  4189. var hasSymbol =
  4190. typeof Symbol !== 'undefined' && isNative(Symbol) &&
  4191. typeof Reflect !== 'undefined' && isNative(Reflect.ownKeys);
  4192. var _Set;
  4193. /* istanbul ignore if */ // $flow-disable-line
  4194. if (typeof Set !== 'undefined' && isNative(Set)) {
  4195. // use native Set when available.
  4196. _Set = Set;
  4197. } else {
  4198. // a non-standard Set polyfill that only works with primitive keys.
  4199. _Set = /*@__PURE__*/(function () {
  4200. function Set () {
  4201. this.set = Object.create(null);
  4202. }
  4203. Set.prototype.has = function has (key) {
  4204. return this.set[key] === true
  4205. };
  4206. Set.prototype.add = function add (key) {
  4207. this.set[key] = true;
  4208. };
  4209. Set.prototype.clear = function clear () {
  4210. this.set = Object.create(null);
  4211. };
  4212. return Set;
  4213. }());
  4214. }
  4215. /* */
  4216. var warn = noop;
  4217. var tip = noop;
  4218. var generateComponentTrace = (noop); // work around flow check
  4219. var formatComponentName = (noop);
  4220. if (true) {
  4221. var hasConsole = typeof console !== 'undefined';
  4222. var classifyRE = /(?:^|[-_])(\w)/g;
  4223. var classify = function (str) { return str
  4224. .replace(classifyRE, function (c) { return c.toUpperCase(); })
  4225. .replace(/[-_]/g, ''); };
  4226. warn = function (msg, vm) {
  4227. var trace = vm ? generateComponentTrace(vm) : '';
  4228. if (config.warnHandler) {
  4229. config.warnHandler.call(null, msg, vm, trace);
  4230. } else if (hasConsole && (!config.silent)) {
  4231. console.error(("[Vue warn]: " + msg + trace));
  4232. }
  4233. };
  4234. tip = function (msg, vm) {
  4235. if (hasConsole && (!config.silent)) {
  4236. console.warn("[Vue tip]: " + msg + (
  4237. vm ? generateComponentTrace(vm) : ''
  4238. ));
  4239. }
  4240. };
  4241. formatComponentName = function (vm, includeFile) {
  4242. if (vm.$root === vm) {
  4243. if (vm.$options && vm.$options.__file) { // fixed by xxxxxx
  4244. return ('') + vm.$options.__file
  4245. }
  4246. return '<Root>'
  4247. }
  4248. var options = typeof vm === 'function' && vm.cid != null
  4249. ? vm.options
  4250. : vm._isVue
  4251. ? vm.$options || vm.constructor.options
  4252. : vm;
  4253. var name = options.name || options._componentTag;
  4254. var file = options.__file;
  4255. if (!name && file) {
  4256. var match = file.match(/([^/\\]+)\.vue$/);
  4257. name = match && match[1];
  4258. }
  4259. return (
  4260. (name ? ("<" + (classify(name)) + ">") : "<Anonymous>") +
  4261. (file && includeFile !== false ? (" at " + file) : '')
  4262. )
  4263. };
  4264. var repeat = function (str, n) {
  4265. var res = '';
  4266. while (n) {
  4267. if (n % 2 === 1) { res += str; }
  4268. if (n > 1) { str += str; }
  4269. n >>= 1;
  4270. }
  4271. return res
  4272. };
  4273. generateComponentTrace = function (vm) {
  4274. if (vm._isVue && vm.$parent) {
  4275. var tree = [];
  4276. var currentRecursiveSequence = 0;
  4277. while (vm && vm.$options.name !== 'PageBody') {
  4278. if (tree.length > 0) {
  4279. var last = tree[tree.length - 1];
  4280. if (last.constructor === vm.constructor) {
  4281. currentRecursiveSequence++;
  4282. vm = vm.$parent;
  4283. continue
  4284. } else if (currentRecursiveSequence > 0) {
  4285. tree[tree.length - 1] = [last, currentRecursiveSequence];
  4286. currentRecursiveSequence = 0;
  4287. }
  4288. }
  4289. !vm.$options.isReserved && tree.push(vm);
  4290. vm = vm.$parent;
  4291. }
  4292. return '\n\nfound in\n\n' + tree
  4293. .map(function (vm, i) { return ("" + (i === 0 ? '---> ' : repeat(' ', 5 + i * 2)) + (Array.isArray(vm)
  4294. ? ((formatComponentName(vm[0])) + "... (" + (vm[1]) + " recursive calls)")
  4295. : formatComponentName(vm))); })
  4296. .join('\n')
  4297. } else {
  4298. return ("\n\n(found in " + (formatComponentName(vm)) + ")")
  4299. }
  4300. };
  4301. }
  4302. /* */
  4303. var uid = 0;
  4304. /**
  4305. * A dep is an observable that can have multiple
  4306. * directives subscribing to it.
  4307. */
  4308. var Dep = function Dep () {
  4309. this.id = uid++;
  4310. this.subs = [];
  4311. };
  4312. Dep.prototype.addSub = function addSub (sub) {
  4313. this.subs.push(sub);
  4314. };
  4315. Dep.prototype.removeSub = function removeSub (sub) {
  4316. remove(this.subs, sub);
  4317. };
  4318. Dep.prototype.depend = function depend () {
  4319. if (Dep.SharedObject.target) {
  4320. Dep.SharedObject.target.addDep(this);
  4321. }
  4322. };
  4323. Dep.prototype.notify = function notify () {
  4324. // stabilize the subscriber list first
  4325. var subs = this.subs.slice();
  4326. if ( true && !config.async) {
  4327. // subs aren't sorted in scheduler if not running async
  4328. // we need to sort them now to make sure they fire in correct
  4329. // order
  4330. subs.sort(function (a, b) { return a.id - b.id; });
  4331. }
  4332. for (var i = 0, l = subs.length; i < l; i++) {
  4333. subs[i].update();
  4334. }
  4335. };
  4336. // The current target watcher being evaluated.
  4337. // This is globally unique because only one watcher
  4338. // can be evaluated at a time.
  4339. // fixed by xxxxxx (nvue shared vuex)
  4340. /* eslint-disable no-undef */
  4341. Dep.SharedObject = {};
  4342. Dep.SharedObject.target = null;
  4343. Dep.SharedObject.targetStack = [];
  4344. function pushTarget (target) {
  4345. Dep.SharedObject.targetStack.push(target);
  4346. Dep.SharedObject.target = target;
  4347. Dep.target = target;
  4348. }
  4349. function popTarget () {
  4350. Dep.SharedObject.targetStack.pop();
  4351. Dep.SharedObject.target = Dep.SharedObject.targetStack[Dep.SharedObject.targetStack.length - 1];
  4352. Dep.target = Dep.SharedObject.target;
  4353. }
  4354. /* */
  4355. var VNode = function VNode (
  4356. tag,
  4357. data,
  4358. children,
  4359. text,
  4360. elm,
  4361. context,
  4362. componentOptions,
  4363. asyncFactory
  4364. ) {
  4365. this.tag = tag;
  4366. this.data = data;
  4367. this.children = children;
  4368. this.text = text;
  4369. this.elm = elm;
  4370. this.ns = undefined;
  4371. this.context = context;
  4372. this.fnContext = undefined;
  4373. this.fnOptions = undefined;
  4374. this.fnScopeId = undefined;
  4375. this.key = data && data.key;
  4376. this.componentOptions = componentOptions;
  4377. this.componentInstance = undefined;
  4378. this.parent = undefined;
  4379. this.raw = false;
  4380. this.isStatic = false;
  4381. this.isRootInsert = true;
  4382. this.isComment = false;
  4383. this.isCloned = false;
  4384. this.isOnce = false;
  4385. this.asyncFactory = asyncFactory;
  4386. this.asyncMeta = undefined;
  4387. this.isAsyncPlaceholder = false;
  4388. };
  4389. var prototypeAccessors = { child: { configurable: true } };
  4390. // DEPRECATED: alias for componentInstance for backwards compat.
  4391. /* istanbul ignore next */
  4392. prototypeAccessors.child.get = function () {
  4393. return this.componentInstance
  4394. };
  4395. Object.defineProperties( VNode.prototype, prototypeAccessors );
  4396. var createEmptyVNode = function (text) {
  4397. if ( text === void 0 ) text = '';
  4398. var node = new VNode();
  4399. node.text = text;
  4400. node.isComment = true;
  4401. return node
  4402. };
  4403. function createTextVNode (val) {
  4404. return new VNode(undefined, undefined, undefined, String(val))
  4405. }
  4406. // optimized shallow clone
  4407. // used for static nodes and slot nodes because they may be reused across
  4408. // multiple renders, cloning them avoids errors when DOM manipulations rely
  4409. // on their elm reference.
  4410. function cloneVNode (vnode) {
  4411. var cloned = new VNode(
  4412. vnode.tag,
  4413. vnode.data,
  4414. // #7975
  4415. // clone children array to avoid mutating original in case of cloning
  4416. // a child.
  4417. vnode.children && vnode.children.slice(),
  4418. vnode.text,
  4419. vnode.elm,
  4420. vnode.context,
  4421. vnode.componentOptions,
  4422. vnode.asyncFactory
  4423. );
  4424. cloned.ns = vnode.ns;
  4425. cloned.isStatic = vnode.isStatic;
  4426. cloned.key = vnode.key;
  4427. cloned.isComment = vnode.isComment;
  4428. cloned.fnContext = vnode.fnContext;
  4429. cloned.fnOptions = vnode.fnOptions;
  4430. cloned.fnScopeId = vnode.fnScopeId;
  4431. cloned.asyncMeta = vnode.asyncMeta;
  4432. cloned.isCloned = true;
  4433. return cloned
  4434. }
  4435. /*
  4436. * not type checking this file because flow doesn't play well with
  4437. * dynamically accessing methods on Array prototype
  4438. */
  4439. var arrayProto = Array.prototype;
  4440. var arrayMethods = Object.create(arrayProto);
  4441. var methodsToPatch = [
  4442. 'push',
  4443. 'pop',
  4444. 'shift',
  4445. 'unshift',
  4446. 'splice',
  4447. 'sort',
  4448. 'reverse'
  4449. ];
  4450. /**
  4451. * Intercept mutating methods and emit events
  4452. */
  4453. methodsToPatch.forEach(function (method) {
  4454. // cache original method
  4455. var original = arrayProto[method];
  4456. def(arrayMethods, method, function mutator () {
  4457. var args = [], len = arguments.length;
  4458. while ( len-- ) args[ len ] = arguments[ len ];
  4459. var result = original.apply(this, args);
  4460. var ob = this.__ob__;
  4461. var inserted;
  4462. switch (method) {
  4463. case 'push':
  4464. case 'unshift':
  4465. inserted = args;
  4466. break
  4467. case 'splice':
  4468. inserted = args.slice(2);
  4469. break
  4470. }
  4471. if (inserted) { ob.observeArray(inserted); }
  4472. // notify change
  4473. ob.dep.notify();
  4474. return result
  4475. });
  4476. });
  4477. /* */
  4478. var arrayKeys = Object.getOwnPropertyNames(arrayMethods);
  4479. /**
  4480. * In some cases we may want to disable observation inside a component's
  4481. * update computation.
  4482. */
  4483. var shouldObserve = true;
  4484. function toggleObserving (value) {
  4485. shouldObserve = value;
  4486. }
  4487. /**
  4488. * Observer class that is attached to each observed
  4489. * object. Once attached, the observer converts the target
  4490. * object's property keys into getter/setters that
  4491. * collect dependencies and dispatch updates.
  4492. */
  4493. var Observer = function Observer (value) {
  4494. this.value = value;
  4495. this.dep = new Dep();
  4496. this.vmCount = 0;
  4497. def(value, '__ob__', this);
  4498. if (Array.isArray(value)) {
  4499. if (hasProto) {
  4500. {// fixed by xxxxxx 微信小程序使用 plugins 之后,数组方法被直接挂载到了数组对象上,需要执行 copyAugment 逻辑
  4501. if(value.push !== value.__proto__.push){
  4502. copyAugment(value, arrayMethods, arrayKeys);
  4503. } else {
  4504. protoAugment(value, arrayMethods);
  4505. }
  4506. }
  4507. } else {
  4508. copyAugment(value, arrayMethods, arrayKeys);
  4509. }
  4510. this.observeArray(value);
  4511. } else {
  4512. this.walk(value);
  4513. }
  4514. };
  4515. /**
  4516. * Walk through all properties and convert them into
  4517. * getter/setters. This method should only be called when
  4518. * value type is Object.
  4519. */
  4520. Observer.prototype.walk = function walk (obj) {
  4521. var keys = Object.keys(obj);
  4522. for (var i = 0; i < keys.length; i++) {
  4523. defineReactive$$1(obj, keys[i]);
  4524. }
  4525. };
  4526. /**
  4527. * Observe a list of Array items.
  4528. */
  4529. Observer.prototype.observeArray = function observeArray (items) {
  4530. for (var i = 0, l = items.length; i < l; i++) {
  4531. observe(items[i]);
  4532. }
  4533. };
  4534. // helpers
  4535. /**
  4536. * Augment a target Object or Array by intercepting
  4537. * the prototype chain using __proto__
  4538. */
  4539. function protoAugment (target, src) {
  4540. /* eslint-disable no-proto */
  4541. target.__proto__ = src;
  4542. /* eslint-enable no-proto */
  4543. }
  4544. /**
  4545. * Augment a target Object or Array by defining
  4546. * hidden properties.
  4547. */
  4548. /* istanbul ignore next */
  4549. function copyAugment (target, src, keys) {
  4550. for (var i = 0, l = keys.length; i < l; i++) {
  4551. var key = keys[i];
  4552. def(target, key, src[key]);
  4553. }
  4554. }
  4555. /**
  4556. * Attempt to create an observer instance for a value,
  4557. * returns the new observer if successfully observed,
  4558. * or the existing observer if the value already has one.
  4559. */
  4560. function observe (value, asRootData) {
  4561. if (!isObject(value) || value instanceof VNode) {
  4562. return
  4563. }
  4564. var ob;
  4565. if (hasOwn(value, '__ob__') && value.__ob__ instanceof Observer) {
  4566. ob = value.__ob__;
  4567. } else if (
  4568. shouldObserve &&
  4569. !isServerRendering() &&
  4570. (Array.isArray(value) || isPlainObject(value)) &&
  4571. Object.isExtensible(value) &&
  4572. !value._isVue &&
  4573. !value.__v_isMPComponent
  4574. ) {
  4575. ob = new Observer(value);
  4576. }
  4577. if (asRootData && ob) {
  4578. ob.vmCount++;
  4579. }
  4580. return ob
  4581. }
  4582. /**
  4583. * Define a reactive property on an Object.
  4584. */
  4585. function defineReactive$$1 (
  4586. obj,
  4587. key,
  4588. val,
  4589. customSetter,
  4590. shallow
  4591. ) {
  4592. var dep = new Dep();
  4593. var property = Object.getOwnPropertyDescriptor(obj, key);
  4594. if (property && property.configurable === false) {
  4595. return
  4596. }
  4597. // cater for pre-defined getter/setters
  4598. var getter = property && property.get;
  4599. var setter = property && property.set;
  4600. if ((!getter || setter) && arguments.length === 2) {
  4601. val = obj[key];
  4602. }
  4603. var childOb = !shallow && observe(val);
  4604. Object.defineProperty(obj, key, {
  4605. enumerable: true,
  4606. configurable: true,
  4607. get: function reactiveGetter () {
  4608. var value = getter ? getter.call(obj) : val;
  4609. if (Dep.SharedObject.target) { // fixed by xxxxxx
  4610. dep.depend();
  4611. if (childOb) {
  4612. childOb.dep.depend();
  4613. if (Array.isArray(value)) {
  4614. dependArray(value);
  4615. }
  4616. }
  4617. }
  4618. return value
  4619. },
  4620. set: function reactiveSetter (newVal) {
  4621. var value = getter ? getter.call(obj) : val;
  4622. /* eslint-disable no-self-compare */
  4623. if (newVal === value || (newVal !== newVal && value !== value)) {
  4624. return
  4625. }
  4626. /* eslint-enable no-self-compare */
  4627. if ( true && customSetter) {
  4628. customSetter();
  4629. }
  4630. // #7981: for accessor properties without setter
  4631. if (getter && !setter) { return }
  4632. if (setter) {
  4633. setter.call(obj, newVal);
  4634. } else {
  4635. val = newVal;
  4636. }
  4637. childOb = !shallow && observe(newVal);
  4638. dep.notify();
  4639. }
  4640. });
  4641. }
  4642. /**
  4643. * Set a property on an object. Adds the new property and
  4644. * triggers change notification if the property doesn't
  4645. * already exist.
  4646. */
  4647. function set (target, key, val) {
  4648. if ( true &&
  4649. (isUndef(target) || isPrimitive(target))
  4650. ) {
  4651. warn(("Cannot set reactive property on undefined, null, or primitive value: " + ((target))));
  4652. }
  4653. if (Array.isArray(target) && isValidArrayIndex(key)) {
  4654. target.length = Math.max(target.length, key);
  4655. target.splice(key, 1, val);
  4656. return val
  4657. }
  4658. if (key in target && !(key in Object.prototype)) {
  4659. target[key] = val;
  4660. return val
  4661. }
  4662. var ob = (target).__ob__;
  4663. if (target._isVue || (ob && ob.vmCount)) {
  4664. true && warn(
  4665. 'Avoid adding reactive properties to a Vue instance or its root $data ' +
  4666. 'at runtime - declare it upfront in the data option.'
  4667. );
  4668. return val
  4669. }
  4670. if (!ob) {
  4671. target[key] = val;
  4672. return val
  4673. }
  4674. defineReactive$$1(ob.value, key, val);
  4675. ob.dep.notify();
  4676. return val
  4677. }
  4678. /**
  4679. * Delete a property and trigger change if necessary.
  4680. */
  4681. function del (target, key) {
  4682. if ( true &&
  4683. (isUndef(target) || isPrimitive(target))
  4684. ) {
  4685. warn(("Cannot delete reactive property on undefined, null, or primitive value: " + ((target))));
  4686. }
  4687. if (Array.isArray(target) && isValidArrayIndex(key)) {
  4688. target.splice(key, 1);
  4689. return
  4690. }
  4691. var ob = (target).__ob__;
  4692. if (target._isVue || (ob && ob.vmCount)) {
  4693. true && warn(
  4694. 'Avoid deleting properties on a Vue instance or its root $data ' +
  4695. '- just set it to null.'
  4696. );
  4697. return
  4698. }
  4699. if (!hasOwn(target, key)) {
  4700. return
  4701. }
  4702. delete target[key];
  4703. if (!ob) {
  4704. return
  4705. }
  4706. ob.dep.notify();
  4707. }
  4708. /**
  4709. * Collect dependencies on array elements when the array is touched, since
  4710. * we cannot intercept array element access like property getters.
  4711. */
  4712. function dependArray (value) {
  4713. for (var e = (void 0), i = 0, l = value.length; i < l; i++) {
  4714. e = value[i];
  4715. e && e.__ob__ && e.__ob__.dep.depend();
  4716. if (Array.isArray(e)) {
  4717. dependArray(e);
  4718. }
  4719. }
  4720. }
  4721. /* */
  4722. /**
  4723. * Option overwriting strategies are functions that handle
  4724. * how to merge a parent option value and a child option
  4725. * value into the final value.
  4726. */
  4727. var strats = config.optionMergeStrategies;
  4728. /**
  4729. * Options with restrictions
  4730. */
  4731. if (true) {
  4732. strats.el = strats.propsData = function (parent, child, vm, key) {
  4733. if (!vm) {
  4734. warn(
  4735. "option \"" + key + "\" can only be used during instance " +
  4736. 'creation with the `new` keyword.'
  4737. );
  4738. }
  4739. return defaultStrat(parent, child)
  4740. };
  4741. }
  4742. /**
  4743. * Helper that recursively merges two data objects together.
  4744. */
  4745. function mergeData (to, from) {
  4746. if (!from) { return to }
  4747. var key, toVal, fromVal;
  4748. var keys = hasSymbol
  4749. ? Reflect.ownKeys(from)
  4750. : Object.keys(from);
  4751. for (var i = 0; i < keys.length; i++) {
  4752. key = keys[i];
  4753. // in case the object is already observed...
  4754. if (key === '__ob__') { continue }
  4755. toVal = to[key];
  4756. fromVal = from[key];
  4757. if (!hasOwn(to, key)) {
  4758. set(to, key, fromVal);
  4759. } else if (
  4760. toVal !== fromVal &&
  4761. isPlainObject(toVal) &&
  4762. isPlainObject(fromVal)
  4763. ) {
  4764. mergeData(toVal, fromVal);
  4765. }
  4766. }
  4767. return to
  4768. }
  4769. /**
  4770. * Data
  4771. */
  4772. function mergeDataOrFn (
  4773. parentVal,
  4774. childVal,
  4775. vm
  4776. ) {
  4777. if (!vm) {
  4778. // in a Vue.extend merge, both should be functions
  4779. if (!childVal) {
  4780. return parentVal
  4781. }
  4782. if (!parentVal) {
  4783. return childVal
  4784. }
  4785. // when parentVal & childVal are both present,
  4786. // we need to return a function that returns the
  4787. // merged result of both functions... no need to
  4788. // check if parentVal is a function here because
  4789. // it has to be a function to pass previous merges.
  4790. return function mergedDataFn () {
  4791. return mergeData(
  4792. typeof childVal === 'function' ? childVal.call(this, this) : childVal,
  4793. typeof parentVal === 'function' ? parentVal.call(this, this) : parentVal
  4794. )
  4795. }
  4796. } else {
  4797. return function mergedInstanceDataFn () {
  4798. // instance merge
  4799. var instanceData = typeof childVal === 'function'
  4800. ? childVal.call(vm, vm)
  4801. : childVal;
  4802. var defaultData = typeof parentVal === 'function'
  4803. ? parentVal.call(vm, vm)
  4804. : parentVal;
  4805. if (instanceData) {
  4806. return mergeData(instanceData, defaultData)
  4807. } else {
  4808. return defaultData
  4809. }
  4810. }
  4811. }
  4812. }
  4813. strats.data = function (
  4814. parentVal,
  4815. childVal,
  4816. vm
  4817. ) {
  4818. if (!vm) {
  4819. if (childVal && typeof childVal !== 'function') {
  4820. true && warn(
  4821. 'The "data" option should be a function ' +
  4822. 'that returns a per-instance value in component ' +
  4823. 'definitions.',
  4824. vm
  4825. );
  4826. return parentVal
  4827. }
  4828. return mergeDataOrFn(parentVal, childVal)
  4829. }
  4830. return mergeDataOrFn(parentVal, childVal, vm)
  4831. };
  4832. /**
  4833. * Hooks and props are merged as arrays.
  4834. */
  4835. function mergeHook (
  4836. parentVal,
  4837. childVal
  4838. ) {
  4839. var res = childVal
  4840. ? parentVal
  4841. ? parentVal.concat(childVal)
  4842. : Array.isArray(childVal)
  4843. ? childVal
  4844. : [childVal]
  4845. : parentVal;
  4846. return res
  4847. ? dedupeHooks(res)
  4848. : res
  4849. }
  4850. function dedupeHooks (hooks) {
  4851. var res = [];
  4852. for (var i = 0; i < hooks.length; i++) {
  4853. if (res.indexOf(hooks[i]) === -1) {
  4854. res.push(hooks[i]);
  4855. }
  4856. }
  4857. return res
  4858. }
  4859. LIFECYCLE_HOOKS.forEach(function (hook) {
  4860. strats[hook] = mergeHook;
  4861. });
  4862. /**
  4863. * Assets
  4864. *
  4865. * When a vm is present (instance creation), we need to do
  4866. * a three-way merge between constructor options, instance
  4867. * options and parent options.
  4868. */
  4869. function mergeAssets (
  4870. parentVal,
  4871. childVal,
  4872. vm,
  4873. key
  4874. ) {
  4875. var res = Object.create(parentVal || null);
  4876. if (childVal) {
  4877. true && assertObjectType(key, childVal, vm);
  4878. return extend(res, childVal)
  4879. } else {
  4880. return res
  4881. }
  4882. }
  4883. ASSET_TYPES.forEach(function (type) {
  4884. strats[type + 's'] = mergeAssets;
  4885. });
  4886. /**
  4887. * Watchers.
  4888. *
  4889. * Watchers hashes should not overwrite one
  4890. * another, so we merge them as arrays.
  4891. */
  4892. strats.watch = function (
  4893. parentVal,
  4894. childVal,
  4895. vm,
  4896. key
  4897. ) {
  4898. // work around Firefox's Object.prototype.watch...
  4899. if (parentVal === nativeWatch) { parentVal = undefined; }
  4900. if (childVal === nativeWatch) { childVal = undefined; }
  4901. /* istanbul ignore if */
  4902. if (!childVal) { return Object.create(parentVal || null) }
  4903. if (true) {
  4904. assertObjectType(key, childVal, vm);
  4905. }
  4906. if (!parentVal) { return childVal }
  4907. var ret = {};
  4908. extend(ret, parentVal);
  4909. for (var key$1 in childVal) {
  4910. var parent = ret[key$1];
  4911. var child = childVal[key$1];
  4912. if (parent && !Array.isArray(parent)) {
  4913. parent = [parent];
  4914. }
  4915. ret[key$1] = parent
  4916. ? parent.concat(child)
  4917. : Array.isArray(child) ? child : [child];
  4918. }
  4919. return ret
  4920. };
  4921. /**
  4922. * Other object hashes.
  4923. */
  4924. strats.props =
  4925. strats.methods =
  4926. strats.inject =
  4927. strats.computed = function (
  4928. parentVal,
  4929. childVal,
  4930. vm,
  4931. key
  4932. ) {
  4933. if (childVal && "development" !== 'production') {
  4934. assertObjectType(key, childVal, vm);
  4935. }
  4936. if (!parentVal) { return childVal }
  4937. var ret = Object.create(null);
  4938. extend(ret, parentVal);
  4939. if (childVal) { extend(ret, childVal); }
  4940. return ret
  4941. };
  4942. strats.provide = mergeDataOrFn;
  4943. /**
  4944. * Default strategy.
  4945. */
  4946. var defaultStrat = function (parentVal, childVal) {
  4947. return childVal === undefined
  4948. ? parentVal
  4949. : childVal
  4950. };
  4951. /**
  4952. * Validate component names
  4953. */
  4954. function checkComponents (options) {
  4955. for (var key in options.components) {
  4956. validateComponentName(key);
  4957. }
  4958. }
  4959. function validateComponentName (name) {
  4960. if (!new RegExp(("^[a-zA-Z][\\-\\.0-9_" + (unicodeRegExp.source) + "]*$")).test(name)) {
  4961. warn(
  4962. 'Invalid component name: "' + name + '". Component names ' +
  4963. 'should conform to valid custom element name in html5 specification.'
  4964. );
  4965. }
  4966. if (isBuiltInTag(name) || config.isReservedTag(name)) {
  4967. warn(
  4968. 'Do not use built-in or reserved HTML elements as component ' +
  4969. 'id: ' + name
  4970. );
  4971. }
  4972. }
  4973. /**
  4974. * Ensure all props option syntax are normalized into the
  4975. * Object-based format.
  4976. */
  4977. function normalizeProps (options, vm) {
  4978. var props = options.props;
  4979. if (!props) { return }
  4980. var res = {};
  4981. var i, val, name;
  4982. if (Array.isArray(props)) {
  4983. i = props.length;
  4984. while (i--) {
  4985. val = props[i];
  4986. if (typeof val === 'string') {
  4987. name = camelize(val);
  4988. res[name] = { type: null };
  4989. } else if (true) {
  4990. warn('props must be strings when using array syntax.');
  4991. }
  4992. }
  4993. } else if (isPlainObject(props)) {
  4994. for (var key in props) {
  4995. val = props[key];
  4996. name = camelize(key);
  4997. res[name] = isPlainObject(val)
  4998. ? val
  4999. : { type: val };
  5000. }
  5001. } else if (true) {
  5002. warn(
  5003. "Invalid value for option \"props\": expected an Array or an Object, " +
  5004. "but got " + (toRawType(props)) + ".",
  5005. vm
  5006. );
  5007. }
  5008. options.props = res;
  5009. }
  5010. /**
  5011. * Normalize all injections into Object-based format
  5012. */
  5013. function normalizeInject (options, vm) {
  5014. var inject = options.inject;
  5015. if (!inject) { return }
  5016. var normalized = options.inject = {};
  5017. if (Array.isArray(inject)) {
  5018. for (var i = 0; i < inject.length; i++) {
  5019. normalized[inject[i]] = { from: inject[i] };
  5020. }
  5021. } else if (isPlainObject(inject)) {
  5022. for (var key in inject) {
  5023. var val = inject[key];
  5024. normalized[key] = isPlainObject(val)
  5025. ? extend({ from: key }, val)
  5026. : { from: val };
  5027. }
  5028. } else if (true) {
  5029. warn(
  5030. "Invalid value for option \"inject\": expected an Array or an Object, " +
  5031. "but got " + (toRawType(inject)) + ".",
  5032. vm
  5033. );
  5034. }
  5035. }
  5036. /**
  5037. * Normalize raw function directives into object format.
  5038. */
  5039. function normalizeDirectives (options) {
  5040. var dirs = options.directives;
  5041. if (dirs) {
  5042. for (var key in dirs) {
  5043. var def$$1 = dirs[key];
  5044. if (typeof def$$1 === 'function') {
  5045. dirs[key] = { bind: def$$1, update: def$$1 };
  5046. }
  5047. }
  5048. }
  5049. }
  5050. function assertObjectType (name, value, vm) {
  5051. if (!isPlainObject(value)) {
  5052. warn(
  5053. "Invalid value for option \"" + name + "\": expected an Object, " +
  5054. "but got " + (toRawType(value)) + ".",
  5055. vm
  5056. );
  5057. }
  5058. }
  5059. /**
  5060. * Merge two option objects into a new one.
  5061. * Core utility used in both instantiation and inheritance.
  5062. */
  5063. function mergeOptions (
  5064. parent,
  5065. child,
  5066. vm
  5067. ) {
  5068. if (true) {
  5069. checkComponents(child);
  5070. }
  5071. if (typeof child === 'function') {
  5072. child = child.options;
  5073. }
  5074. normalizeProps(child, vm);
  5075. normalizeInject(child, vm);
  5076. normalizeDirectives(child);
  5077. // Apply extends and mixins on the child options,
  5078. // but only if it is a raw options object that isn't
  5079. // the result of another mergeOptions call.
  5080. // Only merged options has the _base property.
  5081. if (!child._base) {
  5082. if (child.extends) {
  5083. parent = mergeOptions(parent, child.extends, vm);
  5084. }
  5085. if (child.mixins) {
  5086. for (var i = 0, l = child.mixins.length; i < l; i++) {
  5087. parent = mergeOptions(parent, child.mixins[i], vm);
  5088. }
  5089. }
  5090. }
  5091. var options = {};
  5092. var key;
  5093. for (key in parent) {
  5094. mergeField(key);
  5095. }
  5096. for (key in child) {
  5097. if (!hasOwn(parent, key)) {
  5098. mergeField(key);
  5099. }
  5100. }
  5101. function mergeField (key) {
  5102. var strat = strats[key] || defaultStrat;
  5103. options[key] = strat(parent[key], child[key], vm, key);
  5104. }
  5105. return options
  5106. }
  5107. /**
  5108. * Resolve an asset.
  5109. * This function is used because child instances need access
  5110. * to assets defined in its ancestor chain.
  5111. */
  5112. function resolveAsset (
  5113. options,
  5114. type,
  5115. id,
  5116. warnMissing
  5117. ) {
  5118. /* istanbul ignore if */
  5119. if (typeof id !== 'string') {
  5120. return
  5121. }
  5122. var assets = options[type];
  5123. // check local registration variations first
  5124. if (hasOwn(assets, id)) { return assets[id] }
  5125. var camelizedId = camelize(id);
  5126. if (hasOwn(assets, camelizedId)) { return assets[camelizedId] }
  5127. var PascalCaseId = capitalize(camelizedId);
  5128. if (hasOwn(assets, PascalCaseId)) { return assets[PascalCaseId] }
  5129. // fallback to prototype chain
  5130. var res = assets[id] || assets[camelizedId] || assets[PascalCaseId];
  5131. if ( true && warnMissing && !res) {
  5132. warn(
  5133. 'Failed to resolve ' + type.slice(0, -1) + ': ' + id,
  5134. options
  5135. );
  5136. }
  5137. return res
  5138. }
  5139. /* */
  5140. function validateProp (
  5141. key,
  5142. propOptions,
  5143. propsData,
  5144. vm
  5145. ) {
  5146. var prop = propOptions[key];
  5147. var absent = !hasOwn(propsData, key);
  5148. var value = propsData[key];
  5149. // boolean casting
  5150. var booleanIndex = getTypeIndex(Boolean, prop.type);
  5151. if (booleanIndex > -1) {
  5152. if (absent && !hasOwn(prop, 'default')) {
  5153. value = false;
  5154. } else if (value === '' || value === hyphenate(key)) {
  5155. // only cast empty string / same name to boolean if
  5156. // boolean has higher priority
  5157. var stringIndex = getTypeIndex(String, prop.type);
  5158. if (stringIndex < 0 || booleanIndex < stringIndex) {
  5159. value = true;
  5160. }
  5161. }
  5162. }
  5163. // check default value
  5164. if (value === undefined) {
  5165. value = getPropDefaultValue(vm, prop, key);
  5166. // since the default value is a fresh copy,
  5167. // make sure to observe it.
  5168. var prevShouldObserve = shouldObserve;
  5169. toggleObserving(true);
  5170. observe(value);
  5171. toggleObserving(prevShouldObserve);
  5172. }
  5173. if (
  5174. true
  5175. ) {
  5176. assertProp(prop, key, value, vm, absent);
  5177. }
  5178. return value
  5179. }
  5180. /**
  5181. * Get the default value of a prop.
  5182. */
  5183. function getPropDefaultValue (vm, prop, key) {
  5184. // no default, return undefined
  5185. if (!hasOwn(prop, 'default')) {
  5186. return undefined
  5187. }
  5188. var def = prop.default;
  5189. // warn against non-factory defaults for Object & Array
  5190. if ( true && isObject(def)) {
  5191. warn(
  5192. 'Invalid default value for prop "' + key + '": ' +
  5193. 'Props with type Object/Array must use a factory function ' +
  5194. 'to return the default value.',
  5195. vm
  5196. );
  5197. }
  5198. // the raw prop value was also undefined from previous render,
  5199. // return previous default value to avoid unnecessary watcher trigger
  5200. if (vm && vm.$options.propsData &&
  5201. vm.$options.propsData[key] === undefined &&
  5202. vm._props[key] !== undefined
  5203. ) {
  5204. return vm._props[key]
  5205. }
  5206. // call factory function for non-Function types
  5207. // a value is Function if its prototype is function even across different execution context
  5208. return typeof def === 'function' && getType(prop.type) !== 'Function'
  5209. ? def.call(vm)
  5210. : def
  5211. }
  5212. /**
  5213. * Assert whether a prop is valid.
  5214. */
  5215. function assertProp (
  5216. prop,
  5217. name,
  5218. value,
  5219. vm,
  5220. absent
  5221. ) {
  5222. if (prop.required && absent) {
  5223. warn(
  5224. 'Missing required prop: "' + name + '"',
  5225. vm
  5226. );
  5227. return
  5228. }
  5229. if (value == null && !prop.required) {
  5230. return
  5231. }
  5232. var type = prop.type;
  5233. var valid = !type || type === true;
  5234. var expectedTypes = [];
  5235. if (type) {
  5236. if (!Array.isArray(type)) {
  5237. type = [type];
  5238. }
  5239. for (var i = 0; i < type.length && !valid; i++) {
  5240. var assertedType = assertType(value, type[i]);
  5241. expectedTypes.push(assertedType.expectedType || '');
  5242. valid = assertedType.valid;
  5243. }
  5244. }
  5245. if (!valid) {
  5246. warn(
  5247. getInvalidTypeMessage(name, value, expectedTypes),
  5248. vm
  5249. );
  5250. return
  5251. }
  5252. var validator = prop.validator;
  5253. if (validator) {
  5254. if (!validator(value)) {
  5255. warn(
  5256. 'Invalid prop: custom validator check failed for prop "' + name + '".',
  5257. vm
  5258. );
  5259. }
  5260. }
  5261. }
  5262. var simpleCheckRE = /^(String|Number|Boolean|Function|Symbol)$/;
  5263. function assertType (value, type) {
  5264. var valid;
  5265. var expectedType = getType(type);
  5266. if (simpleCheckRE.test(expectedType)) {
  5267. var t = typeof value;
  5268. valid = t === expectedType.toLowerCase();
  5269. // for primitive wrapper objects
  5270. if (!valid && t === 'object') {
  5271. valid = value instanceof type;
  5272. }
  5273. } else if (expectedType === 'Object') {
  5274. valid = isPlainObject(value);
  5275. } else if (expectedType === 'Array') {
  5276. valid = Array.isArray(value);
  5277. } else {
  5278. valid = value instanceof type;
  5279. }
  5280. return {
  5281. valid: valid,
  5282. expectedType: expectedType
  5283. }
  5284. }
  5285. /**
  5286. * Use function string name to check built-in types,
  5287. * because a simple equality check will fail when running
  5288. * across different vms / iframes.
  5289. */
  5290. function getType (fn) {
  5291. var match = fn && fn.toString().match(/^\s*function (\w+)/);
  5292. return match ? match[1] : ''
  5293. }
  5294. function isSameType (a, b) {
  5295. return getType(a) === getType(b)
  5296. }
  5297. function getTypeIndex (type, expectedTypes) {
  5298. if (!Array.isArray(expectedTypes)) {
  5299. return isSameType(expectedTypes, type) ? 0 : -1
  5300. }
  5301. for (var i = 0, len = expectedTypes.length; i < len; i++) {
  5302. if (isSameType(expectedTypes[i], type)) {
  5303. return i
  5304. }
  5305. }
  5306. return -1
  5307. }
  5308. function getInvalidTypeMessage (name, value, expectedTypes) {
  5309. var message = "Invalid prop: type check failed for prop \"" + name + "\"." +
  5310. " Expected " + (expectedTypes.map(capitalize).join(', '));
  5311. var expectedType = expectedTypes[0];
  5312. var receivedType = toRawType(value);
  5313. var expectedValue = styleValue(value, expectedType);
  5314. var receivedValue = styleValue(value, receivedType);
  5315. // check if we need to specify expected value
  5316. if (expectedTypes.length === 1 &&
  5317. isExplicable(expectedType) &&
  5318. !isBoolean(expectedType, receivedType)) {
  5319. message += " with value " + expectedValue;
  5320. }
  5321. message += ", got " + receivedType + " ";
  5322. // check if we need to specify received value
  5323. if (isExplicable(receivedType)) {
  5324. message += "with value " + receivedValue + ".";
  5325. }
  5326. return message
  5327. }
  5328. function styleValue (value, type) {
  5329. if (type === 'String') {
  5330. return ("\"" + value + "\"")
  5331. } else if (type === 'Number') {
  5332. return ("" + (Number(value)))
  5333. } else {
  5334. return ("" + value)
  5335. }
  5336. }
  5337. function isExplicable (value) {
  5338. var explicitTypes = ['string', 'number', 'boolean'];
  5339. return explicitTypes.some(function (elem) { return value.toLowerCase() === elem; })
  5340. }
  5341. function isBoolean () {
  5342. var args = [], len = arguments.length;
  5343. while ( len-- ) args[ len ] = arguments[ len ];
  5344. return args.some(function (elem) { return elem.toLowerCase() === 'boolean'; })
  5345. }
  5346. /* */
  5347. function handleError (err, vm, info) {
  5348. // Deactivate deps tracking while processing error handler to avoid possible infinite rendering.
  5349. // See: https://github.com/vuejs/vuex/issues/1505
  5350. pushTarget();
  5351. try {
  5352. if (vm) {
  5353. var cur = vm;
  5354. while ((cur = cur.$parent)) {
  5355. var hooks = cur.$options.errorCaptured;
  5356. if (hooks) {
  5357. for (var i = 0; i < hooks.length; i++) {
  5358. try {
  5359. var capture = hooks[i].call(cur, err, vm, info) === false;
  5360. if (capture) { return }
  5361. } catch (e) {
  5362. globalHandleError(e, cur, 'errorCaptured hook');
  5363. }
  5364. }
  5365. }
  5366. }
  5367. }
  5368. globalHandleError(err, vm, info);
  5369. } finally {
  5370. popTarget();
  5371. }
  5372. }
  5373. function invokeWithErrorHandling (
  5374. handler,
  5375. context,
  5376. args,
  5377. vm,
  5378. info
  5379. ) {
  5380. var res;
  5381. try {
  5382. res = args ? handler.apply(context, args) : handler.call(context);
  5383. if (res && !res._isVue && isPromise(res) && !res._handled) {
  5384. res.catch(function (e) { return handleError(e, vm, info + " (Promise/async)"); });
  5385. // issue #9511
  5386. // avoid catch triggering multiple times when nested calls
  5387. res._handled = true;
  5388. }
  5389. } catch (e) {
  5390. handleError(e, vm, info);
  5391. }
  5392. return res
  5393. }
  5394. function globalHandleError (err, vm, info) {
  5395. if (config.errorHandler) {
  5396. try {
  5397. return config.errorHandler.call(null, err, vm, info)
  5398. } catch (e) {
  5399. // if the user intentionally throws the original error in the handler,
  5400. // do not log it twice
  5401. if (e !== err) {
  5402. logError(e, null, 'config.errorHandler');
  5403. }
  5404. }
  5405. }
  5406. logError(err, vm, info);
  5407. }
  5408. function logError (err, vm, info) {
  5409. if (true) {
  5410. warn(("Error in " + info + ": \"" + (err.toString()) + "\""), vm);
  5411. }
  5412. /* istanbul ignore else */
  5413. if ((inBrowser || inWeex) && typeof console !== 'undefined') {
  5414. console.error(err);
  5415. } else {
  5416. throw err
  5417. }
  5418. }
  5419. /* */
  5420. var callbacks = [];
  5421. var pending = false;
  5422. function flushCallbacks () {
  5423. pending = false;
  5424. var copies = callbacks.slice(0);
  5425. callbacks.length = 0;
  5426. for (var i = 0; i < copies.length; i++) {
  5427. copies[i]();
  5428. }
  5429. }
  5430. // Here we have async deferring wrappers using microtasks.
  5431. // In 2.5 we used (macro) tasks (in combination with microtasks).
  5432. // However, it has subtle problems when state is changed right before repaint
  5433. // (e.g. #6813, out-in transitions).
  5434. // Also, using (macro) tasks in event handler would cause some weird behaviors
  5435. // that cannot be circumvented (e.g. #7109, #7153, #7546, #7834, #8109).
  5436. // So we now use microtasks everywhere, again.
  5437. // A major drawback of this tradeoff is that there are some scenarios
  5438. // where microtasks have too high a priority and fire in between supposedly
  5439. // sequential events (e.g. #4521, #6690, which have workarounds)
  5440. // or even between bubbling of the same event (#6566).
  5441. var timerFunc;
  5442. // The nextTick behavior leverages the microtask queue, which can be accessed
  5443. // via either native Promise.then or MutationObserver.
  5444. // MutationObserver has wider support, however it is seriously bugged in
  5445. // UIWebView in iOS >= 9.3.3 when triggered in touch event handlers. It
  5446. // completely stops working after triggering a few times... so, if native
  5447. // Promise is available, we will use it:
  5448. /* istanbul ignore next, $flow-disable-line */
  5449. if (typeof Promise !== 'undefined' && isNative(Promise)) {
  5450. var p = Promise.resolve();
  5451. timerFunc = function () {
  5452. p.then(flushCallbacks);
  5453. // In problematic UIWebViews, Promise.then doesn't completely break, but
  5454. // it can get stuck in a weird state where callbacks are pushed into the
  5455. // microtask queue but the queue isn't being flushed, until the browser
  5456. // needs to do some other work, e.g. handle a timer. Therefore we can
  5457. // "force" the microtask queue to be flushed by adding an empty timer.
  5458. if (isIOS) { setTimeout(noop); }
  5459. };
  5460. } else if (!isIE && typeof MutationObserver !== 'undefined' && (
  5461. isNative(MutationObserver) ||
  5462. // PhantomJS and iOS 7.x
  5463. MutationObserver.toString() === '[object MutationObserverConstructor]'
  5464. )) {
  5465. // Use MutationObserver where native Promise is not available,
  5466. // e.g. PhantomJS, iOS7, Android 4.4
  5467. // (#6466 MutationObserver is unreliable in IE11)
  5468. var counter = 1;
  5469. var observer = new MutationObserver(flushCallbacks);
  5470. var textNode = document.createTextNode(String(counter));
  5471. observer.observe(textNode, {
  5472. characterData: true
  5473. });
  5474. timerFunc = function () {
  5475. counter = (counter + 1) % 2;
  5476. textNode.data = String(counter);
  5477. };
  5478. } else if (typeof setImmediate !== 'undefined' && isNative(setImmediate)) {
  5479. // Fallback to setImmediate.
  5480. // Technically it leverages the (macro) task queue,
  5481. // but it is still a better choice than setTimeout.
  5482. timerFunc = function () {
  5483. setImmediate(flushCallbacks);
  5484. };
  5485. } else {
  5486. // Fallback to setTimeout.
  5487. timerFunc = function () {
  5488. setTimeout(flushCallbacks, 0);
  5489. };
  5490. }
  5491. function nextTick (cb, ctx) {
  5492. var _resolve;
  5493. callbacks.push(function () {
  5494. if (cb) {
  5495. try {
  5496. cb.call(ctx);
  5497. } catch (e) {
  5498. handleError(e, ctx, 'nextTick');
  5499. }
  5500. } else if (_resolve) {
  5501. _resolve(ctx);
  5502. }
  5503. });
  5504. if (!pending) {
  5505. pending = true;
  5506. timerFunc();
  5507. }
  5508. // $flow-disable-line
  5509. if (!cb && typeof Promise !== 'undefined') {
  5510. return new Promise(function (resolve) {
  5511. _resolve = resolve;
  5512. })
  5513. }
  5514. }
  5515. /* */
  5516. /* not type checking this file because flow doesn't play well with Proxy */
  5517. var initProxy;
  5518. if (true) {
  5519. var allowedGlobals = makeMap(
  5520. 'Infinity,undefined,NaN,isFinite,isNaN,' +
  5521. 'parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,' +
  5522. 'Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,' +
  5523. 'require' // for Webpack/Browserify
  5524. );
  5525. var warnNonPresent = function (target, key) {
  5526. warn(
  5527. "Property or method \"" + key + "\" is not defined on the instance but " +
  5528. 'referenced during render. Make sure that this property is reactive, ' +
  5529. 'either in the data option, or for class-based components, by ' +
  5530. 'initializing the property. ' +
  5531. 'See: https://vuejs.org/v2/guide/reactivity.html#Declaring-Reactive-Properties.',
  5532. target
  5533. );
  5534. };
  5535. var warnReservedPrefix = function (target, key) {
  5536. warn(
  5537. "Property \"" + key + "\" must be accessed with \"$data." + key + "\" because " +
  5538. 'properties starting with "$" or "_" are not proxied in the Vue instance to ' +
  5539. 'prevent conflicts with Vue internals. ' +
  5540. 'See: https://vuejs.org/v2/api/#data',
  5541. target
  5542. );
  5543. };
  5544. var hasProxy =
  5545. typeof Proxy !== 'undefined' && isNative(Proxy);
  5546. if (hasProxy) {
  5547. var isBuiltInModifier = makeMap('stop,prevent,self,ctrl,shift,alt,meta,exact');
  5548. config.keyCodes = new Proxy(config.keyCodes, {
  5549. set: function set (target, key, value) {
  5550. if (isBuiltInModifier(key)) {
  5551. warn(("Avoid overwriting built-in modifier in config.keyCodes: ." + key));
  5552. return false
  5553. } else {
  5554. target[key] = value;
  5555. return true
  5556. }
  5557. }
  5558. });
  5559. }
  5560. var hasHandler = {
  5561. has: function has (target, key) {
  5562. var has = key in target;
  5563. var isAllowed = allowedGlobals(key) ||
  5564. (typeof key === 'string' && key.charAt(0) === '_' && !(key in target.$data));
  5565. if (!has && !isAllowed) {
  5566. if (key in target.$data) { warnReservedPrefix(target, key); }
  5567. else { warnNonPresent(target, key); }
  5568. }
  5569. return has || !isAllowed
  5570. }
  5571. };
  5572. var getHandler = {
  5573. get: function get (target, key) {
  5574. if (typeof key === 'string' && !(key in target)) {
  5575. if (key in target.$data) { warnReservedPrefix(target, key); }
  5576. else { warnNonPresent(target, key); }
  5577. }
  5578. return target[key]
  5579. }
  5580. };
  5581. initProxy = function initProxy (vm) {
  5582. if (hasProxy) {
  5583. // determine which proxy handler to use
  5584. var options = vm.$options;
  5585. var handlers = options.render && options.render._withStripped
  5586. ? getHandler
  5587. : hasHandler;
  5588. vm._renderProxy = new Proxy(vm, handlers);
  5589. } else {
  5590. vm._renderProxy = vm;
  5591. }
  5592. };
  5593. }
  5594. /* */
  5595. var seenObjects = new _Set();
  5596. /**
  5597. * Recursively traverse an object to evoke all converted
  5598. * getters, so that every nested property inside the object
  5599. * is collected as a "deep" dependency.
  5600. */
  5601. function traverse (val) {
  5602. _traverse(val, seenObjects);
  5603. seenObjects.clear();
  5604. }
  5605. function _traverse (val, seen) {
  5606. var i, keys;
  5607. var isA = Array.isArray(val);
  5608. if ((!isA && !isObject(val)) || Object.isFrozen(val) || val instanceof VNode) {
  5609. return
  5610. }
  5611. if (val.__ob__) {
  5612. var depId = val.__ob__.dep.id;
  5613. if (seen.has(depId)) {
  5614. return
  5615. }
  5616. seen.add(depId);
  5617. }
  5618. if (isA) {
  5619. i = val.length;
  5620. while (i--) { _traverse(val[i], seen); }
  5621. } else {
  5622. keys = Object.keys(val);
  5623. i = keys.length;
  5624. while (i--) { _traverse(val[keys[i]], seen); }
  5625. }
  5626. }
  5627. var mark;
  5628. var measure;
  5629. if (true) {
  5630. var perf = inBrowser && window.performance;
  5631. /* istanbul ignore if */
  5632. if (
  5633. perf &&
  5634. perf.mark &&
  5635. perf.measure &&
  5636. perf.clearMarks &&
  5637. perf.clearMeasures
  5638. ) {
  5639. mark = function (tag) { return perf.mark(tag); };
  5640. measure = function (name, startTag, endTag) {
  5641. perf.measure(name, startTag, endTag);
  5642. perf.clearMarks(startTag);
  5643. perf.clearMarks(endTag);
  5644. // perf.clearMeasures(name)
  5645. };
  5646. }
  5647. }
  5648. /* */
  5649. var normalizeEvent = cached(function (name) {
  5650. var passive = name.charAt(0) === '&';
  5651. name = passive ? name.slice(1) : name;
  5652. var once$$1 = name.charAt(0) === '~'; // Prefixed last, checked first
  5653. name = once$$1 ? name.slice(1) : name;
  5654. var capture = name.charAt(0) === '!';
  5655. name = capture ? name.slice(1) : name;
  5656. return {
  5657. name: name,
  5658. once: once$$1,
  5659. capture: capture,
  5660. passive: passive
  5661. }
  5662. });
  5663. function createFnInvoker (fns, vm) {
  5664. function invoker () {
  5665. var arguments$1 = arguments;
  5666. var fns = invoker.fns;
  5667. if (Array.isArray(fns)) {
  5668. var cloned = fns.slice();
  5669. for (var i = 0; i < cloned.length; i++) {
  5670. invokeWithErrorHandling(cloned[i], null, arguments$1, vm, "v-on handler");
  5671. }
  5672. } else {
  5673. // return handler return value for single handlers
  5674. return invokeWithErrorHandling(fns, null, arguments, vm, "v-on handler")
  5675. }
  5676. }
  5677. invoker.fns = fns;
  5678. return invoker
  5679. }
  5680. function updateListeners (
  5681. on,
  5682. oldOn,
  5683. add,
  5684. remove$$1,
  5685. createOnceHandler,
  5686. vm
  5687. ) {
  5688. var name, def$$1, cur, old, event;
  5689. for (name in on) {
  5690. def$$1 = cur = on[name];
  5691. old = oldOn[name];
  5692. event = normalizeEvent(name);
  5693. if (isUndef(cur)) {
  5694. true && warn(
  5695. "Invalid handler for event \"" + (event.name) + "\": got " + String(cur),
  5696. vm
  5697. );
  5698. } else if (isUndef(old)) {
  5699. if (isUndef(cur.fns)) {
  5700. cur = on[name] = createFnInvoker(cur, vm);
  5701. }
  5702. if (isTrue(event.once)) {
  5703. cur = on[name] = createOnceHandler(event.name, cur, event.capture);
  5704. }
  5705. add(event.name, cur, event.capture, event.passive, event.params);
  5706. } else if (cur !== old) {
  5707. old.fns = cur;
  5708. on[name] = old;
  5709. }
  5710. }
  5711. for (name in oldOn) {
  5712. if (isUndef(on[name])) {
  5713. event = normalizeEvent(name);
  5714. remove$$1(event.name, oldOn[name], event.capture);
  5715. }
  5716. }
  5717. }
  5718. /* */
  5719. /* */
  5720. // fixed by xxxxxx (mp properties)
  5721. function extractPropertiesFromVNodeData(data, Ctor, res, context) {
  5722. var propOptions = Ctor.options.mpOptions && Ctor.options.mpOptions.properties;
  5723. if (isUndef(propOptions)) {
  5724. return res
  5725. }
  5726. var externalClasses = Ctor.options.mpOptions.externalClasses || [];
  5727. var attrs = data.attrs;
  5728. var props = data.props;
  5729. if (isDef(attrs) || isDef(props)) {
  5730. for (var key in propOptions) {
  5731. var altKey = hyphenate(key);
  5732. var result = checkProp(res, props, key, altKey, true) ||
  5733. checkProp(res, attrs, key, altKey, false);
  5734. // externalClass
  5735. if (
  5736. result &&
  5737. res[key] &&
  5738. externalClasses.indexOf(altKey) !== -1 &&
  5739. context[camelize(res[key])]
  5740. ) {
  5741. // 赋值 externalClass 真正的值(模板里 externalClass 的值可能是字符串)
  5742. res[key] = context[camelize(res[key])];
  5743. }
  5744. }
  5745. }
  5746. return res
  5747. }
  5748. function extractPropsFromVNodeData (
  5749. data,
  5750. Ctor,
  5751. tag,
  5752. context// fixed by xxxxxx
  5753. ) {
  5754. // we are only extracting raw values here.
  5755. // validation and default values are handled in the child
  5756. // component itself.
  5757. var propOptions = Ctor.options.props;
  5758. if (isUndef(propOptions)) {
  5759. // fixed by xxxxxx
  5760. return extractPropertiesFromVNodeData(data, Ctor, {}, context)
  5761. }
  5762. var res = {};
  5763. var attrs = data.attrs;
  5764. var props = data.props;
  5765. if (isDef(attrs) || isDef(props)) {
  5766. for (var key in propOptions) {
  5767. var altKey = hyphenate(key);
  5768. if (true) {
  5769. var keyInLowerCase = key.toLowerCase();
  5770. if (
  5771. key !== keyInLowerCase &&
  5772. attrs && hasOwn(attrs, keyInLowerCase)
  5773. ) {
  5774. tip(
  5775. "Prop \"" + keyInLowerCase + "\" is passed to component " +
  5776. (formatComponentName(tag || Ctor)) + ", but the declared prop name is" +
  5777. " \"" + key + "\". " +
  5778. "Note that HTML attributes are case-insensitive and camelCased " +
  5779. "props need to use their kebab-case equivalents when using in-DOM " +
  5780. "templates. You should probably use \"" + altKey + "\" instead of \"" + key + "\"."
  5781. );
  5782. }
  5783. }
  5784. checkProp(res, props, key, altKey, true) ||
  5785. checkProp(res, attrs, key, altKey, false);
  5786. }
  5787. }
  5788. // fixed by xxxxxx
  5789. return extractPropertiesFromVNodeData(data, Ctor, res, context)
  5790. }
  5791. function checkProp (
  5792. res,
  5793. hash,
  5794. key,
  5795. altKey,
  5796. preserve
  5797. ) {
  5798. if (isDef(hash)) {
  5799. if (hasOwn(hash, key)) {
  5800. res[key] = hash[key];
  5801. if (!preserve) {
  5802. delete hash[key];
  5803. }
  5804. return true
  5805. } else if (hasOwn(hash, altKey)) {
  5806. res[key] = hash[altKey];
  5807. if (!preserve) {
  5808. delete hash[altKey];
  5809. }
  5810. return true
  5811. }
  5812. }
  5813. return false
  5814. }
  5815. /* */
  5816. // The template compiler attempts to minimize the need for normalization by
  5817. // statically analyzing the template at compile time.
  5818. //
  5819. // For plain HTML markup, normalization can be completely skipped because the
  5820. // generated render function is guaranteed to return Array<VNode>. There are
  5821. // two cases where extra normalization is needed:
  5822. // 1. When the children contains components - because a functional component
  5823. // may return an Array instead of a single root. In this case, just a simple
  5824. // normalization is needed - if any child is an Array, we flatten the whole
  5825. // thing with Array.prototype.concat. It is guaranteed to be only 1-level deep
  5826. // because functional components already normalize their own children.
  5827. function simpleNormalizeChildren (children) {
  5828. for (var i = 0; i < children.length; i++) {
  5829. if (Array.isArray(children[i])) {
  5830. return Array.prototype.concat.apply([], children)
  5831. }
  5832. }
  5833. return children
  5834. }
  5835. // 2. When the children contains constructs that always generated nested Arrays,
  5836. // e.g. <template>, <slot>, v-for, or when the children is provided by user
  5837. // with hand-written render functions / JSX. In such cases a full normalization
  5838. // is needed to cater to all possible types of children values.
  5839. function normalizeChildren (children) {
  5840. return isPrimitive(children)
  5841. ? [createTextVNode(children)]
  5842. : Array.isArray(children)
  5843. ? normalizeArrayChildren(children)
  5844. : undefined
  5845. }
  5846. function isTextNode (node) {
  5847. return isDef(node) && isDef(node.text) && isFalse(node.isComment)
  5848. }
  5849. function normalizeArrayChildren (children, nestedIndex) {
  5850. var res = [];
  5851. var i, c, lastIndex, last;
  5852. for (i = 0; i < children.length; i++) {
  5853. c = children[i];
  5854. if (isUndef(c) || typeof c === 'boolean') { continue }
  5855. lastIndex = res.length - 1;
  5856. last = res[lastIndex];
  5857. // nested
  5858. if (Array.isArray(c)) {
  5859. if (c.length > 0) {
  5860. c = normalizeArrayChildren(c, ((nestedIndex || '') + "_" + i));
  5861. // merge adjacent text nodes
  5862. if (isTextNode(c[0]) && isTextNode(last)) {
  5863. res[lastIndex] = createTextVNode(last.text + (c[0]).text);
  5864. c.shift();
  5865. }
  5866. res.push.apply(res, c);
  5867. }
  5868. } else if (isPrimitive(c)) {
  5869. if (isTextNode(last)) {
  5870. // merge adjacent text nodes
  5871. // this is necessary for SSR hydration because text nodes are
  5872. // essentially merged when rendered to HTML strings
  5873. res[lastIndex] = createTextVNode(last.text + c);
  5874. } else if (c !== '') {
  5875. // convert primitive to vnode
  5876. res.push(createTextVNode(c));
  5877. }
  5878. } else {
  5879. if (isTextNode(c) && isTextNode(last)) {
  5880. // merge adjacent text nodes
  5881. res[lastIndex] = createTextVNode(last.text + c.text);
  5882. } else {
  5883. // default key for nested array children (likely generated by v-for)
  5884. if (isTrue(children._isVList) &&
  5885. isDef(c.tag) &&
  5886. isUndef(c.key) &&
  5887. isDef(nestedIndex)) {
  5888. c.key = "__vlist" + nestedIndex + "_" + i + "__";
  5889. }
  5890. res.push(c);
  5891. }
  5892. }
  5893. }
  5894. return res
  5895. }
  5896. /* */
  5897. function initProvide (vm) {
  5898. var provide = vm.$options.provide;
  5899. if (provide) {
  5900. vm._provided = typeof provide === 'function'
  5901. ? provide.call(vm)
  5902. : provide;
  5903. }
  5904. }
  5905. function initInjections (vm) {
  5906. var result = resolveInject(vm.$options.inject, vm);
  5907. if (result) {
  5908. toggleObserving(false);
  5909. Object.keys(result).forEach(function (key) {
  5910. /* istanbul ignore else */
  5911. if (true) {
  5912. defineReactive$$1(vm, key, result[key], function () {
  5913. warn(
  5914. "Avoid mutating an injected value directly since the changes will be " +
  5915. "overwritten whenever the provided component re-renders. " +
  5916. "injection being mutated: \"" + key + "\"",
  5917. vm
  5918. );
  5919. });
  5920. } else {}
  5921. });
  5922. toggleObserving(true);
  5923. }
  5924. }
  5925. function resolveInject (inject, vm) {
  5926. if (inject) {
  5927. // inject is :any because flow is not smart enough to figure out cached
  5928. var result = Object.create(null);
  5929. var keys = hasSymbol
  5930. ? Reflect.ownKeys(inject)
  5931. : Object.keys(inject);
  5932. for (var i = 0; i < keys.length; i++) {
  5933. var key = keys[i];
  5934. // #6574 in case the inject object is observed...
  5935. if (key === '__ob__') { continue }
  5936. var provideKey = inject[key].from;
  5937. var source = vm;
  5938. while (source) {
  5939. if (source._provided && hasOwn(source._provided, provideKey)) {
  5940. result[key] = source._provided[provideKey];
  5941. break
  5942. }
  5943. source = source.$parent;
  5944. }
  5945. if (!source) {
  5946. if ('default' in inject[key]) {
  5947. var provideDefault = inject[key].default;
  5948. result[key] = typeof provideDefault === 'function'
  5949. ? provideDefault.call(vm)
  5950. : provideDefault;
  5951. } else if (true) {
  5952. warn(("Injection \"" + key + "\" not found"), vm);
  5953. }
  5954. }
  5955. }
  5956. return result
  5957. }
  5958. }
  5959. /* */
  5960. /**
  5961. * Runtime helper for resolving raw children VNodes into a slot object.
  5962. */
  5963. function resolveSlots (
  5964. children,
  5965. context
  5966. ) {
  5967. if (!children || !children.length) {
  5968. return {}
  5969. }
  5970. var slots = {};
  5971. for (var i = 0, l = children.length; i < l; i++) {
  5972. var child = children[i];
  5973. var data = child.data;
  5974. // remove slot attribute if the node is resolved as a Vue slot node
  5975. if (data && data.attrs && data.attrs.slot) {
  5976. delete data.attrs.slot;
  5977. }
  5978. // named slots should only be respected if the vnode was rendered in the
  5979. // same context.
  5980. if ((child.context === context || child.fnContext === context) &&
  5981. data && data.slot != null
  5982. ) {
  5983. var name = data.slot;
  5984. var slot = (slots[name] || (slots[name] = []));
  5985. if (child.tag === 'template') {
  5986. slot.push.apply(slot, child.children || []);
  5987. } else {
  5988. slot.push(child);
  5989. }
  5990. } else {
  5991. // fixed by xxxxxx 临时 hack 掉 uni-app 中的异步 name slot page
  5992. if(child.asyncMeta && child.asyncMeta.data && child.asyncMeta.data.slot === 'page'){
  5993. (slots['page'] || (slots['page'] = [])).push(child);
  5994. }else{
  5995. (slots.default || (slots.default = [])).push(child);
  5996. }
  5997. }
  5998. }
  5999. // ignore slots that contains only whitespace
  6000. for (var name$1 in slots) {
  6001. if (slots[name$1].every(isWhitespace)) {
  6002. delete slots[name$1];
  6003. }
  6004. }
  6005. return slots
  6006. }
  6007. function isWhitespace (node) {
  6008. return (node.isComment && !node.asyncFactory) || node.text === ' '
  6009. }
  6010. /* */
  6011. function normalizeScopedSlots (
  6012. slots,
  6013. normalSlots,
  6014. prevSlots
  6015. ) {
  6016. var res;
  6017. var hasNormalSlots = Object.keys(normalSlots).length > 0;
  6018. var isStable = slots ? !!slots.$stable : !hasNormalSlots;
  6019. var key = slots && slots.$key;
  6020. if (!slots) {
  6021. res = {};
  6022. } else if (slots._normalized) {
  6023. // fast path 1: child component re-render only, parent did not change
  6024. return slots._normalized
  6025. } else if (
  6026. isStable &&
  6027. prevSlots &&
  6028. prevSlots !== emptyObject &&
  6029. key === prevSlots.$key &&
  6030. !hasNormalSlots &&
  6031. !prevSlots.$hasNormal
  6032. ) {
  6033. // fast path 2: stable scoped slots w/ no normal slots to proxy,
  6034. // only need to normalize once
  6035. return prevSlots
  6036. } else {
  6037. res = {};
  6038. for (var key$1 in slots) {
  6039. if (slots[key$1] && key$1[0] !== '$') {
  6040. res[key$1] = normalizeScopedSlot(normalSlots, key$1, slots[key$1]);
  6041. }
  6042. }
  6043. }
  6044. // expose normal slots on scopedSlots
  6045. for (var key$2 in normalSlots) {
  6046. if (!(key$2 in res)) {
  6047. res[key$2] = proxyNormalSlot(normalSlots, key$2);
  6048. }
  6049. }
  6050. // avoriaz seems to mock a non-extensible $scopedSlots object
  6051. // and when that is passed down this would cause an error
  6052. if (slots && Object.isExtensible(slots)) {
  6053. (slots)._normalized = res;
  6054. }
  6055. def(res, '$stable', isStable);
  6056. def(res, '$key', key);
  6057. def(res, '$hasNormal', hasNormalSlots);
  6058. return res
  6059. }
  6060. function normalizeScopedSlot(normalSlots, key, fn) {
  6061. var normalized = function () {
  6062. var res = arguments.length ? fn.apply(null, arguments) : fn({});
  6063. res = res && typeof res === 'object' && !Array.isArray(res)
  6064. ? [res] // single vnode
  6065. : normalizeChildren(res);
  6066. return res && (
  6067. res.length === 0 ||
  6068. (res.length === 1 && res[0].isComment) // #9658
  6069. ) ? undefined
  6070. : res
  6071. };
  6072. // this is a slot using the new v-slot syntax without scope. although it is
  6073. // compiled as a scoped slot, render fn users would expect it to be present
  6074. // on this.$slots because the usage is semantically a normal slot.
  6075. if (fn.proxy) {
  6076. Object.defineProperty(normalSlots, key, {
  6077. get: normalized,
  6078. enumerable: true,
  6079. configurable: true
  6080. });
  6081. }
  6082. return normalized
  6083. }
  6084. function proxyNormalSlot(slots, key) {
  6085. return function () { return slots[key]; }
  6086. }
  6087. /* */
  6088. /**
  6089. * Runtime helper for rendering v-for lists.
  6090. */
  6091. function renderList (
  6092. val,
  6093. render
  6094. ) {
  6095. var ret, i, l, keys, key;
  6096. if (Array.isArray(val) || typeof val === 'string') {
  6097. ret = new Array(val.length);
  6098. for (i = 0, l = val.length; i < l; i++) {
  6099. ret[i] = render(val[i], i, i, i); // fixed by xxxxxx
  6100. }
  6101. } else if (typeof val === 'number') {
  6102. ret = new Array(val);
  6103. for (i = 0; i < val; i++) {
  6104. ret[i] = render(i + 1, i, i, i); // fixed by xxxxxx
  6105. }
  6106. } else if (isObject(val)) {
  6107. if (hasSymbol && val[Symbol.iterator]) {
  6108. ret = [];
  6109. var iterator = val[Symbol.iterator]();
  6110. var result = iterator.next();
  6111. while (!result.done) {
  6112. ret.push(render(result.value, ret.length, i, i++)); // fixed by xxxxxx
  6113. result = iterator.next();
  6114. }
  6115. } else {
  6116. keys = Object.keys(val);
  6117. ret = new Array(keys.length);
  6118. for (i = 0, l = keys.length; i < l; i++) {
  6119. key = keys[i];
  6120. ret[i] = render(val[key], key, i, i); // fixed by xxxxxx
  6121. }
  6122. }
  6123. }
  6124. if (!isDef(ret)) {
  6125. ret = [];
  6126. }
  6127. (ret)._isVList = true;
  6128. return ret
  6129. }
  6130. /* */
  6131. /**
  6132. * Runtime helper for rendering <slot>
  6133. */
  6134. function renderSlot (
  6135. name,
  6136. fallback,
  6137. props,
  6138. bindObject
  6139. ) {
  6140. var scopedSlotFn = this.$scopedSlots[name];
  6141. var nodes;
  6142. if (scopedSlotFn) { // scoped slot
  6143. props = props || {};
  6144. if (bindObject) {
  6145. if ( true && !isObject(bindObject)) {
  6146. warn(
  6147. 'slot v-bind without argument expects an Object',
  6148. this
  6149. );
  6150. }
  6151. props = extend(extend({}, bindObject), props);
  6152. }
  6153. // fixed by xxxxxx app-plus scopedSlot
  6154. nodes = scopedSlotFn(props, this, props._i) || fallback;
  6155. } else {
  6156. nodes = this.$slots[name] || fallback;
  6157. }
  6158. var target = props && props.slot;
  6159. if (target) {
  6160. return this.$createElement('template', { slot: target }, nodes)
  6161. } else {
  6162. return nodes
  6163. }
  6164. }
  6165. /* */
  6166. /**
  6167. * Runtime helper for resolving filters
  6168. */
  6169. function resolveFilter (id) {
  6170. return resolveAsset(this.$options, 'filters', id, true) || identity
  6171. }
  6172. /* */
  6173. function isKeyNotMatch (expect, actual) {
  6174. if (Array.isArray(expect)) {
  6175. return expect.indexOf(actual) === -1
  6176. } else {
  6177. return expect !== actual
  6178. }
  6179. }
  6180. /**
  6181. * Runtime helper for checking keyCodes from config.
  6182. * exposed as Vue.prototype._k
  6183. * passing in eventKeyName as last argument separately for backwards compat
  6184. */
  6185. function checkKeyCodes (
  6186. eventKeyCode,
  6187. key,
  6188. builtInKeyCode,
  6189. eventKeyName,
  6190. builtInKeyName
  6191. ) {
  6192. var mappedKeyCode = config.keyCodes[key] || builtInKeyCode;
  6193. if (builtInKeyName && eventKeyName && !config.keyCodes[key]) {
  6194. return isKeyNotMatch(builtInKeyName, eventKeyName)
  6195. } else if (mappedKeyCode) {
  6196. return isKeyNotMatch(mappedKeyCode, eventKeyCode)
  6197. } else if (eventKeyName) {
  6198. return hyphenate(eventKeyName) !== key
  6199. }
  6200. }
  6201. /* */
  6202. /**
  6203. * Runtime helper for merging v-bind="object" into a VNode's data.
  6204. */
  6205. function bindObjectProps (
  6206. data,
  6207. tag,
  6208. value,
  6209. asProp,
  6210. isSync
  6211. ) {
  6212. if (value) {
  6213. if (!isObject(value)) {
  6214. true && warn(
  6215. 'v-bind without argument expects an Object or Array value',
  6216. this
  6217. );
  6218. } else {
  6219. if (Array.isArray(value)) {
  6220. value = toObject(value);
  6221. }
  6222. var hash;
  6223. var loop = function ( key ) {
  6224. if (
  6225. key === 'class' ||
  6226. key === 'style' ||
  6227. isReservedAttribute(key)
  6228. ) {
  6229. hash = data;
  6230. } else {
  6231. var type = data.attrs && data.attrs.type;
  6232. hash = asProp || config.mustUseProp(tag, type, key)
  6233. ? data.domProps || (data.domProps = {})
  6234. : data.attrs || (data.attrs = {});
  6235. }
  6236. var camelizedKey = camelize(key);
  6237. var hyphenatedKey = hyphenate(key);
  6238. if (!(camelizedKey in hash) && !(hyphenatedKey in hash)) {
  6239. hash[key] = value[key];
  6240. if (isSync) {
  6241. var on = data.on || (data.on = {});
  6242. on[("update:" + key)] = function ($event) {
  6243. value[key] = $event;
  6244. };
  6245. }
  6246. }
  6247. };
  6248. for (var key in value) loop( key );
  6249. }
  6250. }
  6251. return data
  6252. }
  6253. /* */
  6254. /**
  6255. * Runtime helper for rendering static trees.
  6256. */
  6257. function renderStatic (
  6258. index,
  6259. isInFor
  6260. ) {
  6261. var cached = this._staticTrees || (this._staticTrees = []);
  6262. var tree = cached[index];
  6263. // if has already-rendered static tree and not inside v-for,
  6264. // we can reuse the same tree.
  6265. if (tree && !isInFor) {
  6266. return tree
  6267. }
  6268. // otherwise, render a fresh tree.
  6269. tree = cached[index] = this.$options.staticRenderFns[index].call(
  6270. this._renderProxy,
  6271. null,
  6272. this // for render fns generated for functional component templates
  6273. );
  6274. markStatic(tree, ("__static__" + index), false);
  6275. return tree
  6276. }
  6277. /**
  6278. * Runtime helper for v-once.
  6279. * Effectively it means marking the node as static with a unique key.
  6280. */
  6281. function markOnce (
  6282. tree,
  6283. index,
  6284. key
  6285. ) {
  6286. markStatic(tree, ("__once__" + index + (key ? ("_" + key) : "")), true);
  6287. return tree
  6288. }
  6289. function markStatic (
  6290. tree,
  6291. key,
  6292. isOnce
  6293. ) {
  6294. if (Array.isArray(tree)) {
  6295. for (var i = 0; i < tree.length; i++) {
  6296. if (tree[i] && typeof tree[i] !== 'string') {
  6297. markStaticNode(tree[i], (key + "_" + i), isOnce);
  6298. }
  6299. }
  6300. } else {
  6301. markStaticNode(tree, key, isOnce);
  6302. }
  6303. }
  6304. function markStaticNode (node, key, isOnce) {
  6305. node.isStatic = true;
  6306. node.key = key;
  6307. node.isOnce = isOnce;
  6308. }
  6309. /* */
  6310. function bindObjectListeners (data, value) {
  6311. if (value) {
  6312. if (!isPlainObject(value)) {
  6313. true && warn(
  6314. 'v-on without argument expects an Object value',
  6315. this
  6316. );
  6317. } else {
  6318. var on = data.on = data.on ? extend({}, data.on) : {};
  6319. for (var key in value) {
  6320. var existing = on[key];
  6321. var ours = value[key];
  6322. on[key] = existing ? [].concat(existing, ours) : ours;
  6323. }
  6324. }
  6325. }
  6326. return data
  6327. }
  6328. /* */
  6329. function resolveScopedSlots (
  6330. fns, // see flow/vnode
  6331. res,
  6332. // the following are added in 2.6
  6333. hasDynamicKeys,
  6334. contentHashKey
  6335. ) {
  6336. res = res || { $stable: !hasDynamicKeys };
  6337. for (var i = 0; i < fns.length; i++) {
  6338. var slot = fns[i];
  6339. if (Array.isArray(slot)) {
  6340. resolveScopedSlots(slot, res, hasDynamicKeys);
  6341. } else if (slot) {
  6342. // marker for reverse proxying v-slot without scope on this.$slots
  6343. if (slot.proxy) {
  6344. slot.fn.proxy = true;
  6345. }
  6346. res[slot.key] = slot.fn;
  6347. }
  6348. }
  6349. if (contentHashKey) {
  6350. (res).$key = contentHashKey;
  6351. }
  6352. return res
  6353. }
  6354. /* */
  6355. function bindDynamicKeys (baseObj, values) {
  6356. for (var i = 0; i < values.length; i += 2) {
  6357. var key = values[i];
  6358. if (typeof key === 'string' && key) {
  6359. baseObj[values[i]] = values[i + 1];
  6360. } else if ( true && key !== '' && key !== null) {
  6361. // null is a special value for explicitly removing a binding
  6362. warn(
  6363. ("Invalid value for dynamic directive argument (expected string or null): " + key),
  6364. this
  6365. );
  6366. }
  6367. }
  6368. return baseObj
  6369. }
  6370. // helper to dynamically append modifier runtime markers to event names.
  6371. // ensure only append when value is already string, otherwise it will be cast
  6372. // to string and cause the type check to miss.
  6373. function prependModifier (value, symbol) {
  6374. return typeof value === 'string' ? symbol + value : value
  6375. }
  6376. /* */
  6377. function installRenderHelpers (target) {
  6378. target._o = markOnce;
  6379. target._n = toNumber;
  6380. target._s = toString;
  6381. target._l = renderList;
  6382. target._t = renderSlot;
  6383. target._q = looseEqual;
  6384. target._i = looseIndexOf;
  6385. target._m = renderStatic;
  6386. target._f = resolveFilter;
  6387. target._k = checkKeyCodes;
  6388. target._b = bindObjectProps;
  6389. target._v = createTextVNode;
  6390. target._e = createEmptyVNode;
  6391. target._u = resolveScopedSlots;
  6392. target._g = bindObjectListeners;
  6393. target._d = bindDynamicKeys;
  6394. target._p = prependModifier;
  6395. }
  6396. /* */
  6397. function FunctionalRenderContext (
  6398. data,
  6399. props,
  6400. children,
  6401. parent,
  6402. Ctor
  6403. ) {
  6404. var this$1 = this;
  6405. var options = Ctor.options;
  6406. // ensure the createElement function in functional components
  6407. // gets a unique context - this is necessary for correct named slot check
  6408. var contextVm;
  6409. if (hasOwn(parent, '_uid')) {
  6410. contextVm = Object.create(parent);
  6411. // $flow-disable-line
  6412. contextVm._original = parent;
  6413. } else {
  6414. // the context vm passed in is a functional context as well.
  6415. // in this case we want to make sure we are able to get a hold to the
  6416. // real context instance.
  6417. contextVm = parent;
  6418. // $flow-disable-line
  6419. parent = parent._original;
  6420. }
  6421. var isCompiled = isTrue(options._compiled);
  6422. var needNormalization = !isCompiled;
  6423. this.data = data;
  6424. this.props = props;
  6425. this.children = children;
  6426. this.parent = parent;
  6427. this.listeners = data.on || emptyObject;
  6428. this.injections = resolveInject(options.inject, parent);
  6429. this.slots = function () {
  6430. if (!this$1.$slots) {
  6431. normalizeScopedSlots(
  6432. data.scopedSlots,
  6433. this$1.$slots = resolveSlots(children, parent)
  6434. );
  6435. }
  6436. return this$1.$slots
  6437. };
  6438. Object.defineProperty(this, 'scopedSlots', ({
  6439. enumerable: true,
  6440. get: function get () {
  6441. return normalizeScopedSlots(data.scopedSlots, this.slots())
  6442. }
  6443. }));
  6444. // support for compiled functional template
  6445. if (isCompiled) {
  6446. // exposing $options for renderStatic()
  6447. this.$options = options;
  6448. // pre-resolve slots for renderSlot()
  6449. this.$slots = this.slots();
  6450. this.$scopedSlots = normalizeScopedSlots(data.scopedSlots, this.$slots);
  6451. }
  6452. if (options._scopeId) {
  6453. this._c = function (a, b, c, d) {
  6454. var vnode = createElement(contextVm, a, b, c, d, needNormalization);
  6455. if (vnode && !Array.isArray(vnode)) {
  6456. vnode.fnScopeId = options._scopeId;
  6457. vnode.fnContext = parent;
  6458. }
  6459. return vnode
  6460. };
  6461. } else {
  6462. this._c = function (a, b, c, d) { return createElement(contextVm, a, b, c, d, needNormalization); };
  6463. }
  6464. }
  6465. installRenderHelpers(FunctionalRenderContext.prototype);
  6466. function createFunctionalComponent (
  6467. Ctor,
  6468. propsData,
  6469. data,
  6470. contextVm,
  6471. children
  6472. ) {
  6473. var options = Ctor.options;
  6474. var props = {};
  6475. var propOptions = options.props;
  6476. if (isDef(propOptions)) {
  6477. for (var key in propOptions) {
  6478. props[key] = validateProp(key, propOptions, propsData || emptyObject);
  6479. }
  6480. } else {
  6481. if (isDef(data.attrs)) { mergeProps(props, data.attrs); }
  6482. if (isDef(data.props)) { mergeProps(props, data.props); }
  6483. }
  6484. var renderContext = new FunctionalRenderContext(
  6485. data,
  6486. props,
  6487. children,
  6488. contextVm,
  6489. Ctor
  6490. );
  6491. var vnode = options.render.call(null, renderContext._c, renderContext);
  6492. if (vnode instanceof VNode) {
  6493. return cloneAndMarkFunctionalResult(vnode, data, renderContext.parent, options, renderContext)
  6494. } else if (Array.isArray(vnode)) {
  6495. var vnodes = normalizeChildren(vnode) || [];
  6496. var res = new Array(vnodes.length);
  6497. for (var i = 0; i < vnodes.length; i++) {
  6498. res[i] = cloneAndMarkFunctionalResult(vnodes[i], data, renderContext.parent, options, renderContext);
  6499. }
  6500. return res
  6501. }
  6502. }
  6503. function cloneAndMarkFunctionalResult (vnode, data, contextVm, options, renderContext) {
  6504. // #7817 clone node before setting fnContext, otherwise if the node is reused
  6505. // (e.g. it was from a cached normal slot) the fnContext causes named slots
  6506. // that should not be matched to match.
  6507. var clone = cloneVNode(vnode);
  6508. clone.fnContext = contextVm;
  6509. clone.fnOptions = options;
  6510. if (true) {
  6511. (clone.devtoolsMeta = clone.devtoolsMeta || {}).renderContext = renderContext;
  6512. }
  6513. if (data.slot) {
  6514. (clone.data || (clone.data = {})).slot = data.slot;
  6515. }
  6516. return clone
  6517. }
  6518. function mergeProps (to, from) {
  6519. for (var key in from) {
  6520. to[camelize(key)] = from[key];
  6521. }
  6522. }
  6523. /* */
  6524. /* */
  6525. /* */
  6526. /* */
  6527. // inline hooks to be invoked on component VNodes during patch
  6528. var componentVNodeHooks = {
  6529. init: function init (vnode, hydrating) {
  6530. if (
  6531. vnode.componentInstance &&
  6532. !vnode.componentInstance._isDestroyed &&
  6533. vnode.data.keepAlive
  6534. ) {
  6535. // kept-alive components, treat as a patch
  6536. var mountedNode = vnode; // work around flow
  6537. componentVNodeHooks.prepatch(mountedNode, mountedNode);
  6538. } else {
  6539. var child = vnode.componentInstance = createComponentInstanceForVnode(
  6540. vnode,
  6541. activeInstance
  6542. );
  6543. child.$mount(hydrating ? vnode.elm : undefined, hydrating);
  6544. }
  6545. },
  6546. prepatch: function prepatch (oldVnode, vnode) {
  6547. var options = vnode.componentOptions;
  6548. var child = vnode.componentInstance = oldVnode.componentInstance;
  6549. updateChildComponent(
  6550. child,
  6551. options.propsData, // updated props
  6552. options.listeners, // updated listeners
  6553. vnode, // new parent vnode
  6554. options.children // new children
  6555. );
  6556. },
  6557. insert: function insert (vnode) {
  6558. var context = vnode.context;
  6559. var componentInstance = vnode.componentInstance;
  6560. if (!componentInstance._isMounted) {
  6561. callHook(componentInstance, 'onServiceCreated');
  6562. callHook(componentInstance, 'onServiceAttached');
  6563. componentInstance._isMounted = true;
  6564. callHook(componentInstance, 'mounted');
  6565. }
  6566. if (vnode.data.keepAlive) {
  6567. if (context._isMounted) {
  6568. // vue-router#1212
  6569. // During updates, a kept-alive component's child components may
  6570. // change, so directly walking the tree here may call activated hooks
  6571. // on incorrect children. Instead we push them into a queue which will
  6572. // be processed after the whole patch process ended.
  6573. queueActivatedComponent(componentInstance);
  6574. } else {
  6575. activateChildComponent(componentInstance, true /* direct */);
  6576. }
  6577. }
  6578. },
  6579. destroy: function destroy (vnode) {
  6580. var componentInstance = vnode.componentInstance;
  6581. if (!componentInstance._isDestroyed) {
  6582. if (!vnode.data.keepAlive) {
  6583. componentInstance.$destroy();
  6584. } else {
  6585. deactivateChildComponent(componentInstance, true /* direct */);
  6586. }
  6587. }
  6588. }
  6589. };
  6590. var hooksToMerge = Object.keys(componentVNodeHooks);
  6591. function createComponent (
  6592. Ctor,
  6593. data,
  6594. context,
  6595. children,
  6596. tag
  6597. ) {
  6598. if (isUndef(Ctor)) {
  6599. return
  6600. }
  6601. var baseCtor = context.$options._base;
  6602. // plain options object: turn it into a constructor
  6603. if (isObject(Ctor)) {
  6604. Ctor = baseCtor.extend(Ctor);
  6605. }
  6606. // if at this stage it's not a constructor or an async component factory,
  6607. // reject.
  6608. if (typeof Ctor !== 'function') {
  6609. if (true) {
  6610. warn(("Invalid Component definition: " + (String(Ctor))), context);
  6611. }
  6612. return
  6613. }
  6614. // async component
  6615. var asyncFactory;
  6616. if (isUndef(Ctor.cid)) {
  6617. asyncFactory = Ctor;
  6618. Ctor = resolveAsyncComponent(asyncFactory, baseCtor);
  6619. if (Ctor === undefined) {
  6620. // return a placeholder node for async component, which is rendered
  6621. // as a comment node but preserves all the raw information for the node.
  6622. // the information will be used for async server-rendering and hydration.
  6623. return createAsyncPlaceholder(
  6624. asyncFactory,
  6625. data,
  6626. context,
  6627. children,
  6628. tag
  6629. )
  6630. }
  6631. }
  6632. data = data || {};
  6633. // resolve constructor options in case global mixins are applied after
  6634. // component constructor creation
  6635. resolveConstructorOptions(Ctor);
  6636. // transform component v-model data into props & events
  6637. if (isDef(data.model)) {
  6638. transformModel(Ctor.options, data);
  6639. }
  6640. // extract props
  6641. var propsData = extractPropsFromVNodeData(data, Ctor, tag, context); // fixed by xxxxxx
  6642. // functional component
  6643. if (isTrue(Ctor.options.functional)) {
  6644. return createFunctionalComponent(Ctor, propsData, data, context, children)
  6645. }
  6646. // extract listeners, since these needs to be treated as
  6647. // child component listeners instead of DOM listeners
  6648. var listeners = data.on;
  6649. // replace with listeners with .native modifier
  6650. // so it gets processed during parent component patch.
  6651. data.on = data.nativeOn;
  6652. if (isTrue(Ctor.options.abstract)) {
  6653. // abstract components do not keep anything
  6654. // other than props & listeners & slot
  6655. // work around flow
  6656. var slot = data.slot;
  6657. data = {};
  6658. if (slot) {
  6659. data.slot = slot;
  6660. }
  6661. }
  6662. // install component management hooks onto the placeholder node
  6663. installComponentHooks(data);
  6664. // return a placeholder vnode
  6665. var name = Ctor.options.name || tag;
  6666. var vnode = new VNode(
  6667. ("vue-component-" + (Ctor.cid) + (name ? ("-" + name) : '')),
  6668. data, undefined, undefined, undefined, context,
  6669. { Ctor: Ctor, propsData: propsData, listeners: listeners, tag: tag, children: children },
  6670. asyncFactory
  6671. );
  6672. return vnode
  6673. }
  6674. function createComponentInstanceForVnode (
  6675. vnode, // we know it's MountedComponentVNode but flow doesn't
  6676. parent // activeInstance in lifecycle state
  6677. ) {
  6678. var options = {
  6679. _isComponent: true,
  6680. _parentVnode: vnode,
  6681. parent: parent
  6682. };
  6683. // check inline-template render functions
  6684. var inlineTemplate = vnode.data.inlineTemplate;
  6685. if (isDef(inlineTemplate)) {
  6686. options.render = inlineTemplate.render;
  6687. options.staticRenderFns = inlineTemplate.staticRenderFns;
  6688. }
  6689. return new vnode.componentOptions.Ctor(options)
  6690. }
  6691. function installComponentHooks (data) {
  6692. var hooks = data.hook || (data.hook = {});
  6693. for (var i = 0; i < hooksToMerge.length; i++) {
  6694. var key = hooksToMerge[i];
  6695. var existing = hooks[key];
  6696. var toMerge = componentVNodeHooks[key];
  6697. if (existing !== toMerge && !(existing && existing._merged)) {
  6698. hooks[key] = existing ? mergeHook$1(toMerge, existing) : toMerge;
  6699. }
  6700. }
  6701. }
  6702. function mergeHook$1 (f1, f2) {
  6703. var merged = function (a, b) {
  6704. // flow complains about extra args which is why we use any
  6705. f1(a, b);
  6706. f2(a, b);
  6707. };
  6708. merged._merged = true;
  6709. return merged
  6710. }
  6711. // transform component v-model info (value and callback) into
  6712. // prop and event handler respectively.
  6713. function transformModel (options, data) {
  6714. var prop = (options.model && options.model.prop) || 'value';
  6715. var event = (options.model && options.model.event) || 'input'
  6716. ;(data.attrs || (data.attrs = {}))[prop] = data.model.value;
  6717. var on = data.on || (data.on = {});
  6718. var existing = on[event];
  6719. var callback = data.model.callback;
  6720. if (isDef(existing)) {
  6721. if (
  6722. Array.isArray(existing)
  6723. ? existing.indexOf(callback) === -1
  6724. : existing !== callback
  6725. ) {
  6726. on[event] = [callback].concat(existing);
  6727. }
  6728. } else {
  6729. on[event] = callback;
  6730. }
  6731. }
  6732. /* */
  6733. var SIMPLE_NORMALIZE = 1;
  6734. var ALWAYS_NORMALIZE = 2;
  6735. // wrapper function for providing a more flexible interface
  6736. // without getting yelled at by flow
  6737. function createElement (
  6738. context,
  6739. tag,
  6740. data,
  6741. children,
  6742. normalizationType,
  6743. alwaysNormalize
  6744. ) {
  6745. if (Array.isArray(data) || isPrimitive(data)) {
  6746. normalizationType = children;
  6747. children = data;
  6748. data = undefined;
  6749. }
  6750. if (isTrue(alwaysNormalize)) {
  6751. normalizationType = ALWAYS_NORMALIZE;
  6752. }
  6753. return _createElement(context, tag, data, children, normalizationType)
  6754. }
  6755. function _createElement (
  6756. context,
  6757. tag,
  6758. data,
  6759. children,
  6760. normalizationType
  6761. ) {
  6762. if (isDef(data) && isDef((data).__ob__)) {
  6763. true && warn(
  6764. "Avoid using observed data object as vnode data: " + (JSON.stringify(data)) + "\n" +
  6765. 'Always create fresh vnode data objects in each render!',
  6766. context
  6767. );
  6768. return createEmptyVNode()
  6769. }
  6770. // object syntax in v-bind
  6771. if (isDef(data) && isDef(data.is)) {
  6772. tag = data.is;
  6773. }
  6774. if (!tag) {
  6775. // in case of component :is set to falsy value
  6776. return createEmptyVNode()
  6777. }
  6778. // warn against non-primitive key
  6779. if ( true &&
  6780. isDef(data) && isDef(data.key) && !isPrimitive(data.key)
  6781. ) {
  6782. {
  6783. warn(
  6784. 'Avoid using non-primitive value as key, ' +
  6785. 'use string/number value instead.',
  6786. context
  6787. );
  6788. }
  6789. }
  6790. // support single function children as default scoped slot
  6791. if (Array.isArray(children) &&
  6792. typeof children[0] === 'function'
  6793. ) {
  6794. data = data || {};
  6795. data.scopedSlots = { default: children[0] };
  6796. children.length = 0;
  6797. }
  6798. if (normalizationType === ALWAYS_NORMALIZE) {
  6799. children = normalizeChildren(children);
  6800. } else if (normalizationType === SIMPLE_NORMALIZE) {
  6801. children = simpleNormalizeChildren(children);
  6802. }
  6803. var vnode, ns;
  6804. if (typeof tag === 'string') {
  6805. var Ctor;
  6806. ns = (context.$vnode && context.$vnode.ns) || config.getTagNamespace(tag);
  6807. if (config.isReservedTag(tag)) {
  6808. // platform built-in elements
  6809. if ( true && isDef(data) && isDef(data.nativeOn)) {
  6810. warn(
  6811. ("The .native modifier for v-on is only valid on components but it was used on <" + tag + ">."),
  6812. context
  6813. );
  6814. }
  6815. vnode = new VNode(
  6816. config.parsePlatformTagName(tag), data, children,
  6817. undefined, undefined, context
  6818. );
  6819. } else if ((!data || !data.pre) && isDef(Ctor = resolveAsset(context.$options, 'components', tag))) {
  6820. // component
  6821. vnode = createComponent(Ctor, data, context, children, tag);
  6822. } else {
  6823. // unknown or unlisted namespaced elements
  6824. // check at runtime because it may get assigned a namespace when its
  6825. // parent normalizes children
  6826. vnode = new VNode(
  6827. tag, data, children,
  6828. undefined, undefined, context
  6829. );
  6830. }
  6831. } else {
  6832. // direct component options / constructor
  6833. vnode = createComponent(tag, data, context, children);
  6834. }
  6835. if (Array.isArray(vnode)) {
  6836. return vnode
  6837. } else if (isDef(vnode)) {
  6838. if (isDef(ns)) { applyNS(vnode, ns); }
  6839. if (isDef(data)) { registerDeepBindings(data); }
  6840. return vnode
  6841. } else {
  6842. return createEmptyVNode()
  6843. }
  6844. }
  6845. function applyNS (vnode, ns, force) {
  6846. vnode.ns = ns;
  6847. if (vnode.tag === 'foreignObject') {
  6848. // use default namespace inside foreignObject
  6849. ns = undefined;
  6850. force = true;
  6851. }
  6852. if (isDef(vnode.children)) {
  6853. for (var i = 0, l = vnode.children.length; i < l; i++) {
  6854. var child = vnode.children[i];
  6855. if (isDef(child.tag) && (
  6856. isUndef(child.ns) || (isTrue(force) && child.tag !== 'svg'))) {
  6857. applyNS(child, ns, force);
  6858. }
  6859. }
  6860. }
  6861. }
  6862. // ref #5318
  6863. // necessary to ensure parent re-render when deep bindings like :style and
  6864. // :class are used on slot nodes
  6865. function registerDeepBindings (data) {
  6866. if (isObject(data.style)) {
  6867. traverse(data.style);
  6868. }
  6869. if (isObject(data.class)) {
  6870. traverse(data.class);
  6871. }
  6872. }
  6873. /* */
  6874. function initRender (vm) {
  6875. vm._vnode = null; // the root of the child tree
  6876. vm._staticTrees = null; // v-once cached trees
  6877. var options = vm.$options;
  6878. var parentVnode = vm.$vnode = options._parentVnode; // the placeholder node in parent tree
  6879. var renderContext = parentVnode && parentVnode.context;
  6880. vm.$slots = resolveSlots(options._renderChildren, renderContext);
  6881. vm.$scopedSlots = emptyObject;
  6882. // bind the createElement fn to this instance
  6883. // so that we get proper render context inside it.
  6884. // args order: tag, data, children, normalizationType, alwaysNormalize
  6885. // internal version is used by render functions compiled from templates
  6886. vm._c = function (a, b, c, d) { return createElement(vm, a, b, c, d, false); };
  6887. // normalization is always applied for the public version, used in
  6888. // user-written render functions.
  6889. vm.$createElement = function (a, b, c, d) { return createElement(vm, a, b, c, d, true); };
  6890. // $attrs & $listeners are exposed for easier HOC creation.
  6891. // they need to be reactive so that HOCs using them are always updated
  6892. var parentData = parentVnode && parentVnode.data;
  6893. /* istanbul ignore else */
  6894. if (true) {
  6895. defineReactive$$1(vm, '$attrs', parentData && parentData.attrs || emptyObject, function () {
  6896. !isUpdatingChildComponent && warn("$attrs is readonly.", vm);
  6897. }, true);
  6898. defineReactive$$1(vm, '$listeners', options._parentListeners || emptyObject, function () {
  6899. !isUpdatingChildComponent && warn("$listeners is readonly.", vm);
  6900. }, true);
  6901. } else {}
  6902. }
  6903. var currentRenderingInstance = null;
  6904. function renderMixin (Vue) {
  6905. // install runtime convenience helpers
  6906. installRenderHelpers(Vue.prototype);
  6907. Vue.prototype.$nextTick = function (fn) {
  6908. return nextTick(fn, this)
  6909. };
  6910. Vue.prototype._render = function () {
  6911. var vm = this;
  6912. var ref = vm.$options;
  6913. var render = ref.render;
  6914. var _parentVnode = ref._parentVnode;
  6915. if (_parentVnode) {
  6916. vm.$scopedSlots = normalizeScopedSlots(
  6917. _parentVnode.data.scopedSlots,
  6918. vm.$slots,
  6919. vm.$scopedSlots
  6920. );
  6921. }
  6922. // set parent vnode. this allows render functions to have access
  6923. // to the data on the placeholder node.
  6924. vm.$vnode = _parentVnode;
  6925. // render self
  6926. var vnode;
  6927. try {
  6928. // There's no need to maintain a stack because all render fns are called
  6929. // separately from one another. Nested component's render fns are called
  6930. // when parent component is patched.
  6931. currentRenderingInstance = vm;
  6932. vnode = render.call(vm._renderProxy, vm.$createElement);
  6933. } catch (e) {
  6934. handleError(e, vm, "render");
  6935. // return error render result,
  6936. // or previous vnode to prevent render error causing blank component
  6937. /* istanbul ignore else */
  6938. if ( true && vm.$options.renderError) {
  6939. try {
  6940. vnode = vm.$options.renderError.call(vm._renderProxy, vm.$createElement, e);
  6941. } catch (e) {
  6942. handleError(e, vm, "renderError");
  6943. vnode = vm._vnode;
  6944. }
  6945. } else {
  6946. vnode = vm._vnode;
  6947. }
  6948. } finally {
  6949. currentRenderingInstance = null;
  6950. }
  6951. // if the returned array contains only a single node, allow it
  6952. if (Array.isArray(vnode) && vnode.length === 1) {
  6953. vnode = vnode[0];
  6954. }
  6955. // return empty vnode in case the render function errored out
  6956. if (!(vnode instanceof VNode)) {
  6957. if ( true && Array.isArray(vnode)) {
  6958. warn(
  6959. 'Multiple root nodes returned from render function. Render function ' +
  6960. 'should return a single root node.',
  6961. vm
  6962. );
  6963. }
  6964. vnode = createEmptyVNode();
  6965. }
  6966. // set parent
  6967. vnode.parent = _parentVnode;
  6968. return vnode
  6969. };
  6970. }
  6971. /* */
  6972. function ensureCtor (comp, base) {
  6973. if (
  6974. comp.__esModule ||
  6975. (hasSymbol && comp[Symbol.toStringTag] === 'Module')
  6976. ) {
  6977. comp = comp.default;
  6978. }
  6979. return isObject(comp)
  6980. ? base.extend(comp)
  6981. : comp
  6982. }
  6983. function createAsyncPlaceholder (
  6984. factory,
  6985. data,
  6986. context,
  6987. children,
  6988. tag
  6989. ) {
  6990. var node = createEmptyVNode();
  6991. node.asyncFactory = factory;
  6992. node.asyncMeta = { data: data, context: context, children: children, tag: tag };
  6993. return node
  6994. }
  6995. function resolveAsyncComponent (
  6996. factory,
  6997. baseCtor
  6998. ) {
  6999. if (isTrue(factory.error) && isDef(factory.errorComp)) {
  7000. return factory.errorComp
  7001. }
  7002. if (isDef(factory.resolved)) {
  7003. return factory.resolved
  7004. }
  7005. var owner = currentRenderingInstance;
  7006. if (owner && isDef(factory.owners) && factory.owners.indexOf(owner) === -1) {
  7007. // already pending
  7008. factory.owners.push(owner);
  7009. }
  7010. if (isTrue(factory.loading) && isDef(factory.loadingComp)) {
  7011. return factory.loadingComp
  7012. }
  7013. if (owner && !isDef(factory.owners)) {
  7014. var owners = factory.owners = [owner];
  7015. var sync = true;
  7016. var timerLoading = null;
  7017. var timerTimeout = null
  7018. ;(owner).$on('hook:destroyed', function () { return remove(owners, owner); });
  7019. var forceRender = function (renderCompleted) {
  7020. for (var i = 0, l = owners.length; i < l; i++) {
  7021. (owners[i]).$forceUpdate();
  7022. }
  7023. if (renderCompleted) {
  7024. owners.length = 0;
  7025. if (timerLoading !== null) {
  7026. clearTimeout(timerLoading);
  7027. timerLoading = null;
  7028. }
  7029. if (timerTimeout !== null) {
  7030. clearTimeout(timerTimeout);
  7031. timerTimeout = null;
  7032. }
  7033. }
  7034. };
  7035. var resolve = once(function (res) {
  7036. // cache resolved
  7037. factory.resolved = ensureCtor(res, baseCtor);
  7038. // invoke callbacks only if this is not a synchronous resolve
  7039. // (async resolves are shimmed as synchronous during SSR)
  7040. if (!sync) {
  7041. forceRender(true);
  7042. } else {
  7043. owners.length = 0;
  7044. }
  7045. });
  7046. var reject = once(function (reason) {
  7047. true && warn(
  7048. "Failed to resolve async component: " + (String(factory)) +
  7049. (reason ? ("\nReason: " + reason) : '')
  7050. );
  7051. if (isDef(factory.errorComp)) {
  7052. factory.error = true;
  7053. forceRender(true);
  7054. }
  7055. });
  7056. var res = factory(resolve, reject);
  7057. if (isObject(res)) {
  7058. if (isPromise(res)) {
  7059. // () => Promise
  7060. if (isUndef(factory.resolved)) {
  7061. res.then(resolve, reject);
  7062. }
  7063. } else if (isPromise(res.component)) {
  7064. res.component.then(resolve, reject);
  7065. if (isDef(res.error)) {
  7066. factory.errorComp = ensureCtor(res.error, baseCtor);
  7067. }
  7068. if (isDef(res.loading)) {
  7069. factory.loadingComp = ensureCtor(res.loading, baseCtor);
  7070. if (res.delay === 0) {
  7071. factory.loading = true;
  7072. } else {
  7073. timerLoading = setTimeout(function () {
  7074. timerLoading = null;
  7075. if (isUndef(factory.resolved) && isUndef(factory.error)) {
  7076. factory.loading = true;
  7077. forceRender(false);
  7078. }
  7079. }, res.delay || 200);
  7080. }
  7081. }
  7082. if (isDef(res.timeout)) {
  7083. timerTimeout = setTimeout(function () {
  7084. timerTimeout = null;
  7085. if (isUndef(factory.resolved)) {
  7086. reject(
  7087. true
  7088. ? ("timeout (" + (res.timeout) + "ms)")
  7089. : undefined
  7090. );
  7091. }
  7092. }, res.timeout);
  7093. }
  7094. }
  7095. }
  7096. sync = false;
  7097. // return in case resolved synchronously
  7098. return factory.loading
  7099. ? factory.loadingComp
  7100. : factory.resolved
  7101. }
  7102. }
  7103. /* */
  7104. function isAsyncPlaceholder (node) {
  7105. return node.isComment && node.asyncFactory
  7106. }
  7107. /* */
  7108. function getFirstComponentChild (children) {
  7109. if (Array.isArray(children)) {
  7110. for (var i = 0; i < children.length; i++) {
  7111. var c = children[i];
  7112. if (isDef(c) && (isDef(c.componentOptions) || isAsyncPlaceholder(c))) {
  7113. return c
  7114. }
  7115. }
  7116. }
  7117. }
  7118. /* */
  7119. /* */
  7120. function initEvents (vm) {
  7121. vm._events = Object.create(null);
  7122. vm._hasHookEvent = false;
  7123. // init parent attached events
  7124. var listeners = vm.$options._parentListeners;
  7125. if (listeners) {
  7126. updateComponentListeners(vm, listeners);
  7127. }
  7128. }
  7129. var target;
  7130. function add (event, fn) {
  7131. target.$on(event, fn);
  7132. }
  7133. function remove$1 (event, fn) {
  7134. target.$off(event, fn);
  7135. }
  7136. function createOnceHandler (event, fn) {
  7137. var _target = target;
  7138. return function onceHandler () {
  7139. var res = fn.apply(null, arguments);
  7140. if (res !== null) {
  7141. _target.$off(event, onceHandler);
  7142. }
  7143. }
  7144. }
  7145. function updateComponentListeners (
  7146. vm,
  7147. listeners,
  7148. oldListeners
  7149. ) {
  7150. target = vm;
  7151. updateListeners(listeners, oldListeners || {}, add, remove$1, createOnceHandler, vm);
  7152. target = undefined;
  7153. }
  7154. function eventsMixin (Vue) {
  7155. var hookRE = /^hook:/;
  7156. Vue.prototype.$on = function (event, fn) {
  7157. var vm = this;
  7158. if (Array.isArray(event)) {
  7159. for (var i = 0, l = event.length; i < l; i++) {
  7160. vm.$on(event[i], fn);
  7161. }
  7162. } else {
  7163. (vm._events[event] || (vm._events[event] = [])).push(fn);
  7164. // optimize hook:event cost by using a boolean flag marked at registration
  7165. // instead of a hash lookup
  7166. if (hookRE.test(event)) {
  7167. vm._hasHookEvent = true;
  7168. }
  7169. }
  7170. return vm
  7171. };
  7172. Vue.prototype.$once = function (event, fn) {
  7173. var vm = this;
  7174. function on () {
  7175. vm.$off(event, on);
  7176. fn.apply(vm, arguments);
  7177. }
  7178. on.fn = fn;
  7179. vm.$on(event, on);
  7180. return vm
  7181. };
  7182. Vue.prototype.$off = function (event, fn) {
  7183. var vm = this;
  7184. // all
  7185. if (!arguments.length) {
  7186. vm._events = Object.create(null);
  7187. return vm
  7188. }
  7189. // array of events
  7190. if (Array.isArray(event)) {
  7191. for (var i$1 = 0, l = event.length; i$1 < l; i$1++) {
  7192. vm.$off(event[i$1], fn);
  7193. }
  7194. return vm
  7195. }
  7196. // specific event
  7197. var cbs = vm._events[event];
  7198. if (!cbs) {
  7199. return vm
  7200. }
  7201. if (!fn) {
  7202. vm._events[event] = null;
  7203. return vm
  7204. }
  7205. // specific handler
  7206. var cb;
  7207. var i = cbs.length;
  7208. while (i--) {
  7209. cb = cbs[i];
  7210. if (cb === fn || cb.fn === fn) {
  7211. cbs.splice(i, 1);
  7212. break
  7213. }
  7214. }
  7215. return vm
  7216. };
  7217. Vue.prototype.$emit = function (event) {
  7218. var vm = this;
  7219. if (true) {
  7220. var lowerCaseEvent = event.toLowerCase();
  7221. if (lowerCaseEvent !== event && vm._events[lowerCaseEvent]) {
  7222. tip(
  7223. "Event \"" + lowerCaseEvent + "\" is emitted in component " +
  7224. (formatComponentName(vm)) + " but the handler is registered for \"" + event + "\". " +
  7225. "Note that HTML attributes are case-insensitive and you cannot use " +
  7226. "v-on to listen to camelCase events when using in-DOM templates. " +
  7227. "You should probably use \"" + (hyphenate(event)) + "\" instead of \"" + event + "\"."
  7228. );
  7229. }
  7230. }
  7231. var cbs = vm._events[event];
  7232. if (cbs) {
  7233. cbs = cbs.length > 1 ? toArray(cbs) : cbs;
  7234. var args = toArray(arguments, 1);
  7235. var info = "event handler for \"" + event + "\"";
  7236. for (var i = 0, l = cbs.length; i < l; i++) {
  7237. invokeWithErrorHandling(cbs[i], vm, args, vm, info);
  7238. }
  7239. }
  7240. return vm
  7241. };
  7242. }
  7243. /* */
  7244. var activeInstance = null;
  7245. var isUpdatingChildComponent = false;
  7246. function setActiveInstance(vm) {
  7247. var prevActiveInstance = activeInstance;
  7248. activeInstance = vm;
  7249. return function () {
  7250. activeInstance = prevActiveInstance;
  7251. }
  7252. }
  7253. function initLifecycle (vm) {
  7254. var options = vm.$options;
  7255. // locate first non-abstract parent
  7256. var parent = options.parent;
  7257. if (parent && !options.abstract) {
  7258. while (parent.$options.abstract && parent.$parent) {
  7259. parent = parent.$parent;
  7260. }
  7261. parent.$children.push(vm);
  7262. }
  7263. vm.$parent = parent;
  7264. vm.$root = parent ? parent.$root : vm;
  7265. vm.$children = [];
  7266. vm.$refs = {};
  7267. vm._watcher = null;
  7268. vm._inactive = null;
  7269. vm._directInactive = false;
  7270. vm._isMounted = false;
  7271. vm._isDestroyed = false;
  7272. vm._isBeingDestroyed = false;
  7273. }
  7274. function lifecycleMixin (Vue) {
  7275. Vue.prototype._update = function (vnode, hydrating) {
  7276. var vm = this;
  7277. var prevEl = vm.$el;
  7278. var prevVnode = vm._vnode;
  7279. var restoreActiveInstance = setActiveInstance(vm);
  7280. vm._vnode = vnode;
  7281. // Vue.prototype.__patch__ is injected in entry points
  7282. // based on the rendering backend used.
  7283. if (!prevVnode) {
  7284. // initial render
  7285. vm.$el = vm.__patch__(vm.$el, vnode, hydrating, false /* removeOnly */);
  7286. } else {
  7287. // updates
  7288. vm.$el = vm.__patch__(prevVnode, vnode);
  7289. }
  7290. restoreActiveInstance();
  7291. // update __vue__ reference
  7292. if (prevEl) {
  7293. prevEl.__vue__ = null;
  7294. }
  7295. if (vm.$el) {
  7296. vm.$el.__vue__ = vm;
  7297. }
  7298. // if parent is an HOC, update its $el as well
  7299. if (vm.$vnode && vm.$parent && vm.$vnode === vm.$parent._vnode) {
  7300. vm.$parent.$el = vm.$el;
  7301. }
  7302. // updated hook is called by the scheduler to ensure that children are
  7303. // updated in a parent's updated hook.
  7304. };
  7305. Vue.prototype.$forceUpdate = function () {
  7306. var vm = this;
  7307. if (vm._watcher) {
  7308. vm._watcher.update();
  7309. }
  7310. };
  7311. Vue.prototype.$destroy = function () {
  7312. var vm = this;
  7313. if (vm._isBeingDestroyed) {
  7314. return
  7315. }
  7316. callHook(vm, 'beforeDestroy');
  7317. vm._isBeingDestroyed = true;
  7318. // remove self from parent
  7319. var parent = vm.$parent;
  7320. if (parent && !parent._isBeingDestroyed && !vm.$options.abstract) {
  7321. remove(parent.$children, vm);
  7322. }
  7323. // teardown watchers
  7324. if (vm._watcher) {
  7325. vm._watcher.teardown();
  7326. }
  7327. var i = vm._watchers.length;
  7328. while (i--) {
  7329. vm._watchers[i].teardown();
  7330. }
  7331. // remove reference from data ob
  7332. // frozen object may not have observer.
  7333. if (vm._data.__ob__) {
  7334. vm._data.__ob__.vmCount--;
  7335. }
  7336. // call the last hook...
  7337. vm._isDestroyed = true;
  7338. // invoke destroy hooks on current rendered tree
  7339. vm.__patch__(vm._vnode, null);
  7340. // fire destroyed hook
  7341. callHook(vm, 'destroyed');
  7342. // turn off all instance listeners.
  7343. vm.$off();
  7344. // remove __vue__ reference
  7345. if (vm.$el) {
  7346. vm.$el.__vue__ = null;
  7347. }
  7348. // release circular reference (#6759)
  7349. if (vm.$vnode) {
  7350. vm.$vnode.parent = null;
  7351. }
  7352. };
  7353. }
  7354. function updateChildComponent (
  7355. vm,
  7356. propsData,
  7357. listeners,
  7358. parentVnode,
  7359. renderChildren
  7360. ) {
  7361. if (true) {
  7362. isUpdatingChildComponent = true;
  7363. }
  7364. // determine whether component has slot children
  7365. // we need to do this before overwriting $options._renderChildren.
  7366. // check if there are dynamic scopedSlots (hand-written or compiled but with
  7367. // dynamic slot names). Static scoped slots compiled from template has the
  7368. // "$stable" marker.
  7369. var newScopedSlots = parentVnode.data.scopedSlots;
  7370. var oldScopedSlots = vm.$scopedSlots;
  7371. var hasDynamicScopedSlot = !!(
  7372. (newScopedSlots && !newScopedSlots.$stable) ||
  7373. (oldScopedSlots !== emptyObject && !oldScopedSlots.$stable) ||
  7374. (newScopedSlots && vm.$scopedSlots.$key !== newScopedSlots.$key)
  7375. );
  7376. // Any static slot children from the parent may have changed during parent's
  7377. // update. Dynamic scoped slots may also have changed. In such cases, a forced
  7378. // update is necessary to ensure correctness.
  7379. var needsForceUpdate = !!(
  7380. renderChildren || // has new static slots
  7381. vm.$options._renderChildren || // has old static slots
  7382. hasDynamicScopedSlot
  7383. );
  7384. vm.$options._parentVnode = parentVnode;
  7385. vm.$vnode = parentVnode; // update vm's placeholder node without re-render
  7386. if (vm._vnode) { // update child tree's parent
  7387. vm._vnode.parent = parentVnode;
  7388. }
  7389. vm.$options._renderChildren = renderChildren;
  7390. // update $attrs and $listeners hash
  7391. // these are also reactive so they may trigger child update if the child
  7392. // used them during render
  7393. vm.$attrs = parentVnode.data.attrs || emptyObject;
  7394. vm.$listeners = listeners || emptyObject;
  7395. // update props
  7396. if (propsData && vm.$options.props) {
  7397. toggleObserving(false);
  7398. var props = vm._props;
  7399. var propKeys = vm.$options._propKeys || [];
  7400. for (var i = 0; i < propKeys.length; i++) {
  7401. var key = propKeys[i];
  7402. var propOptions = vm.$options.props; // wtf flow?
  7403. props[key] = validateProp(key, propOptions, propsData, vm);
  7404. }
  7405. toggleObserving(true);
  7406. // keep a copy of raw propsData
  7407. vm.$options.propsData = propsData;
  7408. }
  7409. // fixed by xxxxxx update properties(mp runtime)
  7410. vm._$updateProperties && vm._$updateProperties(vm);
  7411. // update listeners
  7412. listeners = listeners || emptyObject;
  7413. var oldListeners = vm.$options._parentListeners;
  7414. vm.$options._parentListeners = listeners;
  7415. updateComponentListeners(vm, listeners, oldListeners);
  7416. // resolve slots + force update if has children
  7417. if (needsForceUpdate) {
  7418. vm.$slots = resolveSlots(renderChildren, parentVnode.context);
  7419. vm.$forceUpdate();
  7420. }
  7421. if (true) {
  7422. isUpdatingChildComponent = false;
  7423. }
  7424. }
  7425. function isInInactiveTree (vm) {
  7426. while (vm && (vm = vm.$parent)) {
  7427. if (vm._inactive) { return true }
  7428. }
  7429. return false
  7430. }
  7431. function activateChildComponent (vm, direct) {
  7432. if (direct) {
  7433. vm._directInactive = false;
  7434. if (isInInactiveTree(vm)) {
  7435. return
  7436. }
  7437. } else if (vm._directInactive) {
  7438. return
  7439. }
  7440. if (vm._inactive || vm._inactive === null) {
  7441. vm._inactive = false;
  7442. for (var i = 0; i < vm.$children.length; i++) {
  7443. activateChildComponent(vm.$children[i]);
  7444. }
  7445. callHook(vm, 'activated');
  7446. }
  7447. }
  7448. function deactivateChildComponent (vm, direct) {
  7449. if (direct) {
  7450. vm._directInactive = true;
  7451. if (isInInactiveTree(vm)) {
  7452. return
  7453. }
  7454. }
  7455. if (!vm._inactive) {
  7456. vm._inactive = true;
  7457. for (var i = 0; i < vm.$children.length; i++) {
  7458. deactivateChildComponent(vm.$children[i]);
  7459. }
  7460. callHook(vm, 'deactivated');
  7461. }
  7462. }
  7463. function callHook (vm, hook) {
  7464. // #7573 disable dep collection when invoking lifecycle hooks
  7465. pushTarget();
  7466. var handlers = vm.$options[hook];
  7467. var info = hook + " hook";
  7468. if (handlers) {
  7469. for (var i = 0, j = handlers.length; i < j; i++) {
  7470. invokeWithErrorHandling(handlers[i], vm, null, vm, info);
  7471. }
  7472. }
  7473. if (vm._hasHookEvent) {
  7474. vm.$emit('hook:' + hook);
  7475. }
  7476. popTarget();
  7477. }
  7478. /* */
  7479. var MAX_UPDATE_COUNT = 100;
  7480. var queue = [];
  7481. var activatedChildren = [];
  7482. var has = {};
  7483. var circular = {};
  7484. var waiting = false;
  7485. var flushing = false;
  7486. var index = 0;
  7487. /**
  7488. * Reset the scheduler's state.
  7489. */
  7490. function resetSchedulerState () {
  7491. index = queue.length = activatedChildren.length = 0;
  7492. has = {};
  7493. if (true) {
  7494. circular = {};
  7495. }
  7496. waiting = flushing = false;
  7497. }
  7498. // Async edge case #6566 requires saving the timestamp when event listeners are
  7499. // attached. However, calling performance.now() has a perf overhead especially
  7500. // if the page has thousands of event listeners. Instead, we take a timestamp
  7501. // every time the scheduler flushes and use that for all event listeners
  7502. // attached during that flush.
  7503. var currentFlushTimestamp = 0;
  7504. // Async edge case fix requires storing an event listener's attach timestamp.
  7505. var getNow = Date.now;
  7506. // Determine what event timestamp the browser is using. Annoyingly, the
  7507. // timestamp can either be hi-res (relative to page load) or low-res
  7508. // (relative to UNIX epoch), so in order to compare time we have to use the
  7509. // same timestamp type when saving the flush timestamp.
  7510. // All IE versions use low-res event timestamps, and have problematic clock
  7511. // implementations (#9632)
  7512. if (inBrowser && !isIE) {
  7513. var performance = window.performance;
  7514. if (
  7515. performance &&
  7516. typeof performance.now === 'function' &&
  7517. getNow() > document.createEvent('Event').timeStamp
  7518. ) {
  7519. // if the event timestamp, although evaluated AFTER the Date.now(), is
  7520. // smaller than it, it means the event is using a hi-res timestamp,
  7521. // and we need to use the hi-res version for event listener timestamps as
  7522. // well.
  7523. getNow = function () { return performance.now(); };
  7524. }
  7525. }
  7526. /**
  7527. * Flush both queues and run the watchers.
  7528. */
  7529. function flushSchedulerQueue () {
  7530. currentFlushTimestamp = getNow();
  7531. flushing = true;
  7532. var watcher, id;
  7533. // Sort queue before flush.
  7534. // This ensures that:
  7535. // 1. Components are updated from parent to child. (because parent is always
  7536. // created before the child)
  7537. // 2. A component's user watchers are run before its render watcher (because
  7538. // user watchers are created before the render watcher)
  7539. // 3. If a component is destroyed during a parent component's watcher run,
  7540. // its watchers can be skipped.
  7541. queue.sort(function (a, b) { return a.id - b.id; });
  7542. // do not cache length because more watchers might be pushed
  7543. // as we run existing watchers
  7544. for (index = 0; index < queue.length; index++) {
  7545. watcher = queue[index];
  7546. if (watcher.before) {
  7547. watcher.before();
  7548. }
  7549. id = watcher.id;
  7550. has[id] = null;
  7551. watcher.run();
  7552. // in dev build, check and stop circular updates.
  7553. if ( true && has[id] != null) {
  7554. circular[id] = (circular[id] || 0) + 1;
  7555. if (circular[id] > MAX_UPDATE_COUNT) {
  7556. warn(
  7557. 'You may have an infinite update loop ' + (
  7558. watcher.user
  7559. ? ("in watcher with expression \"" + (watcher.expression) + "\"")
  7560. : "in a component render function."
  7561. ),
  7562. watcher.vm
  7563. );
  7564. break
  7565. }
  7566. }
  7567. }
  7568. // keep copies of post queues before resetting state
  7569. var activatedQueue = activatedChildren.slice();
  7570. var updatedQueue = queue.slice();
  7571. resetSchedulerState();
  7572. // call component updated and activated hooks
  7573. callActivatedHooks(activatedQueue);
  7574. callUpdatedHooks(updatedQueue);
  7575. // devtool hook
  7576. /* istanbul ignore if */
  7577. if (devtools && config.devtools) {
  7578. devtools.emit('flush');
  7579. }
  7580. }
  7581. function callUpdatedHooks (queue) {
  7582. var i = queue.length;
  7583. while (i--) {
  7584. var watcher = queue[i];
  7585. var vm = watcher.vm;
  7586. if (vm._watcher === watcher && vm._isMounted && !vm._isDestroyed) {
  7587. callHook(vm, 'updated');
  7588. }
  7589. }
  7590. }
  7591. /**
  7592. * Queue a kept-alive component that was activated during patch.
  7593. * The queue will be processed after the entire tree has been patched.
  7594. */
  7595. function queueActivatedComponent (vm) {
  7596. // setting _inactive to false here so that a render function can
  7597. // rely on checking whether it's in an inactive tree (e.g. router-view)
  7598. vm._inactive = false;
  7599. activatedChildren.push(vm);
  7600. }
  7601. function callActivatedHooks (queue) {
  7602. for (var i = 0; i < queue.length; i++) {
  7603. queue[i]._inactive = true;
  7604. activateChildComponent(queue[i], true /* true */);
  7605. }
  7606. }
  7607. /**
  7608. * Push a watcher into the watcher queue.
  7609. * Jobs with duplicate IDs will be skipped unless it's
  7610. * pushed when the queue is being flushed.
  7611. */
  7612. function queueWatcher (watcher) {
  7613. var id = watcher.id;
  7614. if (has[id] == null) {
  7615. has[id] = true;
  7616. if (!flushing) {
  7617. queue.push(watcher);
  7618. } else {
  7619. // if already flushing, splice the watcher based on its id
  7620. // if already past its id, it will be run next immediately.
  7621. var i = queue.length - 1;
  7622. while (i > index && queue[i].id > watcher.id) {
  7623. i--;
  7624. }
  7625. queue.splice(i + 1, 0, watcher);
  7626. }
  7627. // queue the flush
  7628. if (!waiting) {
  7629. waiting = true;
  7630. if ( true && !config.async) {
  7631. flushSchedulerQueue();
  7632. return
  7633. }
  7634. nextTick(flushSchedulerQueue);
  7635. }
  7636. }
  7637. }
  7638. /* */
  7639. var uid$2 = 0;
  7640. /**
  7641. * A watcher parses an expression, collects dependencies,
  7642. * and fires callback when the expression value changes.
  7643. * This is used for both the $watch() api and directives.
  7644. */
  7645. var Watcher = function Watcher (
  7646. vm,
  7647. expOrFn,
  7648. cb,
  7649. options,
  7650. isRenderWatcher
  7651. ) {
  7652. this.vm = vm;
  7653. if (isRenderWatcher) {
  7654. vm._watcher = this;
  7655. }
  7656. vm._watchers.push(this);
  7657. // options
  7658. if (options) {
  7659. this.deep = !!options.deep;
  7660. this.user = !!options.user;
  7661. this.lazy = !!options.lazy;
  7662. this.sync = !!options.sync;
  7663. this.before = options.before;
  7664. } else {
  7665. this.deep = this.user = this.lazy = this.sync = false;
  7666. }
  7667. this.cb = cb;
  7668. this.id = ++uid$2; // uid for batching
  7669. this.active = true;
  7670. this.dirty = this.lazy; // for lazy watchers
  7671. this.deps = [];
  7672. this.newDeps = [];
  7673. this.depIds = new _Set();
  7674. this.newDepIds = new _Set();
  7675. this.expression = true
  7676. ? expOrFn.toString()
  7677. : undefined;
  7678. // parse expression for getter
  7679. if (typeof expOrFn === 'function') {
  7680. this.getter = expOrFn;
  7681. } else {
  7682. this.getter = parsePath(expOrFn);
  7683. if (!this.getter) {
  7684. this.getter = noop;
  7685. true && warn(
  7686. "Failed watching path: \"" + expOrFn + "\" " +
  7687. 'Watcher only accepts simple dot-delimited paths. ' +
  7688. 'For full control, use a function instead.',
  7689. vm
  7690. );
  7691. }
  7692. }
  7693. this.value = this.lazy
  7694. ? undefined
  7695. : this.get();
  7696. };
  7697. /**
  7698. * Evaluate the getter, and re-collect dependencies.
  7699. */
  7700. Watcher.prototype.get = function get () {
  7701. pushTarget(this);
  7702. var value;
  7703. var vm = this.vm;
  7704. try {
  7705. value = this.getter.call(vm, vm);
  7706. } catch (e) {
  7707. if (this.user) {
  7708. handleError(e, vm, ("getter for watcher \"" + (this.expression) + "\""));
  7709. } else {
  7710. throw e
  7711. }
  7712. } finally {
  7713. // "touch" every property so they are all tracked as
  7714. // dependencies for deep watching
  7715. if (this.deep) {
  7716. traverse(value);
  7717. }
  7718. popTarget();
  7719. this.cleanupDeps();
  7720. }
  7721. return value
  7722. };
  7723. /**
  7724. * Add a dependency to this directive.
  7725. */
  7726. Watcher.prototype.addDep = function addDep (dep) {
  7727. var id = dep.id;
  7728. if (!this.newDepIds.has(id)) {
  7729. this.newDepIds.add(id);
  7730. this.newDeps.push(dep);
  7731. if (!this.depIds.has(id)) {
  7732. dep.addSub(this);
  7733. }
  7734. }
  7735. };
  7736. /**
  7737. * Clean up for dependency collection.
  7738. */
  7739. Watcher.prototype.cleanupDeps = function cleanupDeps () {
  7740. var i = this.deps.length;
  7741. while (i--) {
  7742. var dep = this.deps[i];
  7743. if (!this.newDepIds.has(dep.id)) {
  7744. dep.removeSub(this);
  7745. }
  7746. }
  7747. var tmp = this.depIds;
  7748. this.depIds = this.newDepIds;
  7749. this.newDepIds = tmp;
  7750. this.newDepIds.clear();
  7751. tmp = this.deps;
  7752. this.deps = this.newDeps;
  7753. this.newDeps = tmp;
  7754. this.newDeps.length = 0;
  7755. };
  7756. /**
  7757. * Subscriber interface.
  7758. * Will be called when a dependency changes.
  7759. */
  7760. Watcher.prototype.update = function update () {
  7761. /* istanbul ignore else */
  7762. if (this.lazy) {
  7763. this.dirty = true;
  7764. } else if (this.sync) {
  7765. this.run();
  7766. } else {
  7767. queueWatcher(this);
  7768. }
  7769. };
  7770. /**
  7771. * Scheduler job interface.
  7772. * Will be called by the scheduler.
  7773. */
  7774. Watcher.prototype.run = function run () {
  7775. if (this.active) {
  7776. var value = this.get();
  7777. if (
  7778. value !== this.value ||
  7779. // Deep watchers and watchers on Object/Arrays should fire even
  7780. // when the value is the same, because the value may
  7781. // have mutated.
  7782. isObject(value) ||
  7783. this.deep
  7784. ) {
  7785. // set new value
  7786. var oldValue = this.value;
  7787. this.value = value;
  7788. if (this.user) {
  7789. try {
  7790. this.cb.call(this.vm, value, oldValue);
  7791. } catch (e) {
  7792. handleError(e, this.vm, ("callback for watcher \"" + (this.expression) + "\""));
  7793. }
  7794. } else {
  7795. this.cb.call(this.vm, value, oldValue);
  7796. }
  7797. }
  7798. }
  7799. };
  7800. /**
  7801. * Evaluate the value of the watcher.
  7802. * This only gets called for lazy watchers.
  7803. */
  7804. Watcher.prototype.evaluate = function evaluate () {
  7805. this.value = this.get();
  7806. this.dirty = false;
  7807. };
  7808. /**
  7809. * Depend on all deps collected by this watcher.
  7810. */
  7811. Watcher.prototype.depend = function depend () {
  7812. var i = this.deps.length;
  7813. while (i--) {
  7814. this.deps[i].depend();
  7815. }
  7816. };
  7817. /**
  7818. * Remove self from all dependencies' subscriber list.
  7819. */
  7820. Watcher.prototype.teardown = function teardown () {
  7821. if (this.active) {
  7822. // remove self from vm's watcher list
  7823. // this is a somewhat expensive operation so we skip it
  7824. // if the vm is being destroyed.
  7825. if (!this.vm._isBeingDestroyed) {
  7826. remove(this.vm._watchers, this);
  7827. }
  7828. var i = this.deps.length;
  7829. while (i--) {
  7830. this.deps[i].removeSub(this);
  7831. }
  7832. this.active = false;
  7833. }
  7834. };
  7835. /* */
  7836. var sharedPropertyDefinition = {
  7837. enumerable: true,
  7838. configurable: true,
  7839. get: noop,
  7840. set: noop
  7841. };
  7842. function proxy (target, sourceKey, key) {
  7843. sharedPropertyDefinition.get = function proxyGetter () {
  7844. return this[sourceKey][key]
  7845. };
  7846. sharedPropertyDefinition.set = function proxySetter (val) {
  7847. this[sourceKey][key] = val;
  7848. };
  7849. Object.defineProperty(target, key, sharedPropertyDefinition);
  7850. }
  7851. function initState (vm) {
  7852. vm._watchers = [];
  7853. var opts = vm.$options;
  7854. if (opts.props) { initProps(vm, opts.props); }
  7855. if (opts.methods) { initMethods(vm, opts.methods); }
  7856. if (opts.data) {
  7857. initData(vm);
  7858. } else {
  7859. observe(vm._data = {}, true /* asRootData */);
  7860. }
  7861. if (opts.computed) { initComputed(vm, opts.computed); }
  7862. if (opts.watch && opts.watch !== nativeWatch) {
  7863. initWatch(vm, opts.watch);
  7864. }
  7865. }
  7866. function initProps (vm, propsOptions) {
  7867. var propsData = vm.$options.propsData || {};
  7868. var props = vm._props = {};
  7869. // cache prop keys so that future props updates can iterate using Array
  7870. // instead of dynamic object key enumeration.
  7871. var keys = vm.$options._propKeys = [];
  7872. var isRoot = !vm.$parent;
  7873. // root instance props should be converted
  7874. if (!isRoot) {
  7875. toggleObserving(false);
  7876. }
  7877. var loop = function ( key ) {
  7878. keys.push(key);
  7879. var value = validateProp(key, propsOptions, propsData, vm);
  7880. /* istanbul ignore else */
  7881. if (true) {
  7882. var hyphenatedKey = hyphenate(key);
  7883. if (isReservedAttribute(hyphenatedKey) ||
  7884. config.isReservedAttr(hyphenatedKey)) {
  7885. warn(
  7886. ("\"" + hyphenatedKey + "\" is a reserved attribute and cannot be used as component prop."),
  7887. vm
  7888. );
  7889. }
  7890. defineReactive$$1(props, key, value, function () {
  7891. if (!isRoot && !isUpdatingChildComponent) {
  7892. {
  7893. if(vm.mpHost === 'mp-baidu' || vm.mpHost === 'mp-kuaishou' || vm.mpHost === 'mp-xhs'){//百度、快手、小红书 observer 在 setData callback 之后触发,直接忽略该 warn
  7894. return
  7895. }
  7896. //fixed by xxxxxx __next_tick_pending,uni://form-field 时不告警
  7897. if(
  7898. key === 'value' &&
  7899. Array.isArray(vm.$options.behaviors) &&
  7900. vm.$options.behaviors.indexOf('uni://form-field') !== -1
  7901. ){
  7902. return
  7903. }
  7904. if(vm._getFormData){
  7905. return
  7906. }
  7907. var $parent = vm.$parent;
  7908. while($parent){
  7909. if($parent.__next_tick_pending){
  7910. return
  7911. }
  7912. $parent = $parent.$parent;
  7913. }
  7914. }
  7915. warn(
  7916. "Avoid mutating a prop directly since the value will be " +
  7917. "overwritten whenever the parent component re-renders. " +
  7918. "Instead, use a data or computed property based on the prop's " +
  7919. "value. Prop being mutated: \"" + key + "\"",
  7920. vm
  7921. );
  7922. }
  7923. });
  7924. } else {}
  7925. // static props are already proxied on the component's prototype
  7926. // during Vue.extend(). We only need to proxy props defined at
  7927. // instantiation here.
  7928. if (!(key in vm)) {
  7929. proxy(vm, "_props", key);
  7930. }
  7931. };
  7932. for (var key in propsOptions) loop( key );
  7933. toggleObserving(true);
  7934. }
  7935. function initData (vm) {
  7936. var data = vm.$options.data;
  7937. data = vm._data = typeof data === 'function'
  7938. ? getData(data, vm)
  7939. : data || {};
  7940. if (!isPlainObject(data)) {
  7941. data = {};
  7942. true && warn(
  7943. 'data functions should return an object:\n' +
  7944. 'https://vuejs.org/v2/guide/components.html#data-Must-Be-a-Function',
  7945. vm
  7946. );
  7947. }
  7948. // proxy data on instance
  7949. var keys = Object.keys(data);
  7950. var props = vm.$options.props;
  7951. var methods = vm.$options.methods;
  7952. var i = keys.length;
  7953. while (i--) {
  7954. var key = keys[i];
  7955. if (true) {
  7956. if (methods && hasOwn(methods, key)) {
  7957. warn(
  7958. ("Method \"" + key + "\" has already been defined as a data property."),
  7959. vm
  7960. );
  7961. }
  7962. }
  7963. if (props && hasOwn(props, key)) {
  7964. true && warn(
  7965. "The data property \"" + key + "\" is already declared as a prop. " +
  7966. "Use prop default value instead.",
  7967. vm
  7968. );
  7969. } else if (!isReserved(key)) {
  7970. proxy(vm, "_data", key);
  7971. }
  7972. }
  7973. // observe data
  7974. observe(data, true /* asRootData */);
  7975. }
  7976. function getData (data, vm) {
  7977. // #7573 disable dep collection when invoking data getters
  7978. pushTarget();
  7979. try {
  7980. return data.call(vm, vm)
  7981. } catch (e) {
  7982. handleError(e, vm, "data()");
  7983. return {}
  7984. } finally {
  7985. popTarget();
  7986. }
  7987. }
  7988. var computedWatcherOptions = { lazy: true };
  7989. function initComputed (vm, computed) {
  7990. // $flow-disable-line
  7991. var watchers = vm._computedWatchers = Object.create(null);
  7992. // computed properties are just getters during SSR
  7993. var isSSR = isServerRendering();
  7994. for (var key in computed) {
  7995. var userDef = computed[key];
  7996. var getter = typeof userDef === 'function' ? userDef : userDef.get;
  7997. if ( true && getter == null) {
  7998. warn(
  7999. ("Getter is missing for computed property \"" + key + "\"."),
  8000. vm
  8001. );
  8002. }
  8003. if (!isSSR) {
  8004. // create internal watcher for the computed property.
  8005. watchers[key] = new Watcher(
  8006. vm,
  8007. getter || noop,
  8008. noop,
  8009. computedWatcherOptions
  8010. );
  8011. }
  8012. // component-defined computed properties are already defined on the
  8013. // component prototype. We only need to define computed properties defined
  8014. // at instantiation here.
  8015. if (!(key in vm)) {
  8016. defineComputed(vm, key, userDef);
  8017. } else if (true) {
  8018. if (key in vm.$data) {
  8019. warn(("The computed property \"" + key + "\" is already defined in data."), vm);
  8020. } else if (vm.$options.props && key in vm.$options.props) {
  8021. warn(("The computed property \"" + key + "\" is already defined as a prop."), vm);
  8022. }
  8023. }
  8024. }
  8025. }
  8026. function defineComputed (
  8027. target,
  8028. key,
  8029. userDef
  8030. ) {
  8031. var shouldCache = !isServerRendering();
  8032. if (typeof userDef === 'function') {
  8033. sharedPropertyDefinition.get = shouldCache
  8034. ? createComputedGetter(key)
  8035. : createGetterInvoker(userDef);
  8036. sharedPropertyDefinition.set = noop;
  8037. } else {
  8038. sharedPropertyDefinition.get = userDef.get
  8039. ? shouldCache && userDef.cache !== false
  8040. ? createComputedGetter(key)
  8041. : createGetterInvoker(userDef.get)
  8042. : noop;
  8043. sharedPropertyDefinition.set = userDef.set || noop;
  8044. }
  8045. if ( true &&
  8046. sharedPropertyDefinition.set === noop) {
  8047. sharedPropertyDefinition.set = function () {
  8048. warn(
  8049. ("Computed property \"" + key + "\" was assigned to but it has no setter."),
  8050. this
  8051. );
  8052. };
  8053. }
  8054. Object.defineProperty(target, key, sharedPropertyDefinition);
  8055. }
  8056. function createComputedGetter (key) {
  8057. return function computedGetter () {
  8058. var watcher = this._computedWatchers && this._computedWatchers[key];
  8059. if (watcher) {
  8060. if (watcher.dirty) {
  8061. watcher.evaluate();
  8062. }
  8063. if (Dep.SharedObject.target) {// fixed by xxxxxx
  8064. watcher.depend();
  8065. }
  8066. return watcher.value
  8067. }
  8068. }
  8069. }
  8070. function createGetterInvoker(fn) {
  8071. return function computedGetter () {
  8072. return fn.call(this, this)
  8073. }
  8074. }
  8075. function initMethods (vm, methods) {
  8076. var props = vm.$options.props;
  8077. for (var key in methods) {
  8078. if (true) {
  8079. if (typeof methods[key] !== 'function') {
  8080. warn(
  8081. "Method \"" + key + "\" has type \"" + (typeof methods[key]) + "\" in the component definition. " +
  8082. "Did you reference the function correctly?",
  8083. vm
  8084. );
  8085. }
  8086. if (props && hasOwn(props, key)) {
  8087. warn(
  8088. ("Method \"" + key + "\" has already been defined as a prop."),
  8089. vm
  8090. );
  8091. }
  8092. if ((key in vm) && isReserved(key)) {
  8093. warn(
  8094. "Method \"" + key + "\" conflicts with an existing Vue instance method. " +
  8095. "Avoid defining component methods that start with _ or $."
  8096. );
  8097. }
  8098. }
  8099. vm[key] = typeof methods[key] !== 'function' ? noop : bind(methods[key], vm);
  8100. }
  8101. }
  8102. function initWatch (vm, watch) {
  8103. for (var key in watch) {
  8104. var handler = watch[key];
  8105. if (Array.isArray(handler)) {
  8106. for (var i = 0; i < handler.length; i++) {
  8107. createWatcher(vm, key, handler[i]);
  8108. }
  8109. } else {
  8110. createWatcher(vm, key, handler);
  8111. }
  8112. }
  8113. }
  8114. function createWatcher (
  8115. vm,
  8116. expOrFn,
  8117. handler,
  8118. options
  8119. ) {
  8120. if (isPlainObject(handler)) {
  8121. options = handler;
  8122. handler = handler.handler;
  8123. }
  8124. if (typeof handler === 'string') {
  8125. handler = vm[handler];
  8126. }
  8127. return vm.$watch(expOrFn, handler, options)
  8128. }
  8129. function stateMixin (Vue) {
  8130. // flow somehow has problems with directly declared definition object
  8131. // when using Object.defineProperty, so we have to procedurally build up
  8132. // the object here.
  8133. var dataDef = {};
  8134. dataDef.get = function () { return this._data };
  8135. var propsDef = {};
  8136. propsDef.get = function () { return this._props };
  8137. if (true) {
  8138. dataDef.set = function () {
  8139. warn(
  8140. 'Avoid replacing instance root $data. ' +
  8141. 'Use nested data properties instead.',
  8142. this
  8143. );
  8144. };
  8145. propsDef.set = function () {
  8146. warn("$props is readonly.", this);
  8147. };
  8148. }
  8149. Object.defineProperty(Vue.prototype, '$data', dataDef);
  8150. Object.defineProperty(Vue.prototype, '$props', propsDef);
  8151. Vue.prototype.$set = set;
  8152. Vue.prototype.$delete = del;
  8153. Vue.prototype.$watch = function (
  8154. expOrFn,
  8155. cb,
  8156. options
  8157. ) {
  8158. var vm = this;
  8159. if (isPlainObject(cb)) {
  8160. return createWatcher(vm, expOrFn, cb, options)
  8161. }
  8162. options = options || {};
  8163. options.user = true;
  8164. var watcher = new Watcher(vm, expOrFn, cb, options);
  8165. if (options.immediate) {
  8166. try {
  8167. cb.call(vm, watcher.value);
  8168. } catch (error) {
  8169. handleError(error, vm, ("callback for immediate watcher \"" + (watcher.expression) + "\""));
  8170. }
  8171. }
  8172. return function unwatchFn () {
  8173. watcher.teardown();
  8174. }
  8175. };
  8176. }
  8177. /* */
  8178. var uid$3 = 0;
  8179. function initMixin (Vue) {
  8180. Vue.prototype._init = function (options) {
  8181. var vm = this;
  8182. // a uid
  8183. vm._uid = uid$3++;
  8184. var startTag, endTag;
  8185. /* istanbul ignore if */
  8186. if ( true && config.performance && mark) {
  8187. startTag = "vue-perf-start:" + (vm._uid);
  8188. endTag = "vue-perf-end:" + (vm._uid);
  8189. mark(startTag);
  8190. }
  8191. // a flag to avoid this being observed
  8192. vm._isVue = true;
  8193. // merge options
  8194. if (options && options._isComponent) {
  8195. // optimize internal component instantiation
  8196. // since dynamic options merging is pretty slow, and none of the
  8197. // internal component options needs special treatment.
  8198. initInternalComponent(vm, options);
  8199. } else {
  8200. vm.$options = mergeOptions(
  8201. resolveConstructorOptions(vm.constructor),
  8202. options || {},
  8203. vm
  8204. );
  8205. }
  8206. /* istanbul ignore else */
  8207. if (true) {
  8208. initProxy(vm);
  8209. } else {}
  8210. // expose real self
  8211. vm._self = vm;
  8212. initLifecycle(vm);
  8213. initEvents(vm);
  8214. initRender(vm);
  8215. callHook(vm, 'beforeCreate');
  8216. !vm._$fallback && initInjections(vm); // resolve injections before data/props
  8217. initState(vm);
  8218. !vm._$fallback && initProvide(vm); // resolve provide after data/props
  8219. !vm._$fallback && callHook(vm, 'created');
  8220. /* istanbul ignore if */
  8221. if ( true && config.performance && mark) {
  8222. vm._name = formatComponentName(vm, false);
  8223. mark(endTag);
  8224. measure(("vue " + (vm._name) + " init"), startTag, endTag);
  8225. }
  8226. if (vm.$options.el) {
  8227. vm.$mount(vm.$options.el);
  8228. }
  8229. };
  8230. }
  8231. function initInternalComponent (vm, options) {
  8232. var opts = vm.$options = Object.create(vm.constructor.options);
  8233. // doing this because it's faster than dynamic enumeration.
  8234. var parentVnode = options._parentVnode;
  8235. opts.parent = options.parent;
  8236. opts._parentVnode = parentVnode;
  8237. var vnodeComponentOptions = parentVnode.componentOptions;
  8238. opts.propsData = vnodeComponentOptions.propsData;
  8239. opts._parentListeners = vnodeComponentOptions.listeners;
  8240. opts._renderChildren = vnodeComponentOptions.children;
  8241. opts._componentTag = vnodeComponentOptions.tag;
  8242. if (options.render) {
  8243. opts.render = options.render;
  8244. opts.staticRenderFns = options.staticRenderFns;
  8245. }
  8246. }
  8247. function resolveConstructorOptions (Ctor) {
  8248. var options = Ctor.options;
  8249. if (Ctor.super) {
  8250. var superOptions = resolveConstructorOptions(Ctor.super);
  8251. var cachedSuperOptions = Ctor.superOptions;
  8252. if (superOptions !== cachedSuperOptions) {
  8253. // super option changed,
  8254. // need to resolve new options.
  8255. Ctor.superOptions = superOptions;
  8256. // check if there are any late-modified/attached options (#4976)
  8257. var modifiedOptions = resolveModifiedOptions(Ctor);
  8258. // update base extend options
  8259. if (modifiedOptions) {
  8260. extend(Ctor.extendOptions, modifiedOptions);
  8261. }
  8262. options = Ctor.options = mergeOptions(superOptions, Ctor.extendOptions);
  8263. if (options.name) {
  8264. options.components[options.name] = Ctor;
  8265. }
  8266. }
  8267. }
  8268. return options
  8269. }
  8270. function resolveModifiedOptions (Ctor) {
  8271. var modified;
  8272. var latest = Ctor.options;
  8273. var sealed = Ctor.sealedOptions;
  8274. for (var key in latest) {
  8275. if (latest[key] !== sealed[key]) {
  8276. if (!modified) { modified = {}; }
  8277. modified[key] = latest[key];
  8278. }
  8279. }
  8280. return modified
  8281. }
  8282. function Vue (options) {
  8283. if ( true &&
  8284. !(this instanceof Vue)
  8285. ) {
  8286. warn('Vue is a constructor and should be called with the `new` keyword');
  8287. }
  8288. this._init(options);
  8289. }
  8290. initMixin(Vue);
  8291. stateMixin(Vue);
  8292. eventsMixin(Vue);
  8293. lifecycleMixin(Vue);
  8294. renderMixin(Vue);
  8295. /* */
  8296. function initUse (Vue) {
  8297. Vue.use = function (plugin) {
  8298. var installedPlugins = (this._installedPlugins || (this._installedPlugins = []));
  8299. if (installedPlugins.indexOf(plugin) > -1) {
  8300. return this
  8301. }
  8302. // additional parameters
  8303. var args = toArray(arguments, 1);
  8304. args.unshift(this);
  8305. if (typeof plugin.install === 'function') {
  8306. plugin.install.apply(plugin, args);
  8307. } else if (typeof plugin === 'function') {
  8308. plugin.apply(null, args);
  8309. }
  8310. installedPlugins.push(plugin);
  8311. return this
  8312. };
  8313. }
  8314. /* */
  8315. function initMixin$1 (Vue) {
  8316. Vue.mixin = function (mixin) {
  8317. this.options = mergeOptions(this.options, mixin);
  8318. return this
  8319. };
  8320. }
  8321. /* */
  8322. function initExtend (Vue) {
  8323. /**
  8324. * Each instance constructor, including Vue, has a unique
  8325. * cid. This enables us to create wrapped "child
  8326. * constructors" for prototypal inheritance and cache them.
  8327. */
  8328. Vue.cid = 0;
  8329. var cid = 1;
  8330. /**
  8331. * Class inheritance
  8332. */
  8333. Vue.extend = function (extendOptions) {
  8334. extendOptions = extendOptions || {};
  8335. var Super = this;
  8336. var SuperId = Super.cid;
  8337. var cachedCtors = extendOptions._Ctor || (extendOptions._Ctor = {});
  8338. if (cachedCtors[SuperId]) {
  8339. return cachedCtors[SuperId]
  8340. }
  8341. var name = extendOptions.name || Super.options.name;
  8342. if ( true && name) {
  8343. validateComponentName(name);
  8344. }
  8345. var Sub = function VueComponent (options) {
  8346. this._init(options);
  8347. };
  8348. Sub.prototype = Object.create(Super.prototype);
  8349. Sub.prototype.constructor = Sub;
  8350. Sub.cid = cid++;
  8351. Sub.options = mergeOptions(
  8352. Super.options,
  8353. extendOptions
  8354. );
  8355. Sub['super'] = Super;
  8356. // For props and computed properties, we define the proxy getters on
  8357. // the Vue instances at extension time, on the extended prototype. This
  8358. // avoids Object.defineProperty calls for each instance created.
  8359. if (Sub.options.props) {
  8360. initProps$1(Sub);
  8361. }
  8362. if (Sub.options.computed) {
  8363. initComputed$1(Sub);
  8364. }
  8365. // allow further extension/mixin/plugin usage
  8366. Sub.extend = Super.extend;
  8367. Sub.mixin = Super.mixin;
  8368. Sub.use = Super.use;
  8369. // create asset registers, so extended classes
  8370. // can have their private assets too.
  8371. ASSET_TYPES.forEach(function (type) {
  8372. Sub[type] = Super[type];
  8373. });
  8374. // enable recursive self-lookup
  8375. if (name) {
  8376. Sub.options.components[name] = Sub;
  8377. }
  8378. // keep a reference to the super options at extension time.
  8379. // later at instantiation we can check if Super's options have
  8380. // been updated.
  8381. Sub.superOptions = Super.options;
  8382. Sub.extendOptions = extendOptions;
  8383. Sub.sealedOptions = extend({}, Sub.options);
  8384. // cache constructor
  8385. cachedCtors[SuperId] = Sub;
  8386. return Sub
  8387. };
  8388. }
  8389. function initProps$1 (Comp) {
  8390. var props = Comp.options.props;
  8391. for (var key in props) {
  8392. proxy(Comp.prototype, "_props", key);
  8393. }
  8394. }
  8395. function initComputed$1 (Comp) {
  8396. var computed = Comp.options.computed;
  8397. for (var key in computed) {
  8398. defineComputed(Comp.prototype, key, computed[key]);
  8399. }
  8400. }
  8401. /* */
  8402. function initAssetRegisters (Vue) {
  8403. /**
  8404. * Create asset registration methods.
  8405. */
  8406. ASSET_TYPES.forEach(function (type) {
  8407. Vue[type] = function (
  8408. id,
  8409. definition
  8410. ) {
  8411. if (!definition) {
  8412. return this.options[type + 's'][id]
  8413. } else {
  8414. /* istanbul ignore if */
  8415. if ( true && type === 'component') {
  8416. validateComponentName(id);
  8417. }
  8418. if (type === 'component' && isPlainObject(definition)) {
  8419. definition.name = definition.name || id;
  8420. definition = this.options._base.extend(definition);
  8421. }
  8422. if (type === 'directive' && typeof definition === 'function') {
  8423. definition = { bind: definition, update: definition };
  8424. }
  8425. this.options[type + 's'][id] = definition;
  8426. return definition
  8427. }
  8428. };
  8429. });
  8430. }
  8431. /* */
  8432. function getComponentName (opts) {
  8433. return opts && (opts.Ctor.options.name || opts.tag)
  8434. }
  8435. function matches (pattern, name) {
  8436. if (Array.isArray(pattern)) {
  8437. return pattern.indexOf(name) > -1
  8438. } else if (typeof pattern === 'string') {
  8439. return pattern.split(',').indexOf(name) > -1
  8440. } else if (isRegExp(pattern)) {
  8441. return pattern.test(name)
  8442. }
  8443. /* istanbul ignore next */
  8444. return false
  8445. }
  8446. function pruneCache (keepAliveInstance, filter) {
  8447. var cache = keepAliveInstance.cache;
  8448. var keys = keepAliveInstance.keys;
  8449. var _vnode = keepAliveInstance._vnode;
  8450. for (var key in cache) {
  8451. var cachedNode = cache[key];
  8452. if (cachedNode) {
  8453. var name = getComponentName(cachedNode.componentOptions);
  8454. if (name && !filter(name)) {
  8455. pruneCacheEntry(cache, key, keys, _vnode);
  8456. }
  8457. }
  8458. }
  8459. }
  8460. function pruneCacheEntry (
  8461. cache,
  8462. key,
  8463. keys,
  8464. current
  8465. ) {
  8466. var cached$$1 = cache[key];
  8467. if (cached$$1 && (!current || cached$$1.tag !== current.tag)) {
  8468. cached$$1.componentInstance.$destroy();
  8469. }
  8470. cache[key] = null;
  8471. remove(keys, key);
  8472. }
  8473. var patternTypes = [String, RegExp, Array];
  8474. var KeepAlive = {
  8475. name: 'keep-alive',
  8476. abstract: true,
  8477. props: {
  8478. include: patternTypes,
  8479. exclude: patternTypes,
  8480. max: [String, Number]
  8481. },
  8482. created: function created () {
  8483. this.cache = Object.create(null);
  8484. this.keys = [];
  8485. },
  8486. destroyed: function destroyed () {
  8487. for (var key in this.cache) {
  8488. pruneCacheEntry(this.cache, key, this.keys);
  8489. }
  8490. },
  8491. mounted: function mounted () {
  8492. var this$1 = this;
  8493. this.$watch('include', function (val) {
  8494. pruneCache(this$1, function (name) { return matches(val, name); });
  8495. });
  8496. this.$watch('exclude', function (val) {
  8497. pruneCache(this$1, function (name) { return !matches(val, name); });
  8498. });
  8499. },
  8500. render: function render () {
  8501. var slot = this.$slots.default;
  8502. var vnode = getFirstComponentChild(slot);
  8503. var componentOptions = vnode && vnode.componentOptions;
  8504. if (componentOptions) {
  8505. // check pattern
  8506. var name = getComponentName(componentOptions);
  8507. var ref = this;
  8508. var include = ref.include;
  8509. var exclude = ref.exclude;
  8510. if (
  8511. // not included
  8512. (include && (!name || !matches(include, name))) ||
  8513. // excluded
  8514. (exclude && name && matches(exclude, name))
  8515. ) {
  8516. return vnode
  8517. }
  8518. var ref$1 = this;
  8519. var cache = ref$1.cache;
  8520. var keys = ref$1.keys;
  8521. var key = vnode.key == null
  8522. // same constructor may get registered as different local components
  8523. // so cid alone is not enough (#3269)
  8524. ? componentOptions.Ctor.cid + (componentOptions.tag ? ("::" + (componentOptions.tag)) : '')
  8525. : vnode.key;
  8526. if (cache[key]) {
  8527. vnode.componentInstance = cache[key].componentInstance;
  8528. // make current key freshest
  8529. remove(keys, key);
  8530. keys.push(key);
  8531. } else {
  8532. cache[key] = vnode;
  8533. keys.push(key);
  8534. // prune oldest entry
  8535. if (this.max && keys.length > parseInt(this.max)) {
  8536. pruneCacheEntry(cache, keys[0], keys, this._vnode);
  8537. }
  8538. }
  8539. vnode.data.keepAlive = true;
  8540. }
  8541. return vnode || (slot && slot[0])
  8542. }
  8543. };
  8544. var builtInComponents = {
  8545. KeepAlive: KeepAlive
  8546. };
  8547. /* */
  8548. function initGlobalAPI (Vue) {
  8549. // config
  8550. var configDef = {};
  8551. configDef.get = function () { return config; };
  8552. if (true) {
  8553. configDef.set = function () {
  8554. warn(
  8555. 'Do not replace the Vue.config object, set individual fields instead.'
  8556. );
  8557. };
  8558. }
  8559. Object.defineProperty(Vue, 'config', configDef);
  8560. // exposed util methods.
  8561. // NOTE: these are not considered part of the public API - avoid relying on
  8562. // them unless you are aware of the risk.
  8563. Vue.util = {
  8564. warn: warn,
  8565. extend: extend,
  8566. mergeOptions: mergeOptions,
  8567. defineReactive: defineReactive$$1
  8568. };
  8569. Vue.set = set;
  8570. Vue.delete = del;
  8571. Vue.nextTick = nextTick;
  8572. // 2.6 explicit observable API
  8573. Vue.observable = function (obj) {
  8574. observe(obj);
  8575. return obj
  8576. };
  8577. Vue.options = Object.create(null);
  8578. ASSET_TYPES.forEach(function (type) {
  8579. Vue.options[type + 's'] = Object.create(null);
  8580. });
  8581. // this is used to identify the "base" constructor to extend all plain-object
  8582. // components with in Weex's multi-instance scenarios.
  8583. Vue.options._base = Vue;
  8584. extend(Vue.options.components, builtInComponents);
  8585. initUse(Vue);
  8586. initMixin$1(Vue);
  8587. initExtend(Vue);
  8588. initAssetRegisters(Vue);
  8589. }
  8590. initGlobalAPI(Vue);
  8591. Object.defineProperty(Vue.prototype, '$isServer', {
  8592. get: isServerRendering
  8593. });
  8594. Object.defineProperty(Vue.prototype, '$ssrContext', {
  8595. get: function get () {
  8596. /* istanbul ignore next */
  8597. return this.$vnode && this.$vnode.ssrContext
  8598. }
  8599. });
  8600. // expose FunctionalRenderContext for ssr runtime helper installation
  8601. Object.defineProperty(Vue, 'FunctionalRenderContext', {
  8602. value: FunctionalRenderContext
  8603. });
  8604. Vue.version = '2.6.11';
  8605. /**
  8606. * https://raw.githubusercontent.com/Tencent/westore/master/packages/westore/utils/diff.js
  8607. */
  8608. var ARRAYTYPE = '[object Array]';
  8609. var OBJECTTYPE = '[object Object]';
  8610. var NULLTYPE = '[object Null]';
  8611. var UNDEFINEDTYPE = '[object Undefined]';
  8612. // const FUNCTIONTYPE = '[object Function]'
  8613. function diff(current, pre) {
  8614. var result = {};
  8615. syncKeys(current, pre);
  8616. _diff(current, pre, '', result);
  8617. return result
  8618. }
  8619. function syncKeys(current, pre) {
  8620. if (current === pre) { return }
  8621. var rootCurrentType = type(current);
  8622. var rootPreType = type(pre);
  8623. if (rootCurrentType == OBJECTTYPE && rootPreType == OBJECTTYPE) {
  8624. if(Object.keys(current).length >= Object.keys(pre).length){
  8625. for (var key in pre) {
  8626. var currentValue = current[key];
  8627. if (currentValue === undefined) {
  8628. current[key] = null;
  8629. } else {
  8630. syncKeys(currentValue, pre[key]);
  8631. }
  8632. }
  8633. }
  8634. } else if (rootCurrentType == ARRAYTYPE && rootPreType == ARRAYTYPE) {
  8635. if (current.length >= pre.length) {
  8636. pre.forEach(function (item, index) {
  8637. syncKeys(current[index], item);
  8638. });
  8639. }
  8640. }
  8641. }
  8642. function nullOrUndefined(currentType, preType) {
  8643. if(
  8644. (currentType === NULLTYPE || currentType === UNDEFINEDTYPE) &&
  8645. (preType === NULLTYPE || preType === UNDEFINEDTYPE)
  8646. ) {
  8647. return false
  8648. }
  8649. return true
  8650. }
  8651. function _diff(current, pre, path, result) {
  8652. if (current === pre) { return }
  8653. var rootCurrentType = type(current);
  8654. var rootPreType = type(pre);
  8655. if (rootCurrentType == OBJECTTYPE) {
  8656. if (rootPreType != OBJECTTYPE || Object.keys(current).length < Object.keys(pre).length) {
  8657. setResult(result, path, current);
  8658. } else {
  8659. var loop = function ( key ) {
  8660. var currentValue = current[key];
  8661. var preValue = pre[key];
  8662. var currentType = type(currentValue);
  8663. var preType = type(preValue);
  8664. if (currentType != ARRAYTYPE && currentType != OBJECTTYPE) {
  8665. if (currentValue !== pre[key] && nullOrUndefined(currentType, preType)) {
  8666. setResult(result, (path == '' ? '' : path + ".") + key, currentValue);
  8667. }
  8668. } else if (currentType == ARRAYTYPE) {
  8669. if (preType != ARRAYTYPE) {
  8670. setResult(result, (path == '' ? '' : path + ".") + key, currentValue);
  8671. } else {
  8672. if (currentValue.length < preValue.length) {
  8673. setResult(result, (path == '' ? '' : path + ".") + key, currentValue);
  8674. } else {
  8675. currentValue.forEach(function (item, index) {
  8676. _diff(item, preValue[index], (path == '' ? '' : path + ".") + key + '[' + index + ']', result);
  8677. });
  8678. }
  8679. }
  8680. } else if (currentType == OBJECTTYPE) {
  8681. if (preType != OBJECTTYPE || Object.keys(currentValue).length < Object.keys(preValue).length) {
  8682. setResult(result, (path == '' ? '' : path + ".") + key, currentValue);
  8683. } else {
  8684. for (var subKey in currentValue) {
  8685. _diff(currentValue[subKey], preValue[subKey], (path == '' ? '' : path + ".") + key + '.' + subKey, result);
  8686. }
  8687. }
  8688. }
  8689. };
  8690. for (var key in current) loop( key );
  8691. }
  8692. } else if (rootCurrentType == ARRAYTYPE) {
  8693. if (rootPreType != ARRAYTYPE) {
  8694. setResult(result, path, current);
  8695. } else {
  8696. if (current.length < pre.length) {
  8697. setResult(result, path, current);
  8698. } else {
  8699. current.forEach(function (item, index) {
  8700. _diff(item, pre[index], path + '[' + index + ']', result);
  8701. });
  8702. }
  8703. }
  8704. } else {
  8705. setResult(result, path, current);
  8706. }
  8707. }
  8708. function setResult(result, k, v) {
  8709. // if (type(v) != FUNCTIONTYPE) {
  8710. result[k] = v;
  8711. // }
  8712. }
  8713. function type(obj) {
  8714. return Object.prototype.toString.call(obj)
  8715. }
  8716. /* */
  8717. function flushCallbacks$1(vm) {
  8718. if (vm.__next_tick_callbacks && vm.__next_tick_callbacks.length) {
  8719. if (Object({"NODE_ENV":"development","VUE_APP_DARK_MODE":"false","VUE_APP_NAME":"核销工具DY","VUE_APP_PLATFORM":"mp-toutiao","BASE_URL":"/"}).VUE_APP_DEBUG) {
  8720. var mpInstance = vm.$scope;
  8721. console.log('[' + (+new Date) + '][' + (mpInstance.is || mpInstance.route) + '][' + vm._uid +
  8722. ']:flushCallbacks[' + vm.__next_tick_callbacks.length + ']');
  8723. }
  8724. var copies = vm.__next_tick_callbacks.slice(0);
  8725. vm.__next_tick_callbacks.length = 0;
  8726. for (var i = 0; i < copies.length; i++) {
  8727. copies[i]();
  8728. }
  8729. }
  8730. }
  8731. function hasRenderWatcher(vm) {
  8732. return queue.find(function (watcher) { return vm._watcher === watcher; })
  8733. }
  8734. function nextTick$1(vm, cb) {
  8735. //1.nextTick 之前 已 setData 且 setData 还未回调完成
  8736. //2.nextTick 之前存在 render watcher
  8737. if (!vm.__next_tick_pending && !hasRenderWatcher(vm)) {
  8738. if(Object({"NODE_ENV":"development","VUE_APP_DARK_MODE":"false","VUE_APP_NAME":"核销工具DY","VUE_APP_PLATFORM":"mp-toutiao","BASE_URL":"/"}).VUE_APP_DEBUG){
  8739. var mpInstance = vm.$scope;
  8740. console.log('[' + (+new Date) + '][' + (mpInstance.is || mpInstance.route) + '][' + vm._uid +
  8741. ']:nextVueTick');
  8742. }
  8743. return nextTick(cb, vm)
  8744. }else{
  8745. if(Object({"NODE_ENV":"development","VUE_APP_DARK_MODE":"false","VUE_APP_NAME":"核销工具DY","VUE_APP_PLATFORM":"mp-toutiao","BASE_URL":"/"}).VUE_APP_DEBUG){
  8746. var mpInstance$1 = vm.$scope;
  8747. console.log('[' + (+new Date) + '][' + (mpInstance$1.is || mpInstance$1.route) + '][' + vm._uid +
  8748. ']:nextMPTick');
  8749. }
  8750. }
  8751. var _resolve;
  8752. if (!vm.__next_tick_callbacks) {
  8753. vm.__next_tick_callbacks = [];
  8754. }
  8755. vm.__next_tick_callbacks.push(function () {
  8756. if (cb) {
  8757. try {
  8758. cb.call(vm);
  8759. } catch (e) {
  8760. handleError(e, vm, 'nextTick');
  8761. }
  8762. } else if (_resolve) {
  8763. _resolve(vm);
  8764. }
  8765. });
  8766. // $flow-disable-line
  8767. if (!cb && typeof Promise !== 'undefined') {
  8768. return new Promise(function (resolve) {
  8769. _resolve = resolve;
  8770. })
  8771. }
  8772. }
  8773. /* */
  8774. function clearInstance(key, value) {
  8775. // 简易去除 Vue 和小程序组件实例
  8776. if (value) {
  8777. if (value._isVue || value.__v_isMPComponent) {
  8778. return {}
  8779. }
  8780. }
  8781. return value
  8782. }
  8783. function cloneWithData(vm) {
  8784. // 确保当前 vm 所有数据被同步
  8785. var ret = Object.create(null);
  8786. var dataKeys = [].concat(
  8787. Object.keys(vm._data || {}),
  8788. Object.keys(vm._computedWatchers || {}));
  8789. dataKeys.reduce(function(ret, key) {
  8790. ret[key] = vm[key];
  8791. return ret
  8792. }, ret);
  8793. // vue-composition-api
  8794. var compositionApiState = vm.__composition_api_state__ || vm.__secret_vfa_state__;
  8795. var rawBindings = compositionApiState && compositionApiState.rawBindings;
  8796. if (rawBindings) {
  8797. Object.keys(rawBindings).forEach(function (key) {
  8798. ret[key] = vm[key];
  8799. });
  8800. }
  8801. //TODO 需要把无用数据处理掉,比如 list=>l0 则 list 需要移除,否则多传输一份数据
  8802. Object.assign(ret, vm.$mp.data || {});
  8803. if (
  8804. Array.isArray(vm.$options.behaviors) &&
  8805. vm.$options.behaviors.indexOf('uni://form-field') !== -1
  8806. ) { //form-field
  8807. ret['name'] = vm.name;
  8808. ret['value'] = vm.value;
  8809. }
  8810. return JSON.parse(JSON.stringify(ret, clearInstance))
  8811. }
  8812. var patch = function(oldVnode, vnode) {
  8813. var this$1 = this;
  8814. if (vnode === null) { //destroy
  8815. return
  8816. }
  8817. if (this.mpType === 'page' || this.mpType === 'component') {
  8818. var mpInstance = this.$scope;
  8819. var data = Object.create(null);
  8820. try {
  8821. data = cloneWithData(this);
  8822. } catch (err) {
  8823. console.error(err);
  8824. }
  8825. data.__webviewId__ = mpInstance.data.__webviewId__;
  8826. var mpData = Object.create(null);
  8827. Object.keys(data).forEach(function (key) { //仅同步 data 中有的数据
  8828. mpData[key] = mpInstance.data[key];
  8829. });
  8830. var diffData = this.$shouldDiffData === false ? data : diff(data, mpData);
  8831. if (Object.keys(diffData).length) {
  8832. if (Object({"NODE_ENV":"development","VUE_APP_DARK_MODE":"false","VUE_APP_NAME":"核销工具DY","VUE_APP_PLATFORM":"mp-toutiao","BASE_URL":"/"}).VUE_APP_DEBUG) {
  8833. console.log('[' + (+new Date) + '][' + (mpInstance.is || mpInstance.route) + '][' + this._uid +
  8834. ']差量更新',
  8835. JSON.stringify(diffData));
  8836. }
  8837. this.__next_tick_pending = true;
  8838. mpInstance.setData(diffData, function () {
  8839. this$1.__next_tick_pending = false;
  8840. flushCallbacks$1(this$1);
  8841. });
  8842. } else {
  8843. flushCallbacks$1(this);
  8844. }
  8845. }
  8846. };
  8847. /* */
  8848. function createEmptyRender() {
  8849. }
  8850. function mountComponent$1(
  8851. vm,
  8852. el,
  8853. hydrating
  8854. ) {
  8855. if (!vm.mpType) {//main.js 中的 new Vue
  8856. return vm
  8857. }
  8858. if (vm.mpType === 'app') {
  8859. vm.$options.render = createEmptyRender;
  8860. }
  8861. if (!vm.$options.render) {
  8862. vm.$options.render = createEmptyRender;
  8863. if (true) {
  8864. /* istanbul ignore if */
  8865. if ((vm.$options.template && vm.$options.template.charAt(0) !== '#') ||
  8866. vm.$options.el || el) {
  8867. warn(
  8868. 'You are using the runtime-only build of Vue where the template ' +
  8869. 'compiler is not available. Either pre-compile the templates into ' +
  8870. 'render functions, or use the compiler-included build.',
  8871. vm
  8872. );
  8873. } else {
  8874. warn(
  8875. 'Failed to mount component: template or render function not defined.',
  8876. vm
  8877. );
  8878. }
  8879. }
  8880. }
  8881. !vm._$fallback && callHook(vm, 'beforeMount');
  8882. var updateComponent = function () {
  8883. vm._update(vm._render(), hydrating);
  8884. };
  8885. // we set this to vm._watcher inside the watcher's constructor
  8886. // since the watcher's initial patch may call $forceUpdate (e.g. inside child
  8887. // component's mounted hook), which relies on vm._watcher being already defined
  8888. new Watcher(vm, updateComponent, noop, {
  8889. before: function before() {
  8890. if (vm._isMounted && !vm._isDestroyed) {
  8891. callHook(vm, 'beforeUpdate');
  8892. }
  8893. }
  8894. }, true /* isRenderWatcher */);
  8895. hydrating = false;
  8896. return vm
  8897. }
  8898. /* */
  8899. function renderClass (
  8900. staticClass,
  8901. dynamicClass
  8902. ) {
  8903. if (isDef(staticClass) || isDef(dynamicClass)) {
  8904. return concat(staticClass, stringifyClass(dynamicClass))
  8905. }
  8906. /* istanbul ignore next */
  8907. return ''
  8908. }
  8909. function concat (a, b) {
  8910. return a ? b ? (a + ' ' + b) : a : (b || '')
  8911. }
  8912. function stringifyClass (value) {
  8913. if (Array.isArray(value)) {
  8914. return stringifyArray(value)
  8915. }
  8916. if (isObject(value)) {
  8917. return stringifyObject(value)
  8918. }
  8919. if (typeof value === 'string') {
  8920. return value
  8921. }
  8922. /* istanbul ignore next */
  8923. return ''
  8924. }
  8925. function stringifyArray (value) {
  8926. var res = '';
  8927. var stringified;
  8928. for (var i = 0, l = value.length; i < l; i++) {
  8929. if (isDef(stringified = stringifyClass(value[i])) && stringified !== '') {
  8930. if (res) { res += ' '; }
  8931. res += stringified;
  8932. }
  8933. }
  8934. return res
  8935. }
  8936. function stringifyObject (value) {
  8937. var res = '';
  8938. for (var key in value) {
  8939. if (value[key]) {
  8940. if (res) { res += ' '; }
  8941. res += key;
  8942. }
  8943. }
  8944. return res
  8945. }
  8946. /* */
  8947. var parseStyleText = cached(function (cssText) {
  8948. var res = {};
  8949. var listDelimiter = /;(?![^(]*\))/g;
  8950. var propertyDelimiter = /:(.+)/;
  8951. cssText.split(listDelimiter).forEach(function (item) {
  8952. if (item) {
  8953. var tmp = item.split(propertyDelimiter);
  8954. tmp.length > 1 && (res[tmp[0].trim()] = tmp[1].trim());
  8955. }
  8956. });
  8957. return res
  8958. });
  8959. // normalize possible array / string values into Object
  8960. function normalizeStyleBinding (bindingStyle) {
  8961. if (Array.isArray(bindingStyle)) {
  8962. return toObject(bindingStyle)
  8963. }
  8964. if (typeof bindingStyle === 'string') {
  8965. return parseStyleText(bindingStyle)
  8966. }
  8967. return bindingStyle
  8968. }
  8969. /* */
  8970. var MP_METHODS = ['createSelectorQuery', 'createIntersectionObserver', 'selectAllComponents', 'selectComponent'];
  8971. function getTarget(obj, path) {
  8972. var parts = path.split('.');
  8973. var key = parts[0];
  8974. if (key.indexOf('__$n') === 0) { //number index
  8975. key = parseInt(key.replace('__$n', ''));
  8976. }
  8977. if (parts.length === 1) {
  8978. return obj[key]
  8979. }
  8980. return getTarget(obj[key], parts.slice(1).join('.'))
  8981. }
  8982. function internalMixin(Vue) {
  8983. Vue.config.errorHandler = function(err, vm, info) {
  8984. Vue.util.warn(("Error in " + info + ": \"" + (err.toString()) + "\""), vm);
  8985. console.error(err);
  8986. /* eslint-disable no-undef */
  8987. var app = typeof getApp === 'function' && getApp();
  8988. if (app && app.onError) {
  8989. app.onError(err);
  8990. }
  8991. };
  8992. var oldEmit = Vue.prototype.$emit;
  8993. Vue.prototype.$emit = function(event) {
  8994. if (this.$scope && event) {
  8995. var triggerEvent = this.$scope['_triggerEvent'] || this.$scope['triggerEvent'];
  8996. if (triggerEvent) {
  8997. try {
  8998. triggerEvent.call(this.$scope, event, {
  8999. __args__: toArray(arguments, 1)
  9000. });
  9001. } catch (error) {
  9002. }
  9003. }
  9004. }
  9005. return oldEmit.apply(this, arguments)
  9006. };
  9007. Vue.prototype.$nextTick = function(fn) {
  9008. return nextTick$1(this, fn)
  9009. };
  9010. MP_METHODS.forEach(function (method) {
  9011. Vue.prototype[method] = function(args) {
  9012. if (this.$scope && this.$scope[method]) {
  9013. return this.$scope[method](args)
  9014. }
  9015. // mp-alipay
  9016. if (typeof my === 'undefined') {
  9017. return
  9018. }
  9019. if (method === 'createSelectorQuery') {
  9020. /* eslint-disable no-undef */
  9021. return my.createSelectorQuery(args)
  9022. } else if (method === 'createIntersectionObserver') {
  9023. /* eslint-disable no-undef */
  9024. return my.createIntersectionObserver(args)
  9025. }
  9026. // TODO mp-alipay 暂不支持 selectAllComponents,selectComponent
  9027. };
  9028. });
  9029. Vue.prototype.__init_provide = initProvide;
  9030. Vue.prototype.__init_injections = initInjections;
  9031. Vue.prototype.__call_hook = function(hook, args) {
  9032. var vm = this;
  9033. // #7573 disable dep collection when invoking lifecycle hooks
  9034. pushTarget();
  9035. var handlers = vm.$options[hook];
  9036. var info = hook + " hook";
  9037. var ret;
  9038. if (handlers) {
  9039. for (var i = 0, j = handlers.length; i < j; i++) {
  9040. ret = invokeWithErrorHandling(handlers[i], vm, args ? [args] : null, vm, info);
  9041. }
  9042. }
  9043. if (vm._hasHookEvent) {
  9044. vm.$emit('hook:' + hook, args);
  9045. }
  9046. popTarget();
  9047. return ret
  9048. };
  9049. Vue.prototype.__set_model = function(target, key, value, modifiers) {
  9050. if (Array.isArray(modifiers)) {
  9051. if (modifiers.indexOf('trim') !== -1) {
  9052. value = value.trim();
  9053. }
  9054. if (modifiers.indexOf('number') !== -1) {
  9055. value = this._n(value);
  9056. }
  9057. }
  9058. if (!target) {
  9059. target = this;
  9060. }
  9061. // 解决动态属性添加
  9062. Vue.set(target, key, value);
  9063. };
  9064. Vue.prototype.__set_sync = function(target, key, value) {
  9065. if (!target) {
  9066. target = this;
  9067. }
  9068. // 解决动态属性添加
  9069. Vue.set(target, key, value);
  9070. };
  9071. Vue.prototype.__get_orig = function(item) {
  9072. if (isPlainObject(item)) {
  9073. return item['$orig'] || item
  9074. }
  9075. return item
  9076. };
  9077. Vue.prototype.__get_value = function(dataPath, target) {
  9078. return getTarget(target || this, dataPath)
  9079. };
  9080. Vue.prototype.__get_class = function(dynamicClass, staticClass) {
  9081. return renderClass(staticClass, dynamicClass)
  9082. };
  9083. Vue.prototype.__get_style = function(dynamicStyle, staticStyle) {
  9084. if (!dynamicStyle && !staticStyle) {
  9085. return ''
  9086. }
  9087. var dynamicStyleObj = normalizeStyleBinding(dynamicStyle);
  9088. var styleObj = staticStyle ? extend(staticStyle, dynamicStyleObj) : dynamicStyleObj;
  9089. return Object.keys(styleObj).map(function (name) { return ((hyphenate(name)) + ":" + (styleObj[name])); }).join(';')
  9090. };
  9091. Vue.prototype.__map = function(val, iteratee) {
  9092. //TODO 暂不考虑 string
  9093. var ret, i, l, keys, key;
  9094. if (Array.isArray(val)) {
  9095. ret = new Array(val.length);
  9096. for (i = 0, l = val.length; i < l; i++) {
  9097. ret[i] = iteratee(val[i], i);
  9098. }
  9099. return ret
  9100. } else if (isObject(val)) {
  9101. keys = Object.keys(val);
  9102. ret = Object.create(null);
  9103. for (i = 0, l = keys.length; i < l; i++) {
  9104. key = keys[i];
  9105. ret[key] = iteratee(val[key], key, i);
  9106. }
  9107. return ret
  9108. } else if (typeof val === 'number') {
  9109. ret = new Array(val);
  9110. for (i = 0, l = val; i < l; i++) {
  9111. // 第一个参数暂时仍和小程序一致
  9112. ret[i] = iteratee(i, i);
  9113. }
  9114. return ret
  9115. }
  9116. return []
  9117. };
  9118. }
  9119. /* */
  9120. var LIFECYCLE_HOOKS$1 = [
  9121. //App
  9122. 'onLaunch',
  9123. 'onShow',
  9124. 'onHide',
  9125. 'onUniNViewMessage',
  9126. 'onPageNotFound',
  9127. 'onThemeChange',
  9128. 'onError',
  9129. 'onUnhandledRejection',
  9130. //Page
  9131. 'onInit',
  9132. 'onLoad',
  9133. // 'onShow',
  9134. 'onReady',
  9135. // 'onHide',
  9136. 'onUnload',
  9137. 'onPullDownRefresh',
  9138. 'onReachBottom',
  9139. 'onTabItemTap',
  9140. 'onAddToFavorites',
  9141. 'onShareTimeline',
  9142. 'onShareAppMessage',
  9143. 'onResize',
  9144. 'onPageScroll',
  9145. 'onNavigationBarButtonTap',
  9146. 'onBackPress',
  9147. 'onNavigationBarSearchInputChanged',
  9148. 'onNavigationBarSearchInputConfirmed',
  9149. 'onNavigationBarSearchInputClicked',
  9150. 'onUploadDouyinVideo',
  9151. 'onNFCReadMessage',
  9152. //Component
  9153. // 'onReady', // 兼容旧版本,应该移除该事件
  9154. 'onPageShow',
  9155. 'onPageHide',
  9156. 'onPageResize'
  9157. ];
  9158. function lifecycleMixin$1(Vue) {
  9159. //fixed vue-class-component
  9160. var oldExtend = Vue.extend;
  9161. Vue.extend = function(extendOptions) {
  9162. extendOptions = extendOptions || {};
  9163. var methods = extendOptions.methods;
  9164. if (methods) {
  9165. Object.keys(methods).forEach(function (methodName) {
  9166. if (LIFECYCLE_HOOKS$1.indexOf(methodName)!==-1) {
  9167. extendOptions[methodName] = methods[methodName];
  9168. delete methods[methodName];
  9169. }
  9170. });
  9171. }
  9172. return oldExtend.call(this, extendOptions)
  9173. };
  9174. var strategies = Vue.config.optionMergeStrategies;
  9175. var mergeHook = strategies.created;
  9176. LIFECYCLE_HOOKS$1.forEach(function (hook) {
  9177. strategies[hook] = mergeHook;
  9178. });
  9179. Vue.prototype.__lifecycle_hooks__ = LIFECYCLE_HOOKS$1;
  9180. }
  9181. /* */
  9182. // install platform patch function
  9183. Vue.prototype.__patch__ = patch;
  9184. // public mount method
  9185. Vue.prototype.$mount = function(
  9186. el ,
  9187. hydrating
  9188. ) {
  9189. return mountComponent$1(this, el, hydrating)
  9190. };
  9191. lifecycleMixin$1(Vue);
  9192. internalMixin(Vue);
  9193. /* */
  9194. /* harmony default export */ __webpack_exports__["default"] = (Vue);
  9195. /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./../../../../../webpack/buildin/global.js */ 2)))
  9196. /***/ }),
  9197. /* 25 */
  9198. /*!*************************************************!*\
  9199. !*** /Users/z/D/hx-mini/hx-mini-uni/pages.json ***!
  9200. \*************************************************/
  9201. /*! no static exports found */
  9202. /***/ (function(module, exports) {
  9203. /***/ }),
  9204. /* 26 */,
  9205. /* 27 */,
  9206. /* 28 */,
  9207. /* 29 */,
  9208. /* 30 */,
  9209. /* 31 */
  9210. /*!**********************************************************************************************************!*\
  9211. !*** ./node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib/runtime/componentNormalizer.js ***!
  9212. \**********************************************************************************************************/
  9213. /*! exports provided: default */
  9214. /***/ (function(module, __webpack_exports__, __webpack_require__) {
  9215. "use strict";
  9216. __webpack_require__.r(__webpack_exports__);
  9217. /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return normalizeComponent; });
  9218. /* globals __VUE_SSR_CONTEXT__ */
  9219. // IMPORTANT: Do NOT use ES2015 features in this file (except for modules).
  9220. // This module is a runtime utility for cleaner component module output and will
  9221. // be included in the final webpack user bundle.
  9222. function normalizeComponent (
  9223. scriptExports,
  9224. render,
  9225. staticRenderFns,
  9226. functionalTemplate,
  9227. injectStyles,
  9228. scopeId,
  9229. moduleIdentifier, /* server only */
  9230. shadowMode, /* vue-cli only */
  9231. components, // fixed by xxxxxx auto components
  9232. renderjs // fixed by xxxxxx renderjs
  9233. ) {
  9234. // Vue.extend constructor export interop
  9235. var options = typeof scriptExports === 'function'
  9236. ? scriptExports.options
  9237. : scriptExports
  9238. // fixed by xxxxxx auto components
  9239. if (components) {
  9240. if (!options.components) {
  9241. options.components = {}
  9242. }
  9243. var hasOwn = Object.prototype.hasOwnProperty
  9244. for (var name in components) {
  9245. if (hasOwn.call(components, name) && !hasOwn.call(options.components, name)) {
  9246. options.components[name] = components[name]
  9247. }
  9248. }
  9249. }
  9250. // fixed by xxxxxx renderjs
  9251. if (renderjs) {
  9252. if(typeof renderjs.beforeCreate === 'function'){
  9253. renderjs.beforeCreate = [renderjs.beforeCreate]
  9254. }
  9255. (renderjs.beforeCreate || (renderjs.beforeCreate = [])).unshift(function() {
  9256. this[renderjs.__module] = this
  9257. });
  9258. (options.mixins || (options.mixins = [])).push(renderjs)
  9259. }
  9260. // render functions
  9261. if (render) {
  9262. options.render = render
  9263. options.staticRenderFns = staticRenderFns
  9264. options._compiled = true
  9265. }
  9266. // functional template
  9267. if (functionalTemplate) {
  9268. options.functional = true
  9269. }
  9270. // scopedId
  9271. if (scopeId) {
  9272. options._scopeId = 'data-v-' + scopeId
  9273. }
  9274. var hook
  9275. if (moduleIdentifier) { // server build
  9276. hook = function (context) {
  9277. // 2.3 injection
  9278. context =
  9279. context || // cached call
  9280. (this.$vnode && this.$vnode.ssrContext) || // stateful
  9281. (this.parent && this.parent.$vnode && this.parent.$vnode.ssrContext) // functional
  9282. // 2.2 with runInNewContext: true
  9283. if (!context && typeof __VUE_SSR_CONTEXT__ !== 'undefined') {
  9284. context = __VUE_SSR_CONTEXT__
  9285. }
  9286. // inject component styles
  9287. if (injectStyles) {
  9288. injectStyles.call(this, context)
  9289. }
  9290. // register component module identifier for async chunk inferrence
  9291. if (context && context._registeredComponents) {
  9292. context._registeredComponents.add(moduleIdentifier)
  9293. }
  9294. }
  9295. // used by ssr in case component is cached and beforeCreate
  9296. // never gets called
  9297. options._ssrRegister = hook
  9298. } else if (injectStyles) {
  9299. hook = shadowMode
  9300. ? function () { injectStyles.call(this, this.$root.$options.shadowRoot) }
  9301. : injectStyles
  9302. }
  9303. if (hook) {
  9304. if (options.functional) {
  9305. // for template-only hot-reload because in that case the render fn doesn't
  9306. // go through the normalizer
  9307. options._injectStyles = hook
  9308. // register for functioal component in vue file
  9309. var originalRender = options.render
  9310. options.render = function renderWithStyleInjection (h, context) {
  9311. hook.call(context)
  9312. return originalRender(h, context)
  9313. }
  9314. } else {
  9315. // inject component registration as beforeCreate hook
  9316. var existing = options.beforeCreate
  9317. options.beforeCreate = existing
  9318. ? [].concat(existing, hook)
  9319. : [hook]
  9320. }
  9321. }
  9322. return {
  9323. exports: scriptExports,
  9324. options: options
  9325. }
  9326. }
  9327. /***/ }),
  9328. /* 32 */
  9329. /*!********************************************************************!*\
  9330. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/index.js ***!
  9331. \********************************************************************/
  9332. /*! no static exports found */
  9333. /***/ (function(module, exports, __webpack_require__) {
  9334. "use strict";
  9335. /* WEBPACK VAR INJECTION */(function(uni) {
  9336. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  9337. Object.defineProperty(exports, "__esModule", {
  9338. value: true
  9339. });
  9340. exports.default = void 0;
  9341. var _defineProperty2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/defineProperty */ 10));
  9342. var _mixin = _interopRequireDefault(__webpack_require__(/*! ./libs/mixin/mixin.js */ 33));
  9343. var _mpMixin = _interopRequireDefault(__webpack_require__(/*! ./libs/mixin/mpMixin.js */ 34));
  9344. var _luchRequest = _interopRequireDefault(__webpack_require__(/*! ./libs/luch-request */ 35));
  9345. var _route = _interopRequireDefault(__webpack_require__(/*! ./libs/util/route.js */ 53));
  9346. var _colorGradient = _interopRequireDefault(__webpack_require__(/*! ./libs/function/colorGradient.js */ 57));
  9347. var _test = _interopRequireDefault(__webpack_require__(/*! ./libs/function/test.js */ 58));
  9348. var _debounce = _interopRequireDefault(__webpack_require__(/*! ./libs/function/debounce.js */ 59));
  9349. var _throttle = _interopRequireDefault(__webpack_require__(/*! ./libs/function/throttle.js */ 60));
  9350. var _index = _interopRequireDefault(__webpack_require__(/*! ./libs/function/index.js */ 61));
  9351. var _config = _interopRequireDefault(__webpack_require__(/*! ./libs/config/config.js */ 64));
  9352. var _props = _interopRequireDefault(__webpack_require__(/*! ./libs/config/props.js */ 65));
  9353. var _zIndex = _interopRequireDefault(__webpack_require__(/*! ./libs/config/zIndex.js */ 155));
  9354. var _color = _interopRequireDefault(__webpack_require__(/*! ./libs/config/color.js */ 113));
  9355. var _platform = _interopRequireDefault(__webpack_require__(/*! ./libs/function/platform */ 156));
  9356. function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
  9357. function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { (0, _defineProperty2.default)(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
  9358. // 看到此报错,是因为没有配置vue.config.js的【transpileDependencies】,详见:https://www.uviewui.com/components/npmSetting.html#_5-cli模式额外配置
  9359. var pleaseSetTranspileDependencies = {},
  9360. babelTest = pleaseSetTranspileDependencies === null || pleaseSetTranspileDependencies === void 0 ? void 0 : pleaseSetTranspileDependencies.test;
  9361. // 引入全局mixin
  9362. var $u = _objectSpread(_objectSpread({
  9363. route: _route.default,
  9364. date: _index.default.timeFormat,
  9365. // 另名date
  9366. colorGradient: _colorGradient.default.colorGradient,
  9367. hexToRgb: _colorGradient.default.hexToRgb,
  9368. rgbToHex: _colorGradient.default.rgbToHex,
  9369. colorToRgba: _colorGradient.default.colorToRgba,
  9370. test: _test.default,
  9371. type: ['primary', 'success', 'error', 'warning', 'info'],
  9372. http: new _luchRequest.default(),
  9373. config: _config.default,
  9374. // uView配置信息相关,比如版本号
  9375. zIndex: _zIndex.default,
  9376. debounce: _debounce.default,
  9377. throttle: _throttle.default,
  9378. mixin: _mixin.default,
  9379. mpMixin: _mpMixin.default,
  9380. props: _props.default
  9381. }, _index.default), {}, {
  9382. color: _color.default,
  9383. platform: _platform.default
  9384. });
  9385. // $u挂载到uni对象上
  9386. uni.$u = $u;
  9387. var install = function install(Vue) {
  9388. // 时间格式化,同时两个名称,date和timeFormat
  9389. Vue.filter('timeFormat', function (timestamp, format) {
  9390. return uni.$u.timeFormat(timestamp, format);
  9391. });
  9392. Vue.filter('date', function (timestamp, format) {
  9393. return uni.$u.timeFormat(timestamp, format);
  9394. });
  9395. // 将多久以前的方法,注入到全局过滤器
  9396. Vue.filter('timeFrom', function (timestamp, format) {
  9397. return uni.$u.timeFrom(timestamp, format);
  9398. });
  9399. // 同时挂载到uni和Vue.prototype中
  9400. // 只有vue,挂载到Vue.prototype才有意义,因为nvue中全局Vue.prototype和Vue.mixin是无效的
  9401. Vue.prototype.$u = $u;
  9402. Vue.mixin(_mixin.default);
  9403. };
  9404. var _default = {
  9405. install: install
  9406. };
  9407. exports.default = _default;
  9408. /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./node_modules/@dcloudio/uni-mp-toutiao/dist/index.js */ 1)["default"]))
  9409. /***/ }),
  9410. /* 33 */
  9411. /*!*******************************************************************************!*\
  9412. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/mixin/mixin.js ***!
  9413. \*******************************************************************************/
  9414. /*! no static exports found */
  9415. /***/ (function(module, exports, __webpack_require__) {
  9416. /* WEBPACK VAR INJECTION */(function(uni) {module.exports = {
  9417. // 定义每个组件都可能需要用到的外部样式以及类名
  9418. props: {
  9419. // 每个组件都有的父组件传递的样式,可以为字符串或者对象形式
  9420. customStyle: {
  9421. type: [Object, String],
  9422. default: function _default() {
  9423. return {};
  9424. }
  9425. },
  9426. customClass: {
  9427. type: String,
  9428. default: ''
  9429. },
  9430. // 跳转的页面路径
  9431. url: {
  9432. type: String,
  9433. default: ''
  9434. },
  9435. // 页面跳转的类型
  9436. linkType: {
  9437. type: String,
  9438. default: 'navigateTo'
  9439. }
  9440. },
  9441. data: function data() {
  9442. return {};
  9443. },
  9444. onLoad: function onLoad() {
  9445. // getRect挂载到$u上,因为这方法需要使用in(this),所以无法把它独立成一个单独的文件导出
  9446. this.$u.getRect = this.$uGetRect;
  9447. },
  9448. created: function created() {
  9449. // 组件当中,只有created声明周期,为了能在组件使用,故也在created中将方法挂载到$u
  9450. this.$u.getRect = this.$uGetRect;
  9451. },
  9452. computed: {
  9453. // 在2.x版本中,将会把$u挂载到uni对象下,导致在模板中无法使用uni.$u.xxx形式
  9454. // 所以这里通过computed计算属性将其附加到this.$u上,就可以在模板或者js中使用uni.$u.xxx
  9455. // 只在nvue环境通过此方式引入完整的$u,其他平台会出现性能问题,非nvue则按需引入(主要原因是props过大)
  9456. $u: function $u() {
  9457. // 在非nvue端,移除props,http,mixin等对象,避免在小程序setData时数据过大影响性能
  9458. return uni.$u.deepMerge(uni.$u, {
  9459. props: undefined,
  9460. http: undefined,
  9461. mixin: undefined
  9462. });
  9463. },
  9464. /**
  9465. * 生成bem规则类名
  9466. * 由于微信小程序,H5,nvue之间绑定class的差异,无法通过:class="[bem()]"的形式进行同用
  9467. * 故采用如下折中做法,最后返回的是数组(一般平台)或字符串(支付宝和字节跳动平台),类似['a', 'b', 'c']或'a b c'的形式
  9468. * @param {String} name 组件名称
  9469. * @param {Array} fixed 一直会存在的类名
  9470. * @param {Array} change 会根据变量值为true或者false而出现或者隐藏的类名
  9471. * @returns {Array|string}
  9472. */
  9473. bem: function bem() {
  9474. return function (name, fixed, change) {
  9475. var _this = this;
  9476. // 类名前缀
  9477. var prefix = "u-".concat(name, "--");
  9478. var classes = {};
  9479. if (fixed) {
  9480. fixed.map(function (item) {
  9481. // 这里的类名,会一直存在
  9482. classes[prefix + _this[item]] = true;
  9483. });
  9484. }
  9485. if (change) {
  9486. change.map(function (item) {
  9487. // 这里的类名,会根据this[item]的值为true或者false,而进行添加或者移除某一个类
  9488. _this[item] ? classes[prefix + item] = _this[item] : delete classes[prefix + item];
  9489. });
  9490. }
  9491. return Object.keys(classes)
  9492. // 支付宝,头条小程序无法动态绑定一个数组类名,否则解析出来的结果会带有",",而导致失效
  9493. .join(' ');
  9494. };
  9495. }
  9496. },
  9497. methods: {
  9498. // 跳转某一个页面
  9499. openPage: function openPage() {
  9500. var urlKey = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'url';
  9501. var url = this[urlKey];
  9502. if (url) {
  9503. // 执行类似uni.navigateTo的方法
  9504. uni[this.linkType]({
  9505. url: url
  9506. });
  9507. }
  9508. },
  9509. // 查询节点信息
  9510. // 目前此方法在支付宝小程序中无法获取组件跟接点的尺寸,为支付宝的bug(2020-07-21)
  9511. // 解决办法为在组件根部再套一个没有任何作用的view元素
  9512. $uGetRect: function $uGetRect(selector, all) {
  9513. var _this2 = this;
  9514. return new Promise(function (resolve) {
  9515. uni.createSelectorQuery().in(_this2)[all ? 'selectAll' : 'select'](selector).boundingClientRect(function (rect) {
  9516. if (all && Array.isArray(rect) && rect.length) {
  9517. resolve(rect);
  9518. }
  9519. if (!all && rect) {
  9520. resolve(rect);
  9521. }
  9522. }).exec();
  9523. });
  9524. },
  9525. getParentData: function getParentData() {
  9526. var _this3 = this;
  9527. var parentName = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';
  9528. // 避免在created中去定义parent变量
  9529. if (!this.parent) this.parent = {};
  9530. // 这里的本质原理是,通过获取父组件实例(也即类似u-radio的父组件u-radio-group的this)
  9531. // 将父组件this中对应的参数,赋值给本组件(u-radio的this)的parentData对象中对应的属性
  9532. // 之所以需要这么做,是因为所有端中,头条小程序不支持通过this.parent.xxx去监听父组件参数的变化
  9533. // 此处并不会自动更新子组件的数据,而是依赖父组件u-radio-group去监听data的变化,手动调用更新子组件的方法去重新获取
  9534. this.parent = uni.$u.$parent.call(this, parentName);
  9535. if (this.parent.children) {
  9536. // 如果父组件的children不存在本组件的实例,才将本实例添加到父组件的children中
  9537. this.parent.children.indexOf(this) === -1 && this.parent.children.push(this);
  9538. }
  9539. if (this.parent && this.parentData) {
  9540. // 历遍parentData中的属性,将parent中的同名属性赋值给parentData
  9541. Object.keys(this.parentData).map(function (key) {
  9542. _this3.parentData[key] = _this3.parent[key];
  9543. });
  9544. }
  9545. },
  9546. // 阻止事件冒泡
  9547. preventEvent: function preventEvent(e) {
  9548. e && typeof e.stopPropagation === 'function' && e.stopPropagation();
  9549. },
  9550. // 空操作
  9551. noop: function noop(e) {
  9552. this.preventEvent(e);
  9553. }
  9554. },
  9555. onReachBottom: function onReachBottom() {
  9556. uni.$emit('uOnReachBottom');
  9557. },
  9558. beforeDestroy: function beforeDestroy() {
  9559. var _this4 = this;
  9560. // 判断当前页面是否存在parent和chldren,一般在checkbox和checkbox-group父子联动的场景会有此情况
  9561. // 组件销毁时,移除子组件在父组件children数组中的实例,释放资源,避免数据混乱
  9562. if (this.parent && uni.$u.test.array(this.parent.children)) {
  9563. // 组件销毁时,移除父组件中的children数组中对应的实例
  9564. var childrenList = this.parent.children;
  9565. childrenList.map(function (child, index) {
  9566. // 如果相等,则移除
  9567. if (child === _this4) {
  9568. childrenList.splice(index, 1);
  9569. }
  9570. });
  9571. }
  9572. }
  9573. };
  9574. /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./node_modules/@dcloudio/uni-mp-toutiao/dist/index.js */ 1)["default"]))
  9575. /***/ }),
  9576. /* 34 */
  9577. /*!*********************************************************************************!*\
  9578. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/mixin/mpMixin.js ***!
  9579. \*********************************************************************************/
  9580. /*! no static exports found */
  9581. /***/ (function(module, exports, __webpack_require__) {
  9582. "use strict";
  9583. Object.defineProperty(exports, "__esModule", {
  9584. value: true
  9585. });
  9586. exports.default = void 0;
  9587. var _default = {};
  9588. exports.default = _default;
  9589. /***/ }),
  9590. /* 35 */
  9591. /*!**************************************************************************************!*\
  9592. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/luch-request/index.js ***!
  9593. \**************************************************************************************/
  9594. /*! no static exports found */
  9595. /***/ (function(module, exports, __webpack_require__) {
  9596. "use strict";
  9597. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  9598. Object.defineProperty(exports, "__esModule", {
  9599. value: true
  9600. });
  9601. exports.default = void 0;
  9602. var _Request = _interopRequireDefault(__webpack_require__(/*! ./core/Request */ 36));
  9603. var _default = _Request.default;
  9604. exports.default = _default;
  9605. /***/ }),
  9606. /* 36 */
  9607. /*!*********************************************************************************************!*\
  9608. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/luch-request/core/Request.js ***!
  9609. \*********************************************************************************************/
  9610. /*! no static exports found */
  9611. /***/ (function(module, exports, __webpack_require__) {
  9612. "use strict";
  9613. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  9614. Object.defineProperty(exports, "__esModule", {
  9615. value: true
  9616. });
  9617. exports.default = void 0;
  9618. var _defineProperty2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/defineProperty */ 10));
  9619. var _classCallCheck2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/classCallCheck */ 17));
  9620. var _createClass2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/createClass */ 18));
  9621. var _dispatchRequest = _interopRequireDefault(__webpack_require__(/*! ./dispatchRequest */ 37));
  9622. var _InterceptorManager = _interopRequireDefault(__webpack_require__(/*! ./InterceptorManager */ 45));
  9623. var _mergeConfig = _interopRequireDefault(__webpack_require__(/*! ./mergeConfig */ 46));
  9624. var _defaults = _interopRequireDefault(__webpack_require__(/*! ./defaults */ 47));
  9625. var _utils = __webpack_require__(/*! ../utils */ 40);
  9626. var _clone = _interopRequireDefault(__webpack_require__(/*! ../utils/clone */ 48));
  9627. function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
  9628. function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { (0, _defineProperty2.default)(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
  9629. var Request = /*#__PURE__*/function () {
  9630. /**
  9631. * @param {Object} arg - 全局配置
  9632. * @param {String} arg.baseURL - 全局根路径
  9633. * @param {Object} arg.header - 全局header
  9634. * @param {String} arg.method = [GET|POST|PUT|DELETE|CONNECT|HEAD|OPTIONS|TRACE] - 全局默认请求方式
  9635. * @param {String} arg.dataType = [json] - 全局默认的dataType
  9636. * @param {String} arg.responseType = [text|arraybuffer] - 全局默认的responseType。支付宝小程序不支持
  9637. * @param {Object} arg.custom - 全局默认的自定义参数
  9638. * @param {Number} arg.timeout - 全局默认的超时时间,单位 ms。默认60000。H5(HBuilderX 2.9.9+)、APP(HBuilderX 2.9.9+)、微信小程序(2.10.0)、支付宝小程序
  9639. * @param {Boolean} arg.sslVerify - 全局默认的是否验证 ssl 证书。默认true.仅App安卓端支持(HBuilderX 2.3.3+)
  9640. * @param {Boolean} arg.withCredentials - 全局默认的跨域请求时是否携带凭证(cookies)。默认false。仅H5支持(HBuilderX 2.6.15+)
  9641. * @param {Boolean} arg.firstIpv4 - 全DNS解析时优先使用ipv4。默认false。仅 App-Android 支持 (HBuilderX 2.8.0+)
  9642. * @param {Function(statusCode):Boolean} arg.validateStatus - 全局默认的自定义验证器。默认statusCode >= 200 && statusCode < 300
  9643. */
  9644. function Request() {
  9645. var arg = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
  9646. (0, _classCallCheck2.default)(this, Request);
  9647. if (!(0, _utils.isPlainObject)(arg)) {
  9648. arg = {};
  9649. console.warn('设置全局参数必须接收一个Object');
  9650. }
  9651. this.config = (0, _clone.default)(_objectSpread(_objectSpread({}, _defaults.default), arg));
  9652. this.interceptors = {
  9653. request: new _InterceptorManager.default(),
  9654. response: new _InterceptorManager.default()
  9655. };
  9656. }
  9657. /**
  9658. * @Function
  9659. * @param {Request~setConfigCallback} f - 设置全局默认配置
  9660. */
  9661. (0, _createClass2.default)(Request, [{
  9662. key: "setConfig",
  9663. value: function setConfig(f) {
  9664. this.config = f(this.config);
  9665. }
  9666. }, {
  9667. key: "middleware",
  9668. value: function middleware(config) {
  9669. config = (0, _mergeConfig.default)(this.config, config);
  9670. var chain = [_dispatchRequest.default, undefined];
  9671. var promise = Promise.resolve(config);
  9672. this.interceptors.request.forEach(function (interceptor) {
  9673. chain.unshift(interceptor.fulfilled, interceptor.rejected);
  9674. });
  9675. this.interceptors.response.forEach(function (interceptor) {
  9676. chain.push(interceptor.fulfilled, interceptor.rejected);
  9677. });
  9678. while (chain.length) {
  9679. promise = promise.then(chain.shift(), chain.shift());
  9680. }
  9681. return promise;
  9682. }
  9683. /**
  9684. * @Function
  9685. * @param {Object} config - 请求配置项
  9686. * @prop {String} options.url - 请求路径
  9687. * @prop {Object} options.data - 请求参数
  9688. * @prop {Object} [options.responseType = config.responseType] [text|arraybuffer] - 响应的数据类型
  9689. * @prop {Object} [options.dataType = config.dataType] - 如果设为 json,会尝试对返回的数据做一次 JSON.parse
  9690. * @prop {Object} [options.header = config.header] - 请求header
  9691. * @prop {Object} [options.method = config.method] - 请求方法
  9692. * @returns {Promise<unknown>}
  9693. */
  9694. }, {
  9695. key: "request",
  9696. value: function request() {
  9697. var config = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
  9698. return this.middleware(config);
  9699. }
  9700. }, {
  9701. key: "get",
  9702. value: function get(url) {
  9703. var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
  9704. return this.middleware(_objectSpread({
  9705. url: url,
  9706. method: 'GET'
  9707. }, options));
  9708. }
  9709. }, {
  9710. key: "post",
  9711. value: function post(url, data) {
  9712. var options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
  9713. return this.middleware(_objectSpread({
  9714. url: url,
  9715. data: data,
  9716. method: 'POST'
  9717. }, options));
  9718. }
  9719. }, {
  9720. key: "put",
  9721. value: function put(url, data) {
  9722. var options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
  9723. return this.middleware(_objectSpread({
  9724. url: url,
  9725. data: data,
  9726. method: 'PUT'
  9727. }, options));
  9728. }
  9729. }, {
  9730. key: "upload",
  9731. value: function upload(url) {
  9732. var config = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
  9733. config.url = url;
  9734. config.method = 'UPLOAD';
  9735. return this.middleware(config);
  9736. }
  9737. }, {
  9738. key: "download",
  9739. value: function download(url) {
  9740. var config = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
  9741. config.url = url;
  9742. config.method = 'DOWNLOAD';
  9743. return this.middleware(config);
  9744. }
  9745. }]);
  9746. return Request;
  9747. }();
  9748. /**
  9749. * setConfig回调
  9750. * @return {Object} - 返回操作后的config
  9751. * @callback Request~setConfigCallback
  9752. * @param {Object} config - 全局默认config
  9753. */
  9754. exports.default = Request;
  9755. /***/ }),
  9756. /* 37 */
  9757. /*!*****************************************************************************************************!*\
  9758. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/luch-request/core/dispatchRequest.js ***!
  9759. \*****************************************************************************************************/
  9760. /*! no static exports found */
  9761. /***/ (function(module, exports, __webpack_require__) {
  9762. "use strict";
  9763. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  9764. Object.defineProperty(exports, "__esModule", {
  9765. value: true
  9766. });
  9767. exports.default = void 0;
  9768. var _index = _interopRequireDefault(__webpack_require__(/*! ../adapters/index */ 38));
  9769. var _default = function _default(config) {
  9770. return (0, _index.default)(config);
  9771. };
  9772. exports.default = _default;
  9773. /***/ }),
  9774. /* 38 */
  9775. /*!***********************************************************************************************!*\
  9776. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/luch-request/adapters/index.js ***!
  9777. \***********************************************************************************************/
  9778. /*! no static exports found */
  9779. /***/ (function(module, exports, __webpack_require__) {
  9780. "use strict";
  9781. /* WEBPACK VAR INJECTION */(function(uni) {
  9782. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  9783. Object.defineProperty(exports, "__esModule", {
  9784. value: true
  9785. });
  9786. exports.default = void 0;
  9787. var _defineProperty2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/defineProperty */ 10));
  9788. var _buildURL = _interopRequireDefault(__webpack_require__(/*! ../helpers/buildURL */ 39));
  9789. var _buildFullPath = _interopRequireDefault(__webpack_require__(/*! ../core/buildFullPath */ 41));
  9790. var _settle = _interopRequireDefault(__webpack_require__(/*! ../core/settle */ 44));
  9791. var _utils = __webpack_require__(/*! ../utils */ 40);
  9792. function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
  9793. function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { (0, _defineProperty2.default)(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
  9794. /**
  9795. * 返回可选值存在的配置
  9796. * @param {Array} keys - 可选值数组
  9797. * @param {Object} config2 - 配置
  9798. * @return {{}} - 存在的配置项
  9799. */
  9800. var mergeKeys = function mergeKeys(keys, config2) {
  9801. var config = {};
  9802. keys.forEach(function (prop) {
  9803. if (!(0, _utils.isUndefined)(config2[prop])) {
  9804. config[prop] = config2[prop];
  9805. }
  9806. });
  9807. return config;
  9808. };
  9809. var _default = function _default(config) {
  9810. return new Promise(function (resolve, reject) {
  9811. var fullPath = (0, _buildURL.default)((0, _buildFullPath.default)(config.baseURL, config.url), config.params);
  9812. var _config = {
  9813. url: fullPath,
  9814. header: config.header,
  9815. complete: function complete(response) {
  9816. config.fullPath = fullPath;
  9817. response.config = config;
  9818. try {
  9819. // 对可能字符串不是json 的情况容错
  9820. if (typeof response.data === 'string') {
  9821. response.data = JSON.parse(response.data);
  9822. }
  9823. // eslint-disable-next-line no-empty
  9824. } catch (e) {}
  9825. (0, _settle.default)(resolve, reject, response);
  9826. }
  9827. };
  9828. var requestTask;
  9829. if (config.method === 'UPLOAD') {
  9830. delete _config.header['content-type'];
  9831. delete _config.header['Content-Type'];
  9832. var otherConfig = {
  9833. filePath: config.filePath,
  9834. name: config.name
  9835. };
  9836. var optionalKeys = ['formData'];
  9837. requestTask = uni.uploadFile(_objectSpread(_objectSpread(_objectSpread({}, _config), otherConfig), mergeKeys(optionalKeys, config)));
  9838. } else if (config.method === 'DOWNLOAD') {
  9839. requestTask = uni.downloadFile(_config);
  9840. } else {
  9841. var _optionalKeys = ['data', 'method', 'dataType', 'responseType'];
  9842. requestTask = uni.request(_objectSpread(_objectSpread({}, _config), mergeKeys(_optionalKeys, config)));
  9843. }
  9844. if (config.getTask) {
  9845. config.getTask(requestTask, config);
  9846. }
  9847. });
  9848. };
  9849. exports.default = _default;
  9850. /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./node_modules/@dcloudio/uni-mp-toutiao/dist/index.js */ 1)["default"]))
  9851. /***/ }),
  9852. /* 39 */
  9853. /*!*************************************************************************************************!*\
  9854. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/luch-request/helpers/buildURL.js ***!
  9855. \*************************************************************************************************/
  9856. /*! no static exports found */
  9857. /***/ (function(module, exports, __webpack_require__) {
  9858. "use strict";
  9859. var _typeof = __webpack_require__(/*! @babel/runtime/helpers/typeof */ 12);
  9860. Object.defineProperty(exports, "__esModule", {
  9861. value: true
  9862. });
  9863. exports.default = buildURL;
  9864. var utils = _interopRequireWildcard(__webpack_require__(/*! ../utils */ 40));
  9865. function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
  9866. function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
  9867. function encode(val) {
  9868. return encodeURIComponent(val).replace(/%40/gi, '@').replace(/%3A/gi, ':').replace(/%24/g, '$').replace(/%2C/gi, ',').replace(/%20/g, '+').replace(/%5B/gi, '[').replace(/%5D/gi, ']');
  9869. }
  9870. /**
  9871. * Build a URL by appending params to the end
  9872. *
  9873. * @param {string} url The base of the url (e.g., http://www.google.com)
  9874. * @param {object} [params] The params to be appended
  9875. * @returns {string} The formatted url
  9876. */
  9877. function buildURL(url, params) {
  9878. /* eslint no-param-reassign:0 */
  9879. if (!params) {
  9880. return url;
  9881. }
  9882. var serializedParams;
  9883. if (utils.isURLSearchParams(params)) {
  9884. serializedParams = params.toString();
  9885. } else {
  9886. var parts = [];
  9887. utils.forEach(params, function (val, key) {
  9888. if (val === null || typeof val === 'undefined') {
  9889. return;
  9890. }
  9891. if (utils.isArray(val)) {
  9892. key = "".concat(key, "[]");
  9893. } else {
  9894. val = [val];
  9895. }
  9896. utils.forEach(val, function (v) {
  9897. if (utils.isDate(v)) {
  9898. v = v.toISOString();
  9899. } else if (utils.isObject(v)) {
  9900. v = JSON.stringify(v);
  9901. }
  9902. parts.push("".concat(encode(key), "=").concat(encode(v)));
  9903. });
  9904. });
  9905. serializedParams = parts.join('&');
  9906. }
  9907. if (serializedParams) {
  9908. var hashmarkIndex = url.indexOf('#');
  9909. if (hashmarkIndex !== -1) {
  9910. url = url.slice(0, hashmarkIndex);
  9911. }
  9912. url += (url.indexOf('?') === -1 ? '?' : '&') + serializedParams;
  9913. }
  9914. return url;
  9915. }
  9916. /***/ }),
  9917. /* 40 */
  9918. /*!**************************************************************************************!*\
  9919. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/luch-request/utils.js ***!
  9920. \**************************************************************************************/
  9921. /*! no static exports found */
  9922. /***/ (function(module, exports, __webpack_require__) {
  9923. "use strict";
  9924. // utils is a library of generic helper functions non-specific to axios
  9925. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  9926. Object.defineProperty(exports, "__esModule", {
  9927. value: true
  9928. });
  9929. exports.deepMerge = deepMerge;
  9930. exports.forEach = forEach;
  9931. exports.isArray = isArray;
  9932. exports.isBoolean = isBoolean;
  9933. exports.isDate = isDate;
  9934. exports.isObject = isObject;
  9935. exports.isPlainObject = isPlainObject;
  9936. exports.isURLSearchParams = isURLSearchParams;
  9937. exports.isUndefined = isUndefined;
  9938. var _typeof2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/typeof */ 12));
  9939. var toString = Object.prototype.toString;
  9940. /**
  9941. * Determine if a value is an Array
  9942. *
  9943. * @param {Object} val The value to test
  9944. * @returns {boolean} True if value is an Array, otherwise false
  9945. */
  9946. function isArray(val) {
  9947. return toString.call(val) === '[object Array]';
  9948. }
  9949. /**
  9950. * Determine if a value is an Object
  9951. *
  9952. * @param {Object} val The value to test
  9953. * @returns {boolean} True if value is an Object, otherwise false
  9954. */
  9955. function isObject(val) {
  9956. return val !== null && (0, _typeof2.default)(val) === 'object';
  9957. }
  9958. /**
  9959. * Determine if a value is a Date
  9960. *
  9961. * @param {Object} val The value to test
  9962. * @returns {boolean} True if value is a Date, otherwise false
  9963. */
  9964. function isDate(val) {
  9965. return toString.call(val) === '[object Date]';
  9966. }
  9967. /**
  9968. * Determine if a value is a URLSearchParams object
  9969. *
  9970. * @param {Object} val The value to test
  9971. * @returns {boolean} True if value is a URLSearchParams object, otherwise false
  9972. */
  9973. function isURLSearchParams(val) {
  9974. return typeof URLSearchParams !== 'undefined' && val instanceof URLSearchParams;
  9975. }
  9976. /**
  9977. * Iterate over an Array or an Object invoking a function for each item.
  9978. *
  9979. * If `obj` is an Array callback will be called passing
  9980. * the value, index, and complete array for each item.
  9981. *
  9982. * If 'obj' is an Object callback will be called passing
  9983. * the value, key, and complete object for each property.
  9984. *
  9985. * @param {Object|Array} obj The object to iterate
  9986. * @param {Function} fn The callback to invoke for each item
  9987. */
  9988. function forEach(obj, fn) {
  9989. // Don't bother if no value provided
  9990. if (obj === null || typeof obj === 'undefined') {
  9991. return;
  9992. }
  9993. // Force an array if not already something iterable
  9994. if ((0, _typeof2.default)(obj) !== 'object') {
  9995. /* eslint no-param-reassign:0 */
  9996. obj = [obj];
  9997. }
  9998. if (isArray(obj)) {
  9999. // Iterate over array values
  10000. for (var i = 0, l = obj.length; i < l; i++) {
  10001. fn.call(null, obj[i], i, obj);
  10002. }
  10003. } else {
  10004. // Iterate over object keys
  10005. for (var key in obj) {
  10006. if (Object.prototype.hasOwnProperty.call(obj, key)) {
  10007. fn.call(null, obj[key], key, obj);
  10008. }
  10009. }
  10010. }
  10011. }
  10012. /**
  10013. * 是否为boolean 值
  10014. * @param val
  10015. * @returns {boolean}
  10016. */
  10017. function isBoolean(val) {
  10018. return typeof val === 'boolean';
  10019. }
  10020. /**
  10021. * 是否为真正的对象{} new Object
  10022. * @param {any} obj - 检测的对象
  10023. * @returns {boolean}
  10024. */
  10025. function isPlainObject(obj) {
  10026. return Object.prototype.toString.call(obj) === '[object Object]';
  10027. }
  10028. /**
  10029. * Function equal to merge with the difference being that no reference
  10030. * to original objects is kept.
  10031. *
  10032. * @see merge
  10033. * @param {Object} obj1 Object to merge
  10034. * @returns {Object} Result of all merge properties
  10035. */
  10036. function deepMerge( /* obj1, obj2, obj3, ... */
  10037. ) {
  10038. var result = {};
  10039. function assignValue(val, key) {
  10040. if ((0, _typeof2.default)(result[key]) === 'object' && (0, _typeof2.default)(val) === 'object') {
  10041. result[key] = deepMerge(result[key], val);
  10042. } else if ((0, _typeof2.default)(val) === 'object') {
  10043. result[key] = deepMerge({}, val);
  10044. } else {
  10045. result[key] = val;
  10046. }
  10047. }
  10048. for (var i = 0, l = arguments.length; i < l; i++) {
  10049. forEach(arguments[i], assignValue);
  10050. }
  10051. return result;
  10052. }
  10053. function isUndefined(val) {
  10054. return typeof val === 'undefined';
  10055. }
  10056. /***/ }),
  10057. /* 41 */
  10058. /*!***************************************************************************************************!*\
  10059. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/luch-request/core/buildFullPath.js ***!
  10060. \***************************************************************************************************/
  10061. /*! no static exports found */
  10062. /***/ (function(module, exports, __webpack_require__) {
  10063. "use strict";
  10064. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  10065. Object.defineProperty(exports, "__esModule", {
  10066. value: true
  10067. });
  10068. exports.default = buildFullPath;
  10069. var _isAbsoluteURL = _interopRequireDefault(__webpack_require__(/*! ../helpers/isAbsoluteURL */ 42));
  10070. var _combineURLs = _interopRequireDefault(__webpack_require__(/*! ../helpers/combineURLs */ 43));
  10071. /**
  10072. * Creates a new URL by combining the baseURL with the requestedURL,
  10073. * only when the requestedURL is not already an absolute URL.
  10074. * If the requestURL is absolute, this function returns the requestedURL untouched.
  10075. *
  10076. * @param {string} baseURL The base URL
  10077. * @param {string} requestedURL Absolute or relative URL to combine
  10078. * @returns {string} The combined full path
  10079. */
  10080. function buildFullPath(baseURL, requestedURL) {
  10081. if (baseURL && !(0, _isAbsoluteURL.default)(requestedURL)) {
  10082. return (0, _combineURLs.default)(baseURL, requestedURL);
  10083. }
  10084. return requestedURL;
  10085. }
  10086. /***/ }),
  10087. /* 42 */
  10088. /*!******************************************************************************************************!*\
  10089. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/luch-request/helpers/isAbsoluteURL.js ***!
  10090. \******************************************************************************************************/
  10091. /*! no static exports found */
  10092. /***/ (function(module, exports, __webpack_require__) {
  10093. "use strict";
  10094. /**
  10095. * Determines whether the specified URL is absolute
  10096. *
  10097. * @param {string} url The URL to test
  10098. * @returns {boolean} True if the specified URL is absolute, otherwise false
  10099. */
  10100. Object.defineProperty(exports, "__esModule", {
  10101. value: true
  10102. });
  10103. exports.default = isAbsoluteURL;
  10104. function isAbsoluteURL(url) {
  10105. // A URL is considered absolute if it begins with "<scheme>://" or "//" (protocol-relative URL).
  10106. // RFC 3986 defines scheme name as a sequence of characters beginning with a letter and followed
  10107. // by any combination of letters, digits, plus, period, or hyphen.
  10108. return /^([a-z][a-z\d+\-.]*:)?\/\//i.test(url);
  10109. }
  10110. /***/ }),
  10111. /* 43 */
  10112. /*!****************************************************************************************************!*\
  10113. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/luch-request/helpers/combineURLs.js ***!
  10114. \****************************************************************************************************/
  10115. /*! no static exports found */
  10116. /***/ (function(module, exports, __webpack_require__) {
  10117. "use strict";
  10118. /**
  10119. * Creates a new URL by combining the specified URLs
  10120. *
  10121. * @param {string} baseURL The base URL
  10122. * @param {string} relativeURL The relative URL
  10123. * @returns {string} The combined URL
  10124. */
  10125. Object.defineProperty(exports, "__esModule", {
  10126. value: true
  10127. });
  10128. exports.default = combineURLs;
  10129. function combineURLs(baseURL, relativeURL) {
  10130. return relativeURL ? "".concat(baseURL.replace(/\/+$/, ''), "/").concat(relativeURL.replace(/^\/+/, '')) : baseURL;
  10131. }
  10132. /***/ }),
  10133. /* 44 */
  10134. /*!********************************************************************************************!*\
  10135. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/luch-request/core/settle.js ***!
  10136. \********************************************************************************************/
  10137. /*! no static exports found */
  10138. /***/ (function(module, exports, __webpack_require__) {
  10139. "use strict";
  10140. Object.defineProperty(exports, "__esModule", {
  10141. value: true
  10142. });
  10143. exports.default = settle;
  10144. /**
  10145. * Resolve or reject a Promise based on response status.
  10146. *
  10147. * @param {Function} resolve A function that resolves the promise.
  10148. * @param {Function} reject A function that rejects the promise.
  10149. * @param {object} response The response.
  10150. */
  10151. function settle(resolve, reject, response) {
  10152. var validateStatus = response.config.validateStatus;
  10153. var status = response.statusCode;
  10154. if (status && (!validateStatus || validateStatus(status))) {
  10155. resolve(response);
  10156. } else {
  10157. reject(response);
  10158. }
  10159. }
  10160. /***/ }),
  10161. /* 45 */
  10162. /*!********************************************************************************************************!*\
  10163. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/luch-request/core/InterceptorManager.js ***!
  10164. \********************************************************************************************************/
  10165. /*! no static exports found */
  10166. /***/ (function(module, exports, __webpack_require__) {
  10167. "use strict";
  10168. Object.defineProperty(exports, "__esModule", {
  10169. value: true
  10170. });
  10171. exports.default = void 0;
  10172. function InterceptorManager() {
  10173. this.handlers = [];
  10174. }
  10175. /**
  10176. * Add a new interceptor to the stack
  10177. *
  10178. * @param {Function} fulfilled The function to handle `then` for a `Promise`
  10179. * @param {Function} rejected The function to handle `reject` for a `Promise`
  10180. *
  10181. * @return {Number} An ID used to remove interceptor later
  10182. */
  10183. InterceptorManager.prototype.use = function use(fulfilled, rejected) {
  10184. this.handlers.push({
  10185. fulfilled: fulfilled,
  10186. rejected: rejected
  10187. });
  10188. return this.handlers.length - 1;
  10189. };
  10190. /**
  10191. * Remove an interceptor from the stack
  10192. *
  10193. * @param {Number} id The ID that was returned by `use`
  10194. */
  10195. InterceptorManager.prototype.eject = function eject(id) {
  10196. if (this.handlers[id]) {
  10197. this.handlers[id] = null;
  10198. }
  10199. };
  10200. /**
  10201. * Iterate over all the registered interceptors
  10202. *
  10203. * This method is particularly useful for skipping over any
  10204. * interceptors that may have become `null` calling `eject`.
  10205. *
  10206. * @param {Function} fn The function to call for each interceptor
  10207. */
  10208. InterceptorManager.prototype.forEach = function forEach(fn) {
  10209. this.handlers.forEach(function (h) {
  10210. if (h !== null) {
  10211. fn(h);
  10212. }
  10213. });
  10214. };
  10215. var _default = InterceptorManager;
  10216. exports.default = _default;
  10217. /***/ }),
  10218. /* 46 */
  10219. /*!*************************************************************************************************!*\
  10220. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/luch-request/core/mergeConfig.js ***!
  10221. \*************************************************************************************************/
  10222. /*! no static exports found */
  10223. /***/ (function(module, exports, __webpack_require__) {
  10224. "use strict";
  10225. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  10226. Object.defineProperty(exports, "__esModule", {
  10227. value: true
  10228. });
  10229. exports.default = void 0;
  10230. var _defineProperty2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/defineProperty */ 10));
  10231. var _utils = __webpack_require__(/*! ../utils */ 40);
  10232. function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
  10233. function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { (0, _defineProperty2.default)(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
  10234. /**
  10235. * 合并局部配置优先的配置,如果局部有该配置项则用局部,如果全局有该配置项则用全局
  10236. * @param {Array} keys - 配置项
  10237. * @param {Object} globalsConfig - 当前的全局配置
  10238. * @param {Object} config2 - 局部配置
  10239. * @return {{}}
  10240. */
  10241. var mergeKeys = function mergeKeys(keys, globalsConfig, config2) {
  10242. var config = {};
  10243. keys.forEach(function (prop) {
  10244. if (!(0, _utils.isUndefined)(config2[prop])) {
  10245. config[prop] = config2[prop];
  10246. } else if (!(0, _utils.isUndefined)(globalsConfig[prop])) {
  10247. config[prop] = globalsConfig[prop];
  10248. }
  10249. });
  10250. return config;
  10251. };
  10252. /**
  10253. *
  10254. * @param globalsConfig - 当前实例的全局配置
  10255. * @param config2 - 当前的局部配置
  10256. * @return - 合并后的配置
  10257. */
  10258. var _default = function _default(globalsConfig) {
  10259. var config2 = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
  10260. var method = config2.method || globalsConfig.method || 'GET';
  10261. var config = {
  10262. baseURL: globalsConfig.baseURL || '',
  10263. method: method,
  10264. url: config2.url || '',
  10265. params: config2.params || {},
  10266. custom: _objectSpread(_objectSpread({}, globalsConfig.custom || {}), config2.custom || {}),
  10267. header: (0, _utils.deepMerge)(globalsConfig.header || {}, config2.header || {})
  10268. };
  10269. var defaultToConfig2Keys = ['getTask', 'validateStatus'];
  10270. config = _objectSpread(_objectSpread({}, config), mergeKeys(defaultToConfig2Keys, globalsConfig, config2));
  10271. // eslint-disable-next-line no-empty
  10272. if (method === 'DOWNLOAD') {} else if (method === 'UPLOAD') {
  10273. delete config.header['content-type'];
  10274. delete config.header['Content-Type'];
  10275. var uploadKeys = ['filePath', 'name', 'formData'];
  10276. uploadKeys.forEach(function (prop) {
  10277. if (!(0, _utils.isUndefined)(config2[prop])) {
  10278. config[prop] = config2[prop];
  10279. }
  10280. });
  10281. } else {
  10282. var defaultsKeys = ['data', 'dataType', 'responseType'];
  10283. config = _objectSpread(_objectSpread({}, config), mergeKeys(defaultsKeys, globalsConfig, config2));
  10284. }
  10285. return config;
  10286. };
  10287. exports.default = _default;
  10288. /***/ }),
  10289. /* 47 */
  10290. /*!**********************************************************************************************!*\
  10291. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/luch-request/core/defaults.js ***!
  10292. \**********************************************************************************************/
  10293. /*! no static exports found */
  10294. /***/ (function(module, exports, __webpack_require__) {
  10295. "use strict";
  10296. Object.defineProperty(exports, "__esModule", {
  10297. value: true
  10298. });
  10299. exports.default = void 0;
  10300. /**
  10301. * 默认的全局配置
  10302. */
  10303. var _default = {
  10304. baseURL: '',
  10305. header: {},
  10306. method: 'GET',
  10307. dataType: 'json',
  10308. responseType: 'text',
  10309. custom: {},
  10310. validateStatus: function validateStatus(status) {
  10311. return status >= 200 && status < 300;
  10312. }
  10313. };
  10314. exports.default = _default;
  10315. /***/ }),
  10316. /* 48 */
  10317. /*!********************************************************************************************!*\
  10318. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/luch-request/utils/clone.js ***!
  10319. \********************************************************************************************/
  10320. /*! no static exports found */
  10321. /***/ (function(module, exports, __webpack_require__) {
  10322. "use strict";
  10323. /* WEBPACK VAR INJECTION */(function(Buffer) {
  10324. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  10325. Object.defineProperty(exports, "__esModule", {
  10326. value: true
  10327. });
  10328. exports.default = void 0;
  10329. var _typeof2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/typeof */ 12));
  10330. /* eslint-disable */
  10331. var clone = function () {
  10332. 'use strict';
  10333. function _instanceof(obj, type) {
  10334. return type != null && obj instanceof type;
  10335. }
  10336. var nativeMap;
  10337. try {
  10338. nativeMap = Map;
  10339. } catch (_) {
  10340. // maybe a reference error because no `Map`. Give it a dummy value that no
  10341. // value will ever be an instanceof.
  10342. nativeMap = function nativeMap() {};
  10343. }
  10344. var nativeSet;
  10345. try {
  10346. nativeSet = Set;
  10347. } catch (_) {
  10348. nativeSet = function nativeSet() {};
  10349. }
  10350. var nativePromise;
  10351. try {
  10352. nativePromise = Promise;
  10353. } catch (_) {
  10354. nativePromise = function nativePromise() {};
  10355. }
  10356. /**
  10357. * Clones (copies) an Object using deep copying.
  10358. *
  10359. * This function supports circular references by default, but if you are certain
  10360. * there are no circular references in your object, you can save some CPU time
  10361. * by calling clone(obj, false).
  10362. *
  10363. * Caution: if `circular` is false and `parent` contains circular references,
  10364. * your program may enter an infinite loop and crash.
  10365. *
  10366. * @param `parent` - the object to be cloned
  10367. * @param `circular` - set to true if the object to be cloned may contain
  10368. * circular references. (optional - true by default)
  10369. * @param `depth` - set to a number if the object is only to be cloned to
  10370. * a particular depth. (optional - defaults to Infinity)
  10371. * @param `prototype` - sets the prototype to be used when cloning an object.
  10372. * (optional - defaults to parent prototype).
  10373. * @param `includeNonEnumerable` - set to true if the non-enumerable properties
  10374. * should be cloned as well. Non-enumerable properties on the prototype
  10375. * chain will be ignored. (optional - false by default)
  10376. */
  10377. function clone(parent, circular, depth, prototype, includeNonEnumerable) {
  10378. if ((0, _typeof2.default)(circular) === 'object') {
  10379. depth = circular.depth;
  10380. prototype = circular.prototype;
  10381. includeNonEnumerable = circular.includeNonEnumerable;
  10382. circular = circular.circular;
  10383. }
  10384. // maintain two arrays for circular references, where corresponding parents
  10385. // and children have the same index
  10386. var allParents = [];
  10387. var allChildren = [];
  10388. var useBuffer = typeof Buffer != 'undefined';
  10389. if (typeof circular == 'undefined') circular = true;
  10390. if (typeof depth == 'undefined') depth = Infinity;
  10391. // recurse this function so we don't reset allParents and allChildren
  10392. function _clone(parent, depth) {
  10393. // cloning null always returns null
  10394. if (parent === null) return null;
  10395. if (depth === 0) return parent;
  10396. var child;
  10397. var proto;
  10398. if ((0, _typeof2.default)(parent) != 'object') {
  10399. return parent;
  10400. }
  10401. if (_instanceof(parent, nativeMap)) {
  10402. child = new nativeMap();
  10403. } else if (_instanceof(parent, nativeSet)) {
  10404. child = new nativeSet();
  10405. } else if (_instanceof(parent, nativePromise)) {
  10406. child = new nativePromise(function (resolve, reject) {
  10407. parent.then(function (value) {
  10408. resolve(_clone(value, depth - 1));
  10409. }, function (err) {
  10410. reject(_clone(err, depth - 1));
  10411. });
  10412. });
  10413. } else if (clone.__isArray(parent)) {
  10414. child = [];
  10415. } else if (clone.__isRegExp(parent)) {
  10416. child = new RegExp(parent.source, __getRegExpFlags(parent));
  10417. if (parent.lastIndex) child.lastIndex = parent.lastIndex;
  10418. } else if (clone.__isDate(parent)) {
  10419. child = new Date(parent.getTime());
  10420. } else if (useBuffer && Buffer.isBuffer(parent)) {
  10421. if (Buffer.from) {
  10422. // Node.js >= 5.10.0
  10423. child = Buffer.from(parent);
  10424. } else {
  10425. // Older Node.js versions
  10426. child = new Buffer(parent.length);
  10427. parent.copy(child);
  10428. }
  10429. return child;
  10430. } else if (_instanceof(parent, Error)) {
  10431. child = Object.create(parent);
  10432. } else {
  10433. if (typeof prototype == 'undefined') {
  10434. proto = Object.getPrototypeOf(parent);
  10435. child = Object.create(proto);
  10436. } else {
  10437. child = Object.create(prototype);
  10438. proto = prototype;
  10439. }
  10440. }
  10441. if (circular) {
  10442. var index = allParents.indexOf(parent);
  10443. if (index != -1) {
  10444. return allChildren[index];
  10445. }
  10446. allParents.push(parent);
  10447. allChildren.push(child);
  10448. }
  10449. if (_instanceof(parent, nativeMap)) {
  10450. parent.forEach(function (value, key) {
  10451. var keyChild = _clone(key, depth - 1);
  10452. var valueChild = _clone(value, depth - 1);
  10453. child.set(keyChild, valueChild);
  10454. });
  10455. }
  10456. if (_instanceof(parent, nativeSet)) {
  10457. parent.forEach(function (value) {
  10458. var entryChild = _clone(value, depth - 1);
  10459. child.add(entryChild);
  10460. });
  10461. }
  10462. for (var i in parent) {
  10463. var attrs = Object.getOwnPropertyDescriptor(parent, i);
  10464. if (attrs) {
  10465. child[i] = _clone(parent[i], depth - 1);
  10466. }
  10467. try {
  10468. var objProperty = Object.getOwnPropertyDescriptor(parent, i);
  10469. if (objProperty.set === 'undefined') {
  10470. // no setter defined. Skip cloning this property
  10471. continue;
  10472. }
  10473. child[i] = _clone(parent[i], depth - 1);
  10474. } catch (e) {
  10475. if (e instanceof TypeError) {
  10476. // when in strict mode, TypeError will be thrown if child[i] property only has a getter
  10477. // we can't do anything about this, other than inform the user that this property cannot be set.
  10478. continue;
  10479. } else if (e instanceof ReferenceError) {
  10480. //this may happen in non strict mode
  10481. continue;
  10482. }
  10483. }
  10484. }
  10485. if (Object.getOwnPropertySymbols) {
  10486. var symbols = Object.getOwnPropertySymbols(parent);
  10487. for (var i = 0; i < symbols.length; i++) {
  10488. // Don't need to worry about cloning a symbol because it is a primitive,
  10489. // like a number or string.
  10490. var symbol = symbols[i];
  10491. var descriptor = Object.getOwnPropertyDescriptor(parent, symbol);
  10492. if (descriptor && !descriptor.enumerable && !includeNonEnumerable) {
  10493. continue;
  10494. }
  10495. child[symbol] = _clone(parent[symbol], depth - 1);
  10496. Object.defineProperty(child, symbol, descriptor);
  10497. }
  10498. }
  10499. if (includeNonEnumerable) {
  10500. var allPropertyNames = Object.getOwnPropertyNames(parent);
  10501. for (var i = 0; i < allPropertyNames.length; i++) {
  10502. var propertyName = allPropertyNames[i];
  10503. var descriptor = Object.getOwnPropertyDescriptor(parent, propertyName);
  10504. if (descriptor && descriptor.enumerable) {
  10505. continue;
  10506. }
  10507. child[propertyName] = _clone(parent[propertyName], depth - 1);
  10508. Object.defineProperty(child, propertyName, descriptor);
  10509. }
  10510. }
  10511. return child;
  10512. }
  10513. return _clone(parent, depth);
  10514. }
  10515. /**
  10516. * Simple flat clone using prototype, accepts only objects, usefull for property
  10517. * override on FLAT configuration object (no nested props).
  10518. *
  10519. * USE WITH CAUTION! This may not behave as you wish if you do not know how this
  10520. * works.
  10521. */
  10522. clone.clonePrototype = function clonePrototype(parent) {
  10523. if (parent === null) return null;
  10524. var c = function c() {};
  10525. c.prototype = parent;
  10526. return new c();
  10527. };
  10528. // private utility functions
  10529. function __objToStr(o) {
  10530. return Object.prototype.toString.call(o);
  10531. }
  10532. clone.__objToStr = __objToStr;
  10533. function __isDate(o) {
  10534. return (0, _typeof2.default)(o) === 'object' && __objToStr(o) === '[object Date]';
  10535. }
  10536. clone.__isDate = __isDate;
  10537. function __isArray(o) {
  10538. return (0, _typeof2.default)(o) === 'object' && __objToStr(o) === '[object Array]';
  10539. }
  10540. clone.__isArray = __isArray;
  10541. function __isRegExp(o) {
  10542. return (0, _typeof2.default)(o) === 'object' && __objToStr(o) === '[object RegExp]';
  10543. }
  10544. clone.__isRegExp = __isRegExp;
  10545. function __getRegExpFlags(re) {
  10546. var flags = '';
  10547. if (re.global) flags += 'g';
  10548. if (re.ignoreCase) flags += 'i';
  10549. if (re.multiline) flags += 'm';
  10550. return flags;
  10551. }
  10552. clone.__getRegExpFlags = __getRegExpFlags;
  10553. return clone;
  10554. }();
  10555. var _default = clone;
  10556. exports.default = _default;
  10557. /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./../../../../../../../../../../Applications/HBuilderX.app/Contents/HBuilderX/plugins/uniapp-cli/node_modules/buffer/index.js */ 49).Buffer))
  10558. /***/ }),
  10559. /* 49 */
  10560. /*!**************************************!*\
  10561. !*** ./node_modules/buffer/index.js ***!
  10562. \**************************************/
  10563. /*! no static exports found */
  10564. /***/ (function(module, exports, __webpack_require__) {
  10565. "use strict";
  10566. /* WEBPACK VAR INJECTION */(function(global) {/*!
  10567. * The buffer module from node.js, for the browser.
  10568. *
  10569. * @author Feross Aboukhadijeh <http://feross.org>
  10570. * @license MIT
  10571. */
  10572. /* eslint-disable no-proto */
  10573. var base64 = __webpack_require__(/*! base64-js */ 50)
  10574. var ieee754 = __webpack_require__(/*! ieee754 */ 51)
  10575. var isArray = __webpack_require__(/*! isarray */ 52)
  10576. exports.Buffer = Buffer
  10577. exports.SlowBuffer = SlowBuffer
  10578. exports.INSPECT_MAX_BYTES = 50
  10579. /**
  10580. * If `Buffer.TYPED_ARRAY_SUPPORT`:
  10581. * === true Use Uint8Array implementation (fastest)
  10582. * === false Use Object implementation (most compatible, even IE6)
  10583. *
  10584. * Browsers that support typed arrays are IE 10+, Firefox 4+, Chrome 7+, Safari 5.1+,
  10585. * Opera 11.6+, iOS 4.2+.
  10586. *
  10587. * Due to various browser bugs, sometimes the Object implementation will be used even
  10588. * when the browser supports typed arrays.
  10589. *
  10590. * Note:
  10591. *
  10592. * - Firefox 4-29 lacks support for adding new properties to `Uint8Array` instances,
  10593. * See: https://bugzilla.mozilla.org/show_bug.cgi?id=695438.
  10594. *
  10595. * - Chrome 9-10 is missing the `TypedArray.prototype.subarray` function.
  10596. *
  10597. * - IE10 has a broken `TypedArray.prototype.subarray` function which returns arrays of
  10598. * incorrect length in some situations.
  10599. * We detect these buggy browsers and set `Buffer.TYPED_ARRAY_SUPPORT` to `false` so they
  10600. * get the Object implementation, which is slower but behaves correctly.
  10601. */
  10602. Buffer.TYPED_ARRAY_SUPPORT = global.TYPED_ARRAY_SUPPORT !== undefined
  10603. ? global.TYPED_ARRAY_SUPPORT
  10604. : typedArraySupport()
  10605. /*
  10606. * Export kMaxLength after typed array support is determined.
  10607. */
  10608. exports.kMaxLength = kMaxLength()
  10609. function typedArraySupport () {
  10610. try {
  10611. var arr = new Uint8Array(1)
  10612. arr.__proto__ = {__proto__: Uint8Array.prototype, foo: function () { return 42 }}
  10613. return arr.foo() === 42 && // typed array instances can be augmented
  10614. typeof arr.subarray === 'function' && // chrome 9-10 lack `subarray`
  10615. arr.subarray(1, 1).byteLength === 0 // ie10 has broken `subarray`
  10616. } catch (e) {
  10617. return false
  10618. }
  10619. }
  10620. function kMaxLength () {
  10621. return Buffer.TYPED_ARRAY_SUPPORT
  10622. ? 0x7fffffff
  10623. : 0x3fffffff
  10624. }
  10625. function createBuffer (that, length) {
  10626. if (kMaxLength() < length) {
  10627. throw new RangeError('Invalid typed array length')
  10628. }
  10629. if (Buffer.TYPED_ARRAY_SUPPORT) {
  10630. // Return an augmented `Uint8Array` instance, for best performance
  10631. that = new Uint8Array(length)
  10632. that.__proto__ = Buffer.prototype
  10633. } else {
  10634. // Fallback: Return an object instance of the Buffer class
  10635. if (that === null) {
  10636. that = new Buffer(length)
  10637. }
  10638. that.length = length
  10639. }
  10640. return that
  10641. }
  10642. /**
  10643. * The Buffer constructor returns instances of `Uint8Array` that have their
  10644. * prototype changed to `Buffer.prototype`. Furthermore, `Buffer` is a subclass of
  10645. * `Uint8Array`, so the returned instances will have all the node `Buffer` methods
  10646. * and the `Uint8Array` methods. Square bracket notation works as expected -- it
  10647. * returns a single octet.
  10648. *
  10649. * The `Uint8Array` prototype remains unmodified.
  10650. */
  10651. function Buffer (arg, encodingOrOffset, length) {
  10652. if (!Buffer.TYPED_ARRAY_SUPPORT && !(this instanceof Buffer)) {
  10653. return new Buffer(arg, encodingOrOffset, length)
  10654. }
  10655. // Common case.
  10656. if (typeof arg === 'number') {
  10657. if (typeof encodingOrOffset === 'string') {
  10658. throw new Error(
  10659. 'If encoding is specified then the first argument must be a string'
  10660. )
  10661. }
  10662. return allocUnsafe(this, arg)
  10663. }
  10664. return from(this, arg, encodingOrOffset, length)
  10665. }
  10666. Buffer.poolSize = 8192 // not used by this implementation
  10667. // TODO: Legacy, not needed anymore. Remove in next major version.
  10668. Buffer._augment = function (arr) {
  10669. arr.__proto__ = Buffer.prototype
  10670. return arr
  10671. }
  10672. function from (that, value, encodingOrOffset, length) {
  10673. if (typeof value === 'number') {
  10674. throw new TypeError('"value" argument must not be a number')
  10675. }
  10676. if (typeof ArrayBuffer !== 'undefined' && value instanceof ArrayBuffer) {
  10677. return fromArrayBuffer(that, value, encodingOrOffset, length)
  10678. }
  10679. if (typeof value === 'string') {
  10680. return fromString(that, value, encodingOrOffset)
  10681. }
  10682. return fromObject(that, value)
  10683. }
  10684. /**
  10685. * Functionally equivalent to Buffer(arg, encoding) but throws a TypeError
  10686. * if value is a number.
  10687. * Buffer.from(str[, encoding])
  10688. * Buffer.from(array)
  10689. * Buffer.from(buffer)
  10690. * Buffer.from(arrayBuffer[, byteOffset[, length]])
  10691. **/
  10692. Buffer.from = function (value, encodingOrOffset, length) {
  10693. return from(null, value, encodingOrOffset, length)
  10694. }
  10695. if (Buffer.TYPED_ARRAY_SUPPORT) {
  10696. Buffer.prototype.__proto__ = Uint8Array.prototype
  10697. Buffer.__proto__ = Uint8Array
  10698. if (typeof Symbol !== 'undefined' && Symbol.species &&
  10699. Buffer[Symbol.species] === Buffer) {
  10700. // Fix subarray() in ES2016. See: https://github.com/feross/buffer/pull/97
  10701. Object.defineProperty(Buffer, Symbol.species, {
  10702. value: null,
  10703. configurable: true
  10704. })
  10705. }
  10706. }
  10707. function assertSize (size) {
  10708. if (typeof size !== 'number') {
  10709. throw new TypeError('"size" argument must be a number')
  10710. } else if (size < 0) {
  10711. throw new RangeError('"size" argument must not be negative')
  10712. }
  10713. }
  10714. function alloc (that, size, fill, encoding) {
  10715. assertSize(size)
  10716. if (size <= 0) {
  10717. return createBuffer(that, size)
  10718. }
  10719. if (fill !== undefined) {
  10720. // Only pay attention to encoding if it's a string. This
  10721. // prevents accidentally sending in a number that would
  10722. // be interpretted as a start offset.
  10723. return typeof encoding === 'string'
  10724. ? createBuffer(that, size).fill(fill, encoding)
  10725. : createBuffer(that, size).fill(fill)
  10726. }
  10727. return createBuffer(that, size)
  10728. }
  10729. /**
  10730. * Creates a new filled Buffer instance.
  10731. * alloc(size[, fill[, encoding]])
  10732. **/
  10733. Buffer.alloc = function (size, fill, encoding) {
  10734. return alloc(null, size, fill, encoding)
  10735. }
  10736. function allocUnsafe (that, size) {
  10737. assertSize(size)
  10738. that = createBuffer(that, size < 0 ? 0 : checked(size) | 0)
  10739. if (!Buffer.TYPED_ARRAY_SUPPORT) {
  10740. for (var i = 0; i < size; ++i) {
  10741. that[i] = 0
  10742. }
  10743. }
  10744. return that
  10745. }
  10746. /**
  10747. * Equivalent to Buffer(num), by default creates a non-zero-filled Buffer instance.
  10748. * */
  10749. Buffer.allocUnsafe = function (size) {
  10750. return allocUnsafe(null, size)
  10751. }
  10752. /**
  10753. * Equivalent to SlowBuffer(num), by default creates a non-zero-filled Buffer instance.
  10754. */
  10755. Buffer.allocUnsafeSlow = function (size) {
  10756. return allocUnsafe(null, size)
  10757. }
  10758. function fromString (that, string, encoding) {
  10759. if (typeof encoding !== 'string' || encoding === '') {
  10760. encoding = 'utf8'
  10761. }
  10762. if (!Buffer.isEncoding(encoding)) {
  10763. throw new TypeError('"encoding" must be a valid string encoding')
  10764. }
  10765. var length = byteLength(string, encoding) | 0
  10766. that = createBuffer(that, length)
  10767. var actual = that.write(string, encoding)
  10768. if (actual !== length) {
  10769. // Writing a hex string, for example, that contains invalid characters will
  10770. // cause everything after the first invalid character to be ignored. (e.g.
  10771. // 'abxxcd' will be treated as 'ab')
  10772. that = that.slice(0, actual)
  10773. }
  10774. return that
  10775. }
  10776. function fromArrayLike (that, array) {
  10777. var length = array.length < 0 ? 0 : checked(array.length) | 0
  10778. that = createBuffer(that, length)
  10779. for (var i = 0; i < length; i += 1) {
  10780. that[i] = array[i] & 255
  10781. }
  10782. return that
  10783. }
  10784. function fromArrayBuffer (that, array, byteOffset, length) {
  10785. array.byteLength // this throws if `array` is not a valid ArrayBuffer
  10786. if (byteOffset < 0 || array.byteLength < byteOffset) {
  10787. throw new RangeError('\'offset\' is out of bounds')
  10788. }
  10789. if (array.byteLength < byteOffset + (length || 0)) {
  10790. throw new RangeError('\'length\' is out of bounds')
  10791. }
  10792. if (byteOffset === undefined && length === undefined) {
  10793. array = new Uint8Array(array)
  10794. } else if (length === undefined) {
  10795. array = new Uint8Array(array, byteOffset)
  10796. } else {
  10797. array = new Uint8Array(array, byteOffset, length)
  10798. }
  10799. if (Buffer.TYPED_ARRAY_SUPPORT) {
  10800. // Return an augmented `Uint8Array` instance, for best performance
  10801. that = array
  10802. that.__proto__ = Buffer.prototype
  10803. } else {
  10804. // Fallback: Return an object instance of the Buffer class
  10805. that = fromArrayLike(that, array)
  10806. }
  10807. return that
  10808. }
  10809. function fromObject (that, obj) {
  10810. if (Buffer.isBuffer(obj)) {
  10811. var len = checked(obj.length) | 0
  10812. that = createBuffer(that, len)
  10813. if (that.length === 0) {
  10814. return that
  10815. }
  10816. obj.copy(that, 0, 0, len)
  10817. return that
  10818. }
  10819. if (obj) {
  10820. if ((typeof ArrayBuffer !== 'undefined' &&
  10821. obj.buffer instanceof ArrayBuffer) || 'length' in obj) {
  10822. if (typeof obj.length !== 'number' || isnan(obj.length)) {
  10823. return createBuffer(that, 0)
  10824. }
  10825. return fromArrayLike(that, obj)
  10826. }
  10827. if (obj.type === 'Buffer' && isArray(obj.data)) {
  10828. return fromArrayLike(that, obj.data)
  10829. }
  10830. }
  10831. throw new TypeError('First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.')
  10832. }
  10833. function checked (length) {
  10834. // Note: cannot use `length < kMaxLength()` here because that fails when
  10835. // length is NaN (which is otherwise coerced to zero.)
  10836. if (length >= kMaxLength()) {
  10837. throw new RangeError('Attempt to allocate Buffer larger than maximum ' +
  10838. 'size: 0x' + kMaxLength().toString(16) + ' bytes')
  10839. }
  10840. return length | 0
  10841. }
  10842. function SlowBuffer (length) {
  10843. if (+length != length) { // eslint-disable-line eqeqeq
  10844. length = 0
  10845. }
  10846. return Buffer.alloc(+length)
  10847. }
  10848. Buffer.isBuffer = function isBuffer (b) {
  10849. return !!(b != null && b._isBuffer)
  10850. }
  10851. Buffer.compare = function compare (a, b) {
  10852. if (!Buffer.isBuffer(a) || !Buffer.isBuffer(b)) {
  10853. throw new TypeError('Arguments must be Buffers')
  10854. }
  10855. if (a === b) return 0
  10856. var x = a.length
  10857. var y = b.length
  10858. for (var i = 0, len = Math.min(x, y); i < len; ++i) {
  10859. if (a[i] !== b[i]) {
  10860. x = a[i]
  10861. y = b[i]
  10862. break
  10863. }
  10864. }
  10865. if (x < y) return -1
  10866. if (y < x) return 1
  10867. return 0
  10868. }
  10869. Buffer.isEncoding = function isEncoding (encoding) {
  10870. switch (String(encoding).toLowerCase()) {
  10871. case 'hex':
  10872. case 'utf8':
  10873. case 'utf-8':
  10874. case 'ascii':
  10875. case 'latin1':
  10876. case 'binary':
  10877. case 'base64':
  10878. case 'ucs2':
  10879. case 'ucs-2':
  10880. case 'utf16le':
  10881. case 'utf-16le':
  10882. return true
  10883. default:
  10884. return false
  10885. }
  10886. }
  10887. Buffer.concat = function concat (list, length) {
  10888. if (!isArray(list)) {
  10889. throw new TypeError('"list" argument must be an Array of Buffers')
  10890. }
  10891. if (list.length === 0) {
  10892. return Buffer.alloc(0)
  10893. }
  10894. var i
  10895. if (length === undefined) {
  10896. length = 0
  10897. for (i = 0; i < list.length; ++i) {
  10898. length += list[i].length
  10899. }
  10900. }
  10901. var buffer = Buffer.allocUnsafe(length)
  10902. var pos = 0
  10903. for (i = 0; i < list.length; ++i) {
  10904. var buf = list[i]
  10905. if (!Buffer.isBuffer(buf)) {
  10906. throw new TypeError('"list" argument must be an Array of Buffers')
  10907. }
  10908. buf.copy(buffer, pos)
  10909. pos += buf.length
  10910. }
  10911. return buffer
  10912. }
  10913. function byteLength (string, encoding) {
  10914. if (Buffer.isBuffer(string)) {
  10915. return string.length
  10916. }
  10917. if (typeof ArrayBuffer !== 'undefined' && typeof ArrayBuffer.isView === 'function' &&
  10918. (ArrayBuffer.isView(string) || string instanceof ArrayBuffer)) {
  10919. return string.byteLength
  10920. }
  10921. if (typeof string !== 'string') {
  10922. string = '' + string
  10923. }
  10924. var len = string.length
  10925. if (len === 0) return 0
  10926. // Use a for loop to avoid recursion
  10927. var loweredCase = false
  10928. for (;;) {
  10929. switch (encoding) {
  10930. case 'ascii':
  10931. case 'latin1':
  10932. case 'binary':
  10933. return len
  10934. case 'utf8':
  10935. case 'utf-8':
  10936. case undefined:
  10937. return utf8ToBytes(string).length
  10938. case 'ucs2':
  10939. case 'ucs-2':
  10940. case 'utf16le':
  10941. case 'utf-16le':
  10942. return len * 2
  10943. case 'hex':
  10944. return len >>> 1
  10945. case 'base64':
  10946. return base64ToBytes(string).length
  10947. default:
  10948. if (loweredCase) return utf8ToBytes(string).length // assume utf8
  10949. encoding = ('' + encoding).toLowerCase()
  10950. loweredCase = true
  10951. }
  10952. }
  10953. }
  10954. Buffer.byteLength = byteLength
  10955. function slowToString (encoding, start, end) {
  10956. var loweredCase = false
  10957. // No need to verify that "this.length <= MAX_UINT32" since it's a read-only
  10958. // property of a typed array.
  10959. // This behaves neither like String nor Uint8Array in that we set start/end
  10960. // to their upper/lower bounds if the value passed is out of range.
  10961. // undefined is handled specially as per ECMA-262 6th Edition,
  10962. // Section 13.3.3.7 Runtime Semantics: KeyedBindingInitialization.
  10963. if (start === undefined || start < 0) {
  10964. start = 0
  10965. }
  10966. // Return early if start > this.length. Done here to prevent potential uint32
  10967. // coercion fail below.
  10968. if (start > this.length) {
  10969. return ''
  10970. }
  10971. if (end === undefined || end > this.length) {
  10972. end = this.length
  10973. }
  10974. if (end <= 0) {
  10975. return ''
  10976. }
  10977. // Force coersion to uint32. This will also coerce falsey/NaN values to 0.
  10978. end >>>= 0
  10979. start >>>= 0
  10980. if (end <= start) {
  10981. return ''
  10982. }
  10983. if (!encoding) encoding = 'utf8'
  10984. while (true) {
  10985. switch (encoding) {
  10986. case 'hex':
  10987. return hexSlice(this, start, end)
  10988. case 'utf8':
  10989. case 'utf-8':
  10990. return utf8Slice(this, start, end)
  10991. case 'ascii':
  10992. return asciiSlice(this, start, end)
  10993. case 'latin1':
  10994. case 'binary':
  10995. return latin1Slice(this, start, end)
  10996. case 'base64':
  10997. return base64Slice(this, start, end)
  10998. case 'ucs2':
  10999. case 'ucs-2':
  11000. case 'utf16le':
  11001. case 'utf-16le':
  11002. return utf16leSlice(this, start, end)
  11003. default:
  11004. if (loweredCase) throw new TypeError('Unknown encoding: ' + encoding)
  11005. encoding = (encoding + '').toLowerCase()
  11006. loweredCase = true
  11007. }
  11008. }
  11009. }
  11010. // The property is used by `Buffer.isBuffer` and `is-buffer` (in Safari 5-7) to detect
  11011. // Buffer instances.
  11012. Buffer.prototype._isBuffer = true
  11013. function swap (b, n, m) {
  11014. var i = b[n]
  11015. b[n] = b[m]
  11016. b[m] = i
  11017. }
  11018. Buffer.prototype.swap16 = function swap16 () {
  11019. var len = this.length
  11020. if (len % 2 !== 0) {
  11021. throw new RangeError('Buffer size must be a multiple of 16-bits')
  11022. }
  11023. for (var i = 0; i < len; i += 2) {
  11024. swap(this, i, i + 1)
  11025. }
  11026. return this
  11027. }
  11028. Buffer.prototype.swap32 = function swap32 () {
  11029. var len = this.length
  11030. if (len % 4 !== 0) {
  11031. throw new RangeError('Buffer size must be a multiple of 32-bits')
  11032. }
  11033. for (var i = 0; i < len; i += 4) {
  11034. swap(this, i, i + 3)
  11035. swap(this, i + 1, i + 2)
  11036. }
  11037. return this
  11038. }
  11039. Buffer.prototype.swap64 = function swap64 () {
  11040. var len = this.length
  11041. if (len % 8 !== 0) {
  11042. throw new RangeError('Buffer size must be a multiple of 64-bits')
  11043. }
  11044. for (var i = 0; i < len; i += 8) {
  11045. swap(this, i, i + 7)
  11046. swap(this, i + 1, i + 6)
  11047. swap(this, i + 2, i + 5)
  11048. swap(this, i + 3, i + 4)
  11049. }
  11050. return this
  11051. }
  11052. Buffer.prototype.toString = function toString () {
  11053. var length = this.length | 0
  11054. if (length === 0) return ''
  11055. if (arguments.length === 0) return utf8Slice(this, 0, length)
  11056. return slowToString.apply(this, arguments)
  11057. }
  11058. Buffer.prototype.equals = function equals (b) {
  11059. if (!Buffer.isBuffer(b)) throw new TypeError('Argument must be a Buffer')
  11060. if (this === b) return true
  11061. return Buffer.compare(this, b) === 0
  11062. }
  11063. Buffer.prototype.inspect = function inspect () {
  11064. var str = ''
  11065. var max = exports.INSPECT_MAX_BYTES
  11066. if (this.length > 0) {
  11067. str = this.toString('hex', 0, max).match(/.{2}/g).join(' ')
  11068. if (this.length > max) str += ' ... '
  11069. }
  11070. return '<Buffer ' + str + '>'
  11071. }
  11072. Buffer.prototype.compare = function compare (target, start, end, thisStart, thisEnd) {
  11073. if (!Buffer.isBuffer(target)) {
  11074. throw new TypeError('Argument must be a Buffer')
  11075. }
  11076. if (start === undefined) {
  11077. start = 0
  11078. }
  11079. if (end === undefined) {
  11080. end = target ? target.length : 0
  11081. }
  11082. if (thisStart === undefined) {
  11083. thisStart = 0
  11084. }
  11085. if (thisEnd === undefined) {
  11086. thisEnd = this.length
  11087. }
  11088. if (start < 0 || end > target.length || thisStart < 0 || thisEnd > this.length) {
  11089. throw new RangeError('out of range index')
  11090. }
  11091. if (thisStart >= thisEnd && start >= end) {
  11092. return 0
  11093. }
  11094. if (thisStart >= thisEnd) {
  11095. return -1
  11096. }
  11097. if (start >= end) {
  11098. return 1
  11099. }
  11100. start >>>= 0
  11101. end >>>= 0
  11102. thisStart >>>= 0
  11103. thisEnd >>>= 0
  11104. if (this === target) return 0
  11105. var x = thisEnd - thisStart
  11106. var y = end - start
  11107. var len = Math.min(x, y)
  11108. var thisCopy = this.slice(thisStart, thisEnd)
  11109. var targetCopy = target.slice(start, end)
  11110. for (var i = 0; i < len; ++i) {
  11111. if (thisCopy[i] !== targetCopy[i]) {
  11112. x = thisCopy[i]
  11113. y = targetCopy[i]
  11114. break
  11115. }
  11116. }
  11117. if (x < y) return -1
  11118. if (y < x) return 1
  11119. return 0
  11120. }
  11121. // Finds either the first index of `val` in `buffer` at offset >= `byteOffset`,
  11122. // OR the last index of `val` in `buffer` at offset <= `byteOffset`.
  11123. //
  11124. // Arguments:
  11125. // - buffer - a Buffer to search
  11126. // - val - a string, Buffer, or number
  11127. // - byteOffset - an index into `buffer`; will be clamped to an int32
  11128. // - encoding - an optional encoding, relevant is val is a string
  11129. // - dir - true for indexOf, false for lastIndexOf
  11130. function bidirectionalIndexOf (buffer, val, byteOffset, encoding, dir) {
  11131. // Empty buffer means no match
  11132. if (buffer.length === 0) return -1
  11133. // Normalize byteOffset
  11134. if (typeof byteOffset === 'string') {
  11135. encoding = byteOffset
  11136. byteOffset = 0
  11137. } else if (byteOffset > 0x7fffffff) {
  11138. byteOffset = 0x7fffffff
  11139. } else if (byteOffset < -0x80000000) {
  11140. byteOffset = -0x80000000
  11141. }
  11142. byteOffset = +byteOffset // Coerce to Number.
  11143. if (isNaN(byteOffset)) {
  11144. // byteOffset: it it's undefined, null, NaN, "foo", etc, search whole buffer
  11145. byteOffset = dir ? 0 : (buffer.length - 1)
  11146. }
  11147. // Normalize byteOffset: negative offsets start from the end of the buffer
  11148. if (byteOffset < 0) byteOffset = buffer.length + byteOffset
  11149. if (byteOffset >= buffer.length) {
  11150. if (dir) return -1
  11151. else byteOffset = buffer.length - 1
  11152. } else if (byteOffset < 0) {
  11153. if (dir) byteOffset = 0
  11154. else return -1
  11155. }
  11156. // Normalize val
  11157. if (typeof val === 'string') {
  11158. val = Buffer.from(val, encoding)
  11159. }
  11160. // Finally, search either indexOf (if dir is true) or lastIndexOf
  11161. if (Buffer.isBuffer(val)) {
  11162. // Special case: looking for empty string/buffer always fails
  11163. if (val.length === 0) {
  11164. return -1
  11165. }
  11166. return arrayIndexOf(buffer, val, byteOffset, encoding, dir)
  11167. } else if (typeof val === 'number') {
  11168. val = val & 0xFF // Search for a byte value [0-255]
  11169. if (Buffer.TYPED_ARRAY_SUPPORT &&
  11170. typeof Uint8Array.prototype.indexOf === 'function') {
  11171. if (dir) {
  11172. return Uint8Array.prototype.indexOf.call(buffer, val, byteOffset)
  11173. } else {
  11174. return Uint8Array.prototype.lastIndexOf.call(buffer, val, byteOffset)
  11175. }
  11176. }
  11177. return arrayIndexOf(buffer, [ val ], byteOffset, encoding, dir)
  11178. }
  11179. throw new TypeError('val must be string, number or Buffer')
  11180. }
  11181. function arrayIndexOf (arr, val, byteOffset, encoding, dir) {
  11182. var indexSize = 1
  11183. var arrLength = arr.length
  11184. var valLength = val.length
  11185. if (encoding !== undefined) {
  11186. encoding = String(encoding).toLowerCase()
  11187. if (encoding === 'ucs2' || encoding === 'ucs-2' ||
  11188. encoding === 'utf16le' || encoding === 'utf-16le') {
  11189. if (arr.length < 2 || val.length < 2) {
  11190. return -1
  11191. }
  11192. indexSize = 2
  11193. arrLength /= 2
  11194. valLength /= 2
  11195. byteOffset /= 2
  11196. }
  11197. }
  11198. function read (buf, i) {
  11199. if (indexSize === 1) {
  11200. return buf[i]
  11201. } else {
  11202. return buf.readUInt16BE(i * indexSize)
  11203. }
  11204. }
  11205. var i
  11206. if (dir) {
  11207. var foundIndex = -1
  11208. for (i = byteOffset; i < arrLength; i++) {
  11209. if (read(arr, i) === read(val, foundIndex === -1 ? 0 : i - foundIndex)) {
  11210. if (foundIndex === -1) foundIndex = i
  11211. if (i - foundIndex + 1 === valLength) return foundIndex * indexSize
  11212. } else {
  11213. if (foundIndex !== -1) i -= i - foundIndex
  11214. foundIndex = -1
  11215. }
  11216. }
  11217. } else {
  11218. if (byteOffset + valLength > arrLength) byteOffset = arrLength - valLength
  11219. for (i = byteOffset; i >= 0; i--) {
  11220. var found = true
  11221. for (var j = 0; j < valLength; j++) {
  11222. if (read(arr, i + j) !== read(val, j)) {
  11223. found = false
  11224. break
  11225. }
  11226. }
  11227. if (found) return i
  11228. }
  11229. }
  11230. return -1
  11231. }
  11232. Buffer.prototype.includes = function includes (val, byteOffset, encoding) {
  11233. return this.indexOf(val, byteOffset, encoding) !== -1
  11234. }
  11235. Buffer.prototype.indexOf = function indexOf (val, byteOffset, encoding) {
  11236. return bidirectionalIndexOf(this, val, byteOffset, encoding, true)
  11237. }
  11238. Buffer.prototype.lastIndexOf = function lastIndexOf (val, byteOffset, encoding) {
  11239. return bidirectionalIndexOf(this, val, byteOffset, encoding, false)
  11240. }
  11241. function hexWrite (buf, string, offset, length) {
  11242. offset = Number(offset) || 0
  11243. var remaining = buf.length - offset
  11244. if (!length) {
  11245. length = remaining
  11246. } else {
  11247. length = Number(length)
  11248. if (length > remaining) {
  11249. length = remaining
  11250. }
  11251. }
  11252. // must be an even number of digits
  11253. var strLen = string.length
  11254. if (strLen % 2 !== 0) throw new TypeError('Invalid hex string')
  11255. if (length > strLen / 2) {
  11256. length = strLen / 2
  11257. }
  11258. for (var i = 0; i < length; ++i) {
  11259. var parsed = parseInt(string.substr(i * 2, 2), 16)
  11260. if (isNaN(parsed)) return i
  11261. buf[offset + i] = parsed
  11262. }
  11263. return i
  11264. }
  11265. function utf8Write (buf, string, offset, length) {
  11266. return blitBuffer(utf8ToBytes(string, buf.length - offset), buf, offset, length)
  11267. }
  11268. function asciiWrite (buf, string, offset, length) {
  11269. return blitBuffer(asciiToBytes(string), buf, offset, length)
  11270. }
  11271. function latin1Write (buf, string, offset, length) {
  11272. return asciiWrite(buf, string, offset, length)
  11273. }
  11274. function base64Write (buf, string, offset, length) {
  11275. return blitBuffer(base64ToBytes(string), buf, offset, length)
  11276. }
  11277. function ucs2Write (buf, string, offset, length) {
  11278. return blitBuffer(utf16leToBytes(string, buf.length - offset), buf, offset, length)
  11279. }
  11280. Buffer.prototype.write = function write (string, offset, length, encoding) {
  11281. // Buffer#write(string)
  11282. if (offset === undefined) {
  11283. encoding = 'utf8'
  11284. length = this.length
  11285. offset = 0
  11286. // Buffer#write(string, encoding)
  11287. } else if (length === undefined && typeof offset === 'string') {
  11288. encoding = offset
  11289. length = this.length
  11290. offset = 0
  11291. // Buffer#write(string, offset[, length][, encoding])
  11292. } else if (isFinite(offset)) {
  11293. offset = offset | 0
  11294. if (isFinite(length)) {
  11295. length = length | 0
  11296. if (encoding === undefined) encoding = 'utf8'
  11297. } else {
  11298. encoding = length
  11299. length = undefined
  11300. }
  11301. // legacy write(string, encoding, offset, length) - remove in v0.13
  11302. } else {
  11303. throw new Error(
  11304. 'Buffer.write(string, encoding, offset[, length]) is no longer supported'
  11305. )
  11306. }
  11307. var remaining = this.length - offset
  11308. if (length === undefined || length > remaining) length = remaining
  11309. if ((string.length > 0 && (length < 0 || offset < 0)) || offset > this.length) {
  11310. throw new RangeError('Attempt to write outside buffer bounds')
  11311. }
  11312. if (!encoding) encoding = 'utf8'
  11313. var loweredCase = false
  11314. for (;;) {
  11315. switch (encoding) {
  11316. case 'hex':
  11317. return hexWrite(this, string, offset, length)
  11318. case 'utf8':
  11319. case 'utf-8':
  11320. return utf8Write(this, string, offset, length)
  11321. case 'ascii':
  11322. return asciiWrite(this, string, offset, length)
  11323. case 'latin1':
  11324. case 'binary':
  11325. return latin1Write(this, string, offset, length)
  11326. case 'base64':
  11327. // Warning: maxLength not taken into account in base64Write
  11328. return base64Write(this, string, offset, length)
  11329. case 'ucs2':
  11330. case 'ucs-2':
  11331. case 'utf16le':
  11332. case 'utf-16le':
  11333. return ucs2Write(this, string, offset, length)
  11334. default:
  11335. if (loweredCase) throw new TypeError('Unknown encoding: ' + encoding)
  11336. encoding = ('' + encoding).toLowerCase()
  11337. loweredCase = true
  11338. }
  11339. }
  11340. }
  11341. Buffer.prototype.toJSON = function toJSON () {
  11342. return {
  11343. type: 'Buffer',
  11344. data: Array.prototype.slice.call(this._arr || this, 0)
  11345. }
  11346. }
  11347. function base64Slice (buf, start, end) {
  11348. if (start === 0 && end === buf.length) {
  11349. return base64.fromByteArray(buf)
  11350. } else {
  11351. return base64.fromByteArray(buf.slice(start, end))
  11352. }
  11353. }
  11354. function utf8Slice (buf, start, end) {
  11355. end = Math.min(buf.length, end)
  11356. var res = []
  11357. var i = start
  11358. while (i < end) {
  11359. var firstByte = buf[i]
  11360. var codePoint = null
  11361. var bytesPerSequence = (firstByte > 0xEF) ? 4
  11362. : (firstByte > 0xDF) ? 3
  11363. : (firstByte > 0xBF) ? 2
  11364. : 1
  11365. if (i + bytesPerSequence <= end) {
  11366. var secondByte, thirdByte, fourthByte, tempCodePoint
  11367. switch (bytesPerSequence) {
  11368. case 1:
  11369. if (firstByte < 0x80) {
  11370. codePoint = firstByte
  11371. }
  11372. break
  11373. case 2:
  11374. secondByte = buf[i + 1]
  11375. if ((secondByte & 0xC0) === 0x80) {
  11376. tempCodePoint = (firstByte & 0x1F) << 0x6 | (secondByte & 0x3F)
  11377. if (tempCodePoint > 0x7F) {
  11378. codePoint = tempCodePoint
  11379. }
  11380. }
  11381. break
  11382. case 3:
  11383. secondByte = buf[i + 1]
  11384. thirdByte = buf[i + 2]
  11385. if ((secondByte & 0xC0) === 0x80 && (thirdByte & 0xC0) === 0x80) {
  11386. tempCodePoint = (firstByte & 0xF) << 0xC | (secondByte & 0x3F) << 0x6 | (thirdByte & 0x3F)
  11387. if (tempCodePoint > 0x7FF && (tempCodePoint < 0xD800 || tempCodePoint > 0xDFFF)) {
  11388. codePoint = tempCodePoint
  11389. }
  11390. }
  11391. break
  11392. case 4:
  11393. secondByte = buf[i + 1]
  11394. thirdByte = buf[i + 2]
  11395. fourthByte = buf[i + 3]
  11396. if ((secondByte & 0xC0) === 0x80 && (thirdByte & 0xC0) === 0x80 && (fourthByte & 0xC0) === 0x80) {
  11397. tempCodePoint = (firstByte & 0xF) << 0x12 | (secondByte & 0x3F) << 0xC | (thirdByte & 0x3F) << 0x6 | (fourthByte & 0x3F)
  11398. if (tempCodePoint > 0xFFFF && tempCodePoint < 0x110000) {
  11399. codePoint = tempCodePoint
  11400. }
  11401. }
  11402. }
  11403. }
  11404. if (codePoint === null) {
  11405. // we did not generate a valid codePoint so insert a
  11406. // replacement char (U+FFFD) and advance only 1 byte
  11407. codePoint = 0xFFFD
  11408. bytesPerSequence = 1
  11409. } else if (codePoint > 0xFFFF) {
  11410. // encode to utf16 (surrogate pair dance)
  11411. codePoint -= 0x10000
  11412. res.push(codePoint >>> 10 & 0x3FF | 0xD800)
  11413. codePoint = 0xDC00 | codePoint & 0x3FF
  11414. }
  11415. res.push(codePoint)
  11416. i += bytesPerSequence
  11417. }
  11418. return decodeCodePointsArray(res)
  11419. }
  11420. // Based on http://stackoverflow.com/a/22747272/680742, the browser with
  11421. // the lowest limit is Chrome, with 0x10000 args.
  11422. // We go 1 magnitude less, for safety
  11423. var MAX_ARGUMENTS_LENGTH = 0x1000
  11424. function decodeCodePointsArray (codePoints) {
  11425. var len = codePoints.length
  11426. if (len <= MAX_ARGUMENTS_LENGTH) {
  11427. return String.fromCharCode.apply(String, codePoints) // avoid extra slice()
  11428. }
  11429. // Decode in chunks to avoid "call stack size exceeded".
  11430. var res = ''
  11431. var i = 0
  11432. while (i < len) {
  11433. res += String.fromCharCode.apply(
  11434. String,
  11435. codePoints.slice(i, i += MAX_ARGUMENTS_LENGTH)
  11436. )
  11437. }
  11438. return res
  11439. }
  11440. function asciiSlice (buf, start, end) {
  11441. var ret = ''
  11442. end = Math.min(buf.length, end)
  11443. for (var i = start; i < end; ++i) {
  11444. ret += String.fromCharCode(buf[i] & 0x7F)
  11445. }
  11446. return ret
  11447. }
  11448. function latin1Slice (buf, start, end) {
  11449. var ret = ''
  11450. end = Math.min(buf.length, end)
  11451. for (var i = start; i < end; ++i) {
  11452. ret += String.fromCharCode(buf[i])
  11453. }
  11454. return ret
  11455. }
  11456. function hexSlice (buf, start, end) {
  11457. var len = buf.length
  11458. if (!start || start < 0) start = 0
  11459. if (!end || end < 0 || end > len) end = len
  11460. var out = ''
  11461. for (var i = start; i < end; ++i) {
  11462. out += toHex(buf[i])
  11463. }
  11464. return out
  11465. }
  11466. function utf16leSlice (buf, start, end) {
  11467. var bytes = buf.slice(start, end)
  11468. var res = ''
  11469. for (var i = 0; i < bytes.length; i += 2) {
  11470. res += String.fromCharCode(bytes[i] + bytes[i + 1] * 256)
  11471. }
  11472. return res
  11473. }
  11474. Buffer.prototype.slice = function slice (start, end) {
  11475. var len = this.length
  11476. start = ~~start
  11477. end = end === undefined ? len : ~~end
  11478. if (start < 0) {
  11479. start += len
  11480. if (start < 0) start = 0
  11481. } else if (start > len) {
  11482. start = len
  11483. }
  11484. if (end < 0) {
  11485. end += len
  11486. if (end < 0) end = 0
  11487. } else if (end > len) {
  11488. end = len
  11489. }
  11490. if (end < start) end = start
  11491. var newBuf
  11492. if (Buffer.TYPED_ARRAY_SUPPORT) {
  11493. newBuf = this.subarray(start, end)
  11494. newBuf.__proto__ = Buffer.prototype
  11495. } else {
  11496. var sliceLen = end - start
  11497. newBuf = new Buffer(sliceLen, undefined)
  11498. for (var i = 0; i < sliceLen; ++i) {
  11499. newBuf[i] = this[i + start]
  11500. }
  11501. }
  11502. return newBuf
  11503. }
  11504. /*
  11505. * Need to make sure that buffer isn't trying to write out of bounds.
  11506. */
  11507. function checkOffset (offset, ext, length) {
  11508. if ((offset % 1) !== 0 || offset < 0) throw new RangeError('offset is not uint')
  11509. if (offset + ext > length) throw new RangeError('Trying to access beyond buffer length')
  11510. }
  11511. Buffer.prototype.readUIntLE = function readUIntLE (offset, byteLength, noAssert) {
  11512. offset = offset | 0
  11513. byteLength = byteLength | 0
  11514. if (!noAssert) checkOffset(offset, byteLength, this.length)
  11515. var val = this[offset]
  11516. var mul = 1
  11517. var i = 0
  11518. while (++i < byteLength && (mul *= 0x100)) {
  11519. val += this[offset + i] * mul
  11520. }
  11521. return val
  11522. }
  11523. Buffer.prototype.readUIntBE = function readUIntBE (offset, byteLength, noAssert) {
  11524. offset = offset | 0
  11525. byteLength = byteLength | 0
  11526. if (!noAssert) {
  11527. checkOffset(offset, byteLength, this.length)
  11528. }
  11529. var val = this[offset + --byteLength]
  11530. var mul = 1
  11531. while (byteLength > 0 && (mul *= 0x100)) {
  11532. val += this[offset + --byteLength] * mul
  11533. }
  11534. return val
  11535. }
  11536. Buffer.prototype.readUInt8 = function readUInt8 (offset, noAssert) {
  11537. if (!noAssert) checkOffset(offset, 1, this.length)
  11538. return this[offset]
  11539. }
  11540. Buffer.prototype.readUInt16LE = function readUInt16LE (offset, noAssert) {
  11541. if (!noAssert) checkOffset(offset, 2, this.length)
  11542. return this[offset] | (this[offset + 1] << 8)
  11543. }
  11544. Buffer.prototype.readUInt16BE = function readUInt16BE (offset, noAssert) {
  11545. if (!noAssert) checkOffset(offset, 2, this.length)
  11546. return (this[offset] << 8) | this[offset + 1]
  11547. }
  11548. Buffer.prototype.readUInt32LE = function readUInt32LE (offset, noAssert) {
  11549. if (!noAssert) checkOffset(offset, 4, this.length)
  11550. return ((this[offset]) |
  11551. (this[offset + 1] << 8) |
  11552. (this[offset + 2] << 16)) +
  11553. (this[offset + 3] * 0x1000000)
  11554. }
  11555. Buffer.prototype.readUInt32BE = function readUInt32BE (offset, noAssert) {
  11556. if (!noAssert) checkOffset(offset, 4, this.length)
  11557. return (this[offset] * 0x1000000) +
  11558. ((this[offset + 1] << 16) |
  11559. (this[offset + 2] << 8) |
  11560. this[offset + 3])
  11561. }
  11562. Buffer.prototype.readIntLE = function readIntLE (offset, byteLength, noAssert) {
  11563. offset = offset | 0
  11564. byteLength = byteLength | 0
  11565. if (!noAssert) checkOffset(offset, byteLength, this.length)
  11566. var val = this[offset]
  11567. var mul = 1
  11568. var i = 0
  11569. while (++i < byteLength && (mul *= 0x100)) {
  11570. val += this[offset + i] * mul
  11571. }
  11572. mul *= 0x80
  11573. if (val >= mul) val -= Math.pow(2, 8 * byteLength)
  11574. return val
  11575. }
  11576. Buffer.prototype.readIntBE = function readIntBE (offset, byteLength, noAssert) {
  11577. offset = offset | 0
  11578. byteLength = byteLength | 0
  11579. if (!noAssert) checkOffset(offset, byteLength, this.length)
  11580. var i = byteLength
  11581. var mul = 1
  11582. var val = this[offset + --i]
  11583. while (i > 0 && (mul *= 0x100)) {
  11584. val += this[offset + --i] * mul
  11585. }
  11586. mul *= 0x80
  11587. if (val >= mul) val -= Math.pow(2, 8 * byteLength)
  11588. return val
  11589. }
  11590. Buffer.prototype.readInt8 = function readInt8 (offset, noAssert) {
  11591. if (!noAssert) checkOffset(offset, 1, this.length)
  11592. if (!(this[offset] & 0x80)) return (this[offset])
  11593. return ((0xff - this[offset] + 1) * -1)
  11594. }
  11595. Buffer.prototype.readInt16LE = function readInt16LE (offset, noAssert) {
  11596. if (!noAssert) checkOffset(offset, 2, this.length)
  11597. var val = this[offset] | (this[offset + 1] << 8)
  11598. return (val & 0x8000) ? val | 0xFFFF0000 : val
  11599. }
  11600. Buffer.prototype.readInt16BE = function readInt16BE (offset, noAssert) {
  11601. if (!noAssert) checkOffset(offset, 2, this.length)
  11602. var val = this[offset + 1] | (this[offset] << 8)
  11603. return (val & 0x8000) ? val | 0xFFFF0000 : val
  11604. }
  11605. Buffer.prototype.readInt32LE = function readInt32LE (offset, noAssert) {
  11606. if (!noAssert) checkOffset(offset, 4, this.length)
  11607. return (this[offset]) |
  11608. (this[offset + 1] << 8) |
  11609. (this[offset + 2] << 16) |
  11610. (this[offset + 3] << 24)
  11611. }
  11612. Buffer.prototype.readInt32BE = function readInt32BE (offset, noAssert) {
  11613. if (!noAssert) checkOffset(offset, 4, this.length)
  11614. return (this[offset] << 24) |
  11615. (this[offset + 1] << 16) |
  11616. (this[offset + 2] << 8) |
  11617. (this[offset + 3])
  11618. }
  11619. Buffer.prototype.readFloatLE = function readFloatLE (offset, noAssert) {
  11620. if (!noAssert) checkOffset(offset, 4, this.length)
  11621. return ieee754.read(this, offset, true, 23, 4)
  11622. }
  11623. Buffer.prototype.readFloatBE = function readFloatBE (offset, noAssert) {
  11624. if (!noAssert) checkOffset(offset, 4, this.length)
  11625. return ieee754.read(this, offset, false, 23, 4)
  11626. }
  11627. Buffer.prototype.readDoubleLE = function readDoubleLE (offset, noAssert) {
  11628. if (!noAssert) checkOffset(offset, 8, this.length)
  11629. return ieee754.read(this, offset, true, 52, 8)
  11630. }
  11631. Buffer.prototype.readDoubleBE = function readDoubleBE (offset, noAssert) {
  11632. if (!noAssert) checkOffset(offset, 8, this.length)
  11633. return ieee754.read(this, offset, false, 52, 8)
  11634. }
  11635. function checkInt (buf, value, offset, ext, max, min) {
  11636. if (!Buffer.isBuffer(buf)) throw new TypeError('"buffer" argument must be a Buffer instance')
  11637. if (value > max || value < min) throw new RangeError('"value" argument is out of bounds')
  11638. if (offset + ext > buf.length) throw new RangeError('Index out of range')
  11639. }
  11640. Buffer.prototype.writeUIntLE = function writeUIntLE (value, offset, byteLength, noAssert) {
  11641. value = +value
  11642. offset = offset | 0
  11643. byteLength = byteLength | 0
  11644. if (!noAssert) {
  11645. var maxBytes = Math.pow(2, 8 * byteLength) - 1
  11646. checkInt(this, value, offset, byteLength, maxBytes, 0)
  11647. }
  11648. var mul = 1
  11649. var i = 0
  11650. this[offset] = value & 0xFF
  11651. while (++i < byteLength && (mul *= 0x100)) {
  11652. this[offset + i] = (value / mul) & 0xFF
  11653. }
  11654. return offset + byteLength
  11655. }
  11656. Buffer.prototype.writeUIntBE = function writeUIntBE (value, offset, byteLength, noAssert) {
  11657. value = +value
  11658. offset = offset | 0
  11659. byteLength = byteLength | 0
  11660. if (!noAssert) {
  11661. var maxBytes = Math.pow(2, 8 * byteLength) - 1
  11662. checkInt(this, value, offset, byteLength, maxBytes, 0)
  11663. }
  11664. var i = byteLength - 1
  11665. var mul = 1
  11666. this[offset + i] = value & 0xFF
  11667. while (--i >= 0 && (mul *= 0x100)) {
  11668. this[offset + i] = (value / mul) & 0xFF
  11669. }
  11670. return offset + byteLength
  11671. }
  11672. Buffer.prototype.writeUInt8 = function writeUInt8 (value, offset, noAssert) {
  11673. value = +value
  11674. offset = offset | 0
  11675. if (!noAssert) checkInt(this, value, offset, 1, 0xff, 0)
  11676. if (!Buffer.TYPED_ARRAY_SUPPORT) value = Math.floor(value)
  11677. this[offset] = (value & 0xff)
  11678. return offset + 1
  11679. }
  11680. function objectWriteUInt16 (buf, value, offset, littleEndian) {
  11681. if (value < 0) value = 0xffff + value + 1
  11682. for (var i = 0, j = Math.min(buf.length - offset, 2); i < j; ++i) {
  11683. buf[offset + i] = (value & (0xff << (8 * (littleEndian ? i : 1 - i)))) >>>
  11684. (littleEndian ? i : 1 - i) * 8
  11685. }
  11686. }
  11687. Buffer.prototype.writeUInt16LE = function writeUInt16LE (value, offset, noAssert) {
  11688. value = +value
  11689. offset = offset | 0
  11690. if (!noAssert) checkInt(this, value, offset, 2, 0xffff, 0)
  11691. if (Buffer.TYPED_ARRAY_SUPPORT) {
  11692. this[offset] = (value & 0xff)
  11693. this[offset + 1] = (value >>> 8)
  11694. } else {
  11695. objectWriteUInt16(this, value, offset, true)
  11696. }
  11697. return offset + 2
  11698. }
  11699. Buffer.prototype.writeUInt16BE = function writeUInt16BE (value, offset, noAssert) {
  11700. value = +value
  11701. offset = offset | 0
  11702. if (!noAssert) checkInt(this, value, offset, 2, 0xffff, 0)
  11703. if (Buffer.TYPED_ARRAY_SUPPORT) {
  11704. this[offset] = (value >>> 8)
  11705. this[offset + 1] = (value & 0xff)
  11706. } else {
  11707. objectWriteUInt16(this, value, offset, false)
  11708. }
  11709. return offset + 2
  11710. }
  11711. function objectWriteUInt32 (buf, value, offset, littleEndian) {
  11712. if (value < 0) value = 0xffffffff + value + 1
  11713. for (var i = 0, j = Math.min(buf.length - offset, 4); i < j; ++i) {
  11714. buf[offset + i] = (value >>> (littleEndian ? i : 3 - i) * 8) & 0xff
  11715. }
  11716. }
  11717. Buffer.prototype.writeUInt32LE = function writeUInt32LE (value, offset, noAssert) {
  11718. value = +value
  11719. offset = offset | 0
  11720. if (!noAssert) checkInt(this, value, offset, 4, 0xffffffff, 0)
  11721. if (Buffer.TYPED_ARRAY_SUPPORT) {
  11722. this[offset + 3] = (value >>> 24)
  11723. this[offset + 2] = (value >>> 16)
  11724. this[offset + 1] = (value >>> 8)
  11725. this[offset] = (value & 0xff)
  11726. } else {
  11727. objectWriteUInt32(this, value, offset, true)
  11728. }
  11729. return offset + 4
  11730. }
  11731. Buffer.prototype.writeUInt32BE = function writeUInt32BE (value, offset, noAssert) {
  11732. value = +value
  11733. offset = offset | 0
  11734. if (!noAssert) checkInt(this, value, offset, 4, 0xffffffff, 0)
  11735. if (Buffer.TYPED_ARRAY_SUPPORT) {
  11736. this[offset] = (value >>> 24)
  11737. this[offset + 1] = (value >>> 16)
  11738. this[offset + 2] = (value >>> 8)
  11739. this[offset + 3] = (value & 0xff)
  11740. } else {
  11741. objectWriteUInt32(this, value, offset, false)
  11742. }
  11743. return offset + 4
  11744. }
  11745. Buffer.prototype.writeIntLE = function writeIntLE (value, offset, byteLength, noAssert) {
  11746. value = +value
  11747. offset = offset | 0
  11748. if (!noAssert) {
  11749. var limit = Math.pow(2, 8 * byteLength - 1)
  11750. checkInt(this, value, offset, byteLength, limit - 1, -limit)
  11751. }
  11752. var i = 0
  11753. var mul = 1
  11754. var sub = 0
  11755. this[offset] = value & 0xFF
  11756. while (++i < byteLength && (mul *= 0x100)) {
  11757. if (value < 0 && sub === 0 && this[offset + i - 1] !== 0) {
  11758. sub = 1
  11759. }
  11760. this[offset + i] = ((value / mul) >> 0) - sub & 0xFF
  11761. }
  11762. return offset + byteLength
  11763. }
  11764. Buffer.prototype.writeIntBE = function writeIntBE (value, offset, byteLength, noAssert) {
  11765. value = +value
  11766. offset = offset | 0
  11767. if (!noAssert) {
  11768. var limit = Math.pow(2, 8 * byteLength - 1)
  11769. checkInt(this, value, offset, byteLength, limit - 1, -limit)
  11770. }
  11771. var i = byteLength - 1
  11772. var mul = 1
  11773. var sub = 0
  11774. this[offset + i] = value & 0xFF
  11775. while (--i >= 0 && (mul *= 0x100)) {
  11776. if (value < 0 && sub === 0 && this[offset + i + 1] !== 0) {
  11777. sub = 1
  11778. }
  11779. this[offset + i] = ((value / mul) >> 0) - sub & 0xFF
  11780. }
  11781. return offset + byteLength
  11782. }
  11783. Buffer.prototype.writeInt8 = function writeInt8 (value, offset, noAssert) {
  11784. value = +value
  11785. offset = offset | 0
  11786. if (!noAssert) checkInt(this, value, offset, 1, 0x7f, -0x80)
  11787. if (!Buffer.TYPED_ARRAY_SUPPORT) value = Math.floor(value)
  11788. if (value < 0) value = 0xff + value + 1
  11789. this[offset] = (value & 0xff)
  11790. return offset + 1
  11791. }
  11792. Buffer.prototype.writeInt16LE = function writeInt16LE (value, offset, noAssert) {
  11793. value = +value
  11794. offset = offset | 0
  11795. if (!noAssert) checkInt(this, value, offset, 2, 0x7fff, -0x8000)
  11796. if (Buffer.TYPED_ARRAY_SUPPORT) {
  11797. this[offset] = (value & 0xff)
  11798. this[offset + 1] = (value >>> 8)
  11799. } else {
  11800. objectWriteUInt16(this, value, offset, true)
  11801. }
  11802. return offset + 2
  11803. }
  11804. Buffer.prototype.writeInt16BE = function writeInt16BE (value, offset, noAssert) {
  11805. value = +value
  11806. offset = offset | 0
  11807. if (!noAssert) checkInt(this, value, offset, 2, 0x7fff, -0x8000)
  11808. if (Buffer.TYPED_ARRAY_SUPPORT) {
  11809. this[offset] = (value >>> 8)
  11810. this[offset + 1] = (value & 0xff)
  11811. } else {
  11812. objectWriteUInt16(this, value, offset, false)
  11813. }
  11814. return offset + 2
  11815. }
  11816. Buffer.prototype.writeInt32LE = function writeInt32LE (value, offset, noAssert) {
  11817. value = +value
  11818. offset = offset | 0
  11819. if (!noAssert) checkInt(this, value, offset, 4, 0x7fffffff, -0x80000000)
  11820. if (Buffer.TYPED_ARRAY_SUPPORT) {
  11821. this[offset] = (value & 0xff)
  11822. this[offset + 1] = (value >>> 8)
  11823. this[offset + 2] = (value >>> 16)
  11824. this[offset + 3] = (value >>> 24)
  11825. } else {
  11826. objectWriteUInt32(this, value, offset, true)
  11827. }
  11828. return offset + 4
  11829. }
  11830. Buffer.prototype.writeInt32BE = function writeInt32BE (value, offset, noAssert) {
  11831. value = +value
  11832. offset = offset | 0
  11833. if (!noAssert) checkInt(this, value, offset, 4, 0x7fffffff, -0x80000000)
  11834. if (value < 0) value = 0xffffffff + value + 1
  11835. if (Buffer.TYPED_ARRAY_SUPPORT) {
  11836. this[offset] = (value >>> 24)
  11837. this[offset + 1] = (value >>> 16)
  11838. this[offset + 2] = (value >>> 8)
  11839. this[offset + 3] = (value & 0xff)
  11840. } else {
  11841. objectWriteUInt32(this, value, offset, false)
  11842. }
  11843. return offset + 4
  11844. }
  11845. function checkIEEE754 (buf, value, offset, ext, max, min) {
  11846. if (offset + ext > buf.length) throw new RangeError('Index out of range')
  11847. if (offset < 0) throw new RangeError('Index out of range')
  11848. }
  11849. function writeFloat (buf, value, offset, littleEndian, noAssert) {
  11850. if (!noAssert) {
  11851. checkIEEE754(buf, value, offset, 4, 3.4028234663852886e+38, -3.4028234663852886e+38)
  11852. }
  11853. ieee754.write(buf, value, offset, littleEndian, 23, 4)
  11854. return offset + 4
  11855. }
  11856. Buffer.prototype.writeFloatLE = function writeFloatLE (value, offset, noAssert) {
  11857. return writeFloat(this, value, offset, true, noAssert)
  11858. }
  11859. Buffer.prototype.writeFloatBE = function writeFloatBE (value, offset, noAssert) {
  11860. return writeFloat(this, value, offset, false, noAssert)
  11861. }
  11862. function writeDouble (buf, value, offset, littleEndian, noAssert) {
  11863. if (!noAssert) {
  11864. checkIEEE754(buf, value, offset, 8, 1.7976931348623157E+308, -1.7976931348623157E+308)
  11865. }
  11866. ieee754.write(buf, value, offset, littleEndian, 52, 8)
  11867. return offset + 8
  11868. }
  11869. Buffer.prototype.writeDoubleLE = function writeDoubleLE (value, offset, noAssert) {
  11870. return writeDouble(this, value, offset, true, noAssert)
  11871. }
  11872. Buffer.prototype.writeDoubleBE = function writeDoubleBE (value, offset, noAssert) {
  11873. return writeDouble(this, value, offset, false, noAssert)
  11874. }
  11875. // copy(targetBuffer, targetStart=0, sourceStart=0, sourceEnd=buffer.length)
  11876. Buffer.prototype.copy = function copy (target, targetStart, start, end) {
  11877. if (!start) start = 0
  11878. if (!end && end !== 0) end = this.length
  11879. if (targetStart >= target.length) targetStart = target.length
  11880. if (!targetStart) targetStart = 0
  11881. if (end > 0 && end < start) end = start
  11882. // Copy 0 bytes; we're done
  11883. if (end === start) return 0
  11884. if (target.length === 0 || this.length === 0) return 0
  11885. // Fatal error conditions
  11886. if (targetStart < 0) {
  11887. throw new RangeError('targetStart out of bounds')
  11888. }
  11889. if (start < 0 || start >= this.length) throw new RangeError('sourceStart out of bounds')
  11890. if (end < 0) throw new RangeError('sourceEnd out of bounds')
  11891. // Are we oob?
  11892. if (end > this.length) end = this.length
  11893. if (target.length - targetStart < end - start) {
  11894. end = target.length - targetStart + start
  11895. }
  11896. var len = end - start
  11897. var i
  11898. if (this === target && start < targetStart && targetStart < end) {
  11899. // descending copy from end
  11900. for (i = len - 1; i >= 0; --i) {
  11901. target[i + targetStart] = this[i + start]
  11902. }
  11903. } else if (len < 1000 || !Buffer.TYPED_ARRAY_SUPPORT) {
  11904. // ascending copy from start
  11905. for (i = 0; i < len; ++i) {
  11906. target[i + targetStart] = this[i + start]
  11907. }
  11908. } else {
  11909. Uint8Array.prototype.set.call(
  11910. target,
  11911. this.subarray(start, start + len),
  11912. targetStart
  11913. )
  11914. }
  11915. return len
  11916. }
  11917. // Usage:
  11918. // buffer.fill(number[, offset[, end]])
  11919. // buffer.fill(buffer[, offset[, end]])
  11920. // buffer.fill(string[, offset[, end]][, encoding])
  11921. Buffer.prototype.fill = function fill (val, start, end, encoding) {
  11922. // Handle string cases:
  11923. if (typeof val === 'string') {
  11924. if (typeof start === 'string') {
  11925. encoding = start
  11926. start = 0
  11927. end = this.length
  11928. } else if (typeof end === 'string') {
  11929. encoding = end
  11930. end = this.length
  11931. }
  11932. if (val.length === 1) {
  11933. var code = val.charCodeAt(0)
  11934. if (code < 256) {
  11935. val = code
  11936. }
  11937. }
  11938. if (encoding !== undefined && typeof encoding !== 'string') {
  11939. throw new TypeError('encoding must be a string')
  11940. }
  11941. if (typeof encoding === 'string' && !Buffer.isEncoding(encoding)) {
  11942. throw new TypeError('Unknown encoding: ' + encoding)
  11943. }
  11944. } else if (typeof val === 'number') {
  11945. val = val & 255
  11946. }
  11947. // Invalid ranges are not set to a default, so can range check early.
  11948. if (start < 0 || this.length < start || this.length < end) {
  11949. throw new RangeError('Out of range index')
  11950. }
  11951. if (end <= start) {
  11952. return this
  11953. }
  11954. start = start >>> 0
  11955. end = end === undefined ? this.length : end >>> 0
  11956. if (!val) val = 0
  11957. var i
  11958. if (typeof val === 'number') {
  11959. for (i = start; i < end; ++i) {
  11960. this[i] = val
  11961. }
  11962. } else {
  11963. var bytes = Buffer.isBuffer(val)
  11964. ? val
  11965. : utf8ToBytes(new Buffer(val, encoding).toString())
  11966. var len = bytes.length
  11967. for (i = 0; i < end - start; ++i) {
  11968. this[i + start] = bytes[i % len]
  11969. }
  11970. }
  11971. return this
  11972. }
  11973. // HELPER FUNCTIONS
  11974. // ================
  11975. var INVALID_BASE64_RE = /[^+\/0-9A-Za-z-_]/g
  11976. function base64clean (str) {
  11977. // Node strips out invalid characters like \n and \t from the string, base64-js does not
  11978. str = stringtrim(str).replace(INVALID_BASE64_RE, '')
  11979. // Node converts strings with length < 2 to ''
  11980. if (str.length < 2) return ''
  11981. // Node allows for non-padded base64 strings (missing trailing ===), base64-js does not
  11982. while (str.length % 4 !== 0) {
  11983. str = str + '='
  11984. }
  11985. return str
  11986. }
  11987. function stringtrim (str) {
  11988. if (str.trim) return str.trim()
  11989. return str.replace(/^\s+|\s+$/g, '')
  11990. }
  11991. function toHex (n) {
  11992. if (n < 16) return '0' + n.toString(16)
  11993. return n.toString(16)
  11994. }
  11995. function utf8ToBytes (string, units) {
  11996. units = units || Infinity
  11997. var codePoint
  11998. var length = string.length
  11999. var leadSurrogate = null
  12000. var bytes = []
  12001. for (var i = 0; i < length; ++i) {
  12002. codePoint = string.charCodeAt(i)
  12003. // is surrogate component
  12004. if (codePoint > 0xD7FF && codePoint < 0xE000) {
  12005. // last char was a lead
  12006. if (!leadSurrogate) {
  12007. // no lead yet
  12008. if (codePoint > 0xDBFF) {
  12009. // unexpected trail
  12010. if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD)
  12011. continue
  12012. } else if (i + 1 === length) {
  12013. // unpaired lead
  12014. if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD)
  12015. continue
  12016. }
  12017. // valid lead
  12018. leadSurrogate = codePoint
  12019. continue
  12020. }
  12021. // 2 leads in a row
  12022. if (codePoint < 0xDC00) {
  12023. if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD)
  12024. leadSurrogate = codePoint
  12025. continue
  12026. }
  12027. // valid surrogate pair
  12028. codePoint = (leadSurrogate - 0xD800 << 10 | codePoint - 0xDC00) + 0x10000
  12029. } else if (leadSurrogate) {
  12030. // valid bmp char, but last char was a lead
  12031. if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD)
  12032. }
  12033. leadSurrogate = null
  12034. // encode utf8
  12035. if (codePoint < 0x80) {
  12036. if ((units -= 1) < 0) break
  12037. bytes.push(codePoint)
  12038. } else if (codePoint < 0x800) {
  12039. if ((units -= 2) < 0) break
  12040. bytes.push(
  12041. codePoint >> 0x6 | 0xC0,
  12042. codePoint & 0x3F | 0x80
  12043. )
  12044. } else if (codePoint < 0x10000) {
  12045. if ((units -= 3) < 0) break
  12046. bytes.push(
  12047. codePoint >> 0xC | 0xE0,
  12048. codePoint >> 0x6 & 0x3F | 0x80,
  12049. codePoint & 0x3F | 0x80
  12050. )
  12051. } else if (codePoint < 0x110000) {
  12052. if ((units -= 4) < 0) break
  12053. bytes.push(
  12054. codePoint >> 0x12 | 0xF0,
  12055. codePoint >> 0xC & 0x3F | 0x80,
  12056. codePoint >> 0x6 & 0x3F | 0x80,
  12057. codePoint & 0x3F | 0x80
  12058. )
  12059. } else {
  12060. throw new Error('Invalid code point')
  12061. }
  12062. }
  12063. return bytes
  12064. }
  12065. function asciiToBytes (str) {
  12066. var byteArray = []
  12067. for (var i = 0; i < str.length; ++i) {
  12068. // Node's code seems to be doing this and not & 0x7F..
  12069. byteArray.push(str.charCodeAt(i) & 0xFF)
  12070. }
  12071. return byteArray
  12072. }
  12073. function utf16leToBytes (str, units) {
  12074. var c, hi, lo
  12075. var byteArray = []
  12076. for (var i = 0; i < str.length; ++i) {
  12077. if ((units -= 2) < 0) break
  12078. c = str.charCodeAt(i)
  12079. hi = c >> 8
  12080. lo = c % 256
  12081. byteArray.push(lo)
  12082. byteArray.push(hi)
  12083. }
  12084. return byteArray
  12085. }
  12086. function base64ToBytes (str) {
  12087. return base64.toByteArray(base64clean(str))
  12088. }
  12089. function blitBuffer (src, dst, offset, length) {
  12090. for (var i = 0; i < length; ++i) {
  12091. if ((i + offset >= dst.length) || (i >= src.length)) break
  12092. dst[i + offset] = src[i]
  12093. }
  12094. return i
  12095. }
  12096. function isnan (val) {
  12097. return val !== val // eslint-disable-line no-self-compare
  12098. }
  12099. /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./../webpack/buildin/global.js */ 2)))
  12100. /***/ }),
  12101. /* 50 */
  12102. /*!*****************************************!*\
  12103. !*** ./node_modules/base64-js/index.js ***!
  12104. \*****************************************/
  12105. /*! no static exports found */
  12106. /***/ (function(module, exports, __webpack_require__) {
  12107. "use strict";
  12108. exports.byteLength = byteLength
  12109. exports.toByteArray = toByteArray
  12110. exports.fromByteArray = fromByteArray
  12111. var lookup = []
  12112. var revLookup = []
  12113. var Arr = typeof Uint8Array !== 'undefined' ? Uint8Array : Array
  12114. var code = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/'
  12115. for (var i = 0, len = code.length; i < len; ++i) {
  12116. lookup[i] = code[i]
  12117. revLookup[code.charCodeAt(i)] = i
  12118. }
  12119. // Support decoding URL-safe base64 strings, as Node.js does.
  12120. // See: https://en.wikipedia.org/wiki/Base64#URL_applications
  12121. revLookup['-'.charCodeAt(0)] = 62
  12122. revLookup['_'.charCodeAt(0)] = 63
  12123. function getLens (b64) {
  12124. var len = b64.length
  12125. if (len % 4 > 0) {
  12126. throw new Error('Invalid string. Length must be a multiple of 4')
  12127. }
  12128. // Trim off extra bytes after placeholder bytes are found
  12129. // See: https://github.com/beatgammit/base64-js/issues/42
  12130. var validLen = b64.indexOf('=')
  12131. if (validLen === -1) validLen = len
  12132. var placeHoldersLen = validLen === len
  12133. ? 0
  12134. : 4 - (validLen % 4)
  12135. return [validLen, placeHoldersLen]
  12136. }
  12137. // base64 is 4/3 + up to two characters of the original data
  12138. function byteLength (b64) {
  12139. var lens = getLens(b64)
  12140. var validLen = lens[0]
  12141. var placeHoldersLen = lens[1]
  12142. return ((validLen + placeHoldersLen) * 3 / 4) - placeHoldersLen
  12143. }
  12144. function _byteLength (b64, validLen, placeHoldersLen) {
  12145. return ((validLen + placeHoldersLen) * 3 / 4) - placeHoldersLen
  12146. }
  12147. function toByteArray (b64) {
  12148. var tmp
  12149. var lens = getLens(b64)
  12150. var validLen = lens[0]
  12151. var placeHoldersLen = lens[1]
  12152. var arr = new Arr(_byteLength(b64, validLen, placeHoldersLen))
  12153. var curByte = 0
  12154. // if there are placeholders, only get up to the last complete 4 chars
  12155. var len = placeHoldersLen > 0
  12156. ? validLen - 4
  12157. : validLen
  12158. var i
  12159. for (i = 0; i < len; i += 4) {
  12160. tmp =
  12161. (revLookup[b64.charCodeAt(i)] << 18) |
  12162. (revLookup[b64.charCodeAt(i + 1)] << 12) |
  12163. (revLookup[b64.charCodeAt(i + 2)] << 6) |
  12164. revLookup[b64.charCodeAt(i + 3)]
  12165. arr[curByte++] = (tmp >> 16) & 0xFF
  12166. arr[curByte++] = (tmp >> 8) & 0xFF
  12167. arr[curByte++] = tmp & 0xFF
  12168. }
  12169. if (placeHoldersLen === 2) {
  12170. tmp =
  12171. (revLookup[b64.charCodeAt(i)] << 2) |
  12172. (revLookup[b64.charCodeAt(i + 1)] >> 4)
  12173. arr[curByte++] = tmp & 0xFF
  12174. }
  12175. if (placeHoldersLen === 1) {
  12176. tmp =
  12177. (revLookup[b64.charCodeAt(i)] << 10) |
  12178. (revLookup[b64.charCodeAt(i + 1)] << 4) |
  12179. (revLookup[b64.charCodeAt(i + 2)] >> 2)
  12180. arr[curByte++] = (tmp >> 8) & 0xFF
  12181. arr[curByte++] = tmp & 0xFF
  12182. }
  12183. return arr
  12184. }
  12185. function tripletToBase64 (num) {
  12186. return lookup[num >> 18 & 0x3F] +
  12187. lookup[num >> 12 & 0x3F] +
  12188. lookup[num >> 6 & 0x3F] +
  12189. lookup[num & 0x3F]
  12190. }
  12191. function encodeChunk (uint8, start, end) {
  12192. var tmp
  12193. var output = []
  12194. for (var i = start; i < end; i += 3) {
  12195. tmp =
  12196. ((uint8[i] << 16) & 0xFF0000) +
  12197. ((uint8[i + 1] << 8) & 0xFF00) +
  12198. (uint8[i + 2] & 0xFF)
  12199. output.push(tripletToBase64(tmp))
  12200. }
  12201. return output.join('')
  12202. }
  12203. function fromByteArray (uint8) {
  12204. var tmp
  12205. var len = uint8.length
  12206. var extraBytes = len % 3 // if we have 1 byte left, pad 2 bytes
  12207. var parts = []
  12208. var maxChunkLength = 16383 // must be multiple of 3
  12209. // go through the array every three bytes, we'll deal with trailing stuff later
  12210. for (var i = 0, len2 = len - extraBytes; i < len2; i += maxChunkLength) {
  12211. parts.push(encodeChunk(uint8, i, (i + maxChunkLength) > len2 ? len2 : (i + maxChunkLength)))
  12212. }
  12213. // pad the end with zeros, but make sure to not forget the extra bytes
  12214. if (extraBytes === 1) {
  12215. tmp = uint8[len - 1]
  12216. parts.push(
  12217. lookup[tmp >> 2] +
  12218. lookup[(tmp << 4) & 0x3F] +
  12219. '=='
  12220. )
  12221. } else if (extraBytes === 2) {
  12222. tmp = (uint8[len - 2] << 8) + uint8[len - 1]
  12223. parts.push(
  12224. lookup[tmp >> 10] +
  12225. lookup[(tmp >> 4) & 0x3F] +
  12226. lookup[(tmp << 2) & 0x3F] +
  12227. '='
  12228. )
  12229. }
  12230. return parts.join('')
  12231. }
  12232. /***/ }),
  12233. /* 51 */
  12234. /*!***************************************!*\
  12235. !*** ./node_modules/ieee754/index.js ***!
  12236. \***************************************/
  12237. /*! no static exports found */
  12238. /***/ (function(module, exports) {
  12239. /*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */
  12240. exports.read = function (buffer, offset, isLE, mLen, nBytes) {
  12241. var e, m
  12242. var eLen = (nBytes * 8) - mLen - 1
  12243. var eMax = (1 << eLen) - 1
  12244. var eBias = eMax >> 1
  12245. var nBits = -7
  12246. var i = isLE ? (nBytes - 1) : 0
  12247. var d = isLE ? -1 : 1
  12248. var s = buffer[offset + i]
  12249. i += d
  12250. e = s & ((1 << (-nBits)) - 1)
  12251. s >>= (-nBits)
  12252. nBits += eLen
  12253. for (; nBits > 0; e = (e * 256) + buffer[offset + i], i += d, nBits -= 8) {}
  12254. m = e & ((1 << (-nBits)) - 1)
  12255. e >>= (-nBits)
  12256. nBits += mLen
  12257. for (; nBits > 0; m = (m * 256) + buffer[offset + i], i += d, nBits -= 8) {}
  12258. if (e === 0) {
  12259. e = 1 - eBias
  12260. } else if (e === eMax) {
  12261. return m ? NaN : ((s ? -1 : 1) * Infinity)
  12262. } else {
  12263. m = m + Math.pow(2, mLen)
  12264. e = e - eBias
  12265. }
  12266. return (s ? -1 : 1) * m * Math.pow(2, e - mLen)
  12267. }
  12268. exports.write = function (buffer, value, offset, isLE, mLen, nBytes) {
  12269. var e, m, c
  12270. var eLen = (nBytes * 8) - mLen - 1
  12271. var eMax = (1 << eLen) - 1
  12272. var eBias = eMax >> 1
  12273. var rt = (mLen === 23 ? Math.pow(2, -24) - Math.pow(2, -77) : 0)
  12274. var i = isLE ? 0 : (nBytes - 1)
  12275. var d = isLE ? 1 : -1
  12276. var s = value < 0 || (value === 0 && 1 / value < 0) ? 1 : 0
  12277. value = Math.abs(value)
  12278. if (isNaN(value) || value === Infinity) {
  12279. m = isNaN(value) ? 1 : 0
  12280. e = eMax
  12281. } else {
  12282. e = Math.floor(Math.log(value) / Math.LN2)
  12283. if (value * (c = Math.pow(2, -e)) < 1) {
  12284. e--
  12285. c *= 2
  12286. }
  12287. if (e + eBias >= 1) {
  12288. value += rt / c
  12289. } else {
  12290. value += rt * Math.pow(2, 1 - eBias)
  12291. }
  12292. if (value * c >= 2) {
  12293. e++
  12294. c /= 2
  12295. }
  12296. if (e + eBias >= eMax) {
  12297. m = 0
  12298. e = eMax
  12299. } else if (e + eBias >= 1) {
  12300. m = ((value * c) - 1) * Math.pow(2, mLen)
  12301. e = e + eBias
  12302. } else {
  12303. m = value * Math.pow(2, eBias - 1) * Math.pow(2, mLen)
  12304. e = 0
  12305. }
  12306. }
  12307. for (; mLen >= 8; buffer[offset + i] = m & 0xff, i += d, m /= 256, mLen -= 8) {}
  12308. e = (e << mLen) | m
  12309. eLen += mLen
  12310. for (; eLen > 0; buffer[offset + i] = e & 0xff, i += d, e /= 256, eLen -= 8) {}
  12311. buffer[offset + i - d] |= s * 128
  12312. }
  12313. /***/ }),
  12314. /* 52 */
  12315. /*!***************************************!*\
  12316. !*** ./node_modules/isarray/index.js ***!
  12317. \***************************************/
  12318. /*! no static exports found */
  12319. /***/ (function(module, exports) {
  12320. var toString = {}.toString;
  12321. module.exports = Array.isArray || function (arr) {
  12322. return toString.call(arr) == '[object Array]';
  12323. };
  12324. /***/ }),
  12325. /* 53 */
  12326. /*!******************************************************************************!*\
  12327. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/util/route.js ***!
  12328. \******************************************************************************/
  12329. /*! no static exports found */
  12330. /***/ (function(module, exports, __webpack_require__) {
  12331. "use strict";
  12332. /* WEBPACK VAR INJECTION */(function(uni) {
  12333. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  12334. Object.defineProperty(exports, "__esModule", {
  12335. value: true
  12336. });
  12337. exports.default = void 0;
  12338. var _regenerator = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/regenerator */ 54));
  12339. var _asyncToGenerator2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/asyncToGenerator */ 56));
  12340. var _classCallCheck2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/classCallCheck */ 17));
  12341. var _createClass2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/createClass */ 18));
  12342. /**
  12343. * 路由跳转方法,该方法相对于直接使用uni.xxx的好处是使用更加简单快捷
  12344. * 并且带有路由拦截功能
  12345. */
  12346. var Router = /*#__PURE__*/function () {
  12347. function Router() {
  12348. (0, _classCallCheck2.default)(this, Router);
  12349. // 原始属性定义
  12350. this.config = {
  12351. type: 'navigateTo',
  12352. url: '',
  12353. delta: 1,
  12354. // navigateBack页面后退时,回退的层数
  12355. params: {},
  12356. // 传递的参数
  12357. animationType: 'pop-in',
  12358. // 窗口动画,只在APP有效
  12359. animationDuration: 300,
  12360. // 窗口动画持续时间,单位毫秒,只在APP有效
  12361. intercept: false // 是否需要拦截
  12362. };
  12363. // 因为route方法是需要对外赋值给另外的对象使用,同时route内部有使用this,会导致route失去上下文
  12364. // 这里在构造函数中进行this绑定
  12365. this.route = this.route.bind(this);
  12366. }
  12367. // 判断url前面是否有"/",如果没有则加上,否则无法跳转
  12368. (0, _createClass2.default)(Router, [{
  12369. key: "addRootPath",
  12370. value: function addRootPath(url) {
  12371. return url[0] === '/' ? url : "/".concat(url);
  12372. }
  12373. // 整合路由参数
  12374. }, {
  12375. key: "mixinParam",
  12376. value: function mixinParam(url, params) {
  12377. url = url && this.addRootPath(url);
  12378. // 使用正则匹配,主要依据是判断是否有"/","?","="等,如“/page/index/index?name=mary"
  12379. // 如果有url中有get参数,转换后无需带上"?"
  12380. var query = '';
  12381. if (/.*\/.*\?.*=.*/.test(url)) {
  12382. // object对象转为get类型的参数
  12383. query = uni.$u.queryParams(params, false);
  12384. // 因为已有get参数,所以后面拼接的参数需要带上"&"隔开
  12385. return url += "&".concat(query);
  12386. }
  12387. // 直接拼接参数,因为此处url中没有后面的query参数,也就没有"?/&"之类的符号
  12388. query = uni.$u.queryParams(params);
  12389. return url += query;
  12390. }
  12391. // 对外的方法名称
  12392. }, {
  12393. key: "route",
  12394. value: function () {
  12395. var _route = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee() {
  12396. var options,
  12397. params,
  12398. mergeConfig,
  12399. isNext,
  12400. _args = arguments;
  12401. return _regenerator.default.wrap(function _callee$(_context) {
  12402. while (1) {
  12403. switch (_context.prev = _context.next) {
  12404. case 0:
  12405. options = _args.length > 0 && _args[0] !== undefined ? _args[0] : {};
  12406. params = _args.length > 1 && _args[1] !== undefined ? _args[1] : {};
  12407. // 合并用户的配置和内部的默认配置
  12408. mergeConfig = {};
  12409. if (typeof options === 'string') {
  12410. // 如果options为字符串,则为route(url, params)的形式
  12411. mergeConfig.url = this.mixinParam(options, params);
  12412. mergeConfig.type = 'navigateTo';
  12413. } else {
  12414. mergeConfig = uni.$u.deepMerge(this.config, options);
  12415. // 否则正常使用mergeConfig中的url和params进行拼接
  12416. mergeConfig.url = this.mixinParam(options.url, options.params);
  12417. }
  12418. // 如果本次跳转的路径和本页面路径一致,不执行跳转,防止用户快速点击跳转按钮,造成多次跳转同一个页面的问题
  12419. if (!(mergeConfig.url === uni.$u.page())) {
  12420. _context.next = 6;
  12421. break;
  12422. }
  12423. return _context.abrupt("return");
  12424. case 6:
  12425. if (params.intercept) {
  12426. this.config.intercept = params.intercept;
  12427. }
  12428. // params参数也带给拦截器
  12429. mergeConfig.params = params;
  12430. // 合并内外部参数
  12431. mergeConfig = uni.$u.deepMerge(this.config, mergeConfig);
  12432. // 判断用户是否定义了拦截器
  12433. if (!(typeof uni.$u.routeIntercept === 'function')) {
  12434. _context.next = 16;
  12435. break;
  12436. }
  12437. _context.next = 12;
  12438. return new Promise(function (resolve, reject) {
  12439. uni.$u.routeIntercept(mergeConfig, resolve);
  12440. });
  12441. case 12:
  12442. isNext = _context.sent;
  12443. // 如果isNext为true,则执行路由跳转
  12444. isNext && this.openPage(mergeConfig);
  12445. _context.next = 17;
  12446. break;
  12447. case 16:
  12448. this.openPage(mergeConfig);
  12449. case 17:
  12450. case "end":
  12451. return _context.stop();
  12452. }
  12453. }
  12454. }, _callee, this);
  12455. }));
  12456. function route() {
  12457. return _route.apply(this, arguments);
  12458. }
  12459. return route;
  12460. }() // 执行路由跳转
  12461. }, {
  12462. key: "openPage",
  12463. value: function openPage(config) {
  12464. // 解构参数
  12465. var url = config.url,
  12466. type = config.type,
  12467. delta = config.delta,
  12468. animationType = config.animationType,
  12469. animationDuration = config.animationDuration;
  12470. if (config.type == 'navigateTo' || config.type == 'to') {
  12471. uni.navigateTo({
  12472. url: url,
  12473. animationType: animationType,
  12474. animationDuration: animationDuration
  12475. });
  12476. }
  12477. if (config.type == 'redirectTo' || config.type == 'redirect') {
  12478. uni.redirectTo({
  12479. url: url
  12480. });
  12481. }
  12482. if (config.type == 'switchTab' || config.type == 'tab') {
  12483. uni.switchTab({
  12484. url: url
  12485. });
  12486. }
  12487. if (config.type == 'reLaunch' || config.type == 'launch') {
  12488. uni.reLaunch({
  12489. url: url
  12490. });
  12491. }
  12492. if (config.type == 'navigateBack' || config.type == 'back') {
  12493. uni.navigateBack({
  12494. delta: delta
  12495. });
  12496. }
  12497. }
  12498. }]);
  12499. return Router;
  12500. }();
  12501. var _default = new Router().route;
  12502. exports.default = _default;
  12503. /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./node_modules/@dcloudio/uni-mp-toutiao/dist/index.js */ 1)["default"]))
  12504. /***/ }),
  12505. /* 54 */
  12506. /*!************************************************************************************************!*\
  12507. !*** ./node_modules/@dcloudio/vue-cli-plugin-uni/packages/@babel/runtime/regenerator/index.js ***!
  12508. \************************************************************************************************/
  12509. /*! no static exports found */
  12510. /***/ (function(module, exports, __webpack_require__) {
  12511. // TODO(Babel 8): Remove this file.
  12512. var runtime = __webpack_require__(/*! @babel/runtime/helpers/regeneratorRuntime */ 55)();
  12513. module.exports = runtime;
  12514. /***/ }),
  12515. /* 55 */
  12516. /*!*******************************************************************!*\
  12517. !*** ./node_modules/@babel/runtime/helpers/regeneratorRuntime.js ***!
  12518. \*******************************************************************/
  12519. /*! no static exports found */
  12520. /***/ (function(module, exports, __webpack_require__) {
  12521. var _typeof = __webpack_require__(/*! ./typeof.js */ 12)["default"];
  12522. function _regeneratorRuntime() {
  12523. "use strict";
  12524. /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */
  12525. module.exports = _regeneratorRuntime = function _regeneratorRuntime() {
  12526. return e;
  12527. }, module.exports.__esModule = true, module.exports["default"] = module.exports;
  12528. var t,
  12529. e = {},
  12530. r = Object.prototype,
  12531. n = r.hasOwnProperty,
  12532. o = Object.defineProperty || function (t, e, r) {
  12533. t[e] = r.value;
  12534. },
  12535. i = "function" == typeof Symbol ? Symbol : {},
  12536. a = i.iterator || "@@iterator",
  12537. c = i.asyncIterator || "@@asyncIterator",
  12538. u = i.toStringTag || "@@toStringTag";
  12539. function define(t, e, r) {
  12540. return Object.defineProperty(t, e, {
  12541. value: r,
  12542. enumerable: !0,
  12543. configurable: !0,
  12544. writable: !0
  12545. }), t[e];
  12546. }
  12547. try {
  12548. define({}, "");
  12549. } catch (t) {
  12550. define = function define(t, e, r) {
  12551. return t[e] = r;
  12552. };
  12553. }
  12554. function wrap(t, e, r, n) {
  12555. var i = e && e.prototype instanceof Generator ? e : Generator,
  12556. a = Object.create(i.prototype),
  12557. c = new Context(n || []);
  12558. return o(a, "_invoke", {
  12559. value: makeInvokeMethod(t, r, c)
  12560. }), a;
  12561. }
  12562. function tryCatch(t, e, r) {
  12563. try {
  12564. return {
  12565. type: "normal",
  12566. arg: t.call(e, r)
  12567. };
  12568. } catch (t) {
  12569. return {
  12570. type: "throw",
  12571. arg: t
  12572. };
  12573. }
  12574. }
  12575. e.wrap = wrap;
  12576. var h = "suspendedStart",
  12577. l = "suspendedYield",
  12578. f = "executing",
  12579. s = "completed",
  12580. y = {};
  12581. function Generator() {}
  12582. function GeneratorFunction() {}
  12583. function GeneratorFunctionPrototype() {}
  12584. var p = {};
  12585. define(p, a, function () {
  12586. return this;
  12587. });
  12588. var d = Object.getPrototypeOf,
  12589. v = d && d(d(values([])));
  12590. v && v !== r && n.call(v, a) && (p = v);
  12591. var g = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(p);
  12592. function defineIteratorMethods(t) {
  12593. ["next", "throw", "return"].forEach(function (e) {
  12594. define(t, e, function (t) {
  12595. return this._invoke(e, t);
  12596. });
  12597. });
  12598. }
  12599. function AsyncIterator(t, e) {
  12600. function invoke(r, o, i, a) {
  12601. var c = tryCatch(t[r], t, o);
  12602. if ("throw" !== c.type) {
  12603. var u = c.arg,
  12604. h = u.value;
  12605. return h && "object" == _typeof(h) && n.call(h, "__await") ? e.resolve(h.__await).then(function (t) {
  12606. invoke("next", t, i, a);
  12607. }, function (t) {
  12608. invoke("throw", t, i, a);
  12609. }) : e.resolve(h).then(function (t) {
  12610. u.value = t, i(u);
  12611. }, function (t) {
  12612. return invoke("throw", t, i, a);
  12613. });
  12614. }
  12615. a(c.arg);
  12616. }
  12617. var r;
  12618. o(this, "_invoke", {
  12619. value: function value(t, n) {
  12620. function callInvokeWithMethodAndArg() {
  12621. return new e(function (e, r) {
  12622. invoke(t, n, e, r);
  12623. });
  12624. }
  12625. return r = r ? r.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg();
  12626. }
  12627. });
  12628. }
  12629. function makeInvokeMethod(e, r, n) {
  12630. var o = h;
  12631. return function (i, a) {
  12632. if (o === f) throw Error("Generator is already running");
  12633. if (o === s) {
  12634. if ("throw" === i) throw a;
  12635. return {
  12636. value: t,
  12637. done: !0
  12638. };
  12639. }
  12640. for (n.method = i, n.arg = a;;) {
  12641. var c = n.delegate;
  12642. if (c) {
  12643. var u = maybeInvokeDelegate(c, n);
  12644. if (u) {
  12645. if (u === y) continue;
  12646. return u;
  12647. }
  12648. }
  12649. if ("next" === n.method) n.sent = n._sent = n.arg;else if ("throw" === n.method) {
  12650. if (o === h) throw o = s, n.arg;
  12651. n.dispatchException(n.arg);
  12652. } else "return" === n.method && n.abrupt("return", n.arg);
  12653. o = f;
  12654. var p = tryCatch(e, r, n);
  12655. if ("normal" === p.type) {
  12656. if (o = n.done ? s : l, p.arg === y) continue;
  12657. return {
  12658. value: p.arg,
  12659. done: n.done
  12660. };
  12661. }
  12662. "throw" === p.type && (o = s, n.method = "throw", n.arg = p.arg);
  12663. }
  12664. };
  12665. }
  12666. function maybeInvokeDelegate(e, r) {
  12667. var n = r.method,
  12668. o = e.iterator[n];
  12669. if (o === t) return r.delegate = null, "throw" === n && e.iterator["return"] && (r.method = "return", r.arg = t, maybeInvokeDelegate(e, r), "throw" === r.method) || "return" !== n && (r.method = "throw", r.arg = new TypeError("The iterator does not provide a '" + n + "' method")), y;
  12670. var i = tryCatch(o, e.iterator, r.arg);
  12671. if ("throw" === i.type) return r.method = "throw", r.arg = i.arg, r.delegate = null, y;
  12672. var a = i.arg;
  12673. return a ? a.done ? (r[e.resultName] = a.value, r.next = e.nextLoc, "return" !== r.method && (r.method = "next", r.arg = t), r.delegate = null, y) : a : (r.method = "throw", r.arg = new TypeError("iterator result is not an object"), r.delegate = null, y);
  12674. }
  12675. function pushTryEntry(t) {
  12676. var e = {
  12677. tryLoc: t[0]
  12678. };
  12679. 1 in t && (e.catchLoc = t[1]), 2 in t && (e.finallyLoc = t[2], e.afterLoc = t[3]), this.tryEntries.push(e);
  12680. }
  12681. function resetTryEntry(t) {
  12682. var e = t.completion || {};
  12683. e.type = "normal", delete e.arg, t.completion = e;
  12684. }
  12685. function Context(t) {
  12686. this.tryEntries = [{
  12687. tryLoc: "root"
  12688. }], t.forEach(pushTryEntry, this), this.reset(!0);
  12689. }
  12690. function values(e) {
  12691. if (e || "" === e) {
  12692. var r = e[a];
  12693. if (r) return r.call(e);
  12694. if ("function" == typeof e.next) return e;
  12695. if (!isNaN(e.length)) {
  12696. var o = -1,
  12697. i = function next() {
  12698. for (; ++o < e.length;) {
  12699. if (n.call(e, o)) return next.value = e[o], next.done = !1, next;
  12700. }
  12701. return next.value = t, next.done = !0, next;
  12702. };
  12703. return i.next = i;
  12704. }
  12705. }
  12706. throw new TypeError(_typeof(e) + " is not iterable");
  12707. }
  12708. return GeneratorFunction.prototype = GeneratorFunctionPrototype, o(g, "constructor", {
  12709. value: GeneratorFunctionPrototype,
  12710. configurable: !0
  12711. }), o(GeneratorFunctionPrototype, "constructor", {
  12712. value: GeneratorFunction,
  12713. configurable: !0
  12714. }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, u, "GeneratorFunction"), e.isGeneratorFunction = function (t) {
  12715. var e = "function" == typeof t && t.constructor;
  12716. return !!e && (e === GeneratorFunction || "GeneratorFunction" === (e.displayName || e.name));
  12717. }, e.mark = function (t) {
  12718. return Object.setPrototypeOf ? Object.setPrototypeOf(t, GeneratorFunctionPrototype) : (t.__proto__ = GeneratorFunctionPrototype, define(t, u, "GeneratorFunction")), t.prototype = Object.create(g), t;
  12719. }, e.awrap = function (t) {
  12720. return {
  12721. __await: t
  12722. };
  12723. }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, c, function () {
  12724. return this;
  12725. }), e.AsyncIterator = AsyncIterator, e.async = function (t, r, n, o, i) {
  12726. void 0 === i && (i = Promise);
  12727. var a = new AsyncIterator(wrap(t, r, n, o), i);
  12728. return e.isGeneratorFunction(r) ? a : a.next().then(function (t) {
  12729. return t.done ? t.value : a.next();
  12730. });
  12731. }, defineIteratorMethods(g), define(g, u, "Generator"), define(g, a, function () {
  12732. return this;
  12733. }), define(g, "toString", function () {
  12734. return "[object Generator]";
  12735. }), e.keys = function (t) {
  12736. var e = Object(t),
  12737. r = [];
  12738. for (var n in e) {
  12739. r.push(n);
  12740. }
  12741. return r.reverse(), function next() {
  12742. for (; r.length;) {
  12743. var t = r.pop();
  12744. if (t in e) return next.value = t, next.done = !1, next;
  12745. }
  12746. return next.done = !0, next;
  12747. };
  12748. }, e.values = values, Context.prototype = {
  12749. constructor: Context,
  12750. reset: function reset(e) {
  12751. if (this.prev = 0, this.next = 0, this.sent = this._sent = t, this.done = !1, this.delegate = null, this.method = "next", this.arg = t, this.tryEntries.forEach(resetTryEntry), !e) for (var r in this) {
  12752. "t" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = t);
  12753. }
  12754. },
  12755. stop: function stop() {
  12756. this.done = !0;
  12757. var t = this.tryEntries[0].completion;
  12758. if ("throw" === t.type) throw t.arg;
  12759. return this.rval;
  12760. },
  12761. dispatchException: function dispatchException(e) {
  12762. if (this.done) throw e;
  12763. var r = this;
  12764. function handle(n, o) {
  12765. return a.type = "throw", a.arg = e, r.next = n, o && (r.method = "next", r.arg = t), !!o;
  12766. }
  12767. for (var o = this.tryEntries.length - 1; o >= 0; --o) {
  12768. var i = this.tryEntries[o],
  12769. a = i.completion;
  12770. if ("root" === i.tryLoc) return handle("end");
  12771. if (i.tryLoc <= this.prev) {
  12772. var c = n.call(i, "catchLoc"),
  12773. u = n.call(i, "finallyLoc");
  12774. if (c && u) {
  12775. if (this.prev < i.catchLoc) return handle(i.catchLoc, !0);
  12776. if (this.prev < i.finallyLoc) return handle(i.finallyLoc);
  12777. } else if (c) {
  12778. if (this.prev < i.catchLoc) return handle(i.catchLoc, !0);
  12779. } else {
  12780. if (!u) throw Error("try statement without catch or finally");
  12781. if (this.prev < i.finallyLoc) return handle(i.finallyLoc);
  12782. }
  12783. }
  12784. }
  12785. },
  12786. abrupt: function abrupt(t, e) {
  12787. for (var r = this.tryEntries.length - 1; r >= 0; --r) {
  12788. var o = this.tryEntries[r];
  12789. if (o.tryLoc <= this.prev && n.call(o, "finallyLoc") && this.prev < o.finallyLoc) {
  12790. var i = o;
  12791. break;
  12792. }
  12793. }
  12794. i && ("break" === t || "continue" === t) && i.tryLoc <= e && e <= i.finallyLoc && (i = null);
  12795. var a = i ? i.completion : {};
  12796. return a.type = t, a.arg = e, i ? (this.method = "next", this.next = i.finallyLoc, y) : this.complete(a);
  12797. },
  12798. complete: function complete(t, e) {
  12799. if ("throw" === t.type) throw t.arg;
  12800. return "break" === t.type || "continue" === t.type ? this.next = t.arg : "return" === t.type ? (this.rval = this.arg = t.arg, this.method = "return", this.next = "end") : "normal" === t.type && e && (this.next = e), y;
  12801. },
  12802. finish: function finish(t) {
  12803. for (var e = this.tryEntries.length - 1; e >= 0; --e) {
  12804. var r = this.tryEntries[e];
  12805. if (r.finallyLoc === t) return this.complete(r.completion, r.afterLoc), resetTryEntry(r), y;
  12806. }
  12807. },
  12808. "catch": function _catch(t) {
  12809. for (var e = this.tryEntries.length - 1; e >= 0; --e) {
  12810. var r = this.tryEntries[e];
  12811. if (r.tryLoc === t) {
  12812. var n = r.completion;
  12813. if ("throw" === n.type) {
  12814. var o = n.arg;
  12815. resetTryEntry(r);
  12816. }
  12817. return o;
  12818. }
  12819. }
  12820. throw Error("illegal catch attempt");
  12821. },
  12822. delegateYield: function delegateYield(e, r, n) {
  12823. return this.delegate = {
  12824. iterator: values(e),
  12825. resultName: r,
  12826. nextLoc: n
  12827. }, "next" === this.method && (this.arg = t), y;
  12828. }
  12829. }, e;
  12830. }
  12831. module.exports = _regeneratorRuntime, module.exports.__esModule = true, module.exports["default"] = module.exports;
  12832. /***/ }),
  12833. /* 56 */
  12834. /*!*****************************************************************!*\
  12835. !*** ./node_modules/@babel/runtime/helpers/asyncToGenerator.js ***!
  12836. \*****************************************************************/
  12837. /*! no static exports found */
  12838. /***/ (function(module, exports) {
  12839. function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {
  12840. try {
  12841. var info = gen[key](arg);
  12842. var value = info.value;
  12843. } catch (error) {
  12844. reject(error);
  12845. return;
  12846. }
  12847. if (info.done) {
  12848. resolve(value);
  12849. } else {
  12850. Promise.resolve(value).then(_next, _throw);
  12851. }
  12852. }
  12853. function _asyncToGenerator(fn) {
  12854. return function () {
  12855. var self = this,
  12856. args = arguments;
  12857. return new Promise(function (resolve, reject) {
  12858. var gen = fn.apply(self, args);
  12859. function _next(value) {
  12860. asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value);
  12861. }
  12862. function _throw(err) {
  12863. asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err);
  12864. }
  12865. _next(undefined);
  12866. });
  12867. };
  12868. }
  12869. module.exports = _asyncToGenerator, module.exports.__esModule = true, module.exports["default"] = module.exports;
  12870. /***/ }),
  12871. /* 57 */
  12872. /*!******************************************************************************************!*\
  12873. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/function/colorGradient.js ***!
  12874. \******************************************************************************************/
  12875. /*! no static exports found */
  12876. /***/ (function(module, exports, __webpack_require__) {
  12877. "use strict";
  12878. Object.defineProperty(exports, "__esModule", {
  12879. value: true
  12880. });
  12881. exports.default = void 0;
  12882. /**
  12883. * 求两个颜色之间的渐变值
  12884. * @param {string} startColor 开始的颜色
  12885. * @param {string} endColor 结束的颜色
  12886. * @param {number} step 颜色等分的份额
  12887. * */
  12888. function colorGradient() {
  12889. var startColor = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'rgb(0, 0, 0)';
  12890. var endColor = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'rgb(255, 255, 255)';
  12891. var step = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 10;
  12892. var startRGB = hexToRgb(startColor, false); // 转换为rgb数组模式
  12893. var startR = startRGB[0];
  12894. var startG = startRGB[1];
  12895. var startB = startRGB[2];
  12896. var endRGB = hexToRgb(endColor, false);
  12897. var endR = endRGB[0];
  12898. var endG = endRGB[1];
  12899. var endB = endRGB[2];
  12900. var sR = (endR - startR) / step; // 总差值
  12901. var sG = (endG - startG) / step;
  12902. var sB = (endB - startB) / step;
  12903. var colorArr = [];
  12904. for (var i = 0; i < step; i++) {
  12905. // 计算每一步的hex值
  12906. var hex = rgbToHex("rgb(".concat(Math.round(sR * i + startR), ",").concat(Math.round(sG * i + startG), ",").concat(Math.round(sB * i + startB), ")"));
  12907. // 确保第一个颜色值为startColor的值
  12908. if (i === 0) hex = rgbToHex(startColor);
  12909. // 确保最后一个颜色值为endColor的值
  12910. if (i === step - 1) hex = rgbToHex(endColor);
  12911. colorArr.push(hex);
  12912. }
  12913. return colorArr;
  12914. }
  12915. // 将hex表示方式转换为rgb表示方式(这里返回rgb数组模式)
  12916. function hexToRgb(sColor) {
  12917. var str = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
  12918. var reg = /^#([0-9a-fA-f]{3}|[0-9a-fA-f]{6})$/;
  12919. sColor = String(sColor).toLowerCase();
  12920. if (sColor && reg.test(sColor)) {
  12921. if (sColor.length === 4) {
  12922. var sColorNew = '#';
  12923. for (var i = 1; i < 4; i += 1) {
  12924. sColorNew += sColor.slice(i, i + 1).concat(sColor.slice(i, i + 1));
  12925. }
  12926. sColor = sColorNew;
  12927. }
  12928. // 处理六位的颜色值
  12929. var sColorChange = [];
  12930. for (var _i = 1; _i < 7; _i += 2) {
  12931. sColorChange.push(parseInt("0x".concat(sColor.slice(_i, _i + 2))));
  12932. }
  12933. if (!str) {
  12934. return sColorChange;
  12935. }
  12936. return "rgb(".concat(sColorChange[0], ",").concat(sColorChange[1], ",").concat(sColorChange[2], ")");
  12937. }
  12938. if (/^(rgb|RGB)/.test(sColor)) {
  12939. var arr = sColor.replace(/(?:\(|\)|rgb|RGB)*/g, '').split(',');
  12940. return arr.map(function (val) {
  12941. return Number(val);
  12942. });
  12943. }
  12944. return sColor;
  12945. }
  12946. // 将rgb表示方式转换为hex表示方式
  12947. function rgbToHex(rgb) {
  12948. var _this = rgb;
  12949. var reg = /^#([0-9a-fA-f]{3}|[0-9a-fA-f]{6})$/;
  12950. if (/^(rgb|RGB)/.test(_this)) {
  12951. var aColor = _this.replace(/(?:\(|\)|rgb|RGB)*/g, '').split(',');
  12952. var strHex = '#';
  12953. for (var i = 0; i < aColor.length; i++) {
  12954. var hex = Number(aColor[i]).toString(16);
  12955. hex = String(hex).length == 1 ? "".concat(0, hex) : hex; // 保证每个rgb的值为2位
  12956. if (hex === '0') {
  12957. hex += hex;
  12958. }
  12959. strHex += hex;
  12960. }
  12961. if (strHex.length !== 7) {
  12962. strHex = _this;
  12963. }
  12964. return strHex;
  12965. }
  12966. if (reg.test(_this)) {
  12967. var aNum = _this.replace(/#/, '').split('');
  12968. if (aNum.length === 6) {
  12969. return _this;
  12970. }
  12971. if (aNum.length === 3) {
  12972. var numHex = '#';
  12973. for (var _i2 = 0; _i2 < aNum.length; _i2 += 1) {
  12974. numHex += aNum[_i2] + aNum[_i2];
  12975. }
  12976. return numHex;
  12977. }
  12978. } else {
  12979. return _this;
  12980. }
  12981. }
  12982. /**
  12983. * JS颜色十六进制转换为rgb或rgba,返回的格式为 rgba(255,255,255,0.5)字符串
  12984. * sHex为传入的十六进制的色值
  12985. * alpha为rgba的透明度
  12986. */
  12987. function colorToRgba(color, alpha) {
  12988. color = rgbToHex(color);
  12989. // 十六进制颜色值的正则表达式
  12990. var reg = /^#([0-9a-fA-f]{3}|[0-9a-fA-f]{6})$/;
  12991. /* 16进制颜色转为RGB格式 */
  12992. var sColor = String(color).toLowerCase();
  12993. if (sColor && reg.test(sColor)) {
  12994. if (sColor.length === 4) {
  12995. var sColorNew = '#';
  12996. for (var i = 1; i < 4; i += 1) {
  12997. sColorNew += sColor.slice(i, i + 1).concat(sColor.slice(i, i + 1));
  12998. }
  12999. sColor = sColorNew;
  13000. }
  13001. // 处理六位的颜色值
  13002. var sColorChange = [];
  13003. for (var _i3 = 1; _i3 < 7; _i3 += 2) {
  13004. sColorChange.push(parseInt("0x".concat(sColor.slice(_i3, _i3 + 2))));
  13005. }
  13006. // return sColorChange.join(',')
  13007. return "rgba(".concat(sColorChange.join(','), ",").concat(alpha, ")");
  13008. }
  13009. return sColor;
  13010. }
  13011. var _default = {
  13012. colorGradient: colorGradient,
  13013. hexToRgb: hexToRgb,
  13014. rgbToHex: rgbToHex,
  13015. colorToRgba: colorToRgba
  13016. };
  13017. exports.default = _default;
  13018. /***/ }),
  13019. /* 58 */
  13020. /*!*********************************************************************************!*\
  13021. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/function/test.js ***!
  13022. \*********************************************************************************/
  13023. /*! no static exports found */
  13024. /***/ (function(module, exports, __webpack_require__) {
  13025. "use strict";
  13026. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  13027. Object.defineProperty(exports, "__esModule", {
  13028. value: true
  13029. });
  13030. exports.default = void 0;
  13031. var _typeof2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/typeof */ 12));
  13032. /**
  13033. * 验证电子邮箱格式
  13034. */
  13035. function email(value) {
  13036. return /^\w+((-\w+)|(\.\w+))*\@[A-Za-z0-9]+((\.|-)[A-Za-z0-9]+)*\.[A-Za-z0-9]+$/.test(value);
  13037. }
  13038. /**
  13039. * 验证手机格式
  13040. */
  13041. function mobile(value) {
  13042. return /^1([3589]\d|4[5-9]|6[1-2,4-7]|7[0-8])\d{8}$/.test(value);
  13043. }
  13044. /**
  13045. * 验证URL格式
  13046. */
  13047. function url(value) {
  13048. return /^((https|http|ftp|rtsp|mms):\/\/)(([0-9a-zA-Z_!~*'().&=+$%-]+: )?[0-9a-zA-Z_!~*'().&=+$%-]+@)?(([0-9]{1,3}.){3}[0-9]{1,3}|([0-9a-zA-Z_!~*'()-]+.)*([0-9a-zA-Z][0-9a-zA-Z-]{0,61})?[0-9a-zA-Z].[a-zA-Z]{2,6})(:[0-9]{1,4})?((\/?)|(\/[0-9a-zA-Z_!~*'().;?:@&=+$,%#-]+)+\/?)$/.test(value);
  13049. }
  13050. /**
  13051. * 验证日期格式
  13052. */
  13053. function date(value) {
  13054. if (!value) return false;
  13055. // 判断是否数值或者字符串数值(意味着为时间戳),转为数值,否则new Date无法识别字符串时间戳
  13056. if (number(value)) value = +value;
  13057. return !/Invalid|NaN/.test(new Date(value).toString());
  13058. }
  13059. /**
  13060. * 验证ISO类型的日期格式
  13061. */
  13062. function dateISO(value) {
  13063. return /^\d{4}[\/\-](0?[1-9]|1[012])[\/\-](0?[1-9]|[12][0-9]|3[01])$/.test(value);
  13064. }
  13065. /**
  13066. * 验证十进制数字
  13067. */
  13068. function number(value) {
  13069. return /^[\+-]?(\d+\.?\d*|\.\d+|\d\.\d+e\+\d+)$/.test(value);
  13070. }
  13071. /**
  13072. * 验证字符串
  13073. */
  13074. function string(value) {
  13075. return typeof value === 'string';
  13076. }
  13077. /**
  13078. * 验证整数
  13079. */
  13080. function digits(value) {
  13081. return /^\d+$/.test(value);
  13082. }
  13083. /**
  13084. * 验证身份证号码
  13085. */
  13086. function idCard(value) {
  13087. return /^[1-9]\d{5}[1-9]\d{3}((0\d)|(1[0-2]))(([0|1|2]\d)|3[0-1])\d{3}([0-9]|X)$/.test(value);
  13088. }
  13089. /**
  13090. * 是否车牌号
  13091. */
  13092. function carNo(value) {
  13093. // 新能源车牌
  13094. var xreg = /^[京津沪渝冀豫云辽黑湘皖鲁新苏浙赣鄂桂甘晋蒙陕吉闽贵粤青藏川宁琼使领A-Z]{1}[A-Z]{1}(([0-9]{5}[DF]$)|([DF][A-HJ-NP-Z0-9][0-9]{4}$))/;
  13095. // 旧车牌
  13096. var creg = /^[京津沪渝冀豫云辽黑湘皖鲁新苏浙赣鄂桂甘晋蒙陕吉闽贵粤青藏川宁琼使领A-Z]{1}[A-Z]{1}[A-HJ-NP-Z0-9]{4}[A-HJ-NP-Z0-9挂学警港澳]{1}$/;
  13097. if (value.length === 7) {
  13098. return creg.test(value);
  13099. }
  13100. if (value.length === 8) {
  13101. return xreg.test(value);
  13102. }
  13103. return false;
  13104. }
  13105. /**
  13106. * 金额,只允许2位小数
  13107. */
  13108. function amount(value) {
  13109. // 金额,只允许保留两位小数
  13110. return /^[1-9]\d*(,\d{3})*(\.\d{1,2})?$|^0\.\d{1,2}$/.test(value);
  13111. }
  13112. /**
  13113. * 中文
  13114. */
  13115. function chinese(value) {
  13116. var reg = /^[\u4e00-\u9fa5]+$/gi;
  13117. return reg.test(value);
  13118. }
  13119. /**
  13120. * 只能输入字母
  13121. */
  13122. function letter(value) {
  13123. return /^[a-zA-Z]*$/.test(value);
  13124. }
  13125. /**
  13126. * 只能是字母或者数字
  13127. */
  13128. function enOrNum(value) {
  13129. // 英文或者数字
  13130. var reg = /^[0-9a-zA-Z]*$/g;
  13131. return reg.test(value);
  13132. }
  13133. /**
  13134. * 验证是否包含某个值
  13135. */
  13136. function contains(value, param) {
  13137. return value.indexOf(param) >= 0;
  13138. }
  13139. /**
  13140. * 验证一个值范围[min, max]
  13141. */
  13142. function range(value, param) {
  13143. return value >= param[0] && value <= param[1];
  13144. }
  13145. /**
  13146. * 验证一个长度范围[min, max]
  13147. */
  13148. function rangeLength(value, param) {
  13149. return value.length >= param[0] && value.length <= param[1];
  13150. }
  13151. /**
  13152. * 是否固定电话
  13153. */
  13154. function landline(value) {
  13155. var reg = /^\d{3,4}-\d{7,8}(-\d{3,4})?$/;
  13156. return reg.test(value);
  13157. }
  13158. /**
  13159. * 判断是否为空
  13160. */
  13161. function empty(value) {
  13162. switch ((0, _typeof2.default)(value)) {
  13163. case 'undefined':
  13164. return true;
  13165. case 'string':
  13166. if (value.replace(/(^[ \t\n\r]*)|([ \t\n\r]*$)/g, '').length == 0) return true;
  13167. break;
  13168. case 'boolean':
  13169. if (!value) return true;
  13170. break;
  13171. case 'number':
  13172. if (value === 0 || isNaN(value)) return true;
  13173. break;
  13174. case 'object':
  13175. if (value === null || value.length === 0) return true;
  13176. for (var i in value) {
  13177. return false;
  13178. }
  13179. return true;
  13180. }
  13181. return false;
  13182. }
  13183. /**
  13184. * 是否json字符串
  13185. */
  13186. function jsonString(value) {
  13187. if (typeof value === 'string') {
  13188. try {
  13189. var obj = JSON.parse(value);
  13190. if ((0, _typeof2.default)(obj) === 'object' && obj) {
  13191. return true;
  13192. }
  13193. return false;
  13194. } catch (e) {
  13195. return false;
  13196. }
  13197. }
  13198. return false;
  13199. }
  13200. /**
  13201. * 是否数组
  13202. */
  13203. function array(value) {
  13204. if (typeof Array.isArray === 'function') {
  13205. return Array.isArray(value);
  13206. }
  13207. return Object.prototype.toString.call(value) === '[object Array]';
  13208. }
  13209. /**
  13210. * 是否对象
  13211. */
  13212. function object(value) {
  13213. return Object.prototype.toString.call(value) === '[object Object]';
  13214. }
  13215. /**
  13216. * 是否短信验证码
  13217. */
  13218. function code(value) {
  13219. var len = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 6;
  13220. return new RegExp("^\\d{".concat(len, "}$")).test(value);
  13221. }
  13222. /**
  13223. * 是否函数方法
  13224. * @param {Object} value
  13225. */
  13226. function func(value) {
  13227. return typeof value === 'function';
  13228. }
  13229. /**
  13230. * 是否promise对象
  13231. * @param {Object} value
  13232. */
  13233. function promise(value) {
  13234. return object(value) && func(value.then) && func(value.catch);
  13235. }
  13236. /** 是否图片格式
  13237. * @param {Object} value
  13238. */
  13239. function image(value) {
  13240. var newValue = value.split('?')[0];
  13241. var IMAGE_REGEXP = /\.(jpeg|jpg|gif|png|svg|webp|jfif|bmp|dpg)/i;
  13242. return IMAGE_REGEXP.test(newValue);
  13243. }
  13244. /**
  13245. * 是否视频格式
  13246. * @param {Object} value
  13247. */
  13248. function video(value) {
  13249. var VIDEO_REGEXP = /\.(mp4|mpg|mpeg|dat|asf|avi|rm|rmvb|mov|wmv|flv|mkv|m3u8)/i;
  13250. return VIDEO_REGEXP.test(value);
  13251. }
  13252. /**
  13253. * 是否为正则对象
  13254. * @param {Object}
  13255. * @return {Boolean}
  13256. */
  13257. function regExp(o) {
  13258. return o && Object.prototype.toString.call(o) === '[object RegExp]';
  13259. }
  13260. var _default = {
  13261. email: email,
  13262. mobile: mobile,
  13263. url: url,
  13264. date: date,
  13265. dateISO: dateISO,
  13266. number: number,
  13267. digits: digits,
  13268. idCard: idCard,
  13269. carNo: carNo,
  13270. amount: amount,
  13271. chinese: chinese,
  13272. letter: letter,
  13273. enOrNum: enOrNum,
  13274. contains: contains,
  13275. range: range,
  13276. rangeLength: rangeLength,
  13277. empty: empty,
  13278. isEmpty: empty,
  13279. jsonString: jsonString,
  13280. landline: landline,
  13281. object: object,
  13282. array: array,
  13283. code: code,
  13284. func: func,
  13285. promise: promise,
  13286. video: video,
  13287. image: image,
  13288. regExp: regExp,
  13289. string: string
  13290. };
  13291. exports.default = _default;
  13292. /***/ }),
  13293. /* 59 */
  13294. /*!*************************************************************************************!*\
  13295. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/function/debounce.js ***!
  13296. \*************************************************************************************/
  13297. /*! no static exports found */
  13298. /***/ (function(module, exports, __webpack_require__) {
  13299. "use strict";
  13300. Object.defineProperty(exports, "__esModule", {
  13301. value: true
  13302. });
  13303. exports.default = void 0;
  13304. var timeout = null;
  13305. /**
  13306. * 防抖原理:一定时间内,只有最后一次操作,再过wait毫秒后才执行函数
  13307. *
  13308. * @param {Function} func 要执行的回调函数
  13309. * @param {Number} wait 延时的时间
  13310. * @param {Boolean} immediate 是否立即执行
  13311. * @return null
  13312. */
  13313. function debounce(func) {
  13314. var wait = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 500;
  13315. var immediate = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
  13316. // 清除定时器
  13317. if (timeout !== null) clearTimeout(timeout);
  13318. // 立即执行,此类情况一般用不到
  13319. if (immediate) {
  13320. var callNow = !timeout;
  13321. timeout = setTimeout(function () {
  13322. timeout = null;
  13323. }, wait);
  13324. if (callNow) typeof func === 'function' && func();
  13325. } else {
  13326. // 设置定时器,当最后一次操作后,timeout不会再被清除,所以在延时wait毫秒后执行func回调方法
  13327. timeout = setTimeout(function () {
  13328. typeof func === 'function' && func();
  13329. }, wait);
  13330. }
  13331. }
  13332. var _default = debounce;
  13333. exports.default = _default;
  13334. /***/ }),
  13335. /* 60 */
  13336. /*!*************************************************************************************!*\
  13337. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/function/throttle.js ***!
  13338. \*************************************************************************************/
  13339. /*! no static exports found */
  13340. /***/ (function(module, exports, __webpack_require__) {
  13341. "use strict";
  13342. Object.defineProperty(exports, "__esModule", {
  13343. value: true
  13344. });
  13345. exports.default = void 0;
  13346. var timer;
  13347. var flag;
  13348. /**
  13349. * 节流原理:在一定时间内,只能触发一次
  13350. *
  13351. * @param {Function} func 要执行的回调函数
  13352. * @param {Number} wait 延时的时间
  13353. * @param {Boolean} immediate 是否立即执行
  13354. * @return null
  13355. */
  13356. function throttle(func) {
  13357. var wait = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 500;
  13358. var immediate = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : true;
  13359. if (immediate) {
  13360. if (!flag) {
  13361. flag = true;
  13362. // 如果是立即执行,则在wait毫秒内开始时执行
  13363. typeof func === 'function' && func();
  13364. timer = setTimeout(function () {
  13365. flag = false;
  13366. }, wait);
  13367. }
  13368. } else if (!flag) {
  13369. flag = true;
  13370. // 如果是非立即执行,则在wait毫秒内的结束处执行
  13371. timer = setTimeout(function () {
  13372. flag = false;
  13373. typeof func === 'function' && func();
  13374. }, wait);
  13375. }
  13376. }
  13377. var _default = throttle;
  13378. exports.default = _default;
  13379. /***/ }),
  13380. /* 61 */
  13381. /*!**********************************************************************************!*\
  13382. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/function/index.js ***!
  13383. \**********************************************************************************/
  13384. /*! no static exports found */
  13385. /***/ (function(module, exports, __webpack_require__) {
  13386. "use strict";
  13387. /* WEBPACK VAR INJECTION */(function(uni) {
  13388. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  13389. Object.defineProperty(exports, "__esModule", {
  13390. value: true
  13391. });
  13392. exports.default = void 0;
  13393. var _slicedToArray2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/slicedToArray */ 4));
  13394. var _typeof2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/typeof */ 12));
  13395. var _test = _interopRequireDefault(__webpack_require__(/*! ./test.js */ 58));
  13396. var _digit = __webpack_require__(/*! ./digit.js */ 62);
  13397. /**
  13398. * @description 如果value小于min,取min;如果value大于max,取max
  13399. * @param {number} min
  13400. * @param {number} max
  13401. * @param {number} value
  13402. */
  13403. function range() {
  13404. var min = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 0;
  13405. var max = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
  13406. var value = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0;
  13407. return Math.max(min, Math.min(max, Number(value)));
  13408. }
  13409. /**
  13410. * @description 用于获取用户传递值的px值 如果用户传递了"xxpx"或者"xxrpx",取出其数值部分,如果是"xxxrpx"还需要用过uni.upx2px进行转换
  13411. * @param {number|string} value 用户传递值的px值
  13412. * @param {boolean} unit
  13413. * @returns {number|string}
  13414. */
  13415. function getPx(value) {
  13416. var unit = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
  13417. if (_test.default.number(value)) {
  13418. return unit ? "".concat(value, "px") : Number(value);
  13419. }
  13420. // 如果带有rpx,先取出其数值部分,再转为px值
  13421. if (/(rpx|upx)$/.test(value)) {
  13422. return unit ? "".concat(uni.upx2px(parseInt(value)), "px") : Number(uni.upx2px(parseInt(value)));
  13423. }
  13424. return unit ? "".concat(parseInt(value), "px") : parseInt(value);
  13425. }
  13426. /**
  13427. * @description 进行延时,以达到可以简写代码的目的 比如: await uni.$u.sleep(20)将会阻塞20ms
  13428. * @param {number} value 堵塞时间 单位ms 毫秒
  13429. * @returns {Promise} 返回promise
  13430. */
  13431. function sleep() {
  13432. var value = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 30;
  13433. return new Promise(function (resolve) {
  13434. setTimeout(function () {
  13435. resolve();
  13436. }, value);
  13437. });
  13438. }
  13439. /**
  13440. * @description 运行期判断平台
  13441. * @returns {string} 返回所在平台(小写)
  13442. * @link 运行期判断平台 https://uniapp.dcloud.io/frame?id=判断平台
  13443. */
  13444. function os() {
  13445. return uni.getSystemInfoSync().platform.toLowerCase();
  13446. }
  13447. /**
  13448. * @description 获取系统信息同步接口
  13449. * @link 获取系统信息同步接口 https://uniapp.dcloud.io/api/system/info?id=getsysteminfosync
  13450. */
  13451. function sys() {
  13452. return uni.getSystemInfoSync();
  13453. }
  13454. /**
  13455. * @description 取一个区间数
  13456. * @param {Number} min 最小值
  13457. * @param {Number} max 最大值
  13458. */
  13459. function random(min, max) {
  13460. if (min >= 0 && max > 0 && max >= min) {
  13461. var gab = max - min + 1;
  13462. return Math.floor(Math.random() * gab + min);
  13463. }
  13464. return 0;
  13465. }
  13466. /**
  13467. * @param {Number} len uuid的长度
  13468. * @param {Boolean} firstU 将返回的首字母置为"u"
  13469. * @param {Nubmer} radix 生成uuid的基数(意味着返回的字符串都是这个基数),2-二进制,8-八进制,10-十进制,16-十六进制
  13470. */
  13471. function guid() {
  13472. var len = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 32;
  13473. var firstU = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
  13474. var radix = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;
  13475. var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz'.split('');
  13476. var uuid = [];
  13477. radix = radix || chars.length;
  13478. if (len) {
  13479. // 如果指定uuid长度,只是取随机的字符,0|x为位运算,能去掉x的小数位,返回整数位
  13480. for (var i = 0; i < len; i++) {
  13481. uuid[i] = chars[0 | Math.random() * radix];
  13482. }
  13483. } else {
  13484. var r;
  13485. // rfc4122标准要求返回的uuid中,某些位为固定的字符
  13486. uuid[8] = uuid[13] = uuid[18] = uuid[23] = '-';
  13487. uuid[14] = '4';
  13488. for (var _i = 0; _i < 36; _i++) {
  13489. if (!uuid[_i]) {
  13490. r = 0 | Math.random() * 16;
  13491. uuid[_i] = chars[_i == 19 ? r & 0x3 | 0x8 : r];
  13492. }
  13493. }
  13494. }
  13495. // 移除第一个字符,并用u替代,因为第一个字符为数值时,该guuid不能用作id或者class
  13496. if (firstU) {
  13497. uuid.shift();
  13498. return "u".concat(uuid.join(''));
  13499. }
  13500. return uuid.join('');
  13501. }
  13502. /**
  13503. * @description 获取父组件的参数,因为支付宝小程序不支持provide/inject的写法
  13504. this.$parent在非H5中,可以准确获取到父组件,但是在H5中,需要多次this.$parent.$parent.xxx
  13505. 这里默认值等于undefined有它的含义,因为最顶层元素(组件)的$parent就是undefined,意味着不传name
  13506. 值(默认为undefined),就是查找最顶层的$parent
  13507. * @param {string|undefined} name 父组件的参数名
  13508. */
  13509. function $parent() {
  13510. var name = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : undefined;
  13511. var parent = this.$parent;
  13512. // 通过while历遍,这里主要是为了H5需要多层解析的问题
  13513. while (parent) {
  13514. // 父组件
  13515. if (parent.$options && parent.$options.name !== name) {
  13516. // 如果组件的name不相等,继续上一级寻找
  13517. parent = parent.$parent;
  13518. } else {
  13519. return parent;
  13520. }
  13521. }
  13522. return false;
  13523. }
  13524. /**
  13525. * @description 样式转换
  13526. * 对象转字符串,或者字符串转对象
  13527. * @param {object | string} customStyle 需要转换的目标
  13528. * @param {String} target 转换的目的,object-转为对象,string-转为字符串
  13529. * @returns {object|string}
  13530. */
  13531. function addStyle(customStyle) {
  13532. var target = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'object';
  13533. // 字符串转字符串,对象转对象情形,直接返回
  13534. if (_test.default.empty(customStyle) || (0, _typeof2.default)(customStyle) === 'object' && target === 'object' || target === 'string' && typeof customStyle === 'string') {
  13535. return customStyle;
  13536. }
  13537. // 字符串转对象
  13538. if (target === 'object') {
  13539. // 去除字符串样式中的两端空格(中间的空格不能去掉,比如padding: 20px 0如果去掉了就错了),空格是无用的
  13540. customStyle = trim(customStyle);
  13541. // 根据";"将字符串转为数组形式
  13542. var styleArray = customStyle.split(';');
  13543. var style = {};
  13544. // 历遍数组,拼接成对象
  13545. for (var i = 0; i < styleArray.length; i++) {
  13546. // 'font-size:20px;color:red;',如此最后字符串有";"的话,会导致styleArray最后一个元素为空字符串,这里需要过滤
  13547. if (styleArray[i]) {
  13548. var item = styleArray[i].split(':');
  13549. style[trim(item[0])] = trim(item[1]);
  13550. }
  13551. }
  13552. return style;
  13553. }
  13554. // 这里为对象转字符串形式
  13555. var string = '';
  13556. for (var _i2 in customStyle) {
  13557. // 驼峰转为中划线的形式,否则css内联样式,无法识别驼峰样式属性名
  13558. var key = _i2.replace(/([A-Z])/g, '-$1').toLowerCase();
  13559. string += "".concat(key, ":").concat(customStyle[_i2], ";");
  13560. }
  13561. // 去除两端空格
  13562. return trim(string);
  13563. }
  13564. /**
  13565. * @description 添加单位,如果有rpx,upx,%,px等单位结尾或者值为auto,直接返回,否则加上px单位结尾
  13566. * @param {string|number} value 需要添加单位的值
  13567. * @param {string} unit 添加的单位名 比如px
  13568. */
  13569. function addUnit() {
  13570. var _uni$$u$config$unit, _uni, _uni$$u, _uni$$u$config;
  13571. var value = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'auto';
  13572. var unit = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : (_uni$$u$config$unit = (_uni = uni) === null || _uni === void 0 ? void 0 : (_uni$$u = _uni.$u) === null || _uni$$u === void 0 ? void 0 : (_uni$$u$config = _uni$$u.config) === null || _uni$$u$config === void 0 ? void 0 : _uni$$u$config.unit) !== null && _uni$$u$config$unit !== void 0 ? _uni$$u$config$unit : 'px';
  13573. value = String(value);
  13574. // 用uView内置验证规则中的number判断是否为数值
  13575. return _test.default.number(value) ? "".concat(value).concat(unit) : value;
  13576. }
  13577. /**
  13578. * @description 深度克隆
  13579. * @param {object} obj 需要深度克隆的对象
  13580. * @param cache 缓存
  13581. * @returns {*} 克隆后的对象或者原值(不是对象)
  13582. */
  13583. function deepClone(obj) {
  13584. var cache = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : new WeakMap();
  13585. if (obj === null || (0, _typeof2.default)(obj) !== 'object') return obj;
  13586. if (cache.has(obj)) return cache.get(obj);
  13587. var clone;
  13588. if (obj instanceof Date) {
  13589. clone = new Date(obj.getTime());
  13590. } else if (obj instanceof RegExp) {
  13591. clone = new RegExp(obj);
  13592. } else if (obj instanceof Map) {
  13593. clone = new Map(Array.from(obj, function (_ref) {
  13594. var _ref2 = (0, _slicedToArray2.default)(_ref, 2),
  13595. key = _ref2[0],
  13596. value = _ref2[1];
  13597. return [key, deepClone(value, cache)];
  13598. }));
  13599. } else if (obj instanceof Set) {
  13600. clone = new Set(Array.from(obj, function (value) {
  13601. return deepClone(value, cache);
  13602. }));
  13603. } else if (Array.isArray(obj)) {
  13604. clone = obj.map(function (value) {
  13605. return deepClone(value, cache);
  13606. });
  13607. } else if (Object.prototype.toString.call(obj) === '[object Object]') {
  13608. clone = Object.create(Object.getPrototypeOf(obj));
  13609. cache.set(obj, clone);
  13610. for (var _i3 = 0, _Object$entries = Object.entries(obj); _i3 < _Object$entries.length; _i3++) {
  13611. var _Object$entries$_i = (0, _slicedToArray2.default)(_Object$entries[_i3], 2),
  13612. key = _Object$entries$_i[0],
  13613. value = _Object$entries$_i[1];
  13614. clone[key] = deepClone(value, cache);
  13615. }
  13616. } else {
  13617. clone = Object.assign({}, obj);
  13618. }
  13619. cache.set(obj, clone);
  13620. return clone;
  13621. }
  13622. /**
  13623. * @description JS对象深度合并
  13624. * @param {object} target 需要拷贝的对象
  13625. * @param {object} source 拷贝的来源对象
  13626. * @returns {object|boolean} 深度合并后的对象或者false(入参有不是对象)
  13627. */
  13628. function deepMerge() {
  13629. var target = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
  13630. var source = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
  13631. target = deepClone(target);
  13632. if ((0, _typeof2.default)(target) !== 'object' || target === null || (0, _typeof2.default)(source) !== 'object' || source === null) return target;
  13633. var merged = Array.isArray(target) ? target.slice() : Object.assign({}, target);
  13634. for (var prop in source) {
  13635. if (!source.hasOwnProperty(prop)) continue;
  13636. var sourceValue = source[prop];
  13637. var targetValue = merged[prop];
  13638. if (sourceValue instanceof Date) {
  13639. merged[prop] = new Date(sourceValue);
  13640. } else if (sourceValue instanceof RegExp) {
  13641. merged[prop] = new RegExp(sourceValue);
  13642. } else if (sourceValue instanceof Map) {
  13643. merged[prop] = new Map(sourceValue);
  13644. } else if (sourceValue instanceof Set) {
  13645. merged[prop] = new Set(sourceValue);
  13646. } else if ((0, _typeof2.default)(sourceValue) === 'object' && sourceValue !== null) {
  13647. merged[prop] = deepMerge(targetValue, sourceValue);
  13648. } else {
  13649. merged[prop] = sourceValue;
  13650. }
  13651. }
  13652. return merged;
  13653. }
  13654. /**
  13655. * @description error提示
  13656. * @param {*} err 错误内容
  13657. */
  13658. function error(err) {
  13659. // 开发环境才提示,生产环境不会提示
  13660. if (true) {
  13661. console.error("uView\u63D0\u793A\uFF1A".concat(err));
  13662. }
  13663. }
  13664. /**
  13665. * @description 打乱数组
  13666. * @param {array} array 需要打乱的数组
  13667. * @returns {array} 打乱后的数组
  13668. */
  13669. function randomArray() {
  13670. var array = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];
  13671. // 原理是sort排序,Math.random()产生0<= x < 1之间的数,会导致x-0.05大于或者小于0
  13672. return array.sort(function () {
  13673. return Math.random() - 0.5;
  13674. });
  13675. }
  13676. // padStart 的 polyfill,因为某些机型或情况,还无法支持es7的padStart,比如电脑版的微信小程序
  13677. // 所以这里做一个兼容polyfill的兼容处理
  13678. if (!String.prototype.padStart) {
  13679. // 为了方便表示这里 fillString 用了ES6 的默认参数,不影响理解
  13680. String.prototype.padStart = function (maxLength) {
  13681. var fillString = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : ' ';
  13682. if (Object.prototype.toString.call(fillString) !== '[object String]') {
  13683. throw new TypeError('fillString must be String');
  13684. }
  13685. var str = this;
  13686. // 返回 String(str) 这里是为了使返回的值是字符串字面量,在控制台中更符合直觉
  13687. if (str.length >= maxLength) return String(str);
  13688. var fillLength = maxLength - str.length;
  13689. var times = Math.ceil(fillLength / fillString.length);
  13690. while (times >>= 1) {
  13691. fillString += fillString;
  13692. if (times === 1) {
  13693. fillString += fillString;
  13694. }
  13695. }
  13696. return fillString.slice(0, fillLength) + str;
  13697. };
  13698. }
  13699. /**
  13700. * @description 格式化时间
  13701. * @param {String|Number} dateTime 需要格式化的时间戳
  13702. * @param {String} fmt 格式化规则 yyyy:mm:dd|yyyy:mm|yyyy年mm月dd日|yyyy年mm月dd日 hh时MM分等,可自定义组合 默认yyyy-mm-dd
  13703. * @returns {string} 返回格式化后的字符串
  13704. */
  13705. function timeFormat() {
  13706. var dateTime = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;
  13707. var formatStr = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'yyyy-mm-dd';
  13708. var date;
  13709. // 若传入时间为假值,则取当前时间
  13710. if (!dateTime) {
  13711. date = new Date();
  13712. }
  13713. // 若为unix秒时间戳,则转为毫秒时间戳(逻辑有点奇怪,但不敢改,以保证历史兼容)
  13714. else if (/^\d{10}$/.test(dateTime === null || dateTime === void 0 ? void 0 : dateTime.toString().trim())) {
  13715. date = new Date(dateTime * 1000);
  13716. }
  13717. // 若用户传入字符串格式时间戳,new Date无法解析,需做兼容
  13718. else if (typeof dateTime === 'string' && /^\d+$/.test(dateTime.trim())) {
  13719. date = new Date(Number(dateTime));
  13720. }
  13721. // 处理平台性差异,在Safari/Webkit中,new Date仅支持/作为分割符的字符串时间
  13722. // 处理 '2022-07-10 01:02:03',跳过 '2022-07-10T01:02:03'
  13723. else if (typeof dateTime === 'string' && dateTime.includes('-') && !dateTime.includes('T')) {
  13724. date = new Date(dateTime.replace(/-/g, '/'));
  13725. }
  13726. // 其他都认为符合 RFC 2822 规范
  13727. else {
  13728. date = new Date(dateTime);
  13729. }
  13730. var timeSource = {
  13731. 'y': date.getFullYear().toString(),
  13732. // 年
  13733. 'm': (date.getMonth() + 1).toString().padStart(2, '0'),
  13734. // 月
  13735. 'd': date.getDate().toString().padStart(2, '0'),
  13736. // 日
  13737. 'h': date.getHours().toString().padStart(2, '0'),
  13738. // 时
  13739. 'M': date.getMinutes().toString().padStart(2, '0'),
  13740. // 分
  13741. 's': date.getSeconds().toString().padStart(2, '0') // 秒
  13742. // 有其他格式化字符需求可以继续添加,必须转化成字符串
  13743. };
  13744. for (var key in timeSource) {
  13745. var _ref3 = new RegExp("".concat(key, "+")).exec(formatStr) || [],
  13746. _ref4 = (0, _slicedToArray2.default)(_ref3, 1),
  13747. ret = _ref4[0];
  13748. if (ret) {
  13749. // 年可能只需展示两位
  13750. var beginIndex = key === 'y' && ret.length === 2 ? 2 : 0;
  13751. formatStr = formatStr.replace(ret, timeSource[key].slice(beginIndex));
  13752. }
  13753. }
  13754. return formatStr;
  13755. }
  13756. /**
  13757. * @description 时间戳转为多久之前
  13758. * @param {String|Number} timestamp 时间戳
  13759. * @param {String|Boolean} format
  13760. * 格式化规则如果为时间格式字符串,超出一定时间范围,返回固定的时间格式;
  13761. * 如果为布尔值false,无论什么时间,都返回多久以前的格式
  13762. * @returns {string} 转化后的内容
  13763. */
  13764. function timeFrom() {
  13765. var timestamp = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;
  13766. var format = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'yyyy-mm-dd';
  13767. if (timestamp == null) timestamp = Number(new Date());
  13768. timestamp = parseInt(timestamp);
  13769. // 判断用户输入的时间戳是秒还是毫秒,一般前端js获取的时间戳是毫秒(13位),后端传过来的为秒(10位)
  13770. if (timestamp.toString().length == 10) timestamp *= 1000;
  13771. var timer = new Date().getTime() - timestamp;
  13772. timer = parseInt(timer / 1000);
  13773. // 如果小于5分钟,则返回"刚刚",其他以此类推
  13774. var tips = '';
  13775. switch (true) {
  13776. case timer < 300:
  13777. tips = '刚刚';
  13778. break;
  13779. case timer >= 300 && timer < 3600:
  13780. tips = "".concat(parseInt(timer / 60), "\u5206\u949F\u524D");
  13781. break;
  13782. case timer >= 3600 && timer < 86400:
  13783. tips = "".concat(parseInt(timer / 3600), "\u5C0F\u65F6\u524D");
  13784. break;
  13785. case timer >= 86400 && timer < 2592000:
  13786. tips = "".concat(parseInt(timer / 86400), "\u5929\u524D");
  13787. break;
  13788. default:
  13789. // 如果format为false,则无论什么时间戳,都显示xx之前
  13790. if (format === false) {
  13791. if (timer >= 2592000 && timer < 365 * 86400) {
  13792. tips = "".concat(parseInt(timer / (86400 * 30)), "\u4E2A\u6708\u524D");
  13793. } else {
  13794. tips = "".concat(parseInt(timer / (86400 * 365)), "\u5E74\u524D");
  13795. }
  13796. } else {
  13797. tips = timeFormat(timestamp, format);
  13798. }
  13799. }
  13800. return tips;
  13801. }
  13802. /**
  13803. * @description 去除空格
  13804. * @param String str 需要去除空格的字符串
  13805. * @param String pos both(左右)|left|right|all 默认both
  13806. */
  13807. function trim(str) {
  13808. var pos = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'both';
  13809. str = String(str);
  13810. if (pos == 'both') {
  13811. return str.replace(/^\s+|\s+$/g, '');
  13812. }
  13813. if (pos == 'left') {
  13814. return str.replace(/^\s*/, '');
  13815. }
  13816. if (pos == 'right') {
  13817. return str.replace(/(\s*$)/g, '');
  13818. }
  13819. if (pos == 'all') {
  13820. return str.replace(/\s+/g, '');
  13821. }
  13822. return str;
  13823. }
  13824. /**
  13825. * @description 对象转url参数
  13826. * @param {object} data,对象
  13827. * @param {Boolean} isPrefix,是否自动加上"?"
  13828. * @param {string} arrayFormat 规则 indices|brackets|repeat|comma
  13829. */
  13830. function queryParams() {
  13831. var data = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
  13832. var isPrefix = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
  13833. var arrayFormat = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 'brackets';
  13834. var prefix = isPrefix ? '?' : '';
  13835. var _result = [];
  13836. if (['indices', 'brackets', 'repeat', 'comma'].indexOf(arrayFormat) == -1) arrayFormat = 'brackets';
  13837. var _loop = function _loop(key) {
  13838. var value = data[key];
  13839. // 去掉为空的参数
  13840. if (['', undefined, null].indexOf(value) >= 0) {
  13841. return "continue";
  13842. }
  13843. // 如果值为数组,另行处理
  13844. if (value.constructor === Array) {
  13845. // e.g. {ids: [1, 2, 3]}
  13846. switch (arrayFormat) {
  13847. case 'indices':
  13848. // 结果: ids[0]=1&ids[1]=2&ids[2]=3
  13849. for (var i = 0; i < value.length; i++) {
  13850. _result.push("".concat(key, "[").concat(i, "]=").concat(value[i]));
  13851. }
  13852. break;
  13853. case 'brackets':
  13854. // 结果: ids[]=1&ids[]=2&ids[]=3
  13855. value.forEach(function (_value) {
  13856. _result.push("".concat(key, "[]=").concat(_value));
  13857. });
  13858. break;
  13859. case 'repeat':
  13860. // 结果: ids=1&ids=2&ids=3
  13861. value.forEach(function (_value) {
  13862. _result.push("".concat(key, "=").concat(_value));
  13863. });
  13864. break;
  13865. case 'comma':
  13866. // 结果: ids=1,2,3
  13867. var commaStr = '';
  13868. value.forEach(function (_value) {
  13869. commaStr += (commaStr ? ',' : '') + _value;
  13870. });
  13871. _result.push("".concat(key, "=").concat(commaStr));
  13872. break;
  13873. default:
  13874. value.forEach(function (_value) {
  13875. _result.push("".concat(key, "[]=").concat(_value));
  13876. });
  13877. }
  13878. } else {
  13879. _result.push("".concat(key, "=").concat(value));
  13880. }
  13881. };
  13882. for (var key in data) {
  13883. var _ret = _loop(key);
  13884. if (_ret === "continue") continue;
  13885. }
  13886. return _result.length ? prefix + _result.join('&') : '';
  13887. }
  13888. /**
  13889. * 显示消息提示框
  13890. * @param {String} title 提示的内容,长度与 icon 取值有关。
  13891. * @param {Number} duration 提示的延迟时间,单位毫秒,默认:2000
  13892. */
  13893. function toast(title) {
  13894. var duration = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 2000;
  13895. uni.showToast({
  13896. title: String(title),
  13897. icon: 'none',
  13898. duration: duration
  13899. });
  13900. }
  13901. /**
  13902. * @description 根据主题type值,获取对应的图标
  13903. * @param {String} type 主题名称,primary|info|error|warning|success
  13904. * @param {boolean} fill 是否使用fill填充实体的图标
  13905. */
  13906. function type2icon() {
  13907. var type = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'success';
  13908. var fill = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
  13909. // 如果非预置值,默认为success
  13910. if (['primary', 'info', 'error', 'warning', 'success'].indexOf(type) == -1) type = 'success';
  13911. var iconName = '';
  13912. // 目前(2019-12-12),info和primary使用同一个图标
  13913. switch (type) {
  13914. case 'primary':
  13915. iconName = 'info-circle';
  13916. break;
  13917. case 'info':
  13918. iconName = 'info-circle';
  13919. break;
  13920. case 'error':
  13921. iconName = 'close-circle';
  13922. break;
  13923. case 'warning':
  13924. iconName = 'error-circle';
  13925. break;
  13926. case 'success':
  13927. iconName = 'checkmark-circle';
  13928. break;
  13929. default:
  13930. iconName = 'checkmark-circle';
  13931. }
  13932. // 是否是实体类型,加上-fill,在icon组件库中,实体的类名是后面加-fill的
  13933. if (fill) iconName += '-fill';
  13934. return iconName;
  13935. }
  13936. /**
  13937. * @description 数字格式化
  13938. * @param {number|string} number 要格式化的数字
  13939. * @param {number} decimals 保留几位小数
  13940. * @param {string} decimalPoint 小数点符号
  13941. * @param {string} thousandsSeparator 千分位符号
  13942. * @returns {string} 格式化后的数字
  13943. */
  13944. function priceFormat(number) {
  13945. var decimals = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
  13946. var decimalPoint = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : '.';
  13947. var thousandsSeparator = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : ',';
  13948. number = "".concat(number).replace(/[^0-9+-Ee.]/g, '');
  13949. var n = !isFinite(+number) ? 0 : +number;
  13950. var prec = !isFinite(+decimals) ? 0 : Math.abs(decimals);
  13951. var sep = typeof thousandsSeparator === 'undefined' ? ',' : thousandsSeparator;
  13952. var dec = typeof decimalPoint === 'undefined' ? '.' : decimalPoint;
  13953. var s = '';
  13954. s = (prec ? (0, _digit.round)(n, prec) + '' : "".concat(Math.round(n))).split('.');
  13955. var re = /(-?\d+)(\d{3})/;
  13956. while (re.test(s[0])) {
  13957. s[0] = s[0].replace(re, "$1".concat(sep, "$2"));
  13958. }
  13959. if ((s[1] || '').length < prec) {
  13960. s[1] = s[1] || '';
  13961. s[1] += new Array(prec - s[1].length + 1).join('0');
  13962. }
  13963. return s.join(dec);
  13964. }
  13965. /**
  13966. * @description 获取duration值
  13967. * 如果带有ms或者s直接返回,如果大于一定值,认为是ms单位,小于一定值,认为是s单位
  13968. * 比如以30位阈值,那么300大于30,可以理解为用户想要的是300ms,而不是想花300s去执行一个动画
  13969. * @param {String|number} value 比如: "1s"|"100ms"|1|100
  13970. * @param {boolean} unit 提示: 如果是false 默认返回number
  13971. * @return {string|number}
  13972. */
  13973. function getDuration(value) {
  13974. var unit = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
  13975. var valueNum = parseInt(value);
  13976. if (unit) {
  13977. if (/s$/.test(value)) return value;
  13978. return value > 30 ? "".concat(value, "ms") : "".concat(value, "s");
  13979. }
  13980. if (/ms$/.test(value)) return valueNum;
  13981. if (/s$/.test(value)) return valueNum > 30 ? valueNum : valueNum * 1000;
  13982. return valueNum;
  13983. }
  13984. /**
  13985. * @description 日期的月或日补零操作
  13986. * @param {String} value 需要补零的值
  13987. */
  13988. function padZero(value) {
  13989. return "00".concat(value).slice(-2);
  13990. }
  13991. /**
  13992. * @description 在u-form的子组件内容发生变化,或者失去焦点时,尝试通知u-form执行校验方法
  13993. * @param {*} instance
  13994. * @param {*} event
  13995. */
  13996. function formValidate(instance, event) {
  13997. var formItem = uni.$u.$parent.call(instance, 'u-form-item');
  13998. var form = uni.$u.$parent.call(instance, 'u-form');
  13999. // 如果发生变化的input或者textarea等,其父组件中有u-form-item或者u-form等,就执行form的validate方法
  14000. // 同时将form-item的pros传递给form,让其进行精确对象验证
  14001. if (formItem && form) {
  14002. form.validateField(formItem.prop, function () {}, event);
  14003. }
  14004. }
  14005. /**
  14006. * @description 获取某个对象下的属性,用于通过类似'a.b.c'的形式去获取一个对象的的属性的形式
  14007. * @param {object} obj 对象
  14008. * @param {string} key 需要获取的属性字段
  14009. * @returns {*}
  14010. */
  14011. function getProperty(obj, key) {
  14012. if (!obj) {
  14013. return;
  14014. }
  14015. if (typeof key !== 'string' || key === '') {
  14016. return '';
  14017. }
  14018. if (key.indexOf('.') !== -1) {
  14019. var keys = key.split('.');
  14020. var firstObj = obj[keys[0]] || {};
  14021. for (var i = 1; i < keys.length; i++) {
  14022. if (firstObj) {
  14023. firstObj = firstObj[keys[i]];
  14024. }
  14025. }
  14026. return firstObj;
  14027. }
  14028. return obj[key];
  14029. }
  14030. /**
  14031. * @description 设置对象的属性值,如果'a.b.c'的形式进行设置
  14032. * @param {object} obj 对象
  14033. * @param {string} key 需要设置的属性
  14034. * @param {string} value 设置的值
  14035. */
  14036. function setProperty(obj, key, value) {
  14037. if (!obj) {
  14038. return;
  14039. }
  14040. // 递归赋值
  14041. var inFn = function inFn(_obj, keys, v) {
  14042. // 最后一个属性key
  14043. if (keys.length === 1) {
  14044. _obj[keys[0]] = v;
  14045. return;
  14046. }
  14047. // 0~length-1个key
  14048. while (keys.length > 1) {
  14049. var k = keys[0];
  14050. if (!_obj[k] || (0, _typeof2.default)(_obj[k]) !== 'object') {
  14051. _obj[k] = {};
  14052. }
  14053. var _key = keys.shift();
  14054. // 自调用判断是否存在属性,不存在则自动创建对象
  14055. inFn(_obj[k], keys, v);
  14056. }
  14057. };
  14058. if (typeof key !== 'string' || key === '') {} else if (key.indexOf('.') !== -1) {
  14059. // 支持多层级赋值操作
  14060. var keys = key.split('.');
  14061. inFn(obj, keys, value);
  14062. } else {
  14063. obj[key] = value;
  14064. }
  14065. }
  14066. /**
  14067. * @description 获取当前页面路径
  14068. */
  14069. function page() {
  14070. var _pages$route, _pages;
  14071. var pages = getCurrentPages();
  14072. // 某些特殊情况下(比如页面进行redirectTo时的一些时机),pages可能为空数组
  14073. return "/".concat((_pages$route = (_pages = pages[pages.length - 1]) === null || _pages === void 0 ? void 0 : _pages.route) !== null && _pages$route !== void 0 ? _pages$route : '');
  14074. }
  14075. /**
  14076. * @description 获取当前路由栈实例数组
  14077. */
  14078. function pages() {
  14079. var pages = getCurrentPages();
  14080. return pages;
  14081. }
  14082. /**
  14083. * 获取页面历史栈指定层实例
  14084. * @param back {number} [0] - 0或者负数,表示获取历史栈的哪一层,0表示获取当前页面实例,-1 表示获取上一个页面实例。默认0。
  14085. */
  14086. function getHistoryPage() {
  14087. var back = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 0;
  14088. var pages = getCurrentPages();
  14089. var len = pages.length;
  14090. return pages[len - 1 + back];
  14091. }
  14092. /**
  14093. * @description 修改uView内置属性值
  14094. * @param {object} props 修改内置props属性
  14095. * @param {object} config 修改内置config属性
  14096. * @param {object} color 修改内置color属性
  14097. * @param {object} zIndex 修改内置zIndex属性
  14098. */
  14099. function setConfig(_ref5) {
  14100. var _ref5$props = _ref5.props,
  14101. props = _ref5$props === void 0 ? {} : _ref5$props,
  14102. _ref5$config = _ref5.config,
  14103. config = _ref5$config === void 0 ? {} : _ref5$config,
  14104. _ref5$color = _ref5.color,
  14105. color = _ref5$color === void 0 ? {} : _ref5$color,
  14106. _ref5$zIndex = _ref5.zIndex,
  14107. zIndex = _ref5$zIndex === void 0 ? {} : _ref5$zIndex;
  14108. var deepMerge = uni.$u.deepMerge;
  14109. uni.$u.config = deepMerge(uni.$u.config, config);
  14110. uni.$u.props = deepMerge(uni.$u.props, props);
  14111. uni.$u.color = deepMerge(uni.$u.color, color);
  14112. uni.$u.zIndex = deepMerge(uni.$u.zIndex, zIndex);
  14113. }
  14114. var _default = {
  14115. range: range,
  14116. getPx: getPx,
  14117. sleep: sleep,
  14118. os: os,
  14119. sys: sys,
  14120. random: random,
  14121. guid: guid,
  14122. $parent: $parent,
  14123. addStyle: addStyle,
  14124. addUnit: addUnit,
  14125. deepClone: deepClone,
  14126. deepMerge: deepMerge,
  14127. error: error,
  14128. randomArray: randomArray,
  14129. timeFormat: timeFormat,
  14130. timeFrom: timeFrom,
  14131. trim: trim,
  14132. queryParams: queryParams,
  14133. toast: toast,
  14134. type2icon: type2icon,
  14135. priceFormat: priceFormat,
  14136. getDuration: getDuration,
  14137. padZero: padZero,
  14138. formValidate: formValidate,
  14139. getProperty: getProperty,
  14140. setProperty: setProperty,
  14141. page: page,
  14142. pages: pages,
  14143. getHistoryPage: getHistoryPage,
  14144. setConfig: setConfig
  14145. };
  14146. exports.default = _default;
  14147. /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./node_modules/@dcloudio/uni-mp-toutiao/dist/index.js */ 1)["default"]))
  14148. /***/ }),
  14149. /* 62 */
  14150. /*!**********************************************************************************!*\
  14151. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/function/digit.js ***!
  14152. \**********************************************************************************/
  14153. /*! no static exports found */
  14154. /***/ (function(module, exports, __webpack_require__) {
  14155. "use strict";
  14156. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  14157. Object.defineProperty(exports, "__esModule", {
  14158. value: true
  14159. });
  14160. exports.default = void 0;
  14161. exports.divide = divide;
  14162. exports.enableBoundaryChecking = enableBoundaryChecking;
  14163. exports.minus = minus;
  14164. exports.plus = plus;
  14165. exports.round = round;
  14166. exports.times = times;
  14167. var _toArray2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/toArray */ 63));
  14168. var _boundaryCheckingState = true; // 是否进行越界检查的全局开关
  14169. /**
  14170. * 把错误的数据转正
  14171. * @private
  14172. * @example strip(0.09999999999999998)=0.1
  14173. */
  14174. function strip(num) {
  14175. var precision = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 15;
  14176. return +parseFloat(Number(num).toPrecision(precision));
  14177. }
  14178. /**
  14179. * Return digits length of a number
  14180. * @private
  14181. * @param {*number} num Input number
  14182. */
  14183. function digitLength(num) {
  14184. // Get digit length of e
  14185. var eSplit = num.toString().split(/[eE]/);
  14186. var len = (eSplit[0].split('.')[1] || '').length - +(eSplit[1] || 0);
  14187. return len > 0 ? len : 0;
  14188. }
  14189. /**
  14190. * 把小数转成整数,如果是小数则放大成整数
  14191. * @private
  14192. * @param {*number} num 输入数
  14193. */
  14194. function float2Fixed(num) {
  14195. if (num.toString().indexOf('e') === -1) {
  14196. return Number(num.toString().replace('.', ''));
  14197. }
  14198. var dLen = digitLength(num);
  14199. return dLen > 0 ? strip(Number(num) * Math.pow(10, dLen)) : Number(num);
  14200. }
  14201. /**
  14202. * 检测数字是否越界,如果越界给出提示
  14203. * @private
  14204. * @param {*number} num 输入数
  14205. */
  14206. function checkBoundary(num) {
  14207. if (_boundaryCheckingState) {
  14208. if (num > Number.MAX_SAFE_INTEGER || num < Number.MIN_SAFE_INTEGER) {
  14209. console.warn("".concat(num, " \u8D85\u51FA\u4E86\u7CBE\u5EA6\u9650\u5236\uFF0C\u7ED3\u679C\u53EF\u80FD\u4E0D\u6B63\u786E"));
  14210. }
  14211. }
  14212. }
  14213. /**
  14214. * 把递归操作扁平迭代化
  14215. * @param {number[]} arr 要操作的数字数组
  14216. * @param {function} operation 迭代操作
  14217. * @private
  14218. */
  14219. function iteratorOperation(arr, operation) {
  14220. var _arr = (0, _toArray2.default)(arr),
  14221. num1 = _arr[0],
  14222. num2 = _arr[1],
  14223. others = _arr.slice(2);
  14224. var res = operation(num1, num2);
  14225. others.forEach(function (num) {
  14226. res = operation(res, num);
  14227. });
  14228. return res;
  14229. }
  14230. /**
  14231. * 高精度乘法
  14232. * @export
  14233. */
  14234. function times() {
  14235. for (var _len = arguments.length, nums = new Array(_len), _key = 0; _key < _len; _key++) {
  14236. nums[_key] = arguments[_key];
  14237. }
  14238. if (nums.length > 2) {
  14239. return iteratorOperation(nums, times);
  14240. }
  14241. var num1 = nums[0],
  14242. num2 = nums[1];
  14243. var num1Changed = float2Fixed(num1);
  14244. var num2Changed = float2Fixed(num2);
  14245. var baseNum = digitLength(num1) + digitLength(num2);
  14246. var leftValue = num1Changed * num2Changed;
  14247. checkBoundary(leftValue);
  14248. return leftValue / Math.pow(10, baseNum);
  14249. }
  14250. /**
  14251. * 高精度加法
  14252. * @export
  14253. */
  14254. function plus() {
  14255. for (var _len2 = arguments.length, nums = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
  14256. nums[_key2] = arguments[_key2];
  14257. }
  14258. if (nums.length > 2) {
  14259. return iteratorOperation(nums, plus);
  14260. }
  14261. var num1 = nums[0],
  14262. num2 = nums[1];
  14263. // 取最大的小数位
  14264. var baseNum = Math.pow(10, Math.max(digitLength(num1), digitLength(num2)));
  14265. // 把小数都转为整数然后再计算
  14266. return (times(num1, baseNum) + times(num2, baseNum)) / baseNum;
  14267. }
  14268. /**
  14269. * 高精度减法
  14270. * @export
  14271. */
  14272. function minus() {
  14273. for (var _len3 = arguments.length, nums = new Array(_len3), _key3 = 0; _key3 < _len3; _key3++) {
  14274. nums[_key3] = arguments[_key3];
  14275. }
  14276. if (nums.length > 2) {
  14277. return iteratorOperation(nums, minus);
  14278. }
  14279. var num1 = nums[0],
  14280. num2 = nums[1];
  14281. var baseNum = Math.pow(10, Math.max(digitLength(num1), digitLength(num2)));
  14282. return (times(num1, baseNum) - times(num2, baseNum)) / baseNum;
  14283. }
  14284. /**
  14285. * 高精度除法
  14286. * @export
  14287. */
  14288. function divide() {
  14289. for (var _len4 = arguments.length, nums = new Array(_len4), _key4 = 0; _key4 < _len4; _key4++) {
  14290. nums[_key4] = arguments[_key4];
  14291. }
  14292. if (nums.length > 2) {
  14293. return iteratorOperation(nums, divide);
  14294. }
  14295. var num1 = nums[0],
  14296. num2 = nums[1];
  14297. var num1Changed = float2Fixed(num1);
  14298. var num2Changed = float2Fixed(num2);
  14299. checkBoundary(num1Changed);
  14300. checkBoundary(num2Changed);
  14301. // 重要,这里必须用strip进行修正
  14302. return times(num1Changed / num2Changed, strip(Math.pow(10, digitLength(num2) - digitLength(num1))));
  14303. }
  14304. /**
  14305. * 四舍五入
  14306. * @export
  14307. */
  14308. function round(num, ratio) {
  14309. var base = Math.pow(10, ratio);
  14310. var result = divide(Math.round(Math.abs(times(num, base))), base);
  14311. if (num < 0 && result !== 0) {
  14312. result = times(result, -1);
  14313. }
  14314. // 位数不足则补0
  14315. return result;
  14316. }
  14317. /**
  14318. * 是否进行边界检查,默认开启
  14319. * @param flag 标记开关,true 为开启,false 为关闭,默认为 true
  14320. * @export
  14321. */
  14322. function enableBoundaryChecking() {
  14323. var flag = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : true;
  14324. _boundaryCheckingState = flag;
  14325. }
  14326. var _default = {
  14327. times: times,
  14328. plus: plus,
  14329. minus: minus,
  14330. divide: divide,
  14331. round: round,
  14332. enableBoundaryChecking: enableBoundaryChecking
  14333. };
  14334. exports.default = _default;
  14335. /***/ }),
  14336. /* 63 */
  14337. /*!********************************************************!*\
  14338. !*** ./node_modules/@babel/runtime/helpers/toArray.js ***!
  14339. \********************************************************/
  14340. /*! no static exports found */
  14341. /***/ (function(module, exports, __webpack_require__) {
  14342. var arrayWithHoles = __webpack_require__(/*! ./arrayWithHoles.js */ 5);
  14343. var iterableToArray = __webpack_require__(/*! ./iterableToArray.js */ 21);
  14344. var unsupportedIterableToArray = __webpack_require__(/*! ./unsupportedIterableToArray.js */ 7);
  14345. var nonIterableRest = __webpack_require__(/*! ./nonIterableRest.js */ 9);
  14346. function _toArray(arr) {
  14347. return arrayWithHoles(arr) || iterableToArray(arr) || unsupportedIterableToArray(arr) || nonIterableRest();
  14348. }
  14349. module.exports = _toArray, module.exports.__esModule = true, module.exports["default"] = module.exports;
  14350. /***/ }),
  14351. /* 64 */
  14352. /*!*********************************************************************************!*\
  14353. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/config.js ***!
  14354. \*********************************************************************************/
  14355. /*! no static exports found */
  14356. /***/ (function(module, exports, __webpack_require__) {
  14357. "use strict";
  14358. Object.defineProperty(exports, "__esModule", {
  14359. value: true
  14360. });
  14361. exports.default = void 0;
  14362. // 此版本发布于2024-03-17
  14363. var version = '2.0.37';
  14364. var _default = {
  14365. v: version,
  14366. version: version,
  14367. // 主题名称
  14368. type: ['primary', 'success', 'info', 'error', 'warning'],
  14369. // 颜色部分,本来可以通过scss的:export导出供js使用,但是奈何nvue不支持
  14370. color: {
  14371. 'u-primary': '#2979ff',
  14372. 'u-warning': '#ff9900',
  14373. 'u-success': '#19be6b',
  14374. 'u-error': '#fa3534',
  14375. 'u-info': '#909399',
  14376. 'u-main-color': '#303133',
  14377. 'u-content-color': '#606266',
  14378. 'u-tips-color': '#909399',
  14379. 'u-light-color': '#c0c4cc'
  14380. },
  14381. // 默认单位,可以通过配置为rpx,那么在用于传入组件大小参数为数值时,就默认为rpx
  14382. unit: 'px'
  14383. };
  14384. exports.default = _default;
  14385. /***/ }),
  14386. /* 65 */
  14387. /*!********************************************************************************!*\
  14388. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props.js ***!
  14389. \********************************************************************************/
  14390. /*! no static exports found */
  14391. /***/ (function(module, exports, __webpack_require__) {
  14392. "use strict";
  14393. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  14394. Object.defineProperty(exports, "__esModule", {
  14395. value: true
  14396. });
  14397. exports.default = void 0;
  14398. var _defineProperty2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/defineProperty */ 10));
  14399. var _config = _interopRequireDefault(__webpack_require__(/*! ./config */ 64));
  14400. var _actionSheet = _interopRequireDefault(__webpack_require__(/*! ./props/actionSheet.js */ 66));
  14401. var _album = _interopRequireDefault(__webpack_require__(/*! ./props/album.js */ 67));
  14402. var _alert = _interopRequireDefault(__webpack_require__(/*! ./props/alert.js */ 68));
  14403. var _avatar = _interopRequireDefault(__webpack_require__(/*! ./props/avatar */ 69));
  14404. var _avatarGroup = _interopRequireDefault(__webpack_require__(/*! ./props/avatarGroup */ 70));
  14405. var _backtop = _interopRequireDefault(__webpack_require__(/*! ./props/backtop */ 71));
  14406. var _badge = _interopRequireDefault(__webpack_require__(/*! ./props/badge */ 72));
  14407. var _button = _interopRequireDefault(__webpack_require__(/*! ./props/button */ 73));
  14408. var _calendar = _interopRequireDefault(__webpack_require__(/*! ./props/calendar */ 74));
  14409. var _carKeyboard = _interopRequireDefault(__webpack_require__(/*! ./props/carKeyboard */ 75));
  14410. var _cell = _interopRequireDefault(__webpack_require__(/*! ./props/cell */ 76));
  14411. var _cellGroup = _interopRequireDefault(__webpack_require__(/*! ./props/cellGroup */ 77));
  14412. var _checkbox = _interopRequireDefault(__webpack_require__(/*! ./props/checkbox */ 78));
  14413. var _checkboxGroup = _interopRequireDefault(__webpack_require__(/*! ./props/checkboxGroup */ 79));
  14414. var _circleProgress = _interopRequireDefault(__webpack_require__(/*! ./props/circleProgress */ 80));
  14415. var _code = _interopRequireDefault(__webpack_require__(/*! ./props/code */ 81));
  14416. var _codeInput = _interopRequireDefault(__webpack_require__(/*! ./props/codeInput */ 82));
  14417. var _col = _interopRequireDefault(__webpack_require__(/*! ./props/col */ 83));
  14418. var _collapse = _interopRequireDefault(__webpack_require__(/*! ./props/collapse */ 84));
  14419. var _collapseItem = _interopRequireDefault(__webpack_require__(/*! ./props/collapseItem */ 85));
  14420. var _columnNotice = _interopRequireDefault(__webpack_require__(/*! ./props/columnNotice */ 86));
  14421. var _countDown = _interopRequireDefault(__webpack_require__(/*! ./props/countDown */ 87));
  14422. var _countTo = _interopRequireDefault(__webpack_require__(/*! ./props/countTo */ 88));
  14423. var _datetimePicker = _interopRequireDefault(__webpack_require__(/*! ./props/datetimePicker */ 89));
  14424. var _divider = _interopRequireDefault(__webpack_require__(/*! ./props/divider */ 90));
  14425. var _empty = _interopRequireDefault(__webpack_require__(/*! ./props/empty */ 91));
  14426. var _form = _interopRequireDefault(__webpack_require__(/*! ./props/form */ 92));
  14427. var _formItem = _interopRequireDefault(__webpack_require__(/*! ./props/formItem */ 93));
  14428. var _gap = _interopRequireDefault(__webpack_require__(/*! ./props/gap */ 94));
  14429. var _grid = _interopRequireDefault(__webpack_require__(/*! ./props/grid */ 95));
  14430. var _gridItem = _interopRequireDefault(__webpack_require__(/*! ./props/gridItem */ 96));
  14431. var _icon = _interopRequireDefault(__webpack_require__(/*! ./props/icon */ 97));
  14432. var _image = _interopRequireDefault(__webpack_require__(/*! ./props/image */ 98));
  14433. var _indexAnchor = _interopRequireDefault(__webpack_require__(/*! ./props/indexAnchor */ 99));
  14434. var _indexList = _interopRequireDefault(__webpack_require__(/*! ./props/indexList */ 100));
  14435. var _input = _interopRequireDefault(__webpack_require__(/*! ./props/input */ 101));
  14436. var _keyboard = _interopRequireDefault(__webpack_require__(/*! ./props/keyboard */ 102));
  14437. var _line = _interopRequireDefault(__webpack_require__(/*! ./props/line */ 103));
  14438. var _lineProgress = _interopRequireDefault(__webpack_require__(/*! ./props/lineProgress */ 104));
  14439. var _link = _interopRequireDefault(__webpack_require__(/*! ./props/link */ 105));
  14440. var _list = _interopRequireDefault(__webpack_require__(/*! ./props/list */ 106));
  14441. var _listItem = _interopRequireDefault(__webpack_require__(/*! ./props/listItem */ 107));
  14442. var _loadingIcon = _interopRequireDefault(__webpack_require__(/*! ./props/loadingIcon */ 108));
  14443. var _loadingPage = _interopRequireDefault(__webpack_require__(/*! ./props/loadingPage */ 109));
  14444. var _loadmore = _interopRequireDefault(__webpack_require__(/*! ./props/loadmore */ 110));
  14445. var _modal = _interopRequireDefault(__webpack_require__(/*! ./props/modal */ 111));
  14446. var _navbar = _interopRequireDefault(__webpack_require__(/*! ./props/navbar */ 112));
  14447. var _noNetwork = _interopRequireDefault(__webpack_require__(/*! ./props/noNetwork */ 114));
  14448. var _noticeBar = _interopRequireDefault(__webpack_require__(/*! ./props/noticeBar */ 115));
  14449. var _notify = _interopRequireDefault(__webpack_require__(/*! ./props/notify */ 116));
  14450. var _numberBox = _interopRequireDefault(__webpack_require__(/*! ./props/numberBox */ 117));
  14451. var _numberKeyboard = _interopRequireDefault(__webpack_require__(/*! ./props/numberKeyboard */ 118));
  14452. var _overlay = _interopRequireDefault(__webpack_require__(/*! ./props/overlay */ 119));
  14453. var _parse = _interopRequireDefault(__webpack_require__(/*! ./props/parse */ 120));
  14454. var _picker = _interopRequireDefault(__webpack_require__(/*! ./props/picker */ 121));
  14455. var _popup = _interopRequireDefault(__webpack_require__(/*! ./props/popup */ 122));
  14456. var _radio = _interopRequireDefault(__webpack_require__(/*! ./props/radio */ 123));
  14457. var _radioGroup = _interopRequireDefault(__webpack_require__(/*! ./props/radioGroup */ 124));
  14458. var _rate = _interopRequireDefault(__webpack_require__(/*! ./props/rate */ 125));
  14459. var _readMore = _interopRequireDefault(__webpack_require__(/*! ./props/readMore */ 126));
  14460. var _row = _interopRequireDefault(__webpack_require__(/*! ./props/row */ 127));
  14461. var _rowNotice = _interopRequireDefault(__webpack_require__(/*! ./props/rowNotice */ 128));
  14462. var _scrollList = _interopRequireDefault(__webpack_require__(/*! ./props/scrollList */ 129));
  14463. var _search = _interopRequireDefault(__webpack_require__(/*! ./props/search */ 130));
  14464. var _section = _interopRequireDefault(__webpack_require__(/*! ./props/section */ 131));
  14465. var _skeleton = _interopRequireDefault(__webpack_require__(/*! ./props/skeleton */ 132));
  14466. var _slider = _interopRequireDefault(__webpack_require__(/*! ./props/slider */ 133));
  14467. var _statusBar = _interopRequireDefault(__webpack_require__(/*! ./props/statusBar */ 134));
  14468. var _steps = _interopRequireDefault(__webpack_require__(/*! ./props/steps */ 135));
  14469. var _stepsItem = _interopRequireDefault(__webpack_require__(/*! ./props/stepsItem */ 136));
  14470. var _sticky = _interopRequireDefault(__webpack_require__(/*! ./props/sticky */ 137));
  14471. var _subsection = _interopRequireDefault(__webpack_require__(/*! ./props/subsection */ 138));
  14472. var _swipeAction = _interopRequireDefault(__webpack_require__(/*! ./props/swipeAction */ 139));
  14473. var _swipeActionItem = _interopRequireDefault(__webpack_require__(/*! ./props/swipeActionItem */ 140));
  14474. var _swiper = _interopRequireDefault(__webpack_require__(/*! ./props/swiper */ 141));
  14475. var _swipterIndicator = _interopRequireDefault(__webpack_require__(/*! ./props/swipterIndicator */ 142));
  14476. var _switch2 = _interopRequireDefault(__webpack_require__(/*! ./props/switch */ 143));
  14477. var _tabbar = _interopRequireDefault(__webpack_require__(/*! ./props/tabbar */ 144));
  14478. var _tabbarItem = _interopRequireDefault(__webpack_require__(/*! ./props/tabbarItem */ 145));
  14479. var _tabs = _interopRequireDefault(__webpack_require__(/*! ./props/tabs */ 146));
  14480. var _tag = _interopRequireDefault(__webpack_require__(/*! ./props/tag */ 147));
  14481. var _text = _interopRequireDefault(__webpack_require__(/*! ./props/text */ 148));
  14482. var _textarea = _interopRequireDefault(__webpack_require__(/*! ./props/textarea */ 149));
  14483. var _toast = _interopRequireDefault(__webpack_require__(/*! ./props/toast */ 150));
  14484. var _toolbar = _interopRequireDefault(__webpack_require__(/*! ./props/toolbar */ 151));
  14485. var _tooltip = _interopRequireDefault(__webpack_require__(/*! ./props/tooltip */ 152));
  14486. var _transition = _interopRequireDefault(__webpack_require__(/*! ./props/transition */ 153));
  14487. var _upload = _interopRequireDefault(__webpack_require__(/*! ./props/upload */ 154));
  14488. function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
  14489. function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { (0, _defineProperty2.default)(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
  14490. var color = _config.default.color;
  14491. var _default = _objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread({}, _actionSheet.default), _album.default), _alert.default), _avatar.default), _avatarGroup.default), _backtop.default), _badge.default), _button.default), _calendar.default), _carKeyboard.default), _cell.default), _cellGroup.default), _checkbox.default), _checkboxGroup.default), _circleProgress.default), _code.default), _codeInput.default), _col.default), _collapse.default), _collapseItem.default), _columnNotice.default), _countDown.default), _countTo.default), _datetimePicker.default), _divider.default), _empty.default), _form.default), _formItem.default), _gap.default), _grid.default), _gridItem.default), _icon.default), _image.default), _indexAnchor.default), _indexList.default), _input.default), _keyboard.default), _line.default), _lineProgress.default), _link.default), _list.default), _listItem.default), _loadingIcon.default), _loadingPage.default), _loadmore.default), _modal.default), _navbar.default), _noNetwork.default), _noticeBar.default), _notify.default), _numberBox.default), _numberKeyboard.default), _overlay.default), _parse.default), _picker.default), _popup.default), _radio.default), _radioGroup.default), _rate.default), _readMore.default), _row.default), _rowNotice.default), _scrollList.default), _search.default), _section.default), _skeleton.default), _slider.default), _statusBar.default), _steps.default), _stepsItem.default), _sticky.default), _subsection.default), _swipeAction.default), _swipeActionItem.default), _swiper.default), _swipterIndicator.default), _switch2.default), _tabbar.default), _tabbarItem.default), _tabs.default), _tag.default), _text.default), _textarea.default), _toast.default), _toolbar.default), _tooltip.default), _transition.default), _upload.default);
  14492. exports.default = _default;
  14493. /***/ }),
  14494. /* 66 */
  14495. /*!********************************************************************************************!*\
  14496. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/actionSheet.js ***!
  14497. \********************************************************************************************/
  14498. /*! no static exports found */
  14499. /***/ (function(module, exports, __webpack_require__) {
  14500. "use strict";
  14501. Object.defineProperty(exports, "__esModule", {
  14502. value: true
  14503. });
  14504. exports.default = void 0;
  14505. /*
  14506. * @Author : LQ
  14507. * @Description :
  14508. * @version : 1.0
  14509. * @Date : 2021-08-20 16:44:21
  14510. * @LastAuthor : LQ
  14511. * @lastTime : 2021-08-20 16:44:35
  14512. * @FilePath : /u-view2.0/uview-ui/libs/config/props/actionSheet.js
  14513. */
  14514. var _default = {
  14515. // action-sheet组件
  14516. actionSheet: {
  14517. show: false,
  14518. title: '',
  14519. description: '',
  14520. actions: function actions() {
  14521. return [];
  14522. },
  14523. index: '',
  14524. cancelText: '',
  14525. closeOnClickAction: true,
  14526. safeAreaInsetBottom: true,
  14527. openType: '',
  14528. closeOnClickOverlay: true,
  14529. round: 0
  14530. }
  14531. };
  14532. exports.default = _default;
  14533. /***/ }),
  14534. /* 67 */
  14535. /*!**************************************************************************************!*\
  14536. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/album.js ***!
  14537. \**************************************************************************************/
  14538. /*! no static exports found */
  14539. /***/ (function(module, exports, __webpack_require__) {
  14540. "use strict";
  14541. Object.defineProperty(exports, "__esModule", {
  14542. value: true
  14543. });
  14544. exports.default = void 0;
  14545. /*
  14546. * @Author : LQ
  14547. * @Description :
  14548. * @version : 1.0
  14549. * @Date : 2021-08-20 16:44:21
  14550. * @LastAuthor : LQ
  14551. * @lastTime : 2021-08-20 16:47:24
  14552. * @FilePath : /u-view2.0/uview-ui/libs/config/props/album.js
  14553. */
  14554. var _default = {
  14555. // album 组件
  14556. album: {
  14557. urls: function urls() {
  14558. return [];
  14559. },
  14560. keyName: '',
  14561. singleSize: 180,
  14562. multipleSize: 70,
  14563. space: 6,
  14564. singleMode: 'scaleToFill',
  14565. multipleMode: 'aspectFill',
  14566. maxCount: 9,
  14567. previewFullImage: true,
  14568. rowCount: 3,
  14569. showMore: true
  14570. }
  14571. };
  14572. exports.default = _default;
  14573. /***/ }),
  14574. /* 68 */
  14575. /*!**************************************************************************************!*\
  14576. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/alert.js ***!
  14577. \**************************************************************************************/
  14578. /*! no static exports found */
  14579. /***/ (function(module, exports, __webpack_require__) {
  14580. "use strict";
  14581. Object.defineProperty(exports, "__esModule", {
  14582. value: true
  14583. });
  14584. exports.default = void 0;
  14585. /*
  14586. * @Author : LQ
  14587. * @Description :
  14588. * @version : 1.0
  14589. * @Date : 2021-08-20 16:44:21
  14590. * @LastAuthor : LQ
  14591. * @lastTime : 2021-08-20 16:48:53
  14592. * @FilePath : /u-view2.0/uview-ui/libs/config/props/alert.js
  14593. */
  14594. var _default = {
  14595. // alert警告组件
  14596. alert: {
  14597. title: '',
  14598. type: 'warning',
  14599. description: '',
  14600. closable: false,
  14601. showIcon: false,
  14602. effect: 'light',
  14603. center: false,
  14604. fontSize: 14
  14605. }
  14606. };
  14607. exports.default = _default;
  14608. /***/ }),
  14609. /* 69 */
  14610. /*!***************************************************************************************!*\
  14611. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/avatar.js ***!
  14612. \***************************************************************************************/
  14613. /*! no static exports found */
  14614. /***/ (function(module, exports, __webpack_require__) {
  14615. "use strict";
  14616. Object.defineProperty(exports, "__esModule", {
  14617. value: true
  14618. });
  14619. exports.default = void 0;
  14620. /*
  14621. * @Author : LQ
  14622. * @Description :
  14623. * @version : 1.0
  14624. * @Date : 2021-08-20 16:44:21
  14625. * @LastAuthor : LQ
  14626. * @lastTime : 2021-08-20 16:49:22
  14627. * @FilePath : /u-view2.0/uview-ui/libs/config/props/avatar.js
  14628. */
  14629. var _default = {
  14630. // avatar 组件
  14631. avatar: {
  14632. src: '',
  14633. shape: 'circle',
  14634. size: 40,
  14635. mode: 'scaleToFill',
  14636. text: '',
  14637. bgColor: '#c0c4cc',
  14638. color: '#ffffff',
  14639. fontSize: 18,
  14640. icon: '',
  14641. mpAvatar: false,
  14642. randomBgColor: false,
  14643. defaultUrl: '',
  14644. colorIndex: '',
  14645. name: ''
  14646. }
  14647. };
  14648. exports.default = _default;
  14649. /***/ }),
  14650. /* 70 */
  14651. /*!********************************************************************************************!*\
  14652. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/avatarGroup.js ***!
  14653. \********************************************************************************************/
  14654. /*! no static exports found */
  14655. /***/ (function(module, exports, __webpack_require__) {
  14656. "use strict";
  14657. Object.defineProperty(exports, "__esModule", {
  14658. value: true
  14659. });
  14660. exports.default = void 0;
  14661. /*
  14662. * @Author : LQ
  14663. * @Description :
  14664. * @version : 1.0
  14665. * @Date : 2021-08-20 16:44:21
  14666. * @LastAuthor : LQ
  14667. * @lastTime : 2021-08-20 16:49:55
  14668. * @FilePath : /u-view2.0/uview-ui/libs/config/props/avatarGroup.js
  14669. */
  14670. var _default = {
  14671. // avatarGroup 组件
  14672. avatarGroup: {
  14673. urls: function urls() {
  14674. return [];
  14675. },
  14676. maxCount: 5,
  14677. shape: 'circle',
  14678. mode: 'scaleToFill',
  14679. showMore: true,
  14680. size: 40,
  14681. keyName: '',
  14682. gap: 0.5,
  14683. extraValue: 0
  14684. }
  14685. };
  14686. exports.default = _default;
  14687. /***/ }),
  14688. /* 71 */
  14689. /*!****************************************************************************************!*\
  14690. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/backtop.js ***!
  14691. \****************************************************************************************/
  14692. /*! no static exports found */
  14693. /***/ (function(module, exports, __webpack_require__) {
  14694. "use strict";
  14695. Object.defineProperty(exports, "__esModule", {
  14696. value: true
  14697. });
  14698. exports.default = void 0;
  14699. /*
  14700. * @Author : LQ
  14701. * @Description :
  14702. * @version : 1.0
  14703. * @Date : 2021-08-20 16:44:21
  14704. * @LastAuthor : LQ
  14705. * @lastTime : 2021-08-20 16:50:18
  14706. * @FilePath : /u-view2.0/uview-ui/libs/config/props/backtop.js
  14707. */
  14708. var _default = {
  14709. // backtop组件
  14710. backtop: {
  14711. mode: 'circle',
  14712. icon: 'arrow-upward',
  14713. text: '',
  14714. duration: 100,
  14715. scrollTop: 0,
  14716. top: 400,
  14717. bottom: 100,
  14718. right: 20,
  14719. zIndex: 9,
  14720. iconStyle: function iconStyle() {
  14721. return {
  14722. color: '#909399',
  14723. fontSize: '19px'
  14724. };
  14725. }
  14726. }
  14727. };
  14728. exports.default = _default;
  14729. /***/ }),
  14730. /* 72 */
  14731. /*!**************************************************************************************!*\
  14732. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/badge.js ***!
  14733. \**************************************************************************************/
  14734. /*! no static exports found */
  14735. /***/ (function(module, exports, __webpack_require__) {
  14736. "use strict";
  14737. Object.defineProperty(exports, "__esModule", {
  14738. value: true
  14739. });
  14740. exports.default = void 0;
  14741. /*
  14742. * @Author : LQ
  14743. * @Description :
  14744. * @version : 1.0
  14745. * @Date : 2021-08-20 16:44:21
  14746. * @LastAuthor : LQ
  14747. * @lastTime : 2021-08-23 19:51:50
  14748. * @FilePath : /u-view2.0/uview-ui/libs/config/props/badge.js
  14749. */
  14750. var _default = {
  14751. // 徽标数组件
  14752. badge: {
  14753. isDot: false,
  14754. value: '',
  14755. show: true,
  14756. max: 999,
  14757. type: 'error',
  14758. showZero: false,
  14759. bgColor: null,
  14760. color: null,
  14761. shape: 'circle',
  14762. numberType: 'overflow',
  14763. offset: function offset() {
  14764. return [];
  14765. },
  14766. inverted: false,
  14767. absolute: false
  14768. }
  14769. };
  14770. exports.default = _default;
  14771. /***/ }),
  14772. /* 73 */
  14773. /*!***************************************************************************************!*\
  14774. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/button.js ***!
  14775. \***************************************************************************************/
  14776. /*! no static exports found */
  14777. /***/ (function(module, exports, __webpack_require__) {
  14778. "use strict";
  14779. Object.defineProperty(exports, "__esModule", {
  14780. value: true
  14781. });
  14782. exports.default = void 0;
  14783. /*
  14784. * @Author : LQ
  14785. * @Description :
  14786. * @version : 1.0
  14787. * @Date : 2021-08-20 16:44:21
  14788. * @LastAuthor : LQ
  14789. * @lastTime : 2021-08-20 16:51:27
  14790. * @FilePath : /u-view2.0/uview-ui/libs/config/props/button.js
  14791. */
  14792. var _default = {
  14793. // button组件
  14794. button: {
  14795. hairline: false,
  14796. type: 'info',
  14797. size: 'normal',
  14798. shape: 'square',
  14799. plain: false,
  14800. disabled: false,
  14801. loading: false,
  14802. loadingText: '',
  14803. loadingMode: 'spinner',
  14804. loadingSize: 15,
  14805. openType: '',
  14806. formType: '',
  14807. appParameter: '',
  14808. hoverStopPropagation: true,
  14809. lang: 'en',
  14810. sessionFrom: '',
  14811. sendMessageTitle: '',
  14812. sendMessagePath: '',
  14813. sendMessageImg: '',
  14814. showMessageCard: false,
  14815. dataName: '',
  14816. throttleTime: 0,
  14817. hoverStartTime: 0,
  14818. hoverStayTime: 200,
  14819. text: '',
  14820. icon: '',
  14821. iconColor: '',
  14822. color: ''
  14823. }
  14824. };
  14825. exports.default = _default;
  14826. /***/ }),
  14827. /* 74 */
  14828. /*!*****************************************************************************************!*\
  14829. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/calendar.js ***!
  14830. \*****************************************************************************************/
  14831. /*! no static exports found */
  14832. /***/ (function(module, exports, __webpack_require__) {
  14833. "use strict";
  14834. Object.defineProperty(exports, "__esModule", {
  14835. value: true
  14836. });
  14837. exports.default = void 0;
  14838. /*
  14839. * @Author : LQ
  14840. * @Description :
  14841. * @version : 1.0
  14842. * @Date : 2021-08-20 16:44:21
  14843. * @LastAuthor : LQ
  14844. * @lastTime : 2021-08-20 16:52:43
  14845. * @FilePath : /u-view2.0/uview-ui/libs/config/props/calendar.js
  14846. */
  14847. var _default = {
  14848. // calendar 组件
  14849. calendar: {
  14850. title: '日期选择',
  14851. showTitle: true,
  14852. showSubtitle: true,
  14853. mode: 'single',
  14854. startText: '开始',
  14855. endText: '结束',
  14856. customList: function customList() {
  14857. return [];
  14858. },
  14859. color: '#3c9cff',
  14860. minDate: 0,
  14861. maxDate: 0,
  14862. defaultDate: null,
  14863. maxCount: Number.MAX_SAFE_INTEGER,
  14864. // Infinity
  14865. rowHeight: 56,
  14866. formatter: null,
  14867. showLunar: false,
  14868. showMark: true,
  14869. confirmText: '确定',
  14870. confirmDisabledText: '确定',
  14871. show: false,
  14872. closeOnClickOverlay: false,
  14873. readonly: false,
  14874. showConfirm: true,
  14875. maxRange: Number.MAX_SAFE_INTEGER,
  14876. // Infinity
  14877. rangePrompt: '',
  14878. showRangePrompt: true,
  14879. allowSameDay: false,
  14880. round: 0,
  14881. monthNum: 3
  14882. }
  14883. };
  14884. exports.default = _default;
  14885. /***/ }),
  14886. /* 75 */
  14887. /*!********************************************************************************************!*\
  14888. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/carKeyboard.js ***!
  14889. \********************************************************************************************/
  14890. /*! no static exports found */
  14891. /***/ (function(module, exports, __webpack_require__) {
  14892. "use strict";
  14893. Object.defineProperty(exports, "__esModule", {
  14894. value: true
  14895. });
  14896. exports.default = void 0;
  14897. /*
  14898. * @Author : LQ
  14899. * @Description :
  14900. * @version : 1.0
  14901. * @Date : 2021-08-20 16:44:21
  14902. * @LastAuthor : LQ
  14903. * @lastTime : 2021-08-20 16:53:20
  14904. * @FilePath : /u-view2.0/uview-ui/libs/config/props/carKeyboard.js
  14905. */
  14906. var _default = {
  14907. // 车牌号键盘
  14908. carKeyboard: {
  14909. random: false
  14910. }
  14911. };
  14912. exports.default = _default;
  14913. /***/ }),
  14914. /* 76 */
  14915. /*!*************************************************************************************!*\
  14916. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/cell.js ***!
  14917. \*************************************************************************************/
  14918. /*! no static exports found */
  14919. /***/ (function(module, exports, __webpack_require__) {
  14920. "use strict";
  14921. Object.defineProperty(exports, "__esModule", {
  14922. value: true
  14923. });
  14924. exports.default = void 0;
  14925. /*
  14926. * @Author : LQ
  14927. * @Description :
  14928. * @version : 1.0
  14929. * @Date : 2021-08-20 16:44:21
  14930. * @LastAuthor : LQ
  14931. * @lastTime : 2021-08-23 20:53:09
  14932. * @FilePath : /u-view2.0/uview-ui/libs/config/props/cell.js
  14933. */
  14934. var _default = {
  14935. // cell组件的props
  14936. cell: {
  14937. customClass: '',
  14938. title: '',
  14939. label: '',
  14940. value: '',
  14941. icon: '',
  14942. disabled: false,
  14943. border: true,
  14944. center: false,
  14945. url: '',
  14946. linkType: 'navigateTo',
  14947. clickable: false,
  14948. isLink: false,
  14949. required: false,
  14950. arrowDirection: '',
  14951. iconStyle: {},
  14952. rightIconStyle: {},
  14953. rightIcon: 'arrow-right',
  14954. titleStyle: {},
  14955. size: '',
  14956. stop: true,
  14957. name: ''
  14958. }
  14959. };
  14960. exports.default = _default;
  14961. /***/ }),
  14962. /* 77 */
  14963. /*!******************************************************************************************!*\
  14964. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/cellGroup.js ***!
  14965. \******************************************************************************************/
  14966. /*! no static exports found */
  14967. /***/ (function(module, exports, __webpack_require__) {
  14968. "use strict";
  14969. Object.defineProperty(exports, "__esModule", {
  14970. value: true
  14971. });
  14972. exports.default = void 0;
  14973. /*
  14974. * @Author : LQ
  14975. * @Description :
  14976. * @version : 1.0
  14977. * @Date : 2021-08-20 16:44:21
  14978. * @LastAuthor : LQ
  14979. * @lastTime : 2021-08-20 16:54:16
  14980. * @FilePath : /u-view2.0/uview-ui/libs/config/props/cellGroup.js
  14981. */
  14982. var _default = {
  14983. // cell-group组件的props
  14984. cellGroup: {
  14985. title: '',
  14986. border: true,
  14987. customStyle: {}
  14988. }
  14989. };
  14990. exports.default = _default;
  14991. /***/ }),
  14992. /* 78 */
  14993. /*!*****************************************************************************************!*\
  14994. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/checkbox.js ***!
  14995. \*****************************************************************************************/
  14996. /*! no static exports found */
  14997. /***/ (function(module, exports, __webpack_require__) {
  14998. "use strict";
  14999. Object.defineProperty(exports, "__esModule", {
  15000. value: true
  15001. });
  15002. exports.default = void 0;
  15003. /*
  15004. * @Author : LQ
  15005. * @Description :
  15006. * @version : 1.0
  15007. * @Date : 2021-08-20 16:44:21
  15008. * @LastAuthor : LQ
  15009. * @lastTime : 2021-08-23 21:06:59
  15010. * @FilePath : /u-view2.0/uview-ui/libs/config/props/checkbox.js
  15011. */
  15012. var _default = {
  15013. // checkbox组件
  15014. checkbox: {
  15015. name: '',
  15016. shape: '',
  15017. size: '',
  15018. checkbox: false,
  15019. disabled: '',
  15020. activeColor: '',
  15021. inactiveColor: '',
  15022. iconSize: '',
  15023. iconColor: '',
  15024. label: '',
  15025. labelSize: '',
  15026. labelColor: '',
  15027. labelDisabled: ''
  15028. }
  15029. };
  15030. exports.default = _default;
  15031. /***/ }),
  15032. /* 79 */
  15033. /*!**********************************************************************************************!*\
  15034. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/checkboxGroup.js ***!
  15035. \**********************************************************************************************/
  15036. /*! no static exports found */
  15037. /***/ (function(module, exports, __webpack_require__) {
  15038. "use strict";
  15039. Object.defineProperty(exports, "__esModule", {
  15040. value: true
  15041. });
  15042. exports.default = void 0;
  15043. /*
  15044. * @Author : LQ
  15045. * @Description :
  15046. * @version : 1.0
  15047. * @Date : 2021-08-20 16:44:21
  15048. * @LastAuthor : LQ
  15049. * @lastTime : 2021-08-20 16:54:47
  15050. * @FilePath : /u-view2.0/uview-ui/libs/config/props/checkboxGroup.js
  15051. */
  15052. var _default = {
  15053. // checkbox-group组件
  15054. checkboxGroup: {
  15055. name: '',
  15056. value: function value() {
  15057. return [];
  15058. },
  15059. shape: 'square',
  15060. disabled: false,
  15061. activeColor: '#2979ff',
  15062. inactiveColor: '#c8c9cc',
  15063. size: 18,
  15064. placement: 'row',
  15065. labelSize: 14,
  15066. labelColor: '#303133',
  15067. labelDisabled: false,
  15068. iconColor: '#ffffff',
  15069. iconSize: 12,
  15070. iconPlacement: 'left',
  15071. borderBottom: false
  15072. }
  15073. };
  15074. exports.default = _default;
  15075. /***/ }),
  15076. /* 80 */
  15077. /*!***********************************************************************************************!*\
  15078. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/circleProgress.js ***!
  15079. \***********************************************************************************************/
  15080. /*! no static exports found */
  15081. /***/ (function(module, exports, __webpack_require__) {
  15082. "use strict";
  15083. Object.defineProperty(exports, "__esModule", {
  15084. value: true
  15085. });
  15086. exports.default = void 0;
  15087. /*
  15088. * @Author : LQ
  15089. * @Description :
  15090. * @version : 1.0
  15091. * @Date : 2021-08-20 16:44:21
  15092. * @LastAuthor : LQ
  15093. * @lastTime : 2021-08-20 16:55:02
  15094. * @FilePath : /u-view2.0/uview-ui/libs/config/props/circleProgress.js
  15095. */
  15096. var _default = {
  15097. // circleProgress 组件
  15098. circleProgress: {
  15099. percentage: 30
  15100. }
  15101. };
  15102. exports.default = _default;
  15103. /***/ }),
  15104. /* 81 */
  15105. /*!*************************************************************************************!*\
  15106. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/code.js ***!
  15107. \*************************************************************************************/
  15108. /*! no static exports found */
  15109. /***/ (function(module, exports, __webpack_require__) {
  15110. "use strict";
  15111. Object.defineProperty(exports, "__esModule", {
  15112. value: true
  15113. });
  15114. exports.default = void 0;
  15115. /*
  15116. * @Author : LQ
  15117. * @Description :
  15118. * @version : 1.0
  15119. * @Date : 2021-08-20 16:44:21
  15120. * @LastAuthor : LQ
  15121. * @lastTime : 2021-08-20 16:55:27
  15122. * @FilePath : /u-view2.0/uview-ui/libs/config/props/code.js
  15123. */
  15124. var _default = {
  15125. // code 组件
  15126. code: {
  15127. seconds: 60,
  15128. startText: '获取验证码',
  15129. changeText: 'X秒重新获取',
  15130. endText: '重新获取',
  15131. keepRunning: false,
  15132. uniqueKey: ''
  15133. }
  15134. };
  15135. exports.default = _default;
  15136. /***/ }),
  15137. /* 82 */
  15138. /*!******************************************************************************************!*\
  15139. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/codeInput.js ***!
  15140. \******************************************************************************************/
  15141. /*! no static exports found */
  15142. /***/ (function(module, exports, __webpack_require__) {
  15143. "use strict";
  15144. Object.defineProperty(exports, "__esModule", {
  15145. value: true
  15146. });
  15147. exports.default = void 0;
  15148. /*
  15149. * @Author : LQ
  15150. * @Description :
  15151. * @version : 1.0
  15152. * @Date : 2021-08-20 16:44:21
  15153. * @LastAuthor : LQ
  15154. * @lastTime : 2021-08-20 16:55:58
  15155. * @FilePath : /u-view2.0/uview-ui/libs/config/props/codeInput.js
  15156. */
  15157. var _default = {
  15158. // codeInput 组件
  15159. codeInput: {
  15160. adjustPosition: true,
  15161. maxlength: 6,
  15162. dot: false,
  15163. mode: 'box',
  15164. hairline: false,
  15165. space: 10,
  15166. value: '',
  15167. focus: false,
  15168. bold: false,
  15169. color: '#606266',
  15170. fontSize: 18,
  15171. size: 35,
  15172. disabledKeyboard: false,
  15173. borderColor: '#c9cacc',
  15174. disabledDot: true
  15175. }
  15176. };
  15177. exports.default = _default;
  15178. /***/ }),
  15179. /* 83 */
  15180. /*!************************************************************************************!*\
  15181. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/col.js ***!
  15182. \************************************************************************************/
  15183. /*! no static exports found */
  15184. /***/ (function(module, exports, __webpack_require__) {
  15185. "use strict";
  15186. Object.defineProperty(exports, "__esModule", {
  15187. value: true
  15188. });
  15189. exports.default = void 0;
  15190. /*
  15191. * @Author : LQ
  15192. * @Description :
  15193. * @version : 1.0
  15194. * @Date : 2021-08-20 16:44:21
  15195. * @LastAuthor : LQ
  15196. * @lastTime : 2021-08-20 16:56:12
  15197. * @FilePath : /u-view2.0/uview-ui/libs/config/props/col.js
  15198. */
  15199. var _default = {
  15200. // col 组件
  15201. col: {
  15202. span: 12,
  15203. offset: 0,
  15204. justify: 'start',
  15205. align: 'stretch',
  15206. textAlign: 'left'
  15207. }
  15208. };
  15209. exports.default = _default;
  15210. /***/ }),
  15211. /* 84 */
  15212. /*!*****************************************************************************************!*\
  15213. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/collapse.js ***!
  15214. \*****************************************************************************************/
  15215. /*! no static exports found */
  15216. /***/ (function(module, exports, __webpack_require__) {
  15217. "use strict";
  15218. Object.defineProperty(exports, "__esModule", {
  15219. value: true
  15220. });
  15221. exports.default = void 0;
  15222. /*
  15223. * @Author : LQ
  15224. * @Description :
  15225. * @version : 1.0
  15226. * @Date : 2021-08-20 16:44:21
  15227. * @LastAuthor : LQ
  15228. * @lastTime : 2021-08-20 16:56:30
  15229. * @FilePath : /u-view2.0/uview-ui/libs/config/props/collapse.js
  15230. */
  15231. var _default = {
  15232. // collapse 组件
  15233. collapse: {
  15234. value: null,
  15235. accordion: false,
  15236. border: true
  15237. }
  15238. };
  15239. exports.default = _default;
  15240. /***/ }),
  15241. /* 85 */
  15242. /*!*********************************************************************************************!*\
  15243. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/collapseItem.js ***!
  15244. \*********************************************************************************************/
  15245. /*! no static exports found */
  15246. /***/ (function(module, exports, __webpack_require__) {
  15247. "use strict";
  15248. Object.defineProperty(exports, "__esModule", {
  15249. value: true
  15250. });
  15251. exports.default = void 0;
  15252. /*
  15253. * @Author : LQ
  15254. * @Description :
  15255. * @version : 1.0
  15256. * @Date : 2021-08-20 16:44:21
  15257. * @LastAuthor : LQ
  15258. * @lastTime : 2021-08-20 16:56:42
  15259. * @FilePath : /u-view2.0/uview-ui/libs/config/props/collapseItem.js
  15260. */
  15261. var _default = {
  15262. // collapseItem 组件
  15263. collapseItem: {
  15264. title: '',
  15265. value: '',
  15266. label: '',
  15267. disabled: false,
  15268. isLink: true,
  15269. clickable: true,
  15270. border: true,
  15271. align: 'left',
  15272. name: '',
  15273. icon: '',
  15274. duration: 300
  15275. }
  15276. };
  15277. exports.default = _default;
  15278. /***/ }),
  15279. /* 86 */
  15280. /*!*********************************************************************************************!*\
  15281. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/columnNotice.js ***!
  15282. \*********************************************************************************************/
  15283. /*! no static exports found */
  15284. /***/ (function(module, exports, __webpack_require__) {
  15285. "use strict";
  15286. Object.defineProperty(exports, "__esModule", {
  15287. value: true
  15288. });
  15289. exports.default = void 0;
  15290. /*
  15291. * @Author : LQ
  15292. * @Description :
  15293. * @version : 1.0
  15294. * @Date : 2021-08-20 16:44:21
  15295. * @LastAuthor : LQ
  15296. * @lastTime : 2021-08-20 16:57:16
  15297. * @FilePath : /u-view2.0/uview-ui/libs/config/props/columnNotice.js
  15298. */
  15299. var _default = {
  15300. // columnNotice 组件
  15301. columnNotice: {
  15302. text: '',
  15303. icon: 'volume',
  15304. mode: '',
  15305. color: '#f9ae3d',
  15306. bgColor: '#fdf6ec',
  15307. fontSize: 14,
  15308. speed: 80,
  15309. step: false,
  15310. duration: 1500,
  15311. disableTouch: true
  15312. }
  15313. };
  15314. exports.default = _default;
  15315. /***/ }),
  15316. /* 87 */
  15317. /*!******************************************************************************************!*\
  15318. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/countDown.js ***!
  15319. \******************************************************************************************/
  15320. /*! no static exports found */
  15321. /***/ (function(module, exports, __webpack_require__) {
  15322. "use strict";
  15323. Object.defineProperty(exports, "__esModule", {
  15324. value: true
  15325. });
  15326. exports.default = void 0;
  15327. /*
  15328. * @Author : LQ
  15329. * @Description :
  15330. * @version : 1.0
  15331. * @Date : 2021-08-20 16:44:21
  15332. * @LastAuthor : LQ
  15333. * @lastTime : 2021-08-20 17:11:29
  15334. * @FilePath : /u-view2.0/uview-ui/libs/config/props/countDown.js
  15335. */
  15336. var _default = {
  15337. // u-count-down 计时器组件
  15338. countDown: {
  15339. time: 0,
  15340. format: 'HH:mm:ss',
  15341. autoStart: true,
  15342. millisecond: false
  15343. }
  15344. };
  15345. exports.default = _default;
  15346. /***/ }),
  15347. /* 88 */
  15348. /*!****************************************************************************************!*\
  15349. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/countTo.js ***!
  15350. \****************************************************************************************/
  15351. /*! no static exports found */
  15352. /***/ (function(module, exports, __webpack_require__) {
  15353. "use strict";
  15354. Object.defineProperty(exports, "__esModule", {
  15355. value: true
  15356. });
  15357. exports.default = void 0;
  15358. /*
  15359. * @Author : LQ
  15360. * @Description :
  15361. * @version : 1.0
  15362. * @Date : 2021-08-20 16:44:21
  15363. * @LastAuthor : LQ
  15364. * @lastTime : 2021-08-20 16:57:32
  15365. * @FilePath : /u-view2.0/uview-ui/libs/config/props/countTo.js
  15366. */
  15367. var _default = {
  15368. // countTo 组件
  15369. countTo: {
  15370. startVal: 0,
  15371. endVal: 0,
  15372. duration: 2000,
  15373. autoplay: true,
  15374. decimals: 0,
  15375. useEasing: true,
  15376. decimal: '.',
  15377. color: '#606266',
  15378. fontSize: 22,
  15379. bold: false,
  15380. separator: ''
  15381. }
  15382. };
  15383. exports.default = _default;
  15384. /***/ }),
  15385. /* 89 */
  15386. /*!***********************************************************************************************!*\
  15387. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/datetimePicker.js ***!
  15388. \***********************************************************************************************/
  15389. /*! no static exports found */
  15390. /***/ (function(module, exports, __webpack_require__) {
  15391. "use strict";
  15392. Object.defineProperty(exports, "__esModule", {
  15393. value: true
  15394. });
  15395. exports.default = void 0;
  15396. /*
  15397. * @Author : LQ
  15398. * @Description :
  15399. * @version : 1.0
  15400. * @Date : 2021-08-20 16:44:21
  15401. * @LastAuthor : LQ
  15402. * @lastTime : 2021-08-20 16:57:48
  15403. * @FilePath : /u-view2.0/uview-ui/libs/config/props/datetimePicker.js
  15404. */
  15405. var _default = {
  15406. // datetimePicker 组件
  15407. datetimePicker: {
  15408. show: false,
  15409. showToolbar: true,
  15410. value: '',
  15411. title: '',
  15412. mode: 'datetime',
  15413. maxDate: new Date(new Date().getFullYear() + 10, 0, 1).getTime(),
  15414. minDate: new Date(new Date().getFullYear() - 10, 0, 1).getTime(),
  15415. minHour: 0,
  15416. maxHour: 23,
  15417. minMinute: 0,
  15418. maxMinute: 59,
  15419. filter: null,
  15420. formatter: null,
  15421. loading: false,
  15422. itemHeight: 44,
  15423. cancelText: '取消',
  15424. confirmText: '确认',
  15425. cancelColor: '#909193',
  15426. confirmColor: '#3c9cff',
  15427. visibleItemCount: 5,
  15428. closeOnClickOverlay: false,
  15429. defaultIndex: function defaultIndex() {
  15430. return [];
  15431. }
  15432. }
  15433. };
  15434. exports.default = _default;
  15435. /***/ }),
  15436. /* 90 */
  15437. /*!****************************************************************************************!*\
  15438. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/divider.js ***!
  15439. \****************************************************************************************/
  15440. /*! no static exports found */
  15441. /***/ (function(module, exports, __webpack_require__) {
  15442. "use strict";
  15443. Object.defineProperty(exports, "__esModule", {
  15444. value: true
  15445. });
  15446. exports.default = void 0;
  15447. /*
  15448. * @Author : LQ
  15449. * @Description :
  15450. * @version : 1.0
  15451. * @Date : 2021-08-20 16:44:21
  15452. * @LastAuthor : LQ
  15453. * @lastTime : 2021-08-20 16:58:03
  15454. * @FilePath : /u-view2.0/uview-ui/libs/config/props/divider.js
  15455. */
  15456. var _default = {
  15457. // divider组件
  15458. divider: {
  15459. dashed: false,
  15460. hairline: true,
  15461. dot: false,
  15462. textPosition: 'center',
  15463. text: '',
  15464. textSize: 14,
  15465. textColor: '#909399',
  15466. lineColor: '#dcdfe6'
  15467. }
  15468. };
  15469. exports.default = _default;
  15470. /***/ }),
  15471. /* 91 */
  15472. /*!**************************************************************************************!*\
  15473. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/empty.js ***!
  15474. \**************************************************************************************/
  15475. /*! no static exports found */
  15476. /***/ (function(module, exports, __webpack_require__) {
  15477. "use strict";
  15478. Object.defineProperty(exports, "__esModule", {
  15479. value: true
  15480. });
  15481. exports.default = void 0;
  15482. /*
  15483. * @Author : LQ
  15484. * @Description :
  15485. * @version : 1.0
  15486. * @Date : 2021-08-20 16:44:21
  15487. * @LastAuthor : LQ
  15488. * @lastTime : 2021-08-20 17:03:27
  15489. * @FilePath : /u-view2.0/uview-ui/libs/config/props/empty.js
  15490. */
  15491. var _default = {
  15492. // empty组件
  15493. empty: {
  15494. icon: '',
  15495. text: '',
  15496. textColor: '#c0c4cc',
  15497. textSize: 14,
  15498. iconColor: '#c0c4cc',
  15499. iconSize: 90,
  15500. mode: 'data',
  15501. width: 160,
  15502. height: 160,
  15503. show: true,
  15504. marginTop: 0
  15505. }
  15506. };
  15507. exports.default = _default;
  15508. /***/ }),
  15509. /* 92 */
  15510. /*!*************************************************************************************!*\
  15511. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/form.js ***!
  15512. \*************************************************************************************/
  15513. /*! no static exports found */
  15514. /***/ (function(module, exports, __webpack_require__) {
  15515. "use strict";
  15516. Object.defineProperty(exports, "__esModule", {
  15517. value: true
  15518. });
  15519. exports.default = void 0;
  15520. /*
  15521. * @Author : LQ
  15522. * @Description :
  15523. * @version : 1.0
  15524. * @Date : 2021-08-20 16:44:21
  15525. * @LastAuthor : LQ
  15526. * @lastTime : 2021-08-20 17:03:49
  15527. * @FilePath : /u-view2.0/uview-ui/libs/config/props/form.js
  15528. */
  15529. var _default = {
  15530. // form 组件
  15531. form: {
  15532. model: function model() {
  15533. return {};
  15534. },
  15535. rules: function rules() {
  15536. return {};
  15537. },
  15538. errorType: 'message',
  15539. borderBottom: true,
  15540. labelPosition: 'left',
  15541. labelWidth: 45,
  15542. labelAlign: 'left',
  15543. labelStyle: function labelStyle() {
  15544. return {};
  15545. }
  15546. }
  15547. };
  15548. exports.default = _default;
  15549. /***/ }),
  15550. /* 93 */
  15551. /*!*****************************************************************************************!*\
  15552. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/formItem.js ***!
  15553. \*****************************************************************************************/
  15554. /*! no static exports found */
  15555. /***/ (function(module, exports, __webpack_require__) {
  15556. "use strict";
  15557. Object.defineProperty(exports, "__esModule", {
  15558. value: true
  15559. });
  15560. exports.default = void 0;
  15561. /*
  15562. * @Author : LQ
  15563. * @Description :
  15564. * @version : 1.0
  15565. * @Date : 2021-08-20 16:44:21
  15566. * @LastAuthor : LQ
  15567. * @lastTime : 2021-08-20 17:04:32
  15568. * @FilePath : /u-view2.0/uview-ui/libs/config/props/formItem.js
  15569. */
  15570. var _default = {
  15571. // formItem 组件
  15572. formItem: {
  15573. label: '',
  15574. prop: '',
  15575. borderBottom: '',
  15576. labelPosition: '',
  15577. labelWidth: '',
  15578. rightIcon: '',
  15579. leftIcon: '',
  15580. required: false,
  15581. leftIconStyle: ''
  15582. }
  15583. };
  15584. exports.default = _default;
  15585. /***/ }),
  15586. /* 94 */
  15587. /*!************************************************************************************!*\
  15588. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/gap.js ***!
  15589. \************************************************************************************/
  15590. /*! no static exports found */
  15591. /***/ (function(module, exports, __webpack_require__) {
  15592. "use strict";
  15593. Object.defineProperty(exports, "__esModule", {
  15594. value: true
  15595. });
  15596. exports.default = void 0;
  15597. /*
  15598. * @Author : LQ
  15599. * @Description :
  15600. * @version : 1.0
  15601. * @Date : 2021-08-20 16:44:21
  15602. * @LastAuthor : LQ
  15603. * @lastTime : 2021-08-20 17:05:25
  15604. * @FilePath : /u-view2.0/uview-ui/libs/config/props/gap.js
  15605. */
  15606. var _default = {
  15607. // gap组件
  15608. gap: {
  15609. bgColor: 'transparent',
  15610. height: 20,
  15611. marginTop: 0,
  15612. marginBottom: 0,
  15613. customStyle: {}
  15614. }
  15615. };
  15616. exports.default = _default;
  15617. /***/ }),
  15618. /* 95 */
  15619. /*!*************************************************************************************!*\
  15620. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/grid.js ***!
  15621. \*************************************************************************************/
  15622. /*! no static exports found */
  15623. /***/ (function(module, exports, __webpack_require__) {
  15624. "use strict";
  15625. Object.defineProperty(exports, "__esModule", {
  15626. value: true
  15627. });
  15628. exports.default = void 0;
  15629. /*
  15630. * @Author : LQ
  15631. * @Description :
  15632. * @version : 1.0
  15633. * @Date : 2021-08-20 16:44:21
  15634. * @LastAuthor : LQ
  15635. * @lastTime : 2021-08-20 17:05:57
  15636. * @FilePath : /u-view2.0/uview-ui/libs/config/props/grid.js
  15637. */
  15638. var _default = {
  15639. // grid组件
  15640. grid: {
  15641. col: 3,
  15642. border: false,
  15643. align: 'left'
  15644. }
  15645. };
  15646. exports.default = _default;
  15647. /***/ }),
  15648. /* 96 */
  15649. /*!*****************************************************************************************!*\
  15650. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/gridItem.js ***!
  15651. \*****************************************************************************************/
  15652. /*! no static exports found */
  15653. /***/ (function(module, exports, __webpack_require__) {
  15654. "use strict";
  15655. Object.defineProperty(exports, "__esModule", {
  15656. value: true
  15657. });
  15658. exports.default = void 0;
  15659. /*
  15660. * @Author : LQ
  15661. * @Description :
  15662. * @version : 1.0
  15663. * @Date : 2021-08-20 16:44:21
  15664. * @LastAuthor : LQ
  15665. * @lastTime : 2021-08-20 17:06:13
  15666. * @FilePath : /u-view2.0/uview-ui/libs/config/props/gridItem.js
  15667. */
  15668. var _default = {
  15669. // grid-item组件
  15670. gridItem: {
  15671. name: null,
  15672. bgColor: 'transparent'
  15673. }
  15674. };
  15675. exports.default = _default;
  15676. /***/ }),
  15677. /* 97 */
  15678. /*!*************************************************************************************!*\
  15679. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/icon.js ***!
  15680. \*************************************************************************************/
  15681. /*! no static exports found */
  15682. /***/ (function(module, exports, __webpack_require__) {
  15683. "use strict";
  15684. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  15685. Object.defineProperty(exports, "__esModule", {
  15686. value: true
  15687. });
  15688. exports.default = void 0;
  15689. var _config = _interopRequireDefault(__webpack_require__(/*! ../config */ 64));
  15690. /*
  15691. * @Author : LQ
  15692. * @Description :
  15693. * @version : 1.0
  15694. * @Date : 2021-08-20 16:44:21
  15695. * @LastAuthor : LQ
  15696. * @lastTime : 2021-08-20 18:00:14
  15697. * @FilePath : /u-view2.0/uview-ui/libs/config/props/icon.js
  15698. */
  15699. var color = _config.default.color;
  15700. var _default = {
  15701. // icon组件
  15702. icon: {
  15703. name: '',
  15704. color: color['u-content-color'],
  15705. size: '16px',
  15706. bold: false,
  15707. index: '',
  15708. hoverClass: '',
  15709. customPrefix: 'uicon',
  15710. label: '',
  15711. labelPos: 'right',
  15712. labelSize: '15px',
  15713. labelColor: color['u-content-color'],
  15714. space: '3px',
  15715. imgMode: '',
  15716. width: '',
  15717. height: '',
  15718. top: 0,
  15719. stop: false
  15720. }
  15721. };
  15722. exports.default = _default;
  15723. /***/ }),
  15724. /* 98 */
  15725. /*!**************************************************************************************!*\
  15726. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/image.js ***!
  15727. \**************************************************************************************/
  15728. /*! no static exports found */
  15729. /***/ (function(module, exports, __webpack_require__) {
  15730. "use strict";
  15731. Object.defineProperty(exports, "__esModule", {
  15732. value: true
  15733. });
  15734. exports.default = void 0;
  15735. /*
  15736. * @Author : LQ
  15737. * @Description :
  15738. * @version : 1.0
  15739. * @Date : 2021-08-20 16:44:21
  15740. * @LastAuthor : LQ
  15741. * @lastTime : 2021-08-20 17:01:51
  15742. * @FilePath : /u-view2.0/uview-ui/libs/config/props/image.js
  15743. */
  15744. var _default = {
  15745. // image组件
  15746. image: {
  15747. src: '',
  15748. mode: 'aspectFill',
  15749. width: '300',
  15750. height: '225',
  15751. shape: 'square',
  15752. radius: 0,
  15753. lazyLoad: true,
  15754. showMenuByLongpress: true,
  15755. loadingIcon: 'photo',
  15756. errorIcon: 'error-circle',
  15757. showLoading: true,
  15758. showError: true,
  15759. fade: true,
  15760. webp: false,
  15761. duration: 500,
  15762. bgColor: '#f3f4f6'
  15763. }
  15764. };
  15765. exports.default = _default;
  15766. /***/ }),
  15767. /* 99 */
  15768. /*!********************************************************************************************!*\
  15769. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/indexAnchor.js ***!
  15770. \********************************************************************************************/
  15771. /*! no static exports found */
  15772. /***/ (function(module, exports, __webpack_require__) {
  15773. "use strict";
  15774. Object.defineProperty(exports, "__esModule", {
  15775. value: true
  15776. });
  15777. exports.default = void 0;
  15778. /*
  15779. * @Author : LQ
  15780. * @Description :
  15781. * @version : 1.0
  15782. * @Date : 2021-08-20 16:44:21
  15783. * @LastAuthor : LQ
  15784. * @lastTime : 2021-08-20 17:13:15
  15785. * @FilePath : /u-view2.0/uview-ui/libs/config/props/indexAnchor.js
  15786. */
  15787. var _default = {
  15788. // indexAnchor 组件
  15789. indexAnchor: {
  15790. text: '',
  15791. color: '#606266',
  15792. size: 14,
  15793. bgColor: '#dedede',
  15794. height: 32
  15795. }
  15796. };
  15797. exports.default = _default;
  15798. /***/ }),
  15799. /* 100 */
  15800. /*!******************************************************************************************!*\
  15801. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/indexList.js ***!
  15802. \******************************************************************************************/
  15803. /*! no static exports found */
  15804. /***/ (function(module, exports, __webpack_require__) {
  15805. "use strict";
  15806. Object.defineProperty(exports, "__esModule", {
  15807. value: true
  15808. });
  15809. exports.default = void 0;
  15810. /*
  15811. * @Author : LQ
  15812. * @Description :
  15813. * @version : 1.0
  15814. * @Date : 2021-08-20 16:44:21
  15815. * @LastAuthor : LQ
  15816. * @lastTime : 2021-08-20 17:13:35
  15817. * @FilePath : /u-view2.0/uview-ui/libs/config/props/indexList.js
  15818. */
  15819. var _default = {
  15820. // indexList 组件
  15821. indexList: {
  15822. inactiveColor: '#606266',
  15823. activeColor: '#5677fc',
  15824. indexList: function indexList() {
  15825. return [];
  15826. },
  15827. sticky: true,
  15828. customNavHeight: 0
  15829. }
  15830. };
  15831. exports.default = _default;
  15832. /***/ }),
  15833. /* 101 */
  15834. /*!**************************************************************************************!*\
  15835. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/input.js ***!
  15836. \**************************************************************************************/
  15837. /*! no static exports found */
  15838. /***/ (function(module, exports, __webpack_require__) {
  15839. "use strict";
  15840. Object.defineProperty(exports, "__esModule", {
  15841. value: true
  15842. });
  15843. exports.default = void 0;
  15844. /*
  15845. * @Author : LQ
  15846. * @Description :
  15847. * @version : 1.0
  15848. * @Date : 2021-08-20 16:44:21
  15849. * @LastAuthor : LQ
  15850. * @lastTime : 2021-08-20 17:13:55
  15851. * @FilePath : /u-view2.0/uview-ui/libs/config/props/input.js
  15852. */
  15853. var _default = {
  15854. // index 组件
  15855. input: {
  15856. value: '',
  15857. type: 'text',
  15858. fixed: false,
  15859. disabled: false,
  15860. disabledColor: '#f5f7fa',
  15861. clearable: false,
  15862. password: false,
  15863. maxlength: -1,
  15864. placeholder: null,
  15865. placeholderClass: 'input-placeholder',
  15866. placeholderStyle: 'color: #c0c4cc',
  15867. showWordLimit: false,
  15868. confirmType: 'done',
  15869. confirmHold: false,
  15870. holdKeyboard: false,
  15871. focus: false,
  15872. autoBlur: false,
  15873. disableDefaultPadding: false,
  15874. cursor: -1,
  15875. cursorSpacing: 30,
  15876. selectionStart: -1,
  15877. selectionEnd: -1,
  15878. adjustPosition: true,
  15879. inputAlign: 'left',
  15880. fontSize: '15px',
  15881. color: '#303133',
  15882. prefixIcon: '',
  15883. prefixIconStyle: '',
  15884. suffixIcon: '',
  15885. suffixIconStyle: '',
  15886. border: 'surround',
  15887. readonly: false,
  15888. shape: 'square',
  15889. formatter: null
  15890. }
  15891. };
  15892. exports.default = _default;
  15893. /***/ }),
  15894. /* 102 */
  15895. /*!*****************************************************************************************!*\
  15896. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/keyboard.js ***!
  15897. \*****************************************************************************************/
  15898. /*! no static exports found */
  15899. /***/ (function(module, exports, __webpack_require__) {
  15900. "use strict";
  15901. Object.defineProperty(exports, "__esModule", {
  15902. value: true
  15903. });
  15904. exports.default = void 0;
  15905. /*
  15906. * @Author : LQ
  15907. * @Description :
  15908. * @version : 1.0
  15909. * @Date : 2021-08-20 16:44:21
  15910. * @LastAuthor : LQ
  15911. * @lastTime : 2021-08-20 17:07:49
  15912. * @FilePath : /u-view2.0/uview-ui/libs/config/props/keyboard.js
  15913. */
  15914. var _default = {
  15915. // 键盘组件
  15916. keyboard: {
  15917. mode: 'number',
  15918. dotDisabled: false,
  15919. tooltip: true,
  15920. showTips: true,
  15921. tips: '',
  15922. showCancel: true,
  15923. showConfirm: true,
  15924. random: false,
  15925. safeAreaInsetBottom: true,
  15926. closeOnClickOverlay: true,
  15927. show: false,
  15928. overlay: true,
  15929. zIndex: 10075,
  15930. cancelText: '取消',
  15931. confirmText: '确定',
  15932. autoChange: false
  15933. }
  15934. };
  15935. exports.default = _default;
  15936. /***/ }),
  15937. /* 103 */
  15938. /*!*************************************************************************************!*\
  15939. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/line.js ***!
  15940. \*************************************************************************************/
  15941. /*! no static exports found */
  15942. /***/ (function(module, exports, __webpack_require__) {
  15943. "use strict";
  15944. Object.defineProperty(exports, "__esModule", {
  15945. value: true
  15946. });
  15947. exports.default = void 0;
  15948. /*
  15949. * @Author : LQ
  15950. * @Description :
  15951. * @version : 1.0
  15952. * @Date : 2021-08-20 16:44:21
  15953. * @LastAuthor : LQ
  15954. * @lastTime : 2021-08-20 17:04:49
  15955. * @FilePath : /u-view2.0/uview-ui/libs/config/props/line.js
  15956. */
  15957. var _default = {
  15958. // line组件
  15959. line: {
  15960. color: '#d6d7d9',
  15961. length: '100%',
  15962. direction: 'row',
  15963. hairline: true,
  15964. margin: 0,
  15965. dashed: false
  15966. }
  15967. };
  15968. exports.default = _default;
  15969. /***/ }),
  15970. /* 104 */
  15971. /*!*********************************************************************************************!*\
  15972. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/lineProgress.js ***!
  15973. \*********************************************************************************************/
  15974. /*! no static exports found */
  15975. /***/ (function(module, exports, __webpack_require__) {
  15976. "use strict";
  15977. Object.defineProperty(exports, "__esModule", {
  15978. value: true
  15979. });
  15980. exports.default = void 0;
  15981. /*
  15982. * @Author : LQ
  15983. * @Description :
  15984. * @version : 1.0
  15985. * @Date : 2021-08-20 16:44:21
  15986. * @LastAuthor : LQ
  15987. * @lastTime : 2021-08-20 17:14:11
  15988. * @FilePath : /u-view2.0/uview-ui/libs/config/props/lineProgress.js
  15989. */
  15990. var _default = {
  15991. // lineProgress 组件
  15992. lineProgress: {
  15993. activeColor: '#19be6b',
  15994. inactiveColor: '#ececec',
  15995. percentage: 0,
  15996. showText: true,
  15997. height: 12
  15998. }
  15999. };
  16000. exports.default = _default;
  16001. /***/ }),
  16002. /* 105 */
  16003. /*!*************************************************************************************!*\
  16004. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/link.js ***!
  16005. \*************************************************************************************/
  16006. /*! no static exports found */
  16007. /***/ (function(module, exports, __webpack_require__) {
  16008. "use strict";
  16009. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  16010. Object.defineProperty(exports, "__esModule", {
  16011. value: true
  16012. });
  16013. exports.default = void 0;
  16014. var _config = _interopRequireDefault(__webpack_require__(/*! ../config */ 64));
  16015. /*
  16016. * @Author : LQ
  16017. * @Description :
  16018. * @version : 1.0
  16019. * @Date : 2021-08-20 16:44:21
  16020. * @LastAuthor : LQ
  16021. * @lastTime : 2021-08-20 17:45:36
  16022. * @FilePath : /u-view2.0/uview-ui/libs/config/props/link.js
  16023. */
  16024. var color = _config.default.color;
  16025. var _default = {
  16026. // link超链接组件props参数
  16027. link: {
  16028. color: color['u-primary'],
  16029. fontSize: 15,
  16030. underLine: false,
  16031. href: '',
  16032. mpTips: '链接已复制,请在浏览器打开',
  16033. lineColor: '',
  16034. text: ''
  16035. }
  16036. };
  16037. exports.default = _default;
  16038. /***/ }),
  16039. /* 106 */
  16040. /*!*************************************************************************************!*\
  16041. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/list.js ***!
  16042. \*************************************************************************************/
  16043. /*! no static exports found */
  16044. /***/ (function(module, exports, __webpack_require__) {
  16045. "use strict";
  16046. Object.defineProperty(exports, "__esModule", {
  16047. value: true
  16048. });
  16049. exports.default = void 0;
  16050. /*
  16051. * @Author : LQ
  16052. * @Description :
  16053. * @version : 1.0
  16054. * @Date : 2021-08-20 16:44:21
  16055. * @LastAuthor : LQ
  16056. * @lastTime : 2021-08-20 17:14:53
  16057. * @FilePath : /u-view2.0/uview-ui/libs/config/props/list.js
  16058. */
  16059. var _default = {
  16060. // list 组件
  16061. list: {
  16062. showScrollbar: false,
  16063. lowerThreshold: 50,
  16064. upperThreshold: 0,
  16065. scrollTop: 0,
  16066. offsetAccuracy: 10,
  16067. enableFlex: false,
  16068. pagingEnabled: false,
  16069. scrollable: true,
  16070. scrollIntoView: '',
  16071. scrollWithAnimation: false,
  16072. enableBackToTop: false,
  16073. height: 0,
  16074. width: 0,
  16075. preLoadScreen: 1
  16076. }
  16077. };
  16078. exports.default = _default;
  16079. /***/ }),
  16080. /* 107 */
  16081. /*!*****************************************************************************************!*\
  16082. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/listItem.js ***!
  16083. \*****************************************************************************************/
  16084. /*! no static exports found */
  16085. /***/ (function(module, exports, __webpack_require__) {
  16086. "use strict";
  16087. Object.defineProperty(exports, "__esModule", {
  16088. value: true
  16089. });
  16090. exports.default = void 0;
  16091. /*
  16092. * @Author : LQ
  16093. * @Description :
  16094. * @version : 1.0
  16095. * @Date : 2021-08-20 16:44:21
  16096. * @LastAuthor : LQ
  16097. * @lastTime : 2021-08-20 17:15:40
  16098. * @FilePath : /u-view2.0/uview-ui/libs/config/props/listItem.js
  16099. */
  16100. var _default = {
  16101. // listItem 组件
  16102. listItem: {
  16103. anchor: ''
  16104. }
  16105. };
  16106. exports.default = _default;
  16107. /***/ }),
  16108. /* 108 */
  16109. /*!********************************************************************************************!*\
  16110. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/loadingIcon.js ***!
  16111. \********************************************************************************************/
  16112. /*! no static exports found */
  16113. /***/ (function(module, exports, __webpack_require__) {
  16114. "use strict";
  16115. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  16116. Object.defineProperty(exports, "__esModule", {
  16117. value: true
  16118. });
  16119. exports.default = void 0;
  16120. var _config = _interopRequireDefault(__webpack_require__(/*! ../config */ 64));
  16121. /*
  16122. * @Author : LQ
  16123. * @Description :
  16124. * @version : 1.0
  16125. * @Date : 2021-08-20 16:44:21
  16126. * @LastAuthor : LQ
  16127. * @lastTime : 2021-08-20 17:45:47
  16128. * @FilePath : /u-view2.0/uview-ui/libs/config/props/loadingIcon.js
  16129. */
  16130. var color = _config.default.color;
  16131. var _default = {
  16132. // loading-icon加载中图标组件
  16133. loadingIcon: {
  16134. show: true,
  16135. color: color['u-tips-color'],
  16136. textColor: color['u-tips-color'],
  16137. vertical: false,
  16138. mode: 'spinner',
  16139. size: 24,
  16140. textSize: 15,
  16141. text: '',
  16142. timingFunction: 'ease-in-out',
  16143. duration: 1200,
  16144. inactiveColor: ''
  16145. }
  16146. };
  16147. exports.default = _default;
  16148. /***/ }),
  16149. /* 109 */
  16150. /*!********************************************************************************************!*\
  16151. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/loadingPage.js ***!
  16152. \********************************************************************************************/
  16153. /*! no static exports found */
  16154. /***/ (function(module, exports, __webpack_require__) {
  16155. "use strict";
  16156. Object.defineProperty(exports, "__esModule", {
  16157. value: true
  16158. });
  16159. exports.default = void 0;
  16160. /*
  16161. * @Author : LQ
  16162. * @Description :
  16163. * @version : 1.0
  16164. * @Date : 2021-08-20 16:44:21
  16165. * @LastAuthor : LQ
  16166. * @lastTime : 2021-08-20 17:00:23
  16167. * @FilePath : /u-view2.0/uview-ui/libs/config/props/loadingPage.js
  16168. */
  16169. var _default = {
  16170. // loading-page组件
  16171. loadingPage: {
  16172. loadingText: '正在加载',
  16173. image: '',
  16174. loadingMode: 'circle',
  16175. loading: false,
  16176. bgColor: '#ffffff',
  16177. color: '#C8C8C8',
  16178. fontSize: 19,
  16179. iconSize: 28,
  16180. loadingColor: '#C8C8C8'
  16181. }
  16182. };
  16183. exports.default = _default;
  16184. /***/ }),
  16185. /* 110 */
  16186. /*!*****************************************************************************************!*\
  16187. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/loadmore.js ***!
  16188. \*****************************************************************************************/
  16189. /*! no static exports found */
  16190. /***/ (function(module, exports, __webpack_require__) {
  16191. "use strict";
  16192. Object.defineProperty(exports, "__esModule", {
  16193. value: true
  16194. });
  16195. exports.default = void 0;
  16196. /*
  16197. * @Author : LQ
  16198. * @Description :
  16199. * @version : 1.0
  16200. * @Date : 2021-08-20 16:44:21
  16201. * @LastAuthor : LQ
  16202. * @lastTime : 2021-08-20 17:15:26
  16203. * @FilePath : /u-view2.0/uview-ui/libs/config/props/loadmore.js
  16204. */
  16205. var _default = {
  16206. // loadmore 组件
  16207. loadmore: {
  16208. status: 'loadmore',
  16209. bgColor: 'transparent',
  16210. icon: true,
  16211. fontSize: 14,
  16212. iconSize: 17,
  16213. color: '#606266',
  16214. loadingIcon: 'spinner',
  16215. loadmoreText: '加载更多',
  16216. loadingText: '正在加载...',
  16217. nomoreText: '没有更多了',
  16218. isDot: false,
  16219. iconColor: '#b7b7b7',
  16220. marginTop: 10,
  16221. marginBottom: 10,
  16222. height: 'auto',
  16223. line: false,
  16224. lineColor: '#E6E8EB',
  16225. dashed: false
  16226. }
  16227. };
  16228. exports.default = _default;
  16229. /***/ }),
  16230. /* 111 */
  16231. /*!**************************************************************************************!*\
  16232. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/modal.js ***!
  16233. \**************************************************************************************/
  16234. /*! no static exports found */
  16235. /***/ (function(module, exports, __webpack_require__) {
  16236. "use strict";
  16237. Object.defineProperty(exports, "__esModule", {
  16238. value: true
  16239. });
  16240. exports.default = void 0;
  16241. /*
  16242. * @Author : LQ
  16243. * @Description :
  16244. * @version : 1.0
  16245. * @Date : 2021-08-20 16:44:21
  16246. * @LastAuthor : LQ
  16247. * @lastTime : 2021-08-20 17:15:59
  16248. * @FilePath : /u-view2.0/uview-ui/libs/config/props/modal.js
  16249. */
  16250. var _default = {
  16251. // modal 组件
  16252. modal: {
  16253. show: false,
  16254. title: '',
  16255. content: '',
  16256. confirmText: '确认',
  16257. cancelText: '取消',
  16258. showConfirmButton: true,
  16259. showCancelButton: false,
  16260. confirmColor: '#2979ff',
  16261. cancelColor: '#606266',
  16262. buttonReverse: false,
  16263. zoom: true,
  16264. asyncClose: false,
  16265. closeOnClickOverlay: false,
  16266. negativeTop: 0,
  16267. width: '650rpx',
  16268. confirmButtonShape: '',
  16269. duration: 400
  16270. }
  16271. };
  16272. exports.default = _default;
  16273. /***/ }),
  16274. /* 112 */
  16275. /*!***************************************************************************************!*\
  16276. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/navbar.js ***!
  16277. \***************************************************************************************/
  16278. /*! no static exports found */
  16279. /***/ (function(module, exports, __webpack_require__) {
  16280. "use strict";
  16281. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  16282. Object.defineProperty(exports, "__esModule", {
  16283. value: true
  16284. });
  16285. exports.default = void 0;
  16286. var _color = _interopRequireDefault(__webpack_require__(/*! ../color */ 113));
  16287. /*
  16288. * @Author : LQ
  16289. * @Description :
  16290. * @version : 1.0
  16291. * @Date : 2021-08-20 16:44:21
  16292. * @LastAuthor : LQ
  16293. * @lastTime : 2021-08-20 17:16:18
  16294. * @FilePath : /u-view2.0/uview-ui/libs/config/props/navbar.js
  16295. */
  16296. var _default = {
  16297. // navbar 组件
  16298. navbar: {
  16299. safeAreaInsetTop: true,
  16300. placeholder: false,
  16301. fixed: true,
  16302. border: false,
  16303. leftIcon: 'arrow-left',
  16304. leftText: '',
  16305. rightText: '',
  16306. rightIcon: '',
  16307. title: '',
  16308. bgColor: '#ffffff',
  16309. titleWidth: '400rpx',
  16310. height: '44px',
  16311. leftIconSize: 20,
  16312. leftIconColor: _color.default.mainColor,
  16313. autoBack: false,
  16314. titleStyle: ''
  16315. }
  16316. };
  16317. exports.default = _default;
  16318. /***/ }),
  16319. /* 113 */
  16320. /*!********************************************************************************!*\
  16321. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/color.js ***!
  16322. \********************************************************************************/
  16323. /*! no static exports found */
  16324. /***/ (function(module, exports, __webpack_require__) {
  16325. "use strict";
  16326. Object.defineProperty(exports, "__esModule", {
  16327. value: true
  16328. });
  16329. exports.default = void 0;
  16330. // 为了让用户能够自定义主题,会逐步弃用此文件,各颜色通过css提供
  16331. // 为了给某些特殊场景使用和向后兼容,无需删除此文件(2020-06-20)
  16332. var color = {
  16333. primary: '#3c9cff',
  16334. info: '#909399',
  16335. default: '#909399',
  16336. warning: '#f9ae3d',
  16337. error: '#f56c6c',
  16338. success: '#5ac725',
  16339. mainColor: '#303133',
  16340. contentColor: '#606266',
  16341. tipsColor: '#909399',
  16342. lightColor: '#c0c4cc',
  16343. borderColor: '#e4e7ed'
  16344. };
  16345. var _default = color;
  16346. exports.default = _default;
  16347. /***/ }),
  16348. /* 114 */
  16349. /*!******************************************************************************************!*\
  16350. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/noNetwork.js ***!
  16351. \******************************************************************************************/
  16352. /*! no static exports found */
  16353. /***/ (function(module, exports, __webpack_require__) {
  16354. "use strict";
  16355. Object.defineProperty(exports, "__esModule", {
  16356. value: true
  16357. });
  16358. exports.default = void 0;
  16359. /*
  16360. * @Author : LQ
  16361. * @Description :
  16362. * @version : 1.0
  16363. * @Date : 2021-08-20 16:44:21
  16364. * @LastAuthor : LQ
  16365. * @lastTime : 2021-08-20 17:16:39
  16366. * @FilePath : /u-view2.0/uview-ui/libs/config/props/noNetwork.js
  16367. */
  16368. var _default = {
  16369. // noNetwork
  16370. noNetwork: {
  16371. tips: '哎呀,网络信号丢失',
  16372. zIndex: '',
  16373. image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAASwAAAEsCAYAAAB5fY51AAAAAXNSR0IArs4c6QAAAERlWElmTU0AKgAAAAgAAYdpAAQAAAABAAAAGgAAAAAAA6ABAAMAAAABAAEAAKACAAQAAAABAAABLKADAAQAAAABAAABLAAAAADYYILnAABAAElEQVR4Ae29CZhkV3kefNeq6m2W7tn3nl0aCbHIAgmQPGB+sLCNzSID9g9PYrAf57d/+4+DiW0cy8QBJ06c2In/PLFDHJ78+MGCGNsYgyxwIwktwEijAc1ohtmnZ+2Z7p5eq6vu9r/vuXWrq25VdVV1V3dXVX9Hmj73nv285963vvOd75yraeIEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQaD8E9PbrkvRopSMwMBBYRs+5O/yJS68cPnzYXel4tFP/jXbqjPRFEAiCQNe6Bw/6gdFn9Oy9Q90LLG2DgBBW2wyldIQIPPPCte2a5q3jtR+4ff/4wuBuXotrDwSEsNpjHKUXQODppy+udYJMEUEZgbd94DvnNwlA7YGAEFZ7jOOK78Xp06eTTkq7sxwQhmXuf/754VXl4iSstRAQwmqt8ZLWlkHg0UcD49qYfUjXfLtMtOZ7npExJu4iqZWLl7DWQUAIq3XGSlpaAYHD77q8xwuCOSUoXw8Sl0eMux977DGzQjES3AIICGG1wCBJEysj8PXnz230XXdr5RQFMYbRvWnv6w8UhMhliyGwYghr4Pjg3oEXL34ey9zyC9tiD2ml5h47dr1LN7S6CMjz/A3PvHh1Z6UyJby5EVgRhKUe7Kz/JU0LfvrJo5f+Y3MPibSuFgQGBgasYSd9l6GDsup0WS/T/9RTp9fXmU2SNwECdQ92E7S57iaMeJnPQLK6ixkDLfjlb7546RfrLkQyNBcC3dsP6oHWMd9G+V3JgwPHh7rnm1/yLQ8CbU9Y33zp0j+nZFUMb/DHmB7+SHGY3LUKAk8cObtD00xlHDrfNge+Z2ozU3c9dvx4Yr5lSL6lR6CtCWvg6OAPw9z538ZhhZRl6XrwhW8du1KX/iNejtwvPQIDR8+vSRqJ/obU7GupjdNdh2gW0ZDypJBFR6BtB2rg2OVtuub9JcmpHIpBoK1xfffLzx4f7C0XL2HNiYDp6bs9z23Ypn1fC1Y/9PCFDc3ZW2lVHIG2JKzTp4Ok7nv/G6Q054MIvda+bNb74pEgKGtwGAdL7pcfAa8vOKEZ2kyjWuLr7uDh+/qvN6o8KWdxEWhLwroyeek/g4zuqwU6kNrhyZcu/UktaSXN8iNwuL9/RuvVXtJ9PbPQ1vhmcP6t9+47u9ByJP/SIdB2hDVw9MJHQFYfrQdCph84evFX68kjaZcPAZJWwjMXRFpJ2zr91tfuvrh8vZCa54NA2xGWrunvmg8QWCJ/N4ir7fCYDxatkOeBB7an501agXbygVdvv9IK/ZQ2FiPQdi9osGbH+zRNf7y4m9Xu9Me7N9nv0HXdr5ZS4psHgXpJC9P/wDRTx0Vn1TxjWG9LGrbaUm/Fi5meSvcrkxf/Cg/ow9XqAUk91v3qHT97r6471dJKfHMi8Oyzgx1Z03t1YAQVT2MwgsC3u+yXHzi0faQ5eyGtqgWBtpOw2Ol9+/TM+sTOn8L08MtzgQCy+tOHXr3jA0JWc6HU/HF5Scssr4jXcYqfP6V/T8iq+ceyWgvbUsKKOn38eJAYyl56TAuCEr2WYei//9Crd/5GlFb81kdASVopSFrerKRlaoZj9HR+700H10+0fg+lB21NWBxe2lhNHsUpDZr27mi4dV379R9+za4/iO7Fbx8ECknLCPTsTDJ17O33bJpqnx6u7J60PWFxeAcCbMV56dJfQKf1bkMLfuGh1+76zMoe9vbuPUnLsb2DtmOe5HSxvXsrvWtLBEhaTx29+Ma27Jx0ShAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQaEsEVoQdVluO3BJ06ptHL34b1XRjp4Ch6Rq24+kmjG4Nwwg+9uA9u/73EjRBqhAEihAoe3xwUQq5WTYEzp0b3ZnV/Ncf6O/9AvY9wlh/6dy3X7ncN512Zw9BVLXjuAP4np44vnQtkZoEgVkEhLBmsWiKqwsXpjbPBOn3gRfenwnc+7GBe+zsjclvonFDS9nA9Iy/u3x9+vAP3735VPk4CRUEFhcBIazFxbfm0k9fHD7k+v4nQFaPQIrx8Gmyx/GJ0J/t7ez7mw0b9MmaC2pQQgh0/ZSm4g5TwueWWtqLt0HuVy4CQljLPPYnB0depTn+b3t+8B4t0AdBUv93h2H9xc6da0aXs2m+r1WQsLRnl7NdUvfKRkAIa5nG//r1oGtsZvjTgev/kqYHF/TA+AXoqv4npJemOEiQU1Eo2l+G0movBK1UBBPU7s9E1+ILAkuNgKwSLjXiqO/khVtvARH8dxDBRkMzPrF/V+9/BlG5y9CUqlXinHv9mRPXtvuus88L9H3JPv2zD2yXExCqAicJBIFWRwAvv3Xqwq0/Pnn+lv/K+ZvfPH3p9p5W75O0fxaBp793ce3AwIDMWmYhafiVgNtwSMsXeHp4eNXJC8Nf0PAdRCiuf/XgrnWUqsqotcvnl9DmRkCdweX4b9N7+m/ih+mbMraLM14yJVwcXItKpT1VRve+ArC3Qqn+3gM7132jKEGZm6tXg86J7OhDfuA/iHwPUpfUZSfu2L59tXxEoQxeyxkEgjKeOnLxHb4RqC+NY5H3+2953d4XlrNN7Vq3ENYij+yZwbG9jpt9GkBPQ5H9zgP9607OVeWp87cOQtn9zwJf+xDMNFfj+jryPqXpxj8c2Nn7P+SXey70lidu4IXzb0DNB4tr9751+HV7zxSHyd1CERDCWiiCc+QPjUCnsaqmZ62O5IN7N/VUNP48ee7mAZDTf4Tt049iUG4Guv4ZfNLos9UIbo7qJWoJEHjy+bP7fNsoOcnW0A0/aacef8PdG28sQTNWTBVCWIs01OfPj66BpfqTmq732UnjgT1bei+Vq4pTv7HM8Ceg2/o1qLQug7T+FaaM3IqTLZdewpoHgYEjV9fphvOj+OShWa5V+CxvZtpzv/LwG/aNl4uXsPoRwI+4uEYjAJ2GmdG8L0FK2mYa+tsrkdXZy+P7x2ZuHdW14P+BLdank9q6Qwd3rf+ckFWjR6Tx5Q2cP58K9Jm3VCIr1ogt48lO237r3//96YofeG18y9q7RFklXITxPXV+5DchKb3ZDMy37Nu5tuxG4R9cHH6b42QfAzlds+3EPXu2rfrBIjRFilwkBIIR7SHoJDurFU89ZOd680Gke6JaWomvjoBIWNUxqivFD87fej0e0n8Fwvr0/t1rnyqX+QfnRz7g+8FX8Rv8vL3auF/IqhxKzR2WCPxXqKeq3krDTdj2ierpJEUtCIgOqxaUakwzNBR0D09yiqePHOjveyOkpxLr9VMXb73V97S/h3nDXx7Y2fdPkAYbncW1IgIDxy5vM7LZt/hgrnLtxyaBrJNxv/72N+6tuNhSLp+EVUZACKsyNnXHvHL+1qcgNf2KbSXu2bt9dcmS9qlzo/fARgcmCtpzB3b1/Vg5QiuslLowENyDWDn8cSjl98PgdBviu03N+rl9/WufLEwr18uDwLdevLTF1YK3xnVZ2HI1bUxrT7z5zTuXdRP78qCyeLUKYTUI25OXbm4JPO00TBj+6I7+db8ZL3ZwMOiYdG4dA1lN9HWte2iuI2NAVPapC8O/CGPR34Ip/AZIbIMo7yX8G9QMbcS09P+2b1vf5XgdrXaPfiYns9oeLLEd8D1/B7Dp0E1jGP042pXQj7RKf546cmGzp+tv1TRf6YQD35/QO3seP3xow5IfC9QqmM23naJ0ny9ysXwgq98BWc0kVhv/Nhalbqe8kd/Fr8MOSEr3zEVWrwyO3I29hl+E9LUHGf+nAXI6sGPdd8uV2YphIKnE5IyL6bLxk7cn3bdkHHefrpvJAExMZ1uBZmqeNzXtfzUzk/m/ens7LjV7Px+8d9e1579/44l0duZtge+Np5zEEw8c2pBu9na3YvtEwmrAqNE8IZvNHsep5//yjl3r/0O8yFOXbv0QCO05gP0JGIL+fjw+uj91YeRh/Dp/PtCDM7Zpfmjvjt6Xo7hW9ycmJjaYduf7Hdf/8HTGfa3rG9rYxLSWnsloPg7fijZV8oFM2Ja2a9t6EJd7bCztvHP7us4rrdD/r3/7ct9I99jEI4cOiQ3dIg2YEFYDgOUJDFj1e8TqX7cT4kImXuQr5279A4DeBEX8ayvprU4N3rovcALot/TH13T0fXDTJn0qXk4r3k9OTm4y7a6PzjjORzOOvn1kbEqbnEprPhRzwAKzwFLHk05hv6Yd6N+o3R6beG50aPSdr3qV6IJKkVp5ITIlXOCYn4Yexr0w/DO6YXymHFlR0e5r7tsM3fxgJbI6fW1ivTeT+SsYmr54cFff+5Cu5X+hb94Merp6/J/PusGvTE6724eGJ7RpSFOkKPCUZvBPBccoHBet3Rwe13rX9tw/PjXzZ5hKvr8SfhWKkeA2REAIa4GD6p0feRdWBnvxjv2PckVhVfBf4A29uG/X2i+Ui2eYn8n8NryuDr3jPfWSFV5k44UT137eshIP2K7/64cObbheqZ6lCp+Ydt8TBO7vTM5od1+/NR4SFVhoLpKKt410lnE8LTMzo3V2dLznxLkhYgQ9obiVjEDln7mVjEodfYcpw+MAsftg/7qSDbAnb97sCSb0Yei2fqOcbovVqKNnNO8HmAE9Cv3Wp+uoWjt27HpXNqH9WTKR+kBHKqEFbvo5y3N/avfu4g23R45f3WGa1k9ZicTd0zPTf/f6O7f8dT311Jp2fHzmgJlI/N70jPPe4bEZ6Kg4qw0lqlrLiNKBiLWerpTW25PUbkPXZViW62ecHz+4d8PXojTirzwEyhq8rTwYFtRjvpX/rlwJ+iSXugPbMuyKBOHo3geRJtuT7PujcmVUCuPJlhnL/9NUqvMD2eyM5sxMaIlE4n7XML907tyNjcxHQjty4sZv66Z1xEok/xNW5n4uZSf+8sT5m++vVO58wkEu5sR09pd9w/rWyET2vReujiqygrSopn/zKZN5qMeirotKeTyolm7p/+X06Wvr51ue5Gt9BISwFjiGsLl6N6SrvylXDNTK70D4mX071pwtF88w6Jd/DG/1E1u26NOV0pQL71y3/8PJVOcHMzPTWkcCH2YGOaTTaS2RTN6f1fQvvvDK1bdnbO2JZCr1SeRfn05Pa1PTU0gXJBKW+ecnzlxvCGndhFQ1NRP8bcY1/vjS9bF1V26MwHwsVKiXa3etYVw1TNhYJ3TDjQCO42jJVMcez7J+t9YyJF37ISCEtahjGjxkGDr2DJZ31D8h5vUQJL5RPkXlUMM07u3qSGidICvkzzuSlmlZb0olrK9hD9v9JCrPC196JoPMAolFg6CV+PPj54YeyWecx8Vk2v1Q0rSfhFT18LnBmzBRyNalp5qrSuq7kiAsh4SFa7oZ9M0wzI+cPHOjZPo9V1kS1z4ICGEt4lhiCvZrSa2jol7qzPXJPk6nIGbVbWfUvcr7hO9MP97ZVXpggOu6ajplYStj7l1XvbRMXbPAbp6HzSSBlkraNknrvfVCcPt2sHYi7f3pTDb47KUbYxuvKqkKpYBXKBnV869c3WgbDEixAck0FGFFfEzJzbIsO9C1TyrcymWWsLZGIHoW2rqTzdo5dXyykz0NC8l779i5vu4zwM+eHVntGP5jqVTq/6AkVc5NZ3wNH2lVxNWZNIukMSjiNd9z0+CHp5DXAdX4SAg203w8GB5IATtODHzdK8C15kEjhXvNS9rWA11dnfcMDY9prscss48RySakrOLWqODCoIKAgkuVgsS0urtD60haeV1YYVbbtjUn6/74HXvW/11huFy3PwKzT1r797Upe3jq4sib9u9Y+wxe+vh7W1N7jx49v6ZzbffnQD4/Cj1Pfjx54XiBls6GVuTUc9mQsOIO9mPQFdkIRlz4fy5JLm2ZMOqTcJaXIqpcqnixVe+rdbZ3dbc2OT0D0wZIibHSksmklslknvx+//q3PiKnXcTQae/b+LPQ3r1t0969cOL6G7o6E09qgZegdMJBpVQ1DbKCpyUt6oPKz/4NEJalCAuZFIuEVBJd+jgLh4rvAiFqUVGkhJZMWFp3Z0obGSu/d5gSnWmavuO6h+/cvYHSobgVgoAYjrb4QPMUiGtj1/79jBMkLBwiTlMASlYzTkhWCJyTrGAyMOFkst/BoYMmuIIyGJYcMXMMdNwHPhYN1qWS1t6ZLGaKZL8yzFXTr15BooLLMugHMBRNKgW+It8y9TEcJGt4rvcRFCCEVQbFdg0Swmrxkb0+cf2XOzq73kgdFieEXF2jdEUJKQH6SVWQrNjtZDKlpTPp38U58iUbthk/Ph7sN6zg/xudSGvD4xkq6otcnnjyF0XRRTflkyC0IIJE1JG0QbqGNpMNp5xFhRTcZDNoj66988SFm5vv3LX+WkGUXLYxAuXnCW3c4XbqGs9hwjv+a9lsuN+ahOJSCoLjNDAFvVUll0p1aNPp6adTweSflEszPO48oFn+4yOTmR+6enOshKyYhzWpf/jDuuf6x2aV/qNRaPG/1d0gUXWCA0uu7GhMmkqmerEc8KOVU0lMuyFQ+Ylut562YX9Sncmf7Ojo3BDZWbGLtMkiUVXSWTFNuMqWuYG530f7+/tnGFboxsfdd9mm8XdDo9O7rg6NFq0CFqZr5DWlK9qV0fZqGvZchSuPlevB2VmG/hOV4yWm3RAQwmrhEcW64qu4ykfJho52Vp3J8quBYQooqWDKADftBd6HD+5efyoKj/zR8ew/hWXY56/cnFh7a3RCTTGjuMX0SVB9qzu1qfQM+jO3dBW1g6uVSHv/qVNX10Vh4rc3AkJYLTy+WA/8ou9kJjo7bOh+DLVFZ64TEbCyBktxI5PJZj56R//Gx+NdH5vM4vuI+p8NXh9LjU1iw3EZhXc8TyPuuV9wDaaCfBjTM06N0hVWQmHBDzvSDZ5tvqYR7ZAymh8BIazmH6OKLbzv0KZvJEz3ZzEFnEolaEtV2XEaCLKadrIz//TQnk1/EU85NuH8th8Yf4j9gMZUOrNkZEVZCnsbtTU9KW18GqcKFyjh420sd2+j33pg3F8uTsLaDwEhrBYf04O7N/2t7/o/C2FoGnsIy/YGlvAwSfCvZzLOe+8oR1ZT3u/5uvHJC9dGtJlMrfqjslXVHwjpat2aLi2rjFFLjUSrFUjlO0juddXSSXx7ICCE1QbjiHO0/hofbPgwpnDTOR2V6hWNQqGUx34890noet5yaO+Gko3Y45PO7/uB/lvnrwxrWdha1absbgxo1FWtwplXqYSJY5Nn5lU3bLHQmGA/yko0plVSSjMjIITVzKNTR9sO7dv8RSeb/T9BWmMkKv4D+YzBXuljV7yxd+zfte6VeHGKrHTz4+cv38JWmyUmKzSGG5z7VndoE7kz3uPtq+Welvhwm39weVjOyaoFsBZPI4TV4gNY2Pw79mz8KyebeRIH+VEZTaX0sf27+v794TKmCxNTzr/2NOPj5wZBVjjdYSklq6jN69dyKuhqmWztivYob+RTSkPbe/xMdlMUJn77IiCE1W5jq+s4dYEO6mzsYAmvi/+CrH7LDYxPcBq4HGTFVcG1ULLT5orS1ULIkoSFI2cMHKG8obiXcteOCAhhtdmo6gaOh4EWWlkyYU9gvHswXfgV19d/7+LVkSWfBrItJJhObL/p7elQR8fUZnEV70XxPc01sM+xrzhU7toRgZIHuh07uZL6xA3LBaYB+Ar8rBsfz34YX1j+D5eu317QNGy2xPquSE4mDuXb2IujY2AgytNE67RiKFshzuwCR5s9ZSMlsK0QEMJqq+GkBKOF5yFzRoidK5BoFCeMjM/8mG+a//Xy0Li55KYLBRiTrGjwOQ1br4VMBQuKVJeQKVPxMLlvPwSEsNpsTEECmBLSgbHUpwD1YGwse59l2p+9fmuig4fiNZIowrqq/6Xeqm9Vh9JbjcOKvqFtACX7gV8kTVZvkaRoRQSEsFpx1OZoM2iKxxuHLtDcsZlgLzYZfv7m7XSv+r7fIm234XSP/8o5ktWqzqSyZr89PoXPYDTYkZvziw0NLluKayoEyq4iNVULpTF1IaDjHHZmoAW4aep9geN8fiLt998cGYdtVp7K6iqzXGJFUCAi7jdkuapsBJKcPBwgyP8YRyV7B04Q3dDbpY3jg6gupoMNla5U41BbUN9n0sr1ScKaHwEhrOYfo7paCAW0WiWknihhW/0Tabf/6tDtxpIVSIhGnz1dSXUkDL8fSHKi4/lWPId9Kp3Vxqegp8J/m9f14D6DQ/nmb281FwgkZ1Dj7bnSSFx7ICCE1R7jmO8FJJr8jCvjeNrIxFjDJBpKVaSlXhwDw384MyucBoLAGEfHI5ptO6n1YAq4FjorH9IWjUOnFlF3pj62aui3whbI33ZGQAir/UY3XCVEvzgdw/8NcSyGUhSlpVWQrFg2p39xp0JYLyIohaXxdZ2FGofG6yi85/QS32F0Asu8URgu1+2JgCjd22xcsVElPC85169Gaa1YTkRWJKpSqooBiQQzONvq9sRULKKxtzzAEJw1api2EFZjoW3K0oSwmnJY5tcoSD09HanEDztubnfO/IopyUWC6sUmZUpW5aSqkgwgK04DxxaZrFivacCaIdAuH9zaM1rSDgloOwSEsNpoSMenvU93dXb+EE5taFivKElRqd67qrNmsqIF+yjMF/i56MV2JqadYKxXMDXM6+4Wu04pf/kQEMJaPuwbWvPticwj4Il/NnTrdl7JrqaDC5wTUle1GmdWWVCw1+JotjA6PgnThsIdQrXknF8arkJi/+R355dbcrUaArU9ha3WqxXW3tHR9C5dN//T9eEJ3aGdUwP7T0V7F86Mr0VW4mF6o2NTS/ilaB2HDmb8wA2+08AuS1FNjIAQVhMPTi1NgwRkGKbxRxMz3uaJSRzVUkumOtLwo6Zc7aOkVdEhynN9NQ1cyuNqeEqD67mX9TXGyxXbJhFthYAQVosP58S0909czfqJqzdGODVqaG/IUbCWr2p0yukfp4FUtDfeir1yl8IPUGjPHFy/fqJyKolpJwSEsFp4NEfT6Z3YBvOp8MvMc0hAi9hHNQ1cBrJil5TUZxhfXsTuSdFNhoAQVpMNSD3NMTzzU1PZYAM/ProYkg3UV5rHT8lXmA7SwnwEq4FLLVkRI04HM+n0LdvzvlEPZpK2tREQwmrR8ZucCd7hePr7rw2N5PfxLUZXON1zHKz4kb0KnIttP6Njk8tyaimbwXPrsW/yq3v3bhoqaJZctjkCQlgtOMCYCnU4GedTI+NpQ32XbxH7QOmKG5nzdIWZJz8HNkKygqI9TmSL2JSiovGVn0A39c8WBcpN2yMghNWCQ4zPc0HRbr6GEs6chJFnmfl3knZO4/hmII1B6fiFG9br0s6qAeXPp2WUrhzHeXH/jr6n5pNf8rQuAkJYLTZ2kK7Wul7w6zeGx9DyUsZovOodOizosTg1TM9k1Wogpa7lIisOF+w48E/7E5B1Y/cgtdizsBKbK6c1tNioT6X9n3MDcyePOo7OoJqrC6S0+ZIYV+GSOHxvc18PJCxXG4ed13I727axqTp9yk9rX1jutkj9S4+ASFhLj/m8axwdDdbgELxfGsLpoZyqVXPVU1QugVJUV0dC27p+FaaBWWxknq6ceAljTNMiAf/BoUMbJpewWqmqSRAQCatJBqKWZpgJ731Zx9pJM4aK0hXe5vlKVFEbKFlxs3PvqpSSqpbzKztRm+gnEkktnU6/2GFMfa4wXK5XDgJCWC0y1iAR6/Z49iOjY7C5qkG6mk+3SFQGlEP8FFdnygrNFqBsn1OxP5+K5pGHbcBhqhT8fqu/v39mHkVIljZAQAirRQYx7Wj3Zj3tddQjVVJ4l50CMjHe8mqOTJCCvmoTyIrENXx7Uinbm4Gs2PZUqkObnp76i0N7N36tWl8kvn0RaGnCGhgILKPn3B3+xKVXDh8+nPseX3sOlpt13+P4uonv71WeDqLr1ampFB8S1JrulNaHc9rTMxltcpofOeWns0rTLkeIZUHRnpm5YibMf7kc9UudzYNAyyrd8ZLpWvfgQT8w+oyevXeo++bBtaEtQd9s1/ffRsV3I6eDJCp+nourgH04UZQnhIYfWm1o8xdUGCU8/E/bil89sH3dlQUVJplbHoGWJaxnXri2HTvd1nEEcCBS3z++MLi75UejQgcmJjL92ax/gNJPo6QekhVXAbdvXI3D+XQ1Bcxiu02zTAEjKFIdHTQS/S8Hd2/4YhQm/spFoCUJ6+mnL651gkwRQRmBt33gO+c3teNQYin/oG6aKX5rcKEukqqoWN+Ij5vy81v8UATDG0WGC21jlJ96K6wKPpWd8H8jChN/ZSPQcoR1+vTppJPS7iw3bIZl7n/++eFV5eJaOczX9Z2YvM1LPxWpocBHKv8qHHdMqSphGUqqahaThfj40ITBcbLnsDj6oXvu2bS4n96JVy73TYtASxHWo48GxrUx+5Cu+XY5RH3PMzLGxF0ktXLxrRoGNVPPfNtOolIrgElLGYH2wbZqcipdIFVFlDbfGhqfj9bskCaHHS/7gTt3r73Y+BqkxFZFoKUI6/C7Lu/Bl1jmlKB8PUhcHjHufuyxx/g5lbZw+BL7bX4EoiZqyS0T0uM0j1+82QSl+ua+bhxj7GjD2LicwWkLzaarigbKsmDJ7gcTmezMBw/t3ixntUfAiK8QaBmzhq8/f26j77pbaxo3w+jetPf1B5D2RE3pmzyR4/nH+Mti4Wx1dUrCHO0lSVGqskFUnakkpn6mhu086jgYHkWTW3Wbo4Tli6L5gqYHE47vfeDufVv+YflaIjU3KwItIWEdO3a9Szc0ElDNDqcLbHjmxas7a87QxAnX9ljfxcr+Mzs29ykpi1O8iJjoR/cm5o7dnUl89LRLW93dyWmVIip+Kp7pmlWqIvQ8Mga9Gslm3Efu3LX+K008HNK0ZUSgplnGMrZPGxgYsIKeXa/TA61jPu0w0+7xBx/cd3M+eZspD0wbDgWm+RXP13cODY/jWGKuGAb48jG+agNpilbqlKZoWDqDY2AyjtNUlupzYZlKpXgaxIVMNv0zd+/d+uxcaSVuZSPQ/IT13TN34QRvZW81n6HSDdMLUqmjh9tgd//Fi8OHEl3JL3Z2dh3MzGA7XU664llVWRz/QhLjNYmsmaWp/DjCjqIDdlaZTOZZ1/A+fGj7hjP5OLkQBMog0NSE9cSRszuswNhdpt31BRnazM3U9IuPHDrUuG+419eChqU+cvzqjp7u5P9KJpMPpqc51Zv9QntLkFQBEqZluVCw/7nhaP9i376+8YIouRQEyiLQtIQ1cPT8GjOw7vE8tyFtxBrb2MBXdh579FF99g0vC0nzB548ebNHT2l/aFmJj1BPBYyav9EFLaQ+jdPAVNL8/pZ13a8qiJLLOhAAjvrTRy/d0enbF+69d0tzHFhWR/vnk7Rple6mp+9uFFkRGF8LVj/08IUN8wGp2fIcPLh+4sCu9R+F3ucj0MLf4vaVVnChqYWmdaQS2jpY2vd0djh86Vqh7c3Yxm8dudTPxaW0lrn7yJEjZW0Tm7HdC2lT0xKW1xecgHE3FDWNcb7uDh6+r/96Y0prjlIO7ur7TOD5b3ayzt9ylY0Gl83qKFXZsCXrXdOlrV3djf2LBr556JOshLDmMWhPPXV6vav5O5jVxYLUhNl3iIbV8yiqpbI0bQcP85C2Xu0l3dczC0XUN4Pzb71339mFltOM+Q/0rzu5f2fvu1zH+QDOt3uZ0pbVRMRFouJK5qqeTkhVqyBdtdUmhGV5JI4cudrpd5kHiyp3tTU/8s6r+4rC2vCmaQmLWJO0Ep65INJK2tbpt75298U2HLuiLh3oX/95L+0/kHUyvwTieiUJHVEimVzy1UKeWMqv2pCoKEVFRNXT1aHawnBx80eAZj7TwcxdAc5Gi5fiaNnNT37nCk4xaV/X1IRF2B94YHt63qQVaCcfePX2K+07fMU9U7qtHev+xE/7r3cc70O+6w1gxuV0dHZiusgvJS/O7IskRXLs6KCxqj+B26t9a3uUREWi4plbQlTFYzXvu+7tB3EIUGel/L6e3TNw5NS8zYAqldss4YvzBC9C7559drAja3qvDoyg6pwCP+KBZaVOPPjazS1vMLpQKE9fuPnawDB+EqehPwzWuAuSl8LPg90WVxhJJPWQCUmPBAWTBEz1TFUGpqO3wYYvIPgr2az35a2b1/50V6f1e1NTlVcvEzB0xRekj67usu5FmS2/crvQcaol/zeeObfTSOj91dIq28PxiaOHDx9quy8LtQxhcZBqIS0Dhkl2l/3yA4e2j1Qb2JUUD1Iyz1waOQib0vsxKXsAFvH3wMB0JySwtZC+DBPTN5BOCEnhrI1BuKe9l6tIzsVCiD6E0DOabrwI2elZ09aP7N3aNxjheXvK+a1OENa0EFYEyYL9rz072Ju03ZpNQKj7Xd899cKhNrA9LASvZTY/s9GcHoK0XsrakLS8UklLxyl+/rj+/Qfu2367sJNyTS7SuZfneO7ffweBGScu3NwAqWgrTvTc5jjBZmw87tMCfRXYKQWOgula4OiBOQUZ7DZuhrAGdQXxV0zPuCaGnkv3VPGHOpPw7+QPR62OM5HhdNddGOeX2kmCbSnC4mDlSStVTFr4eLljdHV+702vWz9R66Cu5HS5h5hmHvz3QiOxwJTRo2BGgY06dm7OVhewYGAY6s75oD+ZDs4JPY9JyqSCQ7ABqftd5VFM3/j2Ja4mtsWpJQSq6ZXu5UZTKeJnsHpohiYPRqBn04nkS2+CQWW59BK2dAjwS0Y4IHDz2ERWG8Gnwm7iK9W3sFmbvrqGPzw6gW8eTmvTM07XmTPX28KYd7EQ3rjnvv1QFHbPt3zT9DcMPHd+13zzN1s+/hC2rKOo7NjeQdsxT5LEWrYjbdLw05eHtwWe9jl0542u62HZHZIVpalY/yIlP5X3MHYddLLZfy4fmYiBhNuB509vw+rG3tKY+kOwGHLi7W/cS91jS7v4s9TSnZHGLx8CICH9lXNDX+zpWfXuycnaBV2e3e567nAm4973qv0bzy1fD5qr5oEB7KXt0u7B3Loh7yhWVfypbOalh9+wr6U3mbfklLC5Hi1pDRE4ef7Wj+EEiZ+amqpvJT2bzWjJRLIPR3n9riA5i4DZg720DSIrlsrvHXSZ9p7ZGlrzSgirNcetqVp9/vz5FJTqj6JRejTdq6eBMzNpHP9s//QrF4bvrydfO6f1JrCX1mvcXlo98Kembjotr3wXwmrnp36J+pYNeh5JdqRem83O77gxkpxtW3bgOZ/g1HKJmt3U1Rw+3D+zrc89aunagnWzpq6PdxujLz388L4F78tdbtCEsJZ7BFq8/sHBoMPX/I9hyrGgnuDUUZzrnnz7yQu3HlxQQW2Ued++fZmJ1e5LoPB5k5ZpWCPXz+08du+99zrtAI0QVjuM4jL2YcIZeh+2+9wF49MFtYJSlgmHE0g/JlLWLJQPg7RmhtyXsJ18eja0tivsXhj6xy9ve/mRR5TRcG2ZmjyViN9NPkDN3Dz1FW5z9XM4i+s1ME1YcFNpUIrVLHzJzHnwjl0bn1twgW1UwPHjxxPXpztejR0HFTc+F3YXRwxdfdM9W08D0zrs4wtLaM5rkbCac1xaolWOvurhZIPIih0OdVm2haNTfqUlAFjCRnJP4HBn+iUqz6tVa2nGpTe/etsP2o2s2G8hrGqjL/FlEQC5GHghfplSUSMdvwaEA/9+4vjpa3c2stx2KIsfUek2dr+EuXNF2xEjSJx98w/tbFt7NiGsdniSl6EPp84O3W/Z1oPzXRms1GRKWdCJdeCIlJ+vlGYlh997r+70+EPH8NHJEtLCauCph+7bmj81ox1xEsJqx1Fdij4Zxi9AT2KSYBrtslgxhOD2gWOyz7AstFzx6zFHj1mGobYUYAgC9cHge3ddK5uhjQKFsNpoMJeqK6+8cm0X6noXiWUxHA8WxAdWNyQM45HFKL8dyiRpueM7jllmMGpnjO+1w9fNaxmXxiogaqlR0jQdAkeOBPjczrnOiQ6jw88ESSOA6KT7iQzOHEvavu1pZsLQg4QPP/DdZG9Xx/vWrOr+mfR03SvtNffdxleAQIgvTzjBT0w409Mpu2faufZy+vDhw5WPMa25dEnYqggIYbXqyNXY7i/jCyvdfmaVb5hdVsLp9LJGp43j1/1A7/RdvdMwPRzEboRnLVHe9vEvL3eXBOB4ZMta22H+TiqV2LJQ26u5u6Bju44Z3J7O/Lvp6cwPmBanOwQ4uNHRTWMK21bSvh1Mm642nTWCtKkH07rnTE72aOO0XZq7bIltVQSEsFp15HLthg5J/+aJE12m3tVjOPYq1/dW4cTjHnwMYhXOce8xDd3y/PJW6OpMdsTRVy4iK/rKMR/jwvz825VIHFzT3fkx13UW/dnhRy3GJyeeHEs7n1XNibUPFvY6vtGDw5vV9w0Vofn81qGhZfDhi3HX8SfQ/3HPMse9CWcCX0gel2OIFJIt+2fRH7qWRaYJG85NxldGzV4tGayFSLQ24+q9ULyu9gJfMU5ELTn6wUISTl03NHz1KzyiJLqmX657OLLdSJgoXTO7cBxyN172blier4YCvBsFdSNXV2dC35tKJrbzfPfFdjwvC/qs9MSMxxNRsSqmT6LhUDQHE+jUBE7UnATXTuLsrRn01K2l/x6+qItiR3TNG8V59KNB0DGSfNXGUXwJY2Gm+osNhpSvEBDCasIHgVLTt75/aQ0MnXpBNb2QgNYEntfr4wu/nBYpKQLtxtdwAh0SBX3VDe7nM/Ha5vf1Fb/CURS2bCTAWWuxR229qRsbQQQbUed61LfW14JVKKsTJ5sk8WUcHbtlNANyTOhgcmAGKH7p3m1FWpqtuZCu+LByVdKHVMjpKEQrBwIW9tnpXOIH+QTDSH/D9f0bmCLewDn1I4HmwtAypPDZ/oe9oXKf/aMPsWxSs/RR13FHrURiZE1gDR86tKHEdCDMKX+XCwEhrOVCvqBeHNaW6ui11/mWDtLQ1kEiWodXE4rwYgepAPssTPCMOjIdAk94TZ8pMZjch8HjDorGFUTUAwlkh64be0A9/ZCatiDZWtOyE7ClQmIdJICJFYhA+TRV4Fo5/QIHiUvrTEbkVRCxiJfsSBbfYk87OTExXxdazY5yUgiRKfpHQ1YSkONmAZY+gV4NIeVFfCXoLNA5h/Plb5LzWAyzF+IVXdNnvO/6GcsyhjC1vmWZ7s2pO3fdOqzriy9asnJxZREoerDLppDAhiIAEtCfO3F5rW0a6z1PX4/nf53nG5RqqrpieSnULEVh8cx4E7ugH78H8tG9eP/24oVezY+pkpA8b/abhPF8le75BqdsXUtaFeaTlTI2IByEoU1l8oq1mkokcZHElIRoWmpejMMCMyCvQXyy7JjjuUcgOl4tLCzCMpTHgFpcgkViX/dH/ax2Szf8m2Yqc/MN+1r7BM/C/rfCtRDWEozSkbMjq7NTY5t13dqE6dhG3wsSqlp+C9DDi0ifLrqmT1f6BgUaPjiHN0lJAGAfvpWcI4XjiHIMF6ocO/EjmMa9HeelQ1LT1PRpoce/sJwOTCQtc+kfGQp6Uxl+9JWtmL+jNEaJ0gKBgbsygR58B4sHfwV5aliVWg3vCHv6ymHcdG868IzrVsK6pnd71+/dsmXxbD3m3/W2ybn0T1/bQFe5I8euX+9ybuqbXMPbDA7ZCKV4uMOecyz+9OfmWvj9x9zEw6JW+JuOX298WhE6qtwLEV3TL1tb/AWj7sqwfqaro/sdmcyM+vBp2XzzDEzaBiQsNH+e+eeTjQ+ohwqnG0BYhfVzNYKrkOmpyauYYH8KvD8G6RPBszrC6Jq+ystl0ghzXEZjR5+O4+iZwTh+eG7Yqa5rq/3hGzzTSkXKn4YgIITVABjBP+ZzP7i8ydasrZCetuCHvIvFRs92SEdlpnCYE2LOQi12OA7RNf1yjrphHIyE9yOXPnfNMDg70DpdTf8DWDKs5rRvMVwChAWrUgh21HzllD0NrigqlxKVC7bKQuOOWeGiuI7OTkhb6T8C/Xw3xkel9cXxj6eIxiY3Hhx3X9dHsWJwDaa3l1+zd9Mt/F4tUk/ijWnP+/DBb8++LWqvnh0c7NDGta0pO7kl6zpb8AJzEUr91kYEFdeBRCt69Nm4+AsSl6jwjVGckY6VwPwUpLhLURx9xliWvxFHi/w+zB0SWCnLsVpxnoXesSI2ngp4zmRJXPgf/0IleGH51R6uwjeX5MR76qtITh7+8N9Cp4GF7Sm8Zl1s35pVXVomm/5c1vG+Wm284njHJeJq44/FjixUAld8w7uijW6+xo3MhW2S6+oIVHumqpewglJ87+LFtcFUcqur+1vxwPcZJqYPMOyhXw6GKI4+4/GwQpjCBhe+6XDIpFb06PM+np5hhS5eXzw9bLJ2pBLGv4Fe36BU4kA6IQGw8MUY6MJywVeqDs54Z69zrWdY7jI3G1ZtUiSV6zzDI3IqLLew/wu9jspl+yywrA1pEed5QceXPT3jBb/DLrA5ua5UHZ/4eMTbFx+fwvE3DJO8fANrjlctL7giJhRx9MrfR89R+VgJ1Y6currONuwd0FNsxwtV02mPlWGLy1TxlPHf6Hh8PH9xesvw9yRM+5PIRT2ZIgVKKZxWUY/PT8aTFPji0i3m4Ed1hDWV/7uY9bNGtiGqAyorJRWSqCgdkrQiR5KddrwPlsq8xfhG6efvx8dvtiQczDdmmPaldDBxSVYeZ3GJXxUMWzxq5d4fPz7Ym7X1HTAL2A7NqtJHEQ3qtCPjw3LoxB/v+OMZ5VVzR5aHWRuErYA+y4uu6fM+Xl9J/lh7bFvbY+vmv0bWos9tsXAWSLIiaSnyApHxJz6SbFSFuXTw8i86r5vVRW1m+6IHmUREAuI0lcREP5q2ztWPrO9/YK54xsXHI56+cePvj3qBfimZNS+J5FWMcrjptThsRd4dPX9+DcwEd5iQphwozfkCwJKaLv9ewHYKeicfSudwShcnJDBBOD3MTwGRO0cqLIj73jQTaejDBYaPHTBgJ/i5+HyYijd95sFhRzkzB7yL2IrCtGwezj9nOQVTUlfPwiicifnu5J0qHHd8mXHIG6ZD7JQqIk9kJK6QwAokMWRUhMaSeJ0vcfaiXNhs7PyuwpYV51Vh+EM/Pu2M9GckpyiOuZm2Wvtom+Y4me8xPbvIIujzPu6Wbvyt1ejL3U7Sv/v754ZHsORwaX3KGdwiJhO5pzY+Mivk/urVq52jTnIXlEc78LKu8qAMx/G8kHhyOicosz0ovM3IrIDKb15HSvDoOoqv+hMLYCOWI8ash0vmufryZVcqLz4u8fym3ov1xT/EVp4UDUTn4/iS0xW+sZTMojASmLqGp64iH4FRXJQ2TKj+lv7JVRTVxwQkm9APyaboGnGMzSVR6VR87ipsVT645ovOzi5tamb6zzB1/nqzjz+s9YetwLioZW5C8jq08K9+1IxS8yQsfF6ap1WL2BK8VOaJc6NbPcPrx7wJ++hmHQUPvOaQgMJ3ETtVlERDP0wVsQ19uPgcLQyt/Dc+p4jlL6k/1xa2qVyh5ApEzEoErm/DsPOTXV3de6anq36roFyRdYWVbVSshHJEMt98saIXfIu9koplYZL6m/hUz7kS/Jt0/PE8+Jj6X/Y6k+fv2tA1BKIvB/OC8WnGAmp5dpqx3XW36fjgYK/upXbhFd+BrRlqn16MfkrspkoC4hnirYjbUVWzs4rHx8uL3cerjwt0TA4RcBcsuX8Rn97q54okVsCKJJ9YkSvy1gJR4aOtnAr6OJP+L13d+BKBKMEzHhAfgDh6yzD+vqHjTDDvYpAxLqwEfVdbE9bpIEi6V27tdLP+LnzPrWS/XrRTnz5d4e79+LNY7r4kP+Z7Jv7z1LyPL0B4Tb+ci9cXLy+eJ54e8Rw//rqqcUR+HOrgYVprJbBl5E2w63oI64J7k8mUDZLGhmAXs19ucVkxP8gKQu4ptCxbMy2TW3KAGI4u1P207ztH3CDx/7bL+Cdse8h1Zy5ev7Dp8uHD7blJuy0J69TV8XW6l92Dl3cbLG6g98idbhDgdANcY1ZY9o2N4mpNr96GRf1Da3Wui0RW69F1bWslvp81LD2xDTOGu9DhQzBc7AcYfYlkAqo6A6ozqHNBYJTESGitTGShsp0qQSxT4AcoPJQw0LBlEPhBFakHDjoLvY+XgVIyg7WK77tG8n9pvpHXBbXL+OMBd7FN6KLu+uf27esbX9RHdIkLbxvCGhgYsDb3v2a7obt7YHakpKmYiqgE2ioqJbzIOszXcSov/DAzRRNehyJKvPx4+igv/ZLKEaCkoZxUFMYXE1I8f7Xyq/UHp9CkAlfbCF3NdlhS7IQguA0N2wiJYy1ktC5IISb1Okr5jSYruy2SGlYkIkKLSC3yy/WrUWGzSnjaTUX/QEhYQuNewLCdwBFKRkpOuAfr4sBnwwfDg6B0MHagORhBHNqHw5WxTwYav6lAt/42MBLfrYZXHO9w3Ftr/B0Hp0pY+tkD29ddAz5ln8NGjddSlNPyhHV8aKjbzAS7Dd3egRcvgRHJWyrHASw9Pyp+vlSxEluH0jWAGQF9VVZMpxHVRZ/xSKQU4PR5Xy0+/sLQZCFS9DN/XKtSeh5WrL2x+sMyZv+W67+vwz5eC7oDx12rm9pakNg639B68XL3Qh+2Bm94DySxHhg0daBHSQhiCbyyyMS9SDi8RhEHyYP1qD9qak0S4VGn5VYrSTRKEkKHWYYiHuQmCYb/YKYLqS+3H5LYckxJmz6qhSYJ5yNgzgtuclESpncBfN8Fj3lgJdCSGpHcGECoxrouMoHjzO+4evLLMB1VKxJV8Wyj8Q80Ix043jnTu32hlTdkh08Yn7UWcnio9Qs3pzZm0lN7LCOxIdIZxbuQ1+lAVFFxJB7aMeUIiPkiPRPjo2v6dPF4FVjHnxi/oQK0Az/bymf5uI7ayGLj6eM63nrbF5VNXzV7nv3HViQL3JAEaSV1z0iBNJIgJBCYkSKJYbdjEiSHw7a0BI5s6QBBbINUswMUsQ6E11UojZGccA9dcZDBdQY+TgyFTgkiEKYyIBvstAQzIRk8cBJ+A2j4gZFDFWAqjAp3V5IhQYYwwUJ57ByS0QINzMYK8FyrRxt3KNbXb2qG/UVNT5wDyCt6/A0boGbdqzPA4tD21SPquWihPy1FWHjQzYs3xnZkM95ePIZd8RccBx1xez/UPowp46I4+uVcLD9/8Plq0Gfy6Jp+uez5uqPyY+UtNN5DuVQc06drpv4bIDXsjtsMpdkOSC79QK4Xog3PzwF4IBNCBiIhpBSpoE8jioqWaM2KCRuOqwLXgIQItKIe0lCYD/lZjoqgGIo0+J++SsmMKA8eqQ21qHuUh2PfzQHN6vgG6vVK8GfmQhcbr3Yff+AEi3rtdCtNF8u/eIWD2ATXx4Mg0XH1Vr/hm7sDQw8PvyvTrriKWocEE0C6oM/kJRJHrAykgj6WGlq+JUifu6YfS6pu4/UVa6AgQcXKi78ApekhcWFBwMstEkTX9MvVHw+Lt2ex+4+Pg62CxgsHEwZbAdgWIJfA+ICkfDRYtyAwWWB7Ay8F8VT/KB0bOJ4Gx/CQfUKSwZGrJJs8iZHYgB0zMB+zk8hopQ8hEcEog2ERASIBAOL5fIrVIKLxXKtzKPZLgZUckvGf+/nH5HsK0+Uz3316zeAjj3D23Lwu90w0ZwNpiZ72UnvwfO/AXIFnXfLBxLOsHn6yiLqmr3oQ04LHX9hq6TFHI6txrlYWkHj98UT1lh8vryR/rIKq6aO204drdP8hRWF3itmLUw42QnW1CSTSA2IAIXkWOBYKLWw8wjVqNkEaFqjFwLQNJhWI4ZiFoiq6QX0SbsEo6HMoWVFCYprwjw6FP65BXCSoXJwiOwpnFK9A6yiWkQhRDwA9XAfpwLS/AqnqSKP7jwapquiznXFXMn6x8Yg/X/HySvLHKqiaPlZfvf0H6BloAM/v3tpzHkJwUx59Uxb4GE5Lfnt2ZGS16SX3+F5mq4llfegtwnaSR6J5EC8hPUV6IDaS6aDnoZ5DpYe6AtdgOr4pyhXLNPH0KKCo/DDP7N+S+mI6qHzbQr7AbdgW+iylWn0l5cf6E29ftfSN6L9lGl04x30tOtMHklmLhxpClW9BL4S1T+i2uNPRp+0FflD0AN9A9LHnmHGBBfJCE3QL9ALiguoJqiu+64gDzWGIIAlhzhaSDsMV/yjJi3BxyY9khP9BXBSzEMY/AFORGMmM1yyKZfmm+ZKuJf4uMHV1THEj+o+S864E7zYd/8Dliqp2MamvPbt9uw4dY/M4DnXTuMuXx/scK9iHLcbryzfKwvOJBSGNPl10Tb8WV0xYyMFymDdXXv46Kq+ueChJQI4WlSUqf8StOf5CNdXqr9afxe8/Gm6AoLAqGKyCGLSG350ACFzKM2FvaeOseEhFOsjItdQ2S6wYYmkOdl2+CfLBvmpIV55vYY2Qn6uAxAWC40zbhxSmWArcQj0TSIiSU37mx0kgVesgLereOSz8E5EWJa6Qzyh1hZEcO7xY4Ct9WLfNvwa+5xA2h6uGP6vMPxMsZ8WNf0Gf+cOCw9usq51a5+kNG9Sn1IjJsjoO0LI7EpVra/vxhPdFs7JyjYriohlbTAKGxO1C6oJEljseOLqmTxfPX66OucJK66OUNzuDjK7p05UIbGwX25I/vrj4BYrnD0uZ/Rtvfzz9fPsPIkgkbL0DZNMFRVEHFEY2ZCBTcwMLdfCsCCVN4SwpE9YG+ARNgD24IDHYSYB1yNCYDkLRFoC8oOUG40AKQx5IYyAmlQ6SF7dDoSof0hbJiApzqLs43aPc5UG+AvVQ/4T7nGQFQiJ5kdbAkmgH2Sz0FaWB4gLrad22v4nmuvPt/yzCc1+V4t0e4z93r8PYwDCvNANxLSthkai0jmCf5+jq6y6Y4SkjTfoKprgWufj9Dg3AozBmiK7pl3H8WDH3u0YfLY6u6c/HVS2vSvsxoygyTF2q/qNenEyjJ5NJPYGPRidME1M1/JYqwyoNq32Ihu4J0z5M+WA2DoqwEI9wfmEaEhQJzPNsKNOh0jJwrfRVJqbnNOrC6IGwQFzgHiKrpCuq2kE+FizrMXWE7IWCEKemg7hSiimOQchNIC3EchqpHlBO95TshQThkwF5TL9k+Mm/MZLGzVo3AlQdLzagDle1vCYd/wU9/5Z5ZcyZPnNow/J8ZHZZCGtsbKw3rdn7nIzTx42o0WfP1cPKuYJ6XPFs5q7p8zmKx5v8cdcxDeMPOR1fj+gh4X10TV/dukiC+nJPeLy8eH1hrtm/UVvpKxcrP2oL/dlcs1eQ9PCeo73wGcp+R2Xyvlp74vH19B9EkoA2CYKUlcQqJCQj6vkoyBjh/IurcJiy4Zxy2FMptRBO7sK3kClR0UYUZAX+wMqfC1ICiYHMYBsKSQsSFKaAUEqZLoiK00ASFsgpN0UEUWE6yOkiiArE6NmUb91OWwAAEuNJREFUszCNxA0c/uBoF04W86YOarWQAYjGmHBBEIkUiXEqib025hNmInWknv6zKo77Sh3/RvcfSx5Xl4O4yr5Y7NxiuEEQFT4uvs8yrF5VvosX28LLS185vsiRHkc9YPiJtrCbJIzHyx3gJdfpl80flZWPR6qIxJghus7xjSqj4E9UNn2VvN76Csqq6XIR+48OYEeGlcAaXhLfQwxNQcgQEI9IErOOxBUuCuDLz9Arm5iyOTaYy7Jty8hAb2VCm43ZmwnwQTbgFpAWyA4SGEKhaMdgYNpngKAcpeMCAfFjYGE4yAqco3RZ0LorUqOkxVkf6AgzvFBPFbISSsOUD+WRrWijpcwbmI4Gomj4yxAIv4bPVU+q9sfxk/EP36UlfP49N3vNWr/m9CZdX/zzjDDofAoW3XHVr9NPHdB8p2+uORl/mjFLUktMbBTtkSJbpLCRxYyD5OpJps/4+DJuvq5IIgoLqfi3pLzcRuloM7QSzKImsBSWG80LVKkxkSvOkFHaCjL5QvrPN9rwvaSVtEg2ICmQCNRQkGjwnlOpNktMxdds+GxcRFrIyCmhTQMEUJjl4qwtzPbAOVC8o0DUZroGiMmBpEUfRBZ4DvRUJC4/1GOpij1ML9XU0PJdFxIZGsOpJkkOQ0YdFh5CPodKl0WfRqQkVUhTIEf1iN4GkdJU4Rx/xsJfHkpfMv4cd+IAUJb1+YdkfSU7NXp6+/bti7qquKiEdfVq0Gl2TO2DonYzAcUTCv0slCB8FuGia/q8j7iAPl30aNIPHVKq55w+00MvjFLo05WmV8H5P9XLzydVF/H0xbGl9UGfjm226B98po2u6fO+0f3H9M7SbT1h+FoS00ybSmm+5/RZHxzbwWvVHtSvNuLRR4BKl0vPtHRhWh1SESUsNBkH0qjvNiAx4MA1JDBc4yBmTPmwJArJCFM+dA1SE5XsmFIqRTzKUrZYkMio78IUkauFoW6Mcbin1GWrOR8nqOEUEUQFmuK3ZdEw6NFg92s9j3XLp0CIsAuS8VdPkcKhCZ9/KAc81x/c3NdzFjy6KHZc0YPNh7VhDg9jYnh4co9n2dvx1nLalys7Rimx2xLGigfEJBQ0Xr149FkBVb04BQiTlPAFbTiDxRGKM1pJf5AgarPKG0sQu413N07hkCANO5m0fSebtCwziW5DqMISHTRMJCDF23inYbmsauNCHq+Vn1ta5dErzKN8psP/RiIXVpAegKJQ30Y06AQSEXdAIpdL0wbTNsLpoSIeCwRJHZYBpTusIFAIlPC0iqL5AxoCcmLPQkkLdITRCc0dSFqQD1A51g4pLOXmhZCwDMO2BpH9q6ZtDoU4oKQIy5yEynFnv+mzw+0+/q3Sf5yT4aYs89zq1alLIK7wYeQANcCpgW5AOaqIARzxcudrXrMTz+cuFAxBI1Rw06eLKz3xsnDikt+Mmr9mWBlXrbySeJAlTt8MXJImXHRNv0zx2GpWZ3r0KKqzXHlRHH26+fQf+mkbg56ADjppUuihMJl7BEhGtmnj+4Phj1lEUAzjaQcgJkzcqPPmlI/yjdJV8Trf/+hbeYyP0uMS0zSVF8SEaSELxkhR6a7IC1IVHkNMBWEkCljxYQ7YXgWKrDCHw2ohJDDKSkr5Tst3TANBp7DdgkTFKSOpxYMtV2i3hXQoJjwbBo3L4oibAajdXmSbCl01PEvi6x3PetMvwfi3cv+xHpPRk8GZvo6Oq5y5FvZlvtfqQZ5v5igfH7iRdHqrn/H24McyEb6ejCUxkCwqEATi8JDNKtWRIxI6wrLj+aOyQgIqLT/KTZ+OLYnCFGHE60PdSgzIgVmcfrbt5evjYkB97VeNyv8plx/UYoChElhYgB7KtD3PAUWRpejIVNzNAjNzyDuYRqnrMF5dIx4CkTrlAJQRps2FhZIX5lqYwfFLOygTBeSmkUhDEgNvIC7MR5ML6JhozoCpn+858G1utbH4j7BRT0Z9VlZzbTyOKJCKeCjkqYbkFBJh+DXCPVcKuXKIFURlm8WBoZSFOBCYmk6i33ioT+Kw1CegEMspcFfe+M8+rRySNum/YUwm9I7TPT04NWOBDg/nwtz16xMbEp3mPswIOuI6G7wBSlynz1pQWZEIP0smIcEEWN3QsfJDn+nj9FFSPh73wilgdE2f+eOumo4pPqWI2kI/LKu4RVXLq7H/kJopRUFhnkj4joNT9KC/BlZgAIVD1I+cwASVUBgCIsF1KEQxJLpGPKHGP5LYrAs5ikREnmJ61KF4K5cG1+REVS6HC1JauGroYYcOrLWUEp6MSF0UpoZgK5hV2dgEzeNLYbMBnRQZEUPnOwGMT6GOp57Kg/0WTCMYjnsQHpDmlJFTR5IcNt/alvV1PdF5NsKcLSpGG03L6QcjnWDpeIXqgFYb//A9wGi1+fMPDeqY7nae6uvT530KKp+JebkhHJyX6Fqz33X83tCgRr1d6gXBH+XnFtEwDmEVMBfAtbK7UvHxVTb1gGLQokbFVBZMDtUJHmT+dsPxmqSRU2nkrxkWxhfbOfEVwLov4sIaonSRr1qZy6vy8xliPbn+qPjYHxSm6mJwdB357DfaVtJ/BMLeW0/ayVQSR6TA5AB7h8kwmFeRrFBUSFYkJk7GsM+F5SuiCQmFBEriCskHYcxfEM9ozBjBS/yaKD//rBzndjD3BHswAcmqwFdhOWGugCw5owwpEt9sxMlVGWQEK4GlcAOi1XAcL6eLICfdcMFmNDnH7xdO/YTCHTkxM2B6EiSPbuXmHrZO5eJy4Iu6lfo2Gu8orFfA+PM9UMjnHpBIx9v+/Q9Wm8nMfcMTE1d7u7vP4Ec6fzy1wqOGP3xI63JHjgT2/rsy/boTbMP0pe78dVUWS5wjK0VUjIqNN3kA62ZYeIcfxofXDFNFUZBTT4W6m71mWBlXrb4yWSoEYWh0jVIUdJEmzA6o18mRDN7dCplCEkK8IiP4WRAU9OO8j5wimZB3SAhKYlJEphLkJCaSEP7PEdxsfVG5UWFxP6qPPngTlvBED6IWLN8dTPmg8ocFPPRXWBdlFWqqCEmLlhAgLRtKdLaAkpQNfRUM6DUQGOUiTimNEaT7FvRVw/F6K91XG4/mHf9KPaovvJ36jzfSS1mpc6mUdhnvhZL4a0GjZsKBKK+n0+kt0AHvztCAsIzjeeAeUKVPF1l101cBWCICxcGmcPalUeHRnyguIsJYej79fFnpKxdjrKhu+spVK69Ke+OW6SXlh7Xk/8b7D5umJKY6nUiQAEmp5ZKoD5Ay8kTFzcAsJIrL+ZREYCWAaU4ubXRNP8wfpuSuGubHMwCJhSuGPCiYJIMw5GV6xkfY0Wd+WoPiBAlEhvnzNluw3SKZYTkQHIQ5J1RQDg7Lw/QQGUIdFp4wcC9KgQ/7KkxjucEHROVmc3ZaCFfEjMxUvlPvBZ0WhT1Q1zG06hQKyGPA9qEh4bPRJuO/0p//WvoPyXpa77BPr9L1mn64QiJRT0vlP3jg1oyn0/th1dnN6VOkQyh8wVRuPpLUH9GHi+sckD4vLaj43NSHLwfv8cKjbGxdgc97JUpFpIRbpovKYHTUltkpHYkyEqNYf1gWfZU+Vn+JiMZERS4qKyTAMv1hmwoItLT/aL6OL9cn8A4mknhDkR5CUuh43ExhAXjnIQVxRQ9UwnU1JM73meHISINzlY/1Ir3jwNQBtui5IpU3K2mFZbEUEhgJiHlZhkqI8rws7hPFxBHlZ5romu1CGRSv2HyQEQiLPkwefJcSk2o0mU+F8Z46KswbKd8qvRUWiq7BsuoYlF/q+Jd839p4/KNnFHhw+Fbc819r/y3dHO7qsk9D2lLPBvEq59SLXC6CYSCq1OTk5F48g+FxLyQSvvyzhFK8taaYL1ACiYdkkSOg/HVO4irmAySLlR8+yHy5wnaWysTF7YmnRxdyecMXFDcxx3KjNCUEGUtb2r4Iixwh5qebxEG58v2Hkh0ERqlLp5kClNLkngLSyF8XExrZi089SYbFm9DRg1FCbEKyoxQE8sqFkTOgTwrDVIPCP/k8qpRcGrxMEXmxnpwjUeXbhjpgA2bBNsp0HPQWOiwNOnddw5YcNIdSFyzTlUKehEbrLDxDNn7osjCXPw5FO22qgPfKHn/pf8XxxxetvSvYlX8BxBVKCdGDmPPDhz0W+Oijjxof//jHt+Hh2oko/qKqFx4l0BJQmQIwS3RNn/fxZXqGFbq4nQzimI9tKFs+S1S1KJ9XoQkEfUQwtKg98fSzefMMwmx5F28/IqK2RLjM2b54/gX0H0v6+IiDZSVgHJogfYWNzDMUpCtsUkKg4pKIUJAsnNTlkjNWzfBCPMOhi8JAiCSqPBmyMFVQ1OdctQwLywNZ5cPCpDl80D6IhjzBASQF0sUeREpSJCyE4ceSpJXbEO2612AHepaTSRn/YrtEAD3n8xV/ntv4+S96nyGRO9gccQZmEPiBK3bRi5kPHcG+v2T32n2+53bxNY8oQyWIB0SR9OmqxMeTh5lm/8azx8srEbCQNSqTpUTX+eagwCiPqiWeQAXO/olHV2tPaYUFjWCxsQJjt7MV564K6iOB2Xj1adNGa3PqDMFl4XwSSnAQCUIibqFPlwtTwbiOkoSR+JvLx3KYv9BXaSrlLyifSegQBNMFTAWhiIeFArRZnoX+8Y2EzKhbnuNlYO9wFpZXkwoH5Kmj/6qOFTz+0n8+Y4Y/2pVIcJqY35+YJ6wjEN33ZzL9kPY3hWjx6Sv+RcByLIQAZZYQJSn2C944FRF/QkvjQ31XZDcV04GVPOGl+WdJEhVGbaNPV3d7Va7ZP83U/1ACgzTjkg4gjUFvHhGWkrPAPnnBLNeFSEKKfAbzOu9yBAUdVj6cZURpZuU3XOUILioD93x2IEnxxFGc9c6M+M93cHSNZVzHquBQDeMn4x898wQ2us7pgGvAbyU8/z5e5EupVEqtJirCgp4KHxVI7sbrQIYKHyKF3+yvIvEEX8FsQNk9qXwgBpgQwNo7p9OKrukzfdzF08+WTmYrV35YF+tU8bEpYImInGtLVH+8PkzZ8iQcVpjrawXCLOHH5uo/9JmWjbXHJMQcNhVW8bOklbsumnJw7Q+cgtVK2mJxAUNNKKncp54KHuzAwnjCE01B1UIHA1A80ik/IkdIfTj6mE8MXh2sSKZhdHUd+IcDykwFLj4eMv7Fv+il75c8/xEmeHaojD+jZ4LgbsPVVvO5iutg4oSAFCCiAqVp/jrUKRU8mzVexsube05ff3tiD0Q1wkP/ojrYgeiaftiheHsjLKL4GrudTxYvb0H9h94bpzeAwCD4cAqJf5SmlBjFH5D8ChVC1Q8KyIkrjtgbE64y4lqtINJHel5Hq4q4ZdsYzsWBWaU+rkFWtFzQbiNNnWciNbT/qD4+Hitq/FdE/3mWzmvQU+W4hZZPenQuRHRNfylcvfVjpUqz0Tj6dNE1/fm4euufTx1z5am3/hr6z6lj9A9ElneKwPJ3IYEVEpqKys0YFeUhoDBP4TV/+bjVIkfqKuu8/ixC/+tqR73111V4DYnrrb+G8a+h1tkk9dY/m7MxV7XUzwdP3ApBgCYG6Co+L6/+kcB4X0g0ERFFzwXjojBc5q8ZhqOKtWEoROmLEwSWBIHowVySyqSS5kIABEYhisRFEov8SgRWGD6K9OMgq8IwBIkTBBYXASGsxcW3pUoHgfF5iIiLPv9x+03kuLxMqaqsUj1KJL4gsFgICGEtFrJtUG6OwDhtJHHhqLOl+dBAG0AnXRAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBAFBQBAQBAQBQUAQEAQEAUFAEBAEBIGVhMD/D0fV/fpMMM+gAAAAAElFTkSuQmCC'
  16374. }
  16375. };
  16376. exports.default = _default;
  16377. /***/ }),
  16378. /* 115 */
  16379. /*!******************************************************************************************!*\
  16380. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/noticeBar.js ***!
  16381. \******************************************************************************************/
  16382. /*! no static exports found */
  16383. /***/ (function(module, exports, __webpack_require__) {
  16384. "use strict";
  16385. Object.defineProperty(exports, "__esModule", {
  16386. value: true
  16387. });
  16388. exports.default = void 0;
  16389. /*
  16390. * @Author : LQ
  16391. * @Description :
  16392. * @version : 1.0
  16393. * @Date : 2021-08-20 16:44:21
  16394. * @LastAuthor : LQ
  16395. * @lastTime : 2021-08-20 17:17:13
  16396. * @FilePath : /u-view2.0/uview-ui/libs/config/props/noticeBar.js
  16397. */
  16398. var _default = {
  16399. // noticeBar
  16400. noticeBar: {
  16401. text: function text() {
  16402. return [];
  16403. },
  16404. direction: 'row',
  16405. step: false,
  16406. icon: 'volume',
  16407. mode: '',
  16408. color: '#f9ae3d',
  16409. bgColor: '#fdf6ec',
  16410. speed: 80,
  16411. fontSize: 14,
  16412. duration: 2000,
  16413. disableTouch: true,
  16414. url: '',
  16415. linkType: 'navigateTo'
  16416. }
  16417. };
  16418. exports.default = _default;
  16419. /***/ }),
  16420. /* 116 */
  16421. /*!***************************************************************************************!*\
  16422. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/notify.js ***!
  16423. \***************************************************************************************/
  16424. /*! no static exports found */
  16425. /***/ (function(module, exports, __webpack_require__) {
  16426. "use strict";
  16427. Object.defineProperty(exports, "__esModule", {
  16428. value: true
  16429. });
  16430. exports.default = void 0;
  16431. /*
  16432. * @Author : LQ
  16433. * @Description :
  16434. * @version : 1.0
  16435. * @Date : 2021-08-20 16:44:21
  16436. * @LastAuthor : LQ
  16437. * @lastTime : 2021-08-20 17:10:21
  16438. * @FilePath : /u-view2.0/uview-ui/libs/config/props/notify.js
  16439. */
  16440. var _default = {
  16441. // notify组件
  16442. notify: {
  16443. top: 0,
  16444. type: 'primary',
  16445. color: '#ffffff',
  16446. bgColor: '',
  16447. message: '',
  16448. duration: 3000,
  16449. fontSize: 15,
  16450. safeAreaInsetTop: false
  16451. }
  16452. };
  16453. exports.default = _default;
  16454. /***/ }),
  16455. /* 117 */
  16456. /*!******************************************************************************************!*\
  16457. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/numberBox.js ***!
  16458. \******************************************************************************************/
  16459. /*! no static exports found */
  16460. /***/ (function(module, exports, __webpack_require__) {
  16461. "use strict";
  16462. Object.defineProperty(exports, "__esModule", {
  16463. value: true
  16464. });
  16465. exports.default = void 0;
  16466. /*
  16467. * @Author : LQ
  16468. * @Description :
  16469. * @version : 1.0
  16470. * @Date : 2021-08-20 16:44:21
  16471. * @LastAuthor : LQ
  16472. * @lastTime : 2021-08-20 17:11:46
  16473. * @FilePath : /u-view2.0/uview-ui/libs/config/props/numberBox.js
  16474. */
  16475. var _default = {
  16476. // 步进器组件
  16477. numberBox: {
  16478. name: '',
  16479. value: 0,
  16480. min: 1,
  16481. max: Number.MAX_SAFE_INTEGER,
  16482. step: 1,
  16483. integer: false,
  16484. disabled: false,
  16485. disabledInput: false,
  16486. asyncChange: false,
  16487. inputWidth: 35,
  16488. showMinus: true,
  16489. showPlus: true,
  16490. decimalLength: null,
  16491. longPress: true,
  16492. color: '#323233',
  16493. buttonSize: 30,
  16494. bgColor: '#EBECEE',
  16495. cursorSpacing: 100,
  16496. disableMinus: false,
  16497. disablePlus: false,
  16498. iconStyle: ''
  16499. }
  16500. };
  16501. exports.default = _default;
  16502. /***/ }),
  16503. /* 118 */
  16504. /*!***********************************************************************************************!*\
  16505. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/numberKeyboard.js ***!
  16506. \***********************************************************************************************/
  16507. /*! no static exports found */
  16508. /***/ (function(module, exports, __webpack_require__) {
  16509. "use strict";
  16510. Object.defineProperty(exports, "__esModule", {
  16511. value: true
  16512. });
  16513. exports.default = void 0;
  16514. /*
  16515. * @Author : LQ
  16516. * @Description :
  16517. * @version : 1.0
  16518. * @Date : 2021-08-20 16:44:21
  16519. * @LastAuthor : LQ
  16520. * @lastTime : 2021-08-20 17:08:05
  16521. * @FilePath : /u-view2.0/uview-ui/libs/config/props/numberKeyboard.js
  16522. */
  16523. var _default = {
  16524. // 数字键盘
  16525. numberKeyboard: {
  16526. mode: 'number',
  16527. dotDisabled: false,
  16528. random: false
  16529. }
  16530. };
  16531. exports.default = _default;
  16532. /***/ }),
  16533. /* 119 */
  16534. /*!****************************************************************************************!*\
  16535. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/overlay.js ***!
  16536. \****************************************************************************************/
  16537. /*! no static exports found */
  16538. /***/ (function(module, exports, __webpack_require__) {
  16539. "use strict";
  16540. Object.defineProperty(exports, "__esModule", {
  16541. value: true
  16542. });
  16543. exports.default = void 0;
  16544. /*
  16545. * @Author : LQ
  16546. * @Description :
  16547. * @version : 1.0
  16548. * @Date : 2021-08-20 16:44:21
  16549. * @LastAuthor : LQ
  16550. * @lastTime : 2021-08-20 17:06:50
  16551. * @FilePath : /u-view2.0/uview-ui/libs/config/props/overlay.js
  16552. */
  16553. var _default = {
  16554. // overlay组件
  16555. overlay: {
  16556. show: false,
  16557. zIndex: 10070,
  16558. duration: 300,
  16559. opacity: 0.5
  16560. }
  16561. };
  16562. exports.default = _default;
  16563. /***/ }),
  16564. /* 120 */
  16565. /*!**************************************************************************************!*\
  16566. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/parse.js ***!
  16567. \**************************************************************************************/
  16568. /*! no static exports found */
  16569. /***/ (function(module, exports, __webpack_require__) {
  16570. "use strict";
  16571. Object.defineProperty(exports, "__esModule", {
  16572. value: true
  16573. });
  16574. exports.default = void 0;
  16575. /*
  16576. * @Author : LQ
  16577. * @Description :
  16578. * @version : 1.0
  16579. * @Date : 2021-08-20 16:44:21
  16580. * @LastAuthor : LQ
  16581. * @lastTime : 2021-08-20 17:17:33
  16582. * @FilePath : /u-view2.0/uview-ui/libs/config/props/parse.js
  16583. */
  16584. var _default = {
  16585. // parse
  16586. parse: {
  16587. copyLink: true,
  16588. errorImg: '',
  16589. lazyLoad: false,
  16590. loadingImg: '',
  16591. pauseVideo: true,
  16592. previewImg: true,
  16593. setTitle: true,
  16594. showImgMenu: true
  16595. }
  16596. };
  16597. exports.default = _default;
  16598. /***/ }),
  16599. /* 121 */
  16600. /*!***************************************************************************************!*\
  16601. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/picker.js ***!
  16602. \***************************************************************************************/
  16603. /*! no static exports found */
  16604. /***/ (function(module, exports, __webpack_require__) {
  16605. "use strict";
  16606. Object.defineProperty(exports, "__esModule", {
  16607. value: true
  16608. });
  16609. exports.default = void 0;
  16610. /*
  16611. * @Author : LQ
  16612. * @Description :
  16613. * @version : 1.0
  16614. * @Date : 2021-08-20 16:44:21
  16615. * @LastAuthor : LQ
  16616. * @lastTime : 2021-08-20 17:18:20
  16617. * @FilePath : /u-view2.0/uview-ui/libs/config/props/picker.js
  16618. */
  16619. var _default = {
  16620. // picker
  16621. picker: {
  16622. show: false,
  16623. showToolbar: true,
  16624. title: '',
  16625. columns: function columns() {
  16626. return [];
  16627. },
  16628. loading: false,
  16629. itemHeight: 44,
  16630. cancelText: '取消',
  16631. confirmText: '确定',
  16632. cancelColor: '#909193',
  16633. confirmColor: '#3c9cff',
  16634. visibleItemCount: 5,
  16635. keyName: 'text',
  16636. closeOnClickOverlay: false,
  16637. defaultIndex: function defaultIndex() {
  16638. return [];
  16639. },
  16640. immediateChange: false
  16641. }
  16642. };
  16643. exports.default = _default;
  16644. /***/ }),
  16645. /* 122 */
  16646. /*!**************************************************************************************!*\
  16647. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/popup.js ***!
  16648. \**************************************************************************************/
  16649. /*! no static exports found */
  16650. /***/ (function(module, exports, __webpack_require__) {
  16651. "use strict";
  16652. Object.defineProperty(exports, "__esModule", {
  16653. value: true
  16654. });
  16655. exports.default = void 0;
  16656. /*
  16657. * @Author : LQ
  16658. * @Description :
  16659. * @version : 1.0
  16660. * @Date : 2021-08-20 16:44:21
  16661. * @LastAuthor : LQ
  16662. * @lastTime : 2021-08-20 17:06:33
  16663. * @FilePath : /u-view2.0/uview-ui/libs/config/props/popup.js
  16664. */
  16665. var _default = {
  16666. // popup组件
  16667. popup: {
  16668. show: false,
  16669. overlay: true,
  16670. mode: 'bottom',
  16671. duration: 300,
  16672. closeable: false,
  16673. overlayStyle: function overlayStyle() {},
  16674. closeOnClickOverlay: true,
  16675. zIndex: 10075,
  16676. safeAreaInsetBottom: true,
  16677. safeAreaInsetTop: false,
  16678. closeIconPos: 'top-right',
  16679. round: 0,
  16680. zoom: true,
  16681. bgColor: '',
  16682. overlayOpacity: 0.5
  16683. }
  16684. };
  16685. exports.default = _default;
  16686. /***/ }),
  16687. /* 123 */
  16688. /*!**************************************************************************************!*\
  16689. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/radio.js ***!
  16690. \**************************************************************************************/
  16691. /*! no static exports found */
  16692. /***/ (function(module, exports, __webpack_require__) {
  16693. "use strict";
  16694. Object.defineProperty(exports, "__esModule", {
  16695. value: true
  16696. });
  16697. exports.default = void 0;
  16698. /*
  16699. * @Author : LQ
  16700. * @Description :
  16701. * @version : 1.0
  16702. * @Date : 2021-08-20 16:44:21
  16703. * @LastAuthor : LQ
  16704. * @lastTime : 2021-08-20 17:02:34
  16705. * @FilePath : /u-view2.0/uview-ui/libs/config/props/radio.js
  16706. */
  16707. var _default = {
  16708. // radio组件
  16709. radio: {
  16710. name: '',
  16711. shape: '',
  16712. disabled: '',
  16713. labelDisabled: '',
  16714. activeColor: '',
  16715. inactiveColor: '',
  16716. iconSize: '',
  16717. labelSize: '',
  16718. label: '',
  16719. labelColor: '',
  16720. size: '',
  16721. iconColor: '',
  16722. placement: ''
  16723. }
  16724. };
  16725. exports.default = _default;
  16726. /***/ }),
  16727. /* 124 */
  16728. /*!*******************************************************************************************!*\
  16729. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/radioGroup.js ***!
  16730. \*******************************************************************************************/
  16731. /*! no static exports found */
  16732. /***/ (function(module, exports, __webpack_require__) {
  16733. "use strict";
  16734. Object.defineProperty(exports, "__esModule", {
  16735. value: true
  16736. });
  16737. exports.default = void 0;
  16738. /*
  16739. * @Author : LQ
  16740. * @Description :
  16741. * @version : 1.0
  16742. * @Date : 2021-08-20 16:44:21
  16743. * @LastAuthor : LQ
  16744. * @lastTime : 2021-08-20 17:03:12
  16745. * @FilePath : /u-view2.0/uview-ui/libs/config/props/radioGroup.js
  16746. */
  16747. var _default = {
  16748. // radio-group组件
  16749. radioGroup: {
  16750. value: '',
  16751. disabled: false,
  16752. shape: 'circle',
  16753. activeColor: '#2979ff',
  16754. inactiveColor: '#c8c9cc',
  16755. name: '',
  16756. size: 18,
  16757. placement: 'row',
  16758. label: '',
  16759. labelColor: '#303133',
  16760. labelSize: 14,
  16761. labelDisabled: false,
  16762. iconColor: '#ffffff',
  16763. iconSize: 12,
  16764. borderBottom: false,
  16765. iconPlacement: 'left'
  16766. }
  16767. };
  16768. exports.default = _default;
  16769. /***/ }),
  16770. /* 125 */
  16771. /*!*************************************************************************************!*\
  16772. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/rate.js ***!
  16773. \*************************************************************************************/
  16774. /*! no static exports found */
  16775. /***/ (function(module, exports, __webpack_require__) {
  16776. "use strict";
  16777. Object.defineProperty(exports, "__esModule", {
  16778. value: true
  16779. });
  16780. exports.default = void 0;
  16781. /*
  16782. * @Author : LQ
  16783. * @Description :
  16784. * @version : 1.0
  16785. * @Date : 2021-08-20 16:44:21
  16786. * @LastAuthor : LQ
  16787. * @lastTime : 2021-08-20 17:05:09
  16788. * @FilePath : /u-view2.0/uview-ui/libs/config/props/rate.js
  16789. */
  16790. var _default = {
  16791. // rate组件
  16792. rate: {
  16793. value: 1,
  16794. count: 5,
  16795. disabled: false,
  16796. size: 18,
  16797. inactiveColor: '#b2b2b2',
  16798. activeColor: '#FA3534',
  16799. gutter: 4,
  16800. minCount: 1,
  16801. allowHalf: false,
  16802. activeIcon: 'star-fill',
  16803. inactiveIcon: 'star',
  16804. touchable: true
  16805. }
  16806. };
  16807. exports.default = _default;
  16808. /***/ }),
  16809. /* 126 */
  16810. /*!*****************************************************************************************!*\
  16811. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/readMore.js ***!
  16812. \*****************************************************************************************/
  16813. /*! no static exports found */
  16814. /***/ (function(module, exports, __webpack_require__) {
  16815. "use strict";
  16816. Object.defineProperty(exports, "__esModule", {
  16817. value: true
  16818. });
  16819. exports.default = void 0;
  16820. /*
  16821. * @Author : LQ
  16822. * @Description :
  16823. * @version : 1.0
  16824. * @Date : 2021-08-20 16:44:21
  16825. * @LastAuthor : LQ
  16826. * @lastTime : 2021-08-20 17:18:41
  16827. * @FilePath : /u-view2.0/uview-ui/libs/config/props/readMore.js
  16828. */
  16829. var _default = {
  16830. // readMore
  16831. readMore: {
  16832. showHeight: 400,
  16833. toggle: false,
  16834. closeText: '展开阅读全文',
  16835. openText: '收起',
  16836. color: '#2979ff',
  16837. fontSize: 14,
  16838. textIndent: '2em',
  16839. name: ''
  16840. }
  16841. };
  16842. exports.default = _default;
  16843. /***/ }),
  16844. /* 127 */
  16845. /*!************************************************************************************!*\
  16846. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/row.js ***!
  16847. \************************************************************************************/
  16848. /*! no static exports found */
  16849. /***/ (function(module, exports, __webpack_require__) {
  16850. "use strict";
  16851. Object.defineProperty(exports, "__esModule", {
  16852. value: true
  16853. });
  16854. exports.default = void 0;
  16855. /*
  16856. * @Author : LQ
  16857. * @Description :
  16858. * @version : 1.0
  16859. * @Date : 2021-08-20 16:44:21
  16860. * @LastAuthor : LQ
  16861. * @lastTime : 2021-08-20 17:18:58
  16862. * @FilePath : /u-view2.0/uview-ui/libs/config/props/row.js
  16863. */
  16864. var _default = {
  16865. // row
  16866. row: {
  16867. gutter: 0,
  16868. justify: 'start',
  16869. align: 'center'
  16870. }
  16871. };
  16872. exports.default = _default;
  16873. /***/ }),
  16874. /* 128 */
  16875. /*!******************************************************************************************!*\
  16876. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/rowNotice.js ***!
  16877. \******************************************************************************************/
  16878. /*! no static exports found */
  16879. /***/ (function(module, exports, __webpack_require__) {
  16880. "use strict";
  16881. Object.defineProperty(exports, "__esModule", {
  16882. value: true
  16883. });
  16884. exports.default = void 0;
  16885. /*
  16886. * @Author : LQ
  16887. * @Description :
  16888. * @version : 1.0
  16889. * @Date : 2021-08-20 16:44:21
  16890. * @LastAuthor : LQ
  16891. * @lastTime : 2021-08-20 17:19:13
  16892. * @FilePath : /u-view2.0/uview-ui/libs/config/props/rowNotice.js
  16893. */
  16894. var _default = {
  16895. // rowNotice
  16896. rowNotice: {
  16897. text: '',
  16898. icon: 'volume',
  16899. mode: '',
  16900. color: '#f9ae3d',
  16901. bgColor: '#fdf6ec',
  16902. fontSize: 14,
  16903. speed: 80
  16904. }
  16905. };
  16906. exports.default = _default;
  16907. /***/ }),
  16908. /* 129 */
  16909. /*!*******************************************************************************************!*\
  16910. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/scrollList.js ***!
  16911. \*******************************************************************************************/
  16912. /*! no static exports found */
  16913. /***/ (function(module, exports, __webpack_require__) {
  16914. "use strict";
  16915. Object.defineProperty(exports, "__esModule", {
  16916. value: true
  16917. });
  16918. exports.default = void 0;
  16919. /*
  16920. * @Author : LQ
  16921. * @Description :
  16922. * @version : 1.0
  16923. * @Date : 2021-08-20 16:44:21
  16924. * @LastAuthor : LQ
  16925. * @lastTime : 2021-08-20 17:19:28
  16926. * @FilePath : /u-view2.0/uview-ui/libs/config/props/scrollList.js
  16927. */
  16928. var _default = {
  16929. // scrollList
  16930. scrollList: {
  16931. indicatorWidth: 50,
  16932. indicatorBarWidth: 20,
  16933. indicator: true,
  16934. indicatorColor: '#f2f2f2',
  16935. indicatorActiveColor: '#3c9cff',
  16936. indicatorStyle: ''
  16937. }
  16938. };
  16939. exports.default = _default;
  16940. /***/ }),
  16941. /* 130 */
  16942. /*!***************************************************************************************!*\
  16943. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/search.js ***!
  16944. \***************************************************************************************/
  16945. /*! no static exports found */
  16946. /***/ (function(module, exports, __webpack_require__) {
  16947. "use strict";
  16948. Object.defineProperty(exports, "__esModule", {
  16949. value: true
  16950. });
  16951. exports.default = void 0;
  16952. /*
  16953. * @Author : LQ
  16954. * @Description :
  16955. * @version : 1.0
  16956. * @Date : 2021-08-20 16:44:21
  16957. * @LastAuthor : LQ
  16958. * @lastTime : 2021-08-20 17:19:45
  16959. * @FilePath : /u-view2.0/uview-ui/libs/config/props/search.js
  16960. */
  16961. var _default = {
  16962. // search
  16963. search: {
  16964. shape: 'round',
  16965. bgColor: '#f2f2f2',
  16966. placeholder: '请输入关键字',
  16967. clearabled: true,
  16968. focus: false,
  16969. showAction: true,
  16970. actionStyle: function actionStyle() {
  16971. return {};
  16972. },
  16973. actionText: '搜索',
  16974. inputAlign: 'left',
  16975. inputStyle: function inputStyle() {
  16976. return {};
  16977. },
  16978. disabled: false,
  16979. borderColor: 'transparent',
  16980. searchIconColor: '#909399',
  16981. searchIconSize: 22,
  16982. color: '#606266',
  16983. placeholderColor: '#909399',
  16984. searchIcon: 'search',
  16985. margin: '0',
  16986. animation: false,
  16987. value: '',
  16988. maxlength: '-1',
  16989. height: 32,
  16990. label: null
  16991. }
  16992. };
  16993. exports.default = _default;
  16994. /***/ }),
  16995. /* 131 */
  16996. /*!****************************************************************************************!*\
  16997. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/section.js ***!
  16998. \****************************************************************************************/
  16999. /*! no static exports found */
  17000. /***/ (function(module, exports, __webpack_require__) {
  17001. "use strict";
  17002. Object.defineProperty(exports, "__esModule", {
  17003. value: true
  17004. });
  17005. exports.default = void 0;
  17006. /*
  17007. * @Author : LQ
  17008. * @Description :
  17009. * @version : 1.0
  17010. * @Date : 2021-08-20 16:44:21
  17011. * @LastAuthor : LQ
  17012. * @lastTime : 2021-08-20 17:07:33
  17013. * @FilePath : /u-view2.0/uview-ui/libs/config/props/section.js
  17014. */
  17015. var _default = {
  17016. // u-section组件
  17017. section: {
  17018. title: '',
  17019. subTitle: '更多',
  17020. right: true,
  17021. fontSize: 15,
  17022. bold: true,
  17023. color: '#303133',
  17024. subColor: '#909399',
  17025. showLine: true,
  17026. lineColor: '',
  17027. arrow: true
  17028. }
  17029. };
  17030. exports.default = _default;
  17031. /***/ }),
  17032. /* 132 */
  17033. /*!*****************************************************************************************!*\
  17034. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/skeleton.js ***!
  17035. \*****************************************************************************************/
  17036. /*! no static exports found */
  17037. /***/ (function(module, exports, __webpack_require__) {
  17038. "use strict";
  17039. Object.defineProperty(exports, "__esModule", {
  17040. value: true
  17041. });
  17042. exports.default = void 0;
  17043. /*
  17044. * @Author : LQ
  17045. * @Description :
  17046. * @version : 1.0
  17047. * @Date : 2021-08-20 16:44:21
  17048. * @LastAuthor : LQ
  17049. * @lastTime : 2021-08-20 17:20:14
  17050. * @FilePath : /u-view2.0/uview-ui/libs/config/props/skeleton.js
  17051. */
  17052. var _default = {
  17053. // skeleton
  17054. skeleton: {
  17055. loading: true,
  17056. animate: true,
  17057. rows: 0,
  17058. rowsWidth: '100%',
  17059. rowsHeight: 18,
  17060. title: true,
  17061. titleWidth: '50%',
  17062. titleHeight: 18,
  17063. avatar: false,
  17064. avatarSize: 32,
  17065. avatarShape: 'circle'
  17066. }
  17067. };
  17068. exports.default = _default;
  17069. /***/ }),
  17070. /* 133 */
  17071. /*!***************************************************************************************!*\
  17072. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/slider.js ***!
  17073. \***************************************************************************************/
  17074. /*! no static exports found */
  17075. /***/ (function(module, exports, __webpack_require__) {
  17076. "use strict";
  17077. Object.defineProperty(exports, "__esModule", {
  17078. value: true
  17079. });
  17080. exports.default = void 0;
  17081. /*
  17082. * @Author : LQ
  17083. * @Description :
  17084. * @version : 1.0
  17085. * @Date : 2021-08-20 16:44:21
  17086. * @LastAuthor : LQ
  17087. * @lastTime : 2021-08-20 17:08:25
  17088. * @FilePath : /u-view2.0/uview-ui/libs/config/props/slider.js
  17089. */
  17090. var _default = {
  17091. // slider组件
  17092. slider: {
  17093. value: 0,
  17094. blockSize: 18,
  17095. min: 0,
  17096. max: 100,
  17097. step: 1,
  17098. activeColor: '#2979ff',
  17099. inactiveColor: '#c0c4cc',
  17100. blockColor: '#ffffff',
  17101. showValue: false,
  17102. disabled: false,
  17103. blockStyle: function blockStyle() {}
  17104. }
  17105. };
  17106. exports.default = _default;
  17107. /***/ }),
  17108. /* 134 */
  17109. /*!******************************************************************************************!*\
  17110. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/statusBar.js ***!
  17111. \******************************************************************************************/
  17112. /*! no static exports found */
  17113. /***/ (function(module, exports, __webpack_require__) {
  17114. "use strict";
  17115. Object.defineProperty(exports, "__esModule", {
  17116. value: true
  17117. });
  17118. exports.default = void 0;
  17119. /*
  17120. * @Author : LQ
  17121. * @Description :
  17122. * @version : 1.0
  17123. * @Date : 2021-08-20 16:44:21
  17124. * @LastAuthor : LQ
  17125. * @lastTime : 2021-08-20 17:20:39
  17126. * @FilePath : /u-view2.0/uview-ui/libs/config/props/statusBar.js
  17127. */
  17128. var _default = {
  17129. // statusBar
  17130. statusBar: {
  17131. bgColor: 'transparent'
  17132. }
  17133. };
  17134. exports.default = _default;
  17135. /***/ }),
  17136. /* 135 */
  17137. /*!**************************************************************************************!*\
  17138. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/steps.js ***!
  17139. \**************************************************************************************/
  17140. /*! no static exports found */
  17141. /***/ (function(module, exports, __webpack_require__) {
  17142. "use strict";
  17143. Object.defineProperty(exports, "__esModule", {
  17144. value: true
  17145. });
  17146. exports.default = void 0;
  17147. /*
  17148. * @Author : LQ
  17149. * @Description :
  17150. * @version : 1.0
  17151. * @Date : 2021-08-20 16:44:21
  17152. * @LastAuthor : LQ
  17153. * @lastTime : 2021-08-20 17:12:37
  17154. * @FilePath : /u-view2.0/uview-ui/libs/config/props/steps.js
  17155. */
  17156. var _default = {
  17157. // steps组件
  17158. steps: {
  17159. direction: 'row',
  17160. current: 0,
  17161. activeColor: '#3c9cff',
  17162. inactiveColor: '#969799',
  17163. activeIcon: '',
  17164. inactiveIcon: '',
  17165. dot: false
  17166. }
  17167. };
  17168. exports.default = _default;
  17169. /***/ }),
  17170. /* 136 */
  17171. /*!******************************************************************************************!*\
  17172. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/stepsItem.js ***!
  17173. \******************************************************************************************/
  17174. /*! no static exports found */
  17175. /***/ (function(module, exports, __webpack_require__) {
  17176. "use strict";
  17177. Object.defineProperty(exports, "__esModule", {
  17178. value: true
  17179. });
  17180. exports.default = void 0;
  17181. /*
  17182. * @Author : LQ
  17183. * @Description :
  17184. * @version : 1.0
  17185. * @Date : 2021-08-20 16:44:21
  17186. * @LastAuthor : LQ
  17187. * @lastTime : 2021-08-20 17:12:55
  17188. * @FilePath : /u-view2.0/uview-ui/libs/config/props/stepsItem.js
  17189. */
  17190. var _default = {
  17191. // steps-item组件
  17192. stepsItem: {
  17193. title: '',
  17194. desc: '',
  17195. iconSize: 17,
  17196. error: false
  17197. }
  17198. };
  17199. exports.default = _default;
  17200. /***/ }),
  17201. /* 137 */
  17202. /*!***************************************************************************************!*\
  17203. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/sticky.js ***!
  17204. \***************************************************************************************/
  17205. /*! no static exports found */
  17206. /***/ (function(module, exports, __webpack_require__) {
  17207. "use strict";
  17208. Object.defineProperty(exports, "__esModule", {
  17209. value: true
  17210. });
  17211. exports.default = void 0;
  17212. /*
  17213. * @Author : LQ
  17214. * @Description :
  17215. * @version : 1.0
  17216. * @Date : 2021-08-20 16:44:21
  17217. * @LastAuthor : LQ
  17218. * @lastTime : 2021-08-20 17:01:30
  17219. * @FilePath : /u-view2.0/uview-ui/libs/config/props/sticky.js
  17220. */
  17221. var _default = {
  17222. // sticky组件
  17223. sticky: {
  17224. offsetTop: 0,
  17225. customNavHeight: 0,
  17226. disabled: false,
  17227. bgColor: 'transparent',
  17228. zIndex: '',
  17229. index: ''
  17230. }
  17231. };
  17232. exports.default = _default;
  17233. /***/ }),
  17234. /* 138 */
  17235. /*!*******************************************************************************************!*\
  17236. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/subsection.js ***!
  17237. \*******************************************************************************************/
  17238. /*! no static exports found */
  17239. /***/ (function(module, exports, __webpack_require__) {
  17240. "use strict";
  17241. Object.defineProperty(exports, "__esModule", {
  17242. value: true
  17243. });
  17244. exports.default = void 0;
  17245. /*
  17246. * @Author : LQ
  17247. * @Description :
  17248. * @version : 1.0
  17249. * @Date : 2021-08-20 16:44:21
  17250. * @LastAuthor : LQ
  17251. * @lastTime : 2021-08-20 17:12:20
  17252. * @FilePath : /u-view2.0/uview-ui/libs/config/props/subsection.js
  17253. */
  17254. var _default = {
  17255. // subsection组件
  17256. subsection: {
  17257. list: [],
  17258. current: 0,
  17259. activeColor: '#3c9cff',
  17260. inactiveColor: '#303133',
  17261. mode: 'button',
  17262. fontSize: 12,
  17263. bold: true,
  17264. bgColor: '#eeeeef',
  17265. keyName: 'name'
  17266. }
  17267. };
  17268. exports.default = _default;
  17269. /***/ }),
  17270. /* 139 */
  17271. /*!********************************************************************************************!*\
  17272. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/swipeAction.js ***!
  17273. \********************************************************************************************/
  17274. /*! no static exports found */
  17275. /***/ (function(module, exports, __webpack_require__) {
  17276. "use strict";
  17277. Object.defineProperty(exports, "__esModule", {
  17278. value: true
  17279. });
  17280. exports.default = void 0;
  17281. /*
  17282. * @Author : LQ
  17283. * @Description :
  17284. * @version : 1.0
  17285. * @Date : 2021-08-20 16:44:21
  17286. * @LastAuthor : LQ
  17287. * @lastTime : 2021-08-20 17:00:42
  17288. * @FilePath : /u-view2.0/uview-ui/libs/config/props/swipeAction.js
  17289. */
  17290. var _default = {
  17291. // swipe-action组件
  17292. swipeAction: {
  17293. autoClose: true
  17294. }
  17295. };
  17296. exports.default = _default;
  17297. /***/ }),
  17298. /* 140 */
  17299. /*!************************************************************************************************!*\
  17300. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/swipeActionItem.js ***!
  17301. \************************************************************************************************/
  17302. /*! no static exports found */
  17303. /***/ (function(module, exports, __webpack_require__) {
  17304. "use strict";
  17305. Object.defineProperty(exports, "__esModule", {
  17306. value: true
  17307. });
  17308. exports.default = void 0;
  17309. /*
  17310. * @Author : LQ
  17311. * @Description :
  17312. * @version : 1.0
  17313. * @Date : 2021-08-20 16:44:21
  17314. * @LastAuthor : LQ
  17315. * @lastTime : 2021-08-20 17:01:13
  17316. * @FilePath : /u-view2.0/uview-ui/libs/config/props/swipeActionItem.js
  17317. */
  17318. var _default = {
  17319. // swipeActionItem 组件
  17320. swipeActionItem: {
  17321. show: false,
  17322. name: '',
  17323. disabled: false,
  17324. threshold: 20,
  17325. autoClose: true,
  17326. options: [],
  17327. duration: 300
  17328. }
  17329. };
  17330. exports.default = _default;
  17331. /***/ }),
  17332. /* 141 */
  17333. /*!***************************************************************************************!*\
  17334. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/swiper.js ***!
  17335. \***************************************************************************************/
  17336. /*! no static exports found */
  17337. /***/ (function(module, exports, __webpack_require__) {
  17338. "use strict";
  17339. Object.defineProperty(exports, "__esModule", {
  17340. value: true
  17341. });
  17342. exports.default = void 0;
  17343. /*
  17344. * @Author : LQ
  17345. * @Description :
  17346. * @version : 1.0
  17347. * @Date : 2021-08-20 16:44:21
  17348. * @LastAuthor : LQ
  17349. * @lastTime : 2021-08-20 17:21:38
  17350. * @FilePath : /u-view2.0/uview-ui/libs/config/props/swiper.js
  17351. */
  17352. var _default = {
  17353. // swiper 组件
  17354. swiper: {
  17355. list: function list() {
  17356. return [];
  17357. },
  17358. indicator: false,
  17359. indicatorActiveColor: '#FFFFFF',
  17360. indicatorInactiveColor: 'rgba(255, 255, 255, 0.35)',
  17361. indicatorStyle: '',
  17362. indicatorMode: 'line',
  17363. autoplay: true,
  17364. current: 0,
  17365. currentItemId: '',
  17366. interval: 3000,
  17367. duration: 300,
  17368. circular: false,
  17369. previousMargin: 0,
  17370. nextMargin: 0,
  17371. acceleration: false,
  17372. displayMultipleItems: 1,
  17373. easingFunction: 'default',
  17374. keyName: 'url',
  17375. imgMode: 'aspectFill',
  17376. height: 130,
  17377. bgColor: '#f3f4f6',
  17378. radius: 4,
  17379. loading: false,
  17380. showTitle: false
  17381. }
  17382. };
  17383. exports.default = _default;
  17384. /***/ }),
  17385. /* 142 */
  17386. /*!*************************************************************************************************!*\
  17387. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/swipterIndicator.js ***!
  17388. \*************************************************************************************************/
  17389. /*! no static exports found */
  17390. /***/ (function(module, exports, __webpack_require__) {
  17391. "use strict";
  17392. Object.defineProperty(exports, "__esModule", {
  17393. value: true
  17394. });
  17395. exports.default = void 0;
  17396. /*
  17397. * @Author : LQ
  17398. * @Description :
  17399. * @version : 1.0
  17400. * @Date : 2021-08-20 16:44:21
  17401. * @LastAuthor : LQ
  17402. * @lastTime : 2021-08-20 17:22:07
  17403. * @FilePath : /u-view2.0/uview-ui/libs/config/props/swiperIndicator.js
  17404. */
  17405. var _default = {
  17406. // swiperIndicator 组件
  17407. swiperIndicator: {
  17408. length: 0,
  17409. current: 0,
  17410. indicatorActiveColor: '',
  17411. indicatorInactiveColor: '',
  17412. indicatorMode: 'line'
  17413. }
  17414. };
  17415. exports.default = _default;
  17416. /***/ }),
  17417. /* 143 */
  17418. /*!***************************************************************************************!*\
  17419. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/switch.js ***!
  17420. \***************************************************************************************/
  17421. /*! no static exports found */
  17422. /***/ (function(module, exports, __webpack_require__) {
  17423. "use strict";
  17424. Object.defineProperty(exports, "__esModule", {
  17425. value: true
  17426. });
  17427. exports.default = void 0;
  17428. /*
  17429. * @Author : LQ
  17430. * @Description :
  17431. * @version : 1.0
  17432. * @Date : 2021-08-20 16:44:21
  17433. * @LastAuthor : LQ
  17434. * @lastTime : 2021-08-20 17:22:24
  17435. * @FilePath : /u-view2.0/uview-ui/libs/config/props/switch.js
  17436. */
  17437. var _default = {
  17438. // switch
  17439. switch: {
  17440. loading: false,
  17441. disabled: false,
  17442. size: 25,
  17443. activeColor: '#2979ff',
  17444. inactiveColor: '#ffffff',
  17445. value: false,
  17446. activeValue: true,
  17447. inactiveValue: false,
  17448. asyncChange: false,
  17449. space: 0
  17450. }
  17451. };
  17452. exports.default = _default;
  17453. /***/ }),
  17454. /* 144 */
  17455. /*!***************************************************************************************!*\
  17456. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/tabbar.js ***!
  17457. \***************************************************************************************/
  17458. /*! no static exports found */
  17459. /***/ (function(module, exports, __webpack_require__) {
  17460. "use strict";
  17461. Object.defineProperty(exports, "__esModule", {
  17462. value: true
  17463. });
  17464. exports.default = void 0;
  17465. /*
  17466. * @Author : LQ
  17467. * @Description :
  17468. * @version : 1.0
  17469. * @Date : 2021-08-20 16:44:21
  17470. * @LastAuthor : LQ
  17471. * @lastTime : 2021-08-20 17:22:40
  17472. * @FilePath : /u-view2.0/uview-ui/libs/config/props/tabbar.js
  17473. */
  17474. var _default = {
  17475. // tabbar
  17476. tabbar: {
  17477. value: null,
  17478. safeAreaInsetBottom: true,
  17479. border: true,
  17480. zIndex: 1,
  17481. activeColor: '#1989fa',
  17482. inactiveColor: '#7d7e80',
  17483. fixed: true,
  17484. placeholder: true
  17485. }
  17486. };
  17487. exports.default = _default;
  17488. /***/ }),
  17489. /* 145 */
  17490. /*!*******************************************************************************************!*\
  17491. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/tabbarItem.js ***!
  17492. \*******************************************************************************************/
  17493. /*! no static exports found */
  17494. /***/ (function(module, exports, __webpack_require__) {
  17495. "use strict";
  17496. Object.defineProperty(exports, "__esModule", {
  17497. value: true
  17498. });
  17499. exports.default = void 0;
  17500. /*
  17501. * @Author : LQ
  17502. * @Description :
  17503. * @version : 1.0
  17504. * @Date : 2021-08-20 16:44:21
  17505. * @LastAuthor : LQ
  17506. * @lastTime : 2021-08-20 17:22:55
  17507. * @FilePath : /u-view2.0/uview-ui/libs/config/props/tabbarItem.js
  17508. */
  17509. var _default = {
  17510. //
  17511. tabbarItem: {
  17512. name: null,
  17513. icon: '',
  17514. badge: null,
  17515. dot: false,
  17516. text: '',
  17517. badgeStyle: 'top: 6px;right:2px;'
  17518. }
  17519. };
  17520. exports.default = _default;
  17521. /***/ }),
  17522. /* 146 */
  17523. /*!*************************************************************************************!*\
  17524. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/tabs.js ***!
  17525. \*************************************************************************************/
  17526. /*! no static exports found */
  17527. /***/ (function(module, exports, __webpack_require__) {
  17528. "use strict";
  17529. Object.defineProperty(exports, "__esModule", {
  17530. value: true
  17531. });
  17532. exports.default = void 0;
  17533. /*
  17534. * @Author : LQ
  17535. * @Description :
  17536. * @version : 1.0
  17537. * @Date : 2021-08-20 16:44:21
  17538. * @LastAuthor : LQ
  17539. * @lastTime : 2021-08-20 17:23:14
  17540. * @FilePath : /u-view2.0/uview-ui/libs/config/props/tabs.js
  17541. */
  17542. var _default = {
  17543. //
  17544. tabs: {
  17545. duration: 300,
  17546. list: function list() {
  17547. return [];
  17548. },
  17549. lineColor: '#3c9cff',
  17550. activeStyle: function activeStyle() {
  17551. return {
  17552. color: '#303133'
  17553. };
  17554. },
  17555. inactiveStyle: function inactiveStyle() {
  17556. return {
  17557. color: '#606266'
  17558. };
  17559. },
  17560. lineWidth: 20,
  17561. lineHeight: 3,
  17562. lineBgSize: 'cover',
  17563. itemStyle: function itemStyle() {
  17564. return {
  17565. height: '44px'
  17566. };
  17567. },
  17568. scrollable: true,
  17569. current: 0,
  17570. keyName: 'name'
  17571. }
  17572. };
  17573. exports.default = _default;
  17574. /***/ }),
  17575. /* 147 */
  17576. /*!************************************************************************************!*\
  17577. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/tag.js ***!
  17578. \************************************************************************************/
  17579. /*! no static exports found */
  17580. /***/ (function(module, exports, __webpack_require__) {
  17581. "use strict";
  17582. Object.defineProperty(exports, "__esModule", {
  17583. value: true
  17584. });
  17585. exports.default = void 0;
  17586. /*
  17587. * @Author : LQ
  17588. * @Description :
  17589. * @version : 1.0
  17590. * @Date : 2021-08-20 16:44:21
  17591. * @LastAuthor : LQ
  17592. * @lastTime : 2021-08-20 17:23:37
  17593. * @FilePath : /u-view2.0/uview-ui/libs/config/props/tag.js
  17594. */
  17595. var _default = {
  17596. // tag 组件
  17597. tag: {
  17598. type: 'primary',
  17599. disabled: false,
  17600. size: 'medium',
  17601. shape: 'square',
  17602. text: '',
  17603. bgColor: '',
  17604. color: '',
  17605. borderColor: '',
  17606. closeColor: '#C6C7CB',
  17607. name: '',
  17608. plainFill: false,
  17609. plain: false,
  17610. closable: false,
  17611. show: true,
  17612. icon: ''
  17613. }
  17614. };
  17615. exports.default = _default;
  17616. /***/ }),
  17617. /* 148 */
  17618. /*!*************************************************************************************!*\
  17619. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/text.js ***!
  17620. \*************************************************************************************/
  17621. /*! no static exports found */
  17622. /***/ (function(module, exports, __webpack_require__) {
  17623. "use strict";
  17624. Object.defineProperty(exports, "__esModule", {
  17625. value: true
  17626. });
  17627. exports.default = void 0;
  17628. /*
  17629. * @Author : LQ
  17630. * @Description :
  17631. * @version : 1.0
  17632. * @Date : 2021-08-20 16:44:21
  17633. * @LastAuthor : LQ
  17634. * @lastTime : 2021-08-20 17:23:58
  17635. * @FilePath : /u-view2.0/uview-ui/libs/config/props/text.js
  17636. */
  17637. var _default = {
  17638. // text 组件
  17639. text: {
  17640. type: '',
  17641. show: true,
  17642. text: '',
  17643. prefixIcon: '',
  17644. suffixIcon: '',
  17645. mode: '',
  17646. href: '',
  17647. format: '',
  17648. call: false,
  17649. openType: '',
  17650. bold: false,
  17651. block: false,
  17652. lines: '',
  17653. color: '#303133',
  17654. size: 15,
  17655. iconStyle: function iconStyle() {
  17656. return {
  17657. fontSize: '15px'
  17658. };
  17659. },
  17660. decoration: 'none',
  17661. margin: 0,
  17662. lineHeight: '',
  17663. align: 'left',
  17664. wordWrap: 'normal'
  17665. }
  17666. };
  17667. exports.default = _default;
  17668. /***/ }),
  17669. /* 149 */
  17670. /*!*****************************************************************************************!*\
  17671. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/textarea.js ***!
  17672. \*****************************************************************************************/
  17673. /*! no static exports found */
  17674. /***/ (function(module, exports, __webpack_require__) {
  17675. "use strict";
  17676. Object.defineProperty(exports, "__esModule", {
  17677. value: true
  17678. });
  17679. exports.default = void 0;
  17680. /*
  17681. * @Author : LQ
  17682. * @Description :
  17683. * @version : 1.0
  17684. * @Date : 2021-08-20 16:44:21
  17685. * @LastAuthor : LQ
  17686. * @lastTime : 2021-08-20 17:24:32
  17687. * @FilePath : /u-view2.0/uview-ui/libs/config/props/textarea.js
  17688. */
  17689. var _default = {
  17690. // textarea 组件
  17691. textarea: {
  17692. value: '',
  17693. placeholder: '',
  17694. placeholderClass: 'textarea-placeholder',
  17695. placeholderStyle: 'color: #c0c4cc',
  17696. height: 70,
  17697. confirmType: 'done',
  17698. disabled: false,
  17699. count: false,
  17700. focus: false,
  17701. autoHeight: false,
  17702. fixed: false,
  17703. cursorSpacing: 0,
  17704. cursor: '',
  17705. showConfirmBar: true,
  17706. selectionStart: -1,
  17707. selectionEnd: -1,
  17708. adjustPosition: true,
  17709. disableDefaultPadding: false,
  17710. holdKeyboard: false,
  17711. maxlength: 140,
  17712. border: 'surround',
  17713. formatter: null
  17714. }
  17715. };
  17716. exports.default = _default;
  17717. /***/ }),
  17718. /* 150 */
  17719. /*!**************************************************************************************!*\
  17720. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/toast.js ***!
  17721. \**************************************************************************************/
  17722. /*! no static exports found */
  17723. /***/ (function(module, exports, __webpack_require__) {
  17724. "use strict";
  17725. Object.defineProperty(exports, "__esModule", {
  17726. value: true
  17727. });
  17728. exports.default = void 0;
  17729. /*
  17730. * @Author : LQ
  17731. * @Description :
  17732. * @version : 1.0
  17733. * @Date : 2021-08-20 16:44:21
  17734. * @LastAuthor : LQ
  17735. * @lastTime : 2021-08-20 17:07:07
  17736. * @FilePath : /u-view2.0/uview-ui/libs/config/props/toast.js
  17737. */
  17738. var _default = {
  17739. // toast组件
  17740. toast: {
  17741. zIndex: 10090,
  17742. loading: false,
  17743. text: '',
  17744. icon: '',
  17745. type: '',
  17746. loadingMode: '',
  17747. show: '',
  17748. overlay: false,
  17749. position: 'center',
  17750. params: function params() {},
  17751. duration: 2000,
  17752. isTab: false,
  17753. url: '',
  17754. callback: null,
  17755. back: false
  17756. }
  17757. };
  17758. exports.default = _default;
  17759. /***/ }),
  17760. /* 151 */
  17761. /*!****************************************************************************************!*\
  17762. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/toolbar.js ***!
  17763. \****************************************************************************************/
  17764. /*! no static exports found */
  17765. /***/ (function(module, exports, __webpack_require__) {
  17766. "use strict";
  17767. Object.defineProperty(exports, "__esModule", {
  17768. value: true
  17769. });
  17770. exports.default = void 0;
  17771. /*
  17772. * @Author : LQ
  17773. * @Description :
  17774. * @version : 1.0
  17775. * @Date : 2021-08-20 16:44:21
  17776. * @LastAuthor : LQ
  17777. * @lastTime : 2021-08-20 17:24:55
  17778. * @FilePath : /u-view2.0/uview-ui/libs/config/props/toolbar.js
  17779. */
  17780. var _default = {
  17781. // toolbar 组件
  17782. toolbar: {
  17783. show: true,
  17784. cancelText: '取消',
  17785. confirmText: '确认',
  17786. cancelColor: '#909193',
  17787. confirmColor: '#3c9cff',
  17788. title: ''
  17789. }
  17790. };
  17791. exports.default = _default;
  17792. /***/ }),
  17793. /* 152 */
  17794. /*!****************************************************************************************!*\
  17795. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/tooltip.js ***!
  17796. \****************************************************************************************/
  17797. /*! no static exports found */
  17798. /***/ (function(module, exports, __webpack_require__) {
  17799. "use strict";
  17800. Object.defineProperty(exports, "__esModule", {
  17801. value: true
  17802. });
  17803. exports.default = void 0;
  17804. /*
  17805. * @Author : LQ
  17806. * @Description :
  17807. * @version : 1.0
  17808. * @Date : 2021-08-20 16:44:21
  17809. * @LastAuthor : LQ
  17810. * @lastTime : 2021-08-20 17:25:14
  17811. * @FilePath : /u-view2.0/uview-ui/libs/config/props/tooltip.js
  17812. */
  17813. var _default = {
  17814. // tooltip 组件
  17815. tooltip: {
  17816. text: '',
  17817. copyText: '',
  17818. size: 14,
  17819. color: '#606266',
  17820. bgColor: 'transparent',
  17821. direction: 'top',
  17822. zIndex: 10071,
  17823. showCopy: true,
  17824. buttons: function buttons() {
  17825. return [];
  17826. },
  17827. overlay: true,
  17828. showToast: true
  17829. }
  17830. };
  17831. exports.default = _default;
  17832. /***/ }),
  17833. /* 153 */
  17834. /*!*******************************************************************************************!*\
  17835. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/transition.js ***!
  17836. \*******************************************************************************************/
  17837. /*! no static exports found */
  17838. /***/ (function(module, exports, __webpack_require__) {
  17839. "use strict";
  17840. Object.defineProperty(exports, "__esModule", {
  17841. value: true
  17842. });
  17843. exports.default = void 0;
  17844. /*
  17845. * @Author : LQ
  17846. * @Description :
  17847. * @version : 1.0
  17848. * @Date : 2021-08-20 16:44:21
  17849. * @LastAuthor : LQ
  17850. * @lastTime : 2021-08-20 16:59:00
  17851. * @FilePath : /u-view2.0/uview-ui/libs/config/props/transition.js
  17852. */
  17853. var _default = {
  17854. // transition动画组件的props
  17855. transition: {
  17856. show: false,
  17857. mode: 'fade',
  17858. duration: '300',
  17859. timingFunction: 'ease-out'
  17860. }
  17861. };
  17862. exports.default = _default;
  17863. /***/ }),
  17864. /* 154 */
  17865. /*!***************************************************************************************!*\
  17866. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/props/upload.js ***!
  17867. \***************************************************************************************/
  17868. /*! no static exports found */
  17869. /***/ (function(module, exports, __webpack_require__) {
  17870. "use strict";
  17871. Object.defineProperty(exports, "__esModule", {
  17872. value: true
  17873. });
  17874. exports.default = void 0;
  17875. /*
  17876. * @Author : LQ
  17877. * @Description :
  17878. * @version : 1.0
  17879. * @Date : 2021-08-20 16:44:21
  17880. * @LastAuthor : LQ
  17881. * @lastTime : 2021-08-20 17:09:50
  17882. * @FilePath : /u-view2.0/uview-ui/libs/config/props/upload.js
  17883. */
  17884. var _default = {
  17885. // upload组件
  17886. upload: {
  17887. accept: 'image',
  17888. capture: function capture() {
  17889. return ['album', 'camera'];
  17890. },
  17891. compressed: true,
  17892. camera: 'back',
  17893. maxDuration: 60,
  17894. uploadIcon: 'camera-fill',
  17895. uploadIconColor: '#D3D4D6',
  17896. useBeforeRead: false,
  17897. previewFullImage: true,
  17898. maxCount: 52,
  17899. disabled: false,
  17900. imageMode: 'aspectFill',
  17901. name: '',
  17902. sizeType: function sizeType() {
  17903. return ['original', 'compressed'];
  17904. },
  17905. multiple: false,
  17906. deletable: true,
  17907. maxSize: Number.MAX_VALUE,
  17908. fileList: function fileList() {
  17909. return [];
  17910. },
  17911. uploadText: '',
  17912. width: 80,
  17913. height: 80,
  17914. previewImage: true
  17915. }
  17916. };
  17917. exports.default = _default;
  17918. /***/ }),
  17919. /* 155 */
  17920. /*!*********************************************************************************!*\
  17921. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/config/zIndex.js ***!
  17922. \*********************************************************************************/
  17923. /*! no static exports found */
  17924. /***/ (function(module, exports, __webpack_require__) {
  17925. "use strict";
  17926. Object.defineProperty(exports, "__esModule", {
  17927. value: true
  17928. });
  17929. exports.default = void 0;
  17930. // uniapp在H5中各API的z-index值如下:
  17931. /**
  17932. * actionsheet: 999
  17933. * modal: 999
  17934. * navigate: 998
  17935. * tabbar: 998
  17936. * toast: 999
  17937. */
  17938. var _default = {
  17939. toast: 10090,
  17940. noNetwork: 10080,
  17941. // popup包含popup,actionsheet,keyboard,picker的值
  17942. popup: 10075,
  17943. mask: 10070,
  17944. navbar: 980,
  17945. topTips: 975,
  17946. sticky: 970,
  17947. indexListSticky: 965
  17948. };
  17949. exports.default = _default;
  17950. /***/ }),
  17951. /* 156 */
  17952. /*!*************************************************************************************!*\
  17953. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/libs/function/platform.js ***!
  17954. \*************************************************************************************/
  17955. /*! no static exports found */
  17956. /***/ (function(module, exports, __webpack_require__) {
  17957. "use strict";
  17958. Object.defineProperty(exports, "__esModule", {
  17959. value: true
  17960. });
  17961. exports.default = void 0;
  17962. /**
  17963. * 注意:
  17964. * 此部分内容,在vue-cli模式下,需要在vue.config.js加入如下内容才有效:
  17965. * module.exports = {
  17966. * transpileDependencies: ['uview-v2']
  17967. * }
  17968. */
  17969. var platform = 'none';
  17970. platform = 'vue2';
  17971. platform = 'toutiao';
  17972. platform = 'mp';
  17973. var _default = platform;
  17974. exports.default = _default;
  17975. /***/ }),
  17976. /* 157 */
  17977. /*!**********************************************************!*\
  17978. !*** /Users/z/D/hx-mini/hx-mini-uni/static/js/common.js ***!
  17979. \**********************************************************/
  17980. /*! no static exports found */
  17981. /***/ (function(module, exports, __webpack_require__) {
  17982. "use strict";
  17983. /* WEBPACK VAR INJECTION */(function(uni) {
  17984. Object.defineProperty(exports, "__esModule", {
  17985. value: true
  17986. });
  17987. exports.default = void 0;
  17988. var _default = {
  17989. shopName: function shopName() {
  17990. return "";
  17991. },
  17992. clearUri: function clearUri(url) {
  17993. var userInfo = uni.getStorageSync("user_data");
  17994. if (!userInfo) {
  17995. uni.showLoading({
  17996. title: "加载中..."
  17997. });
  17998. setTimeout(function () {
  17999. uni.hideLoading();
  18000. uni.$u.route({
  18001. url: '/pages/user/user',
  18002. type: "switchTab",
  18003. animationType: "slide-in-bottom"
  18004. });
  18005. }, 800);
  18006. return;
  18007. }
  18008. uni.$u.route({
  18009. url: url,
  18010. animationType: "slide-in-bottom",
  18011. animationDuration: 300
  18012. });
  18013. },
  18014. jumpUri: function jumpUri(url, type, param) {
  18015. var userInfo = uni.getStorageSync("user_data");
  18016. var cacheShop = this.shopId();
  18017. if (!userInfo) {
  18018. setTimeout(function () {
  18019. uni.hideLoading();
  18020. uni.$u.route({
  18021. url: '/pages/user/login?store=' + cacheShop,
  18022. type: "navigateTo",
  18023. animationType: "slide-in-bottom"
  18024. });
  18025. }, 800);
  18026. return;
  18027. }
  18028. if (type == 1 && !userInfo) {
  18029. uni.showToast({
  18030. title: "请先登录",
  18031. icon: "none"
  18032. });
  18033. return true;
  18034. }
  18035. uni.$u.route(url, param);
  18036. },
  18037. //判断是否登录
  18038. navTo: function navTo(url, param) {
  18039. uni.$u.route(url, param);
  18040. },
  18041. //判断是否登录
  18042. isLogin: function isLogin() {
  18043. return uni.getStorageSync("user") ? true : false;
  18044. },
  18045. /**
  18046. * 操作成功提示框
  18047. * @param {*} msg
  18048. * @param {*} callback
  18049. * @param {*} icon
  18050. */
  18051. showSuccess: function showSuccess(msg, icon, callback) {
  18052. uni.showToast({
  18053. title: msg,
  18054. icon: icon ? icon : 'none',
  18055. mask: true,
  18056. duration: 1500,
  18057. success: function success() {
  18058. callback && setTimeout(function () {
  18059. callback();
  18060. }, 1500);
  18061. }
  18062. });
  18063. },
  18064. /**
  18065. * 操作错误提示
  18066. * @param {*} msg
  18067. * @param {*} showCancel
  18068. * @param {*} callback
  18069. * @param {*} title
  18070. */
  18071. showError: function showError(msg, callback) {
  18072. var title = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : "友情提示";
  18073. var showCancel = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : true;
  18074. uni.showModal({
  18075. title: title,
  18076. content: msg,
  18077. showCancel: showCancel,
  18078. success: function success(res) {
  18079. callback && callback(res);
  18080. }
  18081. });
  18082. },
  18083. showConfirm: function showConfirm(msg, callback, title, yes, cancel) {
  18084. plus.nativeUI.confirm(msg, function (e) {
  18085. callback && callback(e);
  18086. }, {
  18087. "title": title,
  18088. "buttons": [yes ? yes : "确定", cancel ? cancel : "取消"]
  18089. });
  18090. },
  18091. showSysAlert: function showSysAlert(msg, callback, title, showCancel) {
  18092. plus.nativeUI.alert(msg, callback, title, showCancel);
  18093. },
  18094. showSysMsg: function showSysMsg(msg) {
  18095. plus.nativeUI.toast(msg);
  18096. },
  18097. /**
  18098. * loading
  18099. * @param {Object} msg
  18100. * @param {Object} callback
  18101. */
  18102. loading: function loading(msg, callback) {
  18103. uni.showLoading({
  18104. title: msg !== null && msg !== void 0 ? msg : '请求中...',
  18105. mask: true,
  18106. success: function success(res) {
  18107. callback && callback(res);
  18108. }
  18109. });
  18110. },
  18111. hideLoad: function hideLoad() {
  18112. uni.hideLoading();
  18113. },
  18114. formatDate: function formatDate(value) {
  18115. var data = new Date(value);
  18116. var month = data.getMonth() + 1;
  18117. var day = data.getDate();
  18118. var year = data.getFullYear();
  18119. var hours = data.getHours();
  18120. var minutes = data.getMinutes();
  18121. var seconds = data.getSeconds();
  18122. var formattedTime = "".concat(year, "-").concat(month, "-").concat(day);
  18123. // const formattedTime = `${year}-${month}-${day} ${hours}:${minutes}:${seconds}`;
  18124. return formattedTime;
  18125. },
  18126. formatMoney: function formatMoney(num) {
  18127. if (num == 0) return "¥0.00";
  18128. return Intl.NumberFormat("zh-CN", {
  18129. style: "currency",
  18130. currency: "CNY",
  18131. minimumFractionDigits: 2,
  18132. maximumFractionDigits: 2
  18133. }).format(num / 100);
  18134. }
  18135. };
  18136. exports.default = _default;
  18137. /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./node_modules/@dcloudio/uni-mp-toutiao/dist/index.js */ 1)["default"]))
  18138. /***/ }),
  18139. /* 158 */
  18140. /*!***************************************************************!*\
  18141. !*** /Users/z/D/hx-mini/hx-mini-uni/uni.promisify.adaptor.js ***!
  18142. \***************************************************************/
  18143. /*! no static exports found */
  18144. /***/ (function(module, exports, __webpack_require__) {
  18145. /* WEBPACK VAR INJECTION */(function(uni) {var _typeof = __webpack_require__(/*! @babel/runtime/helpers/typeof */ 12);
  18146. uni.addInterceptor({
  18147. returnValue: function returnValue(res) {
  18148. if (!(!!res && (_typeof(res) === "object" || typeof res === "function") && typeof res.then === "function")) {
  18149. return res;
  18150. }
  18151. return new Promise(function (resolve, reject) {
  18152. res.then(function (res) {
  18153. if (!res) return resolve(res);
  18154. return res[0] ? reject(res[0]) : resolve(res[1]);
  18155. });
  18156. });
  18157. }
  18158. });
  18159. /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./node_modules/@dcloudio/uni-mp-toutiao/dist/index.js */ 1)["default"]))
  18160. /***/ }),
  18161. /* 159 */,
  18162. /* 160 */,
  18163. /* 161 */,
  18164. /* 162 */,
  18165. /* 163 */,
  18166. /* 164 */,
  18167. /* 165 */
  18168. /*!*********************************************************!*\
  18169. !*** /Users/z/D/hx-mini/hx-mini-uni/static/api/home.js ***!
  18170. \*********************************************************/
  18171. /*! no static exports found */
  18172. /***/ (function(module, exports, __webpack_require__) {
  18173. "use strict";
  18174. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  18175. Object.defineProperty(exports, "__esModule", {
  18176. value: true
  18177. });
  18178. exports.data = data;
  18179. exports.detail = detail;
  18180. exports.license = license;
  18181. exports.orderDetail = orderDetail;
  18182. var _request = _interopRequireDefault(__webpack_require__(/*! @/static/js/request.js */ 166));
  18183. var apiUri = {
  18184. data: '/home/login',
  18185. detail: '/order/life',
  18186. orderDetail: '/order/life/detail',
  18187. license: '/home/license'
  18188. };
  18189. function orderDetail(param) {
  18190. return _request.default.request(apiUri.orderDetail, 'GET', param, false, true, false);
  18191. }
  18192. function data(param) {
  18193. return _request.default.request(apiUri.data, 'POST', param, false, true, false);
  18194. }
  18195. function detail(param) {
  18196. return _request.default.request(apiUri.detail, 'POST', param, false, true, false);
  18197. }
  18198. function license(param) {
  18199. return _request.default.request(apiUri.license, 'POST', param, false, true, false);
  18200. }
  18201. /***/ }),
  18202. /* 166 */
  18203. /*!***********************************************************!*\
  18204. !*** /Users/z/D/hx-mini/hx-mini-uni/static/js/request.js ***!
  18205. \***********************************************************/
  18206. /*! no static exports found */
  18207. /***/ (function(module, exports, __webpack_require__) {
  18208. "use strict";
  18209. /* WEBPACK VAR INJECTION */(function(uni) {
  18210. Object.defineProperty(exports, "__esModule", {
  18211. value: true
  18212. });
  18213. exports.default = void 0;
  18214. /**
  18215. * 常用方法封装 请求,文件上传等
  18216. * @author echo.
  18217. **/
  18218. var axg = {
  18219. shopId: function shopId() {
  18220. return "10108618787549";
  18221. },
  18222. //接口地址
  18223. interfaceUrl: function interfaceUrl() {
  18224. return 'https://miniapi.jsshuita.com.cn/api/dy';
  18225. // return 'http://127.0.0.1:8190/api/dy'
  18226. },
  18227. toast: function toast(text, duration, success) {},
  18228. modal: function modal(title, content, showCancel, callback, confirmColor, confirmText) {
  18229. uni.showModal({
  18230. title: title || '提示',
  18231. content: content,
  18232. showCancel: showCancel,
  18233. cancelColor: "#555",
  18234. confirmColor: confirmColor || "#5677fc",
  18235. confirmText: confirmText || "确定",
  18236. success: function success(res) {
  18237. if (res.confirm) {
  18238. callback && callback(true);
  18239. } else {
  18240. callback && callback(false);
  18241. }
  18242. }
  18243. });
  18244. },
  18245. isAndroid: function isAndroid() {
  18246. var res = uni.getSystemInfoSync();
  18247. if (res.platform.toLocaleLowerCase() == 'android') {
  18248. return true;
  18249. }
  18250. return false;
  18251. },
  18252. isPhoneX: function isPhoneX() {
  18253. var res = uni.getSystemInfoSync();
  18254. var iphonex = false;
  18255. var models = ['iphonex', 'iphonexr', 'iphonexsmax', 'iphone11', 'iphone11pro', 'iphone11promax'];
  18256. var model = res.model.replace(/\s/g, "").toLowerCase();
  18257. if (models.includes(model)) {
  18258. iphonex = true;
  18259. }
  18260. return iphonex;
  18261. },
  18262. constNum: function constNum() {
  18263. var time = 0;
  18264. return time;
  18265. },
  18266. delayed: null,
  18267. /**
  18268. * 请求数据处理
  18269. * @param string url 请求地址
  18270. * @param string method 请求方式
  18271. * GET or POST
  18272. * @param {*} postData 请求参数
  18273. * @param bool isDelay 是否延迟显示loading
  18274. * @param bool isForm 数据格式
  18275. * true: 'application/x-www-form-urlencoded'
  18276. * false:'application/json'
  18277. * @param bool hideLoading 是否隐藏loading
  18278. * true: 隐藏
  18279. * false:显示
  18280. */
  18281. request: function request(url, method, postData, isDelay, isForm, hideLoading) {
  18282. //接口请求
  18283. var loadding = false;
  18284. axg.delayed && uni.hideLoading();
  18285. clearTimeout(axg.delayed);
  18286. axg.delayed = null;
  18287. if (!hideLoading) {
  18288. axg.delayed = setTimeout(function () {
  18289. uni.showLoading({
  18290. mask: true,
  18291. title: '请求中...',
  18292. success: function success(res) {
  18293. loadding = true;
  18294. }
  18295. });
  18296. }, isDelay ? 1000 : 0);
  18297. }
  18298. var header = {
  18299. 'Content-Type': isForm ? 'application/x-www-form-urlencoded' : 'application/json',
  18300. 'authorization': "Bearer " + axg.getToken(),
  18301. 'platform': "mini"
  18302. };
  18303. // postData.shop = axg.shopId();
  18304. axg.toast(axg.interfaceUrl() + url);
  18305. return new Promise(function (resolve, reject) {
  18306. uni.request({
  18307. url: axg.interfaceUrl() + url,
  18308. data: postData,
  18309. header: header,
  18310. method: method,
  18311. //'GET','POST'
  18312. dataType: 'json',
  18313. success: function success(res) {
  18314. clearTimeout(axg.delayed);
  18315. axg.delayed = null;
  18316. uni.hideLoading();
  18317. if (loadding && !hideLoading) {
  18318. uni.hideLoading();
  18319. }
  18320. // if (res.data && res.data.code == 401) {
  18321. // uni.showToast({
  18322. // title: res.data.msg,
  18323. // icon: 'none',
  18324. // mask: true,
  18325. // duration: 1500,
  18326. // success() {
  18327. // // uni.navigateTo({
  18328. // // url:"/pages/user/login"
  18329. // // });
  18330. // uni.clearStorageSync();
  18331. // }
  18332. // });
  18333. // return ;
  18334. // }
  18335. resolve(res.data);
  18336. },
  18337. fail: function fail(res) {
  18338. clearTimeout(axg.delayed);
  18339. axg.delayed = null;
  18340. axg.toast("网络不给力,请稍后再试~");
  18341. reject(res);
  18342. }
  18343. });
  18344. });
  18345. },
  18346. /**
  18347. * 上传文件
  18348. * @param string url 请求地址
  18349. * @param string src 文件路径
  18350. */
  18351. uploadFile: function uploadFile(url, src, param) {
  18352. return new Promise(function (resolve, reject) {
  18353. var uploadTask = uni.uploadFile({
  18354. url: axg.interfaceUrl() + url,
  18355. filePath: src,
  18356. name: 'file',
  18357. header: {
  18358. 'authorization': "Bearer " + axg.getToken(),
  18359. 'platform': "mini"
  18360. },
  18361. formData: param,
  18362. success: function success(res) {
  18363. uni.hideLoading();
  18364. var d = JSON.parse(res.data.replace(/\ufeff/g, "") || "{}");
  18365. if (d.code == 200) {
  18366. //返回图片地址
  18367. var fileObj = d.data;
  18368. resolve(fileObj);
  18369. } else {
  18370. axg.toast(res.msg);
  18371. }
  18372. },
  18373. fail: function fail(res) {
  18374. console.log('上传错误:', res);
  18375. reject(res);
  18376. axg.toast(res.msg);
  18377. }
  18378. });
  18379. });
  18380. },
  18381. tuiJsonp: function tuiJsonp(url, callback, callbackname) {},
  18382. //设置用户信息
  18383. setUserInfo: function setUserInfo(mobile, token) {
  18384. //uni.setStorageSync("thorui_token", token)
  18385. uni.setStorageSync("user_token", mobile);
  18386. },
  18387. //获取token
  18388. getToken: function getToken() {
  18389. return uni.getStorageSync("user_token") || 'None';
  18390. },
  18391. //判断是否登录
  18392. isLogin: function isLogin() {
  18393. return uni.getStorageSync("user_token") ? true : false;
  18394. },
  18395. //跳转页面,校验登录状态
  18396. href: function href(url, isVerify) {
  18397. if (isVerify && !axg.isLogin()) {
  18398. uni.navigateTo({
  18399. url: '/pages/user/login/login'
  18400. });
  18401. } else {
  18402. uni.navigateTo({
  18403. url: url
  18404. });
  18405. }
  18406. }
  18407. };
  18408. var _default = axg;
  18409. exports.default = _default;
  18410. /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./node_modules/@dcloudio/uni-mp-toutiao/dist/index.js */ 1)["default"]))
  18411. /***/ }),
  18412. /* 167 */,
  18413. /* 168 */,
  18414. /* 169 */,
  18415. /* 170 */,
  18416. /* 171 */,
  18417. /* 172 */,
  18418. /* 173 */,
  18419. /* 174 */,
  18420. /* 175 */
  18421. /*!**********************************************************!*\
  18422. !*** /Users/z/D/hx-mini/hx-mini-uni/static/api/order.js ***!
  18423. \**********************************************************/
  18424. /*! no static exports found */
  18425. /***/ (function(module, exports, __webpack_require__) {
  18426. "use strict";
  18427. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  18428. Object.defineProperty(exports, "__esModule", {
  18429. value: true
  18430. });
  18431. exports.cancel = cancel;
  18432. exports.del = del;
  18433. exports.detail = detail;
  18434. exports.order = order;
  18435. exports.orderDetail = orderDetail;
  18436. exports.store = store;
  18437. exports.submit = submit;
  18438. var _request = _interopRequireDefault(__webpack_require__(/*! @/static/js/request.js */ 166));
  18439. var apiUri = {
  18440. store: '/order/store',
  18441. detail: '/confirm/detail',
  18442. submit: '/confirm/submit',
  18443. order: '/order/data',
  18444. orderDetail: '/order/detail',
  18445. cancel: '/order/cancel',
  18446. del: '/order/del'
  18447. };
  18448. function cancel(param) {
  18449. return _request.default.request(apiUri.cancel, 'POST', param, false, true, false);
  18450. }
  18451. function del(param) {
  18452. return _request.default.request(apiUri.del, 'POST', param, false, true, false);
  18453. }
  18454. function store(param) {
  18455. return _request.default.request(apiUri.store, 'POST', param, false, true, false);
  18456. }
  18457. function detail(param) {
  18458. return _request.default.request(apiUri.detail, 'POST', param, false, true, false);
  18459. }
  18460. function orderDetail(param) {
  18461. return _request.default.request(apiUri.orderDetail, 'GET', param, false, true, false);
  18462. }
  18463. function submit(param) {
  18464. return _request.default.request(apiUri.submit, 'POST', param, false, true, false);
  18465. }
  18466. function order(param) {
  18467. return _request.default.request(apiUri.order, 'GET', param, false, true, false);
  18468. }
  18469. /***/ }),
  18470. /* 176 */,
  18471. /* 177 */,
  18472. /* 178 */,
  18473. /* 179 */,
  18474. /* 180 */,
  18475. /* 181 */,
  18476. /* 182 */,
  18477. /* 183 */,
  18478. /* 184 */
  18479. /*!*********************************************************!*\
  18480. !*** /Users/z/D/hx-mini/hx-mini-uni/static/api/user.js ***!
  18481. \*********************************************************/
  18482. /*! no static exports found */
  18483. /***/ (function(module, exports, __webpack_require__) {
  18484. "use strict";
  18485. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  18486. Object.defineProperty(exports, "__esModule", {
  18487. value: true
  18488. });
  18489. exports.info = info;
  18490. exports.license = license;
  18491. exports.order = order;
  18492. exports.save = save;
  18493. var _request = _interopRequireDefault(__webpack_require__(/*! @/static/js/request.js */ 166));
  18494. var apiUri = {
  18495. info: '/user/info',
  18496. save: '/user/save'
  18497. };
  18498. function info(param) {
  18499. return _request.default.request(apiUri.info, 'GET', param, false, true, false);
  18500. }
  18501. function save(param) {
  18502. return _request.default.request(apiUri.save, 'POST', param, false, true, false);
  18503. }
  18504. function order(param) {
  18505. return _request.default.request(apiUri.order, 'GET', param, false, true, false);
  18506. }
  18507. function license(param) {
  18508. return _request.default.request(apiUri.license, 'POST', param, false, true, false);
  18509. }
  18510. /***/ }),
  18511. /* 185 */,
  18512. /* 186 */,
  18513. /* 187 */,
  18514. /* 188 */,
  18515. /* 189 */,
  18516. /* 190 */,
  18517. /* 191 */,
  18518. /* 192 */,
  18519. /* 193 */,
  18520. /* 194 */,
  18521. /* 195 */,
  18522. /* 196 */,
  18523. /* 197 */,
  18524. /* 198 */,
  18525. /* 199 */,
  18526. /* 200 */,
  18527. /* 201 */,
  18528. /* 202 */,
  18529. /* 203 */,
  18530. /* 204 */,
  18531. /* 205 */,
  18532. /* 206 */,
  18533. /* 207 */,
  18534. /* 208 */,
  18535. /* 209 */,
  18536. /* 210 */,
  18537. /* 211 */,
  18538. /* 212 */,
  18539. /* 213 */,
  18540. /* 214 */,
  18541. /* 215 */,
  18542. /* 216 */,
  18543. /* 217 */,
  18544. /* 218 */,
  18545. /* 219 */,
  18546. /* 220 */,
  18547. /* 221 */,
  18548. /* 222 */,
  18549. /* 223 */,
  18550. /* 224 */,
  18551. /* 225 */
  18552. /*!************************************************************!*\
  18553. !*** /Users/z/D/hx-mini/hx-mini-uni/static/api/address.js ***!
  18554. \************************************************************/
  18555. /*! no static exports found */
  18556. /***/ (function(module, exports, __webpack_require__) {
  18557. "use strict";
  18558. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  18559. Object.defineProperty(exports, "__esModule", {
  18560. value: true
  18561. });
  18562. exports.data = data;
  18563. exports.del = del;
  18564. exports.save = save;
  18565. var _request = _interopRequireDefault(__webpack_require__(/*! @/static/js/request.js */ 166));
  18566. var apiUri = {
  18567. data: '/address/data',
  18568. save: '/address/save',
  18569. del: '/address/del'
  18570. };
  18571. function data(param) {
  18572. return _request.default.request(apiUri.data, 'GET', param, false, true, false);
  18573. }
  18574. function save(param) {
  18575. return _request.default.request(apiUri.save, 'POST', param, false, true, false);
  18576. }
  18577. function del(param) {
  18578. return _request.default.request(apiUri.del, 'POST', param, false, true, false);
  18579. }
  18580. /***/ }),
  18581. /* 226 */
  18582. /*!********************************************************!*\
  18583. !*** /Users/z/D/hx-mini/hx-mini-uni/static/js/form.js ***!
  18584. \********************************************************/
  18585. /*! no static exports found */
  18586. /***/ (function(module, exports) {
  18587. function _createForOfIteratorHelper(o, allowArrayLike) { var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"]; if (!it) { if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") { if (it) o = it; var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e) { throw _e; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var normalCompletion = true, didErr = false, err; return { s: function s() { it = it.call(o); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e2) { didErr = true; err = _e2; }, f: function f() { try { if (!normalCompletion && it.return != null) it.return(); } finally { if (didErr) throw err; } } }; }
  18588. function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
  18589. function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
  18590. /**
  18591. * 表单验证
  18592. * @author dingyong
  18593. * @version 1.4.0
  18594. **/
  18595. var form = {
  18596. //当出现错误时返回错误消息,否则返回空即为验证通过
  18597. /*
  18598. formData:Object 表单对象。{key:value,key:value},key==rules.name
  18599. rules: Array [{name:name,rule:[],msg:[]},{name:name,rule:[],msg:[]}]
  18600. name:name 属性=> 元素的名称
  18601. rule:字符串数组 ["required","isMobile","isEmail","isCarNo","isIdCard","isAmount","isNum","isChinese","isEnglish",isEnAndNo","isSpecial","isEmoji",""isDate","isUrl","isSame:key","range:[1,9]","minLength:9","maxLength:Number"]
  18602. msg:数组 []。 与数组 rule 长度相同,对应的错误提示信息
  18603. */
  18604. validation: function validation(formData, rules) {
  18605. var _iterator = _createForOfIteratorHelper(rules),
  18606. _step;
  18607. try {
  18608. for (_iterator.s(); !(_step = _iterator.n()).done;) {
  18609. var item = _step.value;
  18610. var key = item.name;
  18611. var rule = item.rule;
  18612. var msgArr = item.msg;
  18613. if (!key || !rule || rule.length === 0 || !msgArr || msgArr.length === 0) {
  18614. continue;
  18615. }
  18616. for (var i = 0, length = rule.length; i < length; i++) {
  18617. var ruleItem = rule[i];
  18618. var msg = msgArr[i];
  18619. if (!ruleItem || !msg) {
  18620. continue;
  18621. }
  18622. //数据处理
  18623. var value = null;
  18624. if (~ruleItem.indexOf(":")) {
  18625. var temp = ruleItem.split(":");
  18626. ruleItem = temp[0];
  18627. value = temp[1];
  18628. }
  18629. var isError = false;
  18630. switch (ruleItem) {
  18631. case "required":
  18632. isError = form._isNullOrEmpty(formData[key]);
  18633. break;
  18634. case "isMobile":
  18635. isError = !form._isMobile(formData[key]);
  18636. break;
  18637. case "isEmail":
  18638. isError = !form._isEmail(formData[key]);
  18639. break;
  18640. case "isCarNo":
  18641. isError = !form._isCarNo(formData[key]);
  18642. break;
  18643. case "isIdCard":
  18644. isError = !form._isIdCard(formData[key]);
  18645. break;
  18646. case "isAmount":
  18647. isError = !form._isAmount(formData[key]);
  18648. break;
  18649. case "isNum":
  18650. isError = !form._isNum(formData[key]);
  18651. break;
  18652. case "isChinese":
  18653. isError = !form._isChinese(formData[key]);
  18654. break;
  18655. case "isEnglish":
  18656. isError = !form._isEnglish(formData[key]);
  18657. break;
  18658. case "isEnAndNo":
  18659. isError = !form._isEnAndNo(formData[key]);
  18660. break;
  18661. case "isEnOrNo":
  18662. isError = !form._isEnOrNo(formData[key]);
  18663. break;
  18664. case "isSpecial":
  18665. isError = form._isSpecial(formData[key]);
  18666. break;
  18667. case "isEmoji":
  18668. isError = form._isEmoji(formData[key]);
  18669. break;
  18670. case "isDate":
  18671. isError = !form._isDate(formData[key]);
  18672. break;
  18673. case "isUrl":
  18674. isError = !form._isUrl(formData[key]);
  18675. break;
  18676. case "isSame":
  18677. isError = !form._isSame(formData[key], formData[value]);
  18678. break;
  18679. case "range":
  18680. var range = null;
  18681. try {
  18682. range = JSON.parse(value);
  18683. if (range.length <= 1) {
  18684. throw new Error("range值传入有误!");
  18685. }
  18686. } catch (e) {
  18687. return "range值传入有误!";
  18688. }
  18689. isError = !form._isRange(formData[key], range[0], range[1]);
  18690. break;
  18691. case "minLength":
  18692. isError = !form._minLength(formData[key], value);
  18693. break;
  18694. case "maxLength":
  18695. isError = !form._maxLength(formData[key], value);
  18696. break;
  18697. default:
  18698. break;
  18699. }
  18700. if (isError) {
  18701. return msg;
  18702. }
  18703. }
  18704. }
  18705. } catch (err) {
  18706. _iterator.e(err);
  18707. } finally {
  18708. _iterator.f();
  18709. }
  18710. return "";
  18711. },
  18712. _isNullOrEmpty: function _isNullOrEmpty(value) {
  18713. return value === null || value === '' || value === undefined ? true : false;
  18714. },
  18715. _isMobile: function _isMobile(value) {
  18716. return /^(?:13\d|14\d|15\d|16\d|17\d|18\d|19\d)\d{5}(\d{3}|\*{3})$/.test(value);
  18717. },
  18718. _isEmail: function _isEmail(value) {
  18719. return /^[a-z0-9]+([._\\-]*[a-z0-9])*@([a-z0-9]+[-a-z0-9]*[a-z0-9]+.){1,63}[a-z0-9]+$/.test(value);
  18720. },
  18721. _isCarNo: function _isCarNo(value) {
  18722. // 新能源车牌
  18723. var xreg = /^[京津沪渝冀豫云辽黑湘皖鲁新苏浙赣鄂桂甘晋蒙陕吉闽贵粤青藏川宁琼使领A-Z]{1}[A-Z]{1}(([0-9]{5}[DF]$)|([DF][A-HJ-NP-Z0-9][0-9]{4}$))/;
  18724. // 旧车牌
  18725. var creg = /^[京津沪渝冀豫云辽黑湘皖鲁新苏浙赣鄂桂甘晋蒙陕吉闽贵粤青藏川宁琼使领A-Z]{1}[A-Z]{1}[A-HJ-NP-Z0-9]{4}[A-HJ-NP-Z0-9挂学警港澳]{1}$/;
  18726. if (value.length === 7) {
  18727. return creg.test(value);
  18728. } else if (value.length === 8) {
  18729. return xreg.test(value);
  18730. } else {
  18731. return false;
  18732. }
  18733. },
  18734. _isIdCard: function _isIdCard(value) {
  18735. var idCard = value;
  18736. if (idCard.length == 15) {
  18737. return this.__isValidityBrithBy15IdCard;
  18738. } else if (idCard.length == 18) {
  18739. var arrIdCard = idCard.split("");
  18740. if (this.__isValidityBrithBy18IdCard(idCard) && this.__isTrueValidateCodeBy18IdCard(arrIdCard)) {
  18741. return true;
  18742. } else {
  18743. return false;
  18744. }
  18745. } else {
  18746. return false;
  18747. }
  18748. },
  18749. __isTrueValidateCodeBy18IdCard: function __isTrueValidateCodeBy18IdCard(arrIdCard) {
  18750. var sum = 0;
  18751. var Wi = [7, 9, 10, 5, 8, 4, 2, 1, 6, 3, 7, 9, 10, 5, 8, 4, 2, 1];
  18752. var ValideCode = [1, 0, 10, 9, 8, 7, 6, 5, 4, 3, 2];
  18753. if (arrIdCard[17].toLowerCase() == 'x') {
  18754. arrIdCard[17] = 10;
  18755. }
  18756. for (var i = 0; i < 17; i++) {
  18757. sum += Wi[i] * arrIdCard[i];
  18758. }
  18759. var valCodePosition = sum % 11;
  18760. if (arrIdCard[17] == ValideCode[valCodePosition]) {
  18761. return true;
  18762. } else {
  18763. return false;
  18764. }
  18765. },
  18766. __isValidityBrithBy18IdCard: function __isValidityBrithBy18IdCard(idCard18) {
  18767. var year = idCard18.substring(6, 10);
  18768. var month = idCard18.substring(10, 12);
  18769. var day = idCard18.substring(12, 14);
  18770. var temp_date = new Date(year, parseFloat(month) - 1, parseFloat(day));
  18771. if (temp_date.getFullYear() != parseFloat(year) || temp_date.getMonth() != parseFloat(month) - 1 || temp_date.getDate() != parseFloat(day)) {
  18772. return false;
  18773. } else {
  18774. return true;
  18775. }
  18776. },
  18777. __isValidityBrithBy15IdCard: function __isValidityBrithBy15IdCard(idCard15) {
  18778. var year = idCard15.substring(6, 8);
  18779. var month = idCard15.substring(8, 10);
  18780. var day = idCard15.substring(10, 12);
  18781. var temp_date = new Date(year, parseFloat(month) - 1, parseFloat(day));
  18782. if (temp_date.getYear() != parseFloat(year) || temp_date.getMonth() != parseFloat(month) - 1 || temp_date.getDate() != parseFloat(day)) {
  18783. return false;
  18784. } else {
  18785. return true;
  18786. }
  18787. },
  18788. _isAmount: function _isAmount(value) {
  18789. //金额,只允许保留两位小数
  18790. return /^([0-9]*[.]?[0-9])[0-9]{0,1}$/.test(value);
  18791. },
  18792. _isNum: function _isNum(value) {
  18793. //只能为数字
  18794. return /^[0-9]+$/.test(value);
  18795. },
  18796. _isChinese: function _isChinese(value) {
  18797. var reg = /.*[\u4e00-\u9fa5]+.*$/;
  18798. return value !== "" && reg.test(value) && !form._isSpecial(value) && !form._isEmoji(value);
  18799. },
  18800. _isEnglish: function _isEnglish(value) {
  18801. return /^[a-zA-Z]*$/.test(value);
  18802. },
  18803. _isEnAndNo: function _isEnAndNo(value) {
  18804. //8~20位数字和字母组合
  18805. return /^(?![0-9]+$)(?![a-zA-Z]+$)[0-9A-Za-z]{6,20}$/.test(value);
  18806. },
  18807. _isEnOrNo: function _isEnOrNo(value) {
  18808. //英文或者数字
  18809. var reg = /.*[\u4e00-\u9fa5]+.*$/;
  18810. var result = true;
  18811. if (reg.test(value) || form._isSpecial(value) || form._isEmoji(value)) {
  18812. result = false;
  18813. }
  18814. return result;
  18815. },
  18816. _isSpecial: function _isSpecial(value) {
  18817. //是否包含特殊字符
  18818. var regEn = /[`~!@#$%^&*()_+<>?:"{},.\/;'[\]]/im,
  18819. regCn = /[·!#¥(——):;“”‘、,|《。》?、【】[\]]/im;
  18820. if (regEn.test(value) || regCn.test(value)) {
  18821. return true;
  18822. }
  18823. return false;
  18824. },
  18825. _isEmoji: function _isEmoji(value) {
  18826. //是否包含表情
  18827. return /\uD83C[\uDF00-\uDFFF]|\uD83D[\uDC00-\uDE4F]/g.test(value);
  18828. },
  18829. _isDate: function _isDate(value) {
  18830. //2019-10-12
  18831. var reg = /^(?:(?!0000)[0-9]{4}-(?:(?:0[1-9]|1[0-2])-(?:0[1-9]|1[0-9]|2[0-8])|(?:0[13-9]|1[0-2])-(?:29|30)|(?:0[13578]|1[02])-31)|(?:[0-9]{2}(?:0[48]|[2468][048]|[13579][26])|(?:0[48]|[2468][048]|[13579][26])00)-02-29)$/;
  18832. return reg.test(value);
  18833. },
  18834. _isUrl: function _isUrl(value) {
  18835. return /^((https?|ftp|file):\/\/)?([\da-z\.-]+)\.([a-z\.]{2,6})([\/\w \.-]*)*\/?$/.test(value);
  18836. },
  18837. _isSame: function _isSame(value1, value2) {
  18838. return value1 === value2;
  18839. },
  18840. _isRange: function _isRange(value, range1, range2) {
  18841. if (!range1 && range1 != 0 && !range2 && range2 != 0) {
  18842. return true;
  18843. } else if (!range1 && range1 != 0) {
  18844. return value <= range2;
  18845. } else if (!range2 && range2 != 0) {
  18846. return value >= range1;
  18847. } else {
  18848. return value >= range1 && value <= range2;
  18849. }
  18850. },
  18851. _minLength: function _minLength(value, min) {
  18852. return value.length >= Number(min);
  18853. },
  18854. _maxLength: function _maxLength(value, max) {
  18855. return value.length <= Number(max);
  18856. }
  18857. };
  18858. module.exports = {
  18859. validation: form.validation
  18860. };
  18861. /***/ }),
  18862. /* 227 */,
  18863. /* 228 */,
  18864. /* 229 */,
  18865. /* 230 */,
  18866. /* 231 */,
  18867. /* 232 */,
  18868. /* 233 */,
  18869. /* 234 */,
  18870. /* 235 */,
  18871. /* 236 */,
  18872. /* 237 */,
  18873. /* 238 */,
  18874. /* 239 */,
  18875. /* 240 */,
  18876. /* 241 */,
  18877. /* 242 */
  18878. /*!***************************************************************************************!*\
  18879. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/components/u-empty/props.js ***!
  18880. \***************************************************************************************/
  18881. /*! no static exports found */
  18882. /***/ (function(module, exports, __webpack_require__) {
  18883. "use strict";
  18884. /* WEBPACK VAR INJECTION */(function(uni) {
  18885. Object.defineProperty(exports, "__esModule", {
  18886. value: true
  18887. });
  18888. exports.default = void 0;
  18889. var _default = {
  18890. props: {
  18891. // 内置图标名称,或图片路径,建议绝对路径
  18892. icon: {
  18893. type: String,
  18894. default: uni.$u.props.empty.icon
  18895. },
  18896. // 提示文字
  18897. text: {
  18898. type: String,
  18899. default: uni.$u.props.empty.text
  18900. },
  18901. // 文字颜色
  18902. textColor: {
  18903. type: String,
  18904. default: uni.$u.props.empty.textColor
  18905. },
  18906. // 文字大小
  18907. textSize: {
  18908. type: [String, Number],
  18909. default: uni.$u.props.empty.textSize
  18910. },
  18911. // 图标的颜色
  18912. iconColor: {
  18913. type: String,
  18914. default: uni.$u.props.empty.iconColor
  18915. },
  18916. // 图标的大小
  18917. iconSize: {
  18918. type: [String, Number],
  18919. default: uni.$u.props.empty.iconSize
  18920. },
  18921. // 选择预置的图标类型
  18922. mode: {
  18923. type: String,
  18924. default: uni.$u.props.empty.mode
  18925. },
  18926. // 图标宽度,单位px
  18927. width: {
  18928. type: [String, Number],
  18929. default: uni.$u.props.empty.width
  18930. },
  18931. // 图标高度,单位px
  18932. height: {
  18933. type: [String, Number],
  18934. default: uni.$u.props.empty.height
  18935. },
  18936. // 是否显示组件
  18937. show: {
  18938. type: Boolean,
  18939. default: uni.$u.props.empty.show
  18940. },
  18941. // 组件距离上一个元素之间的距离,默认px单位
  18942. marginTop: {
  18943. type: [String, Number],
  18944. default: uni.$u.props.empty.marginTop
  18945. }
  18946. }
  18947. };
  18948. exports.default = _default;
  18949. /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./node_modules/@dcloudio/uni-mp-toutiao/dist/index.js */ 1)["default"]))
  18950. /***/ }),
  18951. /* 243 */,
  18952. /* 244 */,
  18953. /* 245 */,
  18954. /* 246 */,
  18955. /* 247 */,
  18956. /* 248 */
  18957. /*!****************************************************************************************************************************!*\
  18958. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/z-paging/components/z-paging/js/z-paging-main.js?vue&type=script&lang=js& ***!
  18959. \****************************************************************************************************************************/
  18960. /*! no static exports found */
  18961. /***/ (function(module, __webpack_exports__, __webpack_require__) {
  18962. "use strict";
  18963. __webpack_require__.r(__webpack_exports__);
  18964. /* harmony import */ var _Applications_HBuilderX_app_Contents_HBuilderX_plugins_uniapp_cli_node_modules_babel_loader_lib_index_js_Applications_HBuilderX_app_Contents_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_13_1_Applications_HBuilderX_app_Contents_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_script_js_z_paging_main_js_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! -!../../../../../../../../../../Applications/HBuilderX.app/Contents/HBuilderX/plugins/uniapp-cli/node_modules/babel-loader/lib!../../../../../../../../../../Applications/HBuilderX.app/Contents/HBuilderX/plugins/uniapp-cli/node_modules/@dcloudio/vue-cli-plugin-uni/packages/webpack-preprocess-loader??ref--13-1!../../../../../../../../../../Applications/HBuilderX.app/Contents/HBuilderX/plugins/uniapp-cli/node_modules/@dcloudio/webpack-uni-mp-loader/lib/script.js!./z-paging-main.js?vue&type=script&lang=js& */ 249);
  18965. /* harmony import */ var _Applications_HBuilderX_app_Contents_HBuilderX_plugins_uniapp_cli_node_modules_babel_loader_lib_index_js_Applications_HBuilderX_app_Contents_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_13_1_Applications_HBuilderX_app_Contents_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_script_js_z_paging_main_js_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_Applications_HBuilderX_app_Contents_HBuilderX_plugins_uniapp_cli_node_modules_babel_loader_lib_index_js_Applications_HBuilderX_app_Contents_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_13_1_Applications_HBuilderX_app_Contents_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_script_js_z_paging_main_js_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0__);
  18966. /* harmony reexport (unknown) */ for(var __WEBPACK_IMPORT_KEY__ in _Applications_HBuilderX_app_Contents_HBuilderX_plugins_uniapp_cli_node_modules_babel_loader_lib_index_js_Applications_HBuilderX_app_Contents_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_13_1_Applications_HBuilderX_app_Contents_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_script_js_z_paging_main_js_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0__) if(["default"].indexOf(__WEBPACK_IMPORT_KEY__) < 0) (function(key) { __webpack_require__.d(__webpack_exports__, key, function() { return _Applications_HBuilderX_app_Contents_HBuilderX_plugins_uniapp_cli_node_modules_babel_loader_lib_index_js_Applications_HBuilderX_app_Contents_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_13_1_Applications_HBuilderX_app_Contents_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_script_js_z_paging_main_js_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0__[key]; }) }(__WEBPACK_IMPORT_KEY__));
  18967. /* harmony default export */ __webpack_exports__["default"] = (_Applications_HBuilderX_app_Contents_HBuilderX_plugins_uniapp_cli_node_modules_babel_loader_lib_index_js_Applications_HBuilderX_app_Contents_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_vue_cli_plugin_uni_packages_webpack_preprocess_loader_index_js_ref_13_1_Applications_HBuilderX_app_Contents_HBuilderX_plugins_uniapp_cli_node_modules_dcloudio_webpack_uni_mp_loader_lib_script_js_z_paging_main_js_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0___default.a);
  18968. /***/ }),
  18969. /* 249 */
  18970. /*!*******************************************************************************************************************************************************************************************************************************************************************************************************************!*\
  18971. !*** ./node_modules/babel-loader/lib!./node_modules/@dcloudio/vue-cli-plugin-uni/packages/webpack-preprocess-loader??ref--13-1!./node_modules/@dcloudio/webpack-uni-mp-loader/lib/script.js!/Users/z/D/hx-mini/hx-mini-uni/uni_modules/z-paging/components/z-paging/js/z-paging-main.js?vue&type=script&lang=js& ***!
  18972. \*******************************************************************************************************************************************************************************************************************************************************************************************************************/
  18973. /*! no static exports found */
  18974. /***/ (function(module, exports, __webpack_require__) {
  18975. "use strict";
  18976. /* WEBPACK VAR INJECTION */(function(uni) {
  18977. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  18978. Object.defineProperty(exports, "__esModule", {
  18979. value: true
  18980. });
  18981. exports.default = void 0;
  18982. var _regenerator = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/regenerator */ 54));
  18983. var _asyncToGenerator2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/asyncToGenerator */ 56));
  18984. var _defineProperty2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/defineProperty */ 10));
  18985. var _zPagingStatic = _interopRequireDefault(__webpack_require__(/*! ./z-paging-static */ 250));
  18986. var _zPagingConstant = _interopRequireDefault(__webpack_require__(/*! ./z-paging-constant */ 251));
  18987. var _zPagingUtils = _interopRequireDefault(__webpack_require__(/*! ./z-paging-utils */ 252));
  18988. var _commonLayout = _interopRequireDefault(__webpack_require__(/*! ./modules/common-layout */ 254));
  18989. var _dataHandle = _interopRequireDefault(__webpack_require__(/*! ./modules/data-handle */ 255));
  18990. var _i18n = _interopRequireDefault(__webpack_require__(/*! ./modules/i18n */ 258));
  18991. var _nvue = _interopRequireDefault(__webpack_require__(/*! ./modules/nvue */ 263));
  18992. var _empty = _interopRequireDefault(__webpack_require__(/*! ./modules/empty */ 264));
  18993. var _refresher = _interopRequireDefault(__webpack_require__(/*! ./modules/refresher */ 265));
  18994. var _loadMore = _interopRequireDefault(__webpack_require__(/*! ./modules/load-more */ 266));
  18995. var _loading = _interopRequireDefault(__webpack_require__(/*! ./modules/loading */ 267));
  18996. var _chatRecordMode = _interopRequireDefault(__webpack_require__(/*! ./modules/chat-record-mode */ 268));
  18997. var _scroller = _interopRequireDefault(__webpack_require__(/*! ./modules/scroller */ 269));
  18998. var _backToTop = _interopRequireDefault(__webpack_require__(/*! ./modules/back-to-top */ 270));
  18999. var _virtualList = _interopRequireDefault(__webpack_require__(/*! ./modules/virtual-list */ 271));
  19000. var _zPagingEnum = _interopRequireDefault(__webpack_require__(/*! ./z-paging-enum */ 256));
  19001. function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
  19002. function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { (0, _defineProperty2.default)(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
  19003. var zPagingRefresh = function zPagingRefresh() {
  19004. __webpack_require__.e(/*! require.ensure | uni_modules/z-paging/components/z-paging/components/z-paging-refresh */ "uni_modules/z-paging/components/z-paging/components/z-paging-refresh").then((function () {
  19005. return resolve(__webpack_require__(/*! ../components/z-paging-refresh */ 305));
  19006. }).bind(null, __webpack_require__)).catch(__webpack_require__.oe);
  19007. };
  19008. var zPagingLoadMore = function zPagingLoadMore() {
  19009. __webpack_require__.e(/*! require.ensure | uni_modules/z-paging/components/z-paging/components/z-paging-load-more */ "uni_modules/z-paging/components/z-paging/components/z-paging-load-more").then((function () {
  19010. return resolve(__webpack_require__(/*! ../components/z-paging-load-more */ 312));
  19011. }).bind(null, __webpack_require__)).catch(__webpack_require__.oe);
  19012. };
  19013. var zPagingEmptyView = function zPagingEmptyView() {
  19014. __webpack_require__.e(/*! require.ensure | uni_modules/z-paging/components/z-paging-empty-view/z-paging-empty-view */ "uni_modules/z-paging/components/z-paging-empty-view/z-paging-empty-view").then((function () {
  19015. return resolve(__webpack_require__(/*! ../../z-paging-empty-view/z-paging-empty-view */ 298));
  19016. }).bind(null, __webpack_require__)).catch(__webpack_require__.oe);
  19017. };
  19018. var systemInfo = _zPagingUtils.default.getSystemInfoSync();
  19019. var _default = {
  19020. name: "z-paging",
  19021. components: {
  19022. zPagingRefresh: zPagingRefresh,
  19023. zPagingLoadMore: zPagingLoadMore,
  19024. zPagingEmptyView: zPagingEmptyView
  19025. },
  19026. mixins: [_commonLayout.default, _dataHandle.default, _i18n.default, _nvue.default, _empty.default, _refresher.default, _loadMore.default, _loading.default, _chatRecordMode.default, _scroller.default, _backToTop.default, _virtualList.default],
  19027. data: function data() {
  19028. return {
  19029. // --------------静态资源---------------
  19030. base64BackToTop: _zPagingStatic.default.base64BackToTop,
  19031. // -------------全局数据相关--------------
  19032. // 当前加载类型
  19033. loadingType: _zPagingEnum.default.LoadingType.Refresher,
  19034. requestTimeStamp: 0,
  19035. wxsPropType: '',
  19036. renderPropScrollTop: -1,
  19037. checkScrolledToBottomTimeOut: null,
  19038. cacheTopHeight: -1,
  19039. statusBarHeight: systemInfo.statusBarHeight,
  19040. scrollViewHeight: 0,
  19041. pagingOrgTop: -1,
  19042. // --------------状态&判断---------------
  19043. insideOfPaging: -1,
  19044. isLoadFailed: false,
  19045. isIos: systemInfo.platform === 'ios',
  19046. disabledBounce: false,
  19047. fromCompleteEmit: false,
  19048. disabledCompleteEmit: false,
  19049. pageLaunched: false,
  19050. active: false,
  19051. // ---------------wxs相关---------------
  19052. wxsIsScrollTopInTopRange: true,
  19053. wxsScrollTop: 0,
  19054. wxsPageScrollTop: 0,
  19055. wxsOnPullingDown: false
  19056. };
  19057. },
  19058. props: {
  19059. // 调用complete后延迟处理的时间,单位为毫秒,默认0毫秒,优先级高于minDelay
  19060. delay: {
  19061. type: [Number, String],
  19062. default: _zPagingUtils.default.gc('delay', 0)
  19063. },
  19064. // 触发@query后最小延迟处理的时间,单位为毫秒,默认0毫秒,优先级低于delay(假设设置为300毫秒,若分页请求时间小于300毫秒,则在调用complete后延迟[300毫秒-请求时长];若请求时长大于300毫秒,则不延迟),当show-refresher-when-reload为true或reload(true)时,其最小值为400
  19065. minDelay: {
  19066. type: [Number, String],
  19067. default: _zPagingUtils.default.gc('minDelay', 0)
  19068. },
  19069. // 设置z-paging的style,部分平台(如微信小程序)无法直接修改组件的style,可使用此属性代替
  19070. pagingStyle: {
  19071. type: Object,
  19072. default: _zPagingUtils.default.gc('pagingStyle', {})
  19073. },
  19074. // 设置z-paging的class,优先级低于pagingStyle和height、width、maxWidth、bgColor
  19075. pagingClass: {
  19076. type: [String, Array, Object],
  19077. default: _zPagingUtils.default.gc('pagingClass', '')
  19078. },
  19079. // z-paging的高度,优先级低于pagingStyle中设置的height;传字符串,如100px、100rpx、100%
  19080. height: {
  19081. type: String,
  19082. default: _zPagingUtils.default.gc('height', '')
  19083. },
  19084. // z-paging的宽度,优先级低于pagingStyle中设置的width;传字符串,如100px、100rpx、100%
  19085. width: {
  19086. type: String,
  19087. default: _zPagingUtils.default.gc('width', '')
  19088. },
  19089. // z-paging的最大宽度,优先级低于pagingStyle中设置的max-width;传字符串,如100px、100rpx、100%。默认为空,也就是铺满窗口宽度,若设置了特定值则会自动添加margin: 0 auto
  19090. maxWidth: {
  19091. type: String,
  19092. default: _zPagingUtils.default.gc('maxWidth', '')
  19093. },
  19094. // z-paging的背景色,优先级低于pagingStyle中设置的background。传字符串,如"#ffffff"
  19095. bgColor: {
  19096. type: String,
  19097. default: _zPagingUtils.default.gc('bgColor', '')
  19098. },
  19099. // 设置z-paging的容器(插槽的父view)的style
  19100. pagingContentStyle: {
  19101. type: Object,
  19102. default: _zPagingUtils.default.gc('pagingContentStyle', {})
  19103. },
  19104. // z-paging是否自动高度,若自动高度则会自动铺满屏幕
  19105. autoHeight: {
  19106. type: Boolean,
  19107. default: _zPagingUtils.default.gc('autoHeight', false)
  19108. },
  19109. // z-paging是否自动高度时,附加的高度,注意添加单位px或rpx,若需要减少高度,则传负数
  19110. autoHeightAddition: {
  19111. type: [Number, String],
  19112. default: _zPagingUtils.default.gc('autoHeightAddition', '0px')
  19113. },
  19114. // loading(下拉刷新、上拉加载更多)的主题样式,支持black,white,默认black
  19115. defaultThemeStyle: {
  19116. type: String,
  19117. default: _zPagingUtils.default.gc('defaultThemeStyle', 'black')
  19118. },
  19119. // z-paging是否使用fixed布局,若使用fixed布局,则z-paging的父view无需固定高度,z-paging高度默认为100%,默认为是(当使用内置scroll-view滚动时有效)
  19120. fixed: {
  19121. type: Boolean,
  19122. default: _zPagingUtils.default.gc('fixed', true)
  19123. },
  19124. // 是否开启底部安全区域适配
  19125. safeAreaInsetBottom: {
  19126. type: Boolean,
  19127. default: _zPagingUtils.default.gc('safeAreaInsetBottom', false)
  19128. },
  19129. // 开启底部安全区域适配后,是否使用placeholder形式实现,默认为否。为否时滚动区域会自动避开底部安全区域,也就是所有滚动内容都不会挡住底部安全区域,若设置为是,则滚动时滚动内容会挡住底部安全区域,但是当滚动到底部时才会避开底部安全区域
  19130. useSafeAreaPlaceholder: {
  19131. type: Boolean,
  19132. default: _zPagingUtils.default.gc('useSafeAreaPlaceholder', false)
  19133. },
  19134. // z-paging bottom的背景色,默认透明,传字符串,如"#ffffff"
  19135. bottomBgColor: {
  19136. type: String,
  19137. default: _zPagingUtils.default.gc('bottomBgColor', '')
  19138. },
  19139. // slot="top"的view的z-index,默认为99,仅使用页面滚动时有效
  19140. topZIndex: {
  19141. type: Number,
  19142. default: _zPagingUtils.default.gc('topZIndex', 99)
  19143. },
  19144. // z-paging内容容器父view的z-index,默认为1
  19145. superContentZIndex: {
  19146. type: Number,
  19147. default: _zPagingUtils.default.gc('superContentZIndex', 1)
  19148. },
  19149. // z-paging内容容器部分的z-index,默认为1
  19150. contentZIndex: {
  19151. type: Number,
  19152. default: _zPagingUtils.default.gc('contentZIndex', 1)
  19153. },
  19154. // z-paging二楼的z-index,默认为100
  19155. f2ZIndex: {
  19156. type: Number,
  19157. default: _zPagingUtils.default.gc('f2ZIndex', 100)
  19158. },
  19159. // 使用页面滚动时,是否在不满屏时自动填充满屏幕,默认为是
  19160. autoFullHeight: {
  19161. type: Boolean,
  19162. default: _zPagingUtils.default.gc('autoFullHeight', true)
  19163. },
  19164. // 是否监听列表触摸方向改变,默认为否
  19165. watchTouchDirectionChange: {
  19166. type: Boolean,
  19167. default: _zPagingUtils.default.gc('watchTouchDirectionChange', false)
  19168. },
  19169. // 是否监听列表滚动方向改变,默认为否
  19170. watchScrollDirectionChange: {
  19171. type: Boolean,
  19172. default: _zPagingUtils.default.gc('watchScrollDirectionChange', false)
  19173. },
  19174. // 是否只使用基础布局,设置为true后将关闭mounted自动请求数据、关闭下拉刷新和滚动到底部加载更多,强制隐藏空数据图。默认为否
  19175. layoutOnly: {
  19176. type: Boolean,
  19177. default: _zPagingUtils.default.gc('layoutOnly', false)
  19178. },
  19179. // z-paging中布局的单位,默认为rpx
  19180. unit: {
  19181. type: String,
  19182. default: _zPagingUtils.default.gc('unit', 'rpx')
  19183. }
  19184. },
  19185. created: function created() {
  19186. // 组件创建时,检测是否开始加载状态
  19187. if (this.createdReload && !this.isOnly && this.auto) {
  19188. this._startLoading();
  19189. this.$nextTick(this._preReload);
  19190. }
  19191. },
  19192. mounted: function mounted() {
  19193. var _this = this;
  19194. this.active = true;
  19195. this.wxsPropType = _zPagingUtils.default.getTime().toString();
  19196. this.renderJsIgnore;
  19197. if (!this.createdReload && !this.isOnly && this.auto) {
  19198. // 开始预加载
  19199. _zPagingUtils.default.delay(function () {
  19200. return _this.$nextTick(_this._preReload);
  19201. }, 0);
  19202. }
  19203. // 如果开启了列表缓存,在初始化的时候通过缓存数据填充列表数据
  19204. this.finalUseCache && this._setListByLocalCache();
  19205. var delay = 0;
  19206. delay = _zPagingConstant.default.delayTime;
  19207. this.systemInfo = _zPagingUtils.default.getSystemInfoSync();
  19208. this.$nextTick(function () {
  19209. // 初始化systemInfo
  19210. _this.systemInfo = _zPagingUtils.default.getSystemInfoSync();
  19211. // 初始化z-paging高度
  19212. !_this.usePageScroll && _this.autoHeight && _this._setAutoHeight();
  19213. _this.loaded = true;
  19214. _zPagingUtils.default.delay(function () {
  19215. // 更新fixed模式下z-paging的布局,主要是更新windowTop、windowBottom
  19216. _this.updateFixedLayout();
  19217. // 更新缓存中z-paging整个内容容器高度
  19218. _this._updateCachedSuperContentHeight();
  19219. // 更新z-paging中scroll-view高度
  19220. _this._updateScrollViewHeight();
  19221. });
  19222. });
  19223. // 初始化页面滚动模式下slot="top"、slot="bottom"高度
  19224. this.updatePageScrollTopHeight();
  19225. this.updatePageScrollBottomHeight();
  19226. // 初始化slot="left"、slot="right"宽度
  19227. this.updateLeftAndRightWidth();
  19228. if (this.finalRefresherEnabled && this.useCustomRefresher) {
  19229. this.$nextTick(function () {
  19230. _this.isTouchmoving = true;
  19231. });
  19232. }
  19233. if (!this.layoutOnly) {
  19234. // 监听uni.$emit中全局emit的complete error等事件
  19235. this._onEmit();
  19236. }
  19237. this.$nextTick(function () {
  19238. // 非app平台中,在通过获取css设置的底部安全区域占位view高度设置bottom距离后,更新页面滚动底部高度
  19239. setTimeout(function () {
  19240. _this._getCssSafeAreaInsetBottom(function () {
  19241. return _this.safeAreaInsetBottom && _this.updatePageScrollBottomHeight();
  19242. });
  19243. }, delay);
  19244. });
  19245. },
  19246. destroyed: function destroyed() {
  19247. this._handleUnmounted();
  19248. },
  19249. watch: {
  19250. defaultThemeStyle: {
  19251. handler: function handler(newVal) {
  19252. if (newVal.length) {
  19253. this.finalRefresherDefaultStyle = newVal;
  19254. }
  19255. },
  19256. immediate: true
  19257. },
  19258. autoHeight: function autoHeight(newVal) {
  19259. this.loaded && !this.usePageScroll && this._setAutoHeight(newVal);
  19260. },
  19261. autoHeightAddition: function autoHeightAddition(newVal) {
  19262. this.loaded && !this.usePageScroll && this.autoHeight && this._setAutoHeight(newVal);
  19263. }
  19264. },
  19265. computed: {
  19266. // 当前z-paging的内置样式
  19267. finalPagingStyle: function finalPagingStyle() {
  19268. var pagingStyle = _objectSpread({}, this.pagingStyle);
  19269. if (!this.systemInfo) return pagingStyle;
  19270. var windowTop = this.windowTop,
  19271. windowBottom = this.windowBottom;
  19272. if (!this.usePageScroll && this.fixed) {
  19273. if (windowTop && !pagingStyle.top) {
  19274. pagingStyle.top = windowTop + 'px';
  19275. }
  19276. if (windowBottom && !pagingStyle.bottom) {
  19277. pagingStyle.bottom = windowBottom + 'px';
  19278. }
  19279. }
  19280. if (this.bgColor.length && !pagingStyle['background']) {
  19281. pagingStyle['background'] = this.bgColor;
  19282. }
  19283. if (this.height.length && !pagingStyle['height']) {
  19284. pagingStyle['height'] = this.height;
  19285. }
  19286. if (this.width.length && !pagingStyle['width']) {
  19287. pagingStyle['width'] = this.width;
  19288. }
  19289. if (this.maxWidth.length && !pagingStyle['max-width']) {
  19290. pagingStyle['max-width'] = this.maxWidth;
  19291. pagingStyle['margin'] = '0 auto';
  19292. }
  19293. return pagingStyle;
  19294. },
  19295. // 当前z-paging内容的样式
  19296. finalPagingContentStyle: function finalPagingContentStyle() {
  19297. if (this.contentZIndex != 1) {
  19298. this.pagingContentStyle['z-index'] = this.contentZIndex;
  19299. this.pagingContentStyle['position'] = 'relative';
  19300. }
  19301. return this.pagingContentStyle;
  19302. },
  19303. // 最终的当前开启安全区域适配后,是否使用placeholder形式实现。如果slot=bottom存在,则应当交由固定在底部的view处理,因此需排除此情况
  19304. finalUseSafeAreaPlaceholder: function finalUseSafeAreaPlaceholder() {
  19305. return this.useSafeAreaPlaceholder && !this.zSlots.bottom;
  19306. },
  19307. renderJsIgnore: function renderJsIgnore() {
  19308. var _this2 = this;
  19309. if (this.usePageScroll && this.useChatRecordMode || !this.refresherEnabled && this.scrollable || !this.useCustomRefresher) {
  19310. this.$nextTick(function () {
  19311. _this2.renderPropScrollTop = 10;
  19312. });
  19313. }
  19314. return 0;
  19315. },
  19316. windowHeight: function windowHeight() {
  19317. if (!this.systemInfo) return 0;
  19318. return this.systemInfo.windowHeight || 0;
  19319. },
  19320. windowBottom: function windowBottom() {
  19321. if (!this.systemInfo) return 0;
  19322. return this.systemInfo.windowBottom || 0;
  19323. },
  19324. // 是否是ios+h5
  19325. isIosAndH5: function isIosAndH5() {
  19326. return false;
  19327. return this.isIos;
  19328. },
  19329. // 是否是只使用基础布局或者只使用下拉刷新
  19330. isOnly: function isOnly() {
  19331. return this.layoutOnly || this.refresherOnly;
  19332. }
  19333. },
  19334. methods: {
  19335. // 当前版本号
  19336. getVersion: function getVersion() {
  19337. return "z-paging v".concat(_zPagingConstant.default.version);
  19338. },
  19339. // 设置nvue List的specialEffects
  19340. setSpecialEffects: function setSpecialEffects(args) {
  19341. this.setListSpecialEffects(args);
  19342. },
  19343. // 与setSpecialEffects等效,兼容旧版本
  19344. setListSpecialEffects: function setListSpecialEffects(args) {
  19345. this.nFixFreezing = args && Object.keys(args).length;
  19346. if (this.isIos) {
  19347. this.privateRefresherEnabled = 0;
  19348. }
  19349. !this.usePageScroll && this.$refs['zp-n-list'].setSpecialEffects(args);
  19350. },
  19351. // 使手机发生较短时间的振动(15ms)
  19352. _doVibrateShort: function _doVibrateShort() {
  19353. uni.vibrateShort();
  19354. },
  19355. // 设置z-paging高度
  19356. _setAutoHeight: function _setAutoHeight() {
  19357. var _arguments = arguments,
  19358. _this3 = this;
  19359. return (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee() {
  19360. var shouldFullHeight, scrollViewNode, heightKey, finalScrollViewNode, finalScrollBottomNode, scrollViewTop, scrollViewHeight, additionHeight, importantSuffix, finalHeight;
  19361. return _regenerator.default.wrap(function _callee$(_context) {
  19362. while (1) {
  19363. switch (_context.prev = _context.next) {
  19364. case 0:
  19365. shouldFullHeight = _arguments.length > 0 && _arguments[0] !== undefined ? _arguments[0] : true;
  19366. scrollViewNode = _arguments.length > 1 && _arguments[1] !== undefined ? _arguments[1] : null;
  19367. heightKey = 'min-height';
  19368. _context.prev = 3;
  19369. if (!shouldFullHeight) {
  19370. _context.next = 17;
  19371. break;
  19372. }
  19373. _context.t0 = scrollViewNode;
  19374. if (_context.t0) {
  19375. _context.next = 10;
  19376. break;
  19377. }
  19378. _context.next = 9;
  19379. return _this3._getNodeClientRect('.zp-scroll-view');
  19380. case 9:
  19381. _context.t0 = _context.sent;
  19382. case 10:
  19383. finalScrollViewNode = _context.t0;
  19384. _context.next = 13;
  19385. return _this3._getNodeClientRect('.zp-page-bottom');
  19386. case 13:
  19387. finalScrollBottomNode = _context.sent;
  19388. if (finalScrollViewNode) {
  19389. scrollViewTop = finalScrollViewNode[0].top;
  19390. scrollViewHeight = _this3.windowHeight - scrollViewTop;
  19391. scrollViewHeight -= finalScrollBottomNode ? finalScrollBottomNode[0].height : 0;
  19392. additionHeight = _zPagingUtils.default.convertToPx(_this3.autoHeightAddition); // 在支付宝小程序中,添加!important会导致min-height失效,因此在支付宝小程序中需要去掉
  19393. importantSuffix = ' !important';
  19394. finalHeight = scrollViewHeight + additionHeight - (_this3.insideMore ? 1 : 0) + 'px' + importantSuffix;
  19395. _this3.$set(_this3.scrollViewStyle, heightKey, finalHeight);
  19396. _this3.$set(_this3.scrollViewInStyle, heightKey, finalHeight);
  19397. }
  19398. _context.next = 19;
  19399. break;
  19400. case 17:
  19401. _this3.$delete(_this3.scrollViewStyle, heightKey);
  19402. _this3.$delete(_this3.scrollViewInStyle, heightKey);
  19403. case 19:
  19404. _context.next = 23;
  19405. break;
  19406. case 21:
  19407. _context.prev = 21;
  19408. _context.t1 = _context["catch"](3);
  19409. case 23:
  19410. case "end":
  19411. return _context.stop();
  19412. }
  19413. }
  19414. }, _callee, null, [[3, 21]]);
  19415. }))();
  19416. },
  19417. // 更新scroll-view高度
  19418. _updateScrollViewHeight: function _updateScrollViewHeight() {
  19419. var _this4 = this;
  19420. return (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee2() {
  19421. var scrollViewNode, scrollViewNodeHeight;
  19422. return _regenerator.default.wrap(function _callee2$(_context2) {
  19423. while (1) {
  19424. switch (_context2.prev = _context2.next) {
  19425. case 0:
  19426. _context2.next = 2;
  19427. return _this4._getNodeClientRect('.zp-scroll-view');
  19428. case 2:
  19429. scrollViewNode = _context2.sent;
  19430. if (scrollViewNode) {
  19431. scrollViewNodeHeight = scrollViewNode[0].height;
  19432. _this4.scrollViewHeight = scrollViewNodeHeight;
  19433. _this4.pagingOrgTop = scrollViewNode[0].top;
  19434. // 设置scroll-view内容器的最小高度等于scroll-view的高度(为了解决在快手小程序中内容较少时scroll-view内容器高度无法铺满scroll-view的问题)
  19435. }
  19436. case 4:
  19437. case "end":
  19438. return _context2.stop();
  19439. }
  19440. }
  19441. }, _callee2);
  19442. }))();
  19443. },
  19444. // 组件销毁后续处理
  19445. _handleUnmounted: function _handleUnmounted() {
  19446. this.active = false;
  19447. if (!this.layoutOnly) {
  19448. this._offEmit();
  19449. }
  19450. // 取消监听键盘高度变化事件(H5、百度小程序、抖音小程序、飞书小程序、QQ小程序、快手小程序不支持)
  19451. },
  19452. // 触发更新是否超出页面状态
  19453. _updateInsideOfPaging: function _updateInsideOfPaging() {
  19454. this.insideMore && this.insideOfPaging === true && setTimeout(this.doLoadMore, 200);
  19455. },
  19456. // 清除timeout
  19457. _cleanTimeout: function _cleanTimeout(timeout) {
  19458. if (timeout) {
  19459. clearTimeout(timeout);
  19460. timeout = null;
  19461. }
  19462. return timeout;
  19463. },
  19464. // 添加全局emit监听
  19465. _onEmit: function _onEmit() {
  19466. var _this5 = this;
  19467. uni.$on(_zPagingConstant.default.errorUpdateKey, function (errorMsg) {
  19468. if (_this5.loading) {
  19469. if (!!errorMsg) {
  19470. _this5.customerEmptyViewErrorText = errorMsg;
  19471. }
  19472. _this5.complete(false).catch(function () {});
  19473. }
  19474. });
  19475. uni.$on(_zPagingConstant.default.completeUpdateKey, function (data) {
  19476. setTimeout(function () {
  19477. if (_this5.loading) {
  19478. if (!_this5.disabledCompleteEmit) {
  19479. var type = data.type || 'normal';
  19480. var list = data.list || data;
  19481. var rule = data.rule;
  19482. _this5.fromCompleteEmit = true;
  19483. switch (type) {
  19484. case 'normal':
  19485. _this5.complete(list);
  19486. break;
  19487. case 'total':
  19488. _this5.completeByTotal(list, rule);
  19489. break;
  19490. case 'nomore':
  19491. _this5.completeByNoMore(list, rule);
  19492. break;
  19493. case 'key':
  19494. _this5.completeByKey(list, rule);
  19495. break;
  19496. default:
  19497. break;
  19498. }
  19499. } else {
  19500. _this5.disabledCompleteEmit = false;
  19501. }
  19502. }
  19503. }, 1);
  19504. });
  19505. },
  19506. // 销毁全局emit和listener监听
  19507. _offEmit: function _offEmit() {
  19508. uni.$off(_zPagingConstant.default.errorUpdateKey);
  19509. uni.$off(_zPagingConstant.default.completeUpdateKey);
  19510. }
  19511. }
  19512. };
  19513. exports.default = _default;
  19514. /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./node_modules/@dcloudio/uni-mp-toutiao/dist/index.js */ 1)["default"]))
  19515. /***/ }),
  19516. /* 250 */
  19517. /*!*****************************************************************************************************!*\
  19518. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/z-paging/components/z-paging/js/z-paging-static.js ***!
  19519. \*****************************************************************************************************/
  19520. /*! no static exports found */
  19521. /***/ (function(module, exports, __webpack_require__) {
  19522. "use strict";
  19523. Object.defineProperty(exports, "__esModule", {
  19524. value: true
  19525. });
  19526. exports.default = void 0;
  19527. // [z-paging]公用的静态图片资源
  19528. var _default = {
  19529. base64Arrow: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGQAAABkBAMAAACCzIhnAAAAD1BMVEVHcExRUVFMTExRUVFRUVE9CdWsAAAABHRSTlMAjjrY9ZnUjwAAAQFJREFUWMPt2MsNgzAMgGEEE1B1gKJmAIRYoCH7z9RCXrabh33iYktcIv35EEg5ZBh07pvxJU6MFSPOSRnjnBUjUsaciRUjMsb4xIoRCWNiYsUInzE5sWKEyxiYWDbyefqHx1zIeiYTk7mQYziTYecxHvEJjwmIT3hMQELCYSISEg4TkZj0mYTEpM8kJCU9JiMp6TEZyUmbAUhO2gxAQNJiIAKSFgMRmNQZhMCkziAEJTUGIyipMRjBSZkhCE7KDEFIUmTeGCHJxWz0zXaE0GTCG8ZFtEaS347r/1fe11YyHYVfubxayfjoHmc0YYwmmmiiiSaaaKLJ7ckyz5ve+dw3Xw2emdwm9xSbAAAAAElFTkSuQmCC',
  19530. base64ArrowWhite: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGQAAABkBAMAAACCzIhnAAAAElBMVEVHcEz///////////////////+IGTx/AAAABnRSTlMA/dAkXZOhASU/AAABYElEQVRYw+2YwXLCIBCGsdAHWGbyAKZ4zxi9O017rxLf/1UaWFAgA1m8dcpedNSPf/l/Vh0Ya/Wn6hN0JcGvoCqRM4C8VBFiDwBqqNuJKV0rAnCgy3AUqZE57x0iqTL8Br4U3WBf/YWaIlTKfAcELU/h9w72CSVPa3C3OCDvhpHbRp/s2vq4fHhCeiCl2A3m4Qd71DQR257mFBlMcTlbFnFWzNtHxewYEfSiaLS4el8d8nyhmKJd1CF4eOS0keLMAuSxubLBIeIGQW8YHCFFo7EH9+YDcQt9FMZEswTheaNxTHwHT8SZorJjMrEVwo4Zo0U8HSEyZvJMOg4RjnmmRr8nDYeIz3OMkbfE/QhBo+U9RnZJxjGCRh/WKmHEMWLNkfPKsGh/CWJk1JjG0kcuJggTt34VDP8aWAFhp4nybVb5+9qQhjSkIQ1pSEMa8k+Q5U9rV3dF8MpFBK+/7miVq1/HZ2qmo9D+pAAAAABJRU5ErkJggg==',
  19531. base64Flower: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGQAAABkBAMAAACCzIhnAAAAKlBMVEVHcEzDw8Ovr6+pqamUlJTCwsKenp61tbWxsbGysrLNzc2bm5u5ubmjo6MpovhuAAAACnRSTlMA/P79/sHDhiZS0DxZowAABBBJREFUWMPtl89rE0EUx7ctTXatB3MI1SWnDbUKPUgXqh4ED8Uf7KUVSm3ooVSpSii0Fn/gD4j4o+APiEoVmos9FO2celiqZVgwgaKHPQiCCkv+F99kM7Ozm5kxq1dfD91k9pPve9/3ZjbRNHHok/mKli4eIPNgSuRObuN9SqSEzM20iGnm0yIbqCuV7NSSSIV7uyPM6JMBYdeTOanh/QihJYZsUCSby+VkMj2AvOt0rAeQAwqE3lfKMZVlQCZk1QOCKkkVPadITCfIRNKxfoJI5+0OIFtJx14CMSg1mRSDko7VAfksRQzEbGYqxOJcVTWMCH2I1/IACNW0PWU2M8cmAVHtnH5mM1VRWtwKZjOd5JbF6s1IbaYqaotjNlPHgDAnlAizubTR6ovMYn052g/U5qcmOpi0WL8xTS/3IfSet5m8MEr5ajjF5le6dq/OJpobrdY0t3i9QgefWrxW9/1BLhk0E9m8FeUMhhXal499iD0eQRfDF+ts/tttORRerfp+oV7f4xJj82iUYm1Yzod+ZQEAlS/8mMBwKebVmCVp1f0JLS6zKd17+iwRKTARVg2SHtz3iEbBH+Q+U28zW2Jiza8Tjb1YFoYZMsJyjDqp3M9XBQdSdPLFdxEpvOB37JrHcmR/y9+LgoTlCFGZEa2sc6d4PGlweEa2JSVPoVm+IfGG3ZL037iV9oH+P+Jxc4HGVflNq1M0pivao/EopO4b/ojVCP9GjmiXOeS0DOn1o/iiccT4ORnyvBGF3yUywkQajW4Ti0SGuiy/wVSg/L8w+X/8Q+hvUx8Xd90z4oV5a1i88MbFWHz0WZZ1UrTwBGPX3Rat9AFiXRMRjoMdIdJLEOt2h7jrYOzgOamKZSWSNspOS0X8SAqRYmxRL7sg4eLzYmNehcxh3uoyud/BH2Udux4ywxFTc1xC7Mgf4vMhc5S+kSH3Y7yj+qpwIWSoPTVCOOPVthGx9FbGqrwFw6wSFxJr+17zeKcztt3u+2roAEVgUjDd+AHGuxHy2rZHaa8JMkTHEeyi85ANPO9j9BVuBRD2FY5LDMo/Sz/2hReqGIs/KiFin+CsPsYO/yvM3jL2vE8EbX7/Bf8ejtr2GLN65bioAdgLd8Bis/mD5GmP2qeqyo2ZwQEOtAjRIDH7mBKpUcMoApbZJ5UIxkEwxyMZyMxW/uKFvHCFR3SSmerHyDNQ2dF4JG6zIMpBgLfjSF9x1D6smFcYnGApjmSLICO3ecCDWrQ48geba9DI3STy2i7ax6WIB62fSyIZIiO3GFQqSURp8wCo7GhJBGwuSovJBNjb7kT6FPVnIa9qJ2Ko+l9mefGIdinaMp0yC1URYiwsdfNE45EuA5Cx9EhalfvN5s+UyItm81vaB3p4joniN+SCP7Qc1hblAAAAAElFTkSuQmCC',
  19532. base64FlowerWhite: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGQAAABkBAMAAACCzIhnAAAAElBMVEX///9HcEz///////////////84chYNAAAABnRSTlP/AGzCOYZj5g1nAAACfklEQVRYw+2YTVPDIBCGtza9Jw25a0bvcax30o73OOr//yvma2F3YWlpPTijXNpAHrK8LLALVPFium2vNIFSbwGKTGQA2GUiHcD29yDNy3sMIdUBQl7r2H8mOEVqAHgPkYZUS6Qc2zYhQqtjyDZEximCZwWZLIBeIgYShs2NzxKpSUehYpMJhURGb+O+w5BpMCAREKPnCDHbIY20SzhM5yxziAXpOiBXydrekT9i5XDEq4NIIHHgyU5mRGqviII4mREJJA4QJzMiILwlRJzpKxJKvCBm8OsBBbLux0tsPl4RKYm5aPu6jw1U4mGxEUR9g8M1PcqBEp/WJliNgYOXueBzS4jZSIcgY5lCtevgDSgyzE+rAfuOTQMq0yzvoGH18qju27Mayzs4fPyMziCx81NJa5RNfW7vPYK9KOfDiVkBxFHG8hAj9txuoBuSWORsFfkpBf7xKFLSeaOefEojh5jz22DJEqMP8fUyaKdQx+RnG+yXMpe8Aars8ueR1pVH/bW3FyyvPRw90upLDHwpgBDtg4aUBNkxRLXMAi03IhcZtr1m+FeI/O/JNyDmmL1djLOauSlNflBpW18RQ2bPqXI22MXXEk75KRHTnkPkYbESbdKP2ZFk0r5sIwffAjy1lx+vx7NLjB6/E7Jfv5ERKhzpN0w8IDE8IGFDv5dhz10s7GFiXRZcUeLCEG5P5nDq9k4PFDcoMpE3GY4OuxuCXhmuyNB6k0RsLIAvqp9NE5r8ZCSS8gxnUp7ODdYhZTqxuiJ9uyJJtPmpqJ7wVj+XVieS903iViHziqAhchLEJAyb7jWU647EpUofQ0ziUuXXXhDddtlllSwjgSQu7r4BRWhQqfDPMVwAAAAASUVORK5CYII=',
  19533. base64Success: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGQAAABkBAMAAACCzIhnAAAAElBMVEVRUVFHcExTU1NRUVFRUVFRUVFOSlSUAAAABnRSTlP/AI6+VySB3ZENAAACcElEQVRYw+2YyYKCMAyGI8hdpdxdZu7gcpdZ7jL6/s8yYheSNi0aPdqbwOffpGmaFOYPD3gj4bisN7vddv17N/JVgxn5x12IWgIaWTuO/IE3PseQbwjGPo2cgRmHFLJwdm/X643zwiqOKPPJ1nj3sjEP2iiifZWj5bhopSyGaEO2HX5fbQJzwJ+W7x/jw5ZFjsEU0PMph9xE8i5EqprKALW95eJQURkgzw98uJ/JvwGecR7bIjWWsUgVrrIfFZ2HlLy3sKETD1mmRLRMRhGVssRa0xJkdn3SpJBymBkM8+pSSDXMDNyDaToVHd2fgpNt0sjwiUZO19+jGQ+gQEg9Oq+bufmAVGihomNmjQG7UG3020vrlm7lkFnKFGU3kZ0KGAdmKe821pipQ+qEKcrZeTL2g5FsUks4cStjEZWwXg0b0n4GxmEpkWwIs5VBynjgK7xZaz1/0D7OxkVuLpsY5BQNFyLS84VBjjbg0iL2r2EQHBOxBhikuUOkdxODVF1cxHoWtPPsiyXO455Iv34hssCO8EV4ZIYTjS8SR4qYSHRiTiYQ4ZFbHi0iIhhBTi6dTCgSWRcnw4h4yGTuyTAiOGBIWGoZTgSHJQl+LcOJ4OCnW6yX2bMnJ9pidCOXtkTkTrIGpYuOynAiOF14SamMiOCk5Ke+mq8BcOrrvym8d0zKIQnWT+M1WwOQNO4fFiWb18hhERxJPx2fblbPHHyC41VyiAtKBUFBIih7JMWVoIQTFIr3lKPN80WvoLSWFPC653ioTZA0I0FrQ7qU6asaK0H7JmkSJa2ooOGVtNUsc3j9FYHkIkJy3SG6VHnfXKXGP9t4N9Q4Ye98AAAAAElFTkSuQmCC',
  19534. base64SuccessWhite: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGQAAABkBAMAAACCzIhnAAAAGFBMVEVHcEz///////////////////////////8dS1W+AAAAB3RSTlMAiVYk6KvDHLfaegAAAo1JREFUWMPtWEtzmzAQNhCTq910ytXpiyvxTNOr60zrayepx9d02gnX4sTm7xcEiJX2gdnkGJ1A4tOnfWqXyeR1vMRYzrcPD9v5h5MBl3/Ldvx4cxIg/FWC8X0xjLjalM54uhhCfCrRuJURX0pi3EmIqZV7O59vrRZmguStHL9b7S7ftfLwOtiZDw7AHMtmquAQ12b5Wwbnordm8g9zLLO49qc/m2n6aKnhwPOGZ08hAiNHhheiHae1lOUPGZpQkPKa3q0mOUjaRzSRaGUjpy/mmWSwySSpllcEteBKAT52KEnSbblA51pJEPxBQoiH1FP4E3s5+FJv07h6/ylD6ui7B+9fq/ehrFB98ghec9EoVtyjK8pqCHLmCBOwMWSCeWFNN4MbPAk55NhsvoFHSSVR0k5TCTTEzlUGcqV/nVp7n9oIVkmtaqbAEqEgfdgHJPwsEAyZ9r4VAZXFjpEwyaw3+H2v42KYxKhs1XvY/gSSGv+IHyUSuHXCeZhLAgVI3EjgSGo1Fb3xO0tGGU9S2/KAIbtjxpJASG73qox6w5LUq0cEOa+iIONIWIilQSQ0pPa2jgaRQAgQP7c0mITRWGxpMAmEQFN2NAQJNCV0mI6GIIEO47hlQ0ORQLd0nL+hoUjg1m6I1TRr8uYEAriBHLcVFQ5UEMiBe3XkTBEG04WXlGKGxPnMS305XQPA1Ocn2JiuAZwE66fxnKwBnDTuXxZTMq85lwW6kt5ndLqZPefiU1yvmktcUSooChJF2aMprhQlnKJQ5FxRKkcVRa+itNYU8Io2oVkY14w0NMWYlqft91Bj9VHq+ca3b43BxjWJmla0sfKohlfTVpPN+93L/yLQ/IjQ/O5Q/VR5HdL4D7mlxmjwVdELAAAAAElFTkSuQmCC',
  19535. base64Empty: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAJYAAACWCAMAAAAL34HQAAALeGlUWHRYTUw6Y29tLmFkb2JlLnhtcAAAAAAAPD94cGFja2V0IGJlZ2luPSLvu78iIGlkPSJXNU0wTXBDZWhpSHpyZVN6TlRjemtjOWQiPz4gPHg6eG1wbWV0YSB4bWxuczp4PSJhZG9iZTpuczptZXRhLyIgeDp4bXB0az0iQWRvYmUgWE1QIENvcmUgNi4wLWMwMDIgNzkuMTY0NDg4LCAyMDIwLzA3LzEwLTIyOjA2OjUzICAgICAgICAiPiA8cmRmOlJERiB4bWxuczpyZGY9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkvMDIvMjItcmRmLXN5bnRheC1ucyMiPiA8cmRmOkRlc2NyaXB0aW9uIHJkZjphYm91dD0iIiB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iIHhtbG5zOmRjPSJodHRwOi8vcHVybC5vcmcvZGMvZWxlbWVudHMvMS4xLyIgeG1sbnM6eG1wTU09Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9tbS8iIHhtbG5zOnN0RXZ0PSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VFdmVudCMiIHhtbG5zOnN0UmVmPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VSZWYjIiB4bWxuczpwaG90b3Nob3A9Imh0dHA6Ly9ucy5hZG9iZS5jb20vcGhvdG9zaG9wLzEuMC8iIHhtbG5zOnRpZmY9Imh0dHA6Ly9ucy5hZG9iZS5jb20vdGlmZi8xLjAvIiB4bWxuczpleGlmPSJodHRwOi8vbnMuYWRvYmUuY29tL2V4aWYvMS4wLyIgeG1wOkNyZWF0b3JUb29sPSJBZG9iZSBQaG90b3Nob3AgQ0MgMjAxOSAoV2luZG93cykiIHhtcDpDcmVhdGVEYXRlPSIyMDIyLTAyLTIyVDIxOjIxOjQ1KzA4OjAwIiB4bXA6TWV0YWRhdGFEYXRlPSIyMDI0LTAxLTEzVDE5OjA5OjQwKzA4OjAwIiB4bXA6TW9kaWZ5RGF0ZT0iMjAyNC0wMS0xM1QxOTowOTo0MCswODowMCIgZGM6Zm9ybWF0PSJpbWFnZS9wbmciIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6ZWQwMWYzNWQtOWRjOC00MDBiLWEyMmQtNjM5OGZiNzVhNGRiIiB4bXBNTTpEb2N1bWVudElEPSJhZG9iZTpkb2NpZDpwaG90b3Nob3A6ZDhlMzQ3ZmEtMDY2My1jYTRiLTgzNTctNTk4YjBkNGIzOTU2IiB4bXBNTTpPcmlnaW5hbERvY3VtZW50SUQ9InhtcC5kaWQ6ZDA4MDI4MDItMzUyYS04NTRhLTkxYjctNmRlNmQ1MmViM2QwIiBwaG90b3Nob3A6Q29sb3JNb2RlPSIzIiBwaG90b3Nob3A6SUNDUHJvZmlsZT0ic1JHQiBJRUM2MTk2Ni0yLjEiIHRpZmY6T3JpZW50YXRpb249IjEiIHRpZmY6WFJlc29sdXRpb249IjMwMDAwMDAvMTAwMDAiIHRpZmY6WVJlc29sdXRpb249IjMwMDAwMDAvMTAwMDAiIHRpZmY6UmVzb2x1dGlvblVuaXQ9IjIiIGV4aWY6Q29sb3JTcGFjZT0iMSIgZXhpZjpQaXhlbFhEaW1lbnNpb249IjMwMCIgZXhpZjpQaXhlbFlEaW1lbnNpb249IjMwMCI+IDx4bXBNTTpIaXN0b3J5PiA8cmRmOlNlcT4gPHJkZjpsaSBzdEV2dDphY3Rpb249ImNyZWF0ZWQiIHN0RXZ0Omluc3RhbmNlSUQ9InhtcC5paWQ6ZDA4MDI4MDItMzUyYS04NTRhLTkxYjctNmRlNmQ1MmViM2QwIiBzdEV2dDp3aGVuPSIyMDIyLTAyLTIyVDIxOjIxOjQ1KzA4OjAwIiBzdEV2dDpzb2Z0d2FyZUFnZW50PSJBZG9iZSBQaG90b3Nob3AgQ0MgMjAxOSAoV2luZG93cykiLz4gPHJkZjpsaSBzdEV2dDphY3Rpb249InNhdmVkIiBzdEV2dDppbnN0YW5jZUlEPSJ4bXAuaWlkOjQwNjg2NzJkLWY5NDMtOTU0Mi1iMDBiLTVlMDExNmE1NmIzZSIgc3RFdnQ6d2hlbj0iMjAyNC0wMS0xM1QxMDoyNjoxNiswODowMCIgc3RFdnQ6c29mdHdhcmVBZ2VudD0iQWRvYmUgUGhvdG9zaG9wIENDIDIwMTkgKFdpbmRvd3MpIiBzdEV2dDpjaGFuZ2VkPSIvIi8+IDxyZGY6bGkgc3RFdnQ6YWN0aW9uPSJzYXZlZCIgc3RFdnQ6aW5zdGFuY2VJRD0ieG1wLmlpZDphYmJkZmUyZC0xY2Q2LTJiNDgtYjUyNS05YzlhZjdlNjA4NDMiIHN0RXZ0OndoZW49IjIwMjQtMDEtMTNUMTE6MjM6NDArMDg6MDAiIHN0RXZ0OnNvZnR3YXJlQWdlbnQ9IkFkb2JlIFBob3Rvc2hvcCBDQyAyMDE5IChXaW5kb3dzKSIgc3RFdnQ6Y2hhbmdlZD0iLyIvPiA8cmRmOmxpIHN0RXZ0OmFjdGlvbj0iY29udmVydGVkIiBzdEV2dDpwYXJhbWV0ZXJzPSJmcm9tIGFwcGxpY2F0aW9uL3ZuZC5hZG9iZS5waG90b3Nob3AgdG8gaW1hZ2UvcG5nIi8+IDxyZGY6bGkgc3RFdnQ6YWN0aW9uPSJkZXJpdmVkIiBzdEV2dDpwYXJhbWV0ZXJzPSJjb252ZXJ0ZWQgZnJvbSBhcHBsaWNhdGlvbi92bmQuYWRvYmUucGhvdG9zaG9wIHRvIGltYWdlL3BuZyIvPiA8cmRmOmxpIHN0RXZ0OmFjdGlvbj0ic2F2ZWQiIHN0RXZ0Omluc3RhbmNlSUQ9InhtcC5paWQ6YTQ5MjM5MDAtNDhiZC03YTQ1LWI4NGItYmVlZTVjOWUxYTM1IiBzdEV2dDp3aGVuPSIyMDI0LTAxLTEzVDExOjIzOjQwKzA4OjAwIiBzdEV2dDpzb2Z0d2FyZUFnZW50PSJBZG9iZSBQaG90b3Nob3AgQ0MgMjAxOSAoV2luZG93cykiIHN0RXZ0OmNoYW5nZWQ9Ii8iLz4gPHJkZjpsaSBzdEV2dDphY3Rpb249InNhdmVkIiBzdEV2dDppbnN0YW5jZUlEPSJ4bXAuaWlkOmVkMDFmMzVkLTlkYzgtNDAwYi1hMjJkLTYzOThmYjc1YTRkYiIgc3RFdnQ6d2hlbj0iMjAyNC0wMS0xM1QxOTowOTo0MCswODowMCIgc3RFdnQ6c29mdHdhcmVBZ2VudD0iQWRvYmUgUGhvdG9zaG9wIDIyLjAgKE1hY2ludG9zaCkiIHN0RXZ0OmNoYW5nZWQ9Ii8iLz4gPC9yZGY6U2VxPiA8L3htcE1NOkhpc3Rvcnk+IDx4bXBNTTpEZXJpdmVkRnJvbSBzdFJlZjppbnN0YW5jZUlEPSJ4bXAuaWlkOmFiYmRmZTJkLTFjZDYtMmI0OC1iNTI1LTljOWFmN2U2MDg0MyIgc3RSZWY6ZG9jdW1lbnRJRD0iYWRvYmU6ZG9jaWQ6cGhvdG9zaG9wOjM2ZGQ4NTQxLWQ0MWEtYmY0Yy1iZjA3LWNmNjZhNjZhMDg2MSIgc3RSZWY6b3JpZ2luYWxEb2N1bWVudElEPSJ4bXAuZGlkOmQwODAyODAyLTM1MmEtODU0YS05MWI3LTZkZTZkNTJlYjNkMCIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/Pm30U/gAAAAJcEhZcwAALiMAAC4jAXilP3YAAAA/UExURUdwTODg4O3t7e7u7unp6d7e3uTk5M/Pz8nJyePj4+jo6Pj4+MrKyszMzO7u7unp6fb29vLy8vr6+v7+/sHBweag3xAAAAAOdFJOUwAxia5pF0n+/vzX3KbULQ2DYQAACG1JREFUeNrtm4l2o7gShi20IWFrAd7/WUc7EosDWKZ976Hc7WTmdMKXv0qlqpLyeNx222233Xbbbbfddtv/mOHn8xexSNsiRH5PrbFtW4p+DetpsF4v8Gs+HA3WEwOAfwzriYxaLTVsP8X1QK0z+vqQCzewYogi60aL9SEX5oyxphYVCFTGjfSJCTmN1jBruN5KTGCUS8bhySQGHRaohmW4glwtldbOeYJYKlgvbyUuA8aFFEKc++aIM4hrRnyiMnIZKq1PrihcM3GNKboMF1Naa9X9+8T1KrxIlVbGjv3cAEHOYYMqqgUsVuJqqehV3+sjDwB+DTJp0lYtMCyZpxqjF4e+74+sRcQSFZO8UonUSEFzuUY+DKo59A2kZDatGCjzCauy/2AmhSyCq0WHEj0KTNJDmVeNhErMt1Q8W4xti4/FwMJ4jaxl05TKFiNtD3kBGrHnhiph9V0eXQc6DkyE2xX830AlKshFTErXeuCZXK/9m41wFsGSfZ4lcGeyZ98PrylJ7MWCojQZ3qSukL2QslgdngqJnTEPdTJhXvbNBoR/+7wabIxWduN/Ja5dWEivm4XSZ2uQckNzmRlHrn2lc6eiafvS4V2Hd12tesau8toZW0CtWoZYb9t+OqxdCYKYjVPF16pVbILIy/gR7MVaWMHYPCoa2VkzkX4Iry2rirXbumGyAjGC1h62YLw6ApsNKZph3fpIWHt08JovRWD62sejpXhTrhWrPpl6zZ6PW2oTG5ltlvgtF6weNYCWKeJJSfg4W6PNJlj3sVZgOXV4lc8n4RlkMTLEBDVoYc3nI09kpyzzfgWsjyzBZSNDKF2/wjh+sxYvn8Y1scxlfLF9T1RBO3wVHsnq8Fk4oGkEh/0KJPSa8T2CeWE5X9BPmgLsaRIGeNL2kshCsWoLBmdPJW5Wbz1ndAKUXjPwxXYAUpSV3fy5BJg1aa1tyVXHHMgVH31ewDVrleHr9XqC684SUF4mecR3+wW5SC2QNvxUizRv98mLDhPgYiMDb+v8g0OADxqxcnf9w01mZYJF0fUVP5LcdswbsMmy1DVs5PlE5NpNiTR8M8qAWZkOy6aN13VcoOF2/s3xn3Mes8Xza05tgR/BuNz69nlNzMR0fH45p+G4R9oxh2mKt9MF4J7K/lvWUojwF5nCgCpuRUptnZMQ3au0nSo2UsHgV3xpmeLYzGml3ZFBBzYGPCpOQRwXs1/GG1J74dlZc6JKUOtjBAz9XjVxucGWHbZVJDPJQGYDRl1Qmf1ovk2Sbghb6MQlnF7mBzM1bgOqJAPpoOQaVe+4Skcit3uqHMyG/Sh1rHNN0gAfM0nnPrmulfLVBSm20TSZSdWa0LJl2ukVyE4vTYCgP3uQkwv1TKtQWgxDzBSg80OQjCs4klKvuUzHLCfIbDKIE/S5VIGqD1iD2819pkAqTWdmeina+oZABi7X5B1MGoTJqJSchuk6JNHcgUPAcsVFk0+N0oDN68Vo7FQSmCXjx46OEtUk1lpY2ZFQGr/AcpqVato4wPUD+RhfAeyQI5sJ6l2sDwnKqNFSJvpiyJbFl3kTOjZ2ievwCR7hkUoWeV2vOLAXvB39AJoyqYa81A5cvaAidXYTFTycKDBcalVK5f3XS89kzLVl9txfL+K+p6NUnitz5KkKm7D3DrRPNq4bk7l20aFRppNilmuQI+uzTtj9wPBkTsVwM7HbJ5pwGgujyRyZDzQLNoiRFluRtQ+GzEguqRxUL+ZMFqulMzIfaP3ARj2k/txB8c+2HyjmDizCaVWtNoE5MvMlKs/4VQ7HUJZCrU6qCKcNJ2aSWUZhJZu4VI0LB4CHFdj77DRuGi28WKAxoRyZyzGVrmc0jmk1nP5QaxZo1puqq1YIAqgZb8e/rABZJWNCNxV7DSTpOO7Aail9J9nYHtua/4ouE/aS0X1qtXQzwGx+rnbi2vhF/TfZG52oc6DPo1WCi3RTDnRk7TEntoEp38gg+DjYs2opkR3JW5EpL9rU0XSK5/6LOTAVS+72x7pm60zSf5HMdldjhzJqw1FRcxXdS3ZNZp0s92FiyluUvBPoD9ynZNkBiu2NF11ofnlnQbZgKqvusj9R/f6DOzgVsahbNlXxlsxU8y7qrbTupitRyxFBKG6H3aEPUqj7YrzAymq41FXlZLlO4WLbvG2Kg4vYB+wPfWS2B5Rq8TW9ROpAZbiF6MmCTsx1NLLsx7NOoOiZup2CNbZ36xc96ErcxzuILGrmmFhimjtwKo/yTm7feTVwB61IzbnW4967Kt3cDDotGt8JKrTiUyO3Uy2PZZt9tapXEfXhWmTgcoB+JchFWsiCKvYnhmn/tKuJDbgly897FnFfkE1rQLKy810OU7xW3bEJHCD5gERtuTGuxoJqA6qI9TNMa6MbvZomsiubbPYx78YXDaaRqqsyqfSaLZdjYGHLu65rDgydXCWm1P5EvcQ828f9pcBapTILSMv1nZCAc0WzFIFsGfUi/kmAxc6cFqDSYuPSMIbs1OVrwITTQM9HVRFJ5JL56qcoFzzT1uVcd2v9jFw8BHlcWtmEI86hp5Dy/zOlK8cUp/rVseRUBqawz6kmAcPLM9l5m8h4V53Iz/2mFJaTCvF8JbsMvPjU/7crbUXart0v4WyE0LnDPcAX95Knj4VUE8HCdNdUP8BDcOXKdPl4uSWbh4LfOV0HDdfipOmu+eIRrDsNPkIT7np/8ZAzVdOd1u8wHIqeXt8VqtgiO50ePeNaGG+uO9rHiKdL71pnIun8jxEKXv2r2HYBzO/mz96vFKoMM5WLk7tQXS9U5kwCu5lk7n6++kdCFWRaTUzm0/5fClWGWTrM/AGhCrJO/ZBQhTPFLwmV7ebgcdttt91222233Xbbbf+H9h+2WEtdHVinLAAAAABJRU5ErkJggg==',
  19536. base64Error: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAJYAAACWCAMAAAAL34HQAAALeGlUWHRYTUw6Y29tLmFkb2JlLnhtcAAAAAAAPD94cGFja2V0IGJlZ2luPSLvu78iIGlkPSJXNU0wTXBDZWhpSHpyZVN6TlRjemtjOWQiPz4gPHg6eG1wbWV0YSB4bWxuczp4PSJhZG9iZTpuczptZXRhLyIgeDp4bXB0az0iQWRvYmUgWE1QIENvcmUgNi4wLWMwMDIgNzkuMTY0NDg4LCAyMDIwLzA3LzEwLTIyOjA2OjUzICAgICAgICAiPiA8cmRmOlJERiB4bWxuczpyZGY9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkvMDIvMjItcmRmLXN5bnRheC1ucyMiPiA8cmRmOkRlc2NyaXB0aW9uIHJkZjphYm91dD0iIiB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iIHhtbG5zOmRjPSJodHRwOi8vcHVybC5vcmcvZGMvZWxlbWVudHMvMS4xLyIgeG1sbnM6eG1wTU09Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9tbS8iIHhtbG5zOnN0RXZ0PSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VFdmVudCMiIHhtbG5zOnN0UmVmPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VSZWYjIiB4bWxuczpwaG90b3Nob3A9Imh0dHA6Ly9ucy5hZG9iZS5jb20vcGhvdG9zaG9wLzEuMC8iIHhtbG5zOnRpZmY9Imh0dHA6Ly9ucy5hZG9iZS5jb20vdGlmZi8xLjAvIiB4bWxuczpleGlmPSJodHRwOi8vbnMuYWRvYmUuY29tL2V4aWYvMS4wLyIgeG1wOkNyZWF0b3JUb29sPSJBZG9iZSBQaG90b3Nob3AgQ0MgMjAxOSAoV2luZG93cykiIHhtcDpDcmVhdGVEYXRlPSIyMDIyLTAyLTIyVDIxOjIxOjQ1KzA4OjAwIiB4bXA6TWV0YWRhdGFEYXRlPSIyMDI0LTAxLTEzVDE5OjEwOjEwKzA4OjAwIiB4bXA6TW9kaWZ5RGF0ZT0iMjAyNC0wMS0xM1QxOToxMDoxMCswODowMCIgZGM6Zm9ybWF0PSJpbWFnZS9wbmciIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6MTQ3NTExNjAtZDY5MC00ZTkzLWFhNGUtNGMwYTViNGU1ZGFjIiB4bXBNTTpEb2N1bWVudElEPSJhZG9iZTpkb2NpZDpwaG90b3Nob3A6YzRiNzlkYWMtZTJmYS1iNzQ0LWIxM2ItOWU1N2VjMDhhM2YwIiB4bXBNTTpPcmlnaW5hbERvY3VtZW50SUQ9InhtcC5kaWQ6ZDA4MDI4MDItMzUyYS04NTRhLTkxYjctNmRlNmQ1MmViM2QwIiBwaG90b3Nob3A6Q29sb3JNb2RlPSIzIiBwaG90b3Nob3A6SUNDUHJvZmlsZT0ic1JHQiBJRUM2MTk2Ni0yLjEiIHRpZmY6T3JpZW50YXRpb249IjEiIHRpZmY6WFJlc29sdXRpb249IjMwMDAwMDAvMTAwMDAiIHRpZmY6WVJlc29sdXRpb249IjMwMDAwMDAvMTAwMDAiIHRpZmY6UmVzb2x1dGlvblVuaXQ9IjIiIGV4aWY6Q29sb3JTcGFjZT0iMSIgZXhpZjpQaXhlbFhEaW1lbnNpb249IjMwMCIgZXhpZjpQaXhlbFlEaW1lbnNpb249IjMwMCI+IDx4bXBNTTpIaXN0b3J5PiA8cmRmOlNlcT4gPHJkZjpsaSBzdEV2dDphY3Rpb249ImNyZWF0ZWQiIHN0RXZ0Omluc3RhbmNlSUQ9InhtcC5paWQ6ZDA4MDI4MDItMzUyYS04NTRhLTkxYjctNmRlNmQ1MmViM2QwIiBzdEV2dDp3aGVuPSIyMDIyLTAyLTIyVDIxOjIxOjQ1KzA4OjAwIiBzdEV2dDpzb2Z0d2FyZUFnZW50PSJBZG9iZSBQaG90b3Nob3AgQ0MgMjAxOSAoV2luZG93cykiLz4gPHJkZjpsaSBzdEV2dDphY3Rpb249InNhdmVkIiBzdEV2dDppbnN0YW5jZUlEPSJ4bXAuaWlkOjQwNjg2NzJkLWY5NDMtOTU0Mi1iMDBiLTVlMDExNmE1NmIzZSIgc3RFdnQ6d2hlbj0iMjAyNC0wMS0xM1QxMDoyNjoxNiswODowMCIgc3RFdnQ6c29mdHdhcmVBZ2VudD0iQWRvYmUgUGhvdG9zaG9wIENDIDIwMTkgKFdpbmRvd3MpIiBzdEV2dDpjaGFuZ2VkPSIvIi8+IDxyZGY6bGkgc3RFdnQ6YWN0aW9uPSJzYXZlZCIgc3RFdnQ6aW5zdGFuY2VJRD0ieG1wLmlpZDpjZjk1NTE1OC04MjFiLTA4NDUtYWJmNS05YTE1NGM1ZTY4NjEiIHN0RXZ0OndoZW49IjIwMjQtMDEtMTNUMTE6MDQ6MDQrMDg6MDAiIHN0RXZ0OnNvZnR3YXJlQWdlbnQ9IkFkb2JlIFBob3Rvc2hvcCBDQyAyMDE5IChXaW5kb3dzKSIgc3RFdnQ6Y2hhbmdlZD0iLyIvPiA8cmRmOmxpIHN0RXZ0OmFjdGlvbj0iY29udmVydGVkIiBzdEV2dDpwYXJhbWV0ZXJzPSJmcm9tIGFwcGxpY2F0aW9uL3ZuZC5hZG9iZS5waG90b3Nob3AgdG8gaW1hZ2UvcG5nIi8+IDxyZGY6bGkgc3RFdnQ6YWN0aW9uPSJkZXJpdmVkIiBzdEV2dDpwYXJhbWV0ZXJzPSJjb252ZXJ0ZWQgZnJvbSBhcHBsaWNhdGlvbi92bmQuYWRvYmUucGhvdG9zaG9wIHRvIGltYWdlL3BuZyIvPiA8cmRmOmxpIHN0RXZ0OmFjdGlvbj0ic2F2ZWQiIHN0RXZ0Omluc3RhbmNlSUQ9InhtcC5paWQ6ZGM1Y2IyNWItZDZlNC0yZjQ2LTgyODQtZmUwOTNlY2M2ZTkxIiBzdEV2dDp3aGVuPSIyMDI0LTAxLTEzVDExOjA0OjA0KzA4OjAwIiBzdEV2dDpzb2Z0d2FyZUFnZW50PSJBZG9iZSBQaG90b3Nob3AgQ0MgMjAxOSAoV2luZG93cykiIHN0RXZ0OmNoYW5nZWQ9Ii8iLz4gPHJkZjpsaSBzdEV2dDphY3Rpb249InNhdmVkIiBzdEV2dDppbnN0YW5jZUlEPSJ4bXAuaWlkOjE0NzUxMTYwLWQ2OTAtNGU5My1hYTRlLTRjMGE1YjRlNWRhYyIgc3RFdnQ6d2hlbj0iMjAyNC0wMS0xM1QxOToxMDoxMCswODowMCIgc3RFdnQ6c29mdHdhcmVBZ2VudD0iQWRvYmUgUGhvdG9zaG9wIDIyLjAgKE1hY2ludG9zaCkiIHN0RXZ0OmNoYW5nZWQ9Ii8iLz4gPC9yZGY6U2VxPiA8L3htcE1NOkhpc3Rvcnk+IDx4bXBNTTpEZXJpdmVkRnJvbSBzdFJlZjppbnN0YW5jZUlEPSJ4bXAuaWlkOmNmOTU1MTU4LTgyMWItMDg0NS1hYmY1LTlhMTU0YzVlNjg2MSIgc3RSZWY6ZG9jdW1lbnRJRD0iYWRvYmU6ZG9jaWQ6cGhvdG9zaG9wOjM2ZGQ4NTQxLWQ0MWEtYmY0Yy1iZjA3LWNmNjZhNjZhMDg2MSIgc3RSZWY6b3JpZ2luYWxEb2N1bWVudElEPSJ4bXAuZGlkOmQwODAyODAyLTM1MmEtODU0YS05MWI3LTZkZTZkNTJlYjNkMCIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/Ph2LDQsAAAAJcEhZcwAACxMAAAsTAQCanBgAAAA5UExURUdwTNra2s7Ozq2tre3t7dPT087OzuPj4+3t7dbW1u/v79bW1vz8/MrKytDQ0Nzc3MPDw/X19bi4uMZQDnEAAAAKdFJOUwBqEPywotz+wzqApqiTAAAHW0lEQVR42u1b25akIAwcbx2UFoj//7HLTQVBRcSZfTDnbM/uTl/KSlEkwf75eeONN95444033njjjTduR9/0/yOsbqoevObL7101tYX1HFs9QFtfZalRP+rpQVgdAFx990ZnT8L6eZItUl99jeGpf1DxdV/VP9fV1f/PFlF1bYHoVFSRC60IyVjrFRnuB8IoxpExSrstsErKHpJw1eqybNLbAQvAYkKjUrjoBgKRqAaeIjG5+qaps6hKcMWmcdSwqAJWBbAgCZZaIYbsqggqqlHNbFFa5yVR4jKvrKEErOEjNCqNSwHrfE8lpLsod/u+cOPPMPBJ+Gz5dM0cXNgclre+pSxhYI1WW5Tf9ENSMIdLCiWs6q9hwQprBVYKFqyPlx4WtoSvrT9lC/wkGt8qlkQooC3hi6sgW3Bb8gtdpSV/za/mn49pC0oYhONbfyd5hzDLFivKFpTS1gKM0we0tQCEncfgQn7Rt+DC/299i1MSRJcBC0r7VviG5KZvwV5WIUobxHyrJKy8VRjXVgFYsPu5kOtbxdhycCDuihziXVLoW7xwEiUmDgd544B46luWLW+nugMLB2BimmC3cxTNxCDg8xFtuUSNqoFsDKzY8psa+XtBNWXr74N6qxwsS5T6VL5robKl10+ZRu5S9qBvUYuJwVHzjwjrE3G33qKh+WXBgmkmCvHYquTvZ8oo7rLFA4PJgYW0MdePIRQIGUPNbSMw5lubJMKtJI6+Wk6cVFMmACO+VVryeL7ZgI8MhwS2fnNPPK0geHBRd11eJSiyL4KjrL2umm1XIpRii1MKB/mU/iCZwF+pt5z3UJ7UiF3nQqadAXC3T3xEW2IyuDBe3yDTe0+A64it2WTyYSGVHymUI/EduvSWKJ80Dtv2NbYSoQxbMkVC7yzNGIWFvDF7gRD79RYrWW/BDGti4wwLtgvO7gWKUZ8Mt94qX8vLJE70+xVNwzDm9ghNM+FX7p/jlZUId2HJD+Tf79hMe3WNrAK/30E+C8/6xOCqbqxE5JNMYrNbnaLUvJAewfCg8zF0Ba/tbviWLvPYfsGFA1PVD8ZdnjlVc/DS/o7LK4NHjOjKKbfCTSCo5XmwKbaZM4jlc9NGEYd9Ijd0QS5ZGaOR2O+DPlGyRb2nXZzgnI1GdFWF+0gh3ifyTRqvzpXI2eElk58FeHziCF5hY+hSMV9Ge/mohUTGuQ4vzHYe8bW5sNdFQ58St22Vcf5zzJbtcGT4iYQ7iz8dFuxoWRYMjAM7KCnypHOTLSqdUwYIFpndOD/6B2FBzNQxYmW/zxYE4j8yLHga1s2Rbm/O5PXtGcuNDIW1dTj5hpjGsO+7z2Kk9NP1JWDlnWKAM4H6zCUNM05KyVPHBclYzUbgjE3N3tP2JWHBmbqD4GLeCs2jhMT13lMVljwcEbetwZgtHUxVQ21ho3fE7inf2s8vzMWq0EWpfOBg5hcDSGwaF2+LaysRIzNFqRgBv2sMhi/Ix0WiW8rBKNBv4ExBI7eorx9ANazsPCb5FkSNH+Reacos+AYxaFzX76KMH65c8ytzZ40YvpFAqtgC/otn1eCmMI5K8yVRQVVwq3aVtU+jJktwjyP7x+BKv8vtoH098vXYSJcrWGJcAW11r8WVRxe5vgcuFbXqwnaEZejS6mrLwYKUg1ch2RJswTFYgMOwoau+AQsSp/FuDhVZi7J402ifgGla/GJIzGLYG5H4rnKMCUydL9wcsmZSuPikR2QmjQbWqaV2ob2RdMvaLEvFlRiXpYeTwqVOtMZF+qi0dS4uEjJKMvWuYK3S0jHZwaq7BylYp/O2uu3q04lNqudLWEJQd/3paTBz12IaLIPtzE5P1AUuW9TB8NVzaG9/TIfV+eXsWeezz6HWlptEbo4SIAeWur/Y/RZC/gmZTiLzUY2j5ct6fjKsFvxqgyQxE9sbmfYtnJMIciEKo6+FL0wziJmtkzspIcUl0PgWrL7VCKP7hl61U4WLeN+7Ieli2vZhmq0VgjDOgIyhJ62sSpDkWNZa1wiB8WoLlxzy29XpGVPgn1ut5VYcGyRLK7OCiJaDYMrAneJUkZWdw0yDgNm5nDowqLc0Kp581FO7QS4pC9S/YRW9xkVdNOj0ZHCp9anEZw3VEK/fopiDrkMObkcdJtT1g6+uzQ60bIdUPztdWZWy53m+v/zFYPOGHO4AZsalmtJNkyHrCAx1RXX7mt5g1L1pDezpkXv8wJwpVRSSaf2c26Y0rrXXxyWBptu/ovdak+VhkqjGBZUdvKygqANKA/MqZ/36kcGwFn90RnWp66ksKuHgitLFY8BU+F2ZvqpxpMY9qR3YwOUJ12fc0KUHVKdswcKXuwetErCnwvMKuXxfc/3RVJ2yFc+iosQd3X+WGSVz1UiuN2J156FyVyHbsOUp3krezaPUT/VxXqdfwvknb/Zgp+idTxTbrkLqYuKreRnhy65Gf4W0NsDoYiqf6uZsvr8V9eo6XWc5+3TVf/3N1TfeeOONN95444033njjjTfeSI1/IeOYOeO4fGAAAAAASUVORK5CYII=',
  19537. base64BackToTop: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMgAAADIBAMAAABfdrOtAAAAElBMVEVRUVH+/v5HcEyZmZlRUVFRUVGm1ByOAAAABnRSTlPMzADMTZAJBBGsAAAEnElEQVR42t2cS27jMAyGf7/2U+QCQeDsbeQCgZDujaC5/1UmkzaJn+JDFGcw3LdfflKibJkkDnxrL7dbg7sNt6+L4O8OYBM+B0ys+QrGkHZG+OEEQ8g6go8Bx1GIGMdpNOQyIG6XdMgnSPtKhLQDGEZFBgYMkhKFtGBb0EIEjDgFRowoBVaMGAWpMedEfxMiZtwpUsgZCqtlkCNUdpVAWigtCCCDFtLwIWeoreZCWiRYYEKGFEjDg+yRZCUH0iLRAgNyToXUNCRZyMqWhGnUN2IPm3wSlwJ7IUspyCBkIQUZhCykIIeQuRTkEDKXAuM9srrtYbrZN7Y98giZSoFd+t1OxmMITG0dcrSFXFchZ1tIvQZpYWxhBbK3hpQrkMEa0iwh5t4a+QvZvDXyF7J5a+Qv5PPW21/I5623v5DPW29/IaO3Xv5Clrw1y1/Ikrdm+Qs5svw83yNnSJ5BQb4F/F7EIEJSnThGBAXxkFQfLOviQUE8JAUPsosHBfGQfDAtHhREQ1JxIV00KIgmrnRI84S0yAd5BAXxxJUck0f6Qnwr9qmr6xF5xLMjcwn/iudIEAdWnyjkEXlQKZiRVzoqRyLbgeUKKR8Q4alY7cSnoxzSf2ggsqehKr6YVpcXpOd7H93f60cKhOd7Re2LteUF4eLqiVS1mr0ge4io6C2+soaFkJ7MuuuQs1yITEp9hwwKISIpzR2iESKSIoT0rLNwuVHQqoSIpAQJpGce60vIUSdEIuUqgPTsJ5QFZK8UIpBS8iG94GFrDjlrhfCl8CG96Llxmle4kEr6vKWBPIVo9kqDQSRk9/3cWoikcCFPAd33v4dIChPyEvLzBA6RlEYWke4JEUnhKXkLeUEKxRHJFfKCQHGucIW8IdZSRkLeEGMpYyEjiK2UsZARxFTKRMgYYillImQMMZQyFTKB2EmZCplAuFLIHT8TMoWwpQwiIVMIUwqpZP5bp5CCvCTiQKr5f5lCQN+tPCBn2ZvVDFJwIDUP0m1BYAfZYRNSsCB7BqTbhoARePIxtZ9tgwWkoJcwCalmv3MBAemtO4R6dah2HaKQqj8Zvp9sQDjvJ21+SPCBHPJDDk6QITekEV7gqCC19CpKAym9IMfckKv4olMBCeIrWwVEfvkshzQekO9r9P1/ALk+IG1eSPCDiCJfyG+FyU+A6ZCa/piZDinpz7LpkCv5gdkAEshP5emQhv7onw6pGeULyZCSUYiRDAmMkpJkCKs4JhFSq8p8hJBSVbAkhARV6ZUQoisik0FqXTmcDHLVFfbJIEFXoiiCNMpiSxGkVJaNiiBBWQArgTTaUl4JpNQWJUsgQVteXQg+AKkLxQWFGKW+5J2+eVp4S168X3CF1CltCKdTJ8lb84YK2bUBO+wZW0Pqv9nk4tKu49N45NJC5dMM5tLW5tOg59Jq6NM06dL+abFXwr/RkuvTXJwae1abtE/Dt0/ruksTvs84AZ/BCC4jHnyGVfiM3VBQFANEXEah+Ax18RlP4zNox2dkkM/wI58xTn8yDCXGYCDV3W5RGSajtXyGhG1jbpbjzpwGt/0MJft8jqC7iUbQ/QZaxdnKqcIftwAAAABJRU5ErkJggg=='
  19538. };
  19539. exports.default = _default;
  19540. /***/ }),
  19541. /* 251 */
  19542. /*!*******************************************************************************************************!*\
  19543. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/z-paging/components/z-paging/js/z-paging-constant.js ***!
  19544. \*******************************************************************************************************/
  19545. /*! no static exports found */
  19546. /***/ (function(module, exports, __webpack_require__) {
  19547. "use strict";
  19548. Object.defineProperty(exports, "__esModule", {
  19549. value: true
  19550. });
  19551. exports.default = void 0;
  19552. // [z-paging]常量
  19553. var _default = {
  19554. // 当前版本号
  19555. version: '2.8.8',
  19556. // 延迟操作的通用时间
  19557. delayTime: 100,
  19558. // 请求失败时候全局emit使用的key
  19559. errorUpdateKey: 'z-paging-error-emit',
  19560. // 全局emit complete的key
  19561. completeUpdateKey: 'z-paging-complete-emit',
  19562. // z-paging缓存的前缀key
  19563. cachePrefixKey: 'z-paging-cache',
  19564. // 虚拟列表中列表index的key
  19565. listCellIndexKey: 'zp_index',
  19566. // 虚拟列表中列表的唯一key
  19567. listCellIndexUniqueKey: 'zp_unique_index'
  19568. };
  19569. exports.default = _default;
  19570. /***/ }),
  19571. /* 252 */
  19572. /*!****************************************************************************************************!*\
  19573. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/z-paging/components/z-paging/js/z-paging-utils.js ***!
  19574. \****************************************************************************************************/
  19575. /*! no static exports found */
  19576. /***/ (function(module, exports, __webpack_require__) {
  19577. "use strict";
  19578. /* WEBPACK VAR INJECTION */(function(uni) {
  19579. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  19580. Object.defineProperty(exports, "__esModule", {
  19581. value: true
  19582. });
  19583. exports.default = void 0;
  19584. var _toConsumableArray2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/toConsumableArray */ 19));
  19585. var _typeof2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/typeof */ 12));
  19586. var _defineProperty2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/defineProperty */ 10));
  19587. var _index = _interopRequireDefault(__webpack_require__(/*! ../config/index */ 253));
  19588. var _zPagingConstant = _interopRequireDefault(__webpack_require__(/*! ./z-paging-constant */ 251));
  19589. function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
  19590. function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { (0, _defineProperty2.default)(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
  19591. var storageKey = 'Z-PAGING-REFRESHER-TIME-STORAGE-KEY';
  19592. var config = null;
  19593. var configLoaded = false;
  19594. var cachedSystemInfo = null;
  19595. var timeoutMap = {};
  19596. // 获取默认配置信息
  19597. function gc(key, defaultValue) {
  19598. // 这里return一个函数以解决在vue3+appvue中,props默认配置读取在main.js之前执行导致uni.$zp全局配置无效的问题。相当于props的default中传入一个带有返回值的函数
  19599. return function () {
  19600. // 处理z-paging全局配置
  19601. _handleDefaultConfig();
  19602. // 如果全局配置不存在,则返回默认值
  19603. if (!config) return defaultValue;
  19604. var value = config[key];
  19605. // 如果全局配置存在但对应的配置项不存在,则返回默认值;反之返回配置项
  19606. return value === undefined ? defaultValue : value;
  19607. };
  19608. }
  19609. // 获取最终的touch位置
  19610. function getTouch(e) {
  19611. var touch = null;
  19612. if (e.touches && e.touches.length) {
  19613. touch = e.touches[0];
  19614. } else if (e.changedTouches && e.changedTouches.length) {
  19615. touch = e.changedTouches[0];
  19616. } else if (e.datail && e.datail != {}) {
  19617. touch = e.datail;
  19618. } else {
  19619. return {
  19620. touchX: 0,
  19621. touchY: 0
  19622. };
  19623. }
  19624. return {
  19625. touchX: touch.clientX,
  19626. touchY: touch.clientY
  19627. };
  19628. }
  19629. // 判断当前手势是否在z-paging内触发
  19630. function getTouchFromZPaging(target) {
  19631. if (target && target.tagName && target.tagName !== 'BODY' && target.tagName !== 'UNI-PAGE-BODY') {
  19632. var classList = target.classList;
  19633. if (classList && classList.contains('z-paging-content')) {
  19634. // 此处额外记录当前z-paging是否是页面滚动、是否滚动到了顶部、是否是聊天记录模式以传给renderjs。避免不同z-paging组件renderjs内部判断数据互相影响导致的各种问题
  19635. return {
  19636. isFromZp: true,
  19637. isPageScroll: classList.contains('z-paging-content-page'),
  19638. isReachedTop: classList.contains('z-paging-reached-top'),
  19639. isUseChatRecordMode: classList.contains('z-paging-use-chat-record-mode')
  19640. };
  19641. } else {
  19642. return getTouchFromZPaging(target.parentNode);
  19643. }
  19644. } else {
  19645. return {
  19646. isFromZp: false
  19647. };
  19648. }
  19649. }
  19650. // 递归获取z-paging所在的parent,如果查找不到则返回null
  19651. function getParent(parent) {
  19652. if (!parent) return null;
  19653. if (parent.$refs.paging) return parent;
  19654. return getParent(parent.$parent);
  19655. }
  19656. // 打印错误信息
  19657. function consoleErr(err) {
  19658. console.error("[z-paging]".concat(err));
  19659. }
  19660. // 延时操作,如果key存在,调用时清除对应key之前的延时操作
  19661. function delay(callback) {
  19662. var ms = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : _zPagingConstant.default.delayTime;
  19663. var key = arguments.length > 2 ? arguments[2] : undefined;
  19664. var timeout = setTimeout(callback, ms);
  19665. ;
  19666. if (!!key) {
  19667. timeoutMap[key] && clearTimeout(timeoutMap[key]);
  19668. timeoutMap[key] = timeout;
  19669. }
  19670. return timeout;
  19671. }
  19672. // 设置下拉刷新时间
  19673. function setRefesrherTime(time, key) {
  19674. var datas = getRefesrherTime() || {};
  19675. datas[key] = time;
  19676. uni.setStorageSync(storageKey, datas);
  19677. }
  19678. // 获取下拉刷新时间
  19679. function getRefesrherTime() {
  19680. return uni.getStorageSync(storageKey);
  19681. }
  19682. // 通过下拉刷新标识key获取下拉刷新时间
  19683. function getRefesrherTimeByKey(key) {
  19684. var datas = getRefesrherTime();
  19685. return datas && datas[key] ? datas[key] : null;
  19686. }
  19687. // 通过下拉刷新标识key获取下拉刷新时间(格式化之后)
  19688. function getRefesrherFormatTimeByKey(key, textMap) {
  19689. var time = getRefesrherTimeByKey(key);
  19690. var timeText = time ? _timeFormat(time, textMap) : textMap.none;
  19691. return "".concat(textMap.title).concat(timeText);
  19692. }
  19693. // 将文本的px或者rpx转为px的值
  19694. function convertToPx(text) {
  19695. var dataType = Object.prototype.toString.call(text);
  19696. if (dataType === '[object Number]') return text;
  19697. var isRpx = false;
  19698. if (text.indexOf('rpx') !== -1 || text.indexOf('upx') !== -1) {
  19699. text = text.replace('rpx', '').replace('upx', '');
  19700. isRpx = true;
  19701. } else if (text.indexOf('px') !== -1) {
  19702. text = text.replace('px', '');
  19703. }
  19704. if (!isNaN(text)) {
  19705. if (isRpx) return Number(rpx2px(text));
  19706. return Number(text);
  19707. }
  19708. return 0;
  19709. }
  19710. // rpx => px,预留的兼容处理
  19711. function rpx2px(rpx) {
  19712. return uni.upx2px(rpx);
  19713. }
  19714. // 同步获取系统信息,兼容不同平台
  19715. function getSystemInfoSync() {
  19716. var useCache = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;
  19717. if (useCache && cachedSystemInfo) {
  19718. return cachedSystemInfo;
  19719. }
  19720. // 目前只用到了deviceInfo、appBaseInfo和windowInfo中的信息,因此仅整合这两个信息数据
  19721. var infoTypes = ['DeviceInfo', 'AppBaseInfo', 'WindowInfo'];
  19722. var _infoTypes$reduce = infoTypes.reduce(function (acc, key) {
  19723. var method = "get".concat(key);
  19724. if (uni[method] && uni.canIUse(method)) {
  19725. acc[key.charAt(0).toLowerCase() + key.slice(1)] = uni[method]();
  19726. }
  19727. return acc;
  19728. }, {}),
  19729. deviceInfo = _infoTypes$reduce.deviceInfo,
  19730. appBaseInfo = _infoTypes$reduce.appBaseInfo,
  19731. windowInfo = _infoTypes$reduce.windowInfo;
  19732. // 如果deviceInfo、appBaseInfo和windowInfo都可以从各自专属的api中获取,则整合它们的数据
  19733. if (deviceInfo && appBaseInfo && windowInfo) {
  19734. cachedSystemInfo = _objectSpread(_objectSpread(_objectSpread({}, deviceInfo), appBaseInfo), windowInfo);
  19735. } else {
  19736. // 使用uni.getSystemInfoSync兜底,确保能获取到最终的系统信息
  19737. cachedSystemInfo = uni.getSystemInfoSync();
  19738. }
  19739. return cachedSystemInfo;
  19740. }
  19741. // 获取当前时间
  19742. function getTime() {
  19743. return new Date().getTime();
  19744. }
  19745. // 获取z-paging实例id,随机生成10位数字+字母
  19746. function getInstanceId() {
  19747. var s = [];
  19748. var hexDigits = "0123456789abcdef";
  19749. for (var i = 0; i < 10; i++) {
  19750. s[i] = hexDigits.substr(Math.floor(Math.random() * 0x10), 1);
  19751. }
  19752. return s.join('') + getTime();
  19753. }
  19754. // 等待一段时间
  19755. function wait(ms) {
  19756. return new Promise(function (resolve) {
  19757. setTimeout(resolve, ms);
  19758. });
  19759. }
  19760. // 是否是promise
  19761. function isPromise(func) {
  19762. return Object.prototype.toString.call(func) === '[object Promise]';
  19763. }
  19764. // 添加单位
  19765. function addUnit(value, unit) {
  19766. if (Object.prototype.toString.call(value) === '[object String]') {
  19767. var tempValue = value;
  19768. tempValue = tempValue.replace('rpx', '').replace('upx', '').replace('px', '');
  19769. if (value.indexOf('rpx') === -1 && value.indexOf('upx') === -1 && value.indexOf('px') !== -1) {
  19770. tempValue = parseFloat(tempValue) * 2;
  19771. }
  19772. value = tempValue;
  19773. }
  19774. return unit === 'rpx' ? value + 'rpx' : value / 2 + 'px';
  19775. }
  19776. // 深拷贝
  19777. function deepCopy(obj) {
  19778. if ((0, _typeof2.default)(obj) !== 'object' || obj === null) return obj;
  19779. var newObj = Array.isArray(obj) ? [] : {};
  19780. for (var key in obj) {
  19781. if (obj.hasOwnProperty(key)) {
  19782. newObj[key] = deepCopy(obj[key]);
  19783. }
  19784. }
  19785. return newObj;
  19786. }
  19787. // 对短时间内重复插入的数据进行整合,并一次性插入
  19788. function useBufferedInsert(fn) {
  19789. var delay = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 50;
  19790. var buffer = [];
  19791. var timer = null;
  19792. var latestArgs = [];
  19793. return function insertBuffered(data) {
  19794. var _buffer;
  19795. var newData = Object.prototype.toString.call(data) !== '[object Array]' ? [data] : data;
  19796. (_buffer = buffer).push.apply(_buffer, (0, _toConsumableArray2.default)(newData));
  19797. for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
  19798. args[_key - 1] = arguments[_key];
  19799. }
  19800. latestArgs = args;
  19801. if (!timer) {
  19802. timer = setTimeout(function () {
  19803. fn.apply(void 0, [buffer.length === 1 ? buffer[0] : buffer].concat((0, _toConsumableArray2.default)(latestArgs)));
  19804. buffer = [];
  19805. timer = null;
  19806. }, buffer.length === 1 ? 10 : delay);
  19807. }
  19808. };
  19809. }
  19810. // ------------------ 私有方法 ------------------------
  19811. // 处理全局配置
  19812. function _handleDefaultConfig() {
  19813. // 确保只加载一次全局配置
  19814. if (configLoaded) return;
  19815. // 优先从config.js中读取
  19816. if (_index.default && Object.keys(_index.default).length) {
  19817. config = _index.default;
  19818. }
  19819. // 如果在config.js中读取不到,则尝试到uni.$zp读取
  19820. if (!config && uni.$zp) {
  19821. config = uni.$zp.config;
  19822. }
  19823. // 将config中的短横线写法全部转为驼峰写法,使得读取配置时可以直接通过key去匹配,而非读取每个配置时候再去转,减少不必要的性能开支
  19824. config = config ? Object.keys(config).reduce(function (result, key) {
  19825. result[_toCamelCase(key)] = config[key];
  19826. return result;
  19827. }, {}) : null;
  19828. configLoaded = true;
  19829. }
  19830. // 时间格式化
  19831. function _timeFormat(time, textMap) {
  19832. var date = new Date(time);
  19833. var currentDate = new Date();
  19834. // 设置time对应的天,去除时分秒,使得可以直接比较日期
  19835. var dateDay = new Date(time).setHours(0, 0, 0, 0);
  19836. // 设置当前的天,去除时分秒,使得可以直接比较日期
  19837. var currentDateDay = new Date().setHours(0, 0, 0, 0);
  19838. var disTime = dateDay - currentDateDay;
  19839. var dayStr = '';
  19840. var timeStr = _dateTimeFormat(date);
  19841. if (disTime === 0) {
  19842. dayStr = textMap.today;
  19843. } else if (disTime === -86400000) {
  19844. dayStr = textMap.yesterday;
  19845. } else {
  19846. dayStr = _dateDayFormat(date, date.getFullYear() !== currentDate.getFullYear());
  19847. }
  19848. return "".concat(dayStr, " ").concat(timeStr);
  19849. }
  19850. // date格式化为年月日
  19851. function _dateDayFormat(date) {
  19852. var showYear = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
  19853. var year = date.getFullYear();
  19854. var month = date.getMonth() + 1;
  19855. var day = date.getDate();
  19856. return showYear ? "".concat(year, "-").concat(_fullZeroToTwo(month), "-").concat(_fullZeroToTwo(day)) : "".concat(_fullZeroToTwo(month), "-").concat(_fullZeroToTwo(day));
  19857. }
  19858. // data格式化为时分
  19859. function _dateTimeFormat(date) {
  19860. var hour = date.getHours();
  19861. var minute = date.getMinutes();
  19862. return "".concat(_fullZeroToTwo(hour), ":").concat(_fullZeroToTwo(minute));
  19863. }
  19864. // 不满2位在前面填充0
  19865. function _fullZeroToTwo(str) {
  19866. str = str.toString();
  19867. return str.length === 1 ? '0' + str : str;
  19868. }
  19869. // 驼峰转短横线
  19870. function _toKebab(value) {
  19871. return value.replace(/([A-Z])/g, "-$1").toLowerCase();
  19872. }
  19873. // 短横线转驼峰
  19874. function _toCamelCase(value) {
  19875. return value.replace(/-([a-z])/g, function (_, group1) {
  19876. return group1.toUpperCase();
  19877. });
  19878. }
  19879. var _default = {
  19880. gc: gc,
  19881. setRefesrherTime: setRefesrherTime,
  19882. getRefesrherFormatTimeByKey: getRefesrherFormatTimeByKey,
  19883. getTouch: getTouch,
  19884. getTouchFromZPaging: getTouchFromZPaging,
  19885. getParent: getParent,
  19886. convertToPx: convertToPx,
  19887. getTime: getTime,
  19888. getInstanceId: getInstanceId,
  19889. consoleErr: consoleErr,
  19890. delay: delay,
  19891. wait: wait,
  19892. isPromise: isPromise,
  19893. addUnit: addUnit,
  19894. deepCopy: deepCopy,
  19895. rpx2px: rpx2px,
  19896. getSystemInfoSync: getSystemInfoSync,
  19897. useBufferedInsert: useBufferedInsert
  19898. };
  19899. exports.default = _default;
  19900. /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./node_modules/@dcloudio/uni-mp-toutiao/dist/index.js */ 1)["default"]))
  19901. /***/ }),
  19902. /* 253 */
  19903. /*!***********************************************************************************************!*\
  19904. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/z-paging/components/z-paging/config/index.js ***!
  19905. \***********************************************************************************************/
  19906. /*! no static exports found */
  19907. /***/ (function(module, exports, __webpack_require__) {
  19908. "use strict";
  19909. Object.defineProperty(exports, "__esModule", {
  19910. value: true
  19911. });
  19912. exports.default = void 0;
  19913. // z-paging全局配置文件,注意避免更新时此文件被覆盖,若被覆盖,可在此文件中右键->点击本地历史记录,找回覆盖前的配置
  19914. var _default = {};
  19915. exports.default = _default;
  19916. /***/ }),
  19917. /* 254 */
  19918. /*!***********************************************************************************************************!*\
  19919. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/z-paging/components/z-paging/js/modules/common-layout.js ***!
  19920. \***********************************************************************************************************/
  19921. /*! no static exports found */
  19922. /***/ (function(module, exports, __webpack_require__) {
  19923. "use strict";
  19924. /* WEBPACK VAR INJECTION */(function(uni) {
  19925. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  19926. Object.defineProperty(exports, "__esModule", {
  19927. value: true
  19928. });
  19929. exports.default = void 0;
  19930. var _zPagingUtils = _interopRequireDefault(__webpack_require__(/*! .././z-paging-utils */ 252));
  19931. // [z-paging]通用布局相关模块
  19932. var _default = {
  19933. data: function data() {
  19934. return {
  19935. systemInfo: null,
  19936. cssSafeAreaInsetBottom: -1,
  19937. isReadyDestroy: false
  19938. };
  19939. },
  19940. computed: {
  19941. // 顶部可用距离
  19942. windowTop: function windowTop() {
  19943. if (!this.systemInfo) return 0;
  19944. // 暂时修复vue3中隐藏系统导航栏后windowTop获取不正确的问题,具体bug详见https://ask.dcloud.net.cn/question/141634
  19945. // 感谢litangyu!!https://github.com/SmileZXLee/uni-z-paging/issues/25
  19946. return this.systemInfo.windowTop || 0;
  19947. },
  19948. // 底部安全区域高度
  19949. safeAreaBottom: function safeAreaBottom() {
  19950. if (!this.systemInfo) return 0;
  19951. var safeAreaBottom = 0;
  19952. safeAreaBottom = Math.max(this.cssSafeAreaInsetBottom, 0);
  19953. return safeAreaBottom;
  19954. },
  19955. // 是否是比较老的webview,在一些老的webview中,需要进行一些特殊处理
  19956. isOldWebView: function isOldWebView() {
  19957. try {
  19958. var systemInfos = _zPagingUtils.default.getSystemInfoSync(true).system.split(' ');
  19959. var deviceType = systemInfos[0];
  19960. var version = parseInt(systemInfos[1]);
  19961. if (deviceType === 'iOS' && version <= 10 || deviceType === 'Android' && version <= 6) {
  19962. return true;
  19963. }
  19964. } catch (e) {
  19965. return false;
  19966. }
  19967. return false;
  19968. },
  19969. // 当前组件的$slots,兼容不同平台
  19970. zSlots: function zSlots() {
  19971. return this.$scopedSlots || this.$slots;
  19972. return this.$slots;
  19973. }
  19974. },
  19975. beforeDestroy: function beforeDestroy() {
  19976. this.isReadyDestroy = true;
  19977. },
  19978. methods: {
  19979. // 更新fixed模式下z-paging的布局
  19980. updateFixedLayout: function updateFixedLayout() {
  19981. var _this = this;
  19982. this.fixed && this.$nextTick(function () {
  19983. _this.systemInfo = _zPagingUtils.default.getSystemInfoSync();
  19984. });
  19985. },
  19986. // 获取节点尺寸
  19987. _getNodeClientRect: function _getNodeClientRect(select) {
  19988. var inDom = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
  19989. var scrollOffset = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
  19990. if (this.isReadyDestroy) {
  19991. return Promise.resolve(false);
  19992. }
  19993. ;
  19994. // nvue中获取节点信息
  19995. // vue中获取节点信息
  19996. /*
  19997. inDom可能是true、false,也可能是具体的dom节点
  19998. 如果inDom不为false,则使用uni.createSelectorQuery().in()进行查询,如果inDom为true,则in中的是this,否则in中的为具体的dom
  19999. 如果inDom为false,则使用uni.createSelectorQuery()进行查询
  20000. */
  20001. var res = !!inDom ? uni.createSelectorQuery().in(inDom === true ? this : inDom) : uni.createSelectorQuery();
  20002. scrollOffset ? res.select(select).scrollOffset() : res.select(select).boundingClientRect();
  20003. return new Promise(function (resolve, reject) {
  20004. res.exec(function (data) {
  20005. resolve(data && data != '' && data != undefined && data.length ? data : false);
  20006. });
  20007. });
  20008. },
  20009. // 获取slot="left"和slot="right"宽度并且更新布局
  20010. _updateLeftAndRightWidth: function _updateLeftAndRightWidth(targetStyle, parentNodePrefix) {
  20011. var _this2 = this;
  20012. this.$nextTick(function () {
  20013. var delayTime = 0;
  20014. setTimeout(function () {
  20015. ['left', 'right'].map(function (position) {
  20016. _this2._getNodeClientRect(".".concat(parentNodePrefix, "-").concat(position)).then(function (res) {
  20017. _this2.$set(targetStyle, position, res ? res[0].width + 'px' : '0px');
  20018. });
  20019. });
  20020. }, delayTime);
  20021. });
  20022. },
  20023. // 通过获取css设置的底部安全区域占位view高度设置bottom距离(直接通过systemInfo在部分平台上无法获取到底部安全区域)
  20024. _getCssSafeAreaInsetBottom: function _getCssSafeAreaInsetBottom(success) {
  20025. var _this3 = this;
  20026. this._getNodeClientRect('.zp-safe-area-inset-bottom').then(function (res) {
  20027. _this3.cssSafeAreaInsetBottom = res ? res[0].height : -1;
  20028. res && success && success();
  20029. });
  20030. },
  20031. // 同步获取系统信息,兼容不同平台(供z-paging-swiper使用)
  20032. _getSystemInfoSync: function _getSystemInfoSync() {
  20033. var useCache = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;
  20034. return _zPagingUtils.default.getSystemInfoSync(useCache);
  20035. }
  20036. }
  20037. };
  20038. exports.default = _default;
  20039. /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./node_modules/@dcloudio/uni-mp-toutiao/dist/index.js */ 1)["default"]))
  20040. /***/ }),
  20041. /* 255 */
  20042. /*!*********************************************************************************************************!*\
  20043. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/z-paging/components/z-paging/js/modules/data-handle.js ***!
  20044. \*********************************************************************************************************/
  20045. /*! no static exports found */
  20046. /***/ (function(module, exports, __webpack_require__) {
  20047. "use strict";
  20048. /* WEBPACK VAR INJECTION */(function(uni) {
  20049. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  20050. Object.defineProperty(exports, "__esModule", {
  20051. value: true
  20052. });
  20053. exports.default = void 0;
  20054. var _slicedToArray2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/slicedToArray */ 4));
  20055. var _toConsumableArray2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/toConsumableArray */ 19));
  20056. var _zPagingUtils = _interopRequireDefault(__webpack_require__(/*! .././z-paging-utils */ 252));
  20057. var _zPagingConstant = _interopRequireDefault(__webpack_require__(/*! .././z-paging-constant */ 251));
  20058. var _zPagingEnum = _interopRequireDefault(__webpack_require__(/*! .././z-paging-enum */ 256));
  20059. var _zPagingInterceptor = _interopRequireDefault(__webpack_require__(/*! ../z-paging-interceptor */ 257));
  20060. // [z-paging]数据处理模块
  20061. var _default2 = {
  20062. props: {
  20063. // 自定义初始的pageNo,默认为1
  20064. defaultPageNo: {
  20065. type: Number,
  20066. default: _zPagingUtils.default.gc('defaultPageNo', 1),
  20067. observer: function observer(newVal) {
  20068. this.pageNo = newVal;
  20069. }
  20070. },
  20071. // 自定义pageSize,默认为10
  20072. defaultPageSize: {
  20073. type: Number,
  20074. default: _zPagingUtils.default.gc('defaultPageSize', 10),
  20075. validator: function validator(value) {
  20076. if (value <= 0) _zPagingUtils.default.consoleErr('default-page-size必须大于0!');
  20077. return value > 0;
  20078. }
  20079. },
  20080. // 为保证数据一致,设置当前tab切换时的标识key,并在complete中传递相同key,若二者不一致,则complete将不会生效
  20081. dataKey: {
  20082. type: [Number, String, Object],
  20083. default: _zPagingUtils.default.gc('dataKey', null)
  20084. },
  20085. // 使用缓存,若开启将自动缓存第一页的数据,默认为否。请注意,因考虑到切换tab时不同tab数据不同的情况,默认仅会缓存组件首次加载时第一次请求到的数据,后续的下拉刷新操作不会更新缓存。
  20086. useCache: {
  20087. type: Boolean,
  20088. default: _zPagingUtils.default.gc('useCache', false)
  20089. },
  20090. // 使用缓存时缓存的key,用于区分不同列表的缓存数据,useCache为true时必须设置,否则缓存无效
  20091. cacheKey: {
  20092. type: String,
  20093. default: _zPagingUtils.default.gc('cacheKey', null)
  20094. },
  20095. // 缓存模式,默认仅会缓存组件首次加载时第一次请求到的数据,可设置为always,即代表总是缓存,每次列表刷新(下拉刷新、调用reload等)都会更新缓存
  20096. cacheMode: {
  20097. type: String,
  20098. default: _zPagingUtils.default.gc('cacheMode', _zPagingEnum.default.CacheMode.Default)
  20099. },
  20100. // 自动注入的list名,可自动修改父view(包含ref="paging")中对应name的list值
  20101. autowireListName: {
  20102. type: String,
  20103. default: _zPagingUtils.default.gc('autowireListName', '')
  20104. },
  20105. // 自动注入的query名,可自动调用父view(包含ref="paging")中的query方法
  20106. autowireQueryName: {
  20107. type: String,
  20108. default: _zPagingUtils.default.gc('autowireQueryName', '')
  20109. },
  20110. // 获取分页数据Function,功能与@query类似。若设置了fetch则@query将不再触发
  20111. fetch: {
  20112. type: Function,
  20113. default: null
  20114. },
  20115. // fetch的附加参数,fetch配置后有效
  20116. fetchParams: {
  20117. type: Object,
  20118. default: _zPagingUtils.default.gc('fetchParams', null)
  20119. },
  20120. // z-paging mounted后自动调用reload方法(mounted后自动调用接口),默认为是
  20121. auto: {
  20122. type: Boolean,
  20123. default: _zPagingUtils.default.gc('auto', true)
  20124. },
  20125. // 用户下拉刷新时是否触发reload方法,默认为是
  20126. reloadWhenRefresh: {
  20127. type: Boolean,
  20128. default: _zPagingUtils.default.gc('reloadWhenRefresh', true)
  20129. },
  20130. // reload时自动滚动到顶部,默认为是
  20131. autoScrollToTopWhenReload: {
  20132. type: Boolean,
  20133. default: _zPagingUtils.default.gc('autoScrollToTopWhenReload', true)
  20134. },
  20135. // reload时立即自动清空原list,默认为是,若立即自动清空,则在reload之后、请求回调之前页面是空白的
  20136. autoCleanListWhenReload: {
  20137. type: Boolean,
  20138. default: _zPagingUtils.default.gc('autoCleanListWhenReload', true)
  20139. },
  20140. // 列表刷新时自动显示下拉刷新view,默认为否
  20141. showRefresherWhenReload: {
  20142. type: Boolean,
  20143. default: _zPagingUtils.default.gc('showRefresherWhenReload', false)
  20144. },
  20145. // 列表刷新时自动显示加载更多view,且为加载中状态,默认为否
  20146. showLoadingMoreWhenReload: {
  20147. type: Boolean,
  20148. default: _zPagingUtils.default.gc('showLoadingMoreWhenReload', false)
  20149. },
  20150. // 组件created时立即触发reload(可解决一些情况下先看到页面再看到loading的问题),auto为true时有效。为否时将在mounted+nextTick后触发reload,默认为否
  20151. createdReload: {
  20152. type: Boolean,
  20153. default: _zPagingUtils.default.gc('createdReload', false)
  20154. },
  20155. // 本地分页时上拉加载更多延迟时间,单位为毫秒,默认200毫秒
  20156. localPagingLoadingTime: {
  20157. type: [Number, String],
  20158. default: _zPagingUtils.default.gc('localPagingLoadingTime', 200)
  20159. },
  20160. // 自动拼接complete中传过来的数组(使用聊天记录模式时无效)
  20161. concat: {
  20162. type: Boolean,
  20163. default: _zPagingUtils.default.gc('concat', true)
  20164. },
  20165. // 请求失败是否触发reject,默认为是
  20166. callNetworkReject: {
  20167. type: Boolean,
  20168. default: _zPagingUtils.default.gc('callNetworkReject', true)
  20169. },
  20170. // 父组件v-model所绑定的list的值
  20171. value: {
  20172. type: Array,
  20173. default: function _default() {
  20174. return [];
  20175. }
  20176. }
  20177. },
  20178. data: function data() {
  20179. return {
  20180. currentData: [],
  20181. totalData: [],
  20182. realTotalData: [],
  20183. totalLocalPagingList: [],
  20184. dataPromiseResultMap: {
  20185. reload: null,
  20186. complete: null,
  20187. localPaging: null
  20188. },
  20189. isSettingCacheList: false,
  20190. pageNo: 1,
  20191. currentRefreshPageSize: 0,
  20192. isLocalPaging: false,
  20193. isAddedData: false,
  20194. isTotalChangeFromAddData: false,
  20195. privateConcat: true,
  20196. myParentQuery: -1,
  20197. firstPageLoaded: false,
  20198. pagingLoaded: false,
  20199. loaded: false,
  20200. isUserReload: true,
  20201. fromEmptyViewReload: false,
  20202. queryFrom: '',
  20203. listRendering: false,
  20204. isHandlingRefreshToPage: false,
  20205. isFirstPageAndNoMore: false,
  20206. totalDataChangeThrow: true,
  20207. addDataFromTopBufferedInsert: _zPagingUtils.default.useBufferedInsert(this._addDataFromTop)
  20208. };
  20209. },
  20210. computed: {
  20211. pageSize: function pageSize() {
  20212. return this.defaultPageSize;
  20213. },
  20214. finalConcat: function finalConcat() {
  20215. return this.concat && this.privateConcat;
  20216. },
  20217. finalUseCache: function finalUseCache() {
  20218. if (this.useCache && !this.cacheKey) {
  20219. _zPagingUtils.default.consoleErr('use-cache为true时,必须设置cache-key,否则缓存无效!');
  20220. }
  20221. return this.useCache && !!this.cacheKey;
  20222. },
  20223. finalCacheKey: function finalCacheKey() {
  20224. return this.cacheKey ? "".concat(_zPagingConstant.default.cachePrefixKey, "-").concat(this.cacheKey) : null;
  20225. },
  20226. isFirstPage: function isFirstPage() {
  20227. return this.pageNo === this.defaultPageNo;
  20228. }
  20229. },
  20230. watch: {
  20231. totalData: function totalData(newVal, oldVal) {
  20232. // 触发totalData改变事件时是否触发emit列表更新事件,如果是从缓存中设置则必须触发,否则根据totalDataChangeThrow的规则判断
  20233. var eventThrow = this.isSettingCacheList ? true : this.totalDataChangeThrow;
  20234. this._totalDataChange(newVal, oldVal, eventThrow);
  20235. this.totalDataChangeThrow = true;
  20236. },
  20237. currentData: function currentData(newVal, oldVal) {
  20238. this._currentDataChange(newVal, oldVal);
  20239. },
  20240. useChatRecordMode: function useChatRecordMode(newVal, oldVal) {
  20241. if (newVal) {
  20242. this.nLoadingMoreFixedHeight = false;
  20243. }
  20244. },
  20245. value: {
  20246. handler: function handler(newVal) {
  20247. // 当v-model绑定的数据源被更改时,此时数据源改变不emit input事件,避免循环调用
  20248. if (newVal !== this.totalData) {
  20249. this.totalDataChangeThrow = false;
  20250. this.totalData = newVal;
  20251. }
  20252. },
  20253. immediate: true
  20254. }
  20255. },
  20256. methods: {
  20257. // 请求结束(成功或者失败)调用此方法,将请求的结果传递给z-paging处理,第一个参数为请求结果数组,第二个参数为是否成功(默认为是)
  20258. complete: function complete(data) {
  20259. var success = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
  20260. this.customNoMore = -1;
  20261. return this.addData(data, success);
  20262. },
  20263. //【保证数据一致】请求结束(成功或者失败)调用此方法,将请求的结果传递给z-paging处理,第一个参数为请求结果数组,第二个参数为dataKey,需与:data-key绑定的一致,第三个参数为是否成功(默认为是)
  20264. completeByKey: function completeByKey(data) {
  20265. var dataKey = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
  20266. var success = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : true;
  20267. if (dataKey !== null && this.dataKey !== null && dataKey !== this.dataKey) {
  20268. this.isFirstPage && this.endRefresh();
  20269. return new Promise(function (resolve) {
  20270. return resolve();
  20271. });
  20272. }
  20273. this.customNoMore = -1;
  20274. return this.addData(data, success);
  20275. },
  20276. //【通过total判断是否有更多数据】请求结束(成功或者失败)调用此方法,将请求的结果传递给z-paging处理,第一个参数为请求结果数组,第二个参数为total(列表总数),第三个参数为是否成功(默认为是)
  20277. completeByTotal: function completeByTotal(data, total) {
  20278. var _this = this;
  20279. var success = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : true;
  20280. if (total == 'undefined') {
  20281. this.customNoMore = -1;
  20282. } else {
  20283. var dataTypeRes = this._checkDataType(data, success, false);
  20284. data = dataTypeRes.data;
  20285. success = dataTypeRes.success;
  20286. if (total >= 0 && success) {
  20287. return new Promise(function (resolve, reject) {
  20288. _this.$nextTick(function () {
  20289. var nomore = false;
  20290. var realTotalDataCount = _this.pageNo == _this.defaultPageNo ? 0 : _this.realTotalData.length;
  20291. var dataLength = _this.privateConcat ? data.length : 0;
  20292. var exceedCount = realTotalDataCount + dataLength - total;
  20293. // 没有更多数据了
  20294. if (exceedCount >= 0) {
  20295. nomore = true;
  20296. // 仅截取total内部分的数据
  20297. exceedCount = _this.defaultPageSize - exceedCount;
  20298. if (_this.privateConcat && exceedCount > 0 && exceedCount < data.length) {
  20299. data = data.splice(0, exceedCount);
  20300. }
  20301. }
  20302. _this.completeByNoMore(data, nomore, success).then(function (res) {
  20303. return resolve(res);
  20304. }).catch(function () {
  20305. return reject();
  20306. });
  20307. });
  20308. });
  20309. }
  20310. }
  20311. return this.addData(data, success);
  20312. },
  20313. //【自行判断是否有更多数据】请求结束(成功或者失败)调用此方法,将请求的结果传递给z-paging处理,第一个参数为请求结果数组,第二个参数为是否没有更多数据,第三个参数为是否成功(默认是是)
  20314. completeByNoMore: function completeByNoMore(data, nomore) {
  20315. var success = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : true;
  20316. if (nomore != 'undefined') {
  20317. this.customNoMore = nomore == true ? 1 : 0;
  20318. }
  20319. return this.addData(data, success);
  20320. },
  20321. // 请求结束且请求失败时调用,支持传入请求失败原因
  20322. completeByError: function completeByError(errorMsg) {
  20323. this.customerEmptyViewErrorText = errorMsg;
  20324. return this.complete(false);
  20325. },
  20326. // 与上方complete方法功能一致,新版本中设置服务端回调数组请使用complete方法
  20327. addData: function addData(data) {
  20328. var _this2 = this;
  20329. var success = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
  20330. if (!this.fromCompleteEmit) {
  20331. this.disabledCompleteEmit = true;
  20332. this.fromCompleteEmit = false;
  20333. }
  20334. var currentTimeStamp = _zPagingUtils.default.getTime();
  20335. var disTime = currentTimeStamp - this.requestTimeStamp;
  20336. var minDelay = this.minDelay;
  20337. if (this.isFirstPage && this.finalShowRefresherWhenReload) {
  20338. minDelay = Math.max(400, minDelay);
  20339. }
  20340. var addDataDalay = this.requestTimeStamp > 0 && disTime < minDelay ? minDelay - disTime : 0;
  20341. this.$nextTick(function () {
  20342. _zPagingUtils.default.delay(function () {
  20343. _this2._addData(data, success, false);
  20344. }, _this2.delay > 0 ? _this2.delay : addDataDalay);
  20345. });
  20346. return new Promise(function (resolve, reject) {
  20347. _this2.dataPromiseResultMap.complete = {
  20348. resolve: resolve,
  20349. reject: reject
  20350. };
  20351. });
  20352. },
  20353. // 从顶部添加数据,不会影响分页的pageNo和pageSize
  20354. addDataFromTop: function addDataFromTop(data) {
  20355. var toTop = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
  20356. var toTopWithAnimate = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : true;
  20357. // 如果使用了虚拟列表,则需要对短时间内的大量数据进行整合然后一次性添加,避免设置虚拟列表cellIndex时候key冲突的问题,否则正常调用
  20358. (this.finalUseVirtualList ? this.addDataFromTopBufferedInsert : this._addDataFromTop)(data, toTop, toTopWithAnimate);
  20359. },
  20360. // 重新设置列表数据,调用此方法不会影响pageNo和pageSize,也不会触发请求。适用场景:当需要删除列表中某一项时,将删除对应项后的数组通过此方法传递给z-paging。(当出现类似的需要修改列表数组的场景时,请使用此方法,请勿直接修改page中:list.sync绑定的数组)
  20361. resetTotalData: function resetTotalData(data) {
  20362. this.isTotalChangeFromAddData = true;
  20363. data = Object.prototype.toString.call(data) !== '[object Array]' ? [data] : data;
  20364. this.totalData = data;
  20365. },
  20366. // 设置本地分页数据,请求结束(成功或者失败)调用此方法,将请求的结果传递给z-paging作分页处理(若调用了此方法,则上拉加载更多时内部会自动分页,不会触发@query所绑定的事件)
  20367. setLocalPaging: function setLocalPaging(data) {
  20368. var _this3 = this;
  20369. var success = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
  20370. this.isLocalPaging = true;
  20371. this.$nextTick(function () {
  20372. _this3._addData(data, success, true);
  20373. });
  20374. return new Promise(function (resolve, reject) {
  20375. _this3.dataPromiseResultMap.localPaging = {
  20376. resolve: resolve,
  20377. reject: reject
  20378. };
  20379. });
  20380. },
  20381. // 重新加载分页数据,pageNo会恢复为默认值,相当于下拉刷新的效果(animate为true时会展示下拉刷新动画,默认为false)
  20382. reload: function reload() {
  20383. var _this4 = this;
  20384. var animate = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : this.showRefresherWhenReload;
  20385. if (animate) {
  20386. this.privateShowRefresherWhenReload = animate;
  20387. this.isUserPullDown = true;
  20388. }
  20389. if (!this.showLoadingMoreWhenReload) {
  20390. this.listRendering = true;
  20391. }
  20392. this.$nextTick(function () {
  20393. _this4._preReload(animate, false);
  20394. });
  20395. return new Promise(function (resolve, reject) {
  20396. _this4.dataPromiseResultMap.reload = {
  20397. resolve: resolve,
  20398. reject: reject
  20399. };
  20400. });
  20401. },
  20402. // 刷新列表数据,pageNo和pageSize不会重置,列表数据会重新从服务端获取。必须保证@query绑定的方法中的pageNo和pageSize和传给服务端的一致
  20403. refresh: function refresh() {
  20404. return this._handleRefreshWithDisPageNo(this.pageNo - this.defaultPageNo + 1);
  20405. },
  20406. // 刷新列表数据至指定页,例如pageNo=5时则代表刷新列表至第5页,此时pageNo会变为5,列表会展示前5页的数据。必须保证@query绑定的方法中的pageNo和pageSize和传给服务端的一致
  20407. refreshToPage: function refreshToPage(pageNo) {
  20408. this.isHandlingRefreshToPage = true;
  20409. return this._handleRefreshWithDisPageNo(pageNo + this.defaultPageNo - 1);
  20410. },
  20411. // 手动更新列表缓存数据,将自动截取v-model绑定的list中的前pageSize条覆盖缓存,请确保在list数据更新到预期结果后再调用此方法
  20412. updateCache: function updateCache() {
  20413. if (this.finalUseCache && this.totalData.length) {
  20414. this._saveLocalCache(this.totalData.slice(0, Math.min(this.totalData.length, this.pageSize)));
  20415. }
  20416. },
  20417. // 清空分页数据
  20418. clean: function clean() {
  20419. this._reload(true);
  20420. this._addData([], true, false);
  20421. },
  20422. // 清空分页数据
  20423. clear: function clear() {
  20424. this.clean();
  20425. },
  20426. // reload之前的一些处理
  20427. _preReload: function _preReload() {
  20428. var _this5 = this;
  20429. var animate = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : this.showRefresherWhenReload;
  20430. var isFromMounted = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
  20431. var retryCount = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0;
  20432. var showRefresher = this.finalRefresherEnabled && this.useCustomRefresher;
  20433. // 如果获取slot="refresher"高度失败,则不触发reload,直到获取slot="refresher"高度成功
  20434. if (this.customRefresherHeight === -1 && showRefresher) {
  20435. _zPagingUtils.default.delay(function () {
  20436. retryCount++;
  20437. // 如果重试次数是10的倍数(也就是每500毫秒),尝试重新获取一下slot="refresher"高度
  20438. // 此举是为了解决在某些特殊情况下,z-paging组件mounted了,但是未展示在用户面前,(比如在tabbar页面中,未切换到对应tabbar但是通过代码让z-paging展示了,此时控制台会报Error: Not Found:Page,因为这时候去获取dom节点信息获取不到)
  20439. // 当用户在某个时刻让此z-paging展示在面前时,即可顺利获取到slot="refresher"高度,递归停止
  20440. if (retryCount % 10 === 0) {
  20441. _this5._updateCustomRefresherHeight();
  20442. }
  20443. _this5._preReload(animate, isFromMounted, retryCount);
  20444. }, _zPagingConstant.default.delayTime / 2);
  20445. return;
  20446. }
  20447. this.isUserReload = true;
  20448. this.loadingType = _zPagingEnum.default.LoadingType.Refresher;
  20449. if (animate) {
  20450. this.privateShowRefresherWhenReload = animate;
  20451. if (this.useCustomRefresher) {
  20452. this._doRefresherRefreshAnimate();
  20453. } else {
  20454. this.refresherTriggered = true;
  20455. }
  20456. } else {
  20457. this._refresherEnd(false, false, false, false);
  20458. }
  20459. this._reload(false, isFromMounted);
  20460. },
  20461. // 重新加载分页数据
  20462. _reload: function _reload() {
  20463. var isClean = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;
  20464. var isFromMounted = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
  20465. var isUserPullDown = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
  20466. this.isAddedData = false;
  20467. this.insideOfPaging = -1;
  20468. this.cacheScrollNodeHeight = -1;
  20469. this.pageNo = this.defaultPageNo;
  20470. this._cleanRefresherEndTimeout();
  20471. !this.privateShowRefresherWhenReload && !isClean && this._startLoading(true);
  20472. this.firstPageLoaded = true;
  20473. this.isTotalChangeFromAddData = false;
  20474. if (!this.isSettingCacheList) {
  20475. this.totalData = [];
  20476. }
  20477. if (!isClean) {
  20478. this._emitQuery(this.pageNo, this.defaultPageSize, isUserPullDown ? _zPagingEnum.default.QueryFrom.UserPullDown : _zPagingEnum.default.QueryFrom.Reload);
  20479. var delay = 0;
  20480. delay = 5;
  20481. _zPagingUtils.default.delay(this._callMyParentQuery, delay);
  20482. if (!isFromMounted && this.autoScrollToTopWhenReload) {
  20483. var checkedNRefresherLoading = true;
  20484. checkedNRefresherLoading && this._scrollToTop(false);
  20485. }
  20486. }
  20487. },
  20488. // 处理服务端返回的数组
  20489. _addData: function _addData(data, success, isLocal) {
  20490. var _this6 = this;
  20491. this.isAddedData = true;
  20492. this.fromEmptyViewReload = false;
  20493. this.isTotalChangeFromAddData = true;
  20494. this.refresherTriggered = false;
  20495. this._endSystemLoadingAndRefresh();
  20496. var tempIsUserPullDown = this.isUserPullDown;
  20497. if (this.showRefresherUpdateTime && this.isFirstPage) {
  20498. _zPagingUtils.default.setRefesrherTime(_zPagingUtils.default.getTime(), this.refresherUpdateTimeKey);
  20499. this.$refs.refresh && this.$refs.refresh.updateTime();
  20500. }
  20501. if (!isLocal && tempIsUserPullDown && this.isFirstPage) {
  20502. this.isUserPullDown = false;
  20503. }
  20504. this.listRendering = true;
  20505. this.$nextTick(function () {
  20506. _zPagingUtils.default.delay(function () {
  20507. return _this6.listRendering = false;
  20508. });
  20509. });
  20510. var dataTypeRes = this._checkDataType(data, success, isLocal);
  20511. data = dataTypeRes.data;
  20512. success = dataTypeRes.success;
  20513. var delayTime = _zPagingConstant.default.delayTime;
  20514. if (this.useChatRecordMode) delayTime = 0;
  20515. this.loadingForNow = false;
  20516. _zPagingUtils.default.delay(function () {
  20517. _this6.pagingLoaded = true;
  20518. _this6.$nextTick(function () {
  20519. !isLocal && _this6._refresherEnd(delayTime > 0, true, tempIsUserPullDown);
  20520. });
  20521. });
  20522. if (this.isFirstPage) {
  20523. this.isLoadFailed = !success;
  20524. this.$emit('isLoadFailedChange', this.isLoadFailed);
  20525. if (this.finalUseCache && success && (this.cacheMode === _zPagingEnum.default.CacheMode.Always ? true : this.isSettingCacheList)) {
  20526. this._saveLocalCache(data);
  20527. }
  20528. }
  20529. this.isSettingCacheList = false;
  20530. if (success) {
  20531. if (!(this.privateConcat === false && !this.isHandlingRefreshToPage && this.loadingStatus === _zPagingEnum.default.More.NoMore)) {
  20532. this.loadingStatus = _zPagingEnum.default.More.Default;
  20533. }
  20534. if (isLocal) {
  20535. // 如果当前是本地分页,则必然是由setLocalPaging方法触发,此时直接本地加载第一页数据即可。后续本地分页加载更多方法由滚动到底部加载更多事件处理
  20536. this.totalLocalPagingList = data;
  20537. var localPageNo = this.defaultPageNo;
  20538. var localPageSize = this.queryFrom !== _zPagingEnum.default.QueryFrom.Refresh ? this.defaultPageSize : this.currentRefreshPageSize;
  20539. this._localPagingQueryList(localPageNo, localPageSize, 0, function (res) {
  20540. _zPagingUtils.default.delay(function () {
  20541. _this6.completeByTotal(res, _this6.totalLocalPagingList.length);
  20542. ;
  20543. }, 0);
  20544. });
  20545. } else {
  20546. // 如果当前不是本地分页,则按照正常分页逻辑进行数据处理&emit数据
  20547. var dataChangeDelayTime = 0;
  20548. _zPagingUtils.default.delay(function () {
  20549. _this6._currentDataChange(data, _this6.currentData);
  20550. _this6._callDataPromise(true, _this6.totalData);
  20551. }, dataChangeDelayTime);
  20552. }
  20553. if (this.isHandlingRefreshToPage) {
  20554. this.isHandlingRefreshToPage = false;
  20555. this.pageNo = this.defaultPageNo + Math.ceil(data.length / this.pageSize) - 1;
  20556. if (data.length % this.pageSize !== 0) {
  20557. this.customNoMore = 1;
  20558. }
  20559. }
  20560. } else {
  20561. this._currentDataChange(data, this.currentData);
  20562. this._callDataPromise(false);
  20563. this.loadingStatus = _zPagingEnum.default.More.Fail;
  20564. this.isHandlingRefreshToPage = false;
  20565. if (this.loadingType === _zPagingEnum.default.LoadingType.LoadMore) {
  20566. this.pageNo--;
  20567. }
  20568. }
  20569. },
  20570. // 所有数据改变时调用
  20571. _totalDataChange: function _totalDataChange(newVal, oldVal) {
  20572. var _this7 = this;
  20573. var eventThrow = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : true;
  20574. if ((!this.isUserReload || !this.autoCleanListWhenReload) && this.firstPageLoaded && !newVal.length && oldVal.length) {
  20575. return;
  20576. }
  20577. this._doCheckScrollViewShouldFullHeight(newVal);
  20578. if (!this.realTotalData.length && !newVal.length) {
  20579. eventThrow = false;
  20580. }
  20581. this.realTotalData = newVal;
  20582. // emit列表更新事件
  20583. if (eventThrow) {
  20584. this.$emit('input', newVal);
  20585. this.$emit('update:list', newVal);
  20586. this.$emit('listChange', newVal);
  20587. this._callMyParentList(newVal);
  20588. }
  20589. this.firstPageLoaded = false;
  20590. this.isTotalChangeFromAddData = false;
  20591. this.$nextTick(function () {
  20592. _zPagingUtils.default.delay(function () {
  20593. // emit z-paging内容区域高度改变事件
  20594. _this7._getNodeClientRect('.zp-paging-container-content').then(function (res) {
  20595. res && _this7.$emit('contentHeightChanged', res[0].height);
  20596. });
  20597. }, _zPagingConstant.default.delayTime * (_this7.isIos ? 1 : 3));
  20598. });
  20599. },
  20600. // 当前数据改变时调用
  20601. _currentDataChange: function _currentDataChange(newVal, oldVal) {
  20602. newVal = (0, _toConsumableArray2.default)(newVal);
  20603. this.finalUseVirtualList && this._setCellIndex(newVal, 'bottom');
  20604. if (this.isFirstPage && this.finalConcat) {
  20605. this.totalData = [];
  20606. }
  20607. // customNoMore:-1代表交由z-paging自行判断;1代表没有更多了;0代表还有更多数据
  20608. if (this.customNoMore !== -1) {
  20609. // 如果customNoMore等于1 或者 customNoMore不是0并且新增数组长度为0(也就是不是明确的还有更多数据并且新增的数组长度为0),则没有更多数据了
  20610. if (this.customNoMore === 1 || this.customNoMore !== 0 && !newVal.length) {
  20611. this.loadingStatus = _zPagingEnum.default.More.NoMore;
  20612. }
  20613. } else {
  20614. // 如果新增的数据数组长度为0 或者 新增的数组长度小于默认的pageSize,则没有更多数据了
  20615. if (!newVal.length || newVal.length && newVal.length < this.defaultPageSize) {
  20616. this.loadingStatus = _zPagingEnum.default.More.NoMore;
  20617. }
  20618. }
  20619. if (!this.totalData.length) {
  20620. this.totalData = newVal;
  20621. } else {
  20622. if (this.finalConcat) {
  20623. var currentScrollTop = this.oldScrollTop;
  20624. this.totalData = [].concat((0, _toConsumableArray2.default)(this.totalData), (0, _toConsumableArray2.default)(newVal));
  20625. // 此处是为了解决在微信小程序中,在某些情况下滚动到底部加载更多后滚动位置直接变为最底部的问题,因此需要通过代码强制滚动回加载更多前的位置
  20626. } else {
  20627. this.totalData = newVal;
  20628. }
  20629. }
  20630. this.privateConcat = true;
  20631. },
  20632. // 根据pageNo处理refresh操作
  20633. _handleRefreshWithDisPageNo: function _handleRefreshWithDisPageNo(pageNo) {
  20634. var _this8 = this;
  20635. if (!this.isHandlingRefreshToPage && !this.realTotalData.length) return this.reload();
  20636. if (pageNo >= 1) {
  20637. this.loading = true;
  20638. this.privateConcat = false;
  20639. var totalPageSize = pageNo * this.pageSize;
  20640. this.currentRefreshPageSize = totalPageSize;
  20641. // 如果调用refresh时是本地分页,则在组件内部自己处理分页逻辑,不emit query相关事件
  20642. if (this.isLocalPaging && this.isHandlingRefreshToPage) {
  20643. this._localPagingQueryList(this.defaultPageNo, totalPageSize, 0, function (res) {
  20644. _this8.complete(res);
  20645. });
  20646. } else {
  20647. // emit query相关事件
  20648. this._emitQuery(this.defaultPageNo, totalPageSize, _zPagingEnum.default.QueryFrom.Refresh);
  20649. this._callMyParentQuery(this.defaultPageNo, totalPageSize);
  20650. }
  20651. }
  20652. return new Promise(function (resolve, reject) {
  20653. _this8.dataPromiseResultMap.reload = {
  20654. resolve: resolve,
  20655. reject: reject
  20656. };
  20657. });
  20658. },
  20659. // 本地分页请求
  20660. _localPagingQueryList: function _localPagingQueryList(pageNo, pageSize, localPagingLoadingTime, callback) {
  20661. pageNo = Math.max(1, pageNo);
  20662. pageSize = Math.max(1, pageSize);
  20663. var totalPagingList = (0, _toConsumableArray2.default)(this.totalLocalPagingList);
  20664. var pageNoIndex = (pageNo - 1) * pageSize;
  20665. var finalPageNoIndex = Math.min(totalPagingList.length, pageNoIndex + pageSize);
  20666. var resultPagingList = totalPagingList.splice(pageNoIndex, finalPageNoIndex - pageNoIndex);
  20667. _zPagingUtils.default.delay(function () {
  20668. return callback(resultPagingList);
  20669. }, localPagingLoadingTime);
  20670. },
  20671. // 从顶部添加数据,不会影响分页的pageNo和pageSize
  20672. _addDataFromTop: function _addDataFromTop(data) {
  20673. var _this9 = this;
  20674. var toTop = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
  20675. var toTopWithAnimate = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : true;
  20676. // 数据是否拼接到顶部,如果是聊天记录模式并且列表没有倒置,则应该拼接在底部
  20677. var addFromTop = !this.isChatRecordModeAndNotInversion;
  20678. data = Object.prototype.toString.call(data) !== '[object Array]' ? [data] : addFromTop ? data.reverse() : data;
  20679. this.finalUseVirtualList && this._setCellIndex(data, 'top');
  20680. this.totalData = addFromTop ? [].concat((0, _toConsumableArray2.default)(data), (0, _toConsumableArray2.default)(this.totalData)) : [].concat((0, _toConsumableArray2.default)(this.totalData), (0, _toConsumableArray2.default)(data));
  20681. if (toTop) {
  20682. _zPagingUtils.default.delay(function () {
  20683. return _this9.useChatRecordMode ? _this9.scrollToBottom(toTopWithAnimate) : _this9.scrollToTop(toTopWithAnimate);
  20684. });
  20685. }
  20686. },
  20687. // 存储列表缓存数据
  20688. _saveLocalCache: function _saveLocalCache(data) {
  20689. uni.setStorageSync(this.finalCacheKey, data);
  20690. },
  20691. // 通过缓存数据填充列表数据
  20692. _setListByLocalCache: function _setListByLocalCache() {
  20693. this.totalData = uni.getStorageSync(this.finalCacheKey) || [];
  20694. this.isSettingCacheList = true;
  20695. },
  20696. // 修改父view的list
  20697. _callMyParentList: function _callMyParentList(newVal) {
  20698. if (this.autowireListName.length) {
  20699. var myParent = _zPagingUtils.default.getParent(this.$parent);
  20700. if (myParent && myParent[this.autowireListName]) {
  20701. myParent[this.autowireListName] = newVal;
  20702. }
  20703. }
  20704. },
  20705. // 调用父view的query
  20706. _callMyParentQuery: function _callMyParentQuery() {
  20707. var customPageNo = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 0;
  20708. var customPageSize = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
  20709. if (this.autowireQueryName) {
  20710. if (this.myParentQuery === -1) {
  20711. var myParent = _zPagingUtils.default.getParent(this.$parent);
  20712. if (myParent && myParent[this.autowireQueryName]) {
  20713. this.myParentQuery = myParent[this.autowireQueryName];
  20714. }
  20715. }
  20716. if (this.myParentQuery !== -1) {
  20717. customPageSize > 0 ? this.myParentQuery(customPageNo, customPageSize) : this.myParentQuery(this.pageNo, this.defaultPageSize);
  20718. }
  20719. }
  20720. },
  20721. // emit query事件
  20722. _emitQuery: function _emitQuery(pageNo, pageSize, from) {
  20723. var _this10 = this;
  20724. this.queryFrom = from;
  20725. this.requestTimeStamp = _zPagingUtils.default.getTime();
  20726. var _this$realTotalData$s = this.realTotalData.slice(-1),
  20727. _this$realTotalData$s2 = (0, _slicedToArray2.default)(_this$realTotalData$s, 1),
  20728. lastItem = _this$realTotalData$s2[0];
  20729. if (this.fetch) {
  20730. var fetchParams = _zPagingInterceptor.default._handleFetchParams({
  20731. pageNo: pageNo,
  20732. pageSize: pageSize,
  20733. from: from,
  20734. lastItem: lastItem || null
  20735. }, this.fetchParams);
  20736. var fetchResult = this.fetch(fetchParams);
  20737. if (!_zPagingInterceptor.default._handleFetchResult(fetchResult, this, fetchParams)) {
  20738. _zPagingUtils.default.isPromise(fetchResult) ? fetchResult.then(function (res) {
  20739. _this10.complete(res);
  20740. }).catch(function (err) {
  20741. _this10.complete(false);
  20742. }) : this.complete(fetchResult);
  20743. }
  20744. } else {
  20745. this.$emit.apply(this, ['query'].concat((0, _toConsumableArray2.default)(_zPagingInterceptor.default._handleQuery(pageNo, pageSize, from, lastItem || null))));
  20746. }
  20747. },
  20748. // 触发数据改变promise
  20749. _callDataPromise: function _callDataPromise(success, totalList) {
  20750. for (var key in this.dataPromiseResultMap) {
  20751. var obj = this.dataPromiseResultMap[key];
  20752. if (!obj) continue;
  20753. success ? obj.resolve({
  20754. totalList: totalList,
  20755. noMore: this.loadingStatus === _zPagingEnum.default.More.NoMore
  20756. }) : this.callNetworkReject && obj.reject("z-paging-".concat(key, "-error"));
  20757. }
  20758. },
  20759. // 检查complete data的类型
  20760. _checkDataType: function _checkDataType(data, success, isLocal) {
  20761. var dataType = Object.prototype.toString.call(data);
  20762. if (dataType === '[object Boolean]') {
  20763. success = data;
  20764. data = [];
  20765. } else if (dataType !== '[object Array]') {
  20766. data = [];
  20767. if (dataType !== '[object Undefined]' && dataType !== '[object Null]') {
  20768. _zPagingUtils.default.consoleErr("".concat(isLocal ? 'setLocalPaging' : 'complete', "\u53C2\u6570\u7C7B\u578B\u4E0D\u6B63\u786E\uFF0C\u7B2C\u4E00\u4E2A\u53C2\u6570\u7C7B\u578B\u5FC5\u987B\u4E3AArray!"));
  20769. }
  20770. }
  20771. return {
  20772. data: data,
  20773. success: success
  20774. };
  20775. }
  20776. }
  20777. };
  20778. exports.default = _default2;
  20779. /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./node_modules/@dcloudio/uni-mp-toutiao/dist/index.js */ 1)["default"]))
  20780. /***/ }),
  20781. /* 256 */
  20782. /*!***************************************************************************************************!*\
  20783. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/z-paging/components/z-paging/js/z-paging-enum.js ***!
  20784. \***************************************************************************************************/
  20785. /*! no static exports found */
  20786. /***/ (function(module, exports, __webpack_require__) {
  20787. "use strict";
  20788. Object.defineProperty(exports, "__esModule", {
  20789. value: true
  20790. });
  20791. exports.default = void 0;
  20792. // [z-paging]枚举
  20793. var _default = {
  20794. // 当前加载类型 refresher:下拉刷新 load-more:上拉加载更多
  20795. LoadingType: {
  20796. Refresher: 'refresher',
  20797. LoadMore: 'load-more'
  20798. },
  20799. // 下拉刷新状态 default:默认状态 release-to-refresh:松手立即刷新 loading:刷新中 complete:刷新结束 go-f2:松手进入二楼
  20800. Refresher: {
  20801. Default: 'default',
  20802. ReleaseToRefresh: 'release-to-refresh',
  20803. Loading: 'loading',
  20804. Complete: 'complete',
  20805. GoF2: 'go-f2'
  20806. },
  20807. // 底部加载更多状态 default:默认状态 loading:加载中 no-more:没有更多数据 fail:加载失败
  20808. More: {
  20809. Default: 'default',
  20810. Loading: 'loading',
  20811. NoMore: 'no-more',
  20812. Fail: 'fail'
  20813. },
  20814. // @query触发来源 user-pull-down:用户主动下拉刷新 reload:通过reload触发 refresh:通过refresh触发 load-more:通过滚动到底部加载更多或点击底部加载更多触发
  20815. QueryFrom: {
  20816. UserPullDown: 'user-pull-down',
  20817. Reload: 'reload',
  20818. Refresh: 'refresh',
  20819. LoadMore: 'load-more'
  20820. },
  20821. // 虚拟列表cell高度模式
  20822. CellHeightMode: {
  20823. // 固定高度
  20824. Fixed: 'fixed',
  20825. // 动态高度
  20826. Dynamic: 'dynamic'
  20827. },
  20828. // 列表缓存模式
  20829. CacheMode: {
  20830. // 默认模式,只会缓存一次
  20831. Default: 'default',
  20832. // 总是缓存,每次列表刷新(下拉刷新、调用reload等)都会更新缓存
  20833. Always: 'always'
  20834. }
  20835. };
  20836. exports.default = _default;
  20837. /***/ }),
  20838. /* 257 */
  20839. /*!**********************************************************************************************************!*\
  20840. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/z-paging/components/z-paging/js/z-paging-interceptor.js ***!
  20841. \**********************************************************************************************************/
  20842. /*! no static exports found */
  20843. /***/ (function(module, exports, __webpack_require__) {
  20844. "use strict";
  20845. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  20846. Object.defineProperty(exports, "__esModule", {
  20847. value: true
  20848. });
  20849. exports.default = void 0;
  20850. var _defineProperty2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/defineProperty */ 10));
  20851. function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
  20852. function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { (0, _defineProperty2.default)(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
  20853. // [z-paging]拦截器
  20854. var queryKey = 'Query';
  20855. var fetchParamsKey = 'FetchParams';
  20856. var fetchResultKey = 'FetchResult';
  20857. var language2LocalKey = 'Language2Local';
  20858. // 拦截&处理@query事件
  20859. function handleQuery(callback) {
  20860. _addHandleByKey(queryKey, callback);
  20861. return this;
  20862. }
  20863. // 拦截&处理@query事件(私有,请勿调用)
  20864. function _handleQuery(pageNo, pageSize, from, lastItem) {
  20865. var callback = _getHandleByKey(queryKey);
  20866. return callback ? callback(pageNo, pageSize, from, lastItem) : [pageNo, pageSize, from];
  20867. }
  20868. // 拦截&处理:fetch参数
  20869. function handleFetchParams(callback) {
  20870. _addHandleByKey(fetchParamsKey, callback);
  20871. return this;
  20872. }
  20873. // 拦截&处理:fetch参数(私有,请勿调用)
  20874. function _handleFetchParams(parmas, extraParams) {
  20875. var callback = _getHandleByKey(fetchParamsKey);
  20876. return callback ? callback(parmas, extraParams || {}) : _objectSpread({
  20877. pageNo: parmas.pageNo,
  20878. pageSize: parmas.pageSize
  20879. }, extraParams || {});
  20880. }
  20881. // 拦截&处理:fetch结果
  20882. function handleFetchResult(callback) {
  20883. _addHandleByKey(fetchResultKey, callback);
  20884. return this;
  20885. }
  20886. // 拦截&处理:fetch结果(私有,请勿调用)
  20887. function _handleFetchResult(result, paging, params) {
  20888. var callback = _getHandleByKey(fetchResultKey);
  20889. callback && callback(result, paging, params);
  20890. return callback ? true : false;
  20891. }
  20892. // 拦截&处理系统language转i18n local
  20893. function handleLanguage2Local(callback) {
  20894. _addHandleByKey(language2LocalKey, callback);
  20895. return this;
  20896. }
  20897. // 拦截&处理系统language转i18n local(私有,请勿调用)
  20898. function _handleLanguage2Local(language, local) {
  20899. var callback = _getHandleByKey(language2LocalKey);
  20900. return callback ? callback(language, local) : local;
  20901. }
  20902. // 获取当前app对象
  20903. function _getApp() {
  20904. return getApp();
  20905. }
  20906. // 是否可以访问globalData
  20907. function _hasGlobalData() {
  20908. return _getApp() && _getApp().globalData;
  20909. }
  20910. // 添加处理函数
  20911. function _addHandleByKey(key, callback) {
  20912. try {
  20913. setTimeout(function () {
  20914. if (_hasGlobalData()) {
  20915. _getApp().globalData["zp_handle".concat(key, "Callback")] = callback;
  20916. }
  20917. }, 1);
  20918. } catch (_) {}
  20919. }
  20920. // 获取处理回调函数
  20921. function _getHandleByKey(key) {
  20922. return _hasGlobalData() ? _getApp().globalData["zp_handle".concat(key, "Callback")] : null;
  20923. }
  20924. var _default = {
  20925. handleQuery: handleQuery,
  20926. _handleQuery: _handleQuery,
  20927. handleFetchParams: handleFetchParams,
  20928. _handleFetchParams: _handleFetchParams,
  20929. handleFetchResult: handleFetchResult,
  20930. _handleFetchResult: _handleFetchResult,
  20931. handleLanguage2Local: handleLanguage2Local,
  20932. _handleLanguage2Local: _handleLanguage2Local
  20933. };
  20934. exports.default = _default;
  20935. /***/ }),
  20936. /* 258 */
  20937. /*!**************************************************************************************************!*\
  20938. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/z-paging/components/z-paging/js/modules/i18n.js ***!
  20939. \**************************************************************************************************/
  20940. /*! no static exports found */
  20941. /***/ (function(module, exports, __webpack_require__) {
  20942. "use strict";
  20943. /* WEBPACK VAR INJECTION */(function(uni) {
  20944. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  20945. Object.defineProperty(exports, "__esModule", {
  20946. value: true
  20947. });
  20948. exports.default = void 0;
  20949. var _uniI18n = __webpack_require__(/*! @dcloudio/uni-i18n */ 23);
  20950. var _index = _interopRequireDefault(__webpack_require__(/*! ../../i18n/index.js */ 259));
  20951. var _zPagingUtils = _interopRequireDefault(__webpack_require__(/*! .././z-paging-utils */ 252));
  20952. var _zPagingConstant = _interopRequireDefault(__webpack_require__(/*! .././z-paging-constant */ 251));
  20953. var _zPagingInterceptor = _interopRequireDefault(__webpack_require__(/*! ../z-paging-interceptor */ 257));
  20954. // [z-paging]i18n模块
  20955. var _initVueI18n = (0, _uniI18n.initVueI18n)(_index.default),
  20956. t = _initVueI18n.t;
  20957. var _default = {
  20958. computed: {
  20959. finalLanguage: function finalLanguage() {
  20960. try {
  20961. var local = uni.getLocale();
  20962. var language = this.systemInfo.appLanguage;
  20963. return local === 'auto' ? _zPagingInterceptor.default._handleLanguage2Local(language, this._language2Local(language)) : local;
  20964. } catch (e) {
  20965. // 如果获取系统本地语言异常,则默认返回中文,uni.getLocale在部分低版本HX或者cli中可能报找不到的问题
  20966. return 'zh-Hans';
  20967. }
  20968. },
  20969. // 最终的下拉刷新默认状态的文字
  20970. finalRefresherDefaultText: function finalRefresherDefaultText() {
  20971. return this._getI18nText('zp.refresher.default', this.refresherDefaultText);
  20972. },
  20973. // 最终的下拉刷新下拉中的文字
  20974. finalRefresherPullingText: function finalRefresherPullingText() {
  20975. return this._getI18nText('zp.refresher.pulling', this.refresherPullingText);
  20976. },
  20977. // 最终的下拉刷新中文字
  20978. finalRefresherRefreshingText: function finalRefresherRefreshingText() {
  20979. return this._getI18nText('zp.refresher.refreshing', this.refresherRefreshingText);
  20980. },
  20981. // 最终的下拉刷新完成文字
  20982. finalRefresherCompleteText: function finalRefresherCompleteText() {
  20983. return this._getI18nText('zp.refresher.complete', this.refresherCompleteText);
  20984. },
  20985. // 最终的下拉刷新上次更新时间文字
  20986. finalRefresherUpdateTimeTextMap: function finalRefresherUpdateTimeTextMap() {
  20987. return {
  20988. title: t('zp.refresherUpdateTime.title'),
  20989. none: t('zp.refresherUpdateTime.none'),
  20990. today: t('zp.refresherUpdateTime.today'),
  20991. yesterday: t('zp.refresherUpdateTime.yesterday')
  20992. };
  20993. },
  20994. // 最终的继续下拉进入二楼文字
  20995. finalRefresherGoF2Text: function finalRefresherGoF2Text() {
  20996. return this._getI18nText('zp.refresher.f2', this.refresherGoF2Text);
  20997. },
  20998. // 最终的底部加载更多默认状态文字
  20999. finalLoadingMoreDefaultText: function finalLoadingMoreDefaultText() {
  21000. return this._getI18nText('zp.loadingMore.default', this.loadingMoreDefaultText);
  21001. },
  21002. // 最终的底部加载更多加载中文字
  21003. finalLoadingMoreLoadingText: function finalLoadingMoreLoadingText() {
  21004. return this._getI18nText('zp.loadingMore.loading', this.loadingMoreLoadingText);
  21005. },
  21006. // 最终的底部加载更多没有更多数据文字
  21007. finalLoadingMoreNoMoreText: function finalLoadingMoreNoMoreText() {
  21008. return this._getI18nText('zp.loadingMore.noMore', this.loadingMoreNoMoreText);
  21009. },
  21010. // 最终的底部加载更多加载失败文字
  21011. finalLoadingMoreFailText: function finalLoadingMoreFailText() {
  21012. return this._getI18nText('zp.loadingMore.fail', this.loadingMoreFailText);
  21013. },
  21014. // 最终的空数据图title
  21015. finalEmptyViewText: function finalEmptyViewText() {
  21016. return this.isLoadFailed ? this.finalEmptyViewErrorText : this._getI18nText('zp.emptyView.title', this.emptyViewText);
  21017. },
  21018. // 最终的空数据图reload title
  21019. finalEmptyViewReloadText: function finalEmptyViewReloadText() {
  21020. return this._getI18nText('zp.emptyView.reload', this.emptyViewReloadText);
  21021. },
  21022. // 最终的空数据图加载失败文字
  21023. finalEmptyViewErrorText: function finalEmptyViewErrorText() {
  21024. return this.customerEmptyViewErrorText || this._getI18nText('zp.emptyView.error', this.emptyViewErrorText);
  21025. },
  21026. // 最终的系统loading title
  21027. finalSystemLoadingText: function finalSystemLoadingText() {
  21028. return this._getI18nText('zp.systemLoading.title', this.systemLoadingText);
  21029. }
  21030. },
  21031. methods: {
  21032. // 获取当前z-paging的语言
  21033. getLanguage: function getLanguage() {
  21034. return this.finalLanguage;
  21035. },
  21036. // 获取国际化转换后的文本
  21037. _getI18nText: function _getI18nText(key, value) {
  21038. var dataType = Object.prototype.toString.call(value);
  21039. if (dataType === '[object Object]') {
  21040. var nextValue = value[this.finalLanguage];
  21041. if (nextValue) return nextValue;
  21042. } else if (dataType === '[object String]') {
  21043. return value;
  21044. }
  21045. return t(key);
  21046. },
  21047. // 系统language转i18n local
  21048. _language2Local: function _language2Local(language) {
  21049. var formatedLanguage = language.toLowerCase().replace(new RegExp('_', ''), '-');
  21050. if (formatedLanguage.indexOf('zh') !== -1) {
  21051. if (formatedLanguage === 'zh' || formatedLanguage === 'zh-cn' || formatedLanguage.indexOf('zh-hans') !== -1) {
  21052. return 'zh-Hans';
  21053. }
  21054. return 'zh-Hant';
  21055. }
  21056. if (formatedLanguage.indexOf('en') !== -1) return 'en';
  21057. return language;
  21058. }
  21059. }
  21060. };
  21061. exports.default = _default;
  21062. /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./node_modules/@dcloudio/uni-mp-toutiao/dist/index.js */ 1)["default"]))
  21063. /***/ }),
  21064. /* 259 */
  21065. /*!*********************************************************************************************!*\
  21066. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/z-paging/components/z-paging/i18n/index.js ***!
  21067. \*********************************************************************************************/
  21068. /*! no static exports found */
  21069. /***/ (function(module, exports, __webpack_require__) {
  21070. "use strict";
  21071. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  21072. Object.defineProperty(exports, "__esModule", {
  21073. value: true
  21074. });
  21075. exports.default = void 0;
  21076. var _en = _interopRequireDefault(__webpack_require__(/*! ./en.json */ 260));
  21077. var _zhHans = _interopRequireDefault(__webpack_require__(/*! ./zh-Hans.json */ 261));
  21078. var _zhHant = _interopRequireDefault(__webpack_require__(/*! ./zh-Hant.json */ 262));
  21079. var _default = {
  21080. en: _en.default,
  21081. 'zh-Hans': _zhHans.default,
  21082. 'zh-Hant': _zhHant.default
  21083. };
  21084. exports.default = _default;
  21085. /***/ }),
  21086. /* 260 */
  21087. /*!********************************************************************************************!*\
  21088. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/z-paging/components/z-paging/i18n/en.json ***!
  21089. \********************************************************************************************/
  21090. /*! exports provided: zp.refresher.default, zp.refresher.pulling, zp.refresher.refreshing, zp.refresher.complete, zp.refresher.f2, zp.loadingMore.default, zp.loadingMore.loading, zp.loadingMore.noMore, zp.loadingMore.fail, zp.emptyView.title, zp.emptyView.reload, zp.emptyView.error, zp.refresherUpdateTime.title, zp.refresherUpdateTime.none, zp.refresherUpdateTime.today, zp.refresherUpdateTime.yesterday, zp.systemLoading.title, default */
  21091. /***/ (function(module) {
  21092. module.exports = JSON.parse("{\"zp.refresher.default\":\"Pull down to refresh\",\"zp.refresher.pulling\":\"Release to refresh\",\"zp.refresher.refreshing\":\"Refreshing...\",\"zp.refresher.complete\":\"Refresh succeeded\",\"zp.refresher.f2\":\"Refresh to enter 2f\",\"zp.loadingMore.default\":\"Click to load more\",\"zp.loadingMore.loading\":\"Loading...\",\"zp.loadingMore.noMore\":\"No more data\",\"zp.loadingMore.fail\":\"Load failed,click to reload\",\"zp.emptyView.title\":\"No data\",\"zp.emptyView.reload\":\"Reload\",\"zp.emptyView.error\":\"Sorry,load failed\",\"zp.refresherUpdateTime.title\":\"Last update: \",\"zp.refresherUpdateTime.none\":\"None\",\"zp.refresherUpdateTime.today\":\"Today\",\"zp.refresherUpdateTime.yesterday\":\"Yesterday\",\"zp.systemLoading.title\":\"Loading...\"}");
  21093. /***/ }),
  21094. /* 261 */
  21095. /*!*************************************************************************************************!*\
  21096. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/z-paging/components/z-paging/i18n/zh-Hans.json ***!
  21097. \*************************************************************************************************/
  21098. /*! exports provided: zp.refresher.default, zp.refresher.pulling, zp.refresher.refreshing, zp.refresher.complete, zp.refresher.f2, zp.loadingMore.default, zp.loadingMore.loading, zp.loadingMore.noMore, zp.loadingMore.fail, zp.emptyView.title, zp.emptyView.reload, zp.emptyView.error, zp.refresherUpdateTime.title, zp.refresherUpdateTime.none, zp.refresherUpdateTime.today, zp.refresherUpdateTime.yesterday, zp.systemLoading.title, default */
  21099. /***/ (function(module) {
  21100. module.exports = JSON.parse("{\"zp.refresher.default\":\"继续下拉刷新\",\"zp.refresher.pulling\":\"松开立即刷新\",\"zp.refresher.refreshing\":\"正在刷新...\",\"zp.refresher.complete\":\"刷新成功\",\"zp.refresher.f2\":\"松手进入二楼\",\"zp.loadingMore.default\":\"点击加载更多\",\"zp.loadingMore.loading\":\"正在加载...\",\"zp.loadingMore.noMore\":\"没有更多了\",\"zp.loadingMore.fail\":\"加载失败,点击重新加载\",\"zp.emptyView.title\":\"没有数据哦~\",\"zp.emptyView.reload\":\"重新加载\",\"zp.emptyView.error\":\"很抱歉,加载失败\",\"zp.refresherUpdateTime.title\":\"最后更新:\",\"zp.refresherUpdateTime.none\":\"无\",\"zp.refresherUpdateTime.today\":\"今天\",\"zp.refresherUpdateTime.yesterday\":\"昨天\",\"zp.systemLoading.title\":\"加载中...\"}");
  21101. /***/ }),
  21102. /* 262 */
  21103. /*!*************************************************************************************************!*\
  21104. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/z-paging/components/z-paging/i18n/zh-Hant.json ***!
  21105. \*************************************************************************************************/
  21106. /*! exports provided: zp.refresher.default, zp.refresher.pulling, zp.refresher.refreshing, zp.refresher.complete, zp.refresher.f2, zp.loadingMore.default, zp.loadingMore.loading, zp.loadingMore.noMore, zp.loadingMore.fail, zp.emptyView.title, zp.emptyView.reload, zp.emptyView.error, zp.refresherUpdateTime.title, zp.refresherUpdateTime.none, zp.refresherUpdateTime.today, zp.refresherUpdateTime.yesterday, zp.systemLoading.title, default */
  21107. /***/ (function(module) {
  21108. module.exports = JSON.parse("{\"zp.refresher.default\":\"繼續下拉重繪\",\"zp.refresher.pulling\":\"鬆開立即重繪\",\"zp.refresher.refreshing\":\"正在重繪...\",\"zp.refresher.complete\":\"重繪成功\",\"zp.refresher.f2\":\"鬆手進入二樓\",\"zp.loadingMore.default\":\"點擊加載更多\",\"zp.loadingMore.loading\":\"正在加載...\",\"zp.loadingMore.noMore\":\"沒有更多了\",\"zp.loadingMore.fail\":\"加載失敗,點擊重新加載\",\"zp.emptyView.title\":\"沒有數據哦~\",\"zp.emptyView.reload\":\"重新加載\",\"zp.emptyView.error\":\"很抱歉,加載失敗\",\"zp.refresherUpdateTime.title\":\"最後更新:\",\"zp.refresherUpdateTime.none\":\"無\",\"zp.refresherUpdateTime.today\":\"今天\",\"zp.refresherUpdateTime.yesterday\":\"昨天\",\"zp.systemLoading.title\":\"加載中...\"}");
  21109. /***/ }),
  21110. /* 263 */
  21111. /*!**************************************************************************************************!*\
  21112. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/z-paging/components/z-paging/js/modules/nvue.js ***!
  21113. \**************************************************************************************************/
  21114. /*! no static exports found */
  21115. /***/ (function(module, exports, __webpack_require__) {
  21116. "use strict";
  21117. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  21118. Object.defineProperty(exports, "__esModule", {
  21119. value: true
  21120. });
  21121. exports.default = void 0;
  21122. var _zPagingUtils = _interopRequireDefault(__webpack_require__(/*! .././z-paging-utils */ 252));
  21123. var _zPagingConstant = _interopRequireDefault(__webpack_require__(/*! .././z-paging-constant */ 251));
  21124. var _zPagingEnum = _interopRequireDefault(__webpack_require__(/*! .././z-paging-enum */ 256));
  21125. // [z-paging]nvue独有部分模块
  21126. var _default = {
  21127. props: {},
  21128. data: function data() {
  21129. return {
  21130. nRefresherLoading: false,
  21131. nListIsDragging: false,
  21132. nShowBottom: true,
  21133. nFixFreezing: false,
  21134. nShowRefresherReveal: false,
  21135. nLoadingMoreFixedHeight: false,
  21136. nShowRefresherRevealHeight: 0,
  21137. nOldShowRefresherRevealHeight: -1,
  21138. nRefresherWidth: _zPagingUtils.default.rpx2px(750),
  21139. nListHeight: 0,
  21140. nF2Opacity: 0
  21141. };
  21142. },
  21143. computed: {},
  21144. mounted: function mounted() {},
  21145. methods: {}
  21146. };
  21147. exports.default = _default;
  21148. /***/ }),
  21149. /* 264 */
  21150. /*!***************************************************************************************************!*\
  21151. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/z-paging/components/z-paging/js/modules/empty.js ***!
  21152. \***************************************************************************************************/
  21153. /*! no static exports found */
  21154. /***/ (function(module, exports, __webpack_require__) {
  21155. "use strict";
  21156. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  21157. Object.defineProperty(exports, "__esModule", {
  21158. value: true
  21159. });
  21160. exports.default = void 0;
  21161. var _zPagingUtils = _interopRequireDefault(__webpack_require__(/*! .././z-paging-utils */ 252));
  21162. // [z-paging]空数据图view模块
  21163. var _default = {
  21164. props: {
  21165. // 是否强制隐藏空数据图,默认为否
  21166. hideEmptyView: {
  21167. type: Boolean,
  21168. default: _zPagingUtils.default.gc('hideEmptyView', false)
  21169. },
  21170. // 空数据图描述文字,默认为“没有数据哦~”
  21171. emptyViewText: {
  21172. type: [String, Object],
  21173. default: _zPagingUtils.default.gc('emptyViewText', null)
  21174. },
  21175. // 是否显示空数据图重新加载按钮(无数据时),默认为否
  21176. showEmptyViewReload: {
  21177. type: Boolean,
  21178. default: _zPagingUtils.default.gc('showEmptyViewReload', false)
  21179. },
  21180. // 加载失败时是否显示空数据图重新加载按钮,默认为是
  21181. showEmptyViewReloadWhenError: {
  21182. type: Boolean,
  21183. default: _zPagingUtils.default.gc('showEmptyViewReloadWhenError', true)
  21184. },
  21185. // 空数据图点击重新加载文字,默认为“重新加载”
  21186. emptyViewReloadText: {
  21187. type: [String, Object],
  21188. default: _zPagingUtils.default.gc('emptyViewReloadText', null)
  21189. },
  21190. // 空数据图图片,默认使用z-paging内置的图片
  21191. emptyViewImg: {
  21192. type: String,
  21193. default: _zPagingUtils.default.gc('emptyViewImg', '')
  21194. },
  21195. // 空数据图“加载失败”描述文字,默认为“很抱歉,加载失败”
  21196. emptyViewErrorText: {
  21197. type: [String, Object],
  21198. default: _zPagingUtils.default.gc('emptyViewErrorText', null)
  21199. },
  21200. // 空数据图“加载失败”图片,默认使用z-paging内置的图片
  21201. emptyViewErrorImg: {
  21202. type: String,
  21203. default: _zPagingUtils.default.gc('emptyViewErrorImg', '')
  21204. },
  21205. // 空数据图样式
  21206. emptyViewStyle: {
  21207. type: Object,
  21208. default: _zPagingUtils.default.gc('emptyViewStyle', {})
  21209. },
  21210. // 空数据图容器样式
  21211. emptyViewSuperStyle: {
  21212. type: Object,
  21213. default: _zPagingUtils.default.gc('emptyViewSuperStyle', {})
  21214. },
  21215. // 空数据图img样式
  21216. emptyViewImgStyle: {
  21217. type: Object,
  21218. default: _zPagingUtils.default.gc('emptyViewImgStyle', {})
  21219. },
  21220. // 空数据图描述文字样式
  21221. emptyViewTitleStyle: {
  21222. type: Object,
  21223. default: _zPagingUtils.default.gc('emptyViewTitleStyle', {})
  21224. },
  21225. // 空数据图重新加载按钮样式
  21226. emptyViewReloadStyle: {
  21227. type: Object,
  21228. default: _zPagingUtils.default.gc('emptyViewReloadStyle', {})
  21229. },
  21230. // 空数据图片是否铺满z-paging,默认为否,即填充满z-paging内列表(滚动区域)部分。若设置为否,则为填铺满整个z-paging
  21231. emptyViewFixed: {
  21232. type: Boolean,
  21233. default: _zPagingUtils.default.gc('emptyViewFixed', false)
  21234. },
  21235. // 空数据图片是否垂直居中,默认为是,若设置为否即为从空数据容器顶部开始显示。emptyViewFixed为false时有效
  21236. emptyViewCenter: {
  21237. type: Boolean,
  21238. default: _zPagingUtils.default.gc('emptyViewCenter', true)
  21239. },
  21240. // 加载中时是否自动隐藏空数据图,默认为是
  21241. autoHideEmptyViewWhenLoading: {
  21242. type: Boolean,
  21243. default: _zPagingUtils.default.gc('autoHideEmptyViewWhenLoading', true)
  21244. },
  21245. // 用户下拉列表触发下拉刷新加载中时是否自动隐藏空数据图,默认为是
  21246. autoHideEmptyViewWhenPull: {
  21247. type: Boolean,
  21248. default: _zPagingUtils.default.gc('autoHideEmptyViewWhenPull', true)
  21249. },
  21250. // 空数据view的z-index,默认为9
  21251. emptyViewZIndex: {
  21252. type: Number,
  21253. default: _zPagingUtils.default.gc('emptyViewZIndex', 9)
  21254. }
  21255. },
  21256. data: function data() {
  21257. return {
  21258. customerEmptyViewErrorText: ''
  21259. };
  21260. },
  21261. computed: {
  21262. finalEmptyViewImg: function finalEmptyViewImg() {
  21263. return this.isLoadFailed ? this.emptyViewErrorImg : this.emptyViewImg;
  21264. },
  21265. finalShowEmptyViewReload: function finalShowEmptyViewReload() {
  21266. return this.isLoadFailed ? this.showEmptyViewReloadWhenError : this.showEmptyViewReload;
  21267. },
  21268. // 是否展示空数据图
  21269. showEmpty: function showEmpty() {
  21270. if (this.isOnly || this.hideEmptyView || this.realTotalData.length) return false;
  21271. if (this.autoHideEmptyViewWhenLoading) {
  21272. if (this.isAddedData && !this.firstPageLoaded && !this.loading) return true;
  21273. } else {
  21274. return true;
  21275. }
  21276. return !this.autoHideEmptyViewWhenPull && !this.isUserReload;
  21277. }
  21278. },
  21279. methods: {
  21280. // 点击了空数据view重新加载按钮
  21281. _emptyViewReload: function _emptyViewReload() {
  21282. var _this = this;
  21283. var callbacked = false;
  21284. this.$emit('emptyViewReload', function (reload) {
  21285. if (reload === undefined || reload === true) {
  21286. _this.fromEmptyViewReload = true;
  21287. _this.reload().catch(function () {});
  21288. }
  21289. callbacked = true;
  21290. });
  21291. // 如果用户没有禁止默认的点击重新加载刷新列表事件,则触发列表重新刷新
  21292. this.$nextTick(function () {
  21293. if (!callbacked) {
  21294. _this.fromEmptyViewReload = true;
  21295. _this.reload().catch(function () {});
  21296. }
  21297. });
  21298. },
  21299. // 点击了空数据view
  21300. _emptyViewClick: function _emptyViewClick() {
  21301. this.$emit('emptyViewClick');
  21302. }
  21303. }
  21304. };
  21305. exports.default = _default;
  21306. /***/ }),
  21307. /* 265 */
  21308. /*!*******************************************************************************************************!*\
  21309. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/z-paging/components/z-paging/js/modules/refresher.js ***!
  21310. \*******************************************************************************************************/
  21311. /*! no static exports found */
  21312. /***/ (function(module, exports, __webpack_require__) {
  21313. "use strict";
  21314. /* WEBPACK VAR INJECTION */(function(uni) {
  21315. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  21316. Object.defineProperty(exports, "__esModule", {
  21317. value: true
  21318. });
  21319. exports.default = void 0;
  21320. var _zPagingUtils = _interopRequireDefault(__webpack_require__(/*! .././z-paging-utils */ 252));
  21321. var _zPagingConstant = _interopRequireDefault(__webpack_require__(/*! .././z-paging-constant */ 251));
  21322. var _zPagingEnum = _interopRequireDefault(__webpack_require__(/*! .././z-paging-enum */ 256));
  21323. // [z-paging]下拉刷新view模块
  21324. var _default = {
  21325. props: {
  21326. // 下拉刷新的主题样式,支持black,white,默认black
  21327. refresherThemeStyle: {
  21328. type: String,
  21329. default: _zPagingUtils.default.gc('refresherThemeStyle', '')
  21330. },
  21331. // 自定义下拉刷新中左侧图标的样式
  21332. refresherImgStyle: {
  21333. type: Object,
  21334. default: _zPagingUtils.default.gc('refresherImgStyle', {})
  21335. },
  21336. // 自定义下拉刷新中右侧状态描述文字的样式
  21337. refresherTitleStyle: {
  21338. type: Object,
  21339. default: _zPagingUtils.default.gc('refresherTitleStyle', {})
  21340. },
  21341. // 自定义下拉刷新中右侧最后更新时间文字的样式(show-refresher-update-time为true时有效)
  21342. refresherUpdateTimeStyle: {
  21343. type: Object,
  21344. default: _zPagingUtils.default.gc('refresherUpdateTimeStyle', {})
  21345. },
  21346. // 在微信小程序和QQ小程序中,是否实时监听下拉刷新中进度,默认为否
  21347. watchRefresherTouchmove: {
  21348. type: Boolean,
  21349. default: _zPagingUtils.default.gc('watchRefresherTouchmove', false)
  21350. },
  21351. // 底部加载更多的主题样式,支持black,white,默认black
  21352. loadingMoreThemeStyle: {
  21353. type: String,
  21354. default: _zPagingUtils.default.gc('loadingMoreThemeStyle', '')
  21355. },
  21356. // 是否只使用下拉刷新,设置为true后将关闭mounted自动请求数据、关闭滚动到底部加载更多,强制隐藏空数据图。默认为否
  21357. refresherOnly: {
  21358. type: Boolean,
  21359. default: _zPagingUtils.default.gc('refresherOnly', false)
  21360. },
  21361. // 自定义下拉刷新默认状态下回弹动画时间,单位为毫秒,默认为100毫秒,nvue无效
  21362. refresherDefaultDuration: {
  21363. type: [Number, String],
  21364. default: _zPagingUtils.default.gc('refresherDefaultDuration', 100)
  21365. },
  21366. // 自定义下拉刷新结束以后延迟回弹的时间,单位为毫秒,默认为0
  21367. refresherCompleteDelay: {
  21368. type: [Number, String],
  21369. default: _zPagingUtils.default.gc('refresherCompleteDelay', 0)
  21370. },
  21371. // 自定义下拉刷新结束回弹动画时间,单位为毫秒,默认为300毫秒(refresherEndBounceEnabled为false时,refresherCompleteDuration为设定值的1/3),nvue无效
  21372. refresherCompleteDuration: {
  21373. type: [Number, String],
  21374. default: _zPagingUtils.default.gc('refresherCompleteDuration', 300)
  21375. },
  21376. // 自定义下拉刷新中是否允许列表滚动,默认为是
  21377. refresherRefreshingScrollable: {
  21378. type: Boolean,
  21379. default: _zPagingUtils.default.gc('refresherRefreshingScrollable', true)
  21380. },
  21381. // 自定义下拉刷新结束状态下是否允许列表滚动,默认为否
  21382. refresherCompleteScrollable: {
  21383. type: Boolean,
  21384. default: _zPagingUtils.default.gc('refresherCompleteScrollable', false)
  21385. },
  21386. // 是否使用自定义的下拉刷新,默认为是,即使用z-paging的下拉刷新。设置为false即代表使用uni scroll-view自带的下拉刷新,h5、App、微信小程序以外的平台不支持uni scroll-view自带的下拉刷新
  21387. useCustomRefresher: {
  21388. type: Boolean,
  21389. default: _zPagingUtils.default.gc('useCustomRefresher', true)
  21390. },
  21391. // 自定义下拉刷新下拉帧率,默认为40,过高可能会出现抖动问题
  21392. refresherFps: {
  21393. type: [Number, String],
  21394. default: _zPagingUtils.default.gc('refresherFps', 40)
  21395. },
  21396. // 自定义下拉刷新允许触发的最大下拉角度,默认为40度,当下拉角度小于设定值时,自定义下拉刷新动画不会被触发
  21397. refresherMaxAngle: {
  21398. type: [Number, String],
  21399. default: _zPagingUtils.default.gc('refresherMaxAngle', 40)
  21400. },
  21401. // 自定义下拉刷新的角度由未达到最大角度变到达到最大角度时,是否继续下拉刷新手势,默认为否
  21402. refresherAngleEnableChangeContinued: {
  21403. type: Boolean,
  21404. default: _zPagingUtils.default.gc('refresherAngleEnableChangeContinued', false)
  21405. },
  21406. // 自定义下拉刷新默认状态下的文字
  21407. refresherDefaultText: {
  21408. type: [String, Object],
  21409. default: _zPagingUtils.default.gc('refresherDefaultText', null)
  21410. },
  21411. // 自定义下拉刷新松手立即刷新状态下的文字
  21412. refresherPullingText: {
  21413. type: [String, Object],
  21414. default: _zPagingUtils.default.gc('refresherPullingText', null)
  21415. },
  21416. // 自定义下拉刷新刷新中状态下的文字
  21417. refresherRefreshingText: {
  21418. type: [String, Object],
  21419. default: _zPagingUtils.default.gc('refresherRefreshingText', null)
  21420. },
  21421. // 自定义下拉刷新刷新结束状态下的文字
  21422. refresherCompleteText: {
  21423. type: [String, Object],
  21424. default: _zPagingUtils.default.gc('refresherCompleteText', null)
  21425. },
  21426. // 自定义继续下拉进入二楼文字
  21427. refresherGoF2Text: {
  21428. type: [String, Object],
  21429. default: _zPagingUtils.default.gc('refresherGoF2Text', null)
  21430. },
  21431. // 自定义下拉刷新默认状态下的图片
  21432. refresherDefaultImg: {
  21433. type: String,
  21434. default: _zPagingUtils.default.gc('refresherDefaultImg', null)
  21435. },
  21436. // 自定义下拉刷新松手立即刷新状态下的图片,默认与refresherDefaultImg一致
  21437. refresherPullingImg: {
  21438. type: String,
  21439. default: _zPagingUtils.default.gc('refresherPullingImg', null)
  21440. },
  21441. // 自定义下拉刷新刷新中状态下的图片
  21442. refresherRefreshingImg: {
  21443. type: String,
  21444. default: _zPagingUtils.default.gc('refresherRefreshingImg', null)
  21445. },
  21446. // 自定义下拉刷新刷新结束状态下的图片
  21447. refresherCompleteImg: {
  21448. type: String,
  21449. default: _zPagingUtils.default.gc('refresherCompleteImg', null)
  21450. },
  21451. // 自定义下拉刷新刷新中状态下是否展示旋转动画
  21452. refresherRefreshingAnimated: {
  21453. type: Boolean,
  21454. default: _zPagingUtils.default.gc('refresherRefreshingAnimated', true)
  21455. },
  21456. // 是否开启自定义下拉刷新刷新结束回弹效果,默认为是
  21457. refresherEndBounceEnabled: {
  21458. type: Boolean,
  21459. default: _zPagingUtils.default.gc('refresherEndBounceEnabled', true)
  21460. },
  21461. // 是否开启自定义下拉刷新,默认为是
  21462. refresherEnabled: {
  21463. type: Boolean,
  21464. default: _zPagingUtils.default.gc('refresherEnabled', true)
  21465. },
  21466. // 设置自定义下拉刷新阈值,默认为80rpx
  21467. refresherThreshold: {
  21468. type: [Number, String],
  21469. default: _zPagingUtils.default.gc('refresherThreshold', '80rpx')
  21470. },
  21471. // 设置系统下拉刷新默认样式,支持设置 black,white,none,none 表示不使用默认样式,默认为black
  21472. refresherDefaultStyle: {
  21473. type: String,
  21474. default: _zPagingUtils.default.gc('refresherDefaultStyle', 'black')
  21475. },
  21476. // 设置自定义下拉刷新区域背景
  21477. refresherBackground: {
  21478. type: String,
  21479. default: _zPagingUtils.default.gc('refresherBackground', 'transparent')
  21480. },
  21481. // 设置固定的自定义下拉刷新区域背景
  21482. refresherFixedBackground: {
  21483. type: String,
  21484. default: _zPagingUtils.default.gc('refresherFixedBackground', 'transparent')
  21485. },
  21486. // 设置固定的自定义下拉刷新区域高度,默认为0
  21487. refresherFixedBacHeight: {
  21488. type: [Number, String],
  21489. default: _zPagingUtils.default.gc('refresherFixedBacHeight', 0)
  21490. },
  21491. // 设置自定义下拉刷新下拉超出阈值后继续下拉位移衰减的比例,范围0-1,值越大代表衰减越多。默认为0.65(nvue无效)
  21492. refresherOutRate: {
  21493. type: Number,
  21494. default: _zPagingUtils.default.gc('refresherOutRate', 0.65)
  21495. },
  21496. // 是否开启下拉进入二楼功能,默认为否
  21497. refresherF2Enabled: {
  21498. type: Boolean,
  21499. default: _zPagingUtils.default.gc('refresherF2Enabled', false)
  21500. },
  21501. // 下拉进入二楼阈值,默认为200rpx
  21502. refresherF2Threshold: {
  21503. type: [Number, String],
  21504. default: _zPagingUtils.default.gc('refresherF2Threshold', '200rpx')
  21505. },
  21506. // 下拉进入二楼动画时间,单位为毫秒,默认为200毫秒
  21507. refresherF2Duration: {
  21508. type: [Number, String],
  21509. default: _zPagingUtils.default.gc('refresherF2Duration', 200)
  21510. },
  21511. // 下拉进入二楼状态松手后是否弹出二楼,默认为是
  21512. showRefresherF2: {
  21513. type: Boolean,
  21514. default: _zPagingUtils.default.gc('showRefresherF2', true)
  21515. },
  21516. // 设置自定义下拉刷新下拉时实际下拉位移与用户下拉距离的比值,默认为0.75,即代表若用户下拉10px,则实际位移为7.5px(nvue无效)
  21517. refresherPullRate: {
  21518. type: Number,
  21519. default: _zPagingUtils.default.gc('refresherPullRate', 0.75)
  21520. },
  21521. // 是否显示最后更新时间,默认为否
  21522. showRefresherUpdateTime: {
  21523. type: Boolean,
  21524. default: _zPagingUtils.default.gc('showRefresherUpdateTime', false)
  21525. },
  21526. // 如果需要区别不同页面的最后更新时间,请为不同页面的z-paging的`refresher-update-time-key`设置不同的字符串
  21527. refresherUpdateTimeKey: {
  21528. type: String,
  21529. default: _zPagingUtils.default.gc('refresherUpdateTimeKey', 'default')
  21530. },
  21531. // 下拉刷新时下拉到“松手立即刷新”或“松手进入二楼”状态时是否使手机短振动,默认为否(h5无效)
  21532. refresherVibrate: {
  21533. type: Boolean,
  21534. default: _zPagingUtils.default.gc('refresherVibrate', false)
  21535. },
  21536. // 下拉刷新时是否禁止下拉刷新view跟随用户触摸竖直移动,默认为否。注意此属性只是禁止下拉刷新view移动,其他下拉刷新逻辑依然会正常触发
  21537. refresherNoTransform: {
  21538. type: Boolean,
  21539. default: _zPagingUtils.default.gc('refresherNoTransform', false)
  21540. },
  21541. // 是否开启下拉刷新状态栏占位,适用于隐藏导航栏时,下拉刷新需要避开状态栏高度的情况,默认为否
  21542. useRefresherStatusBarPlaceholder: {
  21543. type: Boolean,
  21544. default: _zPagingUtils.default.gc('useRefresherStatusBarPlaceholder', false)
  21545. }
  21546. },
  21547. data: function data() {
  21548. return {
  21549. R: _zPagingEnum.default.Refresher,
  21550. //下拉刷新状态
  21551. refresherStatus: _zPagingEnum.default.Refresher.Default,
  21552. refresherTouchstartY: 0,
  21553. lastRefresherTouchmove: null,
  21554. refresherReachMaxAngle: true,
  21555. refresherTransform: 'translateY(0px)',
  21556. refresherTransition: '',
  21557. finalRefresherDefaultStyle: 'black',
  21558. refresherRevealStackCount: 0,
  21559. refresherCompleteTimeout: null,
  21560. refresherCompleteSubTimeout: null,
  21561. refresherEndTimeout: null,
  21562. isTouchmovingTimeout: null,
  21563. refresherTriggered: false,
  21564. isTouchmoving: false,
  21565. isTouchEnded: false,
  21566. isUserPullDown: false,
  21567. privateRefresherEnabled: -1,
  21568. privateShowRefresherWhenReload: false,
  21569. customRefresherHeight: -1,
  21570. showCustomRefresher: false,
  21571. doRefreshAnimateAfter: false,
  21572. isRefresherInComplete: false,
  21573. showF2: false,
  21574. f2Transform: '',
  21575. pullDownTimeStamp: 0,
  21576. moveDis: 0,
  21577. oldMoveDis: 0,
  21578. currentDis: 0,
  21579. oldCurrentMoveDis: 0,
  21580. oldRefresherTouchmoveY: 0,
  21581. oldTouchDirection: '',
  21582. oldEmitedTouchDirection: '',
  21583. oldPullingDistance: -1,
  21584. refresherThresholdUpdateTag: 0
  21585. };
  21586. },
  21587. watch: {
  21588. refresherDefaultStyle: {
  21589. handler: function handler(newVal) {
  21590. if (newVal.length) {
  21591. this.finalRefresherDefaultStyle = newVal;
  21592. }
  21593. },
  21594. immediate: true
  21595. },
  21596. refresherStatus: function refresherStatus(newVal) {
  21597. newVal === _zPagingEnum.default.Refresher.Loading && this._cleanRefresherEndTimeout();
  21598. this.refresherVibrate && (newVal === _zPagingEnum.default.Refresher.ReleaseToRefresh || newVal === _zPagingEnum.default.Refresher.GoF2) && this._doVibrateShort();
  21599. this.$emit('refresherStatusChange', newVal);
  21600. this.$emit('update:refresherStatus', newVal);
  21601. },
  21602. // 监听当前下拉刷新启用/禁用状态
  21603. refresherEnabled: function refresherEnabled(newVal) {
  21604. // 当禁用下拉刷新时,强制收回正在展示的下拉刷新view
  21605. !newVal && this.endRefresh();
  21606. }
  21607. },
  21608. computed: {
  21609. pullDownDisTimeStamp: function pullDownDisTimeStamp() {
  21610. return 1000 / this.refresherFps;
  21611. },
  21612. refresherThresholdUnitConverted: function refresherThresholdUnitConverted() {
  21613. return _zPagingUtils.default.addUnit(this.refresherThreshold, this.unit);
  21614. },
  21615. finalRefresherEnabled: function finalRefresherEnabled() {
  21616. if (this.layoutOnly || this.useChatRecordMode) return false;
  21617. if (this.privateRefresherEnabled === -1) return this.refresherEnabled;
  21618. return this.privateRefresherEnabled === 1;
  21619. },
  21620. finalRefresherThreshold: function finalRefresherThreshold() {
  21621. var refresherThreshold = this.refresherThresholdUnitConverted;
  21622. var idDefault = false;
  21623. if (refresherThreshold === _zPagingUtils.default.addUnit(80, this.unit)) {
  21624. idDefault = true;
  21625. if (this.showRefresherUpdateTime) {
  21626. refresherThreshold = _zPagingUtils.default.addUnit(120, this.unit);
  21627. }
  21628. }
  21629. if (idDefault && this.customRefresherHeight > 0) return this.customRefresherHeight + this.finalRefresherThresholdPlaceholder;
  21630. return _zPagingUtils.default.convertToPx(refresherThreshold) + this.finalRefresherThresholdPlaceholder;
  21631. },
  21632. finalRefresherF2Threshold: function finalRefresherF2Threshold() {
  21633. return _zPagingUtils.default.convertToPx(_zPagingUtils.default.addUnit(this.refresherF2Threshold, this.unit));
  21634. },
  21635. finalRefresherThresholdPlaceholder: function finalRefresherThresholdPlaceholder() {
  21636. return this.useRefresherStatusBarPlaceholder ? this.statusBarHeight : 0;
  21637. },
  21638. finalRefresherFixedBacHeight: function finalRefresherFixedBacHeight() {
  21639. return _zPagingUtils.default.convertToPx(this.refresherFixedBacHeight);
  21640. },
  21641. finalRefresherThemeStyle: function finalRefresherThemeStyle() {
  21642. return this.refresherThemeStyle.length ? this.refresherThemeStyle : this.defaultThemeStyle;
  21643. },
  21644. finalRefresherOutRate: function finalRefresherOutRate() {
  21645. var rate = this.refresherOutRate;
  21646. rate = Math.max(0, rate);
  21647. rate = Math.min(1, rate);
  21648. return rate;
  21649. },
  21650. finalRefresherPullRate: function finalRefresherPullRate() {
  21651. var rate = this.refresherPullRate;
  21652. rate = Math.max(0, rate);
  21653. return rate;
  21654. },
  21655. finalRefresherTransform: function finalRefresherTransform() {
  21656. if (this.refresherNoTransform || this.refresherTransform === 'translateY(0px)') return 'none';
  21657. return this.refresherTransform;
  21658. },
  21659. finalShowRefresherWhenReload: function finalShowRefresherWhenReload() {
  21660. return this.showRefresherWhenReload || this.privateShowRefresherWhenReload;
  21661. },
  21662. finalRefresherTriggered: function finalRefresherTriggered() {
  21663. if (!(this.finalRefresherEnabled && !this.useCustomRefresher)) return false;
  21664. return this.refresherTriggered;
  21665. },
  21666. showRefresher: function showRefresher() {
  21667. var showRefresher = this.finalRefresherEnabled || this.useCustomRefresher && !this.useChatRecordMode;
  21668. this.active && this.customRefresherHeight === -1 && showRefresher && this.updateCustomRefresherHeight();
  21669. return showRefresher;
  21670. },
  21671. hasTouchmove: function hasTouchmove() {
  21672. return true;
  21673. return this.watchRefresherTouchmove;
  21674. }
  21675. },
  21676. methods: {
  21677. // 终止下拉刷新状态
  21678. endRefresh: function endRefresh() {
  21679. var _this = this;
  21680. this.totalData = this.realTotalData;
  21681. this._refresherEnd();
  21682. this._endSystemLoadingAndRefresh();
  21683. this._handleScrollViewBounce({
  21684. bounce: true
  21685. });
  21686. this.$nextTick(function () {
  21687. _this.refresherTriggered = false;
  21688. });
  21689. },
  21690. // 手动更新自定义下拉刷新view高度
  21691. updateCustomRefresherHeight: function updateCustomRefresherHeight() {
  21692. var _this2 = this;
  21693. _zPagingUtils.default.delay(function () {
  21694. return _this2.$nextTick(_this2._updateCustomRefresherHeight);
  21695. });
  21696. },
  21697. // 进入二楼
  21698. goF2: function goF2() {
  21699. this._handleGoF2();
  21700. },
  21701. // 关闭二楼
  21702. closeF2: function closeF2() {
  21703. this._handleCloseF2();
  21704. },
  21705. // 自定义下拉刷新被触发
  21706. _onRefresh: function _onRefresh() {
  21707. var fromScrollView = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;
  21708. var isUserPullDown = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
  21709. if (fromScrollView && !(this.finalRefresherEnabled && !this.useCustomRefresher)) return;
  21710. this.$emit('onRefresh');
  21711. this.$emit('Refresh');
  21712. if (this.loading || this.isRefresherInComplete) return;
  21713. this.loadingType = _zPagingEnum.default.LoadingType.Refresher;
  21714. if (this.nShowRefresherReveal) return;
  21715. this.isUserPullDown = isUserPullDown;
  21716. this.isUserReload = !isUserPullDown;
  21717. this._startLoading(true);
  21718. this.refresherTriggered = true;
  21719. if (this.reloadWhenRefresh && isUserPullDown) {
  21720. this.useChatRecordMode ? this._onLoadingMore('click') : this._reload(false, false, isUserPullDown);
  21721. }
  21722. },
  21723. // 自定义下拉刷新被复位
  21724. _onRestore: function _onRestore() {
  21725. this.refresherTriggered = 'restore';
  21726. this.$emit('onRestore');
  21727. this.$emit('Restore');
  21728. },
  21729. // touch开始
  21730. _refresherTouchstart: function _refresherTouchstart(e) {
  21731. this._handleListTouchstart();
  21732. if (this._touchDisabled()) return;
  21733. this._handleRefresherTouchstart(_zPagingUtils.default.getTouch(e));
  21734. },
  21735. // 进一步处理touch开始结果
  21736. _handleRefresherTouchstart: function _handleRefresherTouchstart(touch) {
  21737. if (!this.loading && this.isTouchEnded) {
  21738. this.isTouchmoving = false;
  21739. }
  21740. this.loadingType = _zPagingEnum.default.LoadingType.Refresher;
  21741. this.isTouchmovingTimeout && clearTimeout(this.isTouchmovingTimeout);
  21742. this.isTouchEnded = false;
  21743. this.refresherTransition = '';
  21744. this.refresherTouchstartY = touch.touchY;
  21745. this.$emit('refresherTouchstart', this.refresherTouchstartY);
  21746. this.lastRefresherTouchmove = touch;
  21747. this._cleanRefresherCompleteTimeout();
  21748. this._cleanRefresherEndTimeout();
  21749. },
  21750. // 非app-vue或微信小程序或QQ小程序或h5平台,使用js控制下拉刷新
  21751. // touch中
  21752. _refresherTouchmove: function _refresherTouchmove(e) {
  21753. var currentTimeStamp = _zPagingUtils.default.getTime();
  21754. var touch = null;
  21755. var refresherTouchmoveY = 0;
  21756. if (this.watchTouchDirectionChange) {
  21757. // 检测下拉刷新方向改变
  21758. touch = _zPagingUtils.default.getTouch(e);
  21759. refresherTouchmoveY = touch.touchY;
  21760. var direction = refresherTouchmoveY > this.oldRefresherTouchmoveY ? 'top' : 'bottom';
  21761. // 只有在方向改变的时候才emit相关事件
  21762. if (direction === this.oldTouchDirection && direction !== this.oldEmitedTouchDirection) {
  21763. this._handleTouchDirectionChange({
  21764. direction: direction
  21765. });
  21766. this.oldEmitedTouchDirection = direction;
  21767. }
  21768. this.oldTouchDirection = direction;
  21769. this.oldRefresherTouchmoveY = refresherTouchmoveY;
  21770. }
  21771. // 节流处理,在pullDownDisTimeStamp时间内的下拉刷新中事件不进行处理
  21772. if (this.pullDownTimeStamp && currentTimeStamp - this.pullDownTimeStamp <= this.pullDownDisTimeStamp) return;
  21773. // 如果不允许下拉,则return
  21774. if (this._touchDisabled()) return;
  21775. this.pullDownTimeStamp = Number(currentTimeStamp);
  21776. touch = _zPagingUtils.default.getTouch(e);
  21777. refresherTouchmoveY = touch.touchY;
  21778. // 获取当前touch的y - 初始touch的y,计算它们的差
  21779. var moveDis = refresherTouchmoveY - this.refresherTouchstartY;
  21780. if (moveDis < 0) return;
  21781. // 对下拉刷新的角度进行限制
  21782. if (this.refresherMaxAngle >= 0 && this.refresherMaxAngle <= 90 && this.lastRefresherTouchmove && this.lastRefresherTouchmove.touchY <= refresherTouchmoveY) {
  21783. if (!moveDis && !this.refresherAngleEnableChangeContinued && this.moveDis < 1 && !this.refresherReachMaxAngle) return;
  21784. var x = Math.abs(touch.touchX - this.lastRefresherTouchmove.touchX);
  21785. var y = Math.abs(refresherTouchmoveY - this.lastRefresherTouchmove.touchY);
  21786. var z = Math.sqrt(Math.pow(x, 2) + Math.pow(y, 2));
  21787. if ((x || y) && x > 1) {
  21788. // 获取下拉刷新前后两次位移的角度
  21789. var angle = Math.asin(y / z) / Math.PI * 180;
  21790. // 如果角度小于配置要求,则return
  21791. if (angle < this.refresherMaxAngle) {
  21792. this.lastRefresherTouchmove = touch;
  21793. this.refresherReachMaxAngle = false;
  21794. return;
  21795. }
  21796. }
  21797. }
  21798. // 获取最终的moveDis
  21799. moveDis = this._getFinalRefresherMoveDis(moveDis);
  21800. // 处理下拉刷新位移
  21801. this._handleRefresherTouchmove(moveDis, touch);
  21802. // 下拉刷新时,禁止页面滚动以防止页面向下滚动和下拉刷新同时作用导致下拉刷新位置偏移超过预期
  21803. if (!this.disabledBounce) {
  21804. this._handleScrollViewBounce({
  21805. bounce: false
  21806. });
  21807. this.disabledBounce = true;
  21808. }
  21809. this._emitTouchmove({
  21810. pullingDistance: moveDis,
  21811. dy: this.moveDis - this.oldMoveDis
  21812. });
  21813. },
  21814. // 进一步处理touch中结果
  21815. _handleRefresherTouchmove: function _handleRefresherTouchmove(moveDis, touch) {
  21816. this.refresherReachMaxAngle = true;
  21817. this.isTouchmovingTimeout && clearTimeout(this.isTouchmovingTimeout);
  21818. this.isTouchmoving = true;
  21819. this.isTouchEnded = false;
  21820. // 更新下拉刷新状态
  21821. // 下拉刷新距离超过阈值
  21822. if (moveDis >= this.finalRefresherThreshold) {
  21823. // 如果开启了下拉进入二楼并且下拉刷新距离超过进入二楼阈值,则当前下拉刷新状态为松手进入二楼,否则为松手立即刷新
  21824. this.refresherStatus = this.refresherF2Enabled && moveDis >= this.finalRefresherF2Threshold ? _zPagingEnum.default.Refresher.GoF2 : _zPagingEnum.default.Refresher.ReleaseToRefresh;
  21825. } else {
  21826. // 下拉刷新距离未超过阈值,显示默认状态
  21827. this.refresherStatus = _zPagingEnum.default.Refresher.Default;
  21828. }
  21829. // this.scrollEnable = false;
  21830. // 通过transform控制下拉刷新view垂直偏移
  21831. this.refresherTransform = "translateY(".concat(moveDis, "px)");
  21832. this.lastRefresherTouchmove = touch;
  21833. this.moveDis = moveDis;
  21834. },
  21835. // touch结束
  21836. _refresherTouchend: function _refresherTouchend(e) {
  21837. // 下拉刷新用户手离开屏幕,允许列表滚动
  21838. this._handleScrollViewBounce({
  21839. bounce: true
  21840. });
  21841. if (this._touchDisabled() || !this.isTouchmoving) return;
  21842. var touch = _zPagingUtils.default.getTouch(e);
  21843. var refresherTouchendY = touch.touchY;
  21844. var moveDis = refresherTouchendY - this.refresherTouchstartY;
  21845. moveDis = this._getFinalRefresherMoveDis(moveDis);
  21846. this._handleRefresherTouchend(moveDis);
  21847. this.disabledBounce = false;
  21848. },
  21849. // 进一步处理touch结束结果
  21850. _handleRefresherTouchend: function _handleRefresherTouchend(moveDis) {
  21851. var _this3 = this;
  21852. if (!this.isTouchmoving) return;
  21853. this.isTouchmovingTimeout && clearTimeout(this.isTouchmovingTimeout);
  21854. this.refresherReachMaxAngle = true;
  21855. this.isTouchEnded = true;
  21856. var refresherThreshold = this.finalRefresherThreshold;
  21857. if (moveDis >= refresherThreshold && [_zPagingEnum.default.Refresher.ReleaseToRefresh, _zPagingEnum.default.Refresher.GoF2].indexOf(this.refresherStatus) >= 0) {
  21858. // 如果是松手进入二楼状态,则触发进入二楼
  21859. if (this.refresherStatus === _zPagingEnum.default.Refresher.GoF2) {
  21860. this._handleGoF2();
  21861. this._refresherEnd();
  21862. } else {
  21863. // 如果是松手立即刷新状态,则触发下拉刷新
  21864. this.refresherTransform = "translateY(".concat(refresherThreshold, "px)");
  21865. this.refresherTransition = 'transform .1s linear';
  21866. _zPagingUtils.default.delay(function () {
  21867. _this3._emitTouchmove({
  21868. pullingDistance: refresherThreshold,
  21869. dy: _this3.moveDis - refresherThreshold
  21870. });
  21871. }, 0.1);
  21872. this.moveDis = refresherThreshold;
  21873. this.refresherStatus = _zPagingEnum.default.Refresher.Loading;
  21874. this._doRefresherLoad();
  21875. }
  21876. } else {
  21877. this._refresherEnd();
  21878. this.isTouchmovingTimeout = _zPagingUtils.default.delay(function () {
  21879. _this3.isTouchmoving = false;
  21880. }, this.refresherDefaultDuration);
  21881. }
  21882. this.scrollEnable = true;
  21883. this.$emit('refresherTouchend', moveDis);
  21884. },
  21885. // 处理列表触摸开始事件
  21886. _handleListTouchstart: function _handleListTouchstart() {
  21887. if (this.useChatRecordMode && this.autoHideKeyboardWhenChat) {
  21888. uni.hideKeyboard();
  21889. this.$emit('hidedKeyboard');
  21890. }
  21891. },
  21892. // 处理scroll-view bounce是否生效
  21893. _handleScrollViewBounce: function _handleScrollViewBounce(_ref) {
  21894. var bounce = _ref.bounce;
  21895. if (!this.usePageScroll && !this.scrollToTopBounceEnabled) {
  21896. if (this.wxsScrollTop <= 5) {
  21897. this.scrollEnable = bounce;
  21898. } else if (bounce) {
  21899. this.scrollEnable = bounce;
  21900. }
  21901. }
  21902. },
  21903. // wxs正在下拉状态改变处理
  21904. _handleWxsPullingDownStatusChange: function _handleWxsPullingDownStatusChange(onPullingDown) {
  21905. this.wxsOnPullingDown = onPullingDown;
  21906. if (onPullingDown && !this.useChatRecordMode) {
  21907. this.renderPropScrollTop = 0;
  21908. }
  21909. },
  21910. // wxs正在下拉处理
  21911. _handleWxsPullingDown: function _handleWxsPullingDown(_ref2) {
  21912. var moveDis = _ref2.moveDis,
  21913. diffDis = _ref2.diffDis;
  21914. this._emitTouchmove({
  21915. pullingDistance: moveDis,
  21916. dy: diffDis
  21917. });
  21918. },
  21919. // wxs触摸方向改变
  21920. _handleTouchDirectionChange: function _handleTouchDirectionChange(_ref3) {
  21921. var direction = _ref3.direction;
  21922. this.$emit('touchDirectionChange', direction);
  21923. },
  21924. // wxs通知更新其props
  21925. _handlePropUpdate: function _handlePropUpdate() {
  21926. this.wxsPropType = _zPagingUtils.default.getTime().toString();
  21927. },
  21928. // 下拉刷新结束
  21929. _refresherEnd: function _refresherEnd() {
  21930. var _this4 = this;
  21931. var shouldEndLoadingDelay = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : true;
  21932. var fromAddData = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
  21933. var isUserPullDown = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
  21934. var setLoading = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : true;
  21935. if (this.loadingType === _zPagingEnum.default.LoadingType.Refresher) {
  21936. // 计算当前下拉刷新结束需要延迟的时间(用户主动下拉刷新或reload时显示下拉刷新view才需要计算延迟时间)
  21937. var refresherCompleteDelay = fromAddData && (isUserPullDown || this.finalShowRefresherWhenReload) ? this.refresherCompleteDelay : 0;
  21938. // 如果延迟时间大于0,则展示刷新结束状态,否则直接展示默认状态
  21939. var refresherStatus = refresherCompleteDelay > 0 ? _zPagingEnum.default.Refresher.Complete : _zPagingEnum.default.Refresher.Default;
  21940. if (this.finalShowRefresherWhenReload) {
  21941. var stackCount = this.refresherRevealStackCount;
  21942. this.refresherRevealStackCount--;
  21943. if (stackCount > 1) return;
  21944. }
  21945. this._cleanRefresherEndTimeout();
  21946. this.refresherEndTimeout = _zPagingUtils.default.delay(function () {
  21947. // 更新下拉刷新状态
  21948. _this4.refresherStatus = refresherStatus;
  21949. // 如果当前下拉刷新状态不是刷新结束,则认为其不在刷新结束状态
  21950. if (refresherStatus !== _zPagingEnum.default.Refresher.Complete) {
  21951. _this4.isRefresherInComplete = false;
  21952. }
  21953. }, this.refresherStatus !== _zPagingEnum.default.Refresher.Default && refresherStatus === _zPagingEnum.default.Refresher.Default ? this.refresherCompleteDuration : 0);
  21954. if (refresherCompleteDelay > 0) {
  21955. this.isRefresherInComplete = true;
  21956. }
  21957. this._cleanRefresherCompleteTimeout();
  21958. this.refresherCompleteTimeout = _zPagingUtils.default.delay(function () {
  21959. var animateDuration = 1;
  21960. var animateType = _this4.refresherEndBounceEnabled && fromAddData ? 'cubic-bezier(0.19,1.64,0.42,0.72)' : 'linear';
  21961. if (fromAddData) {
  21962. animateDuration = _this4.refresherEndBounceEnabled ? _this4.refresherCompleteDuration / 1000 : _this4.refresherCompleteDuration / 3000;
  21963. }
  21964. _this4.refresherTransition = "transform ".concat(fromAddData ? animateDuration : _this4.refresherDefaultDuration / 1000, "s ").concat(animateType);
  21965. _this4.refresherTransform = 'translateY(0px)';
  21966. _this4.currentDis = 0;
  21967. _this4.moveDis = 0;
  21968. if (refresherStatus === _zPagingEnum.default.Refresher.Complete) {
  21969. if (_this4.refresherCompleteSubTimeout) {
  21970. clearTimeout(_this4.refresherCompleteSubTimeout);
  21971. _this4.refresherCompleteSubTimeout = null;
  21972. }
  21973. _this4.refresherCompleteSubTimeout = _zPagingUtils.default.delay(function () {
  21974. _this4.$nextTick(function () {
  21975. _this4.refresherStatus = _zPagingEnum.default.Refresher.Default;
  21976. _this4.isRefresherInComplete = false;
  21977. });
  21978. }, animateDuration * 800);
  21979. }
  21980. _this4._emitTouchmove({
  21981. pullingDistance: 0,
  21982. dy: _this4.moveDis
  21983. });
  21984. }, refresherCompleteDelay);
  21985. }
  21986. if (setLoading) {
  21987. _zPagingUtils.default.delay(function () {
  21988. return _this4.loading = false;
  21989. }, shouldEndLoadingDelay ? 10 : 0);
  21990. isUserPullDown && this._onRestore();
  21991. }
  21992. },
  21993. // 处理进入二楼
  21994. _handleGoF2: function _handleGoF2() {
  21995. var _this5 = this;
  21996. if (this.showF2 || !this.refresherF2Enabled) return;
  21997. this.$emit('refresherF2Change', 'go');
  21998. if (!this.showRefresherF2) return;
  21999. this.f2Transform = "translateY(".concat(-this.superContentHeight, "px)");
  22000. this.showF2 = true;
  22001. _zPagingUtils.default.delay(function () {
  22002. _this5.f2Transform = 'translateY(0px)';
  22003. }, 100, 'f2ShowDelay');
  22004. },
  22005. // 处理退出二楼
  22006. _handleCloseF2: function _handleCloseF2() {
  22007. var _this6 = this;
  22008. if (!this.showF2 || !this.refresherF2Enabled) return;
  22009. this.$emit('refresherF2Change', 'close');
  22010. if (!this.showRefresherF2) return;
  22011. this.f2Transform = "translateY(".concat(-this.superContentHeight, "px)");
  22012. _zPagingUtils.default.delay(function () {
  22013. _this6.showF2 = false;
  22014. _this6.nF2Opacity = 0;
  22015. }, this.refresherF2Duration, 'f2CloseDelay');
  22016. },
  22017. // 模拟用户手动触发下拉刷新
  22018. _doRefresherRefreshAnimate: function _doRefresherRefreshAnimate() {
  22019. this._cleanRefresherCompleteTimeout();
  22020. // 用户处理用户在短时间内多次调用reload的情况,此时下拉刷新view不需要重复显示,只需要保证最后一次reload对应的请求结束后收回下拉刷新view即可
  22021. var doRefreshAnimateAfter = !this.doRefreshAnimateAfter && this.finalShowRefresherWhenReload && this.customRefresherHeight === -1 && this.refresherThreshold === _zPagingUtils.default.addUnit(80, this.unit);
  22022. if (doRefreshAnimateAfter) {
  22023. this.doRefreshAnimateAfter = true;
  22024. return;
  22025. }
  22026. this.refresherRevealStackCount++;
  22027. this.refresherTransform = "translateY(".concat(this.finalRefresherThreshold, "px)");
  22028. this.moveDis = this.finalRefresherThreshold;
  22029. this.refresherStatus = _zPagingEnum.default.Refresher.Loading;
  22030. this.isTouchmoving = true;
  22031. this.isTouchmovingTimeout && clearTimeout(this.isTouchmovingTimeout);
  22032. this._doRefresherLoad(false);
  22033. },
  22034. // 触发下拉刷新
  22035. _doRefresherLoad: function _doRefresherLoad() {
  22036. var isUserPullDown = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : true;
  22037. this._onRefresh(false, isUserPullDown);
  22038. this.loading = true;
  22039. },
  22040. // 获取处理后的moveDis
  22041. _getFinalRefresherMoveDis: function _getFinalRefresherMoveDis(moveDis) {
  22042. var diffDis = moveDis - this.oldCurrentMoveDis;
  22043. this.oldCurrentMoveDis = moveDis;
  22044. if (diffDis > 0) {
  22045. // 根据配置的下拉刷新用户手势位移与实际需要的位移比率计算最终的diffDis
  22046. diffDis = diffDis * this.finalRefresherPullRate;
  22047. if (this.currentDis > this.finalRefresherThreshold) {
  22048. diffDis = diffDis * (1 - this.finalRefresherOutRate);
  22049. }
  22050. }
  22051. // 控制diffDis过大的情况,比如进入页面突然猛然下拉,此时diffDis不应进行太大的偏移
  22052. diffDis = diffDis > 100 ? diffDis / 100 : diffDis;
  22053. this.currentDis += diffDis;
  22054. this.currentDis = Math.max(0, this.currentDis);
  22055. return this.currentDis;
  22056. },
  22057. // 判断touch手势是否要触发
  22058. _touchDisabled: function _touchDisabled() {
  22059. var checkOldScrollTop = this.oldScrollTop > 5;
  22060. return this.loading || this.isRefresherInComplete || this.useChatRecordMode || this.layoutOnly || !this.refresherEnabled || !this.useCustomRefresher || this.usePageScroll && this.useCustomRefresher && this.pageScrollTop > 10 || !(this.usePageScroll && this.useCustomRefresher) && checkOldScrollTop;
  22061. },
  22062. // 更新自定义下拉刷新view高度
  22063. _updateCustomRefresherHeight: function _updateCustomRefresherHeight() {
  22064. var _this7 = this;
  22065. this._getNodeClientRect('.zp-custom-refresher-slot-view').then(function (res) {
  22066. _this7.customRefresherHeight = res ? res[0].height : 0;
  22067. _this7.showCustomRefresher = _this7.customRefresherHeight > 0;
  22068. if (_this7.doRefreshAnimateAfter) {
  22069. _this7.doRefreshAnimateAfter = false;
  22070. _this7._doRefresherRefreshAnimate();
  22071. }
  22072. });
  22073. },
  22074. // emit pullingDown事件
  22075. _emitTouchmove: function _emitTouchmove(e) {
  22076. e.viewHeight = this.finalRefresherThreshold;
  22077. e.rate = e.viewHeight > 0 ? e.pullingDistance / e.viewHeight : 0;
  22078. this.hasTouchmove && this.oldPullingDistance !== e.pullingDistance && this.$emit('refresherTouchmove', e);
  22079. this.oldPullingDistance = e.pullingDistance;
  22080. },
  22081. // 清除refresherCompleteTimeout
  22082. _cleanRefresherCompleteTimeout: function _cleanRefresherCompleteTimeout() {
  22083. this.refresherCompleteTimeout = this._cleanTimeout(this.refresherCompleteTimeout);
  22084. },
  22085. // 清除refresherEndTimeout
  22086. _cleanRefresherEndTimeout: function _cleanRefresherEndTimeout() {
  22087. this.refresherEndTimeout = this._cleanTimeout(this.refresherEndTimeout);
  22088. }
  22089. }
  22090. };
  22091. exports.default = _default;
  22092. /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./node_modules/@dcloudio/uni-mp-toutiao/dist/index.js */ 1)["default"]))
  22093. /***/ }),
  22094. /* 266 */
  22095. /*!*******************************************************************************************************!*\
  22096. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/z-paging/components/z-paging/js/modules/load-more.js ***!
  22097. \*******************************************************************************************************/
  22098. /*! no static exports found */
  22099. /***/ (function(module, exports, __webpack_require__) {
  22100. "use strict";
  22101. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  22102. Object.defineProperty(exports, "__esModule", {
  22103. value: true
  22104. });
  22105. exports.default = void 0;
  22106. var _regenerator = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/regenerator */ 54));
  22107. var _asyncToGenerator2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/asyncToGenerator */ 56));
  22108. var _zPagingUtils = _interopRequireDefault(__webpack_require__(/*! .././z-paging-utils */ 252));
  22109. var _zPagingEnum = _interopRequireDefault(__webpack_require__(/*! .././z-paging-enum */ 256));
  22110. // [z-paging]滚动到底部加载更多模块
  22111. var _default = {
  22112. props: {
  22113. // 自定义底部加载更多样式
  22114. loadingMoreCustomStyle: {
  22115. type: Object,
  22116. default: _zPagingUtils.default.gc('loadingMoreCustomStyle', {})
  22117. },
  22118. // 自定义底部加载更多文字样式
  22119. loadingMoreTitleCustomStyle: {
  22120. type: Object,
  22121. default: _zPagingUtils.default.gc('loadingMoreTitleCustomStyle', {})
  22122. },
  22123. // 自定义底部加载更多加载中动画样式
  22124. loadingMoreLoadingIconCustomStyle: {
  22125. type: Object,
  22126. default: _zPagingUtils.default.gc('loadingMoreLoadingIconCustomStyle', {})
  22127. },
  22128. // 自定义底部加载更多加载中动画图标类型,可选flower或circle,默认为flower
  22129. loadingMoreLoadingIconType: {
  22130. type: String,
  22131. default: _zPagingUtils.default.gc('loadingMoreLoadingIconType', 'flower')
  22132. },
  22133. // 自定义底部加载更多加载中动画图标图片
  22134. loadingMoreLoadingIconCustomImage: {
  22135. type: String,
  22136. default: _zPagingUtils.default.gc('loadingMoreLoadingIconCustomImage', '')
  22137. },
  22138. // 底部加载更多加载中view是否展示旋转动画,默认为是
  22139. loadingMoreLoadingAnimated: {
  22140. type: Boolean,
  22141. default: _zPagingUtils.default.gc('loadingMoreLoadingAnimated', true)
  22142. },
  22143. // 是否启用加载更多数据(含滑动到底部加载更多数据和点击加载更多数据),默认为是
  22144. loadingMoreEnabled: {
  22145. type: Boolean,
  22146. default: _zPagingUtils.default.gc('loadingMoreEnabled', true)
  22147. },
  22148. // 是否启用滑动到底部加载更多数据,默认为是
  22149. toBottomLoadingMoreEnabled: {
  22150. type: Boolean,
  22151. default: _zPagingUtils.default.gc('toBottomLoadingMoreEnabled', true)
  22152. },
  22153. // 滑动到底部状态为默认状态时,以加载中的状态展示,默认为否。若设置为是,可避免滚动到底部看到默认状态然后立刻变为加载中状态的问题,但分页数量未超过一屏时,不会显示【点击加载更多】
  22154. loadingMoreDefaultAsLoading: {
  22155. type: Boolean,
  22156. default: _zPagingUtils.default.gc('loadingMoreDefaultAsLoading', false)
  22157. },
  22158. // 滑动到底部"默认"文字,默认为【点击加载更多】
  22159. loadingMoreDefaultText: {
  22160. type: [String, Object],
  22161. default: _zPagingUtils.default.gc('loadingMoreDefaultText', null)
  22162. },
  22163. // 滑动到底部"加载中"文字,默认为【正在加载...】
  22164. loadingMoreLoadingText: {
  22165. type: [String, Object],
  22166. default: _zPagingUtils.default.gc('loadingMoreLoadingText', null)
  22167. },
  22168. // 滑动到底部"没有更多"文字,默认为【没有更多了】
  22169. loadingMoreNoMoreText: {
  22170. type: [String, Object],
  22171. default: _zPagingUtils.default.gc('loadingMoreNoMoreText', null)
  22172. },
  22173. // 滑动到底部"加载失败"文字,默认为【加载失败,点击重新加载】
  22174. loadingMoreFailText: {
  22175. type: [String, Object],
  22176. default: _zPagingUtils.default.gc('loadingMoreFailText', null)
  22177. },
  22178. // 当没有更多数据且分页内容未超出z-paging时是否隐藏没有更多数据的view,默认为否
  22179. hideNoMoreInside: {
  22180. type: Boolean,
  22181. default: _zPagingUtils.default.gc('hideNoMoreInside', false)
  22182. },
  22183. // 当没有更多数据且分页数组长度少于这个值时,隐藏没有更多数据的view,默认为0,代表不限制。
  22184. hideNoMoreByLimit: {
  22185. type: Number,
  22186. default: _zPagingUtils.default.gc('hideNoMoreByLimit', 0)
  22187. },
  22188. // 是否显示默认的加载更多text,默认为是
  22189. showDefaultLoadingMoreText: {
  22190. type: Boolean,
  22191. default: _zPagingUtils.default.gc('showDefaultLoadingMoreText', true)
  22192. },
  22193. // 是否显示没有更多数据的view
  22194. showLoadingMoreNoMoreView: {
  22195. type: Boolean,
  22196. default: _zPagingUtils.default.gc('showLoadingMoreNoMoreView', true)
  22197. },
  22198. // 是否显示没有更多数据的分割线,默认为是
  22199. showLoadingMoreNoMoreLine: {
  22200. type: Boolean,
  22201. default: _zPagingUtils.default.gc('showLoadingMoreNoMoreLine', true)
  22202. },
  22203. // 自定义底部没有更多数据的分割线样式
  22204. loadingMoreNoMoreLineCustomStyle: {
  22205. type: Object,
  22206. default: _zPagingUtils.default.gc('loadingMoreNoMoreLineCustomStyle', {})
  22207. },
  22208. // 当分页未满一屏时,是否自动加载更多,默认为否(nvue无效)
  22209. insideMore: {
  22210. type: Boolean,
  22211. default: _zPagingUtils.default.gc('insideMore', false)
  22212. },
  22213. // 距底部/右边多远时(单位px),触发 scrolltolower 事件,默认为100rpx
  22214. lowerThreshold: {
  22215. type: [Number, String],
  22216. default: _zPagingUtils.default.gc('lowerThreshold', '100rpx')
  22217. }
  22218. },
  22219. data: function data() {
  22220. return {
  22221. M: _zPagingEnum.default.More,
  22222. // 底部加载更多状态
  22223. loadingStatus: _zPagingEnum.default.More.Default,
  22224. // 在渲染之后的底部加载更多状态
  22225. loadingStatusAfterRender: _zPagingEnum.default.More.Default,
  22226. // 底部加载更多时间戳
  22227. loadingMoreTimeStamp: 0,
  22228. // 底部加载更多slot
  22229. loadingMoreDefaultSlot: null,
  22230. // 是否展示底部加载更多
  22231. showLoadingMore: false,
  22232. // 是否是开发者自定义的加载更多,-1代表交由z-paging自行判断;1代表没有更多了;0代表还有更多数据
  22233. customNoMore: -1
  22234. };
  22235. },
  22236. computed: {
  22237. // 底部加载更多配置
  22238. zLoadMoreConfig: function zLoadMoreConfig() {
  22239. return {
  22240. status: this.loadingStatusAfterRender,
  22241. defaultAsLoading: this.loadingMoreDefaultAsLoading || this.useChatRecordMode && this.chatLoadingMoreDefaultAsLoading,
  22242. defaultThemeStyle: this.finalLoadingMoreThemeStyle,
  22243. customStyle: this.loadingMoreCustomStyle,
  22244. titleCustomStyle: this.loadingMoreTitleCustomStyle,
  22245. iconCustomStyle: this.loadingMoreLoadingIconCustomStyle,
  22246. loadingIconType: this.loadingMoreLoadingIconType,
  22247. loadingIconCustomImage: this.loadingMoreLoadingIconCustomImage,
  22248. loadingAnimated: this.loadingMoreLoadingAnimated,
  22249. showNoMoreLine: this.showLoadingMoreNoMoreLine,
  22250. noMoreLineCustomStyle: this.loadingMoreNoMoreLineCustomStyle,
  22251. defaultText: this.finalLoadingMoreDefaultText,
  22252. loadingText: this.finalLoadingMoreLoadingText,
  22253. noMoreText: this.finalLoadingMoreNoMoreText,
  22254. failText: this.finalLoadingMoreFailText,
  22255. hideContent: !this.loadingMoreDefaultAsLoading && this.listRendering,
  22256. unit: this.unit,
  22257. isChat: this.useChatRecordMode,
  22258. chatDefaultAsLoading: this.chatLoadingMoreDefaultAsLoading
  22259. };
  22260. },
  22261. // 最终的底部加载更多主题
  22262. finalLoadingMoreThemeStyle: function finalLoadingMoreThemeStyle() {
  22263. return this.loadingMoreThemeStyle.length ? this.loadingMoreThemeStyle : this.defaultThemeStyle;
  22264. },
  22265. // 最终的底部加载更多触发阈值
  22266. finalLowerThreshold: function finalLowerThreshold() {
  22267. return _zPagingUtils.default.convertToPx(this.lowerThreshold);
  22268. },
  22269. // 是否显示默认状态下的底部加载更多
  22270. showLoadingMoreDefault: function showLoadingMoreDefault() {
  22271. return this._showLoadingMore('Default');
  22272. },
  22273. // 是否显示加载中状态下的底部加载更多
  22274. showLoadingMoreLoading: function showLoadingMoreLoading() {
  22275. return this._showLoadingMore('Loading');
  22276. },
  22277. // 是否显示没有更多了状态下的底部加载更多
  22278. showLoadingMoreNoMore: function showLoadingMoreNoMore() {
  22279. return this._showLoadingMore('NoMore');
  22280. },
  22281. // 是否显示加载失败状态下的底部加载更多
  22282. showLoadingMoreFail: function showLoadingMoreFail() {
  22283. return this._showLoadingMore('Fail');
  22284. },
  22285. // 是否显示自定义状态下的底部加载更多
  22286. showLoadingMoreCustom: function showLoadingMoreCustom() {
  22287. return this._showLoadingMore('Custom');
  22288. },
  22289. // 底部加载更多固定高度
  22290. loadingMoreFixedHeight: function loadingMoreFixedHeight() {
  22291. return _zPagingUtils.default.addUnit('80rpx', this.unit);
  22292. }
  22293. },
  22294. methods: {
  22295. // 页面滚动到底部时通知z-paging进行进一步处理
  22296. pageReachBottom: function pageReachBottom() {
  22297. !this.useChatRecordMode && this.toBottomLoadingMoreEnabled && this._onLoadingMore('toBottom');
  22298. },
  22299. // 手动触发上拉加载更多(非必须,可依据具体需求使用)
  22300. doLoadMore: function doLoadMore(type) {
  22301. this._onLoadingMore(type);
  22302. },
  22303. // 通过@scroll事件检测是否滚动到了底部(顺带检测下是否滚动到了顶部)
  22304. _checkScrolledToBottom: function _checkScrolledToBottom(scrollDiff) {
  22305. var _this = this;
  22306. var checked = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
  22307. // 如果当前scroll-view高度未获取,则获取其高度
  22308. if (this.cacheScrollNodeHeight === -1) {
  22309. // 获取当前scroll-view高度
  22310. this._getNodeClientRect('.zp-scroll-view').then(function (res) {
  22311. if (res) {
  22312. var scrollNodeHeight = res[0].height;
  22313. // 缓存当前scroll-view高度,如果获取过了不再获取
  22314. _this.cacheScrollNodeHeight = scrollNodeHeight;
  22315. // // scrollDiff - this.cacheScrollNodeHeight = 当前滚动区域的顶部与内容底部的距离 - scroll-view高度 = 当前滚动区域的底部与内容底部的距离(也就是最终的与底部的距离)
  22316. if (scrollDiff - scrollNodeHeight <= _this.finalLowerThreshold) {
  22317. // 如果与底部的距离小于阈值,则判断为滚动到了底部,触发滚动到底部事件
  22318. _this._onLoadingMore('toBottom');
  22319. }
  22320. }
  22321. });
  22322. } else {
  22323. // scrollDiff - this.cacheScrollNodeHeight = 当前滚动区域的顶部与内容底部的距离 - scroll-view高度 = 当前滚动区域的底部与内容底部的距离(也就是最终的与底部的距离)
  22324. if (scrollDiff - this.cacheScrollNodeHeight <= this.finalLowerThreshold) {
  22325. // 如果与底部的距离小于阈值,则判断为滚动到了底部,触发滚动到底部事件
  22326. this._onLoadingMore('toBottom');
  22327. } else if (scrollDiff - this.cacheScrollNodeHeight <= 500 && !checked) {
  22328. // 如果与底部的距离小于500px,则获取当前滚动的位置,延迟150毫秒重复上述步骤再次检测(避免@scroll触发时获取的scrollTop不正确导致的其他问题,此时获取的scrollTop不一定可信)。防止因为部分性能较差安卓设备@scroll采样率过低导致的滚动到底部但是依然没有触发的问题
  22329. _zPagingUtils.default.delay(function () {
  22330. _this._getNodeClientRect('.zp-scroll-view', true, true).then(function (res) {
  22331. if (res) {
  22332. _this.oldScrollTop = res[0].scrollTop;
  22333. var newScrollDiff = res[0].scrollHeight - _this.oldScrollTop;
  22334. _this._checkScrolledToBottom(newScrollDiff, true);
  22335. }
  22336. });
  22337. }, 150, 'checkScrolledToBottomDelay');
  22338. }
  22339. // 检测一下是否已经滚动到了顶部了,因为在安卓中滚动到顶部时scrollTop不一定为0(和滚动到底部一样的原因),所以需要在scrollTop小于150px时,通过获取.zp-scroll-view的scrollTop再判断一下
  22340. if (this.oldScrollTop <= 150 && this.oldScrollTop !== 0) {
  22341. _zPagingUtils.default.delay(function () {
  22342. // 这里再判断一下是否确实已经滚动到顶部了,如果已经滚动到顶部了,则不用再判断了,再次判断的原因是可能150毫秒之后oldScrollTop才是0
  22343. if (_this.oldScrollTop !== 0) {
  22344. _this._getNodeClientRect('.zp-scroll-view', true, true).then(function (res) {
  22345. // 如果150毫秒后.zp-scroll-view的scrollTop为0,则认为已经滚动到了顶部了
  22346. if (res && res[0].scrollTop === 0 && _this.oldScrollTop !== 0) {
  22347. _this._onScrollToUpper();
  22348. }
  22349. });
  22350. }
  22351. }, 150, 'checkScrolledToTopDelay');
  22352. }
  22353. }
  22354. },
  22355. // 触发加载更多时调用,from:toBottom-滑动到底部触发;click-点击加载更多触发
  22356. _onLoadingMore: function _onLoadingMore() {
  22357. var _this2 = this;
  22358. var from = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'click';
  22359. // 如果是ios并且是滚动到底部的,则在滚动到底部时候尝试将列表设置为禁止滚动然后设置为允许滚动,以禁止底部bounce的效果
  22360. if (this.isIos && from === 'toBottom' && !this.scrollToBottomBounceEnabled && this.scrollEnable) {
  22361. this.scrollEnable = false;
  22362. this.$nextTick(function () {
  22363. _this2.scrollEnable = true;
  22364. });
  22365. }
  22366. // emit scrolltolower
  22367. this._emitScrollEvent('scrolltolower');
  22368. // 如果是只使用布局或下拉刷新 或者 禁用底部加载更多 或者 底部加载更多不是默认状态或加载失败状态 或者 是加载中状态 或者 空数据图已经展示了,则return,不触发内部加载更多逻辑
  22369. if (this.isOnly || !this.loadingMoreEnabled || !(this.loadingStatus === _zPagingEnum.default.More.Default || this.loadingStatus === _zPagingEnum.default.More.Fail) || this.loading || this.showEmpty) return;
  22370. // 处理加载更多数据
  22371. this._doLoadingMore();
  22372. },
  22373. // 处理开始加载更多
  22374. _doLoadingMore: function _doLoadingMore() {
  22375. var _this3 = this;
  22376. if (this.pageNo >= this.defaultPageNo && this.loadingStatus !== _zPagingEnum.default.More.NoMore) {
  22377. this.pageNo++;
  22378. this._startLoading(false);
  22379. if (this.isLocalPaging) {
  22380. // 如果是本地分页,则在组件内部对数据进行分页处理,不触发@query事件
  22381. this._localPagingQueryList(this.pageNo, this.defaultPageSize, this.localPagingLoadingTime, function (res) {
  22382. _this3.completeByTotal(res, _this3.totalLocalPagingList.length);
  22383. _this3.queryFrom = _zPagingEnum.default.QueryFrom.LoadMore;
  22384. });
  22385. } else {
  22386. // emit @query相关加载更多事件
  22387. this._emitQuery(this.pageNo, this.defaultPageSize, _zPagingEnum.default.QueryFrom.LoadMore);
  22388. this._callMyParentQuery();
  22389. }
  22390. // 设置当前加载状态为底部加载更多状态
  22391. this.loadingType = _zPagingEnum.default.LoadingType.LoadMore;
  22392. }
  22393. },
  22394. // (预处理)判断当没有更多数据且分页内容未超出z-paging时是否显示没有更多数据的view
  22395. _preCheckShowNoMoreInside: function _preCheckShowNoMoreInside(newVal, scrollViewNode, pagingContainerNode) {
  22396. var _this4 = this;
  22397. if (this.loadingStatus === _zPagingEnum.default.More.NoMore && this.hideNoMoreByLimit > 0 && newVal.length) {
  22398. this.showLoadingMore = newVal.length > this.hideNoMoreByLimit;
  22399. } else if (this.loadingStatus === _zPagingEnum.default.More.NoMore && this.hideNoMoreInside && newVal.length || this.insideMore && this.insideOfPaging !== false && newVal.length) {
  22400. this.$nextTick(function () {
  22401. _this4._checkShowNoMoreInside(newVal, scrollViewNode, pagingContainerNode);
  22402. });
  22403. if (this.insideMore && this.insideOfPaging !== false && newVal.length) {
  22404. this.showLoadingMore = newVal.length;
  22405. }
  22406. } else {
  22407. this.showLoadingMore = newVal.length;
  22408. }
  22409. },
  22410. // 判断当没有更多数据且分页内容未超出z-paging时是否显示没有更多数据的view
  22411. _checkShowNoMoreInside: function _checkShowNoMoreInside(totalData, oldScrollViewNode, oldPagingContainerNode) {
  22412. var _this5 = this;
  22413. return (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee() {
  22414. var scrollViewNode, scrollViewTotalH, pagingContainerNode, pagingContainerH, scrollViewH;
  22415. return _regenerator.default.wrap(function _callee$(_context) {
  22416. while (1) {
  22417. switch (_context.prev = _context.next) {
  22418. case 0:
  22419. _context.prev = 0;
  22420. _context.t0 = oldScrollViewNode;
  22421. if (_context.t0) {
  22422. _context.next = 6;
  22423. break;
  22424. }
  22425. _context.next = 5;
  22426. return _this5._getNodeClientRect('.zp-scroll-view');
  22427. case 5:
  22428. _context.t0 = _context.sent;
  22429. case 6:
  22430. scrollViewNode = _context.t0;
  22431. if (!_this5.usePageScroll) {
  22432. _context.next = 11;
  22433. break;
  22434. }
  22435. if (scrollViewNode) {
  22436. // 获取滚动内容总高度
  22437. scrollViewTotalH = scrollViewNode[0].top + scrollViewNode[0].height; // 如果滚动内容总高度小于窗口高度,则认为内容未超出z-paging
  22438. _this5.insideOfPaging = scrollViewTotalH < _this5.windowHeight;
  22439. // 如果需要没有更多数据时,隐藏底部加载更多view,并且内容未超过z-paging,则隐藏底部加载更多
  22440. if (_this5.hideNoMoreInside) {
  22441. _this5.showLoadingMore = !_this5.insideOfPaging;
  22442. }
  22443. // 如果需要内容未超过z-paging时自动加载更多,则触发加载更多
  22444. _this5._updateInsideOfPaging();
  22445. }
  22446. _context.next = 22;
  22447. break;
  22448. case 11:
  22449. _context.t1 = oldPagingContainerNode;
  22450. if (_context.t1) {
  22451. _context.next = 16;
  22452. break;
  22453. }
  22454. _context.next = 15;
  22455. return _this5._getNodeClientRect('.zp-paging-container-content');
  22456. case 15:
  22457. _context.t1 = _context.sent;
  22458. case 16:
  22459. pagingContainerNode = _context.t1;
  22460. // 获取滚动内容总高度
  22461. pagingContainerH = pagingContainerNode ? pagingContainerNode[0].height : 0; // 获取z-paging内置scroll-view高度
  22462. scrollViewH = scrollViewNode ? scrollViewNode[0].height : 0; // 如果滚动内容总高度小于z-paging内置scroll-view高度,则认为内容未超出z-paging
  22463. _this5.insideOfPaging = pagingContainerH < scrollViewH;
  22464. if (_this5.hideNoMoreInside) {
  22465. _this5.showLoadingMore = !_this5.insideOfPaging;
  22466. }
  22467. // 如果需要内容未超过z-paging时自动加载更多,则触发加载更多
  22468. _this5._updateInsideOfPaging();
  22469. case 22:
  22470. _context.next = 29;
  22471. break;
  22472. case 24:
  22473. _context.prev = 24;
  22474. _context.t2 = _context["catch"](0);
  22475. // 如果发生了异常,判断totalData数组长度为0,则认为内容未超出z-paging
  22476. _this5.insideOfPaging = !totalData.length;
  22477. if (_this5.hideNoMoreInside) {
  22478. _this5.showLoadingMore = !_this5.insideOfPaging;
  22479. }
  22480. // 如果需要内容未超过z-paging时自动加载更多,则触发加载更多
  22481. _this5._updateInsideOfPaging();
  22482. case 29:
  22483. case "end":
  22484. return _context.stop();
  22485. }
  22486. }
  22487. }, _callee, null, [[0, 24]]);
  22488. }))();
  22489. },
  22490. // 是否要展示上拉加载更多view
  22491. _showLoadingMore: function _showLoadingMore(type) {
  22492. if (!this.showLoadingMoreWhenReload && (!(this.loadingStatus === _zPagingEnum.default.More.Default ? this.nShowBottom : true) || !this.realTotalData.length)) return false;
  22493. if ((!this.showLoadingMoreWhenReload || this.isUserPullDown || this.loadingStatus !== _zPagingEnum.default.More.Loading) && !this.showLoadingMore || !this.loadingMoreEnabled && (!this.showLoadingMoreWhenReload || this.isUserPullDown || this.loadingStatus !== _zPagingEnum.default.More.Loading) || this.isOnly) {
  22494. return false;
  22495. }
  22496. if (this.useChatRecordMode && type !== 'Loading') return false;
  22497. if (!this.zSlots) return false;
  22498. if (type === 'Custom') {
  22499. return this.showDefaultLoadingMoreText && !(this.loadingStatus === _zPagingEnum.default.More.NoMore && !this.showLoadingMoreNoMoreView);
  22500. }
  22501. var res = this.loadingStatus === _zPagingEnum.default.More[type] && this.zSlots["loadingMore".concat(type)] && (type === 'NoMore' ? this.showLoadingMoreNoMoreView : true);
  22502. if (res) {}
  22503. return res;
  22504. }
  22505. }
  22506. };
  22507. exports.default = _default;
  22508. /***/ }),
  22509. /* 267 */
  22510. /*!*****************************************************************************************************!*\
  22511. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/z-paging/components/z-paging/js/modules/loading.js ***!
  22512. \*****************************************************************************************************/
  22513. /*! no static exports found */
  22514. /***/ (function(module, exports, __webpack_require__) {
  22515. "use strict";
  22516. /* WEBPACK VAR INJECTION */(function(uni) {
  22517. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  22518. Object.defineProperty(exports, "__esModule", {
  22519. value: true
  22520. });
  22521. exports.default = void 0;
  22522. var _zPagingUtils = _interopRequireDefault(__webpack_require__(/*! .././z-paging-utils */ 252));
  22523. var _zPagingEnum = _interopRequireDefault(__webpack_require__(/*! .././z-paging-enum */ 256));
  22524. // [z-paging]loading相关模块
  22525. var _default = {
  22526. props: {
  22527. // 第一次加载后自动隐藏loading slot,默认为是
  22528. autoHideLoadingAfterFirstLoaded: {
  22529. type: Boolean,
  22530. default: _zPagingUtils.default.gc('autoHideLoadingAfterFirstLoaded', true)
  22531. },
  22532. // loading slot是否铺满屏幕并固定,默认为否
  22533. loadingFullFixed: {
  22534. type: Boolean,
  22535. default: _zPagingUtils.default.gc('loadingFullFixed', false)
  22536. },
  22537. // 是否自动显示系统Loading:即uni.showLoading,若开启则将在刷新列表时(调用reload、refresh时)显示,下拉刷新和滚动到底部加载更多不会显示,默认为false。
  22538. autoShowSystemLoading: {
  22539. type: Boolean,
  22540. default: _zPagingUtils.default.gc('autoShowSystemLoading', false)
  22541. },
  22542. // 显示系统Loading时是否显示透明蒙层,防止触摸穿透,默认为是(H5、App、微信小程序、百度小程序有效)
  22543. systemLoadingMask: {
  22544. type: Boolean,
  22545. default: _zPagingUtils.default.gc('systemLoadingMask', true)
  22546. },
  22547. // 显示系统Loading时显示的文字,默认为"加载中"
  22548. systemLoadingText: {
  22549. type: [String, Object],
  22550. default: _zPagingUtils.default.gc('systemLoadingText', null)
  22551. }
  22552. },
  22553. data: function data() {
  22554. return {
  22555. loading: false,
  22556. loadingForNow: false
  22557. };
  22558. },
  22559. watch: {
  22560. // loading状态
  22561. loadingStatus: function loadingStatus(newVal) {
  22562. var _this = this;
  22563. this.$emit('loadingStatusChange', newVal);
  22564. this.$nextTick(function () {
  22565. _this.loadingStatusAfterRender = newVal;
  22566. });
  22567. if (this.useChatRecordMode) {
  22568. if (this.isFirstPage && (newVal === _zPagingEnum.default.More.NoMore || newVal === _zPagingEnum.default.More.Fail)) {
  22569. this.isFirstPageAndNoMore = true;
  22570. return;
  22571. }
  22572. }
  22573. this.isFirstPageAndNoMore = false;
  22574. },
  22575. loading: function loading(newVal) {
  22576. if (newVal) {
  22577. this.loadingForNow = newVal;
  22578. }
  22579. }
  22580. },
  22581. computed: {
  22582. // 是否显示loading
  22583. showLoading: function showLoading() {
  22584. if (this.firstPageLoaded || !this.loading || !this.loadingForNow) return false;
  22585. if (this.finalShowSystemLoading) {
  22586. // 显示系统loading
  22587. uni.showLoading({
  22588. title: this.finalSystemLoadingText,
  22589. mask: this.systemLoadingMask
  22590. });
  22591. }
  22592. return this.autoHideLoadingAfterFirstLoaded ? this.fromEmptyViewReload ? true : !this.pagingLoaded : this.loadingType === _zPagingEnum.default.LoadingType.Refresher;
  22593. },
  22594. // 最终的是否显示系统loading
  22595. finalShowSystemLoading: function finalShowSystemLoading() {
  22596. return this.autoShowSystemLoading && this.loadingType === _zPagingEnum.default.LoadingType.Refresher;
  22597. }
  22598. },
  22599. methods: {
  22600. // 处理开始加载更多状态
  22601. _startLoading: function _startLoading() {
  22602. var isReload = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;
  22603. if (this.showLoadingMoreWhenReload && !this.isUserPullDown || !isReload) {
  22604. this.loadingStatus = _zPagingEnum.default.More.Loading;
  22605. }
  22606. this.loading = true;
  22607. },
  22608. // 停止系统loading和refresh
  22609. _endSystemLoadingAndRefresh: function _endSystemLoadingAndRefresh() {
  22610. this.finalShowSystemLoading && uni.hideLoading();
  22611. !this.useCustomRefresher && uni.stopPullDownRefresh();
  22612. }
  22613. }
  22614. };
  22615. exports.default = _default;
  22616. /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./node_modules/@dcloudio/uni-mp-toutiao/dist/index.js */ 1)["default"]))
  22617. /***/ }),
  22618. /* 268 */
  22619. /*!**************************************************************************************************************!*\
  22620. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/z-paging/components/z-paging/js/modules/chat-record-mode.js ***!
  22621. \**************************************************************************************************************/
  22622. /*! no static exports found */
  22623. /***/ (function(module, exports, __webpack_require__) {
  22624. "use strict";
  22625. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  22626. Object.defineProperty(exports, "__esModule", {
  22627. value: true
  22628. });
  22629. exports.default = void 0;
  22630. var _zPagingUtils = _interopRequireDefault(__webpack_require__(/*! .././z-paging-utils */ 252));
  22631. // [z-paging]聊天记录模式模块
  22632. var _default = {
  22633. props: {
  22634. // 使用聊天记录模式,默认为否
  22635. useChatRecordMode: {
  22636. type: Boolean,
  22637. default: _zPagingUtils.default.gc('useChatRecordMode', false)
  22638. },
  22639. // 使用聊天记录模式时滚动到顶部后,列表垂直移动偏移距离。默认0rpx。单位px(暂时无效)
  22640. chatRecordMoreOffset: {
  22641. type: [Number, String],
  22642. default: _zPagingUtils.default.gc('chatRecordMoreOffset', '0rpx')
  22643. },
  22644. // 使用聊天记录模式时是否自动隐藏键盘:在用户触摸列表时候自动隐藏键盘,默认为是
  22645. autoHideKeyboardWhenChat: {
  22646. type: Boolean,
  22647. default: _zPagingUtils.default.gc('autoHideKeyboardWhenChat', true)
  22648. },
  22649. // 使用聊天记录模式中键盘弹出时是否自动调整slot="bottom"高度,默认为是
  22650. autoAdjustPositionWhenChat: {
  22651. type: Boolean,
  22652. default: _zPagingUtils.default.gc('autoAdjustPositionWhenChat', true)
  22653. },
  22654. // 使用聊天记录模式中键盘弹出时占位高度偏移距离。默认0rpx。单位px
  22655. chatAdjustPositionOffset: {
  22656. type: [Number, String],
  22657. default: _zPagingUtils.default.gc('chatAdjustPositionOffset', '0rpx')
  22658. },
  22659. // 使用聊天记录模式中键盘弹出时是否自动滚动到底部,默认为否
  22660. autoToBottomWhenChat: {
  22661. type: Boolean,
  22662. default: _zPagingUtils.default.gc('autoToBottomWhenChat', false)
  22663. },
  22664. // 使用聊天记录模式中reload时是否显示chatLoading,默认为否
  22665. showChatLoadingWhenReload: {
  22666. type: Boolean,
  22667. default: _zPagingUtils.default.gc('showChatLoadingWhenReload', false)
  22668. },
  22669. // 在聊天记录模式中滑动到顶部状态为默认状态时,以加载中的状态展示,默认为是。若设置为否,则默认会显示【点击加载更多】,然后才会显示loading
  22670. chatLoadingMoreDefaultAsLoading: {
  22671. type: Boolean,
  22672. default: _zPagingUtils.default.gc('chatLoadingMoreDefaultAsLoading', true)
  22673. }
  22674. },
  22675. data: function data() {
  22676. return {
  22677. // 键盘高度
  22678. keyboardHeight: 0,
  22679. // 键盘高度是否未改变,此时占位高度变化不需要动画效果
  22680. isKeyboardHeightChanged: false
  22681. };
  22682. },
  22683. computed: {
  22684. finalChatRecordMoreOffset: function finalChatRecordMoreOffset() {
  22685. return _zPagingUtils.default.convertToPx(this.chatRecordMoreOffset);
  22686. },
  22687. finalChatAdjustPositionOffset: function finalChatAdjustPositionOffset() {
  22688. return _zPagingUtils.default.convertToPx(this.chatAdjustPositionOffset);
  22689. },
  22690. // 聊天记录模式旋转180度style
  22691. chatRecordRotateStyle: function chatRecordRotateStyle() {
  22692. var _this = this;
  22693. var cellStyle;
  22694. // 在vue中,直接将列表倒置,因此在vue的cell中,也直接写style="transform: scaleY(-1)"转回来即可。
  22695. cellStyle = this.useChatRecordMode ? {
  22696. transform: 'scaleY(-1)'
  22697. } : {};
  22698. // 在nvue中,需要考虑数据量不满一页的情况,因为nvue中的list无法通过flex-end修改不满一页的起始位置,会导致不满一页时列表数据从底部开始,因此需要特别判断
  22699. // 当数据不满一屏的时候,不进行列表倒置
  22700. this.$emit('update:cellStyle', cellStyle);
  22701. this.$emit('cellStyleChange', cellStyle);
  22702. // 在聊天记录模式中,如果列表没有倒置并且当前是第一页,则需要自动滚动到最底部
  22703. this.$nextTick(function () {
  22704. if (_this.isFirstPage && _this.isChatRecordModeAndNotInversion) {
  22705. _this.$nextTick(function () {
  22706. // 这里多次触发滚动到底部是为了避免在某些情况下,即使是在nextTick但是cell未渲染完毕导致滚动到底部位置不正确的问题
  22707. _this._scrollToBottom(false);
  22708. _zPagingUtils.default.delay(function () {
  22709. _this._scrollToBottom(false);
  22710. _zPagingUtils.default.delay(function () {
  22711. _this._scrollToBottom(false);
  22712. }, 50);
  22713. }, 50);
  22714. });
  22715. }
  22716. });
  22717. return cellStyle;
  22718. },
  22719. // 是否是聊天记录列表并且有配置transform
  22720. isChatRecordModeHasTransform: function isChatRecordModeHasTransform() {
  22721. return this.useChatRecordMode && this.chatRecordRotateStyle && this.chatRecordRotateStyle.transform;
  22722. },
  22723. // 是否是聊天记录列表并且列表未倒置
  22724. isChatRecordModeAndNotInversion: function isChatRecordModeAndNotInversion() {
  22725. return this.isChatRecordModeHasTransform && this.chatRecordRotateStyle.transform === 'scaleY(1)';
  22726. },
  22727. // 是否是聊天记录列表并且列表倒置
  22728. isChatRecordModeAndInversion: function isChatRecordModeAndInversion() {
  22729. return this.isChatRecordModeHasTransform && this.chatRecordRotateStyle.transform === 'scaleY(-1)';
  22730. },
  22731. // 最终的聊天记录模式中底部安全区域的高度,如果开启了底部安全区域并且键盘未弹出,则添加底部区域高度
  22732. chatRecordModeSafeAreaBottom: function chatRecordModeSafeAreaBottom() {
  22733. return this.safeAreaInsetBottom && !this.keyboardHeight ? this.safeAreaBottom : 0;
  22734. }
  22735. },
  22736. mounted: function mounted() {
  22737. this.addKeyboardHeightChangeListener();
  22738. },
  22739. methods: {
  22740. // 添加聊天记录
  22741. addChatRecordData: function addChatRecordData(data) {
  22742. var toBottom = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
  22743. var toBottomWithAnimate = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : true;
  22744. if (!this.useChatRecordMode) return;
  22745. this.isTotalChangeFromAddData = true;
  22746. this.addDataFromTop(data, toBottom, toBottomWithAnimate);
  22747. },
  22748. // 手动触发滚动到顶部加载更多,聊天记录模式时有效
  22749. doChatRecordLoadMore: function doChatRecordLoadMore() {
  22750. this.useChatRecordMode && this._onLoadingMore('click');
  22751. },
  22752. // 手动添加键盘高度变化监听
  22753. addKeyboardHeightChangeListener: function addKeyboardHeightChangeListener() {
  22754. // 监听键盘高度变化(H5、百度小程序、抖音小程序、飞书小程序不支持)
  22755. },
  22756. // 处理键盘高度变化
  22757. _handleKeyboardHeightChange: function _handleKeyboardHeightChange(res) {
  22758. var _this2 = this;
  22759. this.$emit('keyboardHeightChange', res);
  22760. if (this.autoAdjustPositionWhenChat) {
  22761. this.isKeyboardHeightChanged = true;
  22762. this.keyboardHeight = res.height > 0 ? res.height + this.finalChatAdjustPositionOffset : res.height;
  22763. }
  22764. if (this.autoToBottomWhenChat && this.keyboardHeight > 0) {
  22765. _zPagingUtils.default.delay(function () {
  22766. _this2.scrollToBottom(false);
  22767. _zPagingUtils.default.delay(function () {
  22768. _this2.scrollToBottom(false);
  22769. });
  22770. });
  22771. }
  22772. }
  22773. }
  22774. };
  22775. exports.default = _default;
  22776. /***/ }),
  22777. /* 269 */
  22778. /*!******************************************************************************************************!*\
  22779. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/z-paging/components/z-paging/js/modules/scroller.js ***!
  22780. \******************************************************************************************************/
  22781. /*! no static exports found */
  22782. /***/ (function(module, exports, __webpack_require__) {
  22783. "use strict";
  22784. /* WEBPACK VAR INJECTION */(function(uni) {
  22785. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  22786. Object.defineProperty(exports, "__esModule", {
  22787. value: true
  22788. });
  22789. exports.default = void 0;
  22790. var _regenerator = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/regenerator */ 54));
  22791. var _asyncToGenerator2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/asyncToGenerator */ 56));
  22792. var _zPagingUtils = _interopRequireDefault(__webpack_require__(/*! .././z-paging-utils */ 252));
  22793. var _zPagingEnum = _interopRequireDefault(__webpack_require__(/*! .././z-paging-enum */ 256));
  22794. // [z-paging]scroll相关模块
  22795. var _default = {
  22796. props: {
  22797. // 使用页面滚动,默认为否,当设置为是时则使用页面的滚动而非此组件内部的scroll-view的滚动,使用页面滚动时z-paging无需设置确定的高度且对于长列表展示性能更高,但配置会略微繁琐
  22798. usePageScroll: {
  22799. type: Boolean,
  22800. default: _zPagingUtils.default.gc('usePageScroll', false)
  22801. },
  22802. // 是否可以滚动,使用内置scroll-view和nvue时有效,默认为是
  22803. scrollable: {
  22804. type: Boolean,
  22805. default: _zPagingUtils.default.gc('scrollable', true)
  22806. },
  22807. // 控制是否出现滚动条,默认为是
  22808. showScrollbar: {
  22809. type: Boolean,
  22810. default: _zPagingUtils.default.gc('showScrollbar', true)
  22811. },
  22812. // 是否允许横向滚动,默认为否
  22813. scrollX: {
  22814. type: Boolean,
  22815. default: _zPagingUtils.default.gc('scrollX', false)
  22816. },
  22817. // iOS设备上滚动到顶部时是否允许回弹效果,默认为否。关闭回弹效果后可使滚动到顶部与下拉刷新更连贯,但是有吸顶view时滚动到顶部时可能出现抖动。
  22818. scrollToTopBounceEnabled: {
  22819. type: Boolean,
  22820. default: _zPagingUtils.default.gc('scrollToTopBounceEnabled', false)
  22821. },
  22822. // iOS设备上滚动到底部时是否允许回弹效果,默认为是。
  22823. scrollToBottomBounceEnabled: {
  22824. type: Boolean,
  22825. default: _zPagingUtils.default.gc('scrollToBottomBounceEnabled', true)
  22826. },
  22827. // 在设置滚动条位置时使用动画过渡,默认为否
  22828. scrollWithAnimation: {
  22829. type: Boolean,
  22830. default: _zPagingUtils.default.gc('scrollWithAnimation', false)
  22831. },
  22832. // 值应为某子元素id(id不能以数字开头)。设置哪个方向可滚动,则在哪个方向滚动到该元素
  22833. scrollIntoView: {
  22834. type: String,
  22835. default: _zPagingUtils.default.gc('scrollIntoView', '')
  22836. },
  22837. // z-paging是否使用swiper-item或其他父组件包裹,默认为否,此属性为了解决vue3+(微信小程序或QQ小程序)中,scrollIntoViewById和scrollIntoViewByIndex因无法获取节点信息导致滚动到指定view无效的问题
  22838. inSwiperSlot: {
  22839. type: Boolean,
  22840. default: false
  22841. }
  22842. },
  22843. data: function data() {
  22844. return {
  22845. scrollTop: 0,
  22846. oldScrollTop: 0,
  22847. scrollLeft: 0,
  22848. oldScrollLeft: 0,
  22849. scrollViewStyle: {},
  22850. scrollViewContainerStyle: {},
  22851. scrollViewInStyle: {},
  22852. pageScrollTop: -1,
  22853. scrollEnable: true,
  22854. privateScrollWithAnimation: -1,
  22855. cacheScrollNodeHeight: -1,
  22856. superContentHeight: 0,
  22857. lastScrollHeight: 0,
  22858. lastScrollDirection: '',
  22859. setContentHeightPending: false
  22860. };
  22861. },
  22862. watch: {
  22863. oldScrollTop: function oldScrollTop(newVal) {
  22864. !this.usePageScroll && this._scrollTopChange(newVal, false);
  22865. },
  22866. pageScrollTop: function pageScrollTop(newVal) {
  22867. this.usePageScroll && this._scrollTopChange(newVal, true);
  22868. },
  22869. usePageScroll: {
  22870. handler: function handler(newVal) {
  22871. this.loaded && this.autoHeight && this._setAutoHeight(!newVal);
  22872. },
  22873. immediate: true
  22874. },
  22875. finalScrollTop: function finalScrollTop(newVal) {
  22876. this.renderPropScrollTop = newVal < 6 ? 0 : 10;
  22877. }
  22878. },
  22879. computed: {
  22880. finalScrollWithAnimation: function finalScrollWithAnimation() {
  22881. if (this.privateScrollWithAnimation !== -1) {
  22882. return this.privateScrollWithAnimation === 1;
  22883. }
  22884. return this.scrollWithAnimation;
  22885. },
  22886. finalScrollViewStyle: function finalScrollViewStyle() {
  22887. if (this.superContentZIndex != 1) {
  22888. this.scrollViewStyle['z-index'] = this.superContentZIndex;
  22889. this.scrollViewStyle['position'] = 'relative';
  22890. }
  22891. return this.scrollViewStyle;
  22892. },
  22893. finalScrollTop: function finalScrollTop() {
  22894. return this.usePageScroll ? this.pageScrollTop : this.oldScrollTop;
  22895. },
  22896. // 当前是否是旧版webview
  22897. finalIsOldWebView: function finalIsOldWebView() {
  22898. return this.isOldWebView && !this.usePageScroll;
  22899. },
  22900. // 当前scroll-view/list-view是否允许滚动
  22901. finalScrollable: function finalScrollable() {
  22902. return this.scrollable && !this.usePageScroll && this.scrollEnable && (this.refresherCompleteScrollable ? true : this.refresherStatus !== _zPagingEnum.default.Refresher.Complete) && (this.refresherRefreshingScrollable ? true : this.refresherStatus !== _zPagingEnum.default.Refresher.Loading);
  22903. }
  22904. },
  22905. methods: {
  22906. // 滚动到顶部,animate为是否展示滚动动画,默认为是
  22907. scrollToTop: function scrollToTop(animate) {
  22908. var _this = this;
  22909. var checkReverse = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
  22910. // 如果是聊天记录模式并且列表倒置了,则滚动到顶部实际上是滚动到底部
  22911. if (this.useChatRecordMode && checkReverse && !this.isChatRecordModeAndNotInversion) {
  22912. this.scrollToBottom(animate, false);
  22913. return;
  22914. }
  22915. this.$nextTick(function () {
  22916. _this._scrollToTop(animate, false);
  22917. });
  22918. },
  22919. // 滚动到底部,animate为是否展示滚动动画,默认为是
  22920. scrollToBottom: function scrollToBottom(animate) {
  22921. var _this2 = this;
  22922. var checkReverse = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
  22923. // 如果是聊天记录模式并且列表倒置了,则滚动到底部实际上是滚动到顶部
  22924. if (this.useChatRecordMode && checkReverse && !this.isChatRecordModeAndNotInversion) {
  22925. this.scrollToTop(animate, false);
  22926. return;
  22927. }
  22928. this.$nextTick(function () {
  22929. _this2._scrollToBottom(animate);
  22930. });
  22931. },
  22932. // 滚动到指定view(vue中有效)。sel为需要滚动的view的id值,不包含"#";offset为偏移量,单位为px;animate为是否展示滚动动画,默认为否
  22933. scrollIntoViewById: function scrollIntoViewById(sel, offset, animate) {
  22934. this._scrollIntoView(sel, offset, animate);
  22935. },
  22936. // 滚动到指定view(vue中有效)。nodeTop为需要滚动的view的top值(通过uni.createSelectorQuery()获取);offset为偏移量,单位为px;animate为是否展示滚动动画,默认为否
  22937. scrollIntoViewByNodeTop: function scrollIntoViewByNodeTop(nodeTop, offset, animate) {
  22938. var _this3 = this;
  22939. this.scrollTop = this.oldScrollTop;
  22940. this.$nextTick(function () {
  22941. _this3._scrollIntoViewByNodeTop(nodeTop, offset, animate);
  22942. });
  22943. },
  22944. // y轴滚动到指定位置(vue中有效)。y为与顶部的距离,单位为px;offset为偏移量,单位为px;animate为是否展示滚动动画,默认为否
  22945. scrollToY: function scrollToY(y, offset, animate) {
  22946. var _this4 = this;
  22947. this.scrollTop = this.oldScrollTop;
  22948. this.$nextTick(function () {
  22949. _this4._scrollToY(y, offset, animate);
  22950. });
  22951. },
  22952. // x轴滚动到指定位置(非页面滚动且在vue中有效)。x为与左侧的距离,单位为px;offset为偏移量,单位为px;animate为是否展示滚动动画,默认为否
  22953. scrollToX: function scrollToX(x, offset, animate) {
  22954. var _this5 = this;
  22955. this.scrollLeft = this.oldScrollLeft;
  22956. this.$nextTick(function () {
  22957. _this5._scrollToX(x, offset, animate);
  22958. });
  22959. },
  22960. // 滚动到指定view(nvue中和虚拟列表中有效)。index为需要滚动的view的index(第几个,从0开始);offset为偏移量,单位为px;animate为是否展示滚动动画,默认为否
  22961. scrollIntoViewByIndex: function scrollIntoViewByIndex(index, offset, animate) {
  22962. var _this6 = this;
  22963. if (index >= this.realTotalData.length) {
  22964. _zPagingUtils.default.consoleErr('当前滚动的index超出已渲染列表长度,请先通过refreshToPage加载到对应index页并等待渲染成功后再调用此方法!');
  22965. return;
  22966. }
  22967. this.$nextTick(function () {
  22968. if (_this6.finalUseVirtualList) {
  22969. var isCellFixed = _this6.cellHeightMode === _zPagingEnum.default.CellHeightMode.Fixed;
  22970. _zPagingUtils.default.delay(function () {
  22971. if (_this6.finalUseVirtualList) {
  22972. // 虚拟列表 + 每个cell高度完全相同模式下,此时滚动到对应index的cell就是滚动到scrollTop = cellHeight * index的位置
  22973. // 虚拟列表 + 高度是动态非固定的模式下,此时滚动到对应index的cell就是滚动到scrollTop = 缓存的cell高度数组中第index个的lastTotalHeight的位置
  22974. var scrollTop = isCellFixed ? _this6.virtualCellHeight * index : _this6.virtualHeightCacheList[index].lastTotalHeight;
  22975. _this6.scrollToY(scrollTop, offset, animate);
  22976. }
  22977. }, isCellFixed ? 0 : 100);
  22978. }
  22979. });
  22980. },
  22981. // 滚动到指定view(nvue中有效)。view为需要滚动的view(通过`this.$refs.xxx`获取),不包含"#";offset为偏移量,单位为px;animate为是否展示滚动动画,默认为否
  22982. scrollIntoViewByView: function scrollIntoViewByView(view, offset, animate) {
  22983. this._scrollIntoView(view, offset, animate);
  22984. },
  22985. // 当使用页面滚动并且自定义下拉刷新时,请在页面的onPageScroll中调用此方法,告知z-paging当前的pageScrollTop,否则会导致在任意位置都可以下拉刷新
  22986. updatePageScrollTop: function updatePageScrollTop(value) {
  22987. this.pageScrollTop = value;
  22988. },
  22989. // 当使用页面滚动并且设置了slot="top"时,默认初次加载会自动获取其高度,并使内部容器下移,当slot="top"的view高度动态改变时,在其高度需要更新时调用此方法
  22990. updatePageScrollTopHeight: function updatePageScrollTopHeight() {
  22991. this._updatePageScrollTopOrBottomHeight('top');
  22992. },
  22993. // 当使用页面滚动并且设置了slot="bottom"时,默认初次加载会自动获取其高度,并使内部容器下移,当slot="bottom"的view高度动态改变时,在其高度需要更新时调用此方法
  22994. updatePageScrollBottomHeight: function updatePageScrollBottomHeight() {
  22995. this._updatePageScrollTopOrBottomHeight('bottom');
  22996. },
  22997. // 更新slot="left"和slot="right"宽度,当slot="left"或slot="right"宽度动态改变时调用
  22998. updateLeftAndRightWidth: function updateLeftAndRightWidth() {
  22999. var _this7 = this;
  23000. if (!this.finalIsOldWebView) return;
  23001. this.$nextTick(function () {
  23002. return _this7._updateLeftAndRightWidth(_this7.scrollViewContainerStyle, 'zp-page');
  23003. });
  23004. },
  23005. // 更新z-paging内置scroll-view的scrollTop
  23006. updateScrollViewScrollTop: function updateScrollViewScrollTop(scrollTop) {
  23007. var _this8 = this;
  23008. var animate = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
  23009. this._updatePrivateScrollWithAnimation(animate);
  23010. this.scrollTop = this.oldScrollTop;
  23011. this.$nextTick(function () {
  23012. _this8.scrollTop = scrollTop;
  23013. _this8.oldScrollTop = _this8.scrollTop;
  23014. });
  23015. },
  23016. // 当滚动到顶部时
  23017. _onScrollToUpper: function _onScrollToUpper() {
  23018. var _this9 = this;
  23019. this._emitScrollEvent('scrolltoupper');
  23020. this.$emit('scrollTopChange', 0);
  23021. this.$nextTick(function () {
  23022. _this9.oldScrollTop = 0;
  23023. });
  23024. },
  23025. // 当滚动到底部时
  23026. _onScrollToLower: function _onScrollToLower(e) {
  23027. (!e.detail || !e.detail.direction || e.detail.direction === 'bottom') && this.toBottomLoadingMoreEnabled && this._onLoadingMore(this.useChatRecordMode ? 'click' : 'toBottom');
  23028. },
  23029. // 滚动到顶部
  23030. _scrollToTop: function _scrollToTop() {
  23031. var _this10 = this;
  23032. var animate = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : true;
  23033. var isPrivate = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
  23034. if (this.usePageScroll) {
  23035. this.$nextTick(function () {
  23036. uni.pageScrollTo({
  23037. scrollTop: 0,
  23038. duration: animate ? 100 : 0
  23039. });
  23040. });
  23041. return;
  23042. }
  23043. this._updatePrivateScrollWithAnimation(animate);
  23044. this.scrollTop = this.oldScrollTop;
  23045. this.$nextTick(function () {
  23046. _this10.scrollTop = 0;
  23047. _this10.oldScrollTop = _this10.scrollTop;
  23048. });
  23049. _zPagingUtils.default.delay(function () {
  23050. _this10.scrollTop = _this10.oldScrollTop;
  23051. _this10.$nextTick(function () {
  23052. _this10.scrollTop = 0;
  23053. _this10.oldScrollTop = _this10.scrollTop;
  23054. });
  23055. }, 500);
  23056. },
  23057. // 滚动到底部
  23058. _scrollToBottom: function _scrollToBottom() {
  23059. var _arguments = arguments,
  23060. _this11 = this;
  23061. return (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee() {
  23062. var animate, pagingContainerNode, scrollViewNode, pagingContainerH, scrollViewH;
  23063. return _regenerator.default.wrap(function _callee$(_context) {
  23064. while (1) {
  23065. switch (_context.prev = _context.next) {
  23066. case 0:
  23067. animate = _arguments.length > 0 && _arguments[0] !== undefined ? _arguments[0] : true;
  23068. if (!_this11.usePageScroll) {
  23069. _context.next = 4;
  23070. break;
  23071. }
  23072. _this11.$nextTick(function () {
  23073. uni.pageScrollTo({
  23074. scrollTop: Number.MAX_VALUE,
  23075. duration: animate ? 100 : 0
  23076. });
  23077. });
  23078. return _context.abrupt("return");
  23079. case 4:
  23080. _context.prev = 4;
  23081. _this11._updatePrivateScrollWithAnimation(animate);
  23082. _context.next = 8;
  23083. return _this11._getNodeClientRect('.zp-paging-container');
  23084. case 8:
  23085. pagingContainerNode = _context.sent;
  23086. _context.next = 11;
  23087. return _this11._getNodeClientRect('.zp-scroll-view');
  23088. case 11:
  23089. scrollViewNode = _context.sent;
  23090. pagingContainerH = pagingContainerNode ? pagingContainerNode[0].height : 0;
  23091. scrollViewH = scrollViewNode ? scrollViewNode[0].height : 0;
  23092. if (pagingContainerH > scrollViewH) {
  23093. _this11.scrollTop = _this11.oldScrollTop;
  23094. _this11.$nextTick(function () {
  23095. _this11.scrollTop = pagingContainerH - scrollViewH + _this11.virtualPlaceholderTopHeight;
  23096. _this11.oldScrollTop = _this11.scrollTop;
  23097. });
  23098. }
  23099. _context.next = 19;
  23100. break;
  23101. case 17:
  23102. _context.prev = 17;
  23103. _context.t0 = _context["catch"](4);
  23104. case 19:
  23105. case "end":
  23106. return _context.stop();
  23107. }
  23108. }
  23109. }, _callee, null, [[4, 17]]);
  23110. }))();
  23111. },
  23112. // 滚动到指定view
  23113. _scrollIntoView: function _scrollIntoView(sel) {
  23114. var _this12 = this;
  23115. var offset = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
  23116. var animate = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
  23117. var finishCallback = arguments.length > 3 ? arguments[3] : undefined;
  23118. try {
  23119. this.scrollTop = this.oldScrollTop;
  23120. this.$nextTick(function () {
  23121. // 获取指定view的节点信息
  23122. var inDom = false;
  23123. // 在vue3+(微信小程序或QQ小程序)中,无法获取节点信息导致滚动到指定view无效的问题
  23124. // 通过uni.createSelectorQuery().in(this.$parent)来解决此问题
  23125. _this12._getNodeClientRect('#' + sel.replace('#', ''), inDom).then(function (node) {
  23126. if (node) {
  23127. // 获取zp-scroll-view-container的节点信息
  23128. _this12._getNodeClientRect('.zp-scroll-view-container').then(function (svContainerNode) {
  23129. if (svContainerNode) {
  23130. // 滚动的top为指定view的top减zp-scroll-view-container的top,因为指定view的top是相对于整个窗口的,需要考虑相对的位置关系
  23131. _this12._scrollIntoViewByNodeTop(node[0].top - svContainerNode[0].top, offset, animate);
  23132. finishCallback && finishCallback();
  23133. }
  23134. });
  23135. } else {
  23136. _zPagingUtils.default.consoleErr("\u65E0\u6CD5\u83B7\u53D6".concat(sel, "\u7684\u8282\u70B9\u4FE1\u606F\uFF0C\u8BF7\u68C0\u67E5\uFF01"));
  23137. }
  23138. });
  23139. });
  23140. } catch (e) {}
  23141. },
  23142. // 通过nodeTop滚动到指定view
  23143. _scrollIntoViewByNodeTop: function _scrollIntoViewByNodeTop(nodeTop) {
  23144. var _this13 = this;
  23145. var offset = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
  23146. var animate = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
  23147. // 如果是聊天记录模式并且列表倒置了,此时nodeTop需要等于scroll-view高度 - nodeTop
  23148. if (this.isChatRecordModeAndInversion) {
  23149. this._getNodeClientRect('.zp-scroll-view').then(function (sNode) {
  23150. if (sNode) {
  23151. _this13._scrollToY(sNode[0].height - nodeTop, offset, animate, true);
  23152. }
  23153. });
  23154. } else {
  23155. this._scrollToY(nodeTop, offset, animate, true);
  23156. }
  23157. },
  23158. // y轴滚动到指定位置
  23159. _scrollToY: function _scrollToY(y) {
  23160. var _this14 = this;
  23161. var offset = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
  23162. var animate = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
  23163. var addScrollTop = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : false;
  23164. this._updatePrivateScrollWithAnimation(animate);
  23165. _zPagingUtils.default.delay(function () {
  23166. if (_this14.usePageScroll) {
  23167. if (addScrollTop && _this14.pageScrollTop !== -1) {
  23168. y += _this14.pageScrollTop;
  23169. }
  23170. var scrollTop = y - offset;
  23171. uni.pageScrollTo({
  23172. scrollTop: scrollTop,
  23173. duration: animate ? 100 : 0
  23174. });
  23175. } else {
  23176. if (addScrollTop) {
  23177. y += _this14.oldScrollTop;
  23178. }
  23179. _this14.scrollTop = y - offset;
  23180. }
  23181. }, 10);
  23182. },
  23183. // x轴滚动到指定位置
  23184. _scrollToX: function _scrollToX(x) {
  23185. var _this15 = this;
  23186. var offset = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
  23187. var animate = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
  23188. this._updatePrivateScrollWithAnimation(animate);
  23189. _zPagingUtils.default.delay(function () {
  23190. if (!_this15.usePageScroll) {
  23191. _this15.scrollLeft = x - offset;
  23192. } else {
  23193. _zPagingUtils.default.consoleErr('使用页面滚动时不支持scrollToX');
  23194. }
  23195. }, 10);
  23196. },
  23197. // scroll-view滚动中
  23198. _scroll: function _scroll(e) {
  23199. var _this16 = this;
  23200. this.$emit('scroll', e);
  23201. var _e$detail = e.detail,
  23202. scrollTop = _e$detail.scrollTop,
  23203. scrollLeft = _e$detail.scrollLeft,
  23204. scrollHeight = _e$detail.scrollHeight;
  23205. if (this.watchScrollDirectionChange) {
  23206. // 计算scroll-view滚动方向,正常情况下上次滚动的oldScrollTop大于当前scrollTop即为向上滚动,反之为向下滚动
  23207. var direction = this.oldScrollTop > scrollTop ? 'top' : 'bottom';
  23208. // 此处为解决在iOS中,滚动到顶部因bounce的影响回弹导致滚动方向为bottom的问题:如果滚动到顶部了并且scrollTop小于顶部滚动区域,则强制设置direction为top
  23209. // 此外发现在h5中下拉刷新时direction有概率被判断为bottom(oldScrollTop > scrollTop),因为下拉刷新时会禁止scroll-view滚动,则以此为依据强制设置direction为top
  23210. if (scrollTop <= 0 || !this.scrollEnable) {
  23211. direction = 'top';
  23212. }
  23213. // 此处为解决在iOS中,滚动到底部因bounce的影响回弹导致滚动方向为top的问题:如果滚动到底部了并且scrollTop超过底部滚动区域,则强制设置direction为bottom
  23214. if (scrollTop > this.lastScrollHeight - this.scrollViewHeight - 1 && this.scrollEnable) {
  23215. direction = 'bottom';
  23216. }
  23217. // emit 列表滚动方向改变事件
  23218. if (direction !== this.lastScrollDirection) {
  23219. this.$emit('scrollDirectionChange', direction);
  23220. this.lastScrollDirection = direction;
  23221. }
  23222. // 当scrollHeight变化时,需要延迟100毫秒设置lastScrollHeight,如果直接根据scrollHeight的话,因为此时数据还未改变,会导致滚动方向从bottom变为top
  23223. if (this.lastScrollHeight !== scrollHeight && !this.setContentHeightPending) {
  23224. // 因此处会多次触发,因此加个标识确保在延时期间仅触发一次
  23225. this.setContentHeightPending = true;
  23226. _zPagingUtils.default.delay(function () {
  23227. _this16.lastScrollHeight = scrollHeight;
  23228. _this16.setContentHeightPending = false;
  23229. });
  23230. }
  23231. }
  23232. this.finalUseVirtualList && this._updateVirtualScroll(scrollTop, this.oldScrollTop - scrollTop);
  23233. this.oldScrollTop = scrollTop;
  23234. this.oldScrollLeft = scrollLeft;
  23235. // 在非ios平台滚动中,再次验证一下是否滚动到了底部。因为在一些安卓设备中,有概率滚动到底部不触发@scrolltolower事件,因此添加双重检测逻辑
  23236. // 排除快手的情况,因为在快手安卓中双重检测会导致滚动到底部事件多次触发
  23237. if (!this.isIos) {
  23238. // 滚动区域内容的总高度 - 当前滚动的scrollTop = 当前滚动区域的顶部与内容底部的距离
  23239. var scrollDiff = e.detail.scrollHeight - this.oldScrollTop;
  23240. this._checkScrolledToBottom(scrollDiff);
  23241. }
  23242. },
  23243. // emit scrolltolower/scrolltoupper事件
  23244. _emitScrollEvent: function _emitScrollEvent(type) {
  23245. var reversedType = type === 'scrolltolower' ? 'scrolltoupper' : 'scrolltolower';
  23246. var eventType = this.useChatRecordMode && !this.isChatRecordModeAndNotInversion ? reversedType : type;
  23247. this.$emit(eventType);
  23248. },
  23249. // 更新内置的scroll-view是否启用滚动动画
  23250. _updatePrivateScrollWithAnimation: function _updatePrivateScrollWithAnimation(animate) {
  23251. var _this17 = this;
  23252. this.privateScrollWithAnimation = animate ? 1 : 0;
  23253. _zPagingUtils.default.delay(function () {
  23254. return _this17.$nextTick(function () {
  23255. // 在滚动结束后将滚动动画状态设置回初始状态
  23256. _this17.privateScrollWithAnimation = -1;
  23257. });
  23258. }, 100, 'updateScrollWithAnimationDelay');
  23259. },
  23260. // 检测scrollView是否要铺满屏幕
  23261. _doCheckScrollViewShouldFullHeight: function _doCheckScrollViewShouldFullHeight(totalData) {
  23262. var _this18 = this;
  23263. if (this.autoFullHeight && this.usePageScroll && this.isTotalChangeFromAddData) {
  23264. this.$nextTick(function () {
  23265. _this18._checkScrollViewShouldFullHeight(function (scrollViewNode, pagingContainerNode) {
  23266. _this18._preCheckShowNoMoreInside(totalData, scrollViewNode, pagingContainerNode);
  23267. });
  23268. });
  23269. } else {
  23270. this._preCheckShowNoMoreInside(totalData);
  23271. }
  23272. },
  23273. // 检测z-paging是否要全屏覆盖(当使用页面滚动并且不满全屏时,默认z-paging需要铺满全屏,避免数据过少时内部的empty-view无法正确展示)
  23274. _checkScrollViewShouldFullHeight: function _checkScrollViewShouldFullHeight(callback) {
  23275. var _this19 = this;
  23276. return (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee2() {
  23277. var scrollViewNode, pagingContainerNode, scrollViewHeight, scrollViewTop;
  23278. return _regenerator.default.wrap(function _callee2$(_context2) {
  23279. while (1) {
  23280. switch (_context2.prev = _context2.next) {
  23281. case 0:
  23282. _context2.prev = 0;
  23283. _context2.next = 3;
  23284. return _this19._getNodeClientRect('.zp-scroll-view');
  23285. case 3:
  23286. scrollViewNode = _context2.sent;
  23287. _context2.next = 6;
  23288. return _this19._getNodeClientRect('.zp-paging-container-content');
  23289. case 6:
  23290. pagingContainerNode = _context2.sent;
  23291. if (!(!scrollViewNode || !pagingContainerNode)) {
  23292. _context2.next = 9;
  23293. break;
  23294. }
  23295. return _context2.abrupt("return");
  23296. case 9:
  23297. scrollViewHeight = pagingContainerNode[0].height;
  23298. scrollViewTop = scrollViewNode[0].top;
  23299. if (_this19.isAddedData && scrollViewHeight + scrollViewTop <= _this19.windowHeight) {
  23300. _this19._setAutoHeight(true, scrollViewNode);
  23301. callback(scrollViewNode, pagingContainerNode);
  23302. } else {
  23303. _this19._setAutoHeight(false);
  23304. callback(null, null);
  23305. }
  23306. _context2.next = 17;
  23307. break;
  23308. case 14:
  23309. _context2.prev = 14;
  23310. _context2.t0 = _context2["catch"](0);
  23311. callback(null, null);
  23312. case 17:
  23313. case "end":
  23314. return _context2.stop();
  23315. }
  23316. }
  23317. }, _callee2, null, [[0, 14]]);
  23318. }))();
  23319. },
  23320. // 更新缓存中z-paging整个内容容器高度
  23321. _updateCachedSuperContentHeight: function _updateCachedSuperContentHeight() {
  23322. var _this20 = this;
  23323. return (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee3() {
  23324. var superContentNode;
  23325. return _regenerator.default.wrap(function _callee3$(_context3) {
  23326. while (1) {
  23327. switch (_context3.prev = _context3.next) {
  23328. case 0:
  23329. _context3.next = 2;
  23330. return _this20._getNodeClientRect('.z-paging-content');
  23331. case 2:
  23332. superContentNode = _context3.sent;
  23333. if (superContentNode) {
  23334. _this20.superContentHeight = superContentNode[0].height;
  23335. }
  23336. case 4:
  23337. case "end":
  23338. return _context3.stop();
  23339. }
  23340. }
  23341. }, _callee3);
  23342. }))();
  23343. },
  23344. // scrollTop改变时触发
  23345. _scrollTopChange: function _scrollTopChange(newVal, isPageScrollTop) {
  23346. this.$emit('scrollTopChange', newVal);
  23347. this.$emit('update:scrollTop', newVal);
  23348. this._checkShouldShowBackToTop(newVal);
  23349. // 之前在安卓中scroll-view有概率滚动到顶部时scrollTop不为0导致下拉刷新判断异常,因此判断scrollTop在105之内都允许下拉刷新,但此方案会导致某些情况(例如滚动到距离顶部10px处)下拉抖动,因此改为通过获取zp-scroll-view的节点信息中的scrollTop进行验证的方案
  23350. // const scrollTop = this.isIos ? (newVal > 5 ? 6 : 0) : (newVal > 105 ? 106 : (newVal > 5 ? 6 : 0));
  23351. var scrollTop = newVal > 5 ? 6 : 0;
  23352. if (isPageScrollTop && this.wxsPageScrollTop !== scrollTop) {
  23353. this.wxsPageScrollTop = scrollTop;
  23354. } else if (!isPageScrollTop && this.wxsScrollTop !== scrollTop) {
  23355. this.wxsScrollTop = scrollTop;
  23356. if (scrollTop > 6) {
  23357. this.scrollEnable = true;
  23358. }
  23359. }
  23360. },
  23361. // 更新使用页面滚动时slot="top"或"bottom"插入view的高度
  23362. _updatePageScrollTopOrBottomHeight: function _updatePageScrollTopOrBottomHeight(type) {
  23363. var _this21 = this;
  23364. if (!this.usePageScroll) return;
  23365. this._doCheckScrollViewShouldFullHeight(this.realTotalData);
  23366. var node = ".zp-page-".concat(type);
  23367. var marginText = "margin".concat(type.slice(0, 1).toUpperCase() + type.slice(1));
  23368. // 是否设置底部安全区域间距,仅当开启底部安全区域并且slot=bottom不存在的时候才处理,如果slot=bottom存在则直接在bottom底部插入占位view
  23369. // 如果useSafeAreaPlaceholder为true,这里也不需要额外通过marginBottom设置底部安全区域了
  23370. var safeAreaInsetBottomAdd = this.safeAreaInsetBottom && !this.zSlots.bottom && !this.useSafeAreaPlaceholder;
  23371. this.$nextTick(function () {
  23372. var delayTime = 0;
  23373. _zPagingUtils.default.delay(function () {
  23374. _this21._getNodeClientRect(node).then(function (res) {
  23375. if (res) {
  23376. var pageScrollNodeHeight = res[0].height;
  23377. if (type === 'bottom') {
  23378. if (safeAreaInsetBottomAdd) {
  23379. pageScrollNodeHeight += _this21.safeAreaBottom;
  23380. }
  23381. } else {
  23382. _this21.cacheTopHeight = pageScrollNodeHeight;
  23383. }
  23384. _this21.$set(_this21.scrollViewStyle, marginText, "".concat(pageScrollNodeHeight, "px"));
  23385. } else if (safeAreaInsetBottomAdd) {
  23386. _this21.$set(_this21.scrollViewStyle, marginText, "".concat(_this21.safeAreaBottom, "px"));
  23387. }
  23388. });
  23389. }, delayTime);
  23390. });
  23391. }
  23392. }
  23393. };
  23394. exports.default = _default;
  23395. /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./node_modules/@dcloudio/uni-mp-toutiao/dist/index.js */ 1)["default"]))
  23396. /***/ }),
  23397. /* 270 */
  23398. /*!*********************************************************************************************************!*\
  23399. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/z-paging/components/z-paging/js/modules/back-to-top.js ***!
  23400. \*********************************************************************************************************/
  23401. /*! no static exports found */
  23402. /***/ (function(module, exports, __webpack_require__) {
  23403. "use strict";
  23404. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  23405. Object.defineProperty(exports, "__esModule", {
  23406. value: true
  23407. });
  23408. exports.default = void 0;
  23409. var _zPagingUtils = _interopRequireDefault(__webpack_require__(/*! .././z-paging-utils */ 252));
  23410. // [z-paging]点击返回顶部view模块
  23411. var _default = {
  23412. props: {
  23413. // 自动显示点击返回顶部按钮,默认为否
  23414. autoShowBackToTop: {
  23415. type: Boolean,
  23416. default: _zPagingUtils.default.gc('autoShowBackToTop', false)
  23417. },
  23418. // 点击返回顶部按钮显示/隐藏的阈值(滚动距离),单位为px,默认为400rpx
  23419. backToTopThreshold: {
  23420. type: [Number, String],
  23421. default: _zPagingUtils.default.gc('backToTopThreshold', '400rpx')
  23422. },
  23423. // 点击返回顶部按钮的自定义图片地址,默认使用z-paging内置的图片
  23424. backToTopImg: {
  23425. type: String,
  23426. default: _zPagingUtils.default.gc('backToTopImg', '')
  23427. },
  23428. // 点击返回顶部按钮返回到顶部时是否展示过渡动画,默认为是
  23429. backToTopWithAnimate: {
  23430. type: Boolean,
  23431. default: _zPagingUtils.default.gc('backToTopWithAnimate', true)
  23432. },
  23433. // 点击返回顶部按钮与底部的距离,注意添加单位px或rpx,默认为160rpx
  23434. backToTopBottom: {
  23435. type: [Number, String],
  23436. default: _zPagingUtils.default.gc('backToTopBottom', '160rpx')
  23437. },
  23438. // 点击返回顶部按钮的自定义样式
  23439. backToTopStyle: {
  23440. type: Object,
  23441. default: _zPagingUtils.default.gc('backToTopStyle', {})
  23442. },
  23443. // iOS点击顶部状态栏、安卓双击标题栏时,滚动条返回顶部,只支持竖向,默认为是
  23444. enableBackToTop: {
  23445. type: Boolean,
  23446. default: _zPagingUtils.default.gc('enableBackToTop', true)
  23447. }
  23448. },
  23449. data: function data() {
  23450. return {
  23451. // 点击返回顶部的class
  23452. backToTopClass: 'zp-back-to-top zp-back-to-top-hide',
  23453. // 上次点击返回顶部的时间
  23454. lastBackToTopShowTime: 0,
  23455. // 点击返回顶部显示的class是否在展示中,使得按钮展示/隐藏过度效果更自然
  23456. showBackToTopClass: false
  23457. };
  23458. },
  23459. computed: {
  23460. backToTopThresholdUnitConverted: function backToTopThresholdUnitConverted() {
  23461. return _zPagingUtils.default.addUnit(this.backToTopThreshold, this.unit);
  23462. },
  23463. backToTopBottomUnitConverted: function backToTopBottomUnitConverted() {
  23464. return _zPagingUtils.default.addUnit(this.backToTopBottom, this.unit);
  23465. },
  23466. finalEnableBackToTop: function finalEnableBackToTop() {
  23467. return this.usePageScroll ? false : this.enableBackToTop;
  23468. },
  23469. finalBackToTopThreshold: function finalBackToTopThreshold() {
  23470. return _zPagingUtils.default.convertToPx(this.backToTopThresholdUnitConverted);
  23471. },
  23472. finalBackToTopStyle: function finalBackToTopStyle() {
  23473. var backToTopStyle = this.backToTopStyle;
  23474. if (!backToTopStyle.bottom) {
  23475. backToTopStyle.bottom = this.windowBottom + _zPagingUtils.default.convertToPx(this.backToTopBottomUnitConverted) + 'px';
  23476. }
  23477. if (!backToTopStyle.position) {
  23478. backToTopStyle.position = this.usePageScroll ? 'fixed' : 'absolute';
  23479. }
  23480. return backToTopStyle;
  23481. },
  23482. finalBackToTopClass: function finalBackToTopClass() {
  23483. return "".concat(this.backToTopClass, " zp-back-to-top-").concat(this.unit);
  23484. }
  23485. },
  23486. methods: {
  23487. // 点击了返回顶部
  23488. _backToTopClick: function _backToTopClick() {
  23489. var _this = this;
  23490. var callbacked = false;
  23491. this.$emit('backToTopClick', function (toTop) {
  23492. (toTop === undefined || toTop === true) && _this._handleToTop();
  23493. callbacked = true;
  23494. });
  23495. // 如果用户没有禁止默认的返回顶部事件,则触发滚动到顶部
  23496. this.$nextTick(function () {
  23497. !callbacked && _this._handleToTop();
  23498. });
  23499. },
  23500. // 处理滚动到顶部(聊天记录模式中为滚动到底部)
  23501. _handleToTop: function _handleToTop() {
  23502. !this.backToTopWithAnimate && this._checkShouldShowBackToTop(0);
  23503. !this.useChatRecordMode ? this.scrollToTop(this.backToTopWithAnimate) : this.scrollToBottom(this.backToTopWithAnimate);
  23504. },
  23505. // 判断是否要显示返回顶部按钮
  23506. _checkShouldShowBackToTop: function _checkShouldShowBackToTop(scrollTop) {
  23507. var _this2 = this;
  23508. if (!this.autoShowBackToTop) {
  23509. this.showBackToTopClass = false;
  23510. return;
  23511. }
  23512. if (scrollTop > this.finalBackToTopThreshold) {
  23513. if (!this.showBackToTopClass) {
  23514. // 记录当前点击返回顶部按钮显示的class生效了
  23515. this.showBackToTopClass = true;
  23516. this.lastBackToTopShowTime = new Date().getTime();
  23517. // 当滚动到需要展示返回顶部的阈值内,则延迟300毫秒展示返回到顶部按钮
  23518. _zPagingUtils.default.delay(function () {
  23519. _this2.backToTopClass = 'zp-back-to-top zp-back-to-top-show';
  23520. }, 300);
  23521. }
  23522. } else {
  23523. // 如果当前点击返回顶部按钮显示的class是生效状态并且滚动小于触发阈值,则隐藏返回顶部按钮
  23524. if (this.showBackToTopClass) {
  23525. this.backToTopClass = 'zp-back-to-top zp-back-to-top-hide';
  23526. _zPagingUtils.default.delay(function () {
  23527. _this2.showBackToTopClass = false;
  23528. }, new Date().getTime() - this.lastBackToTopShowTime < 500 ? 0 : 300);
  23529. }
  23530. }
  23531. }
  23532. }
  23533. };
  23534. exports.default = _default;
  23535. /***/ }),
  23536. /* 271 */
  23537. /*!**********************************************************************************************************!*\
  23538. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/z-paging/components/z-paging/js/modules/virtual-list.js ***!
  23539. \**********************************************************************************************************/
  23540. /*! no static exports found */
  23541. /***/ (function(module, exports, __webpack_require__) {
  23542. "use strict";
  23543. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  23544. Object.defineProperty(exports, "__esModule", {
  23545. value: true
  23546. });
  23547. exports.default = void 0;
  23548. var _regenerator = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/regenerator */ 54));
  23549. var _asyncToGenerator2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/asyncToGenerator */ 56));
  23550. var _zPagingUtils = _interopRequireDefault(__webpack_require__(/*! .././z-paging-utils */ 252));
  23551. var _zPagingConstant = _interopRequireDefault(__webpack_require__(/*! .././z-paging-constant */ 251));
  23552. var _zPagingEnum = _interopRequireDefault(__webpack_require__(/*! .././z-paging-enum */ 256));
  23553. // [z-paging]虚拟列表模块
  23554. var _default = {
  23555. props: {
  23556. // 是否使用虚拟列表,默认为否
  23557. useVirtualList: {
  23558. type: Boolean,
  23559. default: _zPagingUtils.default.gc('useVirtualList', false)
  23560. },
  23561. // 在使用虚拟列表时,是否使用兼容模式,默认为否
  23562. useCompatibilityMode: {
  23563. type: Boolean,
  23564. default: _zPagingUtils.default.gc('useCompatibilityMode', false)
  23565. },
  23566. // 使用兼容模式时传递的附加数据
  23567. extraData: {
  23568. type: Object,
  23569. default: _zPagingUtils.default.gc('extraData', {})
  23570. },
  23571. // 是否在z-paging内部循环渲染列表(内置列表),默认为否。若use-virtual-list为true,则此项恒为true
  23572. useInnerList: {
  23573. type: Boolean,
  23574. default: _zPagingUtils.default.gc('useInnerList', false)
  23575. },
  23576. // 强制关闭inner-list,默认为false,如果为true将强制关闭innerList,适用于开启了虚拟列表后需要强制关闭inner-list的情况
  23577. forceCloseInnerList: {
  23578. type: Boolean,
  23579. default: _zPagingUtils.default.gc('forceCloseInnerList', false)
  23580. },
  23581. // 内置列表cell的key名称,仅nvue有效,在nvue中开启use-inner-list时必须填此项
  23582. cellKeyName: {
  23583. type: String,
  23584. default: _zPagingUtils.default.gc('cellKeyName', '')
  23585. },
  23586. // innerList样式
  23587. innerListStyle: {
  23588. type: Object,
  23589. default: _zPagingUtils.default.gc('innerListStyle', {})
  23590. },
  23591. // innerCell样式
  23592. innerCellStyle: {
  23593. type: Object,
  23594. default: _zPagingUtils.default.gc('innerCellStyle', {})
  23595. },
  23596. // 预加载的列表可视范围(列表高度)页数,默认为12,即预加载当前页及上下各12页的cell。此数值越大,则虚拟列表中加载的dom越多,内存消耗越大(会维持在一个稳定值),但增加预加载页面数量可缓解快速滚动短暂白屏问题
  23597. preloadPage: {
  23598. type: [Number, String],
  23599. default: _zPagingUtils.default.gc('preloadPage', 12),
  23600. validator: function validator(value) {
  23601. if (value <= 0) _zPagingUtils.default.consoleErr('preload-page必须大于0!');
  23602. return value > 0;
  23603. }
  23604. },
  23605. // 虚拟列表cell高度模式,默认为fixed,也就是每个cell高度完全相同,将以第一个cell高度为准进行计算。可选值【dynamic】,即代表高度是动态非固定的,【dynamic】性能低于【fixed】。
  23606. cellHeightMode: {
  23607. type: String,
  23608. default: _zPagingUtils.default.gc('cellHeightMode', _zPagingEnum.default.CellHeightMode.Fixed)
  23609. },
  23610. // 固定的cell高度,cellHeightMode=fixed才有效,若设置了值,则不计算第一个cell高度而使用设置的cell高度
  23611. fixedCellHeight: {
  23612. type: [Number, String],
  23613. default: _zPagingUtils.default.gc('fixedCellHeight', 0)
  23614. },
  23615. // 虚拟列表列数,默认为1。常用于每行有多列的情况,例如每行有2列数据,需要将此值设置为2
  23616. virtualListCol: {
  23617. type: [Number, String],
  23618. default: _zPagingUtils.default.gc('virtualListCol', 1)
  23619. },
  23620. // 虚拟列表scroll取样帧率,默认为80,过低容易出现白屏问题,过高容易出现卡顿问题
  23621. virtualScrollFps: {
  23622. type: [Number, String],
  23623. default: _zPagingUtils.default.gc('virtualScrollFps', 80)
  23624. },
  23625. // 虚拟列表cell id的前缀,适用于一个页面有多个虚拟列表的情况,用以区分不同虚拟列表cell的id,注意:请勿传数字或以数字开头的字符串。如设置为list1,则cell的id应为:list1-zp-id-${item.zp_index}
  23626. virtualCellIdPrefix: {
  23627. type: String,
  23628. default: _zPagingUtils.default.gc('virtualCellIdPrefix', '')
  23629. },
  23630. // 虚拟列表是否使用swiper-item或其他父组件包裹,默认为否,此属性为了解决vue3+(微信小程序或QQ小程序)中,使用非内置列表写法时,若z-paging在swiper-item内存在无法获取slot插入的cell高度进而导致虚拟列表失败的问题
  23631. // 仅vue3+(微信小程序或QQ小程序)+非内置列表写法虚拟列表有效,其他情况此属性设置任何值都无效,所以如果您在swiper-item内使用z-paging的非内置虚拟列表写法,将此属性设置为true即可
  23632. virtualInSwiperSlot: {
  23633. type: Boolean,
  23634. default: false
  23635. }
  23636. },
  23637. data: function data() {
  23638. return {
  23639. virtualListKey: _zPagingUtils.default.getInstanceId(),
  23640. virtualCellHeight: 0,
  23641. virtualScrollTimeStamp: 0,
  23642. virtualList: [],
  23643. virtualPlaceholderTopHeight: 0,
  23644. virtualPlaceholderBottomHeight: 0,
  23645. virtualTopRangeIndex: 0,
  23646. virtualBottomRangeIndex: 0,
  23647. lastVirtualTopRangeIndex: 0,
  23648. lastVirtualBottomRangeIndex: 0,
  23649. virtualItemInsertedCount: 0,
  23650. virtualHeightCacheList: [],
  23651. getCellHeightRetryCount: {
  23652. fixed: 0,
  23653. dynamic: 0
  23654. },
  23655. updateVirtualListFromDataChange: false
  23656. };
  23657. },
  23658. watch: {
  23659. // 监听总数据的改变,刷新虚拟列表布局
  23660. realTotalData: function realTotalData() {
  23661. this.updateVirtualListRender();
  23662. },
  23663. // 监听虚拟列表渲染数组的改变并emit
  23664. virtualList: function virtualList(newVal) {
  23665. this.$emit('update:virtualList', newVal);
  23666. this.$emit('virtualListChange', newVal);
  23667. },
  23668. // 监听虚拟列表顶部占位高度改变并emit
  23669. virtualPlaceholderTopHeight: function virtualPlaceholderTopHeight(newVal) {
  23670. this.$emit('virtualTopHeightChange', newVal);
  23671. }
  23672. },
  23673. computed: {
  23674. virtualCellIndexKey: function virtualCellIndexKey() {
  23675. return _zPagingConstant.default.listCellIndexKey;
  23676. },
  23677. finalUseVirtualList: function finalUseVirtualList() {
  23678. if (this.useVirtualList && this.usePageScroll) {
  23679. _zPagingUtils.default.consoleErr('使用页面滚动时,开启虚拟列表无效!');
  23680. }
  23681. return this.useVirtualList && !this.usePageScroll;
  23682. },
  23683. finalUseInnerList: function finalUseInnerList() {
  23684. return this.useInnerList || this.finalUseVirtualList && !this.forceCloseInnerList;
  23685. },
  23686. finalCellKeyName: function finalCellKeyName() {
  23687. return this.cellKeyName;
  23688. },
  23689. finalVirtualPageHeight: function finalVirtualPageHeight() {
  23690. return this.scrollViewHeight > 0 ? this.scrollViewHeight : this.windowHeight;
  23691. },
  23692. finalFixedCellHeight: function finalFixedCellHeight() {
  23693. return _zPagingUtils.default.convertToPx(this.fixedCellHeight);
  23694. },
  23695. fianlVirtualCellIdPrefix: function fianlVirtualCellIdPrefix() {
  23696. var prefix = this.virtualCellIdPrefix ? this.virtualCellIdPrefix + '-' : '';
  23697. return prefix + 'zp-id';
  23698. },
  23699. finalPlaceholderTopHeightStyle: function finalPlaceholderTopHeightStyle() {
  23700. return {
  23701. transform: this.virtualPlaceholderTopHeight > 0 ? "translateY(".concat(this.virtualPlaceholderTopHeight, "px)") : 'none'
  23702. };
  23703. return {};
  23704. },
  23705. virtualRangePageHeight: function virtualRangePageHeight() {
  23706. return this.finalVirtualPageHeight * this.preloadPage;
  23707. },
  23708. virtualScrollDisTimeStamp: function virtualScrollDisTimeStamp() {
  23709. return 1000 / this.virtualScrollFps;
  23710. }
  23711. },
  23712. methods: {
  23713. // 在使用动态高度虚拟列表时,若在列表数组中需要插入某个item,需要调用此方法;item:需要插入的item,index:插入的cell位置,若index为2,则插入的item在原list的index=1之后,index从0开始
  23714. doInsertVirtualListItem: function doInsertVirtualListItem(item, index) {
  23715. var _this = this;
  23716. if (this.cellHeightMode !== _zPagingEnum.default.CellHeightMode.Dynamic) return;
  23717. this.realTotalData.splice(index, 0, item);
  23718. this.virtualItemInsertedCount++;
  23719. if (!item || Object.prototype.toString.call(item) !== '[object Object]') {
  23720. item = {
  23721. item: item
  23722. };
  23723. }
  23724. var cellIndexKey = this.virtualCellIndexKey;
  23725. item[cellIndexKey] = "custom-".concat(this.virtualItemInsertedCount);
  23726. item[_zPagingConstant.default.listCellIndexUniqueKey] = "".concat(this.virtualListKey, "-").concat(item[cellIndexKey]);
  23727. this.$nextTick( /*#__PURE__*/(0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee() {
  23728. var retryCount, cellNode, currentHeight, lastHeightCache, lastTotalHeight, i, thisNode;
  23729. return _regenerator.default.wrap(function _callee$(_context) {
  23730. while (1) {
  23731. switch (_context.prev = _context.next) {
  23732. case 0:
  23733. retryCount = 0;
  23734. case 1:
  23735. if (!(retryCount <= 10)) {
  23736. _context.next = 19;
  23737. break;
  23738. }
  23739. _context.next = 4;
  23740. return _zPagingUtils.default.wait(_zPagingConstant.default.delayTime);
  23741. case 4:
  23742. _context.next = 6;
  23743. return _this._getVirtualCellNodeByIndex(item[cellIndexKey]);
  23744. case 6:
  23745. cellNode = _context.sent;
  23746. if (cellNode) {
  23747. _context.next = 10;
  23748. break;
  23749. }
  23750. retryCount++;
  23751. return _context.abrupt("continue", 1);
  23752. case 10:
  23753. currentHeight = cellNode ? cellNode[0].height : 0;
  23754. lastHeightCache = _this.virtualHeightCacheList[index - 1];
  23755. lastTotalHeight = lastHeightCache ? lastHeightCache.totalHeight : 0; // 在缓存的cell高度数组中,插入此cell高度信息
  23756. _this.virtualHeightCacheList.splice(index, 0, {
  23757. height: currentHeight,
  23758. lastTotalHeight: lastTotalHeight,
  23759. totalHeight: lastTotalHeight + currentHeight
  23760. });
  23761. // 从当前index起后续的cell缓存高度的lastTotalHeight和totalHeight需要加上当前cell的高度
  23762. for (i = index + 1; i < _this.virtualHeightCacheList.length; i++) {
  23763. thisNode = _this.virtualHeightCacheList[i];
  23764. thisNode.lastTotalHeight += currentHeight;
  23765. thisNode.totalHeight += currentHeight;
  23766. }
  23767. _this._updateVirtualScroll(_this.oldScrollTop);
  23768. return _context.abrupt("break", 19);
  23769. case 19:
  23770. case "end":
  23771. return _context.stop();
  23772. }
  23773. }
  23774. }, _callee);
  23775. })));
  23776. },
  23777. // 在使用动态高度虚拟列表时,手动更新指定cell的缓存高度(当cell高度在初始化之后再次改变后调用);index:需要更新的cell在列表中的位置,从0开始
  23778. didUpdateVirtualListCell: function didUpdateVirtualListCell(index) {
  23779. var _this2 = this;
  23780. if (this.cellHeightMode !== _zPagingEnum.default.CellHeightMode.Dynamic) return;
  23781. var currentNode = this.virtualHeightCacheList[index];
  23782. this.$nextTick(function () {
  23783. _this2._getVirtualCellNodeByIndex(index).then(function (cellNode) {
  23784. // 更新当前cell的高度
  23785. var cellNodeHeight = cellNode ? cellNode[0].height : 0;
  23786. var heightDis = cellNodeHeight - currentNode.height;
  23787. currentNode.height = cellNodeHeight;
  23788. currentNode.totalHeight = currentNode.lastTotalHeight + cellNodeHeight;
  23789. // 从当前index起后续的cell缓存高度的lastTotalHeight和totalHeight需要加上当前cell变化的高度
  23790. for (var i = index + 1; i < _this2.virtualHeightCacheList.length; i++) {
  23791. var thisNode = _this2.virtualHeightCacheList[i];
  23792. thisNode.totalHeight += heightDis;
  23793. thisNode.lastTotalHeight += heightDis;
  23794. }
  23795. });
  23796. });
  23797. },
  23798. // 在使用动态高度虚拟列表时,若删除了列表数组中的某个item,需要调用此方法以更新高度缓存数组;index:删除的cell在列表中的位置,从0开始
  23799. didDeleteVirtualListCell: function didDeleteVirtualListCell(index) {
  23800. if (this.cellHeightMode !== _zPagingEnum.default.CellHeightMode.Dynamic) return;
  23801. var currentNode = this.virtualHeightCacheList[index];
  23802. // 从当前index起后续的cell缓存高度的lastTotalHeight和totalHeight需要减去当前cell的高度
  23803. for (var i = index + 1; i < this.virtualHeightCacheList.length; i++) {
  23804. var thisNode = this.virtualHeightCacheList[i];
  23805. thisNode.totalHeight -= currentNode.height;
  23806. thisNode.lastTotalHeight -= currentNode.height;
  23807. }
  23808. // 将当前cell的高度信息从高度缓存数组中删除
  23809. this.virtualHeightCacheList.splice(index, 1);
  23810. },
  23811. // 手动触发虚拟列表渲染更新,可用于解决例如修改了虚拟列表数组中元素,但展示未更新的情况
  23812. updateVirtualListRender: function updateVirtualListRender() {
  23813. var _this3 = this;
  23814. if (this.finalUseVirtualList) {
  23815. this.updateVirtualListFromDataChange = true;
  23816. this.$nextTick(function () {
  23817. _this3.getCellHeightRetryCount.fixed = 0;
  23818. if (_this3.realTotalData.length) {
  23819. _this3.cellHeightMode === _zPagingEnum.default.CellHeightMode.Fixed && _this3.isFirstPage && _this3._updateFixedCellHeight();
  23820. } else {
  23821. _this3._resetDynamicListState(!_this3.isUserPullDown);
  23822. }
  23823. _this3._updateVirtualScroll(_this3.oldScrollTop);
  23824. });
  23825. }
  23826. },
  23827. // cellHeightMode为fixed时获取第一个cell高度
  23828. _updateFixedCellHeight: function _updateFixedCellHeight() {
  23829. var _this4 = this;
  23830. if (!this.finalFixedCellHeight) {
  23831. this.$nextTick(function () {
  23832. _zPagingUtils.default.delay(function () {
  23833. _this4._getVirtualCellNodeByIndex(0).then(function (cellNode) {
  23834. if (!cellNode) {
  23835. if (_this4.getCellHeightRetryCount.fixed > 10) return;
  23836. _this4.getCellHeightRetryCount.fixed++;
  23837. // 如果获取第一个cell的节点信息失败,则重试(不超过10次)
  23838. _this4._updateFixedCellHeight();
  23839. } else {
  23840. _this4.virtualCellHeight = cellNode[0].height;
  23841. _this4._updateVirtualScroll(_this4.oldScrollTop);
  23842. }
  23843. });
  23844. }, _zPagingConstant.default.delayTime, 'updateFixedCellHeightDelay');
  23845. });
  23846. } else {
  23847. this.virtualCellHeight = this.finalFixedCellHeight;
  23848. }
  23849. },
  23850. // cellHeightMode为dynamic时获取每个cell高度
  23851. _updateDynamicCellHeight: function _updateDynamicCellHeight(list) {
  23852. var _this5 = this;
  23853. var dataFrom = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'bottom';
  23854. var dataFromTop = dataFrom === 'top';
  23855. var heightCacheList = this.virtualHeightCacheList;
  23856. var currentCacheList = dataFromTop ? [] : heightCacheList;
  23857. var listTotalHeight = 0;
  23858. this.$nextTick(function () {
  23859. _zPagingUtils.default.delay( /*#__PURE__*/(0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee2() {
  23860. var i, cellNode, currentHeight, lastHeightCache, lastTotalHeight, _i, heightCacheItem;
  23861. return _regenerator.default.wrap(function _callee2$(_context2) {
  23862. while (1) {
  23863. switch (_context2.prev = _context2.next) {
  23864. case 0:
  23865. i = 0;
  23866. case 1:
  23867. if (!(i < list.length)) {
  23868. _context2.next = 16;
  23869. break;
  23870. }
  23871. _context2.next = 4;
  23872. return _this5._getVirtualCellNodeByIndex(list[i][_this5.virtualCellIndexKey]);
  23873. case 4:
  23874. cellNode = _context2.sent;
  23875. currentHeight = cellNode ? cellNode[0].height : 0;
  23876. if (cellNode) {
  23877. _context2.next = 9;
  23878. break;
  23879. }
  23880. if (_this5.getCellHeightRetryCount.dynamic <= 10) {
  23881. heightCacheList.splice(heightCacheList.length - i, i);
  23882. _this5.getCellHeightRetryCount.dynamic++;
  23883. // 如果获取当前cell的节点信息失败,则重试(不超过10次)
  23884. _this5._updateDynamicCellHeight(list, dataFrom);
  23885. }
  23886. return _context2.abrupt("return");
  23887. case 9:
  23888. lastHeightCache = currentCacheList.length ? currentCacheList.slice(-1)[0] : null;
  23889. lastTotalHeight = lastHeightCache ? lastHeightCache.totalHeight : 0; // 缓存当前cell的高度信息:height-当前cell高度;lastTotalHeight-前面所有cell的高度总和;totalHeight-包含当前cell的所有高度总和
  23890. currentCacheList.push({
  23891. height: currentHeight,
  23892. lastTotalHeight: lastTotalHeight,
  23893. totalHeight: lastTotalHeight + currentHeight
  23894. });
  23895. if (dataFromTop) {
  23896. listTotalHeight += currentHeight;
  23897. }
  23898. case 13:
  23899. i++;
  23900. _context2.next = 1;
  23901. break;
  23902. case 16:
  23903. // 如果数据是从顶部拼接的
  23904. if (dataFromTop && list.length) {
  23905. for (_i = 0; _i < heightCacheList.length; _i++) {
  23906. // 更新之前所有项的缓存高度,需要加上此次插入的所有cell高度之和(因为是从顶部插入的cell)
  23907. heightCacheItem = heightCacheList[_i];
  23908. heightCacheItem.lastTotalHeight += listTotalHeight;
  23909. heightCacheItem.totalHeight += listTotalHeight;
  23910. }
  23911. _this5.virtualHeightCacheList = currentCacheList.concat(heightCacheList);
  23912. }
  23913. _this5._updateVirtualScroll(_this5.oldScrollTop);
  23914. case 18:
  23915. case "end":
  23916. return _context2.stop();
  23917. }
  23918. }
  23919. }, _callee2);
  23920. })), _zPagingConstant.default.delayTime, 'updateDynamicCellHeightDelay');
  23921. });
  23922. },
  23923. // 设置cellItem的index
  23924. _setCellIndex: function _setCellIndex(list) {
  23925. var dataFrom = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'bottom';
  23926. var currentItemIndex = 0;
  23927. var cellIndexKey = this.virtualCellIndexKey;
  23928. dataFrom === 'bottom' && [_zPagingEnum.default.QueryFrom.Refresh, _zPagingEnum.default.QueryFrom.Reload].indexOf(this.queryFrom) >= 0 && this._resetDynamicListState();
  23929. if (this.totalData.length && this.queryFrom !== _zPagingEnum.default.QueryFrom.Refresh) {
  23930. if (dataFrom === 'bottom') {
  23931. currentItemIndex = this.realTotalData.length;
  23932. var lastItem = this.realTotalData.length ? this.realTotalData.slice(-1)[0] : null;
  23933. if (lastItem && lastItem[cellIndexKey] !== undefined) {
  23934. currentItemIndex = lastItem[cellIndexKey] + 1;
  23935. }
  23936. } else if (dataFrom === 'top') {
  23937. var firstItem = this.realTotalData.length ? this.realTotalData[0] : null;
  23938. if (firstItem && firstItem[cellIndexKey] !== undefined) {
  23939. currentItemIndex = firstItem[cellIndexKey] - list.length;
  23940. }
  23941. }
  23942. } else {
  23943. this._resetDynamicListState();
  23944. }
  23945. for (var i = 0; i < list.length; i++) {
  23946. var item = list[i];
  23947. if (!item || Object.prototype.toString.call(item) !== '[object Object]') {
  23948. item = {
  23949. item: item
  23950. };
  23951. }
  23952. if (item[_zPagingConstant.default.listCellIndexUniqueKey]) {
  23953. item = _zPagingUtils.default.deepCopy(item);
  23954. }
  23955. item[cellIndexKey] = currentItemIndex + i;
  23956. item[_zPagingConstant.default.listCellIndexUniqueKey] = "".concat(this.virtualListKey, "-").concat(item[cellIndexKey]);
  23957. list[i] = item;
  23958. }
  23959. this.getCellHeightRetryCount.dynamic = 0;
  23960. this.cellHeightMode === _zPagingEnum.default.CellHeightMode.Dynamic && this._updateDynamicCellHeight(list, dataFrom);
  23961. },
  23962. // 更新scroll滚动(虚拟列表滚动时触发)
  23963. _updateVirtualScroll: function _updateVirtualScroll(scrollTop) {
  23964. var scrollDiff = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
  23965. var currentTimeStamp = _zPagingUtils.default.getTime();
  23966. scrollTop === 0 && this._resetTopRange();
  23967. if (scrollTop !== 0 && this.virtualScrollTimeStamp && currentTimeStamp - this.virtualScrollTimeStamp <= this.virtualScrollDisTimeStamp) {
  23968. return;
  23969. }
  23970. this.virtualScrollTimeStamp = currentTimeStamp;
  23971. var scrollIndex = 0;
  23972. var cellHeightMode = this.cellHeightMode;
  23973. if (cellHeightMode === _zPagingEnum.default.CellHeightMode.Fixed) {
  23974. // 如果是固定高度的虚拟列表
  23975. // 计算当前滚动到的cell的index = scrollTop / 虚拟列表cell的固定高度
  23976. scrollIndex = parseInt(scrollTop / this.virtualCellHeight) || 0;
  23977. // 更新顶部和底部占位view的高度(为兼容考虑,顶部采用transformY的方式占位)
  23978. this._updateFixedTopRangeIndex(scrollIndex);
  23979. this._updateFixedBottomRangeIndex(scrollIndex);
  23980. } else if (cellHeightMode === _zPagingEnum.default.CellHeightMode.Dynamic) {
  23981. // 如果是不固定高度的虚拟列表
  23982. // 当前滚动的方向
  23983. var scrollDirection = scrollDiff > 0 ? 'top' : 'bottom';
  23984. // 视图区域的高度
  23985. var rangePageHeight = this.virtualRangePageHeight;
  23986. // 顶部视图区域外的高度(顶部不需要渲染而是需要占位部分的高度)
  23987. var topRangePageOffset = scrollTop - rangePageHeight;
  23988. // 底部视图区域外的高度(底部不需要渲染而是需要占位部分的高度)
  23989. var bottomRangePageOffset = scrollTop + this.finalVirtualPageHeight + rangePageHeight;
  23990. var virtualBottomRangeIndex = 0;
  23991. var virtualPlaceholderBottomHeight = 0;
  23992. var reachedLimitBottom = false;
  23993. var heightCacheList = this.virtualHeightCacheList;
  23994. var lastHeightCache = !!heightCacheList ? heightCacheList.slice(-1)[0] : null;
  23995. var startTopRangeIndex = this.virtualTopRangeIndex;
  23996. // 如果是向底部滚动(顶部占位的高度不断增大,顶部的实际渲染cell数量不断减少)
  23997. if (scrollDirection === 'bottom') {
  23998. // 从顶部视图边缘的cell的位置开始向后查找
  23999. for (var i = startTopRangeIndex; i < heightCacheList.length; i++) {
  24000. var heightCacheItem = heightCacheList[i];
  24001. // 如果查找到某个cell对应的totalHeight大于顶部视图区域外的高度,则此cell为顶部视图边缘的cell
  24002. if (heightCacheItem && heightCacheItem.totalHeight > topRangePageOffset) {
  24003. // 记录顶部视图边缘cell的index并更新顶部占位区域的高度并停止继续查找
  24004. this.virtualTopRangeIndex = i;
  24005. this.virtualPlaceholderTopHeight = heightCacheItem.lastTotalHeight;
  24006. break;
  24007. }
  24008. }
  24009. } else {
  24010. // 如果是向顶部滚动(顶部占位的高度不断减少,顶部的实际渲染cell数量不断增加)
  24011. var topRangeMatched = false;
  24012. // 从顶部视图边缘的cell的位置开始向前查找
  24013. for (var _i2 = startTopRangeIndex; _i2 >= 0; _i2--) {
  24014. var _heightCacheItem = heightCacheList[_i2];
  24015. // 如果查找到某个cell对应的totalHeight小于顶部视图区域外的高度,则此cell为顶部视图边缘的cell
  24016. if (_heightCacheItem && _heightCacheItem.totalHeight < topRangePageOffset) {
  24017. // 记录顶部视图边缘cell的index并更新顶部占位区域的高度并停止继续查找
  24018. this.virtualTopRangeIndex = _i2;
  24019. this.virtualPlaceholderTopHeight = _heightCacheItem.lastTotalHeight;
  24020. topRangeMatched = true;
  24021. break;
  24022. }
  24023. }
  24024. // 如果查找不到,则认为顶部占位高度为0了,顶部cell不需要继续复用,重置topRangeIndex和placeholderTopHeight
  24025. !topRangeMatched && this._resetTopRange();
  24026. }
  24027. // 从顶部视图边缘的cell的位置开始向后查找
  24028. for (var _i3 = this.virtualTopRangeIndex; _i3 < heightCacheList.length; _i3++) {
  24029. var _heightCacheItem2 = heightCacheList[_i3];
  24030. // 如果查找到某个cell对应的totalHeight大于底部视图区域外的高度,则此cell为底部视图边缘的cell
  24031. if (_heightCacheItem2 && _heightCacheItem2.totalHeight > bottomRangePageOffset) {
  24032. // 记录底部视图边缘cell的index并更新底部占位区域的高度并停止继续查找
  24033. virtualBottomRangeIndex = _i3;
  24034. virtualPlaceholderBottomHeight = lastHeightCache.totalHeight - _heightCacheItem2.totalHeight;
  24035. reachedLimitBottom = true;
  24036. break;
  24037. }
  24038. }
  24039. if (!reachedLimitBottom || this.virtualBottomRangeIndex === 0) {
  24040. this.virtualBottomRangeIndex = this.realTotalData.length ? this.realTotalData.length - 1 : this.pageSize;
  24041. this.virtualPlaceholderBottomHeight = 0;
  24042. } else {
  24043. this.virtualBottomRangeIndex = virtualBottomRangeIndex;
  24044. this.virtualPlaceholderBottomHeight = virtualPlaceholderBottomHeight;
  24045. }
  24046. this._updateVirtualList();
  24047. }
  24048. },
  24049. // 更新fixedCell模式下topRangeIndex&placeholderTopHeight
  24050. _updateFixedTopRangeIndex: function _updateFixedTopRangeIndex(scrollIndex) {
  24051. var virtualTopRangeIndex = this.virtualCellHeight === 0 ? 0 : scrollIndex - (parseInt(this.finalVirtualPageHeight / this.virtualCellHeight) || 1) * this.preloadPage;
  24052. virtualTopRangeIndex *= this.virtualListCol;
  24053. virtualTopRangeIndex = Math.max(0, virtualTopRangeIndex);
  24054. this.virtualTopRangeIndex = virtualTopRangeIndex;
  24055. this.virtualPlaceholderTopHeight = virtualTopRangeIndex / this.virtualListCol * this.virtualCellHeight;
  24056. },
  24057. // 更新fixedCell模式下bottomRangeIndex&placeholderBottomHeight
  24058. _updateFixedBottomRangeIndex: function _updateFixedBottomRangeIndex(scrollIndex) {
  24059. var virtualBottomRangeIndex = this.virtualCellHeight === 0 ? this.pageSize : scrollIndex + (parseInt(this.finalVirtualPageHeight / this.virtualCellHeight) || 1) * (this.preloadPage + 1);
  24060. virtualBottomRangeIndex *= this.virtualListCol;
  24061. virtualBottomRangeIndex = Math.min(this.realTotalData.length, virtualBottomRangeIndex);
  24062. this.virtualBottomRangeIndex = virtualBottomRangeIndex;
  24063. this.virtualPlaceholderBottomHeight = (this.realTotalData.length - virtualBottomRangeIndex) * this.virtualCellHeight / this.virtualListCol;
  24064. this._updateVirtualList();
  24065. },
  24066. // 更新virtualList
  24067. _updateVirtualList: function _updateVirtualList() {
  24068. var shouldUpdateList = this.updateVirtualListFromDataChange || this.lastVirtualTopRangeIndex !== this.virtualTopRangeIndex || this.lastVirtualBottomRangeIndex !== this.virtualBottomRangeIndex;
  24069. if (shouldUpdateList) {
  24070. this.updateVirtualListFromDataChange = false;
  24071. this.lastVirtualTopRangeIndex = this.virtualTopRangeIndex;
  24072. this.lastVirtualBottomRangeIndex = this.virtualBottomRangeIndex;
  24073. this.virtualList = this.realTotalData.slice(this.virtualTopRangeIndex, this.virtualBottomRangeIndex + 1);
  24074. }
  24075. },
  24076. // 重置动态cell模式下的高度缓存数据、虚拟列表和滚动状态
  24077. _resetDynamicListState: function _resetDynamicListState() {
  24078. var resetVirtualList = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;
  24079. this.virtualHeightCacheList = [];
  24080. if (resetVirtualList) {
  24081. this.virtualList = [];
  24082. }
  24083. this.virtualTopRangeIndex = 0;
  24084. this.virtualPlaceholderTopHeight = 0;
  24085. },
  24086. // 重置topRangeIndex和placeholderTopHeight
  24087. _resetTopRange: function _resetTopRange() {
  24088. this.virtualTopRangeIndex = 0;
  24089. this.virtualPlaceholderTopHeight = 0;
  24090. this._updateVirtualList();
  24091. },
  24092. // 检测虚拟列表当前滚动位置,如发现滚动位置不正确则重新计算虚拟列表相关参数(为解决在App中可能出现的长时间进入后台后打开App白屏的问题)
  24093. _checkVirtualListScroll: function _checkVirtualListScroll() {
  24094. var _this6 = this;
  24095. if (this.finalUseVirtualList) {
  24096. this.$nextTick(function () {
  24097. _this6._getNodeClientRect('.zp-paging-touch-view').then(function (node) {
  24098. var currentTop = node ? node[0].top : 0;
  24099. if (!node || currentTop === _this6.pagingOrgTop && _this6.virtualPlaceholderTopHeight !== 0) {
  24100. _this6._updateVirtualScroll(0);
  24101. }
  24102. });
  24103. });
  24104. }
  24105. },
  24106. // 获取对应index的虚拟列表cell节点信息
  24107. _getVirtualCellNodeByIndex: function _getVirtualCellNodeByIndex(index) {
  24108. var inDom = this.finalUseInnerList;
  24109. // 在vue3+(微信小程序或QQ小程序)中,使用非内置列表写法时,若z-paging在swiper-item内存在无法获取slot插入的cell高度的问题
  24110. // 通过uni.createSelectorQuery().in(this.$parent)来解决此问题
  24111. return this._getNodeClientRect("#".concat(this.fianlVirtualCellIdPrefix, "-").concat(index), inDom);
  24112. },
  24113. // 处理使用内置列表时点击了cell事件
  24114. _innerCellClick: function _innerCellClick(item, index) {
  24115. this.$emit('innerCellClick', item, index);
  24116. }
  24117. }
  24118. };
  24119. exports.default = _default;
  24120. /***/ }),
  24121. /* 272 */,
  24122. /* 273 */,
  24123. /* 274 */,
  24124. /* 275 */,
  24125. /* 276 */,
  24126. /* 277 */,
  24127. /* 278 */,
  24128. /* 279 */
  24129. /*!******************************************************************************************!*\
  24130. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/components/u-skeleton/props.js ***!
  24131. \******************************************************************************************/
  24132. /*! no static exports found */
  24133. /***/ (function(module, exports, __webpack_require__) {
  24134. "use strict";
  24135. /* WEBPACK VAR INJECTION */(function(uni) {
  24136. Object.defineProperty(exports, "__esModule", {
  24137. value: true
  24138. });
  24139. exports.default = void 0;
  24140. var _default = {
  24141. props: {
  24142. // 是否展示骨架组件
  24143. loading: {
  24144. type: Boolean,
  24145. default: uni.$u.props.skeleton.loading
  24146. },
  24147. // 是否开启动画效果
  24148. animate: {
  24149. type: Boolean,
  24150. default: uni.$u.props.skeleton.animate
  24151. },
  24152. // 段落占位图行数
  24153. rows: {
  24154. type: [String, Number],
  24155. default: uni.$u.props.skeleton.rows
  24156. },
  24157. // 段落占位图的宽度
  24158. rowsWidth: {
  24159. type: [String, Number, Array],
  24160. default: uni.$u.props.skeleton.rowsWidth
  24161. },
  24162. // 段落占位图的高度
  24163. rowsHeight: {
  24164. type: [String, Number, Array],
  24165. default: uni.$u.props.skeleton.rowsHeight
  24166. },
  24167. // 是否展示标题占位图
  24168. title: {
  24169. type: Boolean,
  24170. default: uni.$u.props.skeleton.title
  24171. },
  24172. // 段落标题的宽度
  24173. titleWidth: {
  24174. type: [String, Number],
  24175. default: uni.$u.props.skeleton.titleWidth
  24176. },
  24177. // 段落标题的高度
  24178. titleHeight: {
  24179. type: [String, Number],
  24180. default: uni.$u.props.skeleton.titleHeight
  24181. },
  24182. // 是否展示头像占位图
  24183. avatar: {
  24184. type: Boolean,
  24185. default: uni.$u.props.skeleton.avatar
  24186. },
  24187. // 头像占位图大小
  24188. avatarSize: {
  24189. type: [String, Number],
  24190. default: uni.$u.props.skeleton.avatarSize
  24191. },
  24192. // 头像占位图的形状,circle-圆形,square-方形
  24193. avatarShape: {
  24194. type: String,
  24195. default: uni.$u.props.skeleton.avatarShape
  24196. }
  24197. }
  24198. };
  24199. exports.default = _default;
  24200. /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./node_modules/@dcloudio/uni-mp-toutiao/dist/index.js */ 1)["default"]))
  24201. /***/ }),
  24202. /* 280 */,
  24203. /* 281 */,
  24204. /* 282 */,
  24205. /* 283 */,
  24206. /* 284 */,
  24207. /* 285 */,
  24208. /* 286 */,
  24209. /* 287 */,
  24210. /* 288 */,
  24211. /* 289 */,
  24212. /* 290 */,
  24213. /* 291 */,
  24214. /* 292 */,
  24215. /* 293 */,
  24216. /* 294 */
  24217. /*!**************************************************************************************!*\
  24218. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/components/u-icon/icons.js ***!
  24219. \**************************************************************************************/
  24220. /*! no static exports found */
  24221. /***/ (function(module, exports, __webpack_require__) {
  24222. "use strict";
  24223. Object.defineProperty(exports, "__esModule", {
  24224. value: true
  24225. });
  24226. exports.default = void 0;
  24227. var _default = {
  24228. 'uicon-level': "\uE693",
  24229. 'uicon-column-line': "\uE68E",
  24230. 'uicon-checkbox-mark': "\uE807",
  24231. 'uicon-folder': "\uE7F5",
  24232. 'uicon-movie': "\uE7F6",
  24233. 'uicon-star-fill': "\uE669",
  24234. 'uicon-star': "\uE65F",
  24235. 'uicon-phone-fill': "\uE64F",
  24236. 'uicon-phone': "\uE622",
  24237. 'uicon-apple-fill': "\uE881",
  24238. 'uicon-chrome-circle-fill': "\uE885",
  24239. 'uicon-backspace': "\uE67B",
  24240. 'uicon-attach': "\uE632",
  24241. 'uicon-cut': "\uE948",
  24242. 'uicon-empty-car': "\uE602",
  24243. 'uicon-empty-coupon': "\uE682",
  24244. 'uicon-empty-address': "\uE646",
  24245. 'uicon-empty-favor': "\uE67C",
  24246. 'uicon-empty-permission': "\uE686",
  24247. 'uicon-empty-news': "\uE687",
  24248. 'uicon-empty-search': "\uE664",
  24249. 'uicon-github-circle-fill': "\uE887",
  24250. 'uicon-rmb': "\uE608",
  24251. 'uicon-person-delete-fill': "\uE66A",
  24252. 'uicon-reload': "\uE788",
  24253. 'uicon-order': "\uE68F",
  24254. 'uicon-server-man': "\uE6BC",
  24255. 'uicon-search': "\uE62A",
  24256. 'uicon-fingerprint': "\uE955",
  24257. 'uicon-more-dot-fill': "\uE630",
  24258. 'uicon-scan': "\uE662",
  24259. 'uicon-share-square': "\uE60B",
  24260. 'uicon-map': "\uE61D",
  24261. 'uicon-map-fill': "\uE64E",
  24262. 'uicon-tags': "\uE629",
  24263. 'uicon-tags-fill': "\uE651",
  24264. 'uicon-bookmark-fill': "\uE63B",
  24265. 'uicon-bookmark': "\uE60A",
  24266. 'uicon-eye': "\uE613",
  24267. 'uicon-eye-fill': "\uE641",
  24268. 'uicon-mic': "\uE64A",
  24269. 'uicon-mic-off': "\uE649",
  24270. 'uicon-calendar': "\uE66E",
  24271. 'uicon-calendar-fill': "\uE634",
  24272. 'uicon-trash': "\uE623",
  24273. 'uicon-trash-fill': "\uE658",
  24274. 'uicon-play-left': "\uE66D",
  24275. 'uicon-play-right': "\uE610",
  24276. 'uicon-minus': "\uE618",
  24277. 'uicon-plus': "\uE62D",
  24278. 'uicon-info': "\uE653",
  24279. 'uicon-info-circle': "\uE7D2",
  24280. 'uicon-info-circle-fill': "\uE64B",
  24281. 'uicon-question': "\uE715",
  24282. 'uicon-error': "\uE6D3",
  24283. 'uicon-close': "\uE685",
  24284. 'uicon-checkmark': "\uE6A8",
  24285. 'uicon-android-circle-fill': "\uE67E",
  24286. 'uicon-android-fill': "\uE67D",
  24287. 'uicon-ie': "\uE87B",
  24288. 'uicon-IE-circle-fill': "\uE889",
  24289. 'uicon-google': "\uE87A",
  24290. 'uicon-google-circle-fill': "\uE88A",
  24291. 'uicon-setting-fill': "\uE872",
  24292. 'uicon-setting': "\uE61F",
  24293. 'uicon-minus-square-fill': "\uE855",
  24294. 'uicon-plus-square-fill': "\uE856",
  24295. 'uicon-heart': "\uE7DF",
  24296. 'uicon-heart-fill': "\uE851",
  24297. 'uicon-camera': "\uE7D7",
  24298. 'uicon-camera-fill': "\uE870",
  24299. 'uicon-more-circle': "\uE63E",
  24300. 'uicon-more-circle-fill': "\uE645",
  24301. 'uicon-chat': "\uE620",
  24302. 'uicon-chat-fill': "\uE61E",
  24303. 'uicon-bag-fill': "\uE617",
  24304. 'uicon-bag': "\uE619",
  24305. 'uicon-error-circle-fill': "\uE62C",
  24306. 'uicon-error-circle': "\uE624",
  24307. 'uicon-close-circle': "\uE63F",
  24308. 'uicon-close-circle-fill': "\uE637",
  24309. 'uicon-checkmark-circle': "\uE63D",
  24310. 'uicon-checkmark-circle-fill': "\uE635",
  24311. 'uicon-question-circle-fill': "\uE666",
  24312. 'uicon-question-circle': "\uE625",
  24313. 'uicon-share': "\uE631",
  24314. 'uicon-share-fill': "\uE65E",
  24315. 'uicon-shopping-cart': "\uE621",
  24316. 'uicon-shopping-cart-fill': "\uE65D",
  24317. 'uicon-bell': "\uE609",
  24318. 'uicon-bell-fill': "\uE640",
  24319. 'uicon-list': "\uE650",
  24320. 'uicon-list-dot': "\uE616",
  24321. 'uicon-zhihu': "\uE6BA",
  24322. 'uicon-zhihu-circle-fill': "\uE709",
  24323. 'uicon-zhifubao': "\uE6B9",
  24324. 'uicon-zhifubao-circle-fill': "\uE6B8",
  24325. 'uicon-weixin-circle-fill': "\uE6B1",
  24326. 'uicon-weixin-fill': "\uE6B2",
  24327. 'uicon-twitter-circle-fill': "\uE6AB",
  24328. 'uicon-twitter': "\uE6AA",
  24329. 'uicon-taobao-circle-fill': "\uE6A7",
  24330. 'uicon-taobao': "\uE6A6",
  24331. 'uicon-weibo-circle-fill': "\uE6A5",
  24332. 'uicon-weibo': "\uE6A4",
  24333. 'uicon-qq-fill': "\uE6A1",
  24334. 'uicon-qq-circle-fill': "\uE6A0",
  24335. 'uicon-moments-circel-fill': "\uE69A",
  24336. 'uicon-moments': "\uE69B",
  24337. 'uicon-qzone': "\uE695",
  24338. 'uicon-qzone-circle-fill': "\uE696",
  24339. 'uicon-baidu-circle-fill': "\uE680",
  24340. 'uicon-baidu': "\uE681",
  24341. 'uicon-facebook-circle-fill': "\uE68A",
  24342. 'uicon-facebook': "\uE689",
  24343. 'uicon-car': "\uE60C",
  24344. 'uicon-car-fill': "\uE636",
  24345. 'uicon-warning-fill': "\uE64D",
  24346. 'uicon-warning': "\uE694",
  24347. 'uicon-clock-fill': "\uE638",
  24348. 'uicon-clock': "\uE60F",
  24349. 'uicon-edit-pen': "\uE612",
  24350. 'uicon-edit-pen-fill': "\uE66B",
  24351. 'uicon-email': "\uE611",
  24352. 'uicon-email-fill': "\uE642",
  24353. 'uicon-minus-circle': "\uE61B",
  24354. 'uicon-minus-circle-fill': "\uE652",
  24355. 'uicon-plus-circle': "\uE62E",
  24356. 'uicon-plus-circle-fill': "\uE661",
  24357. 'uicon-file-text': "\uE663",
  24358. 'uicon-file-text-fill': "\uE665",
  24359. 'uicon-pushpin': "\uE7E3",
  24360. 'uicon-pushpin-fill': "\uE86E",
  24361. 'uicon-grid': "\uE673",
  24362. 'uicon-grid-fill': "\uE678",
  24363. 'uicon-play-circle': "\uE647",
  24364. 'uicon-play-circle-fill': "\uE655",
  24365. 'uicon-pause-circle-fill': "\uE654",
  24366. 'uicon-pause': "\uE8FA",
  24367. 'uicon-pause-circle': "\uE643",
  24368. 'uicon-eye-off': "\uE648",
  24369. 'uicon-eye-off-outline': "\uE62B",
  24370. 'uicon-gift-fill': "\uE65C",
  24371. 'uicon-gift': "\uE65B",
  24372. 'uicon-rmb-circle-fill': "\uE657",
  24373. 'uicon-rmb-circle': "\uE677",
  24374. 'uicon-kefu-ermai': "\uE656",
  24375. 'uicon-server-fill': "\uE751",
  24376. 'uicon-coupon-fill': "\uE8C4",
  24377. 'uicon-coupon': "\uE8AE",
  24378. 'uicon-integral': "\uE704",
  24379. 'uicon-integral-fill': "\uE703",
  24380. 'uicon-home-fill': "\uE964",
  24381. 'uicon-home': "\uE965",
  24382. 'uicon-hourglass-half-fill': "\uE966",
  24383. 'uicon-hourglass': "\uE967",
  24384. 'uicon-account': "\uE628",
  24385. 'uicon-plus-people-fill': "\uE626",
  24386. 'uicon-minus-people-fill': "\uE615",
  24387. 'uicon-account-fill': "\uE614",
  24388. 'uicon-thumb-down-fill': "\uE726",
  24389. 'uicon-thumb-down': "\uE727",
  24390. 'uicon-thumb-up': "\uE733",
  24391. 'uicon-thumb-up-fill': "\uE72F",
  24392. 'uicon-lock-fill': "\uE979",
  24393. 'uicon-lock-open': "\uE973",
  24394. 'uicon-lock-opened-fill': "\uE974",
  24395. 'uicon-lock': "\uE97A",
  24396. 'uicon-red-packet-fill': "\uE690",
  24397. 'uicon-photo-fill': "\uE98B",
  24398. 'uicon-photo': "\uE98D",
  24399. 'uicon-volume-off-fill': "\uE659",
  24400. 'uicon-volume-off': "\uE644",
  24401. 'uicon-volume-fill': "\uE670",
  24402. 'uicon-volume': "\uE633",
  24403. 'uicon-red-packet': "\uE691",
  24404. 'uicon-download': "\uE63C",
  24405. 'uicon-arrow-up-fill': "\uE6B0",
  24406. 'uicon-arrow-down-fill': "\uE600",
  24407. 'uicon-play-left-fill': "\uE675",
  24408. 'uicon-play-right-fill': "\uE676",
  24409. 'uicon-rewind-left-fill': "\uE679",
  24410. 'uicon-rewind-right-fill': "\uE67A",
  24411. 'uicon-arrow-downward': "\uE604",
  24412. 'uicon-arrow-leftward': "\uE601",
  24413. 'uicon-arrow-rightward': "\uE603",
  24414. 'uicon-arrow-upward': "\uE607",
  24415. 'uicon-arrow-down': "\uE60D",
  24416. 'uicon-arrow-right': "\uE605",
  24417. 'uicon-arrow-left': "\uE60E",
  24418. 'uicon-arrow-up': "\uE606",
  24419. 'uicon-skip-back-left': "\uE674",
  24420. 'uicon-skip-forward-right': "\uE672",
  24421. 'uicon-rewind-right': "\uE66F",
  24422. 'uicon-rewind-left': "\uE671",
  24423. 'uicon-arrow-right-double': "\uE68D",
  24424. 'uicon-arrow-left-double': "\uE68C",
  24425. 'uicon-wifi-off': "\uE668",
  24426. 'uicon-wifi': "\uE667",
  24427. 'uicon-empty-data': "\uE62F",
  24428. 'uicon-empty-history': "\uE684",
  24429. 'uicon-empty-list': "\uE68B",
  24430. 'uicon-empty-page': "\uE627",
  24431. 'uicon-empty-order': "\uE639",
  24432. 'uicon-man': "\uE697",
  24433. 'uicon-woman': "\uE69C",
  24434. 'uicon-man-add': "\uE61C",
  24435. 'uicon-man-add-fill': "\uE64C",
  24436. 'uicon-man-delete': "\uE61A",
  24437. 'uicon-man-delete-fill': "\uE66A",
  24438. 'uicon-zh': "\uE70A",
  24439. 'uicon-en': "\uE692"
  24440. };
  24441. exports.default = _default;
  24442. /***/ }),
  24443. /* 295 */
  24444. /*!**************************************************************************************!*\
  24445. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uview-ui/components/u-icon/props.js ***!
  24446. \**************************************************************************************/
  24447. /*! no static exports found */
  24448. /***/ (function(module, exports, __webpack_require__) {
  24449. "use strict";
  24450. /* WEBPACK VAR INJECTION */(function(uni) {
  24451. Object.defineProperty(exports, "__esModule", {
  24452. value: true
  24453. });
  24454. exports.default = void 0;
  24455. var _default = {
  24456. props: {
  24457. // 图标类名
  24458. name: {
  24459. type: String,
  24460. default: uni.$u.props.icon.name
  24461. },
  24462. // 图标颜色,可接受主题色
  24463. color: {
  24464. type: String,
  24465. default: uni.$u.props.icon.color
  24466. },
  24467. // 字体大小,单位px
  24468. size: {
  24469. type: [String, Number],
  24470. default: uni.$u.props.icon.size
  24471. },
  24472. // 是否显示粗体
  24473. bold: {
  24474. type: Boolean,
  24475. default: uni.$u.props.icon.bold
  24476. },
  24477. // 点击图标的时候传递事件出去的index(用于区分点击了哪一个)
  24478. index: {
  24479. type: [String, Number],
  24480. default: uni.$u.props.icon.index
  24481. },
  24482. // 触摸图标时的类名
  24483. hoverClass: {
  24484. type: String,
  24485. default: uni.$u.props.icon.hoverClass
  24486. },
  24487. // 自定义扩展前缀,方便用户扩展自己的图标库
  24488. customPrefix: {
  24489. type: String,
  24490. default: uni.$u.props.icon.customPrefix
  24491. },
  24492. // 图标右边或者下面的文字
  24493. label: {
  24494. type: [String, Number],
  24495. default: uni.$u.props.icon.label
  24496. },
  24497. // label的位置,只能右边或者下边
  24498. labelPos: {
  24499. type: String,
  24500. default: uni.$u.props.icon.labelPos
  24501. },
  24502. // label的大小
  24503. labelSize: {
  24504. type: [String, Number],
  24505. default: uni.$u.props.icon.labelSize
  24506. },
  24507. // label的颜色
  24508. labelColor: {
  24509. type: String,
  24510. default: uni.$u.props.icon.labelColor
  24511. },
  24512. // label与图标的距离
  24513. space: {
  24514. type: [String, Number],
  24515. default: uni.$u.props.icon.space
  24516. },
  24517. // 图片的mode
  24518. imgMode: {
  24519. type: String,
  24520. default: uni.$u.props.icon.imgMode
  24521. },
  24522. // 用于显示图片小图标时,图片的宽度
  24523. width: {
  24524. type: [String, Number],
  24525. default: uni.$u.props.icon.width
  24526. },
  24527. // 用于显示图片小图标时,图片的高度
  24528. height: {
  24529. type: [String, Number],
  24530. default: uni.$u.props.icon.height
  24531. },
  24532. // 用于解决某些情况下,让图标垂直居中的用途
  24533. top: {
  24534. type: [String, Number],
  24535. default: uni.$u.props.icon.top
  24536. },
  24537. // 是否阻止事件传播
  24538. stop: {
  24539. type: Boolean,
  24540. default: uni.$u.props.icon.stop
  24541. }
  24542. }
  24543. };
  24544. exports.default = _default;
  24545. /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./node_modules/@dcloudio/uni-mp-toutiao/dist/index.js */ 1)["default"]))
  24546. /***/ }),
  24547. /* 296 */,
  24548. /* 297 */,
  24549. /* 298 */,
  24550. /* 299 */,
  24551. /* 300 */,
  24552. /* 301 */,
  24553. /* 302 */,
  24554. /* 303 */,
  24555. /* 304 */,
  24556. /* 305 */,
  24557. /* 306 */,
  24558. /* 307 */,
  24559. /* 308 */,
  24560. /* 309 */,
  24561. /* 310 */,
  24562. /* 311 */,
  24563. /* 312 */,
  24564. /* 313 */,
  24565. /* 314 */,
  24566. /* 315 */,
  24567. /* 316 */,
  24568. /* 317 */,
  24569. /* 318 */,
  24570. /* 319 */,
  24571. /* 320 */,
  24572. /* 321 */,
  24573. /* 322 */,
  24574. /* 323 */,
  24575. /* 324 */
  24576. /*!**************************************************************************************************************!*\
  24577. !*** /Users/z/D/hx-mini/hx-mini-uni/uni_modules/uni-transition/components/uni-transition/createAnimation.js ***!
  24578. \**************************************************************************************************************/
  24579. /*! no static exports found */
  24580. /***/ (function(module, exports, __webpack_require__) {
  24581. "use strict";
  24582. /* WEBPACK VAR INJECTION */(function(uni) {
  24583. var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 3);
  24584. Object.defineProperty(exports, "__esModule", {
  24585. value: true
  24586. });
  24587. exports.createAnimation = createAnimation;
  24588. var _defineProperty2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/defineProperty */ 10));
  24589. var _classCallCheck2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/classCallCheck */ 17));
  24590. var _createClass2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/createClass */ 18));
  24591. function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
  24592. function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { (0, _defineProperty2.default)(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
  24593. // const defaultOption = {
  24594. // duration: 300,
  24595. // timingFunction: 'linear',
  24596. // delay: 0,
  24597. // transformOrigin: '50% 50% 0'
  24598. // }
  24599. var MPAnimation = /*#__PURE__*/function () {
  24600. function MPAnimation(options, _this) {
  24601. (0, _classCallCheck2.default)(this, MPAnimation);
  24602. this.options = options;
  24603. // 在iOS10+QQ小程序平台下,传给原生的对象一定是个普通对象而不是Proxy对象,否则会报parameter should be Object instead of ProxyObject的错误
  24604. this.animation = uni.createAnimation(_objectSpread({}, options));
  24605. this.currentStepAnimates = {};
  24606. this.next = 0;
  24607. this.$ = _this;
  24608. }
  24609. (0, _createClass2.default)(MPAnimation, [{
  24610. key: "_nvuePushAnimates",
  24611. value: function _nvuePushAnimates(type, args) {
  24612. var aniObj = this.currentStepAnimates[this.next];
  24613. var styles = {};
  24614. if (!aniObj) {
  24615. styles = {
  24616. styles: {},
  24617. config: {}
  24618. };
  24619. } else {
  24620. styles = aniObj;
  24621. }
  24622. if (animateTypes1.includes(type)) {
  24623. if (!styles.styles.transform) {
  24624. styles.styles.transform = '';
  24625. }
  24626. var unit = '';
  24627. if (type === 'rotate') {
  24628. unit = 'deg';
  24629. }
  24630. styles.styles.transform += "".concat(type, "(").concat(args + unit, ") ");
  24631. } else {
  24632. styles.styles[type] = "".concat(args);
  24633. }
  24634. this.currentStepAnimates[this.next] = styles;
  24635. }
  24636. }, {
  24637. key: "_animateRun",
  24638. value: function _animateRun() {
  24639. var styles = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
  24640. var config = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
  24641. var ref = this.$.$refs['ani'].ref;
  24642. if (!ref) return;
  24643. return new Promise(function (resolve, reject) {
  24644. nvueAnimation.transition(ref, _objectSpread({
  24645. styles: styles
  24646. }, config), function (res) {
  24647. resolve();
  24648. });
  24649. });
  24650. }
  24651. }, {
  24652. key: "_nvueNextAnimate",
  24653. value: function _nvueNextAnimate(animates) {
  24654. var _this2 = this;
  24655. var step = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
  24656. var fn = arguments.length > 2 ? arguments[2] : undefined;
  24657. var obj = animates[step];
  24658. if (obj) {
  24659. var styles = obj.styles,
  24660. config = obj.config;
  24661. this._animateRun(styles, config).then(function () {
  24662. step += 1;
  24663. _this2._nvueNextAnimate(animates, step, fn);
  24664. });
  24665. } else {
  24666. this.currentStepAnimates = {};
  24667. typeof fn === 'function' && fn();
  24668. this.isEnd = true;
  24669. }
  24670. }
  24671. }, {
  24672. key: "step",
  24673. value: function step() {
  24674. var config = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
  24675. this.animation.step(config);
  24676. return this;
  24677. }
  24678. }, {
  24679. key: "run",
  24680. value: function run(fn) {
  24681. this.$.animationData = this.animation.export();
  24682. this.$.timer = setTimeout(function () {
  24683. typeof fn === 'function' && fn();
  24684. }, this.$.durationTime);
  24685. }
  24686. }]);
  24687. return MPAnimation;
  24688. }();
  24689. var animateTypes1 = ['matrix', 'matrix3d', 'rotate', 'rotate3d', 'rotateX', 'rotateY', 'rotateZ', 'scale', 'scale3d', 'scaleX', 'scaleY', 'scaleZ', 'skew', 'skewX', 'skewY', 'translate', 'translate3d', 'translateX', 'translateY', 'translateZ'];
  24690. var animateTypes2 = ['opacity', 'backgroundColor'];
  24691. var animateTypes3 = ['width', 'height', 'left', 'right', 'top', 'bottom'];
  24692. animateTypes1.concat(animateTypes2, animateTypes3).forEach(function (type) {
  24693. MPAnimation.prototype[type] = function () {
  24694. var _this$animation;
  24695. (_this$animation = this.animation)[type].apply(_this$animation, arguments);
  24696. return this;
  24697. };
  24698. });
  24699. function createAnimation(option, _this) {
  24700. if (!_this) return;
  24701. clearTimeout(_this.timer);
  24702. return new MPAnimation(option, _this);
  24703. }
  24704. /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./node_modules/@dcloudio/uni-mp-toutiao/dist/index.js */ 1)["default"]))
  24705. /***/ })
  24706. ]]);
  24707. //# sourceMappingURL=../../.sourcemap/mp-toutiao/common/vendor.js.map