| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944294529462947294829492950295129522953295429552956295729582959296029612962296329642965296629672968296929702971297229732974297529762977297829792980298129822983298429852986298729882989299029912992299329942995299629972998299930003001300230033004300530063007300830093010301130123013301430153016301730183019302030213022302330243025302630273028302930303031303230333034303530363037303830393040304130423043304430453046304730483049305030513052305330543055305630573058305930603061306230633064306530663067306830693070307130723073307430753076307730783079308030813082308330843085308630873088308930903091309230933094309530963097309830993100310131023103310431053106310731083109311031113112311331143115311631173118311931203121312231233124312531263127312831293130313131323133313431353136313731383139314031413142314331443145314631473148314931503151315231533154315531563157315831593160316131623163316431653166316731683169317031713172317331743175317631773178317931803181318231833184318531863187318831893190319131923193319431953196319731983199320032013202320332043205320632073208320932103211321232133214321532163217321832193220322132223223322432253226322732283229323032313232323332343235323632373238323932403241324232433244324532463247324832493250325132523253325432553256325732583259326032613262326332643265326632673268326932703271327232733274327532763277327832793280328132823283328432853286328732883289329032913292329332943295329632973298329933003301330233033304330533063307330833093310331133123313331433153316331733183319332033213322332333243325332633273328332933303331333233333334333533363337333833393340334133423343334433453346334733483349335033513352335333543355335633573358335933603361336233633364336533663367336833693370337133723373337433753376337733783379338033813382338333843385338633873388338933903391339233933394339533963397339833993400340134023403340434053406340734083409341034113412341334143415341634173418341934203421342234233424342534263427342834293430343134323433343434353436343734383439344034413442344334443445344634473448344934503451345234533454345534563457345834593460346134623463346434653466346734683469347034713472347334743475347634773478347934803481348234833484348534863487348834893490349134923493349434953496349734983499350035013502350335043505350635073508350935103511351235133514351535163517351835193520352135223523352435253526352735283529353035313532353335343535353635373538353935403541354235433544354535463547354835493550355135523553355435553556355735583559356035613562356335643565356635673568356935703571357235733574357535763577357835793580358135823583358435853586358735883589359035913592359335943595359635973598359936003601360236033604360536063607360836093610361136123613361436153616361736183619362036213622362336243625362636273628362936303631363236333634363536363637363836393640364136423643364436453646364736483649365036513652365336543655365636573658365936603661366236633664366536663667366836693670367136723673367436753676367736783679368036813682368336843685368636873688368936903691369236933694369536963697369836993700370137023703370437053706370737083709371037113712371337143715371637173718371937203721372237233724372537263727372837293730373137323733373437353736373737383739374037413742374337443745374637473748374937503751375237533754375537563757375837593760376137623763376437653766376737683769377037713772377337743775377637773778377937803781378237833784378537863787378837893790379137923793379437953796379737983799380038013802380338043805380638073808380938103811381238133814381538163817381838193820382138223823382438253826382738283829383038313832383338343835383638373838383938403841384238433844384538463847384838493850385138523853385438553856385738583859386038613862386338643865386638673868 |
- /**
- * @license Angular v8.1.3
- * (c) 2010-2019 Google LLC. https://angular.io/
- * License: MIT
- */
- import { ɵparseCookieValue, PlatformLocation, DOCUMENT, isPlatformServer, CommonModule, ɵPLATFORM_BROWSER_ID } from '@angular/common';
- import { ɵglobal, Injectable, Inject, InjectionToken, ApplicationInitStatus, APP_INITIALIZER, Injector, setTestabilityGetter, NgProbeToken, Optional, ApplicationRef, NgZone, getDebugNode, ViewEncapsulation, APP_ID, RendererStyleFlags2, PLATFORM_ID, ɵConsole, SecurityContext, ɵ_sanitizeHtml, ɵ_sanitizeStyle, ɵ_sanitizeUrl, PLATFORM_INITIALIZER, Sanitizer, createPlatformFactory, platformCore, ErrorHandler, ɵAPP_ROOT, RendererFactory2, Testability, NgModule, ApplicationModule, SkipSelf, ɵɵinject, ɵɵdefineInjectable, Version } from '@angular/core';
- /**
- * @fileoverview added by tsickle
- * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
- */
- /**
- * @license
- * Copyright Google Inc. All Rights Reserved.
- *
- * Use of this source code is governed by an MIT-style license that can be
- * found in the LICENSE file at https://angular.io/license
- */
- /** @type {?} */
- let _DOM = (/** @type {?} */ (null));
- /**
- * @return {?}
- */
- function getDOM() {
- return _DOM;
- }
- /**
- * @param {?} adapter
- * @return {?}
- */
- function setRootDomAdapter(adapter) {
- if (!_DOM) {
- _DOM = adapter;
- }
- }
- /* tslint:disable:requireParameterType */
- /**
- * Provides DOM operations in an environment-agnostic way.
- *
- * \@security Tread carefully! Interacting with the DOM directly is dangerous and
- * can introduce XSS risks.
- * @abstract
- */
- class DomAdapter {
- constructor() {
- this.resourceLoaderType = (/** @type {?} */ (null));
- }
- /**
- * Maps attribute names to their corresponding property names for cases
- * where attribute name doesn't match property name.
- * @return {?}
- */
- get attrToPropMap() { return this._attrToPropMap; }
- /**
- * @param {?} value
- * @return {?}
- */
- set attrToPropMap(value) { this._attrToPropMap = value; }
- }
- /**
- * @fileoverview added by tsickle
- * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
- */
- /**
- * Provides DOM operations in any browser environment.
- *
- * \@security Tread carefully! Interacting with the DOM directly is dangerous and
- * can introduce XSS risks.
- * @abstract
- */
- class GenericBrowserDomAdapter extends DomAdapter {
- constructor() {
- super();
- this._animationPrefix = null;
- this._transitionEnd = null;
- try {
- /** @type {?} */
- const element = this.createElement('div', document);
- if (this.getStyle(element, 'animationName') != null) {
- this._animationPrefix = '';
- }
- else {
- /** @type {?} */
- const domPrefixes = ['Webkit', 'Moz', 'O', 'ms'];
- for (let i = 0; i < domPrefixes.length; i++) {
- if (this.getStyle(element, domPrefixes[i] + 'AnimationName') != null) {
- this._animationPrefix = '-' + domPrefixes[i].toLowerCase() + '-';
- break;
- }
- }
- }
- /** @type {?} */
- const transEndEventNames = {
- WebkitTransition: 'webkitTransitionEnd',
- MozTransition: 'transitionend',
- OTransition: 'oTransitionEnd otransitionend',
- transition: 'transitionend'
- };
- Object.keys(transEndEventNames).forEach((/**
- * @param {?} key
- * @return {?}
- */
- (key) => {
- if (this.getStyle(element, key) != null) {
- this._transitionEnd = transEndEventNames[key];
- }
- }));
- }
- catch (_a) {
- this._animationPrefix = null;
- this._transitionEnd = null;
- }
- }
- /**
- * @param {?} el
- * @return {?}
- */
- getDistributedNodes(el) { return ((/** @type {?} */ (el))).getDistributedNodes(); }
- /**
- * @param {?} el
- * @param {?} baseUrl
- * @param {?} href
- * @return {?}
- */
- resolveAndSetHref(el, baseUrl, href) {
- el.href = href == null ? baseUrl : baseUrl + '/../' + href;
- }
- /**
- * @return {?}
- */
- supportsDOMEvents() { return true; }
- /**
- * @return {?}
- */
- supportsNativeShadowDOM() {
- return typeof ((/** @type {?} */ (document.body))).createShadowRoot === 'function';
- }
- /**
- * @return {?}
- */
- getAnimationPrefix() { return this._animationPrefix ? this._animationPrefix : ''; }
- /**
- * @return {?}
- */
- getTransitionEnd() { return this._transitionEnd ? this._transitionEnd : ''; }
- /**
- * @return {?}
- */
- supportsAnimation() {
- return this._animationPrefix != null && this._transitionEnd != null;
- }
- }
- /**
- * @fileoverview added by tsickle
- * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
- */
- /** @type {?} */
- const _attrToPropMap = {
- 'class': 'className',
- 'innerHtml': 'innerHTML',
- 'readonly': 'readOnly',
- 'tabindex': 'tabIndex',
- };
- /** @type {?} */
- const DOM_KEY_LOCATION_NUMPAD = 3;
- // Map to convert some key or keyIdentifier values to what will be returned by getEventKey
- /** @type {?} */
- const _keyMap = {
- // The following values are here for cross-browser compatibility and to match the W3C standard
- // cf http://www.w3.org/TR/DOM-Level-3-Events-key/
- '\b': 'Backspace',
- '\t': 'Tab',
- '\x7F': 'Delete',
- '\x1B': 'Escape',
- 'Del': 'Delete',
- 'Esc': 'Escape',
- 'Left': 'ArrowLeft',
- 'Right': 'ArrowRight',
- 'Up': 'ArrowUp',
- 'Down': 'ArrowDown',
- 'Menu': 'ContextMenu',
- 'Scroll': 'ScrollLock',
- 'Win': 'OS'
- };
- // There is a bug in Chrome for numeric keypad keys:
- // https://code.google.com/p/chromium/issues/detail?id=155654
- // 1, 2, 3 ... are reported as A, B, C ...
- /** @type {?} */
- const _chromeNumKeyPadMap = {
- 'A': '1',
- 'B': '2',
- 'C': '3',
- 'D': '4',
- 'E': '5',
- 'F': '6',
- 'G': '7',
- 'H': '8',
- 'I': '9',
- 'J': '*',
- 'K': '+',
- 'M': '-',
- 'N': '.',
- 'O': '/',
- '\x60': '0',
- '\x90': 'NumLock'
- };
- const ɵ0 = /**
- * @return {?}
- */
- () => {
- if (ɵglobal['Node']) {
- return ɵglobal['Node'].prototype.contains || (/**
- * @param {?} node
- * @return {?}
- */
- function (node) {
- return !!(this.compareDocumentPosition(node) & 16);
- });
- }
- return (/** @type {?} */ (undefined));
- };
- /** @type {?} */
- const nodeContains = ((ɵ0))();
- /**
- * A `DomAdapter` powered by full browser DOM APIs.
- *
- * \@security Tread carefully! Interacting with the DOM directly is dangerous and
- * can introduce XSS risks.
- */
- /* tslint:disable:requireParameterType no-console */
- class BrowserDomAdapter extends GenericBrowserDomAdapter {
- /**
- * @param {?} templateHtml
- * @return {?}
- */
- parse(templateHtml) { throw new Error('parse not implemented'); }
- /**
- * @return {?}
- */
- static makeCurrent() { setRootDomAdapter(new BrowserDomAdapter()); }
- /**
- * @param {?} element
- * @param {?} name
- * @return {?}
- */
- hasProperty(element, name) { return name in element; }
- /**
- * @param {?} el
- * @param {?} name
- * @param {?} value
- * @return {?}
- */
- setProperty(el, name, value) { ((/** @type {?} */ (el)))[name] = value; }
- /**
- * @param {?} el
- * @param {?} name
- * @return {?}
- */
- getProperty(el, name) { return ((/** @type {?} */ (el)))[name]; }
- /**
- * @param {?} el
- * @param {?} methodName
- * @param {?} args
- * @return {?}
- */
- invoke(el, methodName, args) { ((/** @type {?} */ (el)))[methodName](...args); }
- // TODO(tbosch): move this into a separate environment class once we have it
- /**
- * @param {?} error
- * @return {?}
- */
- logError(error) {
- if (window.console) {
- if (console.error) {
- console.error(error);
- }
- else {
- console.log(error);
- }
- }
- }
- /**
- * @param {?} error
- * @return {?}
- */
- log(error) {
- if (window.console) {
- window.console.log && window.console.log(error);
- }
- }
- /**
- * @param {?} error
- * @return {?}
- */
- logGroup(error) {
- if (window.console) {
- window.console.group && window.console.group(error);
- }
- }
- /**
- * @return {?}
- */
- logGroupEnd() {
- if (window.console) {
- window.console.groupEnd && window.console.groupEnd();
- }
- }
- /**
- * @return {?}
- */
- get attrToPropMap() { return _attrToPropMap; }
- /**
- * @param {?} nodeA
- * @param {?} nodeB
- * @return {?}
- */
- contains(nodeA, nodeB) { return nodeContains.call(nodeA, nodeB); }
- /**
- * @param {?} el
- * @param {?} selector
- * @return {?}
- */
- querySelector(el, selector) { return el.querySelector(selector); }
- /**
- * @param {?} el
- * @param {?} selector
- * @return {?}
- */
- querySelectorAll(el, selector) { return el.querySelectorAll(selector); }
- /**
- * @param {?} el
- * @param {?} evt
- * @param {?} listener
- * @return {?}
- */
- on(el, evt, listener) { el.addEventListener(evt, listener, false); }
- /**
- * @param {?} el
- * @param {?} evt
- * @param {?} listener
- * @return {?}
- */
- onAndCancel(el, evt, listener) {
- el.addEventListener(evt, listener, false);
- // Needed to follow Dart's subscription semantic, until fix of
- // https://code.google.com/p/dart/issues/detail?id=17406
- return (/**
- * @return {?}
- */
- () => { el.removeEventListener(evt, listener, false); });
- }
- /**
- * @param {?} el
- * @param {?} evt
- * @return {?}
- */
- dispatchEvent(el, evt) { el.dispatchEvent(evt); }
- /**
- * @param {?} eventType
- * @return {?}
- */
- createMouseEvent(eventType) {
- /** @type {?} */
- const evt = this.getDefaultDocument().createEvent('MouseEvent');
- evt.initEvent(eventType, true, true);
- return evt;
- }
- /**
- * @param {?} eventType
- * @return {?}
- */
- createEvent(eventType) {
- /** @type {?} */
- const evt = this.getDefaultDocument().createEvent('Event');
- evt.initEvent(eventType, true, true);
- return evt;
- }
- /**
- * @param {?} evt
- * @return {?}
- */
- preventDefault(evt) {
- evt.preventDefault();
- evt.returnValue = false;
- }
- /**
- * @param {?} evt
- * @return {?}
- */
- isPrevented(evt) {
- return evt.defaultPrevented || evt.returnValue != null && !evt.returnValue;
- }
- /**
- * @param {?} el
- * @return {?}
- */
- getInnerHTML(el) { return el.innerHTML; }
- /**
- * @param {?} el
- * @return {?}
- */
- getTemplateContent(el) {
- return 'content' in el && this.isTemplateElement(el) ? ((/** @type {?} */ (el))).content : null;
- }
- /**
- * @param {?} el
- * @return {?}
- */
- getOuterHTML(el) { return el.outerHTML; }
- /**
- * @param {?} node
- * @return {?}
- */
- nodeName(node) { return node.nodeName; }
- /**
- * @param {?} node
- * @return {?}
- */
- nodeValue(node) { return node.nodeValue; }
- /**
- * @param {?} node
- * @return {?}
- */
- type(node) { return node.type; }
- /**
- * @param {?} node
- * @return {?}
- */
- content(node) {
- if (this.hasProperty(node, 'content')) {
- return ((/** @type {?} */ (node))).content;
- }
- else {
- return node;
- }
- }
- /**
- * @param {?} el
- * @return {?}
- */
- firstChild(el) { return el.firstChild; }
- /**
- * @param {?} el
- * @return {?}
- */
- nextSibling(el) { return el.nextSibling; }
- /**
- * @param {?} el
- * @return {?}
- */
- parentElement(el) { return el.parentNode; }
- /**
- * @param {?} el
- * @return {?}
- */
- childNodes(el) { return el.childNodes; }
- /**
- * @param {?} el
- * @return {?}
- */
- childNodesAsList(el) {
- /** @type {?} */
- const childNodes = el.childNodes;
- /** @type {?} */
- const res = new Array(childNodes.length);
- for (let i = 0; i < childNodes.length; i++) {
- res[i] = childNodes[i];
- }
- return res;
- }
- /**
- * @param {?} el
- * @return {?}
- */
- clearNodes(el) {
- while (el.firstChild) {
- el.removeChild(el.firstChild);
- }
- }
- /**
- * @param {?} el
- * @param {?} node
- * @return {?}
- */
- appendChild(el, node) { el.appendChild(node); }
- /**
- * @param {?} el
- * @param {?} node
- * @return {?}
- */
- removeChild(el, node) { el.removeChild(node); }
- /**
- * @param {?} el
- * @param {?} newChild
- * @param {?} oldChild
- * @return {?}
- */
- replaceChild(el, newChild, oldChild) { el.replaceChild(newChild, oldChild); }
- /**
- * @param {?} node
- * @return {?}
- */
- remove(node) {
- if (node.parentNode) {
- node.parentNode.removeChild(node);
- }
- return node;
- }
- /**
- * @param {?} parent
- * @param {?} ref
- * @param {?} node
- * @return {?}
- */
- insertBefore(parent, ref, node) { parent.insertBefore(node, ref); }
- /**
- * @param {?} parent
- * @param {?} ref
- * @param {?} nodes
- * @return {?}
- */
- insertAllBefore(parent, ref, nodes) {
- nodes.forEach((/**
- * @param {?} n
- * @return {?}
- */
- (n) => parent.insertBefore(n, ref)));
- }
- /**
- * @param {?} parent
- * @param {?} ref
- * @param {?} node
- * @return {?}
- */
- insertAfter(parent, ref, node) { parent.insertBefore(node, ref.nextSibling); }
- /**
- * @param {?} el
- * @param {?} value
- * @return {?}
- */
- setInnerHTML(el, value) { el.innerHTML = value; }
- /**
- * @param {?} el
- * @return {?}
- */
- getText(el) { return el.textContent; }
- /**
- * @param {?} el
- * @param {?} value
- * @return {?}
- */
- setText(el, value) { el.textContent = value; }
- /**
- * @param {?} el
- * @return {?}
- */
- getValue(el) { return el.value; }
- /**
- * @param {?} el
- * @param {?} value
- * @return {?}
- */
- setValue(el, value) { el.value = value; }
- /**
- * @param {?} el
- * @return {?}
- */
- getChecked(el) { return el.checked; }
- /**
- * @param {?} el
- * @param {?} value
- * @return {?}
- */
- setChecked(el, value) { el.checked = value; }
- /**
- * @param {?} text
- * @return {?}
- */
- createComment(text) { return this.getDefaultDocument().createComment(text); }
- /**
- * @param {?} html
- * @return {?}
- */
- createTemplate(html) {
- /** @type {?} */
- const t = this.getDefaultDocument().createElement('template');
- t.innerHTML = html;
- return t;
- }
- /**
- * @param {?} tagName
- * @param {?=} doc
- * @return {?}
- */
- createElement(tagName, doc) {
- doc = doc || this.getDefaultDocument();
- return doc.createElement(tagName);
- }
- /**
- * @param {?} ns
- * @param {?} tagName
- * @param {?=} doc
- * @return {?}
- */
- createElementNS(ns, tagName, doc) {
- doc = doc || this.getDefaultDocument();
- return doc.createElementNS(ns, tagName);
- }
- /**
- * @param {?} text
- * @param {?=} doc
- * @return {?}
- */
- createTextNode(text, doc) {
- doc = doc || this.getDefaultDocument();
- return doc.createTextNode(text);
- }
- /**
- * @param {?} attrName
- * @param {?} attrValue
- * @param {?=} doc
- * @return {?}
- */
- createScriptTag(attrName, attrValue, doc) {
- doc = doc || this.getDefaultDocument();
- /** @type {?} */
- const el = (/** @type {?} */ (doc.createElement('SCRIPT')));
- el.setAttribute(attrName, attrValue);
- return el;
- }
- /**
- * @param {?} css
- * @param {?=} doc
- * @return {?}
- */
- createStyleElement(css, doc) {
- doc = doc || this.getDefaultDocument();
- /** @type {?} */
- const style = (/** @type {?} */ (doc.createElement('style')));
- this.appendChild(style, this.createTextNode(css, doc));
- return style;
- }
- /**
- * @param {?} el
- * @return {?}
- */
- createShadowRoot(el) { return ((/** @type {?} */ (el))).createShadowRoot(); }
- /**
- * @param {?} el
- * @return {?}
- */
- getShadowRoot(el) { return ((/** @type {?} */ (el))).shadowRoot; }
- /**
- * @param {?} el
- * @return {?}
- */
- getHost(el) { return ((/** @type {?} */ (el))).host; }
- /**
- * @param {?} node
- * @return {?}
- */
- clone(node) { return node.cloneNode(true); }
- /**
- * @param {?} element
- * @param {?} name
- * @return {?}
- */
- getElementsByClassName(element, name) {
- return element.getElementsByClassName(name);
- }
- /**
- * @param {?} element
- * @param {?} name
- * @return {?}
- */
- getElementsByTagName(element, name) {
- return element.getElementsByTagName(name);
- }
- /**
- * @param {?} element
- * @return {?}
- */
- classList(element) { return Array.prototype.slice.call(element.classList, 0); }
- /**
- * @param {?} element
- * @param {?} className
- * @return {?}
- */
- addClass(element, className) { element.classList.add(className); }
- /**
- * @param {?} element
- * @param {?} className
- * @return {?}
- */
- removeClass(element, className) { element.classList.remove(className); }
- /**
- * @param {?} element
- * @param {?} className
- * @return {?}
- */
- hasClass(element, className) {
- return element.classList.contains(className);
- }
- /**
- * @param {?} element
- * @param {?} styleName
- * @param {?} styleValue
- * @return {?}
- */
- setStyle(element, styleName, styleValue) {
- element.style[styleName] = styleValue;
- }
- /**
- * @param {?} element
- * @param {?} stylename
- * @return {?}
- */
- removeStyle(element, stylename) {
- // IE requires '' instead of null
- // see https://github.com/angular/angular/issues/7916
- element.style[stylename] = '';
- }
- /**
- * @param {?} element
- * @param {?} stylename
- * @return {?}
- */
- getStyle(element, stylename) { return element.style[stylename]; }
- /**
- * @param {?} element
- * @param {?} styleName
- * @param {?=} styleValue
- * @return {?}
- */
- hasStyle(element, styleName, styleValue) {
- /** @type {?} */
- const value = this.getStyle(element, styleName) || '';
- return styleValue ? value == styleValue : value.length > 0;
- }
- /**
- * @param {?} element
- * @return {?}
- */
- tagName(element) { return element.tagName; }
- /**
- * @param {?} element
- * @return {?}
- */
- attributeMap(element) {
- /** @type {?} */
- const res = new Map();
- /** @type {?} */
- const elAttrs = element.attributes;
- for (let i = 0; i < elAttrs.length; i++) {
- /** @type {?} */
- const attrib = elAttrs.item(i);
- res.set(attrib.name, attrib.value);
- }
- return res;
- }
- /**
- * @param {?} element
- * @param {?} attribute
- * @return {?}
- */
- hasAttribute(element, attribute) {
- return element.hasAttribute(attribute);
- }
- /**
- * @param {?} element
- * @param {?} ns
- * @param {?} attribute
- * @return {?}
- */
- hasAttributeNS(element, ns, attribute) {
- return element.hasAttributeNS(ns, attribute);
- }
- /**
- * @param {?} element
- * @param {?} attribute
- * @return {?}
- */
- getAttribute(element, attribute) {
- return element.getAttribute(attribute);
- }
- /**
- * @param {?} element
- * @param {?} ns
- * @param {?} name
- * @return {?}
- */
- getAttributeNS(element, ns, name) {
- return element.getAttributeNS(ns, name);
- }
- /**
- * @param {?} element
- * @param {?} name
- * @param {?} value
- * @return {?}
- */
- setAttribute(element, name, value) { element.setAttribute(name, value); }
- /**
- * @param {?} element
- * @param {?} ns
- * @param {?} name
- * @param {?} value
- * @return {?}
- */
- setAttributeNS(element, ns, name, value) {
- element.setAttributeNS(ns, name, value);
- }
- /**
- * @param {?} element
- * @param {?} attribute
- * @return {?}
- */
- removeAttribute(element, attribute) { element.removeAttribute(attribute); }
- /**
- * @param {?} element
- * @param {?} ns
- * @param {?} name
- * @return {?}
- */
- removeAttributeNS(element, ns, name) {
- element.removeAttributeNS(ns, name);
- }
- /**
- * @param {?} el
- * @return {?}
- */
- templateAwareRoot(el) { return this.isTemplateElement(el) ? this.content(el) : el; }
- /**
- * @return {?}
- */
- createHtmlDocument() {
- return document.implementation.createHTMLDocument('fakeTitle');
- }
- /**
- * @return {?}
- */
- getDefaultDocument() { return document; }
- /**
- * @param {?} el
- * @return {?}
- */
- getBoundingClientRect(el) {
- try {
- return el.getBoundingClientRect();
- }
- catch (_a) {
- return { top: 0, bottom: 0, left: 0, right: 0, width: 0, height: 0 };
- }
- }
- /**
- * @param {?} doc
- * @return {?}
- */
- getTitle(doc) { return doc.title; }
- /**
- * @param {?} doc
- * @param {?} newTitle
- * @return {?}
- */
- setTitle(doc, newTitle) { doc.title = newTitle || ''; }
- /**
- * @param {?} n
- * @param {?} selector
- * @return {?}
- */
- elementMatches(n, selector) {
- if (this.isElementNode(n)) {
- return n.matches && n.matches(selector) ||
- n.msMatchesSelector && n.msMatchesSelector(selector) ||
- n.webkitMatchesSelector && n.webkitMatchesSelector(selector);
- }
- return false;
- }
- /**
- * @param {?} el
- * @return {?}
- */
- isTemplateElement(el) {
- return this.isElementNode(el) && el.nodeName === 'TEMPLATE';
- }
- /**
- * @param {?} node
- * @return {?}
- */
- isTextNode(node) { return node.nodeType === Node.TEXT_NODE; }
- /**
- * @param {?} node
- * @return {?}
- */
- isCommentNode(node) { return node.nodeType === Node.COMMENT_NODE; }
- /**
- * @param {?} node
- * @return {?}
- */
- isElementNode(node) { return node.nodeType === Node.ELEMENT_NODE; }
- /**
- * @param {?} node
- * @return {?}
- */
- hasShadowRoot(node) {
- return node.shadowRoot != null && node instanceof HTMLElement;
- }
- /**
- * @param {?} node
- * @return {?}
- */
- isShadowRoot(node) { return node instanceof DocumentFragment; }
- /**
- * @param {?} node
- * @return {?}
- */
- importIntoDoc(node) { return document.importNode(this.templateAwareRoot(node), true); }
- /**
- * @param {?} node
- * @return {?}
- */
- adoptNode(node) { return document.adoptNode(node); }
- /**
- * @param {?} el
- * @return {?}
- */
- getHref(el) { return (/** @type {?} */ (el.getAttribute('href'))); }
- /**
- * @param {?} event
- * @return {?}
- */
- getEventKey(event) {
- /** @type {?} */
- let key = event.key;
- if (key == null) {
- key = event.keyIdentifier;
- // keyIdentifier is defined in the old draft of DOM Level 3 Events implemented by Chrome and
- // Safari cf
- // http://www.w3.org/TR/2007/WD-DOM-Level-3-Events-20071221/events.html#Events-KeyboardEvents-Interfaces
- if (key == null) {
- return 'Unidentified';
- }
- if (key.startsWith('U+')) {
- key = String.fromCharCode(parseInt(key.substring(2), 16));
- if (event.location === DOM_KEY_LOCATION_NUMPAD && _chromeNumKeyPadMap.hasOwnProperty(key)) {
- // There is a bug in Chrome for numeric keypad keys:
- // https://code.google.com/p/chromium/issues/detail?id=155654
- // 1, 2, 3 ... are reported as A, B, C ...
- key = ((/** @type {?} */ (_chromeNumKeyPadMap)))[key];
- }
- }
- }
- return _keyMap[key] || key;
- }
- /**
- * @param {?} doc
- * @param {?} target
- * @return {?}
- */
- getGlobalEventTarget(doc, target) {
- if (target === 'window') {
- return window;
- }
- if (target === 'document') {
- return doc;
- }
- if (target === 'body') {
- return doc.body;
- }
- return null;
- }
- /**
- * @return {?}
- */
- getHistory() { return window.history; }
- /**
- * @return {?}
- */
- getLocation() { return window.location; }
- /**
- * @param {?} doc
- * @return {?}
- */
- getBaseHref(doc) {
- /** @type {?} */
- const href = getBaseElementHref();
- return href == null ? null : relativePath(href);
- }
- /**
- * @return {?}
- */
- resetBaseElement() { baseElement = null; }
- /**
- * @return {?}
- */
- getUserAgent() { return window.navigator.userAgent; }
- /**
- * @param {?} element
- * @param {?} name
- * @param {?} value
- * @return {?}
- */
- setData(element, name, value) {
- this.setAttribute(element, 'data-' + name, value);
- }
- /**
- * @param {?} element
- * @param {?} name
- * @return {?}
- */
- getData(element, name) {
- return this.getAttribute(element, 'data-' + name);
- }
- /**
- * @param {?} element
- * @return {?}
- */
- getComputedStyle(element) { return getComputedStyle(element); }
- // TODO(tbosch): move this into a separate environment class once we have it
- /**
- * @return {?}
- */
- supportsWebAnimation() {
- return typeof ((/** @type {?} */ (Element))).prototype['animate'] === 'function';
- }
- /**
- * @return {?}
- */
- performanceNow() {
- // performance.now() is not available in all browsers, see
- // http://caniuse.com/#search=performance.now
- return window.performance && window.performance.now ? window.performance.now() :
- new Date().getTime();
- }
- /**
- * @return {?}
- */
- supportsCookies() { return true; }
- /**
- * @param {?} name
- * @return {?}
- */
- getCookie(name) { return ɵparseCookieValue(document.cookie, name); }
- /**
- * @param {?} name
- * @param {?} value
- * @return {?}
- */
- setCookie(name, value) {
- // document.cookie is magical, assigning into it assigns/overrides one cookie value, but does
- // not clear other cookies.
- document.cookie = encodeURIComponent(name) + '=' + encodeURIComponent(value);
- }
- }
- /** @type {?} */
- let baseElement = null;
- /**
- * @return {?}
- */
- function getBaseElementHref() {
- if (!baseElement) {
- baseElement = (/** @type {?} */ (document.querySelector('base')));
- if (!baseElement) {
- return null;
- }
- }
- return baseElement.getAttribute('href');
- }
- // based on urlUtils.js in AngularJS 1
- /** @type {?} */
- let urlParsingNode;
- /**
- * @param {?} url
- * @return {?}
- */
- function relativePath(url) {
- if (!urlParsingNode) {
- urlParsingNode = document.createElement('a');
- }
- urlParsingNode.setAttribute('href', url);
- return (urlParsingNode.pathname.charAt(0) === '/') ? urlParsingNode.pathname :
- '/' + urlParsingNode.pathname;
- }
- /**
- * @fileoverview added by tsickle
- * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
- */
- /**
- * @license
- * Copyright Google Inc. All Rights Reserved.
- *
- * Use of this source code is governed by an MIT-style license that can be
- * found in the LICENSE file at https://angular.io/license
- */
- /**
- * @return {?}
- */
- function supportsState() {
- return !!window.history.pushState;
- }
- /**
- * @fileoverview added by tsickle
- * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
- */
- /**
- * `PlatformLocation` encapsulates all of the direct calls to platform APIs.
- * This class should not be used directly by an application developer. Instead, use
- * {\@link Location}.
- */
- class BrowserPlatformLocation extends PlatformLocation {
- /**
- * @param {?} _doc
- */
- constructor(_doc) {
- super();
- this._doc = _doc;
- this._init();
- }
- // This is moved to its own method so that `MockPlatformLocationStrategy` can overwrite it
- /**
- * \@internal
- * @return {?}
- */
- _init() {
- ((/** @type {?} */ (this))).location = getDOM().getLocation();
- this._history = getDOM().getHistory();
- }
- /**
- * @return {?}
- */
- getBaseHrefFromDOM() { return (/** @type {?} */ (getDOM().getBaseHref(this._doc))); }
- /**
- * @param {?} fn
- * @return {?}
- */
- onPopState(fn) {
- getDOM().getGlobalEventTarget(this._doc, 'window').addEventListener('popstate', fn, false);
- }
- /**
- * @param {?} fn
- * @return {?}
- */
- onHashChange(fn) {
- getDOM().getGlobalEventTarget(this._doc, 'window').addEventListener('hashchange', fn, false);
- }
- /**
- * @return {?}
- */
- get href() { return this.location.href; }
- /**
- * @return {?}
- */
- get protocol() { return this.location.protocol; }
- /**
- * @return {?}
- */
- get hostname() { return this.location.hostname; }
- /**
- * @return {?}
- */
- get port() { return this.location.port; }
- /**
- * @return {?}
- */
- get pathname() { return this.location.pathname; }
- /**
- * @return {?}
- */
- get search() { return this.location.search; }
- /**
- * @return {?}
- */
- get hash() { return this.location.hash; }
- /**
- * @param {?} newPath
- * @return {?}
- */
- set pathname(newPath) { this.location.pathname = newPath; }
- /**
- * @param {?} state
- * @param {?} title
- * @param {?} url
- * @return {?}
- */
- pushState(state, title, url) {
- if (supportsState()) {
- this._history.pushState(state, title, url);
- }
- else {
- this.location.hash = url;
- }
- }
- /**
- * @param {?} state
- * @param {?} title
- * @param {?} url
- * @return {?}
- */
- replaceState(state, title, url) {
- if (supportsState()) {
- this._history.replaceState(state, title, url);
- }
- else {
- this.location.hash = url;
- }
- }
- /**
- * @return {?}
- */
- forward() { this._history.forward(); }
- /**
- * @return {?}
- */
- back() { this._history.back(); }
- /**
- * @return {?}
- */
- getState() { return this._history.state; }
- }
- BrowserPlatformLocation.decorators = [
- { type: Injectable }
- ];
- /** @nocollapse */
- BrowserPlatformLocation.ctorParameters = () => [
- { type: undefined, decorators: [{ type: Inject, args: [DOCUMENT,] }] }
- ];
- /**
- * @fileoverview added by tsickle
- * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
- */
- /**
- * An id that identifies a particular application being bootstrapped, that should
- * match across the client/server boundary.
- * @type {?}
- */
- const TRANSITION_ID = new InjectionToken('TRANSITION_ID');
- /**
- * @param {?} transitionId
- * @param {?} document
- * @param {?} injector
- * @return {?}
- */
- function appInitializerFactory(transitionId, document, injector) {
- return (/**
- * @return {?}
- */
- () => {
- // Wait for all application initializers to be completed before removing the styles set by
- // the server.
- injector.get(ApplicationInitStatus).donePromise.then((/**
- * @return {?}
- */
- () => {
- /** @type {?} */
- const dom = getDOM();
- /** @type {?} */
- const styles = Array.prototype.slice.apply(dom.querySelectorAll(document, `style[ng-transition]`));
- styles.filter((/**
- * @param {?} el
- * @return {?}
- */
- el => dom.getAttribute(el, 'ng-transition') === transitionId))
- .forEach((/**
- * @param {?} el
- * @return {?}
- */
- el => dom.remove(el)));
- }));
- });
- }
- /** @type {?} */
- const SERVER_TRANSITION_PROVIDERS = [
- {
- provide: APP_INITIALIZER,
- useFactory: appInitializerFactory,
- deps: [TRANSITION_ID, DOCUMENT, Injector],
- multi: true
- },
- ];
- /**
- * @fileoverview added by tsickle
- * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
- */
- class BrowserGetTestability {
- /**
- * @return {?}
- */
- static init() { setTestabilityGetter(new BrowserGetTestability()); }
- /**
- * @param {?} registry
- * @return {?}
- */
- addToWindow(registry) {
- ɵglobal['getAngularTestability'] = (/**
- * @param {?} elem
- * @param {?=} findInAncestors
- * @return {?}
- */
- (elem, findInAncestors = true) => {
- /** @type {?} */
- const testability = registry.findTestabilityInTree(elem, findInAncestors);
- if (testability == null) {
- throw new Error('Could not find testability for element.');
- }
- return testability;
- });
- ɵglobal['getAllAngularTestabilities'] = (/**
- * @return {?}
- */
- () => registry.getAllTestabilities());
- ɵglobal['getAllAngularRootElements'] = (/**
- * @return {?}
- */
- () => registry.getAllRootElements());
- /** @type {?} */
- const whenAllStable = (/**
- * @param {?} callback
- * @return {?}
- */
- (callback /** TODO #9100 */) => {
- /** @type {?} */
- const testabilities = ɵglobal['getAllAngularTestabilities']();
- /** @type {?} */
- let count = testabilities.length;
- /** @type {?} */
- let didWork = false;
- /** @type {?} */
- const decrement = (/**
- * @param {?} didWork_
- * @return {?}
- */
- function (didWork_ /** TODO #9100 */) {
- didWork = didWork || didWork_;
- count--;
- if (count == 0) {
- callback(didWork);
- }
- });
- testabilities.forEach((/**
- * @param {?} testability
- * @return {?}
- */
- function (testability /** TODO #9100 */) {
- testability.whenStable(decrement);
- }));
- });
- if (!ɵglobal['frameworkStabilizers']) {
- ɵglobal['frameworkStabilizers'] = [];
- }
- ɵglobal['frameworkStabilizers'].push(whenAllStable);
- }
- /**
- * @param {?} registry
- * @param {?} elem
- * @param {?} findInAncestors
- * @return {?}
- */
- findTestabilityInTree(registry, elem, findInAncestors) {
- if (elem == null) {
- return null;
- }
- /** @type {?} */
- const t = registry.getTestability(elem);
- if (t != null) {
- return t;
- }
- else if (!findInAncestors) {
- return null;
- }
- if (getDOM().isShadowRoot(elem)) {
- return this.findTestabilityInTree(registry, getDOM().getHost(elem), true);
- }
- return this.findTestabilityInTree(registry, getDOM().parentElement(elem), true);
- }
- }
- /**
- * @fileoverview added by tsickle
- * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
- */
- /**
- * Exports the value under a given `name` in the global property `ng`. For example `ng.probe` if
- * `name` is `'probe'`.
- * @param {?} name Name under which it will be exported. Keep in mind this will be a property of the
- * global `ng` object.
- * @param {?} value The value to export.
- * @return {?}
- */
- function exportNgVar(name, value) {
- if (typeof COMPILED === 'undefined' || !COMPILED) {
- // Note: we can't export `ng` when using closure enhanced optimization as:
- // - closure declares globals itself for minified names, which sometimes clobber our `ng` global
- // - we can't declare a closure extern as the namespace `ng` is already used within Google
- // for typings for angularJS (via `goog.provide('ng....')`).
- /** @type {?} */
- const ng = ɵglobal['ng'] = ((/** @type {?} */ (ɵglobal['ng']))) || {};
- ng[name] = value;
- }
- }
- /**
- * @fileoverview added by tsickle
- * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
- */
- const ɵ0$1 = /**
- * @return {?}
- */
- () => ({
- 'ApplicationRef': ApplicationRef,
- 'NgZone': NgZone,
- });
- /** @type {?} */
- const CORE_TOKENS = ((ɵ0$1))();
- /** @type {?} */
- const INSPECT_GLOBAL_NAME = 'probe';
- /** @type {?} */
- const CORE_TOKENS_GLOBAL_NAME = 'coreTokens';
- /**
- * Returns a {\@link DebugElement} for the given native DOM element, or
- * null if the given native element does not have an Angular view associated
- * with it.
- * @param {?} element
- * @return {?}
- */
- function inspectNativeElement(element) {
- return getDebugNode(element);
- }
- /**
- * @param {?} coreTokens
- * @return {?}
- */
- function _createNgProbe(coreTokens) {
- exportNgVar(INSPECT_GLOBAL_NAME, inspectNativeElement);
- exportNgVar(CORE_TOKENS_GLOBAL_NAME, Object.assign({}, CORE_TOKENS, _ngProbeTokensToMap(coreTokens || [])));
- return (/**
- * @return {?}
- */
- () => inspectNativeElement);
- }
- /**
- * @param {?} tokens
- * @return {?}
- */
- function _ngProbeTokensToMap(tokens) {
- return tokens.reduce((/**
- * @param {?} prev
- * @param {?} t
- * @return {?}
- */
- (prev, t) => (prev[t.name] = t.token, prev)), {});
- }
- /**
- * In Ivy, we don't support NgProbe because we have our own set of testing utilities
- * with more robust functionality.
- *
- * We shouldn't bring in NgProbe because it prevents DebugNode and friends from
- * tree-shaking properly.
- * @type {?}
- */
- const ELEMENT_PROBE_PROVIDERS__POST_R3__ = [];
- /**
- * Providers which support debugging Angular applications (e.g. via `ng.probe`).
- * @type {?}
- */
- const ELEMENT_PROBE_PROVIDERS__PRE_R3__ = [
- {
- provide: APP_INITIALIZER,
- useFactory: _createNgProbe,
- deps: [
- [NgProbeToken, new Optional()],
- ],
- multi: true,
- },
- ];
- /** @type {?} */
- const ELEMENT_PROBE_PROVIDERS = ELEMENT_PROBE_PROVIDERS__PRE_R3__;
- /**
- * @fileoverview added by tsickle
- * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
- */
- /**
- * The injection token for the event-manager plug-in service.
- *
- * \@publicApi
- * @type {?}
- */
- const EVENT_MANAGER_PLUGINS = new InjectionToken('EventManagerPlugins');
- /**
- * An injectable service that provides event management for Angular
- * through a browser plug-in.
- *
- * \@publicApi
- */
- class EventManager {
- /**
- * Initializes an instance of the event-manager service.
- * @param {?} plugins
- * @param {?} _zone
- */
- constructor(plugins, _zone) {
- this._zone = _zone;
- this._eventNameToPlugin = new Map();
- plugins.forEach((/**
- * @template THIS
- * @this {THIS}
- * @param {?} p
- * @return {THIS}
- */
- p => p.manager = this));
- this._plugins = plugins.slice().reverse();
- }
- /**
- * Registers a handler for a specific element and event.
- *
- * @param {?} element The HTML element to receive event notifications.
- * @param {?} eventName The name of the event to listen for.
- * @param {?} handler A function to call when the notification occurs. Receives the
- * event object as an argument.
- * @return {?} A callback function that can be used to remove the handler.
- */
- addEventListener(element, eventName, handler) {
- /** @type {?} */
- const plugin = this._findPluginFor(eventName);
- return plugin.addEventListener(element, eventName, handler);
- }
- /**
- * Registers a global handler for an event in a target view.
- *
- * @param {?} target A target for global event notifications. One of "window", "document", or "body".
- * @param {?} eventName The name of the event to listen for.
- * @param {?} handler A function to call when the notification occurs. Receives the
- * event object as an argument.
- * @return {?} A callback function that can be used to remove the handler.
- */
- addGlobalEventListener(target, eventName, handler) {
- /** @type {?} */
- const plugin = this._findPluginFor(eventName);
- return plugin.addGlobalEventListener(target, eventName, handler);
- }
- /**
- * Retrieves the compilation zone in which event listeners are registered.
- * @return {?}
- */
- getZone() { return this._zone; }
- /**
- * \@internal
- * @param {?} eventName
- * @return {?}
- */
- _findPluginFor(eventName) {
- /** @type {?} */
- const plugin = this._eventNameToPlugin.get(eventName);
- if (plugin) {
- return plugin;
- }
- /** @type {?} */
- const plugins = this._plugins;
- for (let i = 0; i < plugins.length; i++) {
- /** @type {?} */
- const plugin = plugins[i];
- if (plugin.supports(eventName)) {
- this._eventNameToPlugin.set(eventName, plugin);
- return plugin;
- }
- }
- throw new Error(`No event manager plugin found for event ${eventName}`);
- }
- }
- EventManager.decorators = [
- { type: Injectable }
- ];
- /** @nocollapse */
- EventManager.ctorParameters = () => [
- { type: Array, decorators: [{ type: Inject, args: [EVENT_MANAGER_PLUGINS,] }] },
- { type: NgZone }
- ];
- /**
- * @abstract
- */
- class EventManagerPlugin {
- /**
- * @param {?} _doc
- */
- constructor(_doc) {
- this._doc = _doc;
- }
- /**
- * @param {?} element
- * @param {?} eventName
- * @param {?} handler
- * @return {?}
- */
- addGlobalEventListener(element, eventName, handler) {
- /** @type {?} */
- const target = getDOM().getGlobalEventTarget(this._doc, element);
- if (!target) {
- throw new Error(`Unsupported event target ${target} for event ${eventName}`);
- }
- return this.addEventListener(target, eventName, handler);
- }
- }
- /**
- * @fileoverview added by tsickle
- * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
- */
- class SharedStylesHost {
- constructor() {
- /**
- * \@internal
- */
- this._stylesSet = new Set();
- }
- /**
- * @param {?} styles
- * @return {?}
- */
- addStyles(styles) {
- /** @type {?} */
- const additions = new Set();
- styles.forEach((/**
- * @param {?} style
- * @return {?}
- */
- style => {
- if (!this._stylesSet.has(style)) {
- this._stylesSet.add(style);
- additions.add(style);
- }
- }));
- this.onStylesAdded(additions);
- }
- /**
- * @param {?} additions
- * @return {?}
- */
- onStylesAdded(additions) { }
- /**
- * @return {?}
- */
- getAllStyles() { return Array.from(this._stylesSet); }
- }
- SharedStylesHost.decorators = [
- { type: Injectable }
- ];
- class DomSharedStylesHost extends SharedStylesHost {
- /**
- * @param {?} _doc
- */
- constructor(_doc) {
- super();
- this._doc = _doc;
- this._hostNodes = new Set();
- this._styleNodes = new Set();
- this._hostNodes.add(_doc.head);
- }
- /**
- * @private
- * @param {?} styles
- * @param {?} host
- * @return {?}
- */
- _addStylesToHost(styles, host) {
- styles.forEach((/**
- * @param {?} style
- * @return {?}
- */
- (style) => {
- /** @type {?} */
- const styleEl = this._doc.createElement('style');
- styleEl.textContent = style;
- this._styleNodes.add(host.appendChild(styleEl));
- }));
- }
- /**
- * @param {?} hostNode
- * @return {?}
- */
- addHost(hostNode) {
- this._addStylesToHost(this._stylesSet, hostNode);
- this._hostNodes.add(hostNode);
- }
- /**
- * @param {?} hostNode
- * @return {?}
- */
- removeHost(hostNode) { this._hostNodes.delete(hostNode); }
- /**
- * @param {?} additions
- * @return {?}
- */
- onStylesAdded(additions) {
- this._hostNodes.forEach((/**
- * @param {?} hostNode
- * @return {?}
- */
- hostNode => this._addStylesToHost(additions, hostNode)));
- }
- /**
- * @return {?}
- */
- ngOnDestroy() { this._styleNodes.forEach((/**
- * @param {?} styleNode
- * @return {?}
- */
- styleNode => getDOM().remove(styleNode))); }
- }
- DomSharedStylesHost.decorators = [
- { type: Injectable }
- ];
- /** @nocollapse */
- DomSharedStylesHost.ctorParameters = () => [
- { type: undefined, decorators: [{ type: Inject, args: [DOCUMENT,] }] }
- ];
- /**
- * @fileoverview added by tsickle
- * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
- */
- /** @type {?} */
- const NAMESPACE_URIS = {
- 'svg': 'http://www.w3.org/2000/svg',
- 'xhtml': 'http://www.w3.org/1999/xhtml',
- 'xlink': 'http://www.w3.org/1999/xlink',
- 'xml': 'http://www.w3.org/XML/1998/namespace',
- 'xmlns': 'http://www.w3.org/2000/xmlns/',
- };
- /** @type {?} */
- const COMPONENT_REGEX = /%COMP%/g;
- /** @type {?} */
- const COMPONENT_VARIABLE = '%COMP%';
- /** @type {?} */
- const HOST_ATTR = `_nghost-${COMPONENT_VARIABLE}`;
- /** @type {?} */
- const CONTENT_ATTR = `_ngcontent-${COMPONENT_VARIABLE}`;
- /**
- * @param {?} componentShortId
- * @return {?}
- */
- function shimContentAttribute(componentShortId) {
- return CONTENT_ATTR.replace(COMPONENT_REGEX, componentShortId);
- }
- /**
- * @param {?} componentShortId
- * @return {?}
- */
- function shimHostAttribute(componentShortId) {
- return HOST_ATTR.replace(COMPONENT_REGEX, componentShortId);
- }
- /**
- * @param {?} compId
- * @param {?} styles
- * @param {?} target
- * @return {?}
- */
- function flattenStyles(compId, styles, target) {
- for (let i = 0; i < styles.length; i++) {
- /** @type {?} */
- let style = styles[i];
- if (Array.isArray(style)) {
- flattenStyles(compId, style, target);
- }
- else {
- style = style.replace(COMPONENT_REGEX, compId);
- target.push(style);
- }
- }
- return target;
- }
- /**
- * @param {?} eventHandler
- * @return {?}
- */
- function decoratePreventDefault(eventHandler) {
- return (/**
- * @param {?} event
- * @return {?}
- */
- (event) => {
- /** @type {?} */
- const allowDefaultBehavior = eventHandler(event);
- if (allowDefaultBehavior === false) {
- // TODO(tbosch): move preventDefault into event plugins...
- event.preventDefault();
- event.returnValue = false;
- }
- });
- }
- class DomRendererFactory2 {
- /**
- * @param {?} eventManager
- * @param {?} sharedStylesHost
- * @param {?} appId
- */
- constructor(eventManager, sharedStylesHost, appId) {
- this.eventManager = eventManager;
- this.sharedStylesHost = sharedStylesHost;
- this.appId = appId;
- this.rendererByCompId = new Map();
- this.defaultRenderer = new DefaultDomRenderer2(eventManager);
- }
- /**
- * @param {?} element
- * @param {?} type
- * @return {?}
- */
- createRenderer(element, type) {
- if (!element || !type) {
- return this.defaultRenderer;
- }
- switch (type.encapsulation) {
- case ViewEncapsulation.Emulated: {
- /** @type {?} */
- let renderer = this.rendererByCompId.get(type.id);
- if (!renderer) {
- renderer = new EmulatedEncapsulationDomRenderer2(this.eventManager, this.sharedStylesHost, type, this.appId);
- this.rendererByCompId.set(type.id, renderer);
- }
- ((/** @type {?} */ (renderer))).applyToHost(element);
- return renderer;
- }
- case ViewEncapsulation.Native:
- case ViewEncapsulation.ShadowDom:
- return new ShadowDomRenderer(this.eventManager, this.sharedStylesHost, element, type);
- default: {
- if (!this.rendererByCompId.has(type.id)) {
- /** @type {?} */
- const styles = flattenStyles(type.id, type.styles, []);
- this.sharedStylesHost.addStyles(styles);
- this.rendererByCompId.set(type.id, this.defaultRenderer);
- }
- return this.defaultRenderer;
- }
- }
- }
- /**
- * @return {?}
- */
- begin() { }
- /**
- * @return {?}
- */
- end() { }
- }
- DomRendererFactory2.decorators = [
- { type: Injectable }
- ];
- /** @nocollapse */
- DomRendererFactory2.ctorParameters = () => [
- { type: EventManager },
- { type: DomSharedStylesHost },
- { type: String, decorators: [{ type: Inject, args: [APP_ID,] }] }
- ];
- class DefaultDomRenderer2 {
- /**
- * @param {?} eventManager
- */
- constructor(eventManager) {
- this.eventManager = eventManager;
- this.data = Object.create(null);
- }
- /**
- * @return {?}
- */
- destroy() { }
- /**
- * @param {?} name
- * @param {?=} namespace
- * @return {?}
- */
- createElement(name, namespace) {
- if (namespace) {
- // In cases where Ivy (not ViewEngine) is giving us the actual namespace, the look up by key
- // will result in undefined, so we just return the namespace here.
- return document.createElementNS(NAMESPACE_URIS[namespace] || namespace, name);
- }
- return document.createElement(name);
- }
- /**
- * @param {?} value
- * @return {?}
- */
- createComment(value) { return document.createComment(value); }
- /**
- * @param {?} value
- * @return {?}
- */
- createText(value) { return document.createTextNode(value); }
- /**
- * @param {?} parent
- * @param {?} newChild
- * @return {?}
- */
- appendChild(parent, newChild) { parent.appendChild(newChild); }
- /**
- * @param {?} parent
- * @param {?} newChild
- * @param {?} refChild
- * @return {?}
- */
- insertBefore(parent, newChild, refChild) {
- if (parent) {
- parent.insertBefore(newChild, refChild);
- }
- }
- /**
- * @param {?} parent
- * @param {?} oldChild
- * @return {?}
- */
- removeChild(parent, oldChild) {
- if (parent) {
- parent.removeChild(oldChild);
- }
- }
- /**
- * @param {?} selectorOrNode
- * @param {?=} preserveContent
- * @return {?}
- */
- selectRootElement(selectorOrNode, preserveContent) {
- /** @type {?} */
- let el = typeof selectorOrNode === 'string' ? document.querySelector(selectorOrNode) :
- selectorOrNode;
- if (!el) {
- throw new Error(`The selector "${selectorOrNode}" did not match any elements`);
- }
- if (!preserveContent) {
- el.textContent = '';
- }
- return el;
- }
- /**
- * @param {?} node
- * @return {?}
- */
- parentNode(node) { return node.parentNode; }
- /**
- * @param {?} node
- * @return {?}
- */
- nextSibling(node) { return node.nextSibling; }
- /**
- * @param {?} el
- * @param {?} name
- * @param {?} value
- * @param {?=} namespace
- * @return {?}
- */
- setAttribute(el, name, value, namespace) {
- if (namespace) {
- name = namespace + ':' + name;
- // TODO(benlesh): Ivy may cause issues here because it's passing around
- // full URIs for namespaces, therefore this lookup will fail.
- /** @type {?} */
- const namespaceUri = NAMESPACE_URIS[namespace];
- if (namespaceUri) {
- el.setAttributeNS(namespaceUri, name, value);
- }
- else {
- el.setAttribute(name, value);
- }
- }
- else {
- el.setAttribute(name, value);
- }
- }
- /**
- * @param {?} el
- * @param {?} name
- * @param {?=} namespace
- * @return {?}
- */
- removeAttribute(el, name, namespace) {
- if (namespace) {
- // TODO(benlesh): Ivy may cause issues here because it's passing around
- // full URIs for namespaces, therefore this lookup will fail.
- /** @type {?} */
- const namespaceUri = NAMESPACE_URIS[namespace];
- if (namespaceUri) {
- el.removeAttributeNS(namespaceUri, name);
- }
- else {
- // TODO(benlesh): Since ivy is passing around full URIs for namespaces
- // this could result in properties like `http://www.w3.org/2000/svg:cx="123"`,
- // which is wrong.
- el.removeAttribute(`${namespace}:${name}`);
- }
- }
- else {
- el.removeAttribute(name);
- }
- }
- /**
- * @param {?} el
- * @param {?} name
- * @return {?}
- */
- addClass(el, name) { el.classList.add(name); }
- /**
- * @param {?} el
- * @param {?} name
- * @return {?}
- */
- removeClass(el, name) { el.classList.remove(name); }
- /**
- * @param {?} el
- * @param {?} style
- * @param {?} value
- * @param {?} flags
- * @return {?}
- */
- setStyle(el, style, value, flags) {
- if (flags & RendererStyleFlags2.DashCase) {
- el.style.setProperty(style, value, !!(flags & RendererStyleFlags2.Important) ? 'important' : '');
- }
- else {
- el.style[style] = value;
- }
- }
- /**
- * @param {?} el
- * @param {?} style
- * @param {?} flags
- * @return {?}
- */
- removeStyle(el, style, flags) {
- if (flags & RendererStyleFlags2.DashCase) {
- el.style.removeProperty(style);
- }
- else {
- // IE requires '' instead of null
- // see https://github.com/angular/angular/issues/7916
- el.style[style] = '';
- }
- }
- /**
- * @param {?} el
- * @param {?} name
- * @param {?} value
- * @return {?}
- */
- setProperty(el, name, value) {
- checkNoSyntheticProp(name, 'property');
- el[name] = value;
- }
- /**
- * @param {?} node
- * @param {?} value
- * @return {?}
- */
- setValue(node, value) { node.nodeValue = value; }
- /**
- * @param {?} target
- * @param {?} event
- * @param {?} callback
- * @return {?}
- */
- listen(target, event, callback) {
- checkNoSyntheticProp(event, 'listener');
- if (typeof target === 'string') {
- return (/** @type {?} */ (this.eventManager.addGlobalEventListener(target, event, decoratePreventDefault(callback))));
- }
- return (/** @type {?} */ ((/** @type {?} */ (this.eventManager.addEventListener(target, event, decoratePreventDefault(callback))))));
- }
- }
- const ɵ0$2 = /**
- * @return {?}
- */
- () => '@'.charCodeAt(0);
- /** @type {?} */
- const AT_CHARCODE = ((ɵ0$2))();
- /**
- * @param {?} name
- * @param {?} nameKind
- * @return {?}
- */
- function checkNoSyntheticProp(name, nameKind) {
- if (name.charCodeAt(0) === AT_CHARCODE) {
- throw new Error(`Found the synthetic ${nameKind} ${name}. Please include either "BrowserAnimationsModule" or "NoopAnimationsModule" in your application.`);
- }
- }
- class EmulatedEncapsulationDomRenderer2 extends DefaultDomRenderer2 {
- /**
- * @param {?} eventManager
- * @param {?} sharedStylesHost
- * @param {?} component
- * @param {?} appId
- */
- constructor(eventManager, sharedStylesHost, component, appId) {
- super(eventManager);
- this.component = component;
- /** @type {?} */
- const styles = flattenStyles(appId + '-' + component.id, component.styles, []);
- sharedStylesHost.addStyles(styles);
- this.contentAttr = shimContentAttribute(appId + '-' + component.id);
- this.hostAttr = shimHostAttribute(appId + '-' + component.id);
- }
- /**
- * @param {?} element
- * @return {?}
- */
- applyToHost(element) { super.setAttribute(element, this.hostAttr, ''); }
- /**
- * @param {?} parent
- * @param {?} name
- * @return {?}
- */
- createElement(parent, name) {
- /** @type {?} */
- const el = super.createElement(parent, name);
- super.setAttribute(el, this.contentAttr, '');
- return el;
- }
- }
- class ShadowDomRenderer extends DefaultDomRenderer2 {
- /**
- * @param {?} eventManager
- * @param {?} sharedStylesHost
- * @param {?} hostEl
- * @param {?} component
- */
- constructor(eventManager, sharedStylesHost, hostEl, component) {
- super(eventManager);
- this.sharedStylesHost = sharedStylesHost;
- this.hostEl = hostEl;
- this.component = component;
- if (component.encapsulation === ViewEncapsulation.ShadowDom) {
- this.shadowRoot = ((/** @type {?} */ (hostEl))).attachShadow({ mode: 'open' });
- }
- else {
- this.shadowRoot = ((/** @type {?} */ (hostEl))).createShadowRoot();
- }
- this.sharedStylesHost.addHost(this.shadowRoot);
- /** @type {?} */
- const styles = flattenStyles(component.id, component.styles, []);
- for (let i = 0; i < styles.length; i++) {
- /** @type {?} */
- const styleEl = document.createElement('style');
- styleEl.textContent = styles[i];
- this.shadowRoot.appendChild(styleEl);
- }
- }
- /**
- * @private
- * @param {?} node
- * @return {?}
- */
- nodeOrShadowRoot(node) { return node === this.hostEl ? this.shadowRoot : node; }
- /**
- * @return {?}
- */
- destroy() { this.sharedStylesHost.removeHost(this.shadowRoot); }
- /**
- * @param {?} parent
- * @param {?} newChild
- * @return {?}
- */
- appendChild(parent, newChild) {
- return super.appendChild(this.nodeOrShadowRoot(parent), newChild);
- }
- /**
- * @param {?} parent
- * @param {?} newChild
- * @param {?} refChild
- * @return {?}
- */
- insertBefore(parent, newChild, refChild) {
- return super.insertBefore(this.nodeOrShadowRoot(parent), newChild, refChild);
- }
- /**
- * @param {?} parent
- * @param {?} oldChild
- * @return {?}
- */
- removeChild(parent, oldChild) {
- return super.removeChild(this.nodeOrShadowRoot(parent), oldChild);
- }
- /**
- * @param {?} node
- * @return {?}
- */
- parentNode(node) {
- return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(node)));
- }
- }
- /**
- * @fileoverview added by tsickle
- * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
- */
- const ɵ0$3 = /**
- * @return {?}
- */
- () => (typeof Zone !== 'undefined') && ((/** @type {?} */ (Zone)))['__symbol__'] ||
- (/**
- * @param {?} v
- * @return {?}
- */
- function (v) { return '__zone_symbol__' + v; });
- /**
- * Detect if Zone is present. If it is then use simple zone aware 'addEventListener'
- * since Angular can do much more
- * efficient bookkeeping than Zone can, because we have additional information. This speeds up
- * addEventListener by 3x.
- * @type {?}
- */
- const __symbol__ = ((ɵ0$3))();
- /** @type {?} */
- const ADD_EVENT_LISTENER = __symbol__('addEventListener');
- /** @type {?} */
- const REMOVE_EVENT_LISTENER = __symbol__('removeEventListener');
- /** @type {?} */
- const symbolNames = {};
- /** @type {?} */
- const FALSE = 'FALSE';
- /** @type {?} */
- const ANGULAR = 'ANGULAR';
- /** @type {?} */
- const NATIVE_ADD_LISTENER = 'addEventListener';
- /** @type {?} */
- const NATIVE_REMOVE_LISTENER = 'removeEventListener';
- // use the same symbol string which is used in zone.js
- /** @type {?} */
- const stopSymbol = '__zone_symbol__propagationStopped';
- /** @type {?} */
- const stopMethodSymbol = '__zone_symbol__stopImmediatePropagation';
- const ɵ1 = /**
- * @return {?}
- */
- () => {
- /** @type {?} */
- const blackListedEvents = (typeof Zone !== 'undefined') && ((/** @type {?} */ (Zone)))[__symbol__('BLACK_LISTED_EVENTS')];
- if (blackListedEvents) {
- /** @type {?} */
- const res = {};
- blackListedEvents.forEach((/**
- * @param {?} eventName
- * @return {?}
- */
- eventName => { res[eventName] = eventName; }));
- return res;
- }
- return undefined;
- };
- /** @type {?} */
- const blackListedMap = ((ɵ1))();
- /** @type {?} */
- const isBlackListedEvent = (/**
- * @param {?} eventName
- * @return {?}
- */
- function (eventName) {
- if (!blackListedMap) {
- return false;
- }
- return blackListedMap.hasOwnProperty(eventName);
- });
- // a global listener to handle all dom event,
- // so we do not need to create a closure every time
- /** @type {?} */
- const globalListener = (/**
- * @param {?} event
- * @return {?}
- */
- function (event) {
- /** @type {?} */
- const symbolName = symbolNames[event.type];
- if (!symbolName) {
- return;
- }
- /** @type {?} */
- const taskDatas = this[symbolName];
- if (!taskDatas) {
- return;
- }
- /** @type {?} */
- const args = [event];
- if (taskDatas.length === 1) {
- // if taskDatas only have one element, just invoke it
- /** @type {?} */
- const taskData = taskDatas[0];
- if (taskData.zone !== Zone.current) {
- // only use Zone.run when Zone.current not equals to stored zone
- return taskData.zone.run(taskData.handler, this, args);
- }
- else {
- return taskData.handler.apply(this, args);
- }
- }
- else {
- // copy tasks as a snapshot to avoid event handlers remove
- // itself or others
- /** @type {?} */
- const copiedTasks = taskDatas.slice();
- for (let i = 0; i < copiedTasks.length; i++) {
- // if other listener call event.stopImmediatePropagation
- // just break
- if (((/** @type {?} */ (event)))[stopSymbol] === true) {
- break;
- }
- /** @type {?} */
- const taskData = copiedTasks[i];
- if (taskData.zone !== Zone.current) {
- // only use Zone.run when Zone.current not equals to stored zone
- taskData.zone.run(taskData.handler, this, args);
- }
- else {
- taskData.handler.apply(this, args);
- }
- }
- }
- });
- class DomEventsPlugin extends EventManagerPlugin {
- /**
- * @param {?} doc
- * @param {?} ngZone
- * @param {?} platformId
- */
- constructor(doc, ngZone, platformId) {
- super(doc);
- this.ngZone = ngZone;
- if (!platformId || !isPlatformServer(platformId)) {
- this.patchEvent();
- }
- }
- /**
- * @private
- * @return {?}
- */
- patchEvent() {
- if (typeof Event === 'undefined' || !Event || !Event.prototype) {
- return;
- }
- if (((/** @type {?} */ (Event.prototype)))[stopMethodSymbol]) {
- // already patched by zone.js
- return;
- }
- /** @type {?} */
- const delegate = ((/** @type {?} */ (Event.prototype)))[stopMethodSymbol] =
- Event.prototype.stopImmediatePropagation;
- Event.prototype.stopImmediatePropagation = (/**
- * @return {?}
- */
- function () {
- if (this) {
- this[stopSymbol] = true;
- }
- // should call native delegate in case
- // in some environment part of the application
- // will not use the patched Event
- delegate && delegate.apply(this, arguments);
- });
- }
- // This plugin should come last in the list of plugins, because it accepts all
- // events.
- /**
- * @param {?} eventName
- * @return {?}
- */
- supports(eventName) { return true; }
- /**
- * @param {?} element
- * @param {?} eventName
- * @param {?} handler
- * @return {?}
- */
- addEventListener(element, eventName, handler) {
- /** @type {?} */
- const zoneJsLoaded = element[ADD_EVENT_LISTENER];
- /** @type {?} */
- let callback = (/** @type {?} */ (handler));
- // if zonejs is loaded and current zone is not ngZone
- // we keep Zone.current on target for later restoration.
- if (zoneJsLoaded && (!NgZone.isInAngularZone() || isBlackListedEvent(eventName))) {
- /** @type {?} */
- let symbolName = symbolNames[eventName];
- if (!symbolName) {
- symbolName = symbolNames[eventName] = __symbol__(ANGULAR + eventName + FALSE);
- }
- /** @type {?} */
- let taskDatas = ((/** @type {?} */ (element)))[symbolName];
- /** @type {?} */
- const globalListenerRegistered = taskDatas && taskDatas.length > 0;
- if (!taskDatas) {
- taskDatas = ((/** @type {?} */ (element)))[symbolName] = [];
- }
- /** @type {?} */
- const zone = isBlackListedEvent(eventName) ? Zone.root : Zone.current;
- if (taskDatas.length === 0) {
- taskDatas.push({ zone: zone, handler: callback });
- }
- else {
- /** @type {?} */
- let callbackRegistered = false;
- for (let i = 0; i < taskDatas.length; i++) {
- if (taskDatas[i].handler === callback) {
- callbackRegistered = true;
- break;
- }
- }
- if (!callbackRegistered) {
- taskDatas.push({ zone: zone, handler: callback });
- }
- }
- if (!globalListenerRegistered) {
- element[ADD_EVENT_LISTENER](eventName, globalListener, false);
- }
- }
- else {
- element[NATIVE_ADD_LISTENER](eventName, callback, false);
- }
- return (/**
- * @return {?}
- */
- () => this.removeEventListener(element, eventName, callback));
- }
- /**
- * @param {?} target
- * @param {?} eventName
- * @param {?} callback
- * @return {?}
- */
- removeEventListener(target, eventName, callback) {
- /** @type {?} */
- let underlyingRemove = target[REMOVE_EVENT_LISTENER];
- // zone.js not loaded, use native removeEventListener
- if (!underlyingRemove) {
- return target[NATIVE_REMOVE_LISTENER].apply(target, [eventName, callback, false]);
- }
- /** @type {?} */
- let symbolName = symbolNames[eventName];
- /** @type {?} */
- let taskDatas = symbolName && target[symbolName];
- if (!taskDatas) {
- // addEventListener not using patched version
- // just call native removeEventListener
- return target[NATIVE_REMOVE_LISTENER].apply(target, [eventName, callback, false]);
- }
- // fix issue 20532, should be able to remove
- // listener which was added inside of ngZone
- /** @type {?} */
- let found = false;
- for (let i = 0; i < taskDatas.length; i++) {
- // remove listener from taskDatas if the callback equals
- if (taskDatas[i].handler === callback) {
- found = true;
- taskDatas.splice(i, 1);
- break;
- }
- }
- if (found) {
- if (taskDatas.length === 0) {
- // all listeners are removed, we can remove the globalListener from target
- underlyingRemove.apply(target, [eventName, globalListener, false]);
- }
- }
- else {
- // not found in taskDatas, the callback may be added inside of ngZone
- // use native remove listener to remove the callback
- target[NATIVE_REMOVE_LISTENER].apply(target, [eventName, callback, false]);
- }
- }
- }
- DomEventsPlugin.decorators = [
- { type: Injectable }
- ];
- /** @nocollapse */
- DomEventsPlugin.ctorParameters = () => [
- { type: undefined, decorators: [{ type: Inject, args: [DOCUMENT,] }] },
- { type: NgZone },
- { type: undefined, decorators: [{ type: Optional }, { type: Inject, args: [PLATFORM_ID,] }] }
- ];
- /**
- * @fileoverview added by tsickle
- * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
- */
- /**
- * Supported HammerJS recognizer event names.
- * @type {?}
- */
- const EVENT_NAMES = {
- // pan
- 'pan': true,
- 'panstart': true,
- 'panmove': true,
- 'panend': true,
- 'pancancel': true,
- 'panleft': true,
- 'panright': true,
- 'panup': true,
- 'pandown': true,
- // pinch
- 'pinch': true,
- 'pinchstart': true,
- 'pinchmove': true,
- 'pinchend': true,
- 'pinchcancel': true,
- 'pinchin': true,
- 'pinchout': true,
- // press
- 'press': true,
- 'pressup': true,
- // rotate
- 'rotate': true,
- 'rotatestart': true,
- 'rotatemove': true,
- 'rotateend': true,
- 'rotatecancel': true,
- // swipe
- 'swipe': true,
- 'swipeleft': true,
- 'swiperight': true,
- 'swipeup': true,
- 'swipedown': true,
- // tap
- 'tap': true,
- };
- /**
- * DI token for providing [HammerJS](http://hammerjs.github.io/) support to Angular.
- * @see `HammerGestureConfig`
- *
- * \@publicApi
- * @type {?}
- */
- const HAMMER_GESTURE_CONFIG = new InjectionToken('HammerGestureConfig');
- /**
- * Injection token used to provide a {\@link HammerLoader} to Angular.
- *
- * \@publicApi
- * @type {?}
- */
- const HAMMER_LOADER = new InjectionToken('HammerLoader');
- /**
- * An injectable [HammerJS Manager](http://hammerjs.github.io/api/#hammer.manager)
- * for gesture recognition. Configures specific event recognition.
- * \@publicApi
- */
- class HammerGestureConfig {
- constructor() {
- /**
- * A set of supported event names for gestures to be used in Angular.
- * Angular supports all built-in recognizers, as listed in
- * [HammerJS documentation](http://hammerjs.github.io/).
- */
- this.events = [];
- /**
- * Maps gesture event names to a set of configuration options
- * that specify overrides to the default values for specific properties.
- *
- * The key is a supported event name to be configured,
- * and the options object contains a set of properties, with override values
- * to be applied to the named recognizer event.
- * For example, to disable recognition of the rotate event, specify
- * `{"rotate": {"enable": false}}`.
- *
- * Properties that are not present take the HammerJS default values.
- * For information about which properties are supported for which events,
- * and their allowed and default values, see
- * [HammerJS documentation](http://hammerjs.github.io/).
- *
- */
- this.overrides = {};
- }
- /**
- * Creates a [HammerJS Manager](http://hammerjs.github.io/api/#hammer.manager)
- * and attaches it to a given HTML element.
- * @param {?} element The element that will recognize gestures.
- * @return {?} A HammerJS event-manager object.
- */
- buildHammer(element) {
- /** @type {?} */
- const mc = new (/** @type {?} */ (Hammer))(element, this.options);
- mc.get('pinch').set({ enable: true });
- mc.get('rotate').set({ enable: true });
- for (const eventName in this.overrides) {
- mc.get(eventName).set(this.overrides[eventName]);
- }
- return mc;
- }
- }
- HammerGestureConfig.decorators = [
- { type: Injectable }
- ];
- class HammerGesturesPlugin extends EventManagerPlugin {
- /**
- * @param {?} doc
- * @param {?} _config
- * @param {?} console
- * @param {?=} loader
- */
- constructor(doc, _config, console, loader) {
- super(doc);
- this._config = _config;
- this.console = console;
- this.loader = loader;
- }
- /**
- * @param {?} eventName
- * @return {?}
- */
- supports(eventName) {
- if (!EVENT_NAMES.hasOwnProperty(eventName.toLowerCase()) && !this.isCustomEvent(eventName)) {
- return false;
- }
- if (!((/** @type {?} */ (window))).Hammer && !this.loader) {
- this.console.warn(`The "${eventName}" event cannot be bound because Hammer.JS is not ` +
- `loaded and no custom loader has been specified.`);
- return false;
- }
- return true;
- }
- /**
- * @param {?} element
- * @param {?} eventName
- * @param {?} handler
- * @return {?}
- */
- addEventListener(element, eventName, handler) {
- /** @type {?} */
- const zone = this.manager.getZone();
- eventName = eventName.toLowerCase();
- // If Hammer is not present but a loader is specified, we defer adding the event listener
- // until Hammer is loaded.
- if (!((/** @type {?} */ (window))).Hammer && this.loader) {
- // This `addEventListener` method returns a function to remove the added listener.
- // Until Hammer is loaded, the returned function needs to *cancel* the registration rather
- // than remove anything.
- /** @type {?} */
- let cancelRegistration = false;
- /** @type {?} */
- let deregister = (/**
- * @return {?}
- */
- () => { cancelRegistration = true; });
- this.loader()
- .then((/**
- * @return {?}
- */
- () => {
- // If Hammer isn't actually loaded when the custom loader resolves, give up.
- if (!((/** @type {?} */ (window))).Hammer) {
- this.console.warn(`The custom HAMMER_LOADER completed, but Hammer.JS is not present.`);
- deregister = (/**
- * @return {?}
- */
- () => { });
- return;
- }
- if (!cancelRegistration) {
- // Now that Hammer is loaded and the listener is being loaded for real,
- // the deregistration function changes from canceling registration to removal.
- deregister = this.addEventListener(element, eventName, handler);
- }
- }))
- .catch((/**
- * @return {?}
- */
- () => {
- this.console.warn(`The "${eventName}" event cannot be bound because the custom ` +
- `Hammer.JS loader failed.`);
- deregister = (/**
- * @return {?}
- */
- () => { });
- }));
- // Return a function that *executes* `deregister` (and not `deregister` itself) so that we
- // can change the behavior of `deregister` once the listener is added. Using a closure in
- // this way allows us to avoid any additional data structures to track listener removal.
- return (/**
- * @return {?}
- */
- () => { deregister(); });
- }
- return zone.runOutsideAngular((/**
- * @return {?}
- */
- () => {
- // Creating the manager bind events, must be done outside of angular
- /** @type {?} */
- const mc = this._config.buildHammer(element);
- /** @type {?} */
- const callback = (/**
- * @param {?} eventObj
- * @return {?}
- */
- function (eventObj) {
- zone.runGuarded((/**
- * @return {?}
- */
- function () { handler(eventObj); }));
- });
- mc.on(eventName, callback);
- return (/**
- * @return {?}
- */
- () => {
- mc.off(eventName, callback);
- // destroy mc to prevent memory leak
- if (typeof mc.destroy === 'function') {
- mc.destroy();
- }
- });
- }));
- }
- /**
- * @param {?} eventName
- * @return {?}
- */
- isCustomEvent(eventName) { return this._config.events.indexOf(eventName) > -1; }
- }
- HammerGesturesPlugin.decorators = [
- { type: Injectable }
- ];
- /** @nocollapse */
- HammerGesturesPlugin.ctorParameters = () => [
- { type: undefined, decorators: [{ type: Inject, args: [DOCUMENT,] }] },
- { type: HammerGestureConfig, decorators: [{ type: Inject, args: [HAMMER_GESTURE_CONFIG,] }] },
- { type: ɵConsole },
- { type: undefined, decorators: [{ type: Optional }, { type: Inject, args: [HAMMER_LOADER,] }] }
- ];
- /**
- * @fileoverview added by tsickle
- * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
- */
- /**
- * Defines supported modifiers for key events.
- * @type {?}
- */
- const MODIFIER_KEYS = ['alt', 'control', 'meta', 'shift'];
- const ɵ0$4 = /**
- * @param {?} event
- * @return {?}
- */
- (event) => event.altKey, ɵ1$1 = /**
- * @param {?} event
- * @return {?}
- */
- (event) => event.ctrlKey, ɵ2 = /**
- * @param {?} event
- * @return {?}
- */
- (event) => event.metaKey, ɵ3 = /**
- * @param {?} event
- * @return {?}
- */
- (event) => event.shiftKey;
- /**
- * Retrieves modifiers from key-event objects.
- * @type {?}
- */
- const MODIFIER_KEY_GETTERS = {
- 'alt': (ɵ0$4),
- 'control': (ɵ1$1),
- 'meta': (ɵ2),
- 'shift': (ɵ3)
- };
- /**
- * \@publicApi
- * A browser plug-in that provides support for handling of key events in Angular.
- */
- class KeyEventsPlugin extends EventManagerPlugin {
- /**
- * Initializes an instance of the browser plug-in.
- * @param {?} doc The document in which key events will be detected.
- */
- constructor(doc) { super(doc); }
- /**
- * Reports whether a named key event is supported.
- * @param {?} eventName The event name to query.
- * @return {?} True if the named key event is supported.
- */
- supports(eventName) { return KeyEventsPlugin.parseEventName(eventName) != null; }
- /**
- * Registers a handler for a specific element and key event.
- * @param {?} element The HTML element to receive event notifications.
- * @param {?} eventName The name of the key event to listen for.
- * @param {?} handler A function to call when the notification occurs. Receives the
- * event object as an argument.
- * @return {?} The key event that was registered.
- */
- addEventListener(element, eventName, handler) {
- /** @type {?} */
- const parsedEvent = (/** @type {?} */ (KeyEventsPlugin.parseEventName(eventName)));
- /** @type {?} */
- const outsideHandler = KeyEventsPlugin.eventCallback(parsedEvent['fullKey'], handler, this.manager.getZone());
- return this.manager.getZone().runOutsideAngular((/**
- * @return {?}
- */
- () => {
- return getDOM().onAndCancel(element, parsedEvent['domEventName'], outsideHandler);
- }));
- }
- /**
- * @param {?} eventName
- * @return {?}
- */
- static parseEventName(eventName) {
- /** @type {?} */
- const parts = eventName.toLowerCase().split('.');
- /** @type {?} */
- const domEventName = parts.shift();
- if ((parts.length === 0) || !(domEventName === 'keydown' || domEventName === 'keyup')) {
- return null;
- }
- /** @type {?} */
- const key = KeyEventsPlugin._normalizeKey((/** @type {?} */ (parts.pop())));
- /** @type {?} */
- let fullKey = '';
- MODIFIER_KEYS.forEach((/**
- * @param {?} modifierName
- * @return {?}
- */
- modifierName => {
- /** @type {?} */
- const index = parts.indexOf(modifierName);
- if (index > -1) {
- parts.splice(index, 1);
- fullKey += modifierName + '.';
- }
- }));
- fullKey += key;
- if (parts.length != 0 || key.length === 0) {
- // returning null instead of throwing to let another plugin process the event
- return null;
- }
- /** @type {?} */
- const result = {};
- result['domEventName'] = domEventName;
- result['fullKey'] = fullKey;
- return result;
- }
- /**
- * @param {?} event
- * @return {?}
- */
- static getEventFullKey(event) {
- /** @type {?} */
- let fullKey = '';
- /** @type {?} */
- let key = getDOM().getEventKey(event);
- key = key.toLowerCase();
- if (key === ' ') {
- key = 'space'; // for readability
- }
- else if (key === '.') {
- key = 'dot'; // because '.' is used as a separator in event names
- }
- MODIFIER_KEYS.forEach((/**
- * @param {?} modifierName
- * @return {?}
- */
- modifierName => {
- if (modifierName != key) {
- /** @type {?} */
- const modifierGetter = MODIFIER_KEY_GETTERS[modifierName];
- if (modifierGetter(event)) {
- fullKey += modifierName + '.';
- }
- }
- }));
- fullKey += key;
- return fullKey;
- }
- /**
- * Configures a handler callback for a key event.
- * @param {?} fullKey The event name that combines all simultaneous keystrokes.
- * @param {?} handler The function that responds to the key event.
- * @param {?} zone The zone in which the event occurred.
- * @return {?} A callback function.
- */
- static eventCallback(fullKey, handler, zone) {
- return (/**
- * @param {?} event
- * @return {?}
- */
- (event /** TODO #9100 */) => {
- if (KeyEventsPlugin.getEventFullKey(event) === fullKey) {
- zone.runGuarded((/**
- * @return {?}
- */
- () => handler(event)));
- }
- });
- }
- /**
- * \@internal
- * @param {?} keyName
- * @return {?}
- */
- static _normalizeKey(keyName) {
- // TODO: switch to a Map if the mapping grows too much
- switch (keyName) {
- case 'esc':
- return 'escape';
- default:
- return keyName;
- }
- }
- }
- KeyEventsPlugin.decorators = [
- { type: Injectable }
- ];
- /** @nocollapse */
- KeyEventsPlugin.ctorParameters = () => [
- { type: undefined, decorators: [{ type: Inject, args: [DOCUMENT,] }] }
- ];
- /**
- * @fileoverview added by tsickle
- * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
- */
- /**
- * DomSanitizer helps preventing Cross Site Scripting Security bugs (XSS) by sanitizing
- * values to be safe to use in the different DOM contexts.
- *
- * For example, when binding a URL in an `<a [href]="someValue">` hyperlink, `someValue` will be
- * sanitized so that an attacker cannot inject e.g. a `javascript:` URL that would execute code on
- * the website.
- *
- * In specific situations, it might be necessary to disable sanitization, for example if the
- * application genuinely needs to produce a `javascript:` style link with a dynamic value in it.
- * Users can bypass security by constructing a value with one of the `bypassSecurityTrust...`
- * methods, and then binding to that value from the template.
- *
- * These situations should be very rare, and extraordinary care must be taken to avoid creating a
- * Cross Site Scripting (XSS) security bug!
- *
- * When using `bypassSecurityTrust...`, make sure to call the method as early as possible and as
- * close as possible to the source of the value, to make it easy to verify no security bug is
- * created by its use.
- *
- * It is not required (and not recommended) to bypass security if the value is safe, e.g. a URL that
- * does not start with a suspicious protocol, or an HTML snippet that does not contain dangerous
- * code. The sanitizer leaves safe values intact.
- *
- * \@security Calling any of the `bypassSecurityTrust...` APIs disables Angular's built-in
- * sanitization for the value passed in. Carefully check and audit all values and code paths going
- * into this call. Make sure any user data is appropriately escaped for this security context.
- * For more detail, see the [Security Guide](http://g.co/ng/security).
- *
- * \@publicApi
- * @abstract
- */
- class DomSanitizer {
- }
- class DomSanitizerImpl extends DomSanitizer {
- /**
- * @param {?} _doc
- */
- constructor(_doc) {
- super();
- this._doc = _doc;
- }
- /**
- * @param {?} ctx
- * @param {?} value
- * @return {?}
- */
- sanitize(ctx, value) {
- if (value == null)
- return null;
- switch (ctx) {
- case SecurityContext.NONE:
- return (/** @type {?} */ (value));
- case SecurityContext.HTML:
- if (value instanceof SafeHtmlImpl)
- return value.changingThisBreaksApplicationSecurity;
- this.checkNotSafeValue(value, 'HTML');
- return ɵ_sanitizeHtml(this._doc, String(value));
- case SecurityContext.STYLE:
- if (value instanceof SafeStyleImpl)
- return value.changingThisBreaksApplicationSecurity;
- this.checkNotSafeValue(value, 'Style');
- return ɵ_sanitizeStyle((/** @type {?} */ (value)));
- case SecurityContext.SCRIPT:
- if (value instanceof SafeScriptImpl)
- return value.changingThisBreaksApplicationSecurity;
- this.checkNotSafeValue(value, 'Script');
- throw new Error('unsafe value used in a script context');
- case SecurityContext.URL:
- if (value instanceof SafeResourceUrlImpl || value instanceof SafeUrlImpl) {
- // Allow resource URLs in URL contexts, they are strictly more trusted.
- return value.changingThisBreaksApplicationSecurity;
- }
- this.checkNotSafeValue(value, 'URL');
- return ɵ_sanitizeUrl(String(value));
- case SecurityContext.RESOURCE_URL:
- if (value instanceof SafeResourceUrlImpl) {
- return value.changingThisBreaksApplicationSecurity;
- }
- this.checkNotSafeValue(value, 'ResourceURL');
- throw new Error('unsafe value used in a resource URL context (see http://g.co/ng/security#xss)');
- default:
- throw new Error(`Unexpected SecurityContext ${ctx} (see http://g.co/ng/security#xss)`);
- }
- }
- /**
- * @private
- * @param {?} value
- * @param {?} expectedType
- * @return {?}
- */
- checkNotSafeValue(value, expectedType) {
- if (value instanceof SafeValueImpl) {
- throw new Error(`Required a safe ${expectedType}, got a ${value.getTypeName()} ` +
- `(see http://g.co/ng/security#xss)`);
- }
- }
- /**
- * @param {?} value
- * @return {?}
- */
- bypassSecurityTrustHtml(value) { return new SafeHtmlImpl(value); }
- /**
- * @param {?} value
- * @return {?}
- */
- bypassSecurityTrustStyle(value) { return new SafeStyleImpl(value); }
- /**
- * @param {?} value
- * @return {?}
- */
- bypassSecurityTrustScript(value) { return new SafeScriptImpl(value); }
- /**
- * @param {?} value
- * @return {?}
- */
- bypassSecurityTrustUrl(value) { return new SafeUrlImpl(value); }
- /**
- * @param {?} value
- * @return {?}
- */
- bypassSecurityTrustResourceUrl(value) {
- return new SafeResourceUrlImpl(value);
- }
- }
- DomSanitizerImpl.decorators = [
- { type: Injectable }
- ];
- /** @nocollapse */
- DomSanitizerImpl.ctorParameters = () => [
- { type: undefined, decorators: [{ type: Inject, args: [DOCUMENT,] }] }
- ];
- /**
- * @abstract
- */
- class SafeValueImpl {
- /**
- * @param {?} changingThisBreaksApplicationSecurity
- */
- constructor(changingThisBreaksApplicationSecurity) {
- this.changingThisBreaksApplicationSecurity = changingThisBreaksApplicationSecurity;
- // empty
- }
- /**
- * @return {?}
- */
- toString() {
- return `SafeValue must use [property]=binding: ${this.changingThisBreaksApplicationSecurity}` +
- ` (see http://g.co/ng/security#xss)`;
- }
- }
- class SafeHtmlImpl extends SafeValueImpl {
- /**
- * @return {?}
- */
- getTypeName() { return 'HTML'; }
- }
- class SafeStyleImpl extends SafeValueImpl {
- /**
- * @return {?}
- */
- getTypeName() { return 'Style'; }
- }
- class SafeScriptImpl extends SafeValueImpl {
- /**
- * @return {?}
- */
- getTypeName() { return 'Script'; }
- }
- class SafeUrlImpl extends SafeValueImpl {
- /**
- * @return {?}
- */
- getTypeName() { return 'URL'; }
- }
- class SafeResourceUrlImpl extends SafeValueImpl {
- /**
- * @return {?}
- */
- getTypeName() { return 'ResourceURL'; }
- }
- /**
- * @fileoverview added by tsickle
- * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
- */
- const ɵ0$5 = ɵPLATFORM_BROWSER_ID;
- /** @type {?} */
- const INTERNAL_BROWSER_PLATFORM_PROVIDERS = [
- { provide: PLATFORM_ID, useValue: ɵ0$5 },
- { provide: PLATFORM_INITIALIZER, useValue: initDomAdapter, multi: true },
- { provide: PlatformLocation, useClass: BrowserPlatformLocation, deps: [DOCUMENT] },
- { provide: DOCUMENT, useFactory: _document, deps: [] },
- ];
- /**
- * \@security Replacing built-in sanitization providers exposes the application to XSS risks.
- * Attacker-controlled data introduced by an unsanitized provider could expose your
- * application to XSS risks. For more detail, see the [Security Guide](http://g.co/ng/security).
- * \@publicApi
- * @type {?}
- */
- const BROWSER_SANITIZATION_PROVIDERS = [
- { provide: Sanitizer, useExisting: DomSanitizer },
- { provide: DomSanitizer, useClass: DomSanitizerImpl, deps: [DOCUMENT] },
- ];
- /**
- * \@publicApi
- * @type {?}
- */
- const platformBrowser = createPlatformFactory(platformCore, 'browser', INTERNAL_BROWSER_PLATFORM_PROVIDERS);
- /**
- * @return {?}
- */
- function initDomAdapter() {
- BrowserDomAdapter.makeCurrent();
- BrowserGetTestability.init();
- }
- /**
- * @return {?}
- */
- function errorHandler() {
- return new ErrorHandler();
- }
- /**
- * @return {?}
- */
- function _document() {
- return document;
- }
- /** @type {?} */
- const BROWSER_MODULE_PROVIDERS = [
- BROWSER_SANITIZATION_PROVIDERS,
- { provide: ɵAPP_ROOT, useValue: true },
- { provide: ErrorHandler, useFactory: errorHandler, deps: [] },
- {
- provide: EVENT_MANAGER_PLUGINS,
- useClass: DomEventsPlugin,
- multi: true,
- deps: [DOCUMENT, NgZone, PLATFORM_ID]
- },
- { provide: EVENT_MANAGER_PLUGINS, useClass: KeyEventsPlugin, multi: true, deps: [DOCUMENT] },
- {
- provide: EVENT_MANAGER_PLUGINS,
- useClass: HammerGesturesPlugin,
- multi: true,
- deps: [DOCUMENT, HAMMER_GESTURE_CONFIG, ɵConsole, [new Optional(), HAMMER_LOADER]]
- },
- { provide: HAMMER_GESTURE_CONFIG, useClass: HammerGestureConfig, deps: [] },
- {
- provide: DomRendererFactory2,
- useClass: DomRendererFactory2,
- deps: [EventManager, DomSharedStylesHost, APP_ID]
- },
- { provide: RendererFactory2, useExisting: DomRendererFactory2 },
- { provide: SharedStylesHost, useExisting: DomSharedStylesHost },
- { provide: DomSharedStylesHost, useClass: DomSharedStylesHost, deps: [DOCUMENT] },
- { provide: Testability, useClass: Testability, deps: [NgZone] },
- { provide: EventManager, useClass: EventManager, deps: [EVENT_MANAGER_PLUGINS, NgZone] },
- ELEMENT_PROBE_PROVIDERS,
- ];
- /**
- * Exports required infrastructure for all Angular apps.
- * Included by default in all Angular apps created with the CLI
- * `new` command.
- * Re-exports `CommonModule` and `ApplicationModule`, making their
- * exports and providers available to all apps.
- *
- * \@publicApi
- */
- class BrowserModule {
- /**
- * @param {?} parentModule
- */
- constructor(parentModule) {
- if (parentModule) {
- throw new Error(`BrowserModule has already been loaded. If you need access to common directives such as NgIf and NgFor from a lazy loaded module, import CommonModule instead.`);
- }
- }
- /**
- * Configures a browser-based app to transition from a server-rendered app, if
- * one is present on the page.
- *
- * @param {?} params An object containing an identifier for the app to transition.
- * The ID must match between the client and server versions of the app.
- * @return {?} The reconfigured `BrowserModule` to import into the app's root `AppModule`.
- */
- static withServerTransition(params) {
- return {
- ngModule: BrowserModule,
- providers: [
- { provide: APP_ID, useValue: params.appId },
- { provide: TRANSITION_ID, useExisting: APP_ID },
- SERVER_TRANSITION_PROVIDERS,
- ],
- };
- }
- }
- BrowserModule.decorators = [
- { type: NgModule, args: [{ providers: BROWSER_MODULE_PROVIDERS, exports: [CommonModule, ApplicationModule] },] }
- ];
- /** @nocollapse */
- BrowserModule.ctorParameters = () => [
- { type: undefined, decorators: [{ type: Optional }, { type: SkipSelf }, { type: Inject, args: [BrowserModule,] }] }
- ];
- /**
- * @fileoverview added by tsickle
- * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
- */
- /**
- * Factory to create Meta service.
- * @return {?}
- */
- function createMeta() {
- return new Meta(ɵɵinject(DOCUMENT));
- }
- /**
- * A service that can be used to get and add meta tags.
- *
- * \@publicApi
- */
- class Meta {
- /**
- * @param {?} _doc
- */
- constructor(_doc) {
- this._doc = _doc;
- this._dom = getDOM();
- }
- /**
- * @param {?} tag
- * @param {?=} forceCreation
- * @return {?}
- */
- addTag(tag, forceCreation = false) {
- if (!tag)
- return null;
- return this._getOrCreateElement(tag, forceCreation);
- }
- /**
- * @param {?} tags
- * @param {?=} forceCreation
- * @return {?}
- */
- addTags(tags, forceCreation = false) {
- if (!tags)
- return [];
- return tags.reduce((/**
- * @param {?} result
- * @param {?} tag
- * @return {?}
- */
- (result, tag) => {
- if (tag) {
- result.push(this._getOrCreateElement(tag, forceCreation));
- }
- return result;
- }), []);
- }
- /**
- * @param {?} attrSelector
- * @return {?}
- */
- getTag(attrSelector) {
- if (!attrSelector)
- return null;
- return this._dom.querySelector(this._doc, `meta[${attrSelector}]`) || null;
- }
- /**
- * @param {?} attrSelector
- * @return {?}
- */
- getTags(attrSelector) {
- if (!attrSelector)
- return [];
- /** @type {?} */
- const list /*NodeList*/ = this._dom.querySelectorAll(this._doc, `meta[${attrSelector}]`);
- return list ? [].slice.call(list) : [];
- }
- /**
- * @param {?} tag
- * @param {?=} selector
- * @return {?}
- */
- updateTag(tag, selector) {
- if (!tag)
- return null;
- selector = selector || this._parseSelector(tag);
- /** @type {?} */
- const meta = (/** @type {?} */ (this.getTag(selector)));
- if (meta) {
- return this._setMetaElementAttributes(tag, meta);
- }
- return this._getOrCreateElement(tag, true);
- }
- /**
- * @param {?} attrSelector
- * @return {?}
- */
- removeTag(attrSelector) { this.removeTagElement((/** @type {?} */ (this.getTag(attrSelector)))); }
- /**
- * @param {?} meta
- * @return {?}
- */
- removeTagElement(meta) {
- if (meta) {
- this._dom.remove(meta);
- }
- }
- /**
- * @private
- * @param {?} meta
- * @param {?=} forceCreation
- * @return {?}
- */
- _getOrCreateElement(meta, forceCreation = false) {
- if (!forceCreation) {
- /** @type {?} */
- const selector = this._parseSelector(meta);
- /** @type {?} */
- const elem = (/** @type {?} */ (this.getTag(selector)));
- // It's allowed to have multiple elements with the same name so it's not enough to
- // just check that element with the same name already present on the page. We also need to
- // check if element has tag attributes
- if (elem && this._containsAttributes(meta, elem))
- return elem;
- }
- /** @type {?} */
- const element = (/** @type {?} */ (this._dom.createElement('meta')));
- this._setMetaElementAttributes(meta, element);
- /** @type {?} */
- const head = this._dom.getElementsByTagName(this._doc, 'head')[0];
- this._dom.appendChild(head, element);
- return element;
- }
- /**
- * @private
- * @param {?} tag
- * @param {?} el
- * @return {?}
- */
- _setMetaElementAttributes(tag, el) {
- Object.keys(tag).forEach((/**
- * @param {?} prop
- * @return {?}
- */
- (prop) => this._dom.setAttribute(el, prop, tag[prop])));
- return el;
- }
- /**
- * @private
- * @param {?} tag
- * @return {?}
- */
- _parseSelector(tag) {
- /** @type {?} */
- const attr = tag.name ? 'name' : 'property';
- return `${attr}="${tag[attr]}"`;
- }
- /**
- * @private
- * @param {?} tag
- * @param {?} elem
- * @return {?}
- */
- _containsAttributes(tag, elem) {
- return Object.keys(tag).every((/**
- * @param {?} key
- * @return {?}
- */
- (key) => this._dom.getAttribute(elem, key) === tag[key]));
- }
- }
- Meta.decorators = [
- { type: Injectable, args: [{ providedIn: 'root', useFactory: createMeta, deps: [] },] }
- ];
- /** @nocollapse */
- Meta.ctorParameters = () => [
- { type: undefined, decorators: [{ type: Inject, args: [DOCUMENT,] }] }
- ];
- /** @nocollapse */ Meta.ngInjectableDef = ɵɵdefineInjectable({ factory: createMeta, token: Meta, providedIn: "root" });
- /**
- * @fileoverview added by tsickle
- * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
- */
- /**
- * Factory to create Title service.
- * @return {?}
- */
- function createTitle() {
- return new Title(ɵɵinject(DOCUMENT));
- }
- /**
- * A service that can be used to get and set the title of a current HTML document.
- *
- * Since an Angular application can't be bootstrapped on the entire HTML document (`<html>` tag)
- * it is not possible to bind to the `text` property of the `HTMLTitleElement` elements
- * (representing the `<title>` tag). Instead, this service can be used to set and get the current
- * title value.
- *
- * \@publicApi
- */
- class Title {
- /**
- * @param {?} _doc
- */
- constructor(_doc) {
- this._doc = _doc;
- }
- /**
- * Get the title of the current HTML document.
- * @return {?}
- */
- getTitle() { return getDOM().getTitle(this._doc); }
- /**
- * Set the title of the current HTML document.
- * @param {?} newTitle
- * @return {?}
- */
- setTitle(newTitle) { getDOM().setTitle(this._doc, newTitle); }
- }
- Title.decorators = [
- { type: Injectable, args: [{ providedIn: 'root', useFactory: createTitle, deps: [] },] }
- ];
- /** @nocollapse */
- Title.ctorParameters = () => [
- { type: undefined, decorators: [{ type: Inject, args: [DOCUMENT,] }] }
- ];
- /** @nocollapse */ Title.ngInjectableDef = ɵɵdefineInjectable({ factory: createTitle, token: Title, providedIn: "root" });
- /**
- * @fileoverview added by tsickle
- * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
- */
- /**
- * @license
- * Copyright Google Inc. All Rights Reserved.
- *
- * Use of this source code is governed by an MIT-style license that can be
- * found in the LICENSE file at https://angular.io/license
- */
- /** @type {?} */
- const win = typeof window !== 'undefined' && window || (/** @type {?} */ ({}));
- /**
- * @fileoverview added by tsickle
- * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
- */
- class ChangeDetectionPerfRecord {
- /**
- * @param {?} msPerTick
- * @param {?} numTicks
- */
- constructor(msPerTick, numTicks) {
- this.msPerTick = msPerTick;
- this.numTicks = numTicks;
- }
- }
- /**
- * Entry point for all Angular profiling-related debug tools. This object
- * corresponds to the `ng.profiler` in the dev console.
- */
- class AngularProfiler {
- /**
- * @param {?} ref
- */
- constructor(ref) { this.appRef = ref.injector.get(ApplicationRef); }
- // tslint:disable:no-console
- /**
- * Exercises change detection in a loop and then prints the average amount of
- * time in milliseconds how long a single round of change detection takes for
- * the current state of the UI. It runs a minimum of 5 rounds for a minimum
- * of 500 milliseconds.
- *
- * Optionally, a user may pass a `config` parameter containing a map of
- * options. Supported options are:
- *
- * `record` (boolean) - causes the profiler to record a CPU profile while
- * it exercises the change detector. Example:
- *
- * ```
- * ng.profiler.timeChangeDetection({record: true})
- * ```
- * @param {?} config
- * @return {?}
- */
- timeChangeDetection(config) {
- /** @type {?} */
- const record = config && config['record'];
- /** @type {?} */
- const profileName = 'Change Detection';
- // Profiler is not available in Android browsers, nor in IE 9 without dev tools opened
- /** @type {?} */
- const isProfilerAvailable = win.console.profile != null;
- if (record && isProfilerAvailable) {
- win.console.profile(profileName);
- }
- /** @type {?} */
- const start = getDOM().performanceNow();
- /** @type {?} */
- let numTicks = 0;
- while (numTicks < 5 || (getDOM().performanceNow() - start) < 500) {
- this.appRef.tick();
- numTicks++;
- }
- /** @type {?} */
- const end = getDOM().performanceNow();
- if (record && isProfilerAvailable) {
- win.console.profileEnd(profileName);
- }
- /** @type {?} */
- const msPerTick = (end - start) / numTicks;
- win.console.log(`ran ${numTicks} change detection cycles`);
- win.console.log(`${msPerTick.toFixed(2)} ms per check`);
- return new ChangeDetectionPerfRecord(msPerTick, numTicks);
- }
- }
- /**
- * @fileoverview added by tsickle
- * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
- */
- /** @type {?} */
- const PROFILER_GLOBAL_NAME = 'profiler';
- /**
- * Enabled Angular debug tools that are accessible via your browser's
- * developer console.
- *
- * Usage:
- *
- * 1. Open developer console (e.g. in Chrome Ctrl + Shift + j)
- * 1. Type `ng.` (usually the console will show auto-complete suggestion)
- * 1. Try the change detection profiler `ng.profiler.timeChangeDetection()`
- * then hit Enter.
- *
- * \@publicApi
- * @template T
- * @param {?} ref
- * @return {?}
- */
- function enableDebugTools(ref) {
- exportNgVar(PROFILER_GLOBAL_NAME, new AngularProfiler(ref));
- return ref;
- }
- /**
- * Disables Angular tools.
- *
- * \@publicApi
- * @return {?}
- */
- function disableDebugTools() {
- exportNgVar(PROFILER_GLOBAL_NAME, null);
- }
- /**
- * @fileoverview added by tsickle
- * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
- */
- /**
- * @param {?} text
- * @return {?}
- */
- function escapeHtml(text) {
- /** @type {?} */
- const escapedText = {
- '&': '&a;',
- '"': '&q;',
- '\'': '&s;',
- '<': '&l;',
- '>': '&g;',
- };
- return text.replace(/[&"'<>]/g, (/**
- * @param {?} s
- * @return {?}
- */
- s => escapedText[s]));
- }
- /**
- * @param {?} text
- * @return {?}
- */
- function unescapeHtml(text) {
- /** @type {?} */
- const unescapedText = {
- '&a;': '&',
- '&q;': '"',
- '&s;': '\'',
- '&l;': '<',
- '&g;': '>',
- };
- return text.replace(/&[^;]+;/g, (/**
- * @param {?} s
- * @return {?}
- */
- s => unescapedText[s]));
- }
- /**
- * Create a `StateKey<T>` that can be used to store value of type T with `TransferState`.
- *
- * Example:
- *
- * ```
- * const COUNTER_KEY = makeStateKey<number>('counter');
- * let value = 10;
- *
- * transferState.set(COUNTER_KEY, value);
- * ```
- *
- * \@publicApi
- * @template T
- * @param {?} key
- * @return {?}
- */
- function makeStateKey(key) {
- return (/** @type {?} */ (key));
- }
- /**
- * A key value store that is transferred from the application on the server side to the application
- * on the client side.
- *
- * `TransferState` will be available as an injectable token. To use it import
- * `ServerTransferStateModule` on the server and `BrowserTransferStateModule` on the client.
- *
- * The values in the store are serialized/deserialized using JSON.stringify/JSON.parse. So only
- * boolean, number, string, null and non-class objects will be serialized and deserialzied in a
- * non-lossy manner.
- *
- * \@publicApi
- */
- class TransferState {
- constructor() {
- this.store = {};
- this.onSerializeCallbacks = {};
- }
- /**
- * \@internal
- * @param {?} initState
- * @return {?}
- */
- static init(initState) {
- /** @type {?} */
- const transferState = new TransferState();
- transferState.store = initState;
- return transferState;
- }
- /**
- * Get the value corresponding to a key. Return `defaultValue` if key is not found.
- * @template T
- * @param {?} key
- * @param {?} defaultValue
- * @return {?}
- */
- get(key, defaultValue) {
- return this.store[key] !== undefined ? (/** @type {?} */ (this.store[key])) : defaultValue;
- }
- /**
- * Set the value corresponding to a key.
- * @template T
- * @param {?} key
- * @param {?} value
- * @return {?}
- */
- set(key, value) { this.store[key] = value; }
- /**
- * Remove a key from the store.
- * @template T
- * @param {?} key
- * @return {?}
- */
- remove(key) { delete this.store[key]; }
- /**
- * Test whether a key exists in the store.
- * @template T
- * @param {?} key
- * @return {?}
- */
- hasKey(key) { return this.store.hasOwnProperty(key); }
- /**
- * Register a callback to provide the value for a key when `toJson` is called.
- * @template T
- * @param {?} key
- * @param {?} callback
- * @return {?}
- */
- onSerialize(key, callback) {
- this.onSerializeCallbacks[key] = callback;
- }
- /**
- * Serialize the current state of the store to JSON.
- * @return {?}
- */
- toJson() {
- // Call the onSerialize callbacks and put those values into the store.
- for (const key in this.onSerializeCallbacks) {
- if (this.onSerializeCallbacks.hasOwnProperty(key)) {
- try {
- this.store[key] = this.onSerializeCallbacks[key]();
- }
- catch (e) {
- console.warn('Exception in onSerialize callback: ', e);
- }
- }
- }
- return JSON.stringify(this.store);
- }
- }
- TransferState.decorators = [
- { type: Injectable }
- ];
- /**
- * @param {?} doc
- * @param {?} appId
- * @return {?}
- */
- function initTransferState(doc, appId) {
- // Locate the script tag with the JSON data transferred from the server.
- // The id of the script tag is set to the Angular appId + 'state'.
- /** @type {?} */
- const script = doc.getElementById(appId + '-state');
- /** @type {?} */
- let initialState = {};
- if (script && script.textContent) {
- try {
- initialState = JSON.parse(unescapeHtml(script.textContent));
- }
- catch (e) {
- console.warn('Exception while restoring TransferState for app ' + appId, e);
- }
- }
- return TransferState.init(initialState);
- }
- /**
- * NgModule to install on the client side while using the `TransferState` to transfer state from
- * server to client.
- *
- * \@publicApi
- */
- class BrowserTransferStateModule {
- }
- BrowserTransferStateModule.decorators = [
- { type: NgModule, args: [{
- providers: [{ provide: TransferState, useFactory: initTransferState, deps: [DOCUMENT, APP_ID] }],
- },] }
- ];
- /**
- * @fileoverview added by tsickle
- * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
- */
- /**
- * Predicates for use with {\@link DebugElement}'s query functions.
- *
- * \@publicApi
- */
- class By {
- /**
- * Match all elements.
- *
- * \@usageNotes
- * ### Example
- *
- * {\@example platform-browser/dom/debug/ts/by/by.ts region='by_all'}
- * @return {?}
- */
- static all() { return (/**
- * @param {?} debugElement
- * @return {?}
- */
- (debugElement) => true); }
- /**
- * Match elements by the given CSS selector.
- *
- * \@usageNotes
- * ### Example
- *
- * {\@example platform-browser/dom/debug/ts/by/by.ts region='by_css'}
- * @param {?} selector
- * @return {?}
- */
- static css(selector) {
- return (/**
- * @param {?} debugElement
- * @return {?}
- */
- (debugElement) => {
- return debugElement.nativeElement != null ?
- getDOM().elementMatches(debugElement.nativeElement, selector) :
- false;
- });
- }
- /**
- * Match elements that have the given directive present.
- *
- * \@usageNotes
- * ### Example
- *
- * {\@example platform-browser/dom/debug/ts/by/by.ts region='by_directive'}
- * @param {?} type
- * @return {?}
- */
- static directive(type) {
- return (/**
- * @param {?} debugElement
- * @return {?}
- */
- (debugElement) => (/** @type {?} */ (debugElement.providerTokens)).indexOf(type) !== -1);
- }
- }
- /**
- * @fileoverview added by tsickle
- * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
- */
- /**
- * @fileoverview added by tsickle
- * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
- */
- /**
- * \@publicApi
- * @type {?}
- */
- const VERSION = new Version('8.1.3');
- /**
- * @fileoverview added by tsickle
- * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
- */
- /**
- * @fileoverview added by tsickle
- * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
- */
- /**
- * @fileoverview added by tsickle
- * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
- */
- /**
- * Generated bundle index. Do not edit.
- */
- export { BROWSER_MODULE_PROVIDERS as ɵangular_packages_platform_browser_platform_browser_c, _document as ɵangular_packages_platform_browser_platform_browser_b, errorHandler as ɵangular_packages_platform_browser_platform_browser_a, GenericBrowserDomAdapter as ɵangular_packages_platform_browser_platform_browser_l, createMeta as ɵangular_packages_platform_browser_platform_browser_d, SERVER_TRANSITION_PROVIDERS as ɵangular_packages_platform_browser_platform_browser_i, appInitializerFactory as ɵangular_packages_platform_browser_platform_browser_h, createTitle as ɵangular_packages_platform_browser_platform_browser_e, initTransferState as ɵangular_packages_platform_browser_platform_browser_f, ELEMENT_PROBE_PROVIDERS__PRE_R3__ as ɵangular_packages_platform_browser_platform_browser_k, _createNgProbe as ɵangular_packages_platform_browser_platform_browser_j, EventManagerPlugin as ɵangular_packages_platform_browser_platform_browser_g, BrowserModule, platformBrowser, Meta, Title, disableDebugTools, enableDebugTools, BrowserTransferStateModule, TransferState, makeStateKey, By, EVENT_MANAGER_PLUGINS, EventManager, HAMMER_GESTURE_CONFIG, HAMMER_LOADER, HammerGestureConfig, DomSanitizer, VERSION, ELEMENT_PROBE_PROVIDERS__POST_R3__ as ɵELEMENT_PROBE_PROVIDERS__POST_R3__, BROWSER_SANITIZATION_PROVIDERS as ɵBROWSER_SANITIZATION_PROVIDERS, INTERNAL_BROWSER_PLATFORM_PROVIDERS as ɵINTERNAL_BROWSER_PLATFORM_PROVIDERS, initDomAdapter as ɵinitDomAdapter, BrowserDomAdapter as ɵBrowserDomAdapter, BrowserPlatformLocation as ɵBrowserPlatformLocation, TRANSITION_ID as ɵTRANSITION_ID, BrowserGetTestability as ɵBrowserGetTestability, escapeHtml as ɵescapeHtml, ELEMENT_PROBE_PROVIDERS as ɵELEMENT_PROBE_PROVIDERS, DomAdapter as ɵDomAdapter, getDOM as ɵgetDOM, setRootDomAdapter as ɵsetRootDomAdapter, DomRendererFactory2 as ɵDomRendererFactory2, NAMESPACE_URIS as ɵNAMESPACE_URIS, flattenStyles as ɵflattenStyles, shimContentAttribute as ɵshimContentAttribute, shimHostAttribute as ɵshimHostAttribute, DomEventsPlugin as ɵDomEventsPlugin, HammerGesturesPlugin as ɵHammerGesturesPlugin, KeyEventsPlugin as ɵKeyEventsPlugin, DomSharedStylesHost as ɵDomSharedStylesHost, SharedStylesHost as ɵSharedStylesHost, DomSanitizerImpl as ɵDomSanitizerImpl };
- //# sourceMappingURL=platform-browser.js.map
|