· 6 years ago · Nov 13, 2019, 10:24 AM
1/**
2 * @license Angular v8.2.4
3 * (c) 2010-2019 Google LLC. https://angular.io/
4 * License: MIT
5 */
6
7import { Observable } from 'rxjs';
8import { Subject } from 'rxjs';
9import { Subscription } from 'rxjs';
10
11/**
12 * @description
13 *
14 * Represents an abstract class `T`, if applied to a concrete class it would stop being
15 * instantiatable.
16 *
17 * @publicApi
18 */
19export declare interface AbstractType<T> extends Function {
20 prototype: T;
21}
22
23/**
24 * Below are constants for LContainer indices to help us look up LContainer members
25 * without having to remember the specific indices.
26 * Uglify will inline these when minifying so there shouldn't be a cost.
27 */
28declare const ACTIVE_INDEX = 2;
29
30/**
31 * @description
32 * A lifecycle hook that is called after the default change detector has
33 * completed checking all content of a directive.
34 *
35 * @see `AfterViewChecked`
36 * @see [Lifecycle Hooks](guide/lifecycle-hooks#onchanges) guide
37 *
38 * @usageNotes
39 * The following snippet shows how a component can implement this interface to
40 * define its own after-check functionality.
41 *
42 * {@example core/ts/metadata/lifecycle_hooks_spec.ts region='AfterContentChecked'}
43 *
44 * @publicApi
45 */
46export declare interface AfterContentChecked {
47 /**
48 * A callback method that is invoked immediately after the
49 * default change detector has completed checking all of the directive's
50 * content.
51 */
52 ngAfterContentChecked(): void;
53}
54
55/**
56 * @description
57 * A lifecycle hook that is called after Angular has fully initialized
58 * all content of a directive.
59 * Define an `ngAfterContentInit()` method to handle any additional initialization tasks.
60 *
61 * @see `OnInit`
62 * @see `AfterViewInit`
63 * @see [Lifecycle Hooks](guide/lifecycle-hooks#onchanges) guide
64 *
65 * @usageNotes
66 * The following snippet shows how a component can implement this interface to
67 * define its own content initialization method.
68 *
69 * {@example core/ts/metadata/lifecycle_hooks_spec.ts region='AfterContentInit'}
70 *
71 * @publicApi
72 */
73export declare interface AfterContentInit {
74 /**
75 * A callback method that is invoked immediately after
76 * Angular has completed initialization of all of the directive's
77 * content.
78 * It is invoked only once when the directive is instantiated.
79 */
80 ngAfterContentInit(): void;
81}
82
83/**
84 * @description
85 * A lifecycle hook that is called after the default change detector has
86 * completed checking a component's view for changes.
87 *
88 * @see `AfterContentChecked`
89 * @see [Lifecycle Hooks](guide/lifecycle-hooks#onchanges) guide
90 *
91 * @usageNotes
92 * The following snippet shows how a component can implement this interface to
93 * define its own after-check functionality.
94 *
95 * {@example core/ts/metadata/lifecycle_hooks_spec.ts region='AfterViewChecked'}
96 *
97 * @publicApi
98 */
99export declare interface AfterViewChecked {
100 /**
101 * A callback method that is invoked immediately after the
102 * default change detector has completed one change-check cycle
103 * for a component's view.
104 */
105 ngAfterViewChecked(): void;
106}
107
108/**
109 * @description
110 * A lifecycle hook that is called after Angular has fully initialized
111 * a component's view.
112 * Define an `ngAfterViewInit()` method to handle any additional initialization tasks.
113 *
114 * @see `OnInit`
115 * @see `AfterContentInit`
116 * @see [Lifecycle Hooks](guide/lifecycle-hooks#onchanges) guide
117 *
118 * @usageNotes
119 * The following snippet shows how a component can implement this interface to
120 * define its own view initialization method.
121 *
122 * {@example core/ts/metadata/lifecycle_hooks_spec.ts region='AfterViewInit'}
123 *
124 * @publicApi
125 */
126export declare interface AfterViewInit {
127 /**
128 * A callback method that is invoked immediately after
129 * Angular has completed initialization of a component's view.
130 * It is invoked only once when the view is instantiated.
131 *
132 */
133 ngAfterViewInit(): void;
134}
135
136/**
137 * A DI token that you can use to create a virtual [provider](guide/glossary#provider)
138 * that will populate the `entryComponents` field of components and NgModules
139 * based on its `useValue` property value.
140 * All components that are referenced in the `useValue` value (either directly
141 * or in a nested array or map) are added to the `entryComponents` property.
142 *
143 * @usageNotes
144 *
145 * The following example shows how the router can populate the `entryComponents`
146 * field of an NgModule based on a router configuration that refers
147 * to components.
148 *
149 * ```typescript
150 * // helper function inside the router
151 * function provideRoutes(routes) {
152 * return [
153 * {provide: ROUTES, useValue: routes},
154 * {provide: ANALYZE_FOR_ENTRY_COMPONENTS, useValue: routes, multi: true}
155 * ];
156 * }
157 *
158 * // user code
159 * let routes = [
160 * {path: '/root', component: RootComp},
161 * {path: '/teams', component: TeamsComp}
162 * ];
163 *
164 * @NgModule({
165 * providers: [provideRoutes(routes)]
166 * })
167 * class ModuleWithRoutes {}
168 * ```
169 *
170 * @publicApi
171 */
172export declare const ANALYZE_FOR_ENTRY_COMPONENTS: InjectionToken<any>;
173
174/**
175 * All callbacks provided via this token will be called for every component that is bootstrapped.
176 * Signature of the callback:
177 *
178 * `(componentRef: ComponentRef) => void`.
179 *
180 * @publicApi
181 */
182export declare const APP_BOOTSTRAP_LISTENER: InjectionToken<((compRef: ComponentRef<any>) => void)[]>;
183
184/**
185 * A DI Token representing a unique string id assigned to the application by Angular and used
186 * primarily for prefixing application attributes and CSS styles when
187 * {@link ViewEncapsulation#Emulated ViewEncapsulation.Emulated} is being used.
188 *
189 * If you need to avoid randomly generated value to be used as an application id, you can provide
190 * a custom value via a DI provider <!-- TODO: provider --> configuring the root {@link Injector}
191 * using this token.
192 * @publicApi
193 */
194export declare const APP_ID: InjectionToken<string>;
195
196/**
197 * A function that will be executed when an application is initialized.
198 *
199 * @publicApi
200 */
201export declare const APP_INITIALIZER: InjectionToken<(() => void)[]>;
202
203/**
204 * A class that reflects the state of running {@link APP_INITIALIZER}s.
205 *
206 * @publicApi
207 */
208export declare class ApplicationInitStatus {
209 private appInits;
210 private resolve;
211 private reject;
212 private initialized;
213 readonly donePromise: Promise<any>;
214 readonly done = false;
215 constructor(appInits: (() => any)[]);
216}
217
218/**
219 * Configures the root injector for an app with
220 * providers of `@angular/core` dependencies that `ApplicationRef` needs
221 * to bootstrap components.
222 *
223 * Re-exported by `BrowserModule`, which is included automatically in the root
224 * `AppModule` when you create a new app with the CLI `new` command.
225 *
226 * @publicApi
227 */
228export declare class ApplicationModule {
229 constructor(appRef: ApplicationRef);
230}
231
232/**
233 * A reference to an Angular application running on a page.
234 *
235 * @usageNotes
236 *
237 * {@a is-stable-examples}
238 * ### isStable examples and caveats
239 *
240 * Note two important points about `isStable`, demonstrated in the examples below:
241 * - the application will never be stable if you start any kind
242 * of recurrent asynchronous task when the application starts
243 * (for example for a polling process, started with a `setInterval`, a `setTimeout`
244 * or using RxJS operators like `interval`);
245 * - the `isStable` Observable runs outside of the Angular zone.
246 *
247 * Let's imagine that you start a recurrent task
248 * (here incrementing a counter, using RxJS `interval`),
249 * and at the same time subscribe to `isStable`.
250 *
251 * ```
252 * constructor(appRef: ApplicationRef) {
253 * appRef.isStable.pipe(
254 * filter(stable => stable)
255 * ).subscribe(() => console.log('App is stable now');
256 * interval(1000).subscribe(counter => console.log(counter));
257 * }
258 * ```
259 * In this example, `isStable` will never emit `true`,
260 * and the trace "App is stable now" will never get logged.
261 *
262 * If you want to execute something when the app is stable,
263 * you have to wait for the application to be stable
264 * before starting your polling process.
265 *
266 * ```
267 * constructor(appRef: ApplicationRef) {
268 * appRef.isStable.pipe(
269 * first(stable => stable),
270 * tap(stable => console.log('App is stable now')),
271 * switchMap(() => interval(1000))
272 * ).subscribe(counter => console.log(counter));
273 * }
274 * ```
275 * In this example, the trace "App is stable now" will be logged
276 * and then the counter starts incrementing every second.
277 *
278 * Note also that this Observable runs outside of the Angular zone,
279 * which means that the code in the subscription
280 * to this Observable will not trigger the change detection.
281 *
282 * Let's imagine that instead of logging the counter value,
283 * you update a field of your component
284 * and display it in its template.
285 *
286 * ```
287 * constructor(appRef: ApplicationRef) {
288 * appRef.isStable.pipe(
289 * first(stable => stable),
290 * switchMap(() => interval(1000))
291 * ).subscribe(counter => this.value = counter);
292 * }
293 * ```
294 * As the `isStable` Observable runs outside the zone,
295 * the `value` field will be updated properly,
296 * but the template will not be refreshed!
297 *
298 * You'll have to manually trigger the change detection to update the template.
299 *
300 * ```
301 * constructor(appRef: ApplicationRef, cd: ChangeDetectorRef) {
302 * appRef.isStable.pipe(
303 * first(stable => stable),
304 * switchMap(() => interval(1000))
305 * ).subscribe(counter => {
306 * this.value = counter;
307 * cd.detectChanges();
308 * });
309 * }
310 * ```
311 *
312 * Or make the subscription callback run inside the zone.
313 *
314 * ```
315 * constructor(appRef: ApplicationRef, zone: NgZone) {
316 * appRef.isStable.pipe(
317 * first(stable => stable),
318 * switchMap(() => interval(1000))
319 * ).subscribe(counter => zone.run(() => this.value = counter));
320 * }
321 * ```
322 *
323 * @publicApi
324 */
325export declare class ApplicationRef {
326 private _zone;
327 private _console;
328 private _injector;
329 private _exceptionHandler;
330 private _componentFactoryResolver;
331 private _initStatus;
332 private _bootstrapListeners;
333 private _views;
334 private _runningTick;
335 private _enforceNoNewChanges;
336 private _stable;
337 /**
338 * Get a list of component types registered to this application.
339 * This list is populated even before the component is created.
340 */
341 readonly componentTypes: Type<any>[];
342 /**
343 * Get a list of components registered to this application.
344 */
345 readonly components: ComponentRef<any>[];
346 /**
347 * Returns an Observable that indicates when the application is stable or unstable.
348 *
349 * @see [Usage notes](#is-stable-examples) for examples and caveats when using this API.
350 */
351 readonly isStable: Observable<boolean>;
352 /**
353 * Bootstrap a new component at the root level of the application.
354 *
355 * @usageNotes
356 * ### Bootstrap process
357 *
358 * When bootstrapping a new root component into an application, Angular mounts the
359 * specified application component onto DOM elements identified by the componentType's
360 * selector and kicks off automatic change detection to finish initializing the component.
361 *
362 * Optionally, a component can be mounted onto a DOM element that does not match the
363 * componentType's selector.
364 *
365 * ### Example
366 * {@example core/ts/platform/platform.ts region='longform'}
367 */
368 bootstrap<C>(componentOrFactory: ComponentFactory<C> | Type<C>, rootSelectorOrNode?: string | any): ComponentRef<C>;
369 /**
370 * Invoke this method to explicitly process change detection and its side-effects.
371 *
372 * In development mode, `tick()` also performs a second change detection cycle to ensure that no
373 * further changes are detected. If additional changes are picked up during this second cycle,
374 * bindings in the app have side-effects that cannot be resolved in a single change detection
375 * pass.
376 * In this case, Angular throws an error, since an Angular application can only have one change
377 * detection pass during which all change detection must complete.
378 */
379 tick(): void;
380 /**
381 * Attaches a view so that it will be dirty checked.
382 * The view will be automatically detached when it is destroyed.
383 * This will throw if the view is already attached to a ViewContainer.
384 */
385 attachView(viewRef: ViewRef): void;
386 /**
387 * Detaches a view from dirty checking again.
388 */
389 detachView(viewRef: ViewRef): void;
390 private _loadComponent;
391 private _unloadComponent;
392 /**
393 * Returns the number of attached views.
394 */
395 readonly viewCount: number;
396}
397
398/**
399 * @publicApi
400 */
401export declare function asNativeElements(debugEls: DebugElement[]): any;
402
403/**
404 * Checks that there currently is a platform which contains the given token as a provider.
405 *
406 * @publicApi
407 */
408export declare function assertPlatform(requiredToken: any): PlatformRef;
409
410/**
411 * Type of the Attribute metadata.
412 *
413 * @publicApi
414 */
415export declare interface Attribute {
416 /**
417 * The name of the attribute whose value can be injected.
418 */
419 attributeName?: string;
420}
421
422/**
423 * Attribute decorator and metadata.
424 *
425 * @Annotation
426 * @publicApi
427 */
428export declare const Attribute: AttributeDecorator;
429
430/**
431 * Type of the Attribute decorator / constructor function.
432 *
433 * @publicApi
434 */
435export declare interface AttributeDecorator {
436 /**
437 * Parameter decorator for a directive constructor that designates
438 * a host-element attribute whose value is injected as a constant string literal.
439 *
440 * @usageNotes
441 *
442 * Suppose we have an `<input>` element and want to know its `type`.
443 *
444 * ```html
445 * <input type="text">
446 * ```
447 *
448 * The following example uses the decorator to inject the string literal `text`.
449 *
450 * {@example core/ts/metadata/metadata.ts region='attributeMetadata'}
451 *
452 * ### Example as TypeScript Decorator
453 *
454 * {@example core/ts/metadata/metadata.ts region='attributeFactory'}
455 *
456 */
457 (name: string): any;
458 new (name: string): Attribute;
459}
460
461declare const BINDING_INDEX = 7;
462
463declare interface BindingDef {
464 flags: ɵBindingFlags;
465 ns: string | null;
466 name: string | null;
467 nonMinifiedName: string | null;
468 securityContext: SecurityContext | null;
469 suffix: string | null;
470}
471
472/**
473 * Provides additional options to the bootstraping process.
474 *
475 *
476 */
477declare interface BootstrapOptions {
478 /**
479 * Optionally specify which `NgZone` should be used.
480 *
481 * - Provide your own `NgZone` instance.
482 * - `zone.js` - Use default `NgZone` which requires `Zone.js`.
483 * - `noop` - Use `NoopNgZone` which does nothing.
484 */
485 ngZone?: NgZone | 'zone.js' | 'noop';
486}
487
488
489declare const BRAND = "__SANITIZER_TRUSTED_BRAND__";
490
491declare const enum BypassType {
492 Url = "Url",
493 Html = "Html",
494 ResourceUrl = "ResourceUrl",
495 Script = "Script",
496 Style = "Style"
497}
498
499
500/**
501 * The strategy that the default change detector uses to detect changes.
502 * When set, takes effect the next time change detection is triggered.
503 *
504 * @publicApi
505 */
506export declare enum ChangeDetectionStrategy {
507 /**
508 * Use the `CheckOnce` strategy, meaning that automatic change detection is deactivated
509 * until reactivated by setting the strategy to `Default` (`CheckAlways`).
510 * Change detection can still be explicitly invoked.
511 * This strategy applies to all child directives and cannot be overridden.
512 */
513 OnPush = 0,
514 /**
515 * Use the default `CheckAlways` strategy, in which change detection is automatic until
516 * explicitly deactivated.
517 */
518 Default = 1
519}
520
521/**
522 * Base class for Angular Views, provides change detection functionality.
523 * A change-detection tree collects all views that are to be checked for changes.
524 * Use the methods to add and remove views from the tree, initiate change-detection,
525 * and explicitly mark views as _dirty_, meaning that they have changed and need to be rerendered.
526 *
527 * @usageNotes
528 *
529 * The following examples demonstrate how to modify default change-detection behavior
530 * to perform explicit detection when needed.
531 *
532 * ### Use `markForCheck()` with `CheckOnce` strategy
533 *
534 * The following example sets the `OnPush` change-detection strategy for a component
535 * (`CheckOnce`, rather than the default `CheckAlways`), then forces a second check
536 * after an interval. See [live demo](http://plnkr.co/edit/GC512b?p=preview).
537 *
538 * <code-example path="core/ts/change_detect/change-detection.ts"
539 * region="mark-for-check"></code-example>
540 *
541 * ### Detach change detector to limit how often check occurs
542 *
543 * The following example defines a component with a large list of read-only data
544 * that is expected to change constantly, many times per second.
545 * To improve performance, we want to check and update the list
546 * less often than the changes actually occur. To do that, we detach
547 * the component's change detector and perform an explicit local check every five seconds.
548 *
549 * <code-example path="core/ts/change_detect/change-detection.ts" region="detach"></code-example>
550 *
551 *
552 * ### Reattaching a detached component
553 *
554 * The following example creates a component displaying live data.
555 * The component detaches its change detector from the main change detector tree
556 * when the `live` property is set to false, and reattaches it when the property
557 * becomes true.
558 *
559 * <code-example path="core/ts/change_detect/change-detection.ts" region="reattach"></code-example>
560 *
561 * @publicApi
562 */
563export declare abstract class ChangeDetectorRef {
564 /**
565 * When a view uses the {@link ChangeDetectionStrategy#OnPush OnPush} (checkOnce)
566 * change detection strategy, explicitly marks the view as changed so that
567 * it can be checked again.
568 *
569 * Components are normally marked as dirty (in need of rerendering) when inputs
570 * have changed or events have fired in the view. Call this method to ensure that
571 * a component is checked even if these triggers have not occured.
572 *
573 * <!-- TODO: Add a link to a chapter on OnPush components -->
574 *
575 */
576 abstract markForCheck(): void;
577 /**
578 * Detaches this view from the change-detection tree.
579 * A detached view is not checked until it is reattached.
580 * Use in combination with `detectChanges()` to implement local change detection checks.
581 *
582 * Detached views are not checked during change detection runs until they are
583 * re-attached, even if they are marked as dirty.
584 *
585 * <!-- TODO: Add a link to a chapter on detach/reattach/local digest -->
586 * <!-- TODO: Add a live demo once ref.detectChanges is merged into master -->
587 *
588 */
589 abstract detach(): void;
590 /**
591 * Checks this view and its children. Use in combination with {@link ChangeDetectorRef#detach
592 * detach}
593 * to implement local change detection checks.
594 *
595 * <!-- TODO: Add a link to a chapter on detach/reattach/local digest -->
596 * <!-- TODO: Add a live demo once ref.detectChanges is merged into master -->
597 *
598 */
599 abstract detectChanges(): void;
600 /**
601 * Checks the change detector and its children, and throws if any changes are detected.
602 *
603 * Use in development mode to verify that running change detection doesn't introduce
604 * other changes.
605 */
606 abstract checkNoChanges(): void;
607 /**
608 * Re-attaches the previously detached view to the change detection tree.
609 * Views are attached to the tree by default.
610 *
611 * <!-- TODO: Add a link to a chapter on detach/reattach/local digest -->
612 *
613 */
614 abstract reattach(): void;
615}
616
617declare const CHILD_HEAD = 14;
618
619declare const CHILD_TAIL = 15;
620
621/**
622 * Configures the `Injector` to return an instance of `useClass` for a token.
623 * @see ["Dependency Injection Guide"](guide/dependency-injection).
624 *
625 * @usageNotes
626 *
627 * {@example core/di/ts/provider_spec.ts region='ClassProvider'}
628 *
629 * Note that following two providers are not equal:
630 *
631 * {@example core/di/ts/provider_spec.ts region='ClassProviderDifference'}
632 *
633 * ### Multi-value example
634 *
635 * {@example core/di/ts/provider_spec.ts region='MultiProviderAspect'}
636 *
637 * @publicApi
638 */
639export declare interface ClassProvider extends ClassSansProvider {
640 /**
641 * An injection token. (Typically an instance of `Type` or `InjectionToken`, but can be `any`).
642 */
643 provide: any;
644 /**
645 * When true, injector returns an array of instances. This is useful to allow multiple
646 * providers spread across many files to provide configuration information to a common token.
647 */
648 multi?: boolean;
649}
650
651/**
652 * Configures the `Injector` to return a value by invoking a `useClass` function.
653 * Base for `ClassProvider` decorator.
654 *
655 * @see ["Dependency Injection Guide"](guide/dependency-injection).
656 *
657 * @publicApi
658 */
659export declare interface ClassSansProvider {
660 /**
661 * Class to instantiate for the `token`.
662 */
663 useClass: Type<any>;
664}
665
666declare const CLEANUP = 8;
667
668/**
669 * @deprecated v4.0.0 - Use IterableChangeRecord instead.
670 * @publicApi
671 */
672export declare interface CollectionChangeRecord<V> extends IterableChangeRecord<V> {
673}
674
675/**
676 * Marks that the next string is for comment.
677 *
678 * See `I18nMutateOpCodes` documentation.
679 */
680declare const COMMENT_MARKER: COMMENT_MARKER;
681
682declare interface COMMENT_MARKER {
683 marker: 'comment';
684}
685
686/**
687 * Compile an Angular injectable according to its `Injectable` metadata, and patch the resulting
688 * `ngInjectableDef` onto the injectable type.
689 */
690declare function compileInjectable(type: Type<any>, srcMeta?: Injectable): void;
691
692/**
693 * Low-level service for running the angular compiler during runtime
694 * to create {@link ComponentFactory}s, which
695 * can later be used to create and render a Component instance.
696 *
697 * Each `@NgModule` provides an own `Compiler` to its injector,
698 * that will use the directives/pipes of the ng module for compilation
699 * of components.
700 *
701 * @publicApi
702 */
703export declare class Compiler {
704 /**
705 * Compiles the given NgModule and all of its components. All templates of the components listed
706 * in `entryComponents` have to be inlined.
707 */
708 compileModuleSync: <T>(moduleType: Type<T>) => NgModuleFactory<T>;
709 /**
710 * Compiles the given NgModule and all of its components
711 */
712 compileModuleAsync: <T>(moduleType: Type<T>) => Promise<NgModuleFactory<T>>;
713 /**
714 * Same as {@link #compileModuleSync} but also creates ComponentFactories for all components.
715 */
716 compileModuleAndAllComponentsSync: <T>(moduleType: Type<T>) => ModuleWithComponentFactories<T>;
717 /**
718 * Same as {@link #compileModuleAsync} but also creates ComponentFactories for all components.
719 */
720 compileModuleAndAllComponentsAsync: <T>(moduleType: Type<T>) => Promise<ModuleWithComponentFactories<T>>;
721 /**
722 * Clears all caches.
723 */
724 clearCache(): void;
725 /**
726 * Clears the cache for the given component/ngModule.
727 */
728 clearCacheFor(type: Type<any>): void;
729 /**
730 * Returns the id for a given NgModule, if one is defined and known to the compiler.
731 */
732 getModuleId(moduleType: Type<any>): string | undefined;
733}
734
735/**
736 * Token to provide CompilerOptions in the platform injector.
737 *
738 * @publicApi
739 */
740export declare const COMPILER_OPTIONS: InjectionToken<CompilerOptions[]>;
741
742/**
743 * A factory for creating a Compiler
744 *
745 * @publicApi
746 */
747export declare abstract class CompilerFactory {
748 abstract createCompiler(options?: CompilerOptions[]): Compiler;
749}
750
751/**
752 * Options for creating a compiler
753 *
754 * @publicApi
755 */
756export declare type CompilerOptions = {
757 useJit?: boolean;
758 defaultEncapsulation?: ViewEncapsulation;
759 providers?: StaticProvider[];
760 missingTranslation?: MissingTranslationStrategy;
761 preserveWhitespaces?: boolean;
762};
763
764/**
765 * Supplies configuration metadata for an Angular component.
766 *
767 * @publicApi
768 */
769export declare interface Component extends Directive {
770 /**
771 * The change-detection strategy to use for this component.
772 *
773 * When a component is instantiated, Angular creates a change detector,
774 * which is responsible for propagating the component's bindings.
775 * The strategy is one of:
776 * - `ChangeDetectionStrategy#OnPush` sets the strategy to `CheckOnce` (on demand).
777 * - `ChangeDetectionStrategy#Default` sets the strategy to `CheckAlways`.
778 */
779 changeDetection?: ChangeDetectionStrategy;
780 /**
781 * Defines the set of injectable objects that are visible to its view DOM children.
782 * See [example](#injecting-a-class-with-a-view-provider).
783 *
784 */
785 viewProviders?: Provider[];
786 /**
787 * The module ID of the module that contains the component.
788 * The component must be able to resolve relative URLs for templates and styles.
789 * SystemJS exposes the `__moduleName` variable within each module.
790 * In CommonJS, this can be set to `module.id`.
791 *
792 */
793 moduleId?: string;
794 /**
795 * The relative path or absolute URL of a template file for an Angular component.
796 * If provided, do not supply an inline template using `template`.
797 *
798 */
799 templateUrl?: string;
800 /**
801 * An inline template for an Angular component. If provided,
802 * do not supply a template file using `templateUrl`.
803 *
804 */
805 template?: string;
806 /**
807 * One or more relative paths or absolute URLs for files containing CSS stylesheets to use
808 * in this component.
809 */
810 styleUrls?: string[];
811 /**
812 * One or more inline CSS stylesheets to use
813 * in this component.
814 */
815 styles?: string[];
816 /**
817 * One or more animation `trigger()` calls, containing
818 * `state()` and `transition()` definitions.
819 * See the [Animations guide](/guide/animations) and animations API documentation.
820 *
821 */
822 animations?: any[];
823 /**
824 * An encapsulation policy for the template and CSS styles. One of:
825 * - `ViewEncapsulation.Native`: Deprecated. Use `ViewEncapsulation.ShadowDom` instead.
826 * - `ViewEncapsulation.Emulated`: Use shimmed CSS that
827 * emulates the native behavior.
828 * - `ViewEncapsulation.None`: Use global CSS without any
829 * encapsulation.
830 * - `ViewEncapsulation.ShadowDom`: Use Shadow DOM v1 to encapsulate styles.
831 *
832 * If not supplied, the value is taken from `CompilerOptions`. The default compiler option is
833 * `ViewEncapsulation.Emulated`.
834 *
835 * If the policy is set to `ViewEncapsulation.Emulated` and the component has no `styles`
836 * or `styleUrls` specified, the policy is automatically switched to `ViewEncapsulation.None`.
837 */
838 encapsulation?: ViewEncapsulation;
839 /**
840 * Overrides the default encapsulation start and end delimiters (`{{` and `}}`)
841 */
842 interpolation?: [string, string];
843 /**
844 * A set of components that should be compiled along with
845 * this component. For each component listed here,
846 * Angular creates a {@link ComponentFactory} and stores it in the
847 * {@link ComponentFactoryResolver}.
848 */
849 entryComponents?: Array<Type<any> | any[]>;
850 /**
851 * True to preserve or false to remove potentially superfluous whitespace characters
852 * from the compiled template. Whitespace characters are those matching the `\s`
853 * character class in JavaScript regular expressions. Default is false, unless
854 * overridden in compiler options.
855 */
856 preserveWhitespaces?: boolean;
857}
858
859/**
860 * Component decorator and metadata.
861 *
862 * @Annotation
863 * @publicApi
864 */
865export declare const Component: ComponentDecorator;
866
867/**
868 * Component decorator interface
869 *
870 * @publicApi
871 */
872export declare interface ComponentDecorator {
873 /**
874 * Decorator that marks a class as an Angular component and provides configuration
875 * metadata that determines how the component should be processed,
876 * instantiated, and used at runtime.
877 *
878 * Components are the most basic UI building block of an Angular app.
879 * An Angular app contains a tree of Angular components.
880 *
881 * Angular components are a subset of directives, always associated with a template.
882 * Unlike other directives, only one component can be instantiated per an element in a template.
883 *
884 * A component must belong to an NgModule in order for it to be available
885 * to another component or application. To make it a member of an NgModule,
886 * list it in the `declarations` field of the `NgModule` metadata.
887 *
888 * Note that, in addition to these options for configuring a directive,
889 * you can control a component's runtime behavior by implementing
890 * life-cycle hooks. For more information, see the
891 * [Lifecycle Hooks](guide/lifecycle-hooks) guide.
892 *
893 * @usageNotes
894 *
895 * ### Setting component inputs
896 *
897 * The following example creates a component with two data-bound properties,
898 * specified by the `inputs` value.
899 *
900 * <code-example path="core/ts/metadata/directives.ts" region="component-input"></code-example>
901 *
902 *
903 * ### Setting component outputs
904 *
905 * The following example shows two event emitters that emit on an interval. One
906 * emits an output every second, while the other emits every five seconds.
907 *
908 * {@example core/ts/metadata/directives.ts region='component-output-interval'}
909 *
910 * ### Injecting a class with a view provider
911 *
912 * The following simple example injects a class into a component
913 * using the view provider specified in component metadata:
914 *
915 * ```ts
916 * class Greeter {
917 * greet(name:string) {
918 * return 'Hello ' + name + '!';
919 * }
920 * }
921 *
922 * @Directive({
923 * selector: 'needs-greeter'
924 * })
925 * class NeedsGreeter {
926 * greeter:Greeter;
927 *
928 * constructor(greeter:Greeter) {
929 * this.greeter = greeter;
930 * }
931 * }
932 *
933 * @Component({
934 * selector: 'greet',
935 * viewProviders: [
936 * Greeter
937 * ],
938 * template: `<needs-greeter></needs-greeter>`
939 * })
940 * class HelloWorld {
941 * }
942 *
943 * ```
944 *
945 * ### Preserving whitespace
946 *
947 * Removing whitespace can greatly reduce AOT-generated code size and speed up view creation.
948 * As of Angular 6, the default for `preserveWhitespaces` is false (whitespace is removed).
949 * To change the default setting for all components in your application, set
950 * the `preserveWhitespaces` option of the AOT compiler.
951 *
952 * By default, the AOT compiler removes whitespace characters as follows:
953 * * Trims all whitespaces at the beginning and the end of a template.
954 * * Removes whitespace-only text nodes. For example,
955 *
956 * ```html
957 * <button>Action 1</button> <button>Action 2</button>
958 * ```
959 *
960 * becomes:
961 *
962 * ```html
963 * <button>Action 1</button><button>Action 2</button>
964 * ```
965 *
966 * * Replaces a series of whitespace characters in text nodes with a single space.
967 * For example, `<span>\n some text\n</span>` becomes `<span> some text </span>`.
968 * * Does NOT alter text nodes inside HTML tags such as `<pre>` or `<textarea>`,
969 * where whitespace characters are significant.
970 *
971 * Note that these transformations can influence DOM nodes layout, although impact
972 * should be minimal.
973 *
974 * You can override the default behavior to preserve whitespace characters
975 * in certain fragments of a template. For example, you can exclude an entire
976 * DOM sub-tree by using the `ngPreserveWhitespaces` attribute:
977 *
978 * ```html
979 * <div ngPreserveWhitespaces>
980 * whitespaces are preserved here
981 * <span> and here </span>
982 * </div>
983 * ```
984 *
985 * You can force a single space to be preserved in a text node by using `&ngsp;`,
986 * which is replaced with a space character by Angular's template
987 * compiler:
988 *
989 * ```html
990 * <a>Spaces</a>&ngsp;<a>between</a>&ngsp;<a>links.</a>
991 * <!-->compiled to be equivalent to:</>
992 * <a>Spaces</a> <a>between</a> <a>links.</a>
993 * ```
994 *
995 * Note that sequences of `&ngsp;` are still collapsed to just one space character when
996 * the `preserveWhitespaces` option is set to `false`.
997 *
998 * ```html
999 * <a>before</a>&ngsp;&ngsp;&ngsp;<a>after</a>
1000 * <!-->compiled to be equivalent to:</>
1001 * <a>Spaces</a> <a>between</a> <a>links.</a>
1002 * ```
1003 *
1004 * To preserve sequences of whitespace characters, use the
1005 * `ngPreserveWhitespaces` attribute.
1006 *
1007 * @Annotation
1008 */
1009 (obj: Component): TypeDecorator;
1010 /**
1011 * See the `Component` decorator.
1012 */
1013 new (obj: Component): Component;
1014}
1015
1016declare interface ComponentDefFeature {
1017 <T>(componentDef: ɵComponentDef<T>): void;
1018 /**
1019 * Marks a feature as something that {@link InheritDefinitionFeature} will execute
1020 * during inheritance.
1021 *
1022 * NOTE: DO NOT SET IN ROOT OF MODULE! Doing so will result in tree-shakers/bundlers
1023 * identifying the change as a side effect, and the feature will be included in
1024 * every bundle.
1025 */
1026 ngInherit?: true;
1027}
1028
1029/**
1030 * Base class for a factory that can create a component dynamically.
1031 * Instantiate a factory for a given type of component with `resolveComponentFactory()`.
1032 * Use the resulting `ComponentFactory.create()` method to create a component of that type.
1033 *
1034 * @see [Dynamic Components](guide/dynamic-component-loader)
1035 *
1036 * @publicApi
1037 */
1038declare abstract class ComponentFactory<C> {
1039 /**
1040 * The component's HTML selector.
1041 */
1042 abstract readonly selector: string;
1043 /**
1044 * The type of component the factory will create.
1045 */
1046 abstract readonly componentType: Type<any>;
1047 /**
1048 * Selector for all <ng-content> elements in the component.
1049 */
1050 abstract readonly ngContentSelectors: string[];
1051 /**
1052 * The inputs of the component.
1053 */
1054 abstract readonly inputs: {
1055 propName: string;
1056 templateName: string;
1057 }[];
1058 /**
1059 * The outputs of the component.
1060 */
1061 abstract readonly outputs: {
1062 propName: string;
1063 templateName: string;
1064 }[];
1065 /**
1066 * Creates a new component.
1067 */
1068 abstract create(injector: Injector, projectableNodes?: any[][], rootSelectorOrNode?: string | any, ngModule?: NgModuleRef<any>): ComponentRef<C>;
1069}
1070export { ComponentFactory }
1071export { ComponentFactory as ɵComponentFactory }
1072
1073/**
1074 * A simple registry that maps `Components` to generated `ComponentFactory` classes
1075 * that can be used to create instances of components.
1076 * Use to obtain the factory for a given component type,
1077 * then use the factory's `create()` method to create a component of that type.
1078 *
1079 * @see [Dynamic Components](guide/dynamic-component-loader)
1080 * @publicApi
1081 */
1082export declare abstract class ComponentFactoryResolver {
1083 static NULL: ComponentFactoryResolver;
1084 /**
1085 * Retrieves the factory object that creates a component of the given type.
1086 * @param component The component type.
1087 */
1088 abstract resolveComponentFactory<T>(component: Type<T>): ComponentFactory<T>;
1089}
1090
1091declare type ComponentInstance = {};
1092
1093/**
1094 * Represents a component created by a `ComponentFactory`.
1095 * Provides access to the component instance and related objects,
1096 * and provides the means of destroying the instance.
1097 *
1098 * @publicApi
1099 */
1100export declare abstract class ComponentRef<C> {
1101 /**
1102 * The host or anchor [element](guide/glossary#element) for this component instance.
1103 */
1104 abstract readonly location: ElementRef;
1105 /**
1106 * The [dependency injector](guide/glossary#injector) for this component instance.
1107 */
1108 abstract readonly injector: Injector;
1109 /**
1110 * This component instance.
1111 */
1112 abstract readonly instance: C;
1113 /**
1114 * The [host view](guide/glossary#view-tree) defined by the template
1115 * for this component instance.
1116 */
1117 abstract readonly hostView: ViewRef;
1118 /**
1119 * The change detector for this component instance.
1120 */
1121 abstract readonly changeDetectorRef: ChangeDetectorRef;
1122 /**
1123 * The type of this component (as created by a `ComponentFactory` class).
1124 */
1125 abstract readonly componentType: Type<any>;
1126 /**
1127 * Destroys the component instance and all of the data structures associated with it.
1128 */
1129 abstract destroy(): void;
1130 /**
1131 * A lifecycle hook that provides additional developer-defined cleanup
1132 * functionality for the component.
1133 * @param callback A handler function that cleans up developer-defined data
1134 * associated with this component. Called when the `destroy()` method is invoked.
1135 */
1136 abstract onDestroy(callback: Function): void;
1137}
1138
1139/**
1140 * Definition of what a template rendering function should look like for a component.
1141 */
1142declare type ComponentTemplate<T> = {
1143 <U extends T>(rf: ɵRenderFlags, ctx: T | U): void;
1144};
1145
1146/**
1147 * Configures the `Injector` to return an instance of a token.
1148 *
1149 * @see ["Dependency Injection Guide"](guide/dependency-injection).
1150 *
1151 * @usageNotes
1152 *
1153 * {@example core/di/ts/provider_spec.ts region='ConstructorProvider'}
1154 *
1155 * ### Multi-value example
1156 *
1157 * {@example core/di/ts/provider_spec.ts region='MultiProviderAspect'}
1158 *
1159 * @publicApi
1160 */
1161export declare interface ConstructorProvider extends ConstructorSansProvider {
1162 /**
1163 * An injection token. Typically an instance of `Type` or `InjectionToken`, but can be `any`.
1164 */
1165 provide: Type<any>;
1166 /**
1167 * When true, injector returns an array of instances. This is useful to allow multiple
1168 * providers spread across many files to provide configuration information to a common token.
1169 */
1170 multi?: boolean;
1171}
1172
1173/**
1174 * Configures the `Injector` to return an instance of a token.
1175 *
1176 * @see ["Dependency Injection Guide"](guide/dependency-injection).
1177 *
1178 * @usageNotes
1179 *
1180 * ```ts
1181 * @Injectable(SomeModule, {deps: []})
1182 * class MyService {}
1183 * ```
1184 *
1185 * @publicApi
1186 */
1187export declare interface ConstructorSansProvider {
1188 /**
1189 * A list of `token`s to be resolved by the injector.
1190 */
1191 deps?: any[];
1192}
1193
1194/**
1195 * Type of the ContentChild metadata.
1196 *
1197 * @publicApi
1198 */
1199export declare type ContentChild = Query;
1200
1201/**
1202 * ContentChild decorator and metadata.
1203 *
1204 *
1205 * @Annotation
1206 *
1207 * @publicApi
1208 */
1209export declare const ContentChild: ContentChildDecorator;
1210
1211/**
1212 * Type of the ContentChild decorator / constructor function.
1213 *
1214 * @publicApi
1215 */
1216export declare interface ContentChildDecorator {
1217 /**
1218 * Parameter decorator that configures a content query.
1219 *
1220 * Use to get the first element or the directive matching the selector from the content DOM.
1221 * If the content DOM changes, and a new child matches the selector,
1222 * the property will be updated.
1223 *
1224 * Content queries are set before the `ngAfterContentInit` callback is called.
1225 *
1226 * Does not retrieve elements or directives that are in other components' templates,
1227 * since a component's template is always a black box to its ancestors.
1228 *
1229 * **Metadata Properties**:
1230 *
1231 * * **selector** - The directive type or the name used for querying.
1232 * * **read** - True to read a different token from the queried element.
1233 * * **static** - True to resolve query results before change detection runs,
1234 * false to resolve after change detection.
1235 *
1236 * When `static` is not provided, uses the query results to determine the timing of query
1237 * resolution. If any query results are inside a nested view (such as `*ngIf`), the query is
1238 * resolved after change detection runs. Otherwise, it is resolved before change detection
1239 * runs.
1240 *
1241 * @usageNotes
1242 *
1243 * {@example core/di/ts/contentChild/content_child_howto.ts region='HowTo'}
1244 *
1245 * ### Example
1246 *
1247 * {@example core/di/ts/contentChild/content_child_example.ts region='Component'}
1248 *
1249 * @Annotation
1250 */
1251 (selector: Type<any> | Function | string, opts: {
1252 read?: any;
1253 static: boolean;
1254 }): any;
1255 new (selector: Type<any> | Function | string, opts: {
1256 read?: any;
1257 static: boolean;
1258 }): ContentChild;
1259}
1260
1261/**
1262 * Type of the ContentChildren metadata.
1263 *
1264 *
1265 * @Annotation
1266 * @publicApi
1267 */
1268export declare type ContentChildren = Query;
1269
1270/**
1271 * ContentChildren decorator and metadata.
1272 *
1273 *
1274 * @Annotation
1275 * @publicApi
1276 */
1277export declare const ContentChildren: ContentChildrenDecorator;
1278
1279/**
1280 * Type of the ContentChildren decorator / constructor function.
1281 *
1282 * @see `ContentChildren`.
1283 * @publicApi
1284 */
1285export declare interface ContentChildrenDecorator {
1286 /**
1287 * Parameter decorator that configures a content query.
1288 *
1289 * Use to get the `QueryList` of elements or directives from the content DOM.
1290 * Any time a child element is added, removed, or moved, the query list will be
1291 * updated, and the changes observable of the query list will emit a new value.
1292 *
1293 * Content queries are set before the `ngAfterContentInit` callback is called.
1294 *
1295 * Does not retrieve elements or directives that are in other components' templates,
1296 * since a component's template is always a black box to its ancestors.
1297 *
1298 * **Metadata Properties**:
1299 *
1300 * * **selector** - The directive type or the name used for querying.
1301 * * **descendants** - True to include all descendants, otherwise include only direct children.
1302 * * **read** - True to read a different token from the queried elements.
1303 *
1304 * @usageNotes
1305 *
1306 * Here is a simple demonstration of how the `ContentChildren` decorator can be used.
1307 *
1308 * {@example core/di/ts/contentChildren/content_children_howto.ts region='HowTo'}
1309 *
1310 * ### Tab-pane example
1311 *
1312 * Here is a slightly more realistic example that shows how `ContentChildren` decorators
1313 * can be used to implement a tab pane component.
1314 *
1315 * {@example core/di/ts/contentChildren/content_children_example.ts region='Component'}
1316 *
1317 * @Annotation
1318 */
1319 (selector: Type<any> | Function | string, opts?: {
1320 descendants?: boolean;
1321 read?: any;
1322 }): any;
1323 new (selector: Type<any> | Function | string, opts?: {
1324 descendants?: boolean;
1325 read?: any;
1326 }): Query;
1327}
1328
1329/**
1330 * Definition of what a content queries function should look like.
1331 */
1332declare type ContentQueriesFunction<T> = <U extends T>(rf: ɵRenderFlags, ctx: U, directiveIndex: number) => void;
1333
1334declare const CONTEXT = 9;
1335
1336/** Options that control how the component should be bootstrapped. */
1337declare interface CreateComponentOptions {
1338 /** Which renderer factory to use. */
1339 rendererFactory?: RendererFactory3;
1340 /** A custom sanitizer instance */
1341 sanitizer?: Sanitizer;
1342 /** A custom animation player handler */
1343 playerHandler?: ɵPlayerHandler;
1344 /**
1345 * Host element on which the component will be bootstrapped. If not specified,
1346 * the component definition's `tag` is used to query the existing DOM for the
1347 * element to bootstrap.
1348 */
1349 host?: RElement | string;
1350 /** Module injector for the component. If unspecified, the injector will be NULL_INJECTOR. */
1351 injector?: Injector;
1352 /**
1353 * List of features to be applied to the created component. Features are simply
1354 * functions that decorate a component with a certain behavior.
1355 *
1356 * Typically, the features in this list are features that cannot be added to the
1357 * other features list in the component definition because they rely on other factors.
1358 *
1359 * Example: `LifecycleHooksFeature` is a function that adds lifecycle hook capabilities
1360 * to root components in a tree-shakable way. It cannot be added to the component
1361 * features list because there's no way of knowing when the component will be used as
1362 * a root component.
1363 */
1364 hostFeatures?: HostFeature[];
1365 /**
1366 * A function which is used to schedule change detection work in the future.
1367 *
1368 * When marking components as dirty, it is necessary to schedule the work of
1369 * change detection in the future. This is done to coalesce multiple
1370 * {@link markDirty} calls into a single changed detection processing.
1371 *
1372 * The default value of the scheduler is the `requestAnimationFrame` function.
1373 *
1374 * It is also useful to override this function for testing purposes.
1375 */
1376 scheduler?: (work: () => void) => void;
1377}
1378
1379/**
1380 * Creates a platform.
1381 * Platforms have to be eagerly created via this function.
1382 *
1383 * @publicApi
1384 */
1385export declare function createPlatform(injector: Injector): PlatformRef;
1386
1387/**
1388 * Creates a factory for a platform
1389 *
1390 * @publicApi
1391 */
1392export declare function createPlatformFactory(parentPlatformFactory: ((extraProviders?: StaticProvider[]) => PlatformRef) | null, name: string, providers?: StaticProvider[]): (extraProviders?: StaticProvider[]) => PlatformRef;
1393
1394
1395/**
1396 * Expresses a single CSS Selector.
1397 *
1398 * Beginning of array
1399 * - First index: element name
1400 * - Subsequent odd indices: attr keys
1401 * - Subsequent even indices: attr values
1402 *
1403 * After SelectorFlags.CLASS flag
1404 * - Class name values
1405 *
1406 * SelectorFlags.NOT flag
1407 * - Changes the mode to NOT
1408 * - Can be combined with other flags to set the element / attr / class mode
1409 *
1410 * e.g. SelectorFlags.NOT | SelectorFlags.ELEMENT
1411 *
1412 * Example:
1413 * Original: `div.foo.bar[attr1=val1][attr2]`
1414 * Parsed: ['div', 'attr1', 'val1', 'attr2', '', SelectorFlags.CLASS, 'foo', 'bar']
1415 *
1416 * Original: 'div[attr1]:not(.foo[attr2])
1417 * Parsed: [
1418 * 'div', 'attr1', '',
1419 * SelectorFlags.NOT | SelectorFlags.ATTRIBUTE 'attr2', '', SelectorFlags.CLASS, 'foo'
1420 * ]
1421 *
1422 * See more examples in node_selector_matcher_spec.ts
1423 */
1424declare type CssSelector = (string | SelectorFlags)[];
1425
1426/**
1427 * Defines a schema that allows an NgModule to contain the following:
1428 * - Non-Angular elements named with dash case (`-`).
1429 * - Element properties named with dash case (`-`).
1430 * Dash case is the naming convention for custom elements.
1431 *
1432 * @publicApi
1433 */
1434export declare const CUSTOM_ELEMENTS_SCHEMA: SchemaMetadata;
1435
1436/**
1437 * @publicApi
1438 */
1439export declare interface DebugElement extends DebugNode {
1440 readonly name: string;
1441 readonly properties: {
1442 [key: string]: any;
1443 };
1444 readonly attributes: {
1445 [key: string]: string | null;
1446 };
1447 readonly classes: {
1448 [key: string]: boolean;
1449 };
1450 readonly styles: {
1451 [key: string]: string | null;
1452 };
1453 readonly childNodes: DebugNode[];
1454 readonly nativeElement: any;
1455 readonly children: DebugElement[];
1456 query(predicate: Predicate<DebugElement>): DebugElement;
1457 queryAll(predicate: Predicate<DebugElement>): DebugElement[];
1458 queryAllNodes(predicate: Predicate<DebugNode>): DebugNode[];
1459 triggerEventHandler(eventName: string, eventObj: any): void;
1460}
1461
1462/**
1463 * @publicApi
1464 */
1465export declare const DebugElement: {
1466 new (...args: any[]): DebugElement;
1467};
1468
1469declare class DebugElement__POST_R3__ extends DebugNode__POST_R3__ implements DebugElement {
1470 constructor(nativeNode: Element);
1471 readonly nativeElement: Element | null;
1472 readonly name: string;
1473 /**
1474 * Gets a map of property names to property values for an element.
1475 *
1476 * This map includes:
1477 * - Regular property bindings (e.g. `[id]="id"`)
1478 * - Host property bindings (e.g. `host: { '[id]': "id" }`)
1479 * - Interpolated property bindings (e.g. `id="{{ value }}")
1480 *
1481 * It does not include:
1482 * - input property bindings (e.g. `[myCustomInput]="value"`)
1483 * - attribute bindings (e.g. `[attr.role]="menu"`)
1484 */
1485 readonly properties: {
1486 [key: string]: any;
1487 };
1488 readonly attributes: {
1489 [key: string]: string | null;
1490 };
1491 readonly styles: {
1492 [key: string]: string | null;
1493 };
1494 readonly classes: {
1495 [key: string]: boolean;
1496 };
1497 readonly childNodes: DebugNode[];
1498 readonly children: DebugElement[];
1499 query(predicate: Predicate<DebugElement>): DebugElement;
1500 queryAll(predicate: Predicate<DebugElement>): DebugElement[];
1501 queryAllNodes(predicate: Predicate<DebugNode>): DebugNode[];
1502 triggerEventHandler(eventName: string, eventObj: any): void;
1503}
1504
1505/**
1506 * @publicApi
1507 */
1508export declare class DebugEventListener {
1509 name: string;
1510 callback: Function;
1511 constructor(name: string, callback: Function);
1512}
1513
1514/**
1515 * @publicApi
1516 */
1517export declare interface DebugNode {
1518 readonly listeners: DebugEventListener[];
1519 readonly parent: DebugElement | null;
1520 readonly nativeNode: any;
1521 readonly injector: Injector;
1522 readonly componentInstance: any;
1523 readonly context: any;
1524 readonly references: {
1525 [key: string]: any;
1526 };
1527 readonly providerTokens: any[];
1528}
1529
1530/**
1531 * @publicApi
1532 */
1533export declare const DebugNode: {
1534 new (...args: any[]): DebugNode;
1535};
1536
1537declare class DebugNode__POST_R3__ implements DebugNode {
1538 readonly nativeNode: Node;
1539 constructor(nativeNode: Node);
1540 readonly parent: DebugElement | null;
1541 readonly injector: Injector;
1542 readonly componentInstance: any;
1543 readonly context: any;
1544 readonly listeners: DebugEventListener[];
1545 readonly references: {
1546 [key: string]: any;
1547 };
1548 readonly providerTokens: any[];
1549}
1550
1551declare const DECLARATION_LCONTAINER = 17;
1552
1553declare const DECLARATION_VIEW = 16;
1554
1555/**
1556 * @deprecated v4.0.0 - Should not be part of public API.
1557 * @publicApi
1558 */
1559export declare class DefaultIterableDiffer<V> implements IterableDiffer<V>, IterableChanges<V> {
1560 readonly length: number;
1561 readonly collection: V[] | Iterable<V> | null;
1562 private _linkedRecords;
1563 private _unlinkedRecords;
1564 private _previousItHead;
1565 private _itHead;
1566 private _itTail;
1567 private _additionsHead;
1568 private _additionsTail;
1569 private _movesHead;
1570 private _movesTail;
1571 private _removalsHead;
1572 private _removalsTail;
1573 private _identityChangesHead;
1574 private _identityChangesTail;
1575 private _trackByFn;
1576 constructor(trackByFn?: TrackByFunction<V>);
1577 forEachItem(fn: (record: IterableChangeRecord_<V>) => void): void;
1578 forEachOperation(fn: (item: IterableChangeRecord<V>, previousIndex: number | null, currentIndex: number | null) => void): void;
1579 forEachPreviousItem(fn: (record: IterableChangeRecord_<V>) => void): void;
1580 forEachAddedItem(fn: (record: IterableChangeRecord_<V>) => void): void;
1581 forEachMovedItem(fn: (record: IterableChangeRecord_<V>) => void): void;
1582 forEachRemovedItem(fn: (record: IterableChangeRecord_<V>) => void): void;
1583 forEachIdentityChange(fn: (record: IterableChangeRecord_<V>) => void): void;
1584 diff(collection: NgIterable<V>): DefaultIterableDiffer<V> | null;
1585 onDestroy(): void;
1586 check(collection: NgIterable<V>): boolean;
1587 readonly isDirty: boolean;
1588 private _addToRemovals;
1589}
1590
1591/**
1592 * @deprecated in v8, delete after v10. This API should be used only be generated code, and that
1593 * code should now use ɵɵdefineInjectable instead.
1594 * @publicApi
1595 */
1596export declare const defineInjectable: typeof ɵɵdefineInjectable;
1597
1598declare interface Definition<DF extends DefinitionFactory<any>> {
1599 factory: DF | null;
1600}
1601
1602/**
1603 * Factory for ViewDefinitions/NgModuleDefinitions.
1604 * We use a function so we can reexeute it in case an error happens and use the given logger
1605 * function to log the error from the definition of the node, which is shown in all browser
1606 * logs.
1607 */
1608declare interface DefinitionFactory<D extends Definition<any>> {
1609 (logger: NodeLogger): D;
1610}
1611
1612declare interface DepDef {
1613 flags: ɵDepFlags;
1614 token: any;
1615 tokenKey: string;
1616}
1617
1618/**
1619 * Destroy the existing platform.
1620 *
1621 * @publicApi
1622 */
1623export declare function destroyPlatform(): void;
1624
1625/**
1626 * Directive decorator and metadata.
1627 *
1628 * @Annotation
1629 * @publicApi
1630 */
1631export declare interface Directive {
1632 /**
1633 * The CSS selector that identifies this directive in a template
1634 * and triggers instantiation of the directive.
1635 *
1636 * Declare as one of the following:
1637 *
1638 * - `element-name`: Select by element name.
1639 * - `.class`: Select by class name.
1640 * - `[attribute]`: Select by attribute name.
1641 * - `[attribute=value]`: Select by attribute name and value.
1642 * - `:not(sub_selector)`: Select only if the element does not match the `sub_selector`.
1643 * - `selector1, selector2`: Select if either `selector1` or `selector2` matches.
1644 *
1645 * Angular only allows directives to apply on CSS selectors that do not cross
1646 * element boundaries.
1647 *
1648 * For the following template HTML, a directive with an `input[type=text]` selector,
1649 * would be instantiated only on the `<input type="text">` element.
1650 *
1651 * ```html
1652 * <form>
1653 * <input type="text">
1654 * <input type="radio">
1655 * <form>
1656 * ```
1657 *
1658 */
1659 selector?: string;
1660 /**
1661 * Enumerates the set of data-bound input properties for a directive
1662 *
1663 * Angular automatically updates input properties during change detection.
1664 * The `inputs` property defines a set of `directiveProperty` to `bindingProperty`
1665 * configuration:
1666 *
1667 * - `directiveProperty` specifies the component property where the value is written.
1668 * - `bindingProperty` specifies the DOM property where the value is read from.
1669 *
1670 * When `bindingProperty` is not provided, it is assumed to be equal to `directiveProperty`.
1671 *
1672 * @usageNotes
1673 *
1674 * The following example creates a component with two data-bound properties.
1675 *
1676 * ```typescript
1677 * @Component({
1678 * selector: 'bank-account',
1679 * inputs: ['bankName', 'id: account-id'],
1680 * template: `
1681 * Bank Name: {{bankName}}
1682 * Account Id: {{id}}
1683 * `
1684 * })
1685 * class BankAccount {
1686 * bankName: string;
1687 * id: string;
1688 *
1689 * ```
1690 *
1691 */
1692 inputs?: string[];
1693 /**
1694 * Enumerates the set of event-bound output properties.
1695 *
1696 * When an output property emits an event, an event handler attached to that event
1697 * in the template is invoked.
1698 *
1699 * The `outputs` property defines a set of `directiveProperty` to `bindingProperty`
1700 * configuration:
1701 *
1702 * - `directiveProperty` specifies the component property that emits events.
1703 * - `bindingProperty` specifies the DOM property the event handler is attached to.
1704 *
1705 * @usageNotes
1706 *
1707 * ```typescript
1708 * @Component({
1709 * selector: 'child-dir',
1710 * outputs: [ 'bankNameChange' ]
1711 * template: `<input (input)="bankNameChange.emit($event.target.value)" />`
1712 * })
1713 * class ChildDir {
1714 * bankNameChange: EventEmitter<string> = new EventEmitter<string>();
1715 * }
1716 *
1717 * @Component({
1718 * selector: 'main',
1719 * template: `
1720 * {{ bankName }} <child-dir (bankNameChange)="onBankNameChange($event)"></child-dir>
1721 * `
1722 * })
1723 * class MainComponent {
1724 * bankName: string;
1725 *
1726 * onBankNameChange(bankName: string) {
1727 * this.bankName = bankName;
1728 * }
1729 * }
1730 * ```
1731 *
1732 */
1733 outputs?: string[];
1734 /**
1735 * Configures the [injector](guide/glossary#injector) of this
1736 * directive or component with a [token](guide/glossary#di-token)
1737 * that maps to a [provider](guide/glossary#provider) of a dependency.
1738 */
1739 providers?: Provider[];
1740 /**
1741 * Defines the name that can be used in the template to assign this directive to a variable.
1742 *
1743 * @usageNotes
1744 *
1745 * ```ts
1746 * @Directive({
1747 * selector: 'child-dir',
1748 * exportAs: 'child'
1749 * })
1750 * class ChildDir {
1751 * }
1752 *
1753 * @Component({
1754 * selector: 'main',
1755 * template: `<child-dir #c="child"></child-dir>`
1756 * })
1757 * class MainComponent {
1758 * }
1759 * ```
1760 *
1761 */
1762 exportAs?: string;
1763 /**
1764 * Configures the queries that will be injected into the directive.
1765 *
1766 * Content queries are set before the `ngAfterContentInit` callback is called.
1767 * View queries are set before the `ngAfterViewInit` callback is called.
1768 *
1769 * @usageNotes
1770 *
1771 * The following example shows how queries are defined
1772 * and when their results are available in lifecycle hooks:
1773 *
1774 * ```ts
1775 * @Component({
1776 * selector: 'someDir',
1777 * queries: {
1778 * contentChildren: new ContentChildren(ChildDirective),
1779 * viewChildren: new ViewChildren(ChildDirective)
1780 * },
1781 * template: '<child-directive></child-directive>'
1782 * })
1783 * class SomeDir {
1784 * contentChildren: QueryList<ChildDirective>,
1785 * viewChildren: QueryList<ChildDirective>
1786 *
1787 * ngAfterContentInit() {
1788 * // contentChildren is set
1789 * }
1790 *
1791 * ngAfterViewInit() {
1792 * // viewChildren is set
1793 * }
1794 * }
1795 * ```
1796 *
1797 * @Annotation
1798 */
1799 queries?: {
1800 [key: string]: any;
1801 };
1802 /**
1803 * Maps class properties to host element bindings for properties,
1804 * attributes, and events, using a set of key-value pairs.
1805 *
1806 * Angular automatically checks host property bindings during change detection.
1807 * If a binding changes, Angular updates the directive's host element.
1808 *
1809 * When the key is a property of the host element, the property value is
1810 * the propagated to the specified DOM property.
1811 *
1812 * When the key is a static attribute in the DOM, the attribute value
1813 * is propagated to the specified property in the host element.
1814 *
1815 * For event handling:
1816 * - The key is the DOM event that the directive listens to.
1817 * To listen to global events, add the target to the event name.
1818 * The target can be `window`, `document` or `body`.
1819 * - The value is the statement to execute when the event occurs. If the
1820 * statement evaluates to `false`, then `preventDefault` is applied on the DOM
1821 * event. A handler method can refer to the `$event` local variable.
1822 *
1823 */
1824 host?: {
1825 [key: string]: string;
1826 };
1827 /**
1828 * If true, this directive/component will be skipped by the AOT compiler and so will always be
1829 * compiled using JIT.
1830 *
1831 * This exists to support future Ivy work and has no effect currently.
1832 */
1833 jit?: true;
1834}
1835
1836/**
1837 * Type of the Directive metadata.
1838 *
1839 * @publicApi
1840 */
1841export declare const Directive: DirectiveDecorator;
1842
1843/**
1844 * Type of the Directive decorator / constructor function.
1845 * @publicApi
1846 */
1847export declare interface DirectiveDecorator {
1848 /**
1849 * Decorator that marks a class as an Angular directive.
1850 * You can define your own directives to attach custom behavior to elements in the DOM.
1851 *
1852 * The options provide configuration metadata that determines
1853 * how the directive should be processed, instantiated and used at
1854 * runtime.
1855 *
1856 * Directive classes, like component classes, can implement
1857 * [life-cycle hooks](guide/lifecycle-hooks) to influence their configuration and behavior.
1858 *
1859 *
1860 * @usageNotes
1861 * To define a directive, mark the class with the decorator and provide metadata.
1862 *
1863 * ```ts
1864 * import {Directive} from '@angular/core';
1865 *
1866 * @Directive({
1867 * selector: 'my-directive',
1868 * })
1869 * export class MyDirective {
1870 * ...
1871 * }
1872 * ```
1873 *
1874 * ### Declaring directives
1875 *
1876 * Directives are [declarables](guide/glossary#declarable).
1877 * They must be declared by an NgModule
1878 * in order to be usable in an app.
1879 *
1880 * A directive must belong to exactly one NgModule. Do not re-declare
1881 * a directive imported from another module.
1882 * List the directive class in the `declarations` field of an NgModule.
1883 *
1884 * ```ts
1885 * declarations: [
1886 * AppComponent,
1887 * MyDirective
1888 * ],
1889 * ```
1890 *
1891 * @Annotation
1892 */
1893 (obj: Directive): TypeDecorator;
1894 /**
1895 * See the `Directive` decorator.
1896 */
1897 new (obj: Directive): Directive;
1898}
1899
1900declare interface DirectiveDefFeature {
1901 <T>(directiveDef: ɵDirectiveDef<T>): void;
1902 /**
1903 * Marks a feature as something that {@link InheritDefinitionFeature} will execute
1904 * during inheritance.
1905 *
1906 * NOTE: DO NOT SET IN ROOT OF MODULE! Doing so will result in tree-shakers/bundlers
1907 * identifying the change as a side effect, and the feature will be included in
1908 * every bundle.
1909 */
1910 ngInherit?: true;
1911}
1912
1913declare type DirectiveDefList = (ɵDirectiveDef<any> | ɵComponentDef<any>)[];
1914
1915/**
1916 * Type used for directiveDefs on component definition.
1917 *
1918 * The function is necessary to be able to support forward declarations.
1919 */
1920declare type DirectiveDefListOrFactory = (() => DirectiveDefList) | DirectiveDefList;
1921
1922declare type DirectiveInstance = {};
1923
1924declare type DirectiveTypeList = (ɵDirectiveType<any> | ɵComponentType<any> | Type<any>)[];
1925
1926declare type DirectiveTypesOrFactory = (() => DirectiveTypeList) | DirectiveTypeList;
1927
1928declare interface DisposableFn {
1929 (): void;
1930}
1931
1932/**
1933 * @description
1934 * Hook for manual bootstrapping of the application instead of using bootstrap array in @NgModule
1935 * annotation.
1936 *
1937 * Reference to the current application is provided as a parameter.
1938 *
1939 * See ["Bootstrapping"](guide/bootstrapping) and ["Entry components"](guide/entry-components).
1940 *
1941 * @usageNotes
1942 * ```typescript
1943 * class AppModule implements DoBootstrap {
1944 * ngDoBootstrap(appRef: ApplicationRef) {
1945 * appRef.bootstrap(AppComponent); // Or some other component
1946 * }
1947 * }
1948 * ```
1949 *
1950 * @publicApi
1951 */
1952export declare interface DoBootstrap {
1953 ngDoBootstrap(appRef: ApplicationRef): void;
1954}
1955
1956/**
1957 * A lifecycle hook that invokes a custom change-detection function for a directive,
1958 * in addition to the check performed by the default change-detector.
1959 *
1960 * The default change-detection algorithm looks for differences by comparing
1961 * bound-property values by reference across change detection runs. You can use this
1962 * hook to check for and respond to changes by some other means.
1963 *
1964 * When the default change detector detects changes, it invokes `ngOnChanges()` if supplied,
1965 * regardless of whether you perform additional change detection.
1966 * Typically, you should not use both `DoCheck` and `OnChanges` to respond to
1967 * changes on the same input.
1968 *
1969 * @see `OnChanges`
1970 * @see [Lifecycle Hooks](guide/lifecycle-hooks#onchanges) guide
1971 *
1972 * @usageNotes
1973 * The following snippet shows how a component can implement this interface
1974 * to invoke it own change-detection cycle.
1975 *
1976 * {@example core/ts/metadata/lifecycle_hooks_spec.ts region='DoCheck'}
1977 *
1978 * @publicApi
1979 */
1980export declare interface DoCheck {
1981 /**
1982 * A callback method that performs change-detection, invoked
1983 * after the default change-detector runs.
1984 * See `KeyValueDiffers` and `IterableDiffers` for implementing
1985 * custom change checking for collections.
1986 *
1987 */
1988 ngDoCheck(): void;
1989}
1990
1991/**
1992 * Marks that the next string is for element.
1993 *
1994 * See `I18nMutateOpCodes` documentation.
1995 */
1996declare const ELEMENT_MARKER: ELEMENT_MARKER;
1997
1998declare interface ELEMENT_MARKER {
1999 marker: 'element';
2000}
2001
2002declare interface ElementDef {
2003 name: string | null;
2004 ns: string | null;
2005 /** ns, name, value */
2006 attrs: [string, string, string][] | null;
2007 template: ɵViewDefinition | null;
2008 componentProvider: NodeDef | null;
2009 componentRendererType: RendererType2 | null;
2010 componentView: ViewDefinitionFactory | null;
2011 /**
2012 * visible public providers for DI in the view,
2013 * as see from this element. This does not include private providers.
2014 */
2015 publicProviders: {
2016 [tokenKey: string]: NodeDef;
2017 } | null;
2018 /**
2019 * same as visiblePublicProviders, but also includes private providers
2020 * that are located on this element.
2021 */
2022 allProviders: {
2023 [tokenKey: string]: NodeDef;
2024 } | null;
2025 handleEvent: ElementHandleEventFn | null;
2026}
2027
2028declare interface ElementHandleEventFn {
2029 (view: ViewData, eventName: string, event: any): boolean;
2030}
2031
2032/**
2033 * A wrapper around a native element inside of a View.
2034 *
2035 * An `ElementRef` is backed by a render-specific element. In the browser, this is usually a DOM
2036 * element.
2037 *
2038 * @security Permitting direct access to the DOM can make your application more vulnerable to
2039 * XSS attacks. Carefully review any use of `ElementRef` in your code. For more detail, see the
2040 * [Security Guide](http://g.co/ng/security).
2041 *
2042 * @publicApi
2043 */
2044export declare class ElementRef<T extends any = any> {
2045 /**
2046 * The underlying native element or `null` if direct access to native elements is not supported
2047 * (e.g. when the application runs in a web worker).
2048 *
2049 * <div class="callout is-critical">
2050 * <header>Use with caution</header>
2051 * <p>
2052 * Use this API as the last resort when direct access to DOM is needed. Use templating and
2053 * data-binding provided by Angular instead. Alternatively you can take a look at {@link
2054 * Renderer2}
2055 * which provides API that can safely be used even when direct access to native elements is not
2056 * supported.
2057 * </p>
2058 * <p>
2059 * Relying on direct DOM access creates tight coupling between your application and rendering
2060 * layers which will make it impossible to separate the two and deploy your application into a
2061 * web worker.
2062 * </p>
2063 * </div>
2064 *
2065 */
2066 nativeElement: T;
2067 constructor(nativeElement: T);
2068}
2069
2070/**
2071 * Represents an Angular [view](guide/glossary#view) in a view container.
2072 * An [embedded view](guide/glossary#view-tree) can be referenced from a component
2073 * other than the hosting component whose template defines it, or it can be defined
2074 * independently by a `TemplateRef`.
2075 *
2076 * Properties of elements in a view can change, but the structure (number and order) of elements in
2077 * a view cannot. Change the structure of elements by inserting, moving, or
2078 * removing nested views in a view container.
2079 *
2080 * @see `ViewContainerRef`
2081 *
2082 * @usageNotes
2083 *
2084 * The following template breaks down into two separate `TemplateRef` instances,
2085 * an outer one and an inner one.
2086 *
2087 * ```
2088 * Count: {{items.length}}
2089 * <ul>
2090 * <li *ngFor="let item of items">{{item}}</li>
2091 * </ul>
2092 * ```
2093 *
2094 * This is the outer `TemplateRef`:
2095 *
2096 * ```
2097 * Count: {{items.length}}
2098 * <ul>
2099 * <ng-template ngFor let-item [ngForOf]="items"></ng-template>
2100 * </ul>
2101 * ```
2102 *
2103 * This is the inner `TemplateRef`:
2104 *
2105 * ```
2106 * <li>{{item}}</li>
2107 * ```
2108 *
2109 * The outer and inner `TemplateRef` instances are assembled into views as follows:
2110 *
2111 * ```
2112 * <!-- ViewRef: outer-0 -->
2113 * Count: 2
2114 * <ul>
2115 * <ng-template view-container-ref></ng-template>
2116 * <!-- ViewRef: inner-1 --><li>first</li><!-- /ViewRef: inner-1 -->
2117 * <!-- ViewRef: inner-2 --><li>second</li><!-- /ViewRef: inner-2 -->
2118 * </ul>
2119 * <!-- /ViewRef: outer-0 -->
2120 * ```
2121 * @publicApi
2122 */
2123export declare abstract class EmbeddedViewRef<C> extends ViewRef {
2124 /**
2125 * The context for this view, inherited from the anchor element.
2126 */
2127 abstract readonly context: C;
2128 /**
2129 * The root nodes for this embedded view.
2130 */
2131 abstract readonly rootNodes: any[];
2132}
2133
2134/**
2135 * Disable Angular's development mode, which turns off assertions and other
2136 * checks within the framework.
2137 *
2138 * One important assertion this disables verifies that a change detection pass
2139 * does not result in additional changes to any bindings (also known as
2140 * unidirectional data flow).
2141 *
2142 * @publicApi
2143 */
2144export declare function enableProdMode(): void;
2145
2146
2147/**
2148 * Provides a hook for centralized exception handling.
2149 *
2150 * The default implementation of `ErrorHandler` prints error messages to the `console`. To
2151 * intercept error handling, write a custom exception handler that replaces this default as
2152 * appropriate for your app.
2153 *
2154 * @usageNotes
2155 * ### Example
2156 *
2157 * ```
2158 * class MyErrorHandler implements ErrorHandler {
2159 * handleError(error) {
2160 * // do something with the exception
2161 * }
2162 * }
2163 *
2164 * @NgModule({
2165 * providers: [{provide: ErrorHandler, useClass: MyErrorHandler}]
2166 * })
2167 * class MyModule {}
2168 * ```
2169 *
2170 * @publicApi
2171 */
2172export declare class ErrorHandler {
2173 handleError(error: any): void;
2174}
2175
2176/**
2177 * Use in components with the `@Output` directive to emit custom events
2178 * synchronously or asynchronously, and register handlers for those events
2179 * by subscribing to an instance.
2180 *
2181 * @usageNotes
2182 *
2183 * Extends
2184 * [RxJS `Subject`](https://rxjs.dev/api/index/class/Subject)
2185 * for Angular by adding the `emit()` method.
2186 *
2187 * In the following example, a component defines two output properties
2188 * that create event emitters. When the title is clicked, the emitter
2189 * emits an open or close event to toggle the current visibility state.
2190 *
2191 * ```html
2192 * @Component({
2193 * selector: 'zippy',
2194 * template: `
2195 * <div class="zippy">
2196 * <div (click)="toggle()">Toggle</div>
2197 * <div [hidden]="!visible">
2198 * <ng-content></ng-content>
2199 * </div>
2200 * </div>`})
2201 * export class Zippy {
2202 * visible: boolean = true;
2203 * @Output() open: EventEmitter<any> = new EventEmitter();
2204 * @Output() close: EventEmitter<any> = new EventEmitter();
2205 *
2206 * toggle() {
2207 * this.visible = !this.visible;
2208 * if (this.visible) {
2209 * this.open.emit(null);
2210 * } else {
2211 * this.close.emit(null);
2212 * }
2213 * }
2214 * }
2215 * ```
2216 *
2217 * Access the event object with the `$event` argument passed to the output event
2218 * handler:
2219 *
2220 * ```html
2221 * <zippy (open)="onOpen($event)" (close)="onClose($event)"></zippy>
2222 * ```
2223 *
2224 * @see [Observables in Angular](guide/observables-in-angular)
2225 * @publicApi
2226 */
2227export declare class EventEmitter<T extends any> extends Subject<T> {
2228 /**
2229 * Internal
2230 */
2231 __isAsync: boolean;
2232 /**
2233 * Creates an instance of this class that can
2234 * deliver events synchronously or asynchronously.
2235 *
2236 * @param isAsync When true, deliver events asynchronously.
2237 *
2238 */
2239 constructor(isAsync?: boolean);
2240 /**
2241 * Emits an event containing a given value.
2242 * @param value The value to emit.
2243 */
2244 emit(value?: T): void;
2245 /**
2246 * Registers handlers for events emitted by this instance.
2247 * @param generatorOrNext When supplied, a custom handler for emitted events.
2248 * @param error When supplied, a custom handler for an error notification
2249 * from this emitter.
2250 * @param complete When supplied, a custom handler for a completion
2251 * notification from this emitter.
2252 */
2253 subscribe(generatorOrNext?: any, error?: any, complete?: any): Subscription;
2254}
2255
2256/**
2257 * Configures the `Injector` to return a value of another `useExisting` token.
2258 *
2259 * @see ["Dependency Injection Guide"](guide/dependency-injection).
2260 *
2261 * @usageNotes
2262 *
2263 * {@example core/di/ts/provider_spec.ts region='ExistingProvider'}
2264 *
2265 * ### Multi-value example
2266 *
2267 * {@example core/di/ts/provider_spec.ts region='MultiProviderAspect'}
2268 *
2269 * @publicApi
2270 */
2271export declare interface ExistingProvider extends ExistingSansProvider {
2272 /**
2273 * An injection token. Typically an instance of `Type` or `InjectionToken`, but can be `any`.
2274 */
2275 provide: any;
2276 /**
2277 * When true, injector returns an array of instances. This is useful to allow multiple
2278 * providers spread across many files to provide configuration information to a common token.
2279 */
2280 multi?: boolean;
2281}
2282
2283/**
2284 * Configures the `Injector` to return a value of another `useExisting` token.
2285 *
2286 * @see `ExistingProvider`
2287 * @see ["Dependency Injection Guide"](guide/dependency-injection).
2288 *
2289 * @publicApi
2290 */
2291export declare interface ExistingSansProvider {
2292 /**
2293 * Existing `token` to return. (Equivalent to `injector.get(useExisting)`)
2294 */
2295 useExisting: any;
2296}
2297
2298/**
2299 * Set of instructions used to process host bindings efficiently.
2300 *
2301 * See VIEW_DATA.md for more information.
2302 */
2303declare interface ExpandoInstructions extends Array<number | HostBindingsFunction<any> | null> {
2304}
2305
2306/**
2307 * Definition of what a factory function should look like.
2308 */
2309declare type FactoryFn<T> = {
2310 /**
2311 * Subclasses without an explicit constructor call through to the factory of their base
2312 * definition, providing it with their own constructor to instantiate.
2313 */
2314 <U extends T>(t: Type<U>): U;
2315 /**
2316 * If no constructor to instantiate is provided, an instance of type T itself is created.
2317 */
2318 (t?: undefined): T;
2319};
2320
2321/**
2322 * Configures the `Injector` to return a value by invoking a `useFactory` function.
2323 * @see ["Dependency Injection Guide"](guide/dependency-injection).
2324 *
2325 * @usageNotes
2326 *
2327 * {@example core/di/ts/provider_spec.ts region='FactoryProvider'}
2328 *
2329 * Dependencies can also be marked as optional:
2330 *
2331 * {@example core/di/ts/provider_spec.ts region='FactoryProviderOptionalDeps'}
2332 *
2333 * ### Multi-value example
2334 *
2335 * {@example core/di/ts/provider_spec.ts region='MultiProviderAspect'}
2336 *
2337 * @publicApi
2338 */
2339export declare interface FactoryProvider extends FactorySansProvider {
2340 /**
2341 * An injection token. (Typically an instance of `Type` or `InjectionToken`, but can be `any`).
2342 */
2343 provide: any;
2344 /**
2345 * When true, injector returns an array of instances. This is useful to allow multiple
2346 * providers spread across many files to provide configuration information to a common token.
2347 */
2348 multi?: boolean;
2349}
2350
2351/**
2352 * Configures the `Injector` to return a value by invoking a `useFactory` function.
2353 *
2354 * @see `FactoryProvider`
2355 * @see ["Dependency Injection Guide"](guide/dependency-injection).
2356 *
2357 * @publicApi
2358 */
2359export declare interface FactorySansProvider {
2360 /**
2361 * A function to invoke to create a value for this `token`. The function is invoked with
2362 * resolved values of `token`s in the `deps` field.
2363 */
2364 useFactory: Function;
2365 /**
2366 * A list of `token`s to be resolved by the injector. The list of values is then
2367 * used as arguments to the `useFactory` function.
2368 */
2369 deps?: any[];
2370}
2371
2372declare const FLAGS = 2;
2373
2374/**
2375 * Allows to refer to references which are not yet defined.
2376 *
2377 * For instance, `forwardRef` is used when the `token` which we need to refer to for the purposes of
2378 * DI is declared, but not yet defined. It is also used when the `token` which we use when creating
2379 * a query is not yet defined.
2380 *
2381 * @usageNotes
2382 * ### Example
2383 * {@example core/di/ts/forward_ref/forward_ref_spec.ts region='forward_ref'}
2384 * @publicApi
2385 */
2386export declare function forwardRef(forwardRefFn: ForwardRefFn): Type<any>;
2387
2388/**
2389 * An interface that a function passed into {@link forwardRef} has to implement.
2390 *
2391 * @usageNotes
2392 * ### Example
2393 *
2394 * {@example core/di/ts/forward_ref/forward_ref_spec.ts region='forward_ref_fn'}
2395 * @publicApi
2396 */
2397export declare interface ForwardRefFn {
2398 (): any;
2399}
2400
2401/**
2402 * @publicApi
2403 */
2404export declare const getDebugNode: (nativeNode: any) => DebugNode | null;
2405
2406/**
2407 * Returns the NgModuleFactory with the given id, if it exists and has been loaded.
2408 * Factories for modules that do not specify an `id` cannot be retrieved. Throws if the module
2409 * cannot be found.
2410 * @publicApi
2411 */
2412export declare const getModuleFactory: (id: string) => NgModuleFactory<any>;
2413
2414/**
2415 * Returns the current platform.
2416 *
2417 * @publicApi
2418 */
2419export declare function getPlatform(): PlatformRef | null;
2420
2421/**
2422 * Adapter interface for retrieving the `Testability` service associated for a
2423 * particular context.
2424 *
2425 * @publicApi
2426 */
2427export declare interface GetTestability {
2428 addToWindow(registry: TestabilityRegistry): void;
2429 findTestabilityInTree(registry: TestabilityRegistry, elem: any, findInAncestors: boolean): Testability | null;
2430}
2431
2432declare type GlobalTargetName = 'document' | 'window' | 'body';
2433
2434declare type GlobalTargetResolver = (element: any) => {
2435 name: GlobalTargetName;
2436 target: EventTarget;
2437};
2438
2439/**
2440 * Array of hooks that should be executed for a view and their directive indices.
2441 *
2442 * For each node of the view, the following data is stored:
2443 * 1) Node index (optional)
2444 * 2) A series of number/function pairs where:
2445 * - even indices are directive indices
2446 * - odd indices are hook functions
2447 *
2448 * Special cases:
2449 * - a negative directive index flags an init hook (ngOnInit, ngAfterContentInit, ngAfterViewInit)
2450 */
2451declare type HookData = (number | (() => void))[];
2452
2453declare const HOST = 0;
2454
2455/**
2456 * Type of the Host metadata.
2457 *
2458 * @publicApi
2459 */
2460export declare interface Host {
2461}
2462
2463/**
2464 * Host decorator and metadata.
2465 *
2466 * @Annotation
2467 * @publicApi
2468 */
2469export declare const Host: HostDecorator;
2470
2471/**
2472 * Type of the HostBinding metadata.
2473 *
2474 * @publicApi
2475 */
2476export declare interface HostBinding {
2477 /**
2478 * The DOM property that is bound to a data property.
2479 */
2480 hostPropertyName?: string;
2481}
2482
2483/**
2484 * @Annotation
2485 * @publicApi
2486 */
2487export declare const HostBinding: HostBindingDecorator;
2488
2489/**
2490 * Type of the HostBinding decorator / constructor function.
2491 *
2492 * @publicApi
2493 */
2494export declare interface HostBindingDecorator {
2495 /**
2496 * Decorator that marks a DOM property as a host-binding property and supplies configuration
2497 * metadata.
2498 * Angular automatically checks host property bindings during change detection, and
2499 * if a binding changes it updates the host element of the directive.
2500 *
2501 * @usageNotes
2502 *
2503 * The following example creates a directive that sets the `valid` and `invalid`
2504 * properties on the DOM element that has an `ngModel` directive on it.
2505 *
2506 * ```typescript
2507 * @Directive({selector: '[ngModel]'})
2508 * class NgModelStatus {
2509 * constructor(public control: NgModel) {}
2510 * @HostBinding('class.valid') get valid() { return this.control.valid; }
2511 * @HostBinding('class.invalid') get invalid() { return this.control.invalid; }
2512 * }
2513 *
2514 * @Component({
2515 * selector: 'app',
2516 * template: `<input [(ngModel)]="prop">`,
2517 * })
2518 * class App {
2519 * prop;
2520 * }
2521 * ```
2522 *
2523 */
2524 (hostPropertyName?: string): any;
2525 new (hostPropertyName?: string): any;
2526}
2527
2528declare type HostBindingsFunction<T> = <U extends T>(rf: ɵRenderFlags, ctx: U, elementIndex: number) => void;
2529
2530/**
2531 * Type of the Host decorator / constructor function.
2532 *
2533 * @publicApi
2534 */
2535export declare interface HostDecorator {
2536 /**
2537 * Parameter decorator on a view-provider parameter of a class constructor
2538 * that tells the DI framework to resolve the view by checking injectors of child
2539 * elements, and stop when reaching the host element of the current component.
2540 *
2541 * For an extended example, see
2542 * ["Dependency Injection Guide"](guide/dependency-injection-in-action#optional).
2543 *
2544 * @usageNotes
2545 *
2546 * The following shows use with the `@Optional` decorator, and allows for a null result.
2547 *
2548 * <code-example path="core/di/ts/metadata_spec.ts" region="Host">
2549 * </code-example>
2550 */
2551 (): any;
2552 new (): Host;
2553}
2554
2555/** See CreateComponentOptions.hostFeatures */
2556declare type HostFeature = (<T>(component: T, componentDef: ɵComponentDef<T>) => void);
2557
2558/**
2559 * Type of the HostListener metadata.
2560 *
2561 * @publicApi
2562 */
2563export declare interface HostListener {
2564 /**
2565 * The DOM event to listen for.
2566 */
2567 eventName?: string;
2568 /**
2569 * A set of arguments to pass to the handler method when the event occurs.
2570 */
2571 args?: string[];
2572}
2573
2574/**
2575 * Decorator that binds a DOM event to a host listener and supplies configuration metadata.
2576 * Angular invokes the supplied handler method when the host element emits the specified event,
2577 * and updates the bound element with the result.
2578 *
2579 * If the handler method returns false, applies `preventDefault` on the bound element.
2580 *
2581 * @usageNotes
2582 *
2583 * The following example declares a directive
2584 * that attaches a click listener to a button and counts clicks.
2585 *
2586 * ```ts
2587 * @Directive({selector: 'button[counting]'})
2588 * class CountClicks {
2589 * numberOfClicks = 0;
2590 *
2591 * @HostListener('click', ['$event.target'])
2592 * onClick(btn) {
2593 * console.log('button', btn, 'number of clicks:', this.numberOfClicks++);
2594 * }
2595 * }
2596 *
2597 * @Component({
2598 * selector: 'app',
2599 * template: '<button counting>Increment</button>',
2600 * })
2601 * class App {}
2602 * ```
2603 *
2604 * @Annotation
2605 * @publicApi
2606 */
2607export declare const HostListener: HostListenerDecorator;
2608
2609/**
2610 * Type of the HostListener decorator / constructor function.
2611 *
2612 * @publicApi
2613 */
2614export declare interface HostListenerDecorator {
2615 /**
2616 * Decorator that declares a DOM event to listen for,
2617 * and provides a handler method to run when that event occurs.
2618 */
2619 (eventName: string, args?: string[]): any;
2620 new (eventName: string, args?: string[]): any;
2621}
2622
2623declare interface I18nLocalizeOptions {
2624 translations: {
2625 [key: string]: string;
2626 };
2627}
2628
2629/**
2630 * Array storing OpCode for dynamically creating `i18n` blocks.
2631 *
2632 * Example:
2633 * ```ts
2634 * <I18nCreateOpCode>[
2635 * // For adding text nodes
2636 * // ---------------------
2637 * // Equivalent to:
2638 * // const node = lView[index++] = document.createTextNode('abc');
2639 * // lView[1].insertBefore(node, lView[2]);
2640 * 'abc', 1 << SHIFT_PARENT | 2 << SHIFT_REF | InsertBefore,
2641 *
2642 * // Equivalent to:
2643 * // const node = lView[index++] = document.createTextNode('xyz');
2644 * // lView[1].appendChild(node);
2645 * 'xyz', 1 << SHIFT_PARENT | AppendChild,
2646 *
2647 * // For adding element nodes
2648 * // ---------------------
2649 * // Equivalent to:
2650 * // const node = lView[index++] = document.createElement('div');
2651 * // lView[1].insertBefore(node, lView[2]);
2652 * ELEMENT_MARKER, 'div', 1 << SHIFT_PARENT | 2 << SHIFT_REF | InsertBefore,
2653 *
2654 * // Equivalent to:
2655 * // const node = lView[index++] = document.createElement('div');
2656 * // lView[1].appendChild(node);
2657 * ELEMENT_MARKER, 'div', 1 << SHIFT_PARENT | AppendChild,
2658 *
2659 * // For adding comment nodes
2660 * // ---------------------
2661 * // Equivalent to:
2662 * // const node = lView[index++] = document.createComment('');
2663 * // lView[1].insertBefore(node, lView[2]);
2664 * COMMENT_MARKER, '', 1 << SHIFT_PARENT | 2 << SHIFT_REF | InsertBefore,
2665 *
2666 * // Equivalent to:
2667 * // const node = lView[index++] = document.createComment('');
2668 * // lView[1].appendChild(node);
2669 * COMMENT_MARKER, '', 1 << SHIFT_PARENT | AppendChild,
2670 *
2671 * // For moving existing nodes to a different location
2672 * // --------------------------------------------------
2673 * // Equivalent to:
2674 * // const node = lView[1];
2675 * // lView[2].insertBefore(node, lView[3]);
2676 * 1 << SHIFT_REF | Select, 2 << SHIFT_PARENT | 3 << SHIFT_REF | InsertBefore,
2677 *
2678 * // Equivalent to:
2679 * // const node = lView[1];
2680 * // lView[2].appendChild(node);
2681 * 1 << SHIFT_REF | Select, 2 << SHIFT_PARENT | AppendChild,
2682 *
2683 * // For removing existing nodes
2684 * // --------------------------------------------------
2685 * // const node = lView[1];
2686 * // removeChild(tView.data(1), node, lView);
2687 * 1 << SHIFT_REF | Remove,
2688 *
2689 * // For writing attributes
2690 * // --------------------------------------------------
2691 * // const node = lView[1];
2692 * // node.setAttribute('attr', 'value');
2693 * 1 << SHIFT_REF | Select, 'attr', 'value'
2694 * // NOTE: Select followed by two string (vs select followed by OpCode)
2695 * ];
2696 * ```
2697 * NOTE:
2698 * - `index` is initial location where the extra nodes should be stored in the EXPANDO section of
2699 * `LVIewData`.
2700 *
2701 * See: `applyI18nCreateOpCodes`;
2702 */
2703declare interface I18nMutateOpCodes extends Array<number | string | ELEMENT_MARKER | COMMENT_MARKER | null> {
2704}
2705
2706/**
2707 * Stores DOM operations which need to be applied to update DOM render tree due to changes in
2708 * expressions.
2709 *
2710 * The basic idea is that `i18nExp` OpCodes capture expression changes and update a change
2711 * mask bit. (Bit 1 for expression 1, bit 2 for expression 2 etc..., bit 32 for expression 32 and
2712 * higher.) The OpCodes then compare its own change mask against the expression change mask to
2713 * determine if the OpCodes should execute.
2714 *
2715 * These OpCodes can be used by both the i18n block as well as ICU sub-block.
2716 *
2717 * ## Example
2718 *
2719 * Assume
2720 * ```ts
2721 * if (rf & RenderFlags.Update) {
2722 * i18nExp(bind(ctx.exp1)); // If changed set mask bit 1
2723 * i18nExp(bind(ctx.exp2)); // If changed set mask bit 2
2724 * i18nExp(bind(ctx.exp3)); // If changed set mask bit 3
2725 * i18nExp(bind(ctx.exp4)); // If changed set mask bit 4
2726 * i18nApply(0); // Apply all changes by executing the OpCodes.
2727 * }
2728 * ```
2729 * We can assume that each call to `i18nExp` sets an internal `changeMask` bit depending on the
2730 * index of `i18nExp`.
2731 *
2732 * ### OpCodes
2733 * ```ts
2734 * <I18nUpdateOpCodes>[
2735 * // The following OpCodes represent: `<div i18n-title="pre{{exp1}}in{{exp2}}post">`
2736 * // If `changeMask & 0b11`
2737 * // has changed then execute update OpCodes.
2738 * // has NOT changed then skip `7` values and start processing next OpCodes.
2739 * 0b11, 7,
2740 * // Concatenate `newValue = 'pre'+lView[bindIndex-4]+'in'+lView[bindIndex-3]+'post';`.
2741 * 'pre', -4, 'in', -3, 'post',
2742 * // Update attribute: `elementAttribute(1, 'title', sanitizerFn(newValue));`
2743 * 1 << SHIFT_REF | Attr, 'title', sanitizerFn,
2744 *
2745 * // The following OpCodes represent: `<div i18n>Hello {{exp3}}!">`
2746 * // If `changeMask & 0b100`
2747 * // has changed then execute update OpCodes.
2748 * // has NOT changed then skip `4` values and start processing next OpCodes.
2749 * 0b100, 4,
2750 * // Concatenate `newValue = 'Hello ' + lView[bindIndex -2] + '!';`.
2751 * 'Hello ', -2, '!',
2752 * // Update text: `lView[1].textContent = newValue;`
2753 * 1 << SHIFT_REF | Text,
2754 *
2755 * // The following OpCodes represent: `<div i18n>{exp4, plural, ... }">`
2756 * // If `changeMask & 0b1000`
2757 * // has changed then execute update OpCodes.
2758 * // has NOT changed then skip `4` values and start processing next OpCodes.
2759 * 0b1000, 4,
2760 * // Concatenate `newValue = lView[bindIndex -1];`.
2761 * -1,
2762 * // Switch ICU: `icuSwitchCase(lView[1], 0, newValue);`
2763 * 0 << SHIFT_ICU | 1 << SHIFT_REF | IcuSwitch,
2764 *
2765 * // Note `changeMask & -1` is always true, so the IcuUpdate will always execute.
2766 * -1, 1,
2767 * // Update ICU: `icuUpdateCase(lView[1], 0);`
2768 * 0 << SHIFT_ICU | 1 << SHIFT_REF | IcuUpdate,
2769 *
2770 * ];
2771 * ```
2772 *
2773 */
2774declare interface I18nUpdateOpCodes extends Array<string | number | SanitizerFn | null> {
2775}
2776
2777/**
2778 * Defines the ICU type of `select` or `plural`
2779 */
2780declare const enum IcuType {
2781 select = 0,
2782 plural = 1
2783}
2784
2785/**
2786 * This array contains information about input properties that
2787 * need to be set once from attribute data. It's ordered by
2788 * directive index (relative to element) so it's simple to
2789 * look up a specific directive's initial input data.
2790 *
2791 * Within each sub-array:
2792 *
2793 * i+0: attribute name
2794 * i+1: minified/internal input name
2795 * i+2: initial value
2796 *
2797 * If a directive on a node does not have any input properties
2798 * that should be set from attributes, its index is set to null
2799 * to avoid a sparse array.
2800 *
2801 * e.g. [null, ['role-min', 'minified-input', 'button']]
2802 */
2803declare type InitialInputData = (InitialInputs | null)[];
2804
2805/**
2806 * Used by InitialInputData to store input properties
2807 * that should be set once from attributes.
2808 *
2809 * i+0: attribute name
2810 * i+1: minified/internal input name
2811 * i+2: initial value
2812 *
2813 * e.g. ['role-min', 'minified-input', 'button']
2814 */
2815declare type InitialInputs = string[];
2816
2817/**
2818 * Type of the Inject metadata.
2819 *
2820 * @publicApi
2821 */
2822export declare interface Inject {
2823 /**
2824 * A [DI token](guide/glossary#di-token) that maps to the dependency to be injected.
2825 */
2826 token: any;
2827}
2828
2829/**
2830 * Inject decorator and metadata.
2831 *
2832 * @Annotation
2833 * @publicApi
2834 */
2835export declare const Inject: InjectDecorator;
2836
2837/**
2838 * Injects a token from the currently active injector.
2839 *
2840 * Must be used in the context of a factory function such as one defined for an
2841 * `InjectionToken`. Throws an error if not called from such a context.
2842 *
2843 * Within such a factory function, using this function to request injection of a dependency
2844 * is faster and more type-safe than providing an additional array of dependencies
2845 * (as has been common with `useFactory` providers).
2846 *
2847 * @param token The injection token for the dependency to be injected.
2848 * @param flags Optional flags that control how injection is executed.
2849 * The flags correspond to injection strategies that can be specified with
2850 * parameter decorators `@Host`, `@Self`, `@SkipSef`, and `@Optional`.
2851 * @returns True if injection is successful, null otherwise.
2852 *
2853 * @usageNotes
2854 *
2855 * ### Example
2856 *
2857 * {@example core/di/ts/injector_spec.ts region='ShakableInjectionToken'}
2858 *
2859 * @publicApi
2860 */
2861export declare const inject: typeof ɵɵinject;
2862
2863/**
2864 * Type of the Injectable metadata.
2865 *
2866 * @publicApi
2867 */
2868export declare interface Injectable {
2869 /**
2870 * Determines which injectors will provide the injectable,
2871 * by either associating it with an @NgModule or other `InjectorType`,
2872 * or by specifying that this injectable should be provided in the
2873 * 'root' injector, which will be the application-level injector in most apps.
2874 */
2875 providedIn?: Type<any> | 'root' | null;
2876}
2877
2878/**
2879 * Injectable decorator and metadata.
2880 *
2881 * @Annotation
2882 * @publicApi
2883 */
2884export declare const Injectable: InjectableDecorator;
2885
2886/**
2887 * Type of the Injectable decorator / constructor function.
2888 *
2889 * @publicApi
2890 */
2891export declare interface InjectableDecorator {
2892 /**
2893 * Decorator that marks a class as available to be
2894 * provided and injected as a dependency.
2895 *
2896 * @see [Introduction to Services and DI](guide/architecture-services)
2897 * @see [Dependency Injection Guide](guide/dependency-injection)
2898 *
2899 * @usageNotes
2900 *
2901 * Marking a class with `@Injectable` ensures that the compiler
2902 * will generate the necessary metadata to create the class's
2903 * dependencies when the class is injected.
2904 *
2905 * The following example shows how a service class is properly
2906 * marked so that a supporting service can be injected upon creation.
2907 *
2908 * <code-example path="core/di/ts/metadata_spec.ts" region="Injectable"></code-example>
2909 *
2910 */
2911 (): TypeDecorator;
2912 (options?: {
2913 providedIn: Type<any> | 'root' | null;
2914 } & InjectableProvider): TypeDecorator;
2915 new (): Injectable;
2916 new (options?: {
2917 providedIn: Type<any> | 'root' | null;
2918 } & InjectableProvider): Injectable;
2919}
2920
2921/**
2922 * Injectable providers used in `@Injectable` decorator.
2923 *
2924 * @publicApi
2925 */
2926export declare type InjectableProvider = ValueSansProvider | ExistingSansProvider | StaticClassSansProvider | ConstructorSansProvider | FactorySansProvider | ClassSansProvider;
2927
2928/**
2929 * A `Type` which has an `InjectableDef` static field.
2930 *
2931 * `InjectableDefType`s contain their own Dependency Injection metadata and are usable in an
2932 * `InjectorDef`-based `StaticInjector.
2933 *
2934 * @publicApi
2935 */
2936export declare interface InjectableType<T> extends Type<T> {
2937 /**
2938 * Opaque type whose structure is highly version dependent. Do not rely on any properties.
2939 */
2940 ngInjectableDef: never;
2941}
2942
2943/** Returns a ChangeDetectorRef (a.k.a. a ViewRef) */
2944declare function injectChangeDetectorRef(isPipe?: boolean): ChangeDetectorRef;
2945
2946
2947/**
2948 * Type of the Inject decorator / constructor function.
2949 *
2950 * @publicApi
2951 */
2952export declare interface InjectDecorator {
2953 /**
2954 * Parameter decorator on a dependency parameter of a class constructor
2955 * that specifies a custom provider of the dependency.
2956 *
2957 * Learn more in the ["Dependency Injection Guide"](guide/dependency-injection).
2958 *
2959 * @usageNotes
2960 * The following example shows a class constructor that specifies a
2961 * custom provider of a dependency using the parameter decorator.
2962 *
2963 * When `@Inject()` is not present, the injector uses the type annotation of the
2964 * parameter as the provider.
2965 *
2966 * <code-example path="core/di/ts/metadata_spec.ts" region="InjectWithoutDecorator">
2967 * </code-example>
2968 */
2969 (token: any): any;
2970 new (token: any): Inject;
2971}
2972
2973/**
2974 * Creates an ElementRef from the most recent node.
2975 *
2976 * @returns The ElementRef instance to use
2977 */
2978declare function injectElementRef(ElementRefToken: typeof ElementRef): ElementRef;
2979
2980
2981/**
2982 * Injection flags for DI.
2983 *
2984 * @publicApi
2985 */
2986export declare enum InjectFlags {
2987 /** Check self and check parent injector if needed */
2988 Default = 0,
2989 /**
2990 * Specifies that an injector should retrieve a dependency from any injector until reaching the
2991 * host element of the current component. (Only used with Element Injector)
2992 */
2993 Host = 1,
2994 /** Don't ascend to ancestors of the node requesting injection. */
2995 Self = 2,
2996 /** Skip the node that is requesting injection. */
2997 SkipSelf = 4,
2998 /** Inject `defaultValue` instead if token not found. */
2999 Optional = 8
3000}
3001
3002/**
3003 * Creates a token that can be used in a DI Provider.
3004 *
3005 * Use an `InjectionToken` whenever the type you are injecting is not reified (does not have a
3006 * runtime representation) such as when injecting an interface, callable type, array or
3007 * parameterized type.
3008 *
3009 * `InjectionToken` is parameterized on `T` which is the type of object which will be returned by
3010 * the `Injector`. This provides additional level of type safety.
3011 *
3012 * ```
3013 * interface MyInterface {...}
3014 * var myInterface = injector.get(new InjectionToken<MyInterface>('SomeToken'));
3015 * // myInterface is inferred to be MyInterface.
3016 * ```
3017 *
3018 * When creating an `InjectionToken`, you can optionally specify a factory function which returns
3019 * (possibly by creating) a default value of the parameterized type `T`. This sets up the
3020 * `InjectionToken` using this factory as a provider as if it was defined explicitly in the
3021 * application's root injector. If the factory function, which takes zero arguments, needs to inject
3022 * dependencies, it can do so using the `inject` function. See below for an example.
3023 *
3024 * Additionally, if a `factory` is specified you can also specify the `providedIn` option, which
3025 * overrides the above behavior and marks the token as belonging to a particular `@NgModule`. As
3026 * mentioned above, `'root'` is the default value for `providedIn`.
3027 *
3028 * @usageNotes
3029 * ### Basic Example
3030 *
3031 * ### Plain InjectionToken
3032 *
3033 * {@example core/di/ts/injector_spec.ts region='InjectionToken'}
3034 *
3035 * ### Tree-shakable InjectionToken
3036 *
3037 * {@example core/di/ts/injector_spec.ts region='ShakableInjectionToken'}
3038 *
3039 *
3040 * @publicApi
3041 */
3042export declare class InjectionToken<T> {
3043 protected _desc: string;
3044 readonly ngInjectableDef: never | undefined;
3045 constructor(_desc: string, options?: {
3046 providedIn?: Type<any> | 'root' | null;
3047 factory: () => T;
3048 });
3049 toString(): string;
3050}
3051
3052/**
3053 * An InjectionToken that gets the current `Injector` for `createInjector()`-style injectors.
3054 *
3055 * Requesting this token instead of `Injector` allows `StaticInjector` to be tree-shaken from a
3056 * project.
3057 *
3058 * @publicApi
3059 */
3060export declare const INJECTOR: InjectionToken<Injector>;
3061
3062/**
3063 * Concrete injectors implement this interface.
3064 *
3065 * For more details, see the ["Dependency Injection Guide"](guide/dependency-injection).
3066 *
3067 * @usageNotes
3068 * ### Example
3069 *
3070 * {@example core/di/ts/injector_spec.ts region='Injector'}
3071 *
3072 * `Injector` returns itself when given `Injector` as a token:
3073 *
3074 * {@example core/di/ts/injector_spec.ts region='injectInjector'}
3075 *
3076 * @publicApi
3077 */
3078export declare abstract class Injector {
3079 static THROW_IF_NOT_FOUND: Object;
3080 static NULL: Injector;
3081 /**
3082 * Retrieves an instance from the injector based on the provided token.
3083 * @returns The instance from the injector if defined, otherwise the `notFoundValue`.
3084 * @throws When the `notFoundValue` is `undefined` or `Injector.THROW_IF_NOT_FOUND`.
3085 */
3086 abstract get<T>(token: Type<T> | InjectionToken<T>, notFoundValue?: T, flags?: InjectFlags): T;
3087 /**
3088 * @deprecated from v4.0.0 use Type<T> or InjectionToken<T>
3089 * @suppress {duplicate}
3090 */
3091 abstract get(token: any, notFoundValue?: any): any;
3092 /**
3093 * @deprecated from v5 use the new signature Injector.create(options)
3094 */
3095 static create(providers: StaticProvider[], parent?: Injector): Injector;
3096 static create(options: {
3097 providers: StaticProvider[];
3098 parent?: Injector;
3099 name?: string;
3100 }): Injector;
3101 /** @nocollapse */
3102 static ngInjectableDef: never;
3103}
3104
3105declare const INJECTOR_2 = 10;
3106
3107/**
3108 * A type which has an `InjectorDef` static field.
3109 *
3110 * `InjectorDefTypes` can be used to configure a `StaticInjector`.
3111 *
3112 * @publicApi
3113 */
3114export declare interface InjectorType<T> extends Type<T> {
3115 /**
3116 * Opaque type whose structure is highly version dependent. Do not rely on any properties.
3117 */
3118 ngInjectorDef: never;
3119}
3120
3121/**
3122 * Describes the `InjectorDef` equivalent of a `ModuleWithProviders`, an `InjectorDefType` with an
3123 * associated array of providers.
3124 *
3125 * Objects of this type can be listed in the imports section of an `InjectorDef`.
3126 *
3127 * NOTE: This is a private type and should not be exported
3128 */
3129declare interface InjectorTypeWithProviders<T> {
3130 ngModule: InjectorType<T>;
3131 providers?: (Type<any> | ValueProvider | ExistingProvider | FactoryProvider | ConstructorProvider | StaticClassProvider | ClassProvider | any[])[];
3132}
3133
3134/** Injects a Renderer2 for the current component. */
3135declare function injectRenderer2(): Renderer2;
3136
3137/**
3138 * Creates a TemplateRef given a node.
3139 *
3140 * @returns The TemplateRef instance to use
3141 */
3142declare function injectTemplateRef<T>(TemplateRefToken: typeof TemplateRef, ElementRefToken: typeof ElementRef): TemplateRef<T> | null;
3143
3144/**
3145 * Creates a ViewContainerRef and stores it on the injector. Or, if the ViewContainerRef
3146 * already exists, retrieves the existing ViewContainerRef.
3147 *
3148 * @returns The ViewContainerRef instance to use
3149 */
3150declare function injectViewContainerRef(ViewContainerRefToken: typeof ViewContainerRef, ElementRefToken: typeof ElementRef): ViewContainerRef;
3151
3152/**
3153 * Type of metadata for an `Input` property.
3154 *
3155 * @publicApi
3156 */
3157export declare interface Input {
3158 /**
3159 * The name of the DOM property to which the input property is bound.
3160 */
3161 bindingPropertyName?: string;
3162}
3163
3164/**
3165 * @Annotation
3166 * @publicApi
3167 */
3168export declare const Input: InputDecorator;
3169
3170/**
3171 * @publicApi
3172 */
3173export declare interface InputDecorator {
3174 /**
3175 * Decorator that marks a class field as an input property and supplies configuration metadata.
3176 * The input property is bound to a DOM property in the template. During change detection,
3177 * Angular automatically updates the data property with the DOM property's value.
3178 *
3179 * @usageNotes
3180 *
3181 * You can supply an optional name to use in templates when the
3182 * component is instantiated, that maps to the
3183 * name of the bound property. By default, the original
3184 * name of the bound property is used for input binding.
3185 *
3186 * The following example creates a component with two input properties,
3187 * one of which is given a special binding name.
3188 *
3189 * ```typescript
3190 * @Component({
3191 * selector: 'bank-account',
3192 * template: `
3193 * Bank Name: {{bankName}}
3194 * Account Id: {{id}}
3195 * `
3196 * })
3197 * class BankAccount {
3198 * // This property is bound using its original name.
3199 * @Input() bankName: string;
3200 * // this property value is bound to a different property name
3201 * // when this component is instantiated in a template.
3202 * @Input('account-id') id: string;
3203 *
3204 * // this property is not bound, and is not automatically updated by Angular
3205 * normalizedBankName: string;
3206 * }
3207 *
3208 * @Component({
3209 * selector: 'app',
3210 * template: `
3211 * <bank-account bankName="RBC" account-id="4747"></bank-account>
3212 * `
3213 * })
3214 * class App {}
3215 * ```
3216 *
3217 * @see [Input and Output properties](guide/template-syntax#input-and-output-properties)
3218 */
3219 (bindingPropertyName?: string): any;
3220 new (bindingPropertyName?: string): any;
3221}
3222
3223declare interface InternalNgModuleRef<T> extends NgModuleRef<T> {
3224 _bootstrapComponents: Type<any>[];
3225}
3226
3227declare interface InternalViewRef extends ViewRef {
3228 detachFromAppRef(): void;
3229 attachToAppRef(appRef: ApplicationRef): void;
3230}
3231
3232
3233/**
3234 * Returns whether Angular is in development mode. After called once,
3235 * the value is locked and won't change any more.
3236 *
3237 * By default, this is true, unless a user calls `enableProdMode` before calling this.
3238 *
3239 * @publicApi
3240 */
3241export declare function isDevMode(): boolean;
3242
3243/**
3244 * Record representing the item change information.
3245 *
3246 * @publicApi
3247 */
3248export declare interface IterableChangeRecord<V> {
3249 /** Current index of the item in `Iterable` or null if removed. */
3250 readonly currentIndex: number | null;
3251 /** Previous index of the item in `Iterable` or null if added. */
3252 readonly previousIndex: number | null;
3253 /** The item. */
3254 readonly item: V;
3255 /** Track by identity as computed by the `TrackByFunction`. */
3256 readonly trackById: any;
3257}
3258
3259declare class IterableChangeRecord_<V> implements IterableChangeRecord<V> {
3260 item: V;
3261 trackById: any;
3262 currentIndex: number | null;
3263 previousIndex: number | null;
3264 constructor(item: V, trackById: any);
3265}
3266
3267/**
3268 * An object describing the changes in the `Iterable` collection since last time
3269 * `IterableDiffer#diff()` was invoked.
3270 *
3271 * @publicApi
3272 */
3273export declare interface IterableChanges<V> {
3274 /**
3275 * Iterate over all changes. `IterableChangeRecord` will contain information about changes
3276 * to each item.
3277 */
3278 forEachItem(fn: (record: IterableChangeRecord<V>) => void): void;
3279 /**
3280 * Iterate over a set of operations which when applied to the original `Iterable` will produce the
3281 * new `Iterable`.
3282 *
3283 * NOTE: These are not necessarily the actual operations which were applied to the original
3284 * `Iterable`, rather these are a set of computed operations which may not be the same as the
3285 * ones applied.
3286 *
3287 * @param record A change which needs to be applied
3288 * @param previousIndex The `IterableChangeRecord#previousIndex` of the `record` refers to the
3289 * original `Iterable` location, where as `previousIndex` refers to the transient location
3290 * of the item, after applying the operations up to this point.
3291 * @param currentIndex The `IterableChangeRecord#currentIndex` of the `record` refers to the
3292 * original `Iterable` location, where as `currentIndex` refers to the transient location
3293 * of the item, after applying the operations up to this point.
3294 */
3295 forEachOperation(fn: (record: IterableChangeRecord<V>, previousIndex: number | null, currentIndex: number | null) => void): void;
3296 /**
3297 * Iterate over changes in the order of original `Iterable` showing where the original items
3298 * have moved.
3299 */
3300 forEachPreviousItem(fn: (record: IterableChangeRecord<V>) => void): void;
3301 /** Iterate over all added items. */
3302 forEachAddedItem(fn: (record: IterableChangeRecord<V>) => void): void;
3303 /** Iterate over all moved items. */
3304 forEachMovedItem(fn: (record: IterableChangeRecord<V>) => void): void;
3305 /** Iterate over all removed items. */
3306 forEachRemovedItem(fn: (record: IterableChangeRecord<V>) => void): void;
3307 /** Iterate over all items which had their identity (as computed by the `TrackByFunction`)
3308 * changed. */
3309 forEachIdentityChange(fn: (record: IterableChangeRecord<V>) => void): void;
3310}
3311
3312/**
3313 * A strategy for tracking changes over time to an iterable. Used by {@link NgForOf} to
3314 * respond to changes in an iterable by effecting equivalent changes in the DOM.
3315 *
3316 * @publicApi
3317 */
3318export declare interface IterableDiffer<V> {
3319 /**
3320 * Compute a difference between the previous state and the new `object` state.
3321 *
3322 * @param object containing the new value.
3323 * @returns an object describing the difference. The return value is only valid until the next
3324 * `diff()` invocation.
3325 */
3326 diff(object: NgIterable<V>): IterableChanges<V> | null;
3327}
3328
3329/**
3330 * Provides a factory for {@link IterableDiffer}.
3331 *
3332 * @publicApi
3333 */
3334export declare interface IterableDifferFactory {
3335 supports(objects: any): boolean;
3336 create<V>(trackByFn?: TrackByFunction<V>): IterableDiffer<V>;
3337}
3338
3339/**
3340 * A repository of different iterable diffing strategies used by NgFor, NgClass, and others.
3341 *
3342 * @publicApi
3343 */
3344export declare class IterableDiffers {
3345 /** @nocollapse */
3346 static ngInjectableDef: never;
3347 /**
3348 * @deprecated v4.0.0 - Should be private
3349 */
3350 factories: IterableDifferFactory[];
3351 constructor(factories: IterableDifferFactory[]);
3352 static create(factories: IterableDifferFactory[], parent?: IterableDiffers): IterableDiffers;
3353 /**
3354 * Takes an array of {@link IterableDifferFactory} and returns a provider used to extend the
3355 * inherited {@link IterableDiffers} instance with the provided factories and return a new
3356 * {@link IterableDiffers} instance.
3357 *
3358 * @usageNotes
3359 * ### Example
3360 *
3361 * The following example shows how to extend an existing list of factories,
3362 * which will only be applied to the injector for this component and its children.
3363 * This step is all that's required to make a new {@link IterableDiffer} available.
3364 *
3365 * ```
3366 * @Component({
3367 * viewProviders: [
3368 * IterableDiffers.extend([new ImmutableListDiffer()])
3369 * ]
3370 * })
3371 * ```
3372 */
3373 static extend(factories: IterableDifferFactory[]): StaticProvider;
3374 find(iterable: any): IterableDifferFactory;
3375}
3376
3377/**
3378 * Record representing the item change information.
3379 *
3380 * @publicApi
3381 */
3382export declare interface KeyValueChangeRecord<K, V> {
3383 /**
3384 * Current key in the Map.
3385 */
3386 readonly key: K;
3387 /**
3388 * Current value for the key or `null` if removed.
3389 */
3390 readonly currentValue: V | null;
3391 /**
3392 * Previous value for the key or `null` if added.
3393 */
3394 readonly previousValue: V | null;
3395}
3396
3397/**
3398 * An object describing the changes in the `Map` or `{[k:string]: string}` since last time
3399 * `KeyValueDiffer#diff()` was invoked.
3400 *
3401 * @publicApi
3402 */
3403export declare interface KeyValueChanges<K, V> {
3404 /**
3405 * Iterate over all changes. `KeyValueChangeRecord` will contain information about changes
3406 * to each item.
3407 */
3408 forEachItem(fn: (r: KeyValueChangeRecord<K, V>) => void): void;
3409 /**
3410 * Iterate over changes in the order of original Map showing where the original items
3411 * have moved.
3412 */
3413 forEachPreviousItem(fn: (r: KeyValueChangeRecord<K, V>) => void): void;
3414 /**
3415 * Iterate over all keys for which values have changed.
3416 */
3417 forEachChangedItem(fn: (r: KeyValueChangeRecord<K, V>) => void): void;
3418 /**
3419 * Iterate over all added items.
3420 */
3421 forEachAddedItem(fn: (r: KeyValueChangeRecord<K, V>) => void): void;
3422 /**
3423 * Iterate over all removed items.
3424 */
3425 forEachRemovedItem(fn: (r: KeyValueChangeRecord<K, V>) => void): void;
3426}
3427
3428/**
3429 * A differ that tracks changes made to an object over time.
3430 *
3431 * @publicApi
3432 */
3433export declare interface KeyValueDiffer<K, V> {
3434 /**
3435 * Compute a difference between the previous state and the new `object` state.
3436 *
3437 * @param object containing the new value.
3438 * @returns an object describing the difference. The return value is only valid until the next
3439 * `diff()` invocation.
3440 */
3441 diff(object: Map<K, V>): KeyValueChanges<K, V> | null;
3442 /**
3443 * Compute a difference between the previous state and the new `object` state.
3444 *
3445 * @param object containing the new value.
3446 * @returns an object describing the difference. The return value is only valid until the next
3447 * `diff()` invocation.
3448 */
3449 diff(object: {
3450 [key: string]: V;
3451 }): KeyValueChanges<string, V> | null;
3452}
3453
3454/**
3455 * Provides a factory for {@link KeyValueDiffer}.
3456 *
3457 * @publicApi
3458 */
3459export declare interface KeyValueDifferFactory {
3460 /**
3461 * Test to see if the differ knows how to diff this kind of object.
3462 */
3463 supports(objects: any): boolean;
3464 /**
3465 * Create a `KeyValueDiffer`.
3466 */
3467 create<K, V>(): KeyValueDiffer<K, V>;
3468}
3469
3470/**
3471 * A repository of different Map diffing strategies used by NgClass, NgStyle, and others.
3472 *
3473 * @publicApi
3474 */
3475export declare class KeyValueDiffers {
3476 /** @nocollapse */
3477 static ngInjectableDef: never;
3478 /**
3479 * @deprecated v4.0.0 - Should be private.
3480 */
3481 factories: KeyValueDifferFactory[];
3482 constructor(factories: KeyValueDifferFactory[]);
3483 static create<S>(factories: KeyValueDifferFactory[], parent?: KeyValueDiffers): KeyValueDiffers;
3484 /**
3485 * Takes an array of {@link KeyValueDifferFactory} and returns a provider used to extend the
3486 * inherited {@link KeyValueDiffers} instance with the provided factories and return a new
3487 * {@link KeyValueDiffers} instance.
3488 *
3489 * @usageNotes
3490 * ### Example
3491 *
3492 * The following example shows how to extend an existing list of factories,
3493 * which will only be applied to the injector for this component and its children.
3494 * This step is all that's required to make a new {@link KeyValueDiffer} available.
3495 *
3496 * ```
3497 * @Component({
3498 * viewProviders: [
3499 * KeyValueDiffers.extend([new ImmutableMapDiffer()])
3500 * ]
3501 * })
3502 * ```
3503 */
3504 static extend<S>(factories: KeyValueDifferFactory[]): StaticProvider;
3505 find(kv: any): KeyValueDifferFactory;
3506}
3507
3508/**
3509 * The state associated with a container.
3510 *
3511 * This is an array so that its structure is closer to LView. This helps
3512 * when traversing the view tree (which is a mix of containers and component
3513 * views), so we can jump to viewOrContainer[NEXT] in the same way regardless
3514 * of type.
3515 */
3516declare interface LContainer extends Array<any> {
3517 /**
3518 * The host element of this LContainer.
3519 *
3520 * The host could be an LView if this container is on a component node.
3521 * In that case, the component LView is its HOST.
3522 */
3523 readonly [HOST]: RElement | RComment | ɵangular_packages_core_core_bj;
3524 /**
3525 * This is a type field which allows us to differentiate `LContainer` from `StylingContext` in an
3526 * efficient way. The value is always set to `true`
3527 */
3528 [TYPE]: true;
3529 /**
3530 * The next active index in the views array to read or write to. This helps us
3531 * keep track of where we are in the views array.
3532 * In the case the LContainer is created for a ViewContainerRef,
3533 * it is set to null to identify this scenario, as indices are "absolute" in that case,
3534 * i.e. provided directly by the user of the ViewContainerRef API.
3535 */
3536 [ACTIVE_INDEX]: number;
3537 /**
3538 * Access to the parent view is necessary so we can propagate back
3539 * up from inside a container to parent[NEXT].
3540 */
3541 [PARENT]: ɵangular_packages_core_core_bj;
3542 /**
3543 * This allows us to jump from a container to a sibling container or component
3544 * view with the same parent, so we can remove listeners efficiently.
3545 */
3546 [NEXT]: ɵangular_packages_core_core_bj | LContainer | null;
3547 /**
3548 * A collection of views created based on the underlying `<ng-template>` element but inserted into
3549 * a different `LContainer`. We need to track views created from a given declaration point since
3550 * queries collect matches from the embedded view declaration point and _not_ the insertion point.
3551 */
3552 [MOVED_VIEWS]: ɵangular_packages_core_core_bj[] | null;
3553 /**
3554 * Pointer to the `TNode` which represents the host of the container.
3555 */
3556 [T_HOST]: TNode;
3557 /** The comment element that serves as an anchor for this LContainer. */
3558 readonly [NATIVE]: RComment;
3559 /**
3560 * Array of `ViewRef`s used by any `ViewContainerRef`s that point to this container.
3561 *
3562 * This is lazily initialized by `ViewContainerRef` when the first view is inserted.
3563 */
3564 [VIEW_REFS]: ViewRef[] | null;
3565}
3566
3567/**
3568 * Provide this token to set the locale of your application.
3569 * It is used for i18n extraction, by i18n pipes (DatePipe, I18nPluralPipe, CurrencyPipe,
3570 * DecimalPipe and PercentPipe) and by ICU expressions.
3571 *
3572 * See the [i18n guide](guide/i18n#setting-up-locale) for more information.
3573 *
3574 * @usageNotes
3575 * ### Example
3576 *
3577 * ```typescript
3578 * import { LOCALE_ID } from '@angular/core';
3579 * import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';
3580 * import { AppModule } from './app/app.module';
3581 *
3582 * platformBrowserDynamic().bootstrapModule(AppModule, {
3583 * providers: [{provide: LOCALE_ID, useValue: 'en-US' }]
3584 * });
3585 * ```
3586 *
3587 * @publicApi
3588 */
3589export declare const LOCALE_ID: InjectionToken<string>;
3590
3591/**
3592 * Type for a function that extracts a value for a local refs.
3593 * Example:
3594 * - `<div #nativeDivEl>` - `nativeDivEl` should point to the native `<div>` element;
3595 * - `<ng-template #tplRef>` - `tplRef` should point to the `TemplateRef` instance;
3596 */
3597declare type LocalRefExtractor = (tNode: TNodeWithLocalRefs, currentView: ɵangular_packages_core_core_bj) => any;
3598
3599/**
3600 * lQueries represent a collection of individual LQuery objects tracked in a given view.
3601 */
3602declare interface LQueries {
3603 /**
3604 * A collection of queries tracked in a given view.
3605 */
3606 queries: LQuery<any>[];
3607 /**
3608 * A method called when a new embedded view is created. As a result a set of LQueries applicable
3609 * for a new embedded view is instantiated (cloned) from the declaration view.
3610 * @param tView
3611 */
3612 createEmbeddedView(tView: TView): LQueries | null;
3613 /**
3614 * A method called when an embedded view is inserted into a container. As a result all impacted
3615 * `LQuery` objects (and associated `QueryList`) are marked as dirty.
3616 * @param tView
3617 */
3618 insertView(tView: TView): void;
3619 /**
3620 * A method called when an embedded view is detached from a container. As a result all impacted
3621 * `LQuery` objects (and associated `QueryList`) are marked as dirty.
3622 * @param tView
3623 */
3624 detachView(tView: TView): void;
3625}
3626
3627/**
3628 * An interface that represents query-related information specific to a view instance. Most notably
3629 * it contains:
3630 * - materialized query matches;
3631 * - a pointer to a QueryList where materialized query results should be reported.
3632 */
3633declare interface LQuery<T> {
3634 /**
3635 * Materialized query matches for a given view only (!). Results are initialized lazily so the
3636 * array of matches is set to `null` initially.
3637 */
3638 matches: (T | null)[] | null;
3639 /**
3640 * A QueryList where materialized query results should be reported.
3641 */
3642 queryList: QueryList<T>;
3643 /**
3644 * Clones an LQuery for an embedded view. A cloned query shares the same `QueryList` but has a
3645 * separate collection of materialized matches.
3646 */
3647 clone(): LQuery<T>;
3648 /**
3649 * Called when an embedded view, impacting results of this query, is inserted or removed.
3650 */
3651 setDirty(): void;
3652}
3653
3654/** Flags associated with an LView (saved in LView[FLAGS]) */
3655declare const enum LViewFlags {
3656 /** The state of the init phase on the first 2 bits */
3657 InitPhaseStateIncrementer = 1,
3658 InitPhaseStateMask = 3,
3659 /**
3660 * Whether or not the view is in creationMode.
3661 *
3662 * This must be stored in the view rather than using `data` as a marker so that
3663 * we can properly support embedded views. Otherwise, when exiting a child view
3664 * back into the parent view, `data` will be defined and `creationMode` will be
3665 * improperly reported as false.
3666 */
3667 CreationMode = 4,
3668 /**
3669 * Whether or not this LView instance is on its first processing pass.
3670 *
3671 * An LView instance is considered to be on its "first pass" until it
3672 * has completed one creation mode run and one update mode run. At this
3673 * time, the flag is turned off.
3674 */
3675 FirstLViewPass = 8,
3676 /** Whether this view has default change detection strategy (checks always) or onPush */
3677 CheckAlways = 16,
3678 /**
3679 * Whether or not manual change detection is turned on for onPush components.
3680 *
3681 * This is a special mode that only marks components dirty in two cases:
3682 * 1) There has been a change to an @Input property
3683 * 2) `markDirty()` has been called manually by the user
3684 *
3685 * Note that in this mode, the firing of events does NOT mark components
3686 * dirty automatically.
3687 *
3688 * Manual mode is turned off by default for backwards compatibility, as events
3689 * automatically mark OnPush components dirty in View Engine.
3690 *
3691 * TODO: Add a public API to ChangeDetectionStrategy to turn this mode on
3692 */
3693 ManualOnPush = 32,
3694 /** Whether or not this view is currently dirty (needing check) */
3695 Dirty = 64,
3696 /** Whether or not this view is currently attached to change detection tree. */
3697 Attached = 128,
3698 /** Whether or not this view is destroyed. */
3699 Destroyed = 256,
3700 /** Whether or not this view is the root view */
3701 IsRoot = 512,
3702 /**
3703 * Index of the current init phase on last 22 bits
3704 */
3705 IndexWithinInitPhaseIncrementer = 1024,
3706 IndexWithinInitPhaseShift = 10,
3707 IndexWithinInitPhaseReset = 1023
3708}
3709
3710/**
3711 * Use this enum at bootstrap as an option of `bootstrapModule` to define the strategy
3712 * that the compiler should use in case of missing translations:
3713 * - Error: throw if you have missing translations.
3714 * - Warning (default): show a warning in the console and/or shell.
3715 * - Ignore: do nothing.
3716 *
3717 * See the [i18n guide](guide/i18n#missing-translation) for more information.
3718 *
3719 * @usageNotes
3720 * ### Example
3721 * ```typescript
3722 * import { MissingTranslationStrategy } from '@angular/core';
3723 * import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';
3724 * import { AppModule } from './app/app.module';
3725 *
3726 * platformBrowserDynamic().bootstrapModule(AppModule, {
3727 * missingTranslation: MissingTranslationStrategy.Error
3728 * });
3729 * ```
3730 *
3731 * @publicApi
3732 */
3733export declare enum MissingTranslationStrategy {
3734 Error = 0,
3735 Warning = 1,
3736 Ignore = 2
3737}
3738
3739/**
3740 * Combination of NgModuleFactory and ComponentFactorys.
3741 *
3742 * @publicApi
3743 */
3744export declare class ModuleWithComponentFactories<T> {
3745 ngModuleFactory: NgModuleFactory<T>;
3746 componentFactories: ComponentFactory<any>[];
3747 constructor(ngModuleFactory: NgModuleFactory<T>, componentFactories: ComponentFactory<any>[]);
3748}
3749
3750/**
3751 * A wrapper around an NgModule that associates it with the providers.
3752 *
3753 * @param T the module type. In Ivy applications, this must be explicitly
3754 * provided.
3755 *
3756 * @publicApi
3757 */
3758export declare interface ModuleWithProviders<T = any /** TODO(alxhub): remove default when callers pass explicit type param */> {
3759 ngModule: Type<T>;
3760 providers?: Provider[];
3761}
3762
3763declare const MOVED_VIEWS = 5;
3764
3765declare const NATIVE = 7;
3766
3767declare const NEXT = 4;
3768
3769declare interface NgContentDef {
3770 /**
3771 * this index is checked against NodeDef.ngContentIndex to find the nodes
3772 * that are matched by this ng-content.
3773 * Note that a NodeDef with an ng-content can be reprojected, i.e.
3774 * have a ngContentIndex on its own.
3775 */
3776 index: number;
3777}
3778
3779/**
3780 * A type describing supported iterable types.
3781 *
3782 * @publicApi
3783 */
3784export declare type NgIterable<T> = Array<T> | Iterable<T>;
3785
3786/**
3787 * Type of the NgModule metadata.
3788 *
3789 * @publicApi
3790 */
3791export declare interface NgModule {
3792 /**
3793 * The set of injectable objects that are available in the injector
3794 * of this module.
3795 *
3796 * @see [Dependency Injection guide](guide/dependency-injection)
3797 * @see [NgModule guide](guide/providers)
3798 *
3799 * @usageNotes
3800 *
3801 * Dependencies whose providers are listed here become available for injection
3802 * into any component, directive, pipe or service that is a child of this injector.
3803 * The NgModule used for bootstrapping uses the root injector, and can provide dependencies
3804 * to any part of the app.
3805 *
3806 * A lazy-loaded module has its own injector, typically a child of the app root injector.
3807 * Lazy-loaded services are scoped to the lazy-loaded module's injector.
3808 * If a lazy-loaded module also provides the `UserService`, any component created
3809 * within that module's context (such as by router navigation) gets the local instance
3810 * of the service, not the instance in the root injector.
3811 * Components in external modules continue to receive the instance provided by their injectors.
3812 *
3813 * ### Example
3814 *
3815 * The following example defines a class that is injected in
3816 * the HelloWorld NgModule:
3817 *
3818 * ```
3819 * class Greeter {
3820 * greet(name:string) {
3821 * return 'Hello ' + name + '!';
3822 * }
3823 * }
3824 *
3825 * @NgModule({
3826 * providers: [
3827 * Greeter
3828 * ]
3829 * })
3830 * class HelloWorld {
3831 * greeter:Greeter;
3832 *
3833 * constructor(greeter:Greeter) {
3834 * this.greeter = greeter;
3835 * }
3836 * }
3837 * ```
3838 */
3839 providers?: Provider[];
3840 /**
3841 * The set of components, directives, and pipes ([declarables](guide/glossary#declarable))
3842 * that belong to this module.
3843 *
3844 * @usageNotes
3845 *
3846 * The set of selectors that are available to a template include those declared here, and
3847 * those that are exported from imported NgModules.
3848 *
3849 * Declarables must belong to exactly one module.
3850 * The compiler emits an error if you try to declare the same class in more than one module.
3851 * Be careful not to declare a class that is imported from another module.
3852 *
3853 * ### Example
3854 *
3855 * The following example allows the CommonModule to use the `NgFor`
3856 * directive.
3857 *
3858 * ```javascript
3859 * @NgModule({
3860 * declarations: [NgFor]
3861 * })
3862 * class CommonModule {
3863 * }
3864 * ```
3865 */
3866 declarations?: Array<Type<any> | any[]>;
3867 /**
3868 * The set of NgModules whose exported [declarables](guide/glossary#declarable)
3869 * are available to templates in this module.
3870 *
3871 * @usageNotes
3872 *
3873 * A template can use exported declarables from any
3874 * imported module, including those from modules that are imported indirectly
3875 * and re-exported.
3876 * For example, `ModuleA` imports `ModuleB`, and also exports
3877 * it, which makes the declarables from `ModuleB` available
3878 * wherever `ModuleA` is imported.
3879 *
3880 * ### Example
3881 *
3882 * The following example allows MainModule to use anything exported by
3883 * `CommonModule`:
3884 *
3885 * ```javascript
3886 * @NgModule({
3887 * imports: [CommonModule]
3888 * })
3889 * class MainModule {
3890 * }
3891 * ```
3892 *
3893 */
3894 imports?: Array<Type<any> | ModuleWithProviders<{}> | any[]>;
3895 /**
3896 * The set of components, directives, and pipes declared in this
3897 * NgModule that can be used in the template of any component that is part of an
3898 * NgModule that imports this NgModule. Exported declarations are the module's public API.
3899 *
3900 * A declarable belongs to one and only one NgModule.
3901 * A module can list another module among its exports, in which case all of that module's
3902 * public declaration are exported.
3903 *
3904 * @usageNotes
3905 *
3906 * Declarations are private by default.
3907 * If this ModuleA does not export UserComponent, then only the components within this
3908 * ModuleA can use UserComponent.
3909 *
3910 * ModuleA can import ModuleB and also export it, making exports from ModuleB
3911 * available to an NgModule that imports ModuleA.
3912 *
3913 * ### Example
3914 *
3915 * The following example exports the `NgFor` directive from CommonModule.
3916 *
3917 * ```javascript
3918 * @NgModule({
3919 * exports: [NgFor]
3920 * })
3921 * class CommonModule {
3922 * }
3923 * ```
3924 */
3925 exports?: Array<Type<any> | any[]>;
3926 /**
3927 * The set of components to compile when this NgModule is defined,
3928 * so that they can be dynamically loaded into the view.
3929 *
3930 * For each component listed here, Angular creates a `ComponentFactory`
3931 * and stores it in the `ComponentFactoryResolver`.
3932 *
3933 * Angular automatically adds components in the module's bootstrap
3934 * and route definitions into the `entryComponents` list. Use this
3935 * option to add components that are bootstrapped
3936 * using one of the imperative techniques, such as `ViewContainerRef.createComponent()`.
3937 *
3938 * @see [Entry Components](guide/entry-components)
3939 */
3940 entryComponents?: Array<Type<any> | any[]>;
3941 /**
3942 * The set of components that are bootstrapped when
3943 * this module is bootstrapped. The components listed here
3944 * are automatically added to `entryComponents`.
3945 */
3946 bootstrap?: Array<Type<any> | any[]>;
3947 /**
3948 * The set of schemas that declare elements to be allowed in the NgModule.
3949 * Elements and properties that are neither Angular components nor directives
3950 * must be declared in a schema.
3951 *
3952 * Allowed value are `NO_ERRORS_SCHEMA` and `CUSTOM_ELEMENTS_SCHEMA`.
3953 *
3954 * @security When using one of `NO_ERRORS_SCHEMA` or `CUSTOM_ELEMENTS_SCHEMA`
3955 * you must ensure that allowed elements and properties securely escape inputs.
3956 */
3957 schemas?: Array<SchemaMetadata | any[]>;
3958 /**
3959 * A name or path that uniquely identifies this NgModule in `getModuleFactory`.
3960 * If left `undefined`, the NgModule is not registered with
3961 * `getModuleFactory`.
3962 */
3963 id?: string;
3964 /**
3965 * If true, this module will be skipped by the AOT compiler and so will always be compiled
3966 * using JIT.
3967 *
3968 * This exists to support future Ivy work and has no effect currently.
3969 */
3970 jit?: true;
3971}
3972
3973/**
3974 * @Annotation
3975 * @publicApi
3976 */
3977export declare const NgModule: NgModuleDecorator;
3978
3979/**
3980 * Type of the NgModule decorator / constructor function.
3981 *
3982 * @publicApi
3983 */
3984export declare interface NgModuleDecorator {
3985 /**
3986 * Decorator that marks a class as an NgModule and supplies configuration metadata.
3987 */
3988 (obj?: NgModule): TypeDecorator;
3989 new (obj?: NgModule): NgModule;
3990}
3991
3992declare interface NgModuleDefinition extends Definition<NgModuleDefinitionFactory> {
3993 providers: NgModuleProviderDef[];
3994 providersByKey: {
3995 [tokenKey: string]: NgModuleProviderDef;
3996 };
3997 modules: any[];
3998 isRoot: boolean;
3999}
4000
4001declare interface NgModuleDefinitionFactory extends DefinitionFactory<NgModuleDefinition> {
4002}
4003
4004/**
4005 * @publicApi
4006 */
4007export declare abstract class NgModuleFactory<T> {
4008 abstract readonly moduleType: Type<T>;
4009 abstract create(parentInjector: Injector | null): NgModuleRef<T>;
4010}
4011
4012/**
4013 * Used to load ng module factories.
4014 *
4015 * @publicApi
4016 * @deprecated the `string` form of `loadChildren` is deprecated, and `NgModuleFactoryLoader` is
4017 * part of its implementation. See `LoadChildren` for more details.
4018 */
4019export declare abstract class NgModuleFactoryLoader {
4020 abstract load(path: string): Promise<NgModuleFactory<any>>;
4021}
4022
4023declare interface NgModuleProviderDef {
4024 flags: ɵNodeFlags;
4025 index: number;
4026 token: any;
4027 value: any;
4028 deps: DepDef[];
4029}
4030
4031/**
4032 * Represents an instance of an NgModule created via a {@link NgModuleFactory}.
4033 *
4034 * `NgModuleRef` provides access to the NgModule Instance as well other objects related to this
4035 * NgModule Instance.
4036 *
4037 * @publicApi
4038 */
4039export declare abstract class NgModuleRef<T> {
4040 /**
4041 * The injector that contains all of the providers of the NgModule.
4042 */
4043 abstract readonly injector: Injector;
4044 /**
4045 * The ComponentFactoryResolver to get hold of the ComponentFactories
4046 * declared in the `entryComponents` property of the module.
4047 */
4048 abstract readonly componentFactoryResolver: ComponentFactoryResolver;
4049 /**
4050 * The NgModule instance.
4051 */
4052 abstract readonly instance: T;
4053 /**
4054 * Destroys the module instance and all of the data structures associated with it.
4055 */
4056 abstract destroy(): void;
4057 /**
4058 * Allows to register a callback that will be called when the module is destroyed.
4059 */
4060 abstract onDestroy(callback: () => void): void;
4061}
4062
4063/**
4064 * A token for third-party components that can register themselves with NgProbe.
4065 *
4066 * @publicApi
4067 */
4068export declare class NgProbeToken {
4069 name: string;
4070 token: any;
4071 constructor(name: string, token: any);
4072}
4073
4074/**
4075 * An injectable service for executing work inside or outside of the Angular zone.
4076 *
4077 * The most common use of this service is to optimize performance when starting a work consisting of
4078 * one or more asynchronous tasks that don't require UI updates or error handling to be handled by
4079 * Angular. Such tasks can be kicked off via {@link #runOutsideAngular} and if needed, these tasks
4080 * can reenter the Angular zone via {@link #run}.
4081 *
4082 * <!-- TODO: add/fix links to:
4083 * - docs explaining zones and the use of zones in Angular and change-detection
4084 * - link to runOutsideAngular/run (throughout this file!)
4085 * -->
4086 *
4087 * @usageNotes
4088 * ### Example
4089 *
4090 * ```
4091 * import {Component, NgZone} from '@angular/core';
4092 * import {NgIf} from '@angular/common';
4093 *
4094 * @Component({
4095 * selector: 'ng-zone-demo',
4096 * template: `
4097 * <h2>Demo: NgZone</h2>
4098 *
4099 * <p>Progress: {{progress}}%</p>
4100 * <p *ngIf="progress >= 100">Done processing {{label}} of Angular zone!</p>
4101 *
4102 * <button (click)="processWithinAngularZone()">Process within Angular zone</button>
4103 * <button (click)="processOutsideOfAngularZone()">Process outside of Angular zone</button>
4104 * `,
4105 * })
4106 * export class NgZoneDemo {
4107 * progress: number = 0;
4108 * label: string;
4109 *
4110 * constructor(private _ngZone: NgZone) {}
4111 *
4112 * // Loop inside the Angular zone
4113 * // so the UI DOES refresh after each setTimeout cycle
4114 * processWithinAngularZone() {
4115 * this.label = 'inside';
4116 * this.progress = 0;
4117 * this._increaseProgress(() => console.log('Inside Done!'));
4118 * }
4119 *
4120 * // Loop outside of the Angular zone
4121 * // so the UI DOES NOT refresh after each setTimeout cycle
4122 * processOutsideOfAngularZone() {
4123 * this.label = 'outside';
4124 * this.progress = 0;
4125 * this._ngZone.runOutsideAngular(() => {
4126 * this._increaseProgress(() => {
4127 * // reenter the Angular zone and display done
4128 * this._ngZone.run(() => { console.log('Outside Done!'); });
4129 * });
4130 * });
4131 * }
4132 *
4133 * _increaseProgress(doneCallback: () => void) {
4134 * this.progress += 1;
4135 * console.log(`Current progress: ${this.progress}%`);
4136 *
4137 * if (this.progress < 100) {
4138 * window.setTimeout(() => this._increaseProgress(doneCallback), 10);
4139 * } else {
4140 * doneCallback();
4141 * }
4142 * }
4143 * }
4144 * ```
4145 *
4146 * @publicApi
4147 */
4148export declare class NgZone {
4149 readonly hasPendingMicrotasks: boolean;
4150 readonly hasPendingMacrotasks: boolean;
4151 /**
4152 * Whether there are no outstanding microtasks or macrotasks.
4153 */
4154 readonly isStable: boolean;
4155 /**
4156 * Notifies when code enters Angular Zone. This gets fired first on VM Turn.
4157 */
4158 readonly onUnstable: EventEmitter<any>;
4159 /**
4160 * Notifies when there is no more microtasks enqueued in the current VM Turn.
4161 * This is a hint for Angular to do change detection, which may enqueue more microtasks.
4162 * For this reason this event can fire multiple times per VM Turn.
4163 */
4164 readonly onMicrotaskEmpty: EventEmitter<any>;
4165 /**
4166 * Notifies when the last `onMicrotaskEmpty` has run and there are no more microtasks, which
4167 * implies we are about to relinquish VM turn.
4168 * This event gets called just once.
4169 */
4170 readonly onStable: EventEmitter<any>;
4171 /**
4172 * Notifies that an error has been delivered.
4173 */
4174 readonly onError: EventEmitter<any>;
4175 constructor({ enableLongStackTrace }: {
4176 enableLongStackTrace?: boolean | undefined;
4177 });
4178 static isInAngularZone(): boolean;
4179 static assertInAngularZone(): void;
4180 static assertNotInAngularZone(): void;
4181 /**
4182 * Executes the `fn` function synchronously within the Angular zone and returns value returned by
4183 * the function.
4184 *
4185 * Running functions via `run` allows you to reenter Angular zone from a task that was executed
4186 * outside of the Angular zone (typically started via {@link #runOutsideAngular}).
4187 *
4188 * Any future tasks or microtasks scheduled from within this function will continue executing from
4189 * within the Angular zone.
4190 *
4191 * If a synchronous error happens it will be rethrown and not reported via `onError`.
4192 */
4193 run<T>(fn: (...args: any[]) => T, applyThis?: any, applyArgs?: any[]): T;
4194 /**
4195 * Executes the `fn` function synchronously within the Angular zone as a task and returns value
4196 * returned by the function.
4197 *
4198 * Running functions via `run` allows you to reenter Angular zone from a task that was executed
4199 * outside of the Angular zone (typically started via {@link #runOutsideAngular}).
4200 *
4201 * Any future tasks or microtasks scheduled from within this function will continue executing from
4202 * within the Angular zone.
4203 *
4204 * If a synchronous error happens it will be rethrown and not reported via `onError`.
4205 */
4206 runTask<T>(fn: (...args: any[]) => T, applyThis?: any, applyArgs?: any[], name?: string): T;
4207 /**
4208 * Same as `run`, except that synchronous errors are caught and forwarded via `onError` and not
4209 * rethrown.
4210 */
4211 runGuarded<T>(fn: (...args: any[]) => T, applyThis?: any, applyArgs?: any[]): T;
4212 /**
4213 * Executes the `fn` function synchronously in Angular's parent zone and returns value returned by
4214 * the function.
4215 *
4216 * Running functions via {@link #runOutsideAngular} allows you to escape Angular's zone and do
4217 * work that
4218 * doesn't trigger Angular change-detection or is subject to Angular's error handling.
4219 *
4220 * Any future tasks or microtasks scheduled from within this function will continue executing from
4221 * outside of the Angular zone.
4222 *
4223 * Use {@link #run} to reenter the Angular zone and do work that updates the application model.
4224 */
4225 runOutsideAngular<T>(fn: (...args: any[]) => T): T;
4226}
4227
4228/**
4229 * Defines a schema that allows any property on any element.
4230 *
4231 * @publicApi
4232 */
4233export declare const NO_ERRORS_SCHEMA: SchemaMetadata;
4234
4235declare interface NodeCheckFn {
4236 (view: ViewData, nodeIndex: number, argStyle: ɵArgumentType.Dynamic, values: any[]): any;
4237 (view: ViewData, nodeIndex: number, argStyle: ɵArgumentType.Inline, v0?: any, v1?: any, v2?: any, v3?: any, v4?: any, v5?: any, v6?: any, v7?: any, v8?: any, v9?: any): any;
4238}
4239
4240/**
4241 * Node instance data.
4242 *
4243 * We have a separate type per NodeType to save memory
4244 * (TextData | ElementData | ProviderData | PureExpressionData | QueryList<any>)
4245 *
4246 * To keep our code monomorphic,
4247 * we prohibit using `NodeData` directly but enforce the use of accessors (`asElementData`, ...).
4248 * This way, no usage site can get a `NodeData` from view.nodes and then use it for different
4249 * purposes.
4250 */
4251declare class NodeData {
4252 private __brand;
4253}
4254
4255/**
4256 * A node definition in the view.
4257 *
4258 * Note: We use one type for all nodes so that loops that loop over all nodes
4259 * of a ViewDefinition stay monomorphic!
4260 */
4261declare interface NodeDef {
4262 flags: ɵNodeFlags;
4263 nodeIndex: number;
4264 checkIndex: number;
4265 parent: NodeDef | null;
4266 renderParent: NodeDef | null;
4267 /** this is checked against NgContentDef.index to find matched nodes */
4268 ngContentIndex: number | null;
4269 /** number of transitive children */
4270 childCount: number;
4271 /** aggregated NodeFlags for all transitive children (does not include self) **/
4272 childFlags: ɵNodeFlags;
4273 /** aggregated NodeFlags for all direct children (does not include self) **/
4274 directChildFlags: ɵNodeFlags;
4275 bindingIndex: number;
4276 bindings: BindingDef[];
4277 bindingFlags: ɵBindingFlags;
4278 outputIndex: number;
4279 outputs: OutputDef[];
4280 /**
4281 * references that the user placed on the element
4282 */
4283 references: {
4284 [refId: string]: ɵQueryValueType;
4285 };
4286 /**
4287 * ids and value types of all queries that are matched by this node.
4288 */
4289 matchedQueries: {
4290 [queryId: number]: ɵQueryValueType;
4291 };
4292 /** Binary or of all matched query ids of this node. */
4293 matchedQueryIds: number;
4294 /**
4295 * Binary or of all query ids that are matched by one of the children.
4296 * This includes query ids from templates as well.
4297 * Used as a bloom filter.
4298 */
4299 childMatchedQueries: number;
4300 element: ElementDef | null;
4301 provider: ProviderDef | null;
4302 text: TextDef | null;
4303 query: QueryDef | null;
4304 ngContent: NgContentDef | null;
4305}
4306
4307/**
4308 * Function to call console.error at the right source location. This is an indirection
4309 * via another function as browser will log the location that actually called
4310 * `console.error`.
4311 */
4312declare interface NodeLogger {
4313 (): () => void;
4314}
4315
4316/**
4317 * Object Oriented style of API needed to create elements and text nodes.
4318 *
4319 * This is the native browser API style, e.g. operations are methods on individual objects
4320 * like HTMLElement. With this style, no additional code is needed as a facade
4321 * (reducing payload size).
4322 * */
4323declare interface ObjectOrientedRenderer3 {
4324 createComment(data: string): RComment;
4325 createElement(tagName: string): RElement;
4326 createElementNS(namespace: string, tagName: string): RElement;
4327 createTextNode(data: string): RText;
4328 querySelector(selectors: string): RElement | null;
4329}
4330
4331/**
4332 * @description
4333 * A lifecycle hook that is called when any data-bound property of a directive changes.
4334 * Define an `ngOnChanges()` method to handle the changes.
4335 *
4336 * @see `DoCheck`
4337 * @see `OnInit`
4338 * @see [Lifecycle Hooks](guide/lifecycle-hooks#onchanges) guide
4339 *
4340 * @usageNotes
4341 * The following snippet shows how a component can implement this interface to
4342 * define an on-changes handler for an input property.
4343 *
4344 * {@example core/ts/metadata/lifecycle_hooks_spec.ts region='OnChanges'}
4345 *
4346 * @publicApi
4347 */
4348export declare interface OnChanges {
4349 /**
4350 * A callback method that is invoked immediately after the
4351 * default change detector has checked data-bound properties
4352 * if at least one has changed, and before the view and content
4353 * children are checked.
4354 * @param changes The changed properties.
4355 */
4356 ngOnChanges(changes: SimpleChanges): void;
4357}
4358
4359/**
4360 * A lifecycle hook that is called when a directive, pipe, or service is destroyed.
4361 * Use for any custom cleanup that needs to occur when the
4362 * instance is destroyed.
4363 * @see [Lifecycle Hooks](guide/lifecycle-hooks#onchanges) guide
4364 *
4365 * @usageNotes
4366 * The following snippet shows how a component can implement this interface
4367 * to define its own custom clean-up method.
4368 *
4369 * {@example core/ts/metadata/lifecycle_hooks_spec.ts region='OnDestroy'}
4370 *
4371 * @publicApi
4372 */
4373export declare interface OnDestroy {
4374 /**
4375 * A callback method that performs custom clean-up, invoked immediately
4376 * after a directive, pipe, or service instance is destroyed.
4377 */
4378 ngOnDestroy(): void;
4379}
4380
4381/**
4382 * @description
4383 * A lifecycle hook that is called after Angular has initialized
4384 * all data-bound properties of a directive.
4385 * Define an `ngOnInit()` method to handle any additional initialization tasks.
4386 *
4387 * @see `AfterContentInit`
4388 * @see [Lifecycle Hooks](guide/lifecycle-hooks#onchanges) guide
4389 *
4390 * @usageNotes
4391 * The following snippet shows how a component can implement this interface to
4392 * define its own initialization method.
4393 *
4394 * {@example core/ts/metadata/lifecycle_hooks_spec.ts region='OnInit'}
4395 *
4396 * @publicApi
4397 */
4398export declare interface OnInit {
4399 /**
4400 * A callback method that is invoked immediately after the
4401 * default change detector has checked the directive's
4402 * data-bound properties for the first time,
4403 * and before any of the view or content children have been checked.
4404 * It is invoked only once when the directive is instantiated.
4405 */
4406 ngOnInit(): void;
4407}
4408
4409declare interface OpaqueViewState {
4410 '__brand__': 'Brand for OpaqueViewState that nothing will match';
4411}
4412
4413/**
4414 * Type of the Optional metadata.
4415 *
4416 * @publicApi
4417 */
4418export declare interface Optional {
4419}
4420
4421/**
4422 * Optional decorator and metadata.
4423 *
4424 * @Annotation
4425 * @publicApi
4426 */
4427export declare const Optional: OptionalDecorator;
4428
4429/**
4430 * Type of the Optional decorator / constructor function.
4431 *
4432 * @publicApi
4433 */
4434export declare interface OptionalDecorator {
4435 /**
4436 * Parameter decorator to be used on constructor parameters,
4437 * which marks the parameter as being an optional dependency.
4438 * The DI framework provides null if the dependency is not found.
4439 *
4440 * Can be used together with other parameter decorators
4441 * that modify how dependency injection operates.
4442 *
4443 * Learn more in the ["Dependency Injection Guide"](guide/dependency-injection).
4444 *
4445 * @usageNotes
4446 *
4447 * The following code allows the possibility of a null result:
4448 *
4449 * <code-example path="core/di/ts/metadata_spec.ts" region="Optional">
4450 * </code-example>
4451 *
4452 */
4453 (): any;
4454 new (): Optional;
4455}
4456
4457/**
4458 * Type of the Output metadata.
4459 *
4460 * @publicApi
4461 */
4462export declare interface Output {
4463 /**
4464 * The name of the DOM property to which the output property is bound.
4465 */
4466 bindingPropertyName?: string;
4467}
4468
4469/**
4470 * @Annotation
4471 * @publicApi
4472 */
4473export declare const Output: OutputDecorator;
4474
4475/**
4476 * Type of the Output decorator / constructor function.
4477 *
4478 * @publicApi
4479 */
4480export declare interface OutputDecorator {
4481 /**
4482 * Decorator that marks a class field as an output property and supplies configuration metadata.
4483 * The DOM property bound to the output property is automatically updated during change detection.
4484 *
4485 * @usageNotes
4486 *
4487 * You can supply an optional name to use in templates when the
4488 * component is instantiated, that maps to the
4489 * name of the bound property. By default, the original
4490 * name of the bound property is used for output binding.
4491 *
4492 * See `Input` decorator for an example of providing a binding name.
4493 *
4494 * @see [Input and Output properties](guide/template-syntax#input-and-output-properties)
4495 *
4496 */
4497 (bindingPropertyName?: string): any;
4498 new (bindingPropertyName?: string): any;
4499}
4500
4501declare interface OutputDef {
4502 type: OutputType;
4503 target: 'window' | 'document' | 'body' | 'component' | null;
4504 eventName: string;
4505 propName: string | null;
4506}
4507
4508declare const enum OutputType {
4509 ElementOutput = 0,
4510 DirectiveOutput = 1
4511}
4512
4513/**
4514 * A token which indicates the root directory of the application
4515 * @publicApi
4516 */
4517export declare const PACKAGE_ROOT_URL: InjectionToken<string>;
4518
4519declare const PARENT = 3;
4520
4521/**
4522 * Type of the Pipe metadata.
4523 *
4524 * @publicApi
4525 */
4526export declare interface Pipe {
4527 /**
4528 * The pipe name to use in template bindings.
4529 * Typically uses [lowerCamelCase](guide/glossary#case-types)
4530 * because the name cannot contain hyphens.
4531 */
4532 name: string;
4533 /**
4534 * When true, the pipe is pure, meaning that the
4535 * `transform()` method is invoked only when its input arguments
4536 * change. Pipes are pure by default.
4537 *
4538 * If the pipe has internal state (that is, the result
4539 * depends on state other than its arguments), set `pure` to false.
4540 * In this case, the pipe is invoked on each change-detection cycle,
4541 * even if the arguments have not changed.
4542 */
4543 pure?: boolean;
4544}
4545
4546/**
4547 * @Annotation
4548 * @publicApi
4549 */
4550export declare const Pipe: PipeDecorator;
4551
4552/**
4553 * Type of the Pipe decorator / constructor function.
4554 *
4555 * @publicApi
4556 */
4557export declare interface PipeDecorator {
4558 /**
4559 *
4560 * Decorator that marks a class as pipe and supplies configuration metadata.
4561 *
4562 * A pipe class must implement the `PipeTransform` interface.
4563 * For example, if the name is "myPipe", use a template binding expression
4564 * such as the following:
4565 *
4566 * ```
4567 * {{ exp | myPipe }}
4568 * ```
4569 *
4570 * The result of the expression is passed to the pipe's `transform()` method.
4571 *
4572 * A pipe must belong to an NgModule in order for it to be available
4573 * to a template. To make it a member of an NgModule,
4574 * list it in the `declarations` field of the `NgModule` metadata.
4575 *
4576 * @see [Style Guide: Pipe Names](guide/styleguide#02-09)
4577 *
4578 */
4579 (obj: Pipe): TypeDecorator;
4580 /**
4581 * See the `Pipe` decorator.
4582 */
4583 new (obj: Pipe): Pipe;
4584}
4585
4586declare type PipeDefList = ɵPipeDef<any>[];
4587
4588/**
4589 * Type used for PipeDefs on component definition.
4590 *
4591 * The function is necessary to be able to support forward declarations.
4592 */
4593declare type PipeDefListOrFactory = (() => PipeDefList) | PipeDefList;
4594
4595
4596/**
4597 * An interface that is implemented by pipes in order to perform a transformation.
4598 * Angular invokes the `transform` method with the value of a binding
4599 * as the first argument, and any parameters as the second argument in list form.
4600 *
4601 * @usageNotes
4602 *
4603 * In the following example, `RepeatPipe` repeats a given value a given number of times.
4604 *
4605 * ```ts
4606 * import {Pipe, PipeTransform} from '@angular/core';
4607 *
4608 * @Pipe({name: 'repeat'})
4609 * export class RepeatPipe implements PipeTransform {
4610 * transform(value: any, times: number) {
4611 * return value.repeat(times);
4612 * }
4613 * }
4614 * ```
4615 *
4616 * Invoking `{{ 'ok' | repeat:3 }}` in a template produces `okokok`.
4617 *
4618 * @publicApi
4619 */
4620export declare interface PipeTransform {
4621 transform(value: any, ...args: any[]): any;
4622}
4623
4624/**
4625 * A subclass of `Type` which has a static `ngPipeDef`:`PipeDef` field making it
4626 * consumable for rendering.
4627 */
4628declare interface PipeType<T> extends Type<T> {
4629 ngPipeDef: never;
4630}
4631
4632declare type PipeTypeList = (PipeType<any> | Type<any>)[];
4633
4634declare type PipeTypesOrFactory = (() => PipeTypeList) | PipeTypeList;
4635
4636/**
4637 * A token that indicates an opaque platform id.
4638 * @publicApi
4639 */
4640export declare const PLATFORM_ID: InjectionToken<Object>;
4641
4642/**
4643 * A function that will be executed when a platform is initialized.
4644 * @publicApi
4645 */
4646export declare const PLATFORM_INITIALIZER: InjectionToken<(() => void)[]>;
4647
4648/**
4649 * This platform has to be included in any other platform
4650 *
4651 * @publicApi
4652 */
4653export declare const platformCore: (extraProviders?: StaticProvider[] | undefined) => PlatformRef;
4654
4655/**
4656 * The Angular platform is the entry point for Angular on a web page. Each page
4657 * has exactly one platform, and services (such as reflection) which are common
4658 * to every Angular application running on the page are bound in its scope.
4659 *
4660 * A page's platform is initialized implicitly when a platform is created via a platform factory
4661 * (e.g. {@link platformBrowser}), or explicitly by calling the {@link createPlatform} function.
4662 *
4663 * @publicApi
4664 */
4665export declare class PlatformRef {
4666 private _injector;
4667 private _modules;
4668 private _destroyListeners;
4669 private _destroyed;
4670 /**
4671 * Creates an instance of an `@NgModule` for the given platform
4672 * for offline compilation.
4673 *
4674 * @usageNotes
4675 * ### Simple Example
4676 *
4677 * ```typescript
4678 * my_module.ts:
4679 *
4680 * @NgModule({
4681 * imports: [BrowserModule]
4682 * })
4683 * class MyModule {}
4684 *
4685 * main.ts:
4686 * import {MyModuleNgFactory} from './my_module.ngfactory';
4687 * import {platformBrowser} from '@angular/platform-browser';
4688 *
4689 * let moduleRef = platformBrowser().bootstrapModuleFactory(MyModuleNgFactory);
4690 * ```
4691 */
4692 bootstrapModuleFactory<M>(moduleFactory: NgModuleFactory<M>, options?: BootstrapOptions): Promise<NgModuleRef<M>>;
4693 /**
4694 * Creates an instance of an `@NgModule` for a given platform using the given runtime compiler.
4695 *
4696 * @usageNotes
4697 * ### Simple Example
4698 *
4699 * ```typescript
4700 * @NgModule({
4701 * imports: [BrowserModule]
4702 * })
4703 * class MyModule {}
4704 *
4705 * let moduleRef = platformBrowser().bootstrapModule(MyModule);
4706 * ```
4707 *
4708 */
4709 bootstrapModule<M>(moduleType: Type<M>, compilerOptions?: (CompilerOptions & BootstrapOptions) | Array<CompilerOptions & BootstrapOptions>): Promise<NgModuleRef<M>>;
4710 private _moduleDoBootstrap;
4711 /**
4712 * Register a listener to be called when the platform is disposed.
4713 */
4714 onDestroy(callback: () => void): void;
4715 /**
4716 * Retrieve the platform {@link Injector}, which is the parent injector for
4717 * every Angular application on the page and provides singleton providers.
4718 */
4719 readonly injector: Injector;
4720 /**
4721 * Destroy the Angular platform and all Angular applications on the page.
4722 */
4723 destroy(): void;
4724 readonly destroyed: boolean;
4725}
4726
4727declare interface PlatformReflectionCapabilities {
4728 isReflectionEnabled(): boolean;
4729 factory(type: Type<any>): Function;
4730 hasLifecycleHook(type: any, lcProperty: string): boolean;
4731 guards(type: any): {
4732 [key: string]: any;
4733 };
4734 /**
4735 * Return a list of annotations/types for constructor parameters
4736 */
4737 parameters(type: Type<any>): any[][];
4738 /**
4739 * Return a list of annotations declared on the class
4740 */
4741 annotations(type: Type<any>): any[];
4742 /**
4743 * Return a object literal which describes the annotations on Class fields/properties.
4744 */
4745 propMetadata(typeOrFunc: Type<any>): {
4746 [key: string]: any[];
4747 };
4748 getter(name: string): ɵGetterFn;
4749 setter(name: string): ɵSetterFn;
4750 method(name: string): ɵMethodFn;
4751 importUri(type: Type<any>): string;
4752 resourceUri(type: Type<any>): string;
4753 resolveIdentifier(name: string, moduleUrl: string, members: string[], runtime: any): any;
4754 resolveEnum(enumIdentifier: any, name: string): any;
4755}
4756
4757/**
4758 * A boolean-valued function over a value, possibly including context information
4759 * regarding that value's position in an array.
4760 *
4761 * @publicApi
4762 */
4763export declare interface Predicate<T> {
4764 (value: T): boolean;
4765}
4766
4767declare const PREORDER_HOOK_FLAGS = 18;
4768
4769/** More flags associated with an LView (saved in LView[FLAGS_MORE]) */
4770declare const enum PreOrderHookFlags {
4771 /** The index of the next pre-order hook to be called in the hooks array, on the first 16
4772 bits */
4773 IndexOfTheNextPreOrderHookMaskMask = 65535,
4774 /**
4775 * The number of init hooks that have already been called, on the last 16 bits
4776 */
4777 NumberOfInitHooksCalledIncrementer = 65536,
4778 NumberOfInitHooksCalledShift = 16,
4779 NumberOfInitHooksCalledMask = 4294901760
4780}
4781
4782/**
4783 * Procedural style of API needed to create elements and text nodes.
4784 *
4785 * In non-native browser environments (e.g. platforms such as web-workers), this is the
4786 * facade that enables element manipulation. This also facilitates backwards compatibility
4787 * with Renderer2.
4788 */
4789declare interface ProceduralRenderer3 {
4790 destroy(): void;
4791 createComment(value: string): RComment;
4792 createElement(name: string, namespace?: string | null): RElement;
4793 createText(value: string): RText;
4794 /**
4795 * This property is allowed to be null / undefined,
4796 * in which case the view engine won't call it.
4797 * This is used as a performance optimization for production mode.
4798 */
4799 destroyNode?: ((node: RNode) => void) | null;
4800 appendChild(parent: RElement, newChild: RNode): void;
4801 insertBefore(parent: RNode, newChild: RNode, refChild: RNode | null): void;
4802 removeChild(parent: RElement, oldChild: RNode, isHostElement?: boolean): void;
4803 selectRootElement(selectorOrNode: string | any): RElement;
4804 parentNode(node: RNode): RElement | null;
4805 nextSibling(node: RNode): RNode | null;
4806 setAttribute(el: RElement, name: string, value: string, namespace?: string | null): void;
4807 removeAttribute(el: RElement, name: string, namespace?: string | null): void;
4808 addClass(el: RElement, name: string): void;
4809 removeClass(el: RElement, name: string): void;
4810 setStyle(el: RElement, style: string, value: any, flags?: RendererStyleFlags2 | RendererStyleFlags3): void;
4811 removeStyle(el: RElement, style: string, flags?: RendererStyleFlags2 | RendererStyleFlags3): void;
4812 setProperty(el: RElement, name: string, value: any): void;
4813 setValue(node: RText | RComment, value: string): void;
4814 listen(target: GlobalTargetName | RNode, eventName: string, callback: (event: any) => boolean | void): () => void;
4815}
4816
4817/**
4818 * Describes a function that is used to process provider lists (such as provider
4819 * overrides).
4820 */
4821declare type ProcessProvidersFunction = (providers: Provider[]) => Provider[];
4822
4823/**
4824 * List of slots for a projection. A slot can be either based on a parsed CSS selector
4825 * which will be used to determine nodes which are projected into that slot.
4826 *
4827 * When set to "*", the slot is reserved and can be used for multi-slot projection
4828 * using {@link ViewContainerRef#createComponent}. The last slot that specifies the
4829 * wildcard selector will retrieve all projectable nodes which do not match any selector.
4830 */
4831declare type ProjectionSlots = (ɵCssSelectorList | '*')[];
4832
4833/**
4834 * This mapping is necessary so we can set input properties and output listeners
4835 * properly at runtime when property names are minified or aliased.
4836 *
4837 * Key: unminified / public input or output name
4838 * Value: array containing minified / internal name and related directive index
4839 *
4840 * The value must be an array to support inputs and outputs with the same name
4841 * on the same node.
4842 */
4843declare type PropertyAliases = {
4844 [key: string]: PropertyAliasValue;
4845};
4846
4847/**
4848 * Store the runtime input or output names for all the directives.
4849 *
4850 * i+0: directive instance index
4851 * i+1: publicName
4852 * i+2: privateName
4853 *
4854 * e.g. [0, 'change', 'change-minified']
4855 */
4856declare type PropertyAliasValue = (number | string)[];
4857
4858/**
4859 * Describes how the `Injector` should be configured.
4860 * @see ["Dependency Injection Guide"](guide/dependency-injection).
4861 *
4862 * @see `StaticProvider`
4863 *
4864 * @publicApi
4865 */
4866export declare type Provider = TypeProvider | ValueProvider | ClassProvider | ConstructorProvider | ExistingProvider | FactoryProvider | any[];
4867
4868declare interface ProviderDef {
4869 token: any;
4870 value: any;
4871 deps: DepDef[];
4872}
4873
4874declare interface ProviderOverride {
4875 token: any;
4876 flags: ɵNodeFlags;
4877 value: any;
4878 deps: ([ɵDepFlags, any] | any)[];
4879 deprecatedBehavior: boolean;
4880}
4881
4882/**
4883 * Testability API.
4884 * `declare` keyword causes tsickle to generate externs, so these methods are
4885 * not renamed by Closure Compiler.
4886 * @publicApi
4887 */
4888declare interface PublicTestability {
4889 isStable(): boolean;
4890 whenStable(callback: Function, timeout?: number, updateCallback?: Function): void;
4891 findProviders(using: any, provider: string, exactMatch: boolean): any[];
4892}
4893
4894declare const QUERIES = 5;
4895
4896/**
4897 * Type of the Query metadata.
4898 *
4899 * @publicApi
4900 */
4901export declare interface Query {
4902 descendants: boolean;
4903 first: boolean;
4904 read: any;
4905 isViewQuery: boolean;
4906 selector: any;
4907 static: boolean;
4908}
4909
4910/**
4911 * Base class for query metadata.
4912 *
4913 * @see `ContentChildren`.
4914 * @see `ContentChild`.
4915 * @see `ViewChildren`.
4916 * @see `ViewChild`.
4917 *
4918 * @publicApi
4919 */
4920export declare abstract class Query {
4921}
4922
4923declare interface QueryBindingDef {
4924 propName: string;
4925 bindingType: ɵQueryBindingType;
4926}
4927
4928declare interface QueryDef {
4929 id: number;
4930 filterId: number;
4931 bindings: QueryBindingDef[];
4932}
4933
4934/**
4935 * An unmodifiable list of items that Angular keeps up to date when the state
4936 * of the application changes.
4937 *
4938 * The type of object that {@link ViewChildren}, {@link ContentChildren}, and {@link QueryList}
4939 * provide.
4940 *
4941 * Implements an iterable interface, therefore it can be used in both ES6
4942 * javascript `for (var i of items)` loops as well as in Angular templates with
4943 * `*ngFor="let i of myList"`.
4944 *
4945 * Changes can be observed by subscribing to the changes `Observable`.
4946 *
4947 * NOTE: In the future this class will implement an `Observable` interface.
4948 *
4949 * @usageNotes
4950 * ### Example
4951 * ```typescript
4952 * @Component({...})
4953 * class Container {
4954 * @ViewChildren(Item) items:QueryList<Item>;
4955 * }
4956 * ```
4957 *
4958 * @publicApi
4959 */
4960export declare class QueryList<T> {
4961 readonly dirty = true;
4962 private _results;
4963 readonly changes: Observable<any>;
4964 readonly length: number;
4965 readonly first: T;
4966 readonly last: T;
4967 constructor();
4968 /**
4969 * See
4970 * [Array.map](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/map)
4971 */
4972 map<U>(fn: (item: T, index: number, array: T[]) => U): U[];
4973 /**
4974 * See
4975 * [Array.filter](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/filter)
4976 */
4977 filter(fn: (item: T, index: number, array: T[]) => boolean): T[];
4978 /**
4979 * See
4980 * [Array.find](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/find)
4981 */
4982 find(fn: (item: T, index: number, array: T[]) => boolean): T | undefined;
4983 /**
4984 * See
4985 * [Array.reduce](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/reduce)
4986 */
4987 reduce<U>(fn: (prevValue: U, curValue: T, curIndex: number, array: T[]) => U, init: U): U;
4988 /**
4989 * See
4990 * [Array.forEach](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/forEach)
4991 */
4992 forEach(fn: (item: T, index: number, array: T[]) => void): void;
4993 /**
4994 * See
4995 * [Array.some](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/some)
4996 */
4997 some(fn: (value: T, index: number, array: T[]) => boolean): boolean;
4998 /**
4999 * Returns a copy of the internal results list as an Array.
5000 */
5001 toArray(): T[];
5002 toString(): string;
5003 /**
5004 * Updates the stored data of the query list, and resets the `dirty` flag to `false`, so that
5005 * on change detection, it will not notify of changes to the queries, unless a new change
5006 * occurs.
5007 *
5008 * @param resultsTree The query results to store
5009 */
5010 reset(resultsTree: Array<T | any[]>): void;
5011 /**
5012 * Triggers a change event by emitting on the `changes` {@link EventEmitter}.
5013 */
5014 notifyOnChanges(): void;
5015 /** internal */
5016 setDirty(): void;
5017 /** internal */
5018 destroy(): void;
5019}
5020
5021declare class R3Injector {
5022 readonly parent: Injector;
5023 /**
5024 * Map of tokens to records which contain the instances of those tokens.
5025 */
5026 private records;
5027 /**
5028 * The transitive set of `InjectorType`s which define this injector.
5029 */
5030 private injectorDefTypes;
5031 /**
5032 * Set of values instantiated by this injector which contain `ngOnDestroy` lifecycle hooks.
5033 */
5034 private onDestroy;
5035 /**
5036 * Flag indicating this injector provides the APP_ROOT_SCOPE token, and thus counts as the
5037 * root scope.
5038 */
5039 private readonly isRootInjector;
5040 readonly source: string | null;
5041 /**
5042 * Flag indicating that this injector was previously destroyed.
5043 */
5044 readonly destroyed: boolean;
5045 private _destroyed;
5046 constructor(def: InjectorType<any>, additionalProviders: StaticProvider[] | null, parent: Injector, source?: string | null);
5047 /**
5048 * Destroy the injector and release references to every instance or provider associated with it.
5049 *
5050 * Also calls the `OnDestroy` lifecycle hooks of every instance that was created for which a
5051 * hook was found.
5052 */
5053 destroy(): void;
5054 get<T>(token: Type<T> | InjectionToken<T>, notFoundValue?: any, flags?: InjectFlags): T;
5055 toString(): string;
5056 private assertNotDestroyed;
5057 /**
5058 * Add an `InjectorType` or `InjectorTypeWithProviders` and all of its transitive providers
5059 * to this injector.
5060 *
5061 * If an `InjectorTypeWithProviders` that declares providers besides the type is specified,
5062 * the function will return "true" to indicate that the providers of the type definition need
5063 * to be processed. This allows us to process providers of injector types after all imports of
5064 * an injector definition are processed. (following View Engine semantics: see FW-1349)
5065 */
5066 private processInjectorType;
5067 /**
5068 * Process a `SingleProvider` and add it.
5069 */
5070 private processProvider;
5071 private hydrate;
5072 private injectableDefInScope;
5073}
5074
5075declare interface Range {
5076}
5077
5078declare interface RComment extends RNode {
5079 textContent: string | null;
5080}
5081
5082declare interface RCssStyleDeclaration {
5083 removeProperty(propertyName: string): string;
5084 setProperty(propertyName: string, value: string | null, priority?: string): void;
5085}
5086
5087declare interface RDomTokenList {
5088 add(token: string): void;
5089 remove(token: string): void;
5090}
5091
5092/**
5093 * A ReflectiveDependency injection container used for instantiating objects and resolving
5094 * dependencies.
5095 *
5096 * An `Injector` is a replacement for a `new` operator, which can automatically resolve the
5097 * constructor dependencies.
5098 *
5099 * In typical use, application code asks for the dependencies in the constructor and they are
5100 * resolved by the `Injector`.
5101 *
5102 * @usageNotes
5103 * ### Example
5104 *
5105 * The following example creates an `Injector` configured to create `Engine` and `Car`.
5106 *
5107 * ```typescript
5108 * @Injectable()
5109 * class Engine {
5110 * }
5111 *
5112 * @Injectable()
5113 * class Car {
5114 * constructor(public engine:Engine) {}
5115 * }
5116 *
5117 * var injector = ReflectiveInjector.resolveAndCreate([Car, Engine]);
5118 * var car = injector.get(Car);
5119 * expect(car instanceof Car).toBe(true);
5120 * expect(car.engine instanceof Engine).toBe(true);
5121 * ```
5122 *
5123 * Notice, we don't use the `new` operator because we explicitly want to have the `Injector`
5124 * resolve all of the object's dependencies automatically.
5125 *
5126 * @deprecated from v5 - slow and brings in a lot of code, Use `Injector.create` instead.
5127 * @publicApi
5128 */
5129export declare abstract class ReflectiveInjector implements Injector {
5130 /**
5131 * Turns an array of provider definitions into an array of resolved providers.
5132 *
5133 * A resolution is a process of flattening multiple nested arrays and converting individual
5134 * providers into an array of `ResolvedReflectiveProvider`s.
5135 *
5136 * @usageNotes
5137 * ### Example
5138 *
5139 * ```typescript
5140 * @Injectable()
5141 * class Engine {
5142 * }
5143 *
5144 * @Injectable()
5145 * class Car {
5146 * constructor(public engine:Engine) {}
5147 * }
5148 *
5149 * var providers = ReflectiveInjector.resolve([Car, [[Engine]]]);
5150 *
5151 * expect(providers.length).toEqual(2);
5152 *
5153 * expect(providers[0] instanceof ResolvedReflectiveProvider).toBe(true);
5154 * expect(providers[0].key.displayName).toBe("Car");
5155 * expect(providers[0].dependencies.length).toEqual(1);
5156 * expect(providers[0].factory).toBeDefined();
5157 *
5158 * expect(providers[1].key.displayName).toBe("Engine");
5159 * });
5160 * ```
5161 *
5162 */
5163 static resolve(providers: Provider[]): ResolvedReflectiveProvider[];
5164 /**
5165 * Resolves an array of providers and creates an injector from those providers.
5166 *
5167 * The passed-in providers can be an array of `Type`, `Provider`,
5168 * or a recursive array of more providers.
5169 *
5170 * @usageNotes
5171 * ### Example
5172 *
5173 * ```typescript
5174 * @Injectable()
5175 * class Engine {
5176 * }
5177 *
5178 * @Injectable()
5179 * class Car {
5180 * constructor(public engine:Engine) {}
5181 * }
5182 *
5183 * var injector = ReflectiveInjector.resolveAndCreate([Car, Engine]);
5184 * expect(injector.get(Car) instanceof Car).toBe(true);
5185 * ```
5186 */
5187 static resolveAndCreate(providers: Provider[], parent?: Injector): ReflectiveInjector;
5188 /**
5189 * Creates an injector from previously resolved providers.
5190 *
5191 * This API is the recommended way to construct injectors in performance-sensitive parts.
5192 *
5193 * @usageNotes
5194 * ### Example
5195 *
5196 * ```typescript
5197 * @Injectable()
5198 * class Engine {
5199 * }
5200 *
5201 * @Injectable()
5202 * class Car {
5203 * constructor(public engine:Engine) {}
5204 * }
5205 *
5206 * var providers = ReflectiveInjector.resolve([Car, Engine]);
5207 * var injector = ReflectiveInjector.fromResolvedProviders(providers);
5208 * expect(injector.get(Car) instanceof Car).toBe(true);
5209 * ```
5210 */
5211 static fromResolvedProviders(providers: ResolvedReflectiveProvider[], parent?: Injector): ReflectiveInjector;
5212 /**
5213 * Parent of this injector.
5214 *
5215 * <!-- TODO: Add a link to the section of the user guide talking about hierarchical injection.
5216 * -->
5217 */
5218 abstract readonly parent: Injector | null;
5219 /**
5220 * Resolves an array of providers and creates a child injector from those providers.
5221 *
5222 * <!-- TODO: Add a link to the section of the user guide talking about hierarchical injection.
5223 * -->
5224 *
5225 * The passed-in providers can be an array of `Type`, `Provider`,
5226 * or a recursive array of more providers.
5227 *
5228 * @usageNotes
5229 * ### Example
5230 *
5231 * ```typescript
5232 * class ParentProvider {}
5233 * class ChildProvider {}
5234 *
5235 * var parent = ReflectiveInjector.resolveAndCreate([ParentProvider]);
5236 * var child = parent.resolveAndCreateChild([ChildProvider]);
5237 *
5238 * expect(child.get(ParentProvider) instanceof ParentProvider).toBe(true);
5239 * expect(child.get(ChildProvider) instanceof ChildProvider).toBe(true);
5240 * expect(child.get(ParentProvider)).toBe(parent.get(ParentProvider));
5241 * ```
5242 */
5243 abstract resolveAndCreateChild(providers: Provider[]): ReflectiveInjector;
5244 /**
5245 * Creates a child injector from previously resolved providers.
5246 *
5247 * <!-- TODO: Add a link to the section of the user guide talking about hierarchical injection.
5248 * -->
5249 *
5250 * This API is the recommended way to construct injectors in performance-sensitive parts.
5251 *
5252 * @usageNotes
5253 * ### Example
5254 *
5255 * ```typescript
5256 * class ParentProvider {}
5257 * class ChildProvider {}
5258 *
5259 * var parentProviders = ReflectiveInjector.resolve([ParentProvider]);
5260 * var childProviders = ReflectiveInjector.resolve([ChildProvider]);
5261 *
5262 * var parent = ReflectiveInjector.fromResolvedProviders(parentProviders);
5263 * var child = parent.createChildFromResolved(childProviders);
5264 *
5265 * expect(child.get(ParentProvider) instanceof ParentProvider).toBe(true);
5266 * expect(child.get(ChildProvider) instanceof ChildProvider).toBe(true);
5267 * expect(child.get(ParentProvider)).toBe(parent.get(ParentProvider));
5268 * ```
5269 */
5270 abstract createChildFromResolved(providers: ResolvedReflectiveProvider[]): ReflectiveInjector;
5271 /**
5272 * Resolves a provider and instantiates an object in the context of the injector.
5273 *
5274 * The created object does not get cached by the injector.
5275 *
5276 * @usageNotes
5277 * ### Example
5278 *
5279 * ```typescript
5280 * @Injectable()
5281 * class Engine {
5282 * }
5283 *
5284 * @Injectable()
5285 * class Car {
5286 * constructor(public engine:Engine) {}
5287 * }
5288 *
5289 * var injector = ReflectiveInjector.resolveAndCreate([Engine]);
5290 *
5291 * var car = injector.resolveAndInstantiate(Car);
5292 * expect(car.engine).toBe(injector.get(Engine));
5293 * expect(car).not.toBe(injector.resolveAndInstantiate(Car));
5294 * ```
5295 */
5296 abstract resolveAndInstantiate(provider: Provider): any;
5297 /**
5298 * Instantiates an object using a resolved provider in the context of the injector.
5299 *
5300 * The created object does not get cached by the injector.
5301 *
5302 * @usageNotes
5303 * ### Example
5304 *
5305 * ```typescript
5306 * @Injectable()
5307 * class Engine {
5308 * }
5309 *
5310 * @Injectable()
5311 * class Car {
5312 * constructor(public engine:Engine) {}
5313 * }
5314 *
5315 * var injector = ReflectiveInjector.resolveAndCreate([Engine]);
5316 * var carProvider = ReflectiveInjector.resolve([Car])[0];
5317 * var car = injector.instantiateResolved(carProvider);
5318 * expect(car.engine).toBe(injector.get(Engine));
5319 * expect(car).not.toBe(injector.instantiateResolved(carProvider));
5320 * ```
5321 */
5322 abstract instantiateResolved(provider: ResolvedReflectiveProvider): any;
5323 abstract get(token: any, notFoundValue?: any): any;
5324}
5325
5326
5327/**
5328 * A unique object used for retrieving items from the {@link ReflectiveInjector}.
5329 *
5330 * Keys have:
5331 * - a system-wide unique `id`.
5332 * - a `token`.
5333 *
5334 * `Key` is used internally by {@link ReflectiveInjector} because its system-wide unique `id` allows
5335 * the
5336 * injector to store created objects in a more efficient way.
5337 *
5338 * `Key` should not be created directly. {@link ReflectiveInjector} creates keys automatically when
5339 * resolving
5340 * providers.
5341 *
5342 * @deprecated No replacement
5343 * @publicApi
5344 */
5345export declare class ReflectiveKey {
5346 token: Object;
5347 id: number;
5348 readonly displayName: string;
5349 /**
5350 * Private
5351 */
5352 constructor(token: Object, id: number);
5353 /**
5354 * Retrieves a `Key` for a token.
5355 */
5356 static get(token: Object): ReflectiveKey;
5357 /**
5358 * @returns the number of keys registered in the system.
5359 */
5360 static readonly numberOfKeys: number;
5361}
5362
5363/**
5364 * Subset of API needed for writing attributes, properties, and setting up
5365 * listeners on Element.
5366 */
5367declare interface RElement extends RNode {
5368 style: RCssStyleDeclaration;
5369 classList: RDomTokenList;
5370 className: string;
5371 setAttribute(name: string, value: string): void;
5372 removeAttribute(name: string): void;
5373 setAttributeNS(namespaceURI: string, qualifiedName: string, value: string): void;
5374 addEventListener(type: string, listener: EventListener, useCapture?: boolean): void;
5375 removeEventListener(type: string, listener?: EventListener, options?: boolean): void;
5376 setProperty?(name: string, value: any): void;
5377}
5378
5379/**
5380 * @deprecated Use `RendererType2` (and `Renderer2`) instead.
5381 * @publicApi
5382 */
5383export declare class RenderComponentType {
5384 id: string;
5385 templateUrl: string;
5386 slotCount: number;
5387 encapsulation: ViewEncapsulation;
5388 styles: Array<string | any[]>;
5389 animations: any;
5390 constructor(id: string, templateUrl: string, slotCount: number, encapsulation: ViewEncapsulation, styles: Array<string | any[]>, animations: any);
5391}
5392
5393declare const RENDERER = 12;
5394
5395/**
5396 * @deprecated Use the `Renderer2` instead.
5397 * @publicApi
5398 */
5399export declare abstract class Renderer {
5400 abstract selectRootElement(selectorOrNode: string | any, debugInfo?: ɵRenderDebugInfo): any;
5401 abstract createElement(parentElement: any, name: string, debugInfo?: ɵRenderDebugInfo): any;
5402 abstract createViewRoot(hostElement: any): any;
5403 abstract createTemplateAnchor(parentElement: any, debugInfo?: ɵRenderDebugInfo): any;
5404 abstract createText(parentElement: any, value: string, debugInfo?: ɵRenderDebugInfo): any;
5405 abstract projectNodes(parentElement: any, nodes: any[]): void;
5406 abstract attachViewAfter(node: any, viewRootNodes: any[]): void;
5407 abstract detachView(viewRootNodes: any[]): void;
5408 abstract destroyView(hostElement: any, viewAllNodes: any[]): void;
5409 abstract listen(renderElement: any, name: string, callback: Function): Function;
5410 abstract listenGlobal(target: string, name: string, callback: Function): Function;
5411 abstract setElementProperty(renderElement: any, propertyName: string, propertyValue: any): void;
5412 abstract setElementAttribute(renderElement: any, attributeName: string, attributeValue?: string): void;
5413 /**
5414 * Used only in debug mode to serialize property changes to dom nodes as attributes.
5415 */
5416 abstract setBindingDebugInfo(renderElement: any, propertyName: string, propertyValue: string): void;
5417 abstract setElementClass(renderElement: any, className: string, isAdd: boolean): void;
5418 abstract setElementStyle(renderElement: any, styleName: string, styleValue?: string): void;
5419 abstract invokeElementMethod(renderElement: any, methodName: string, args?: any[]): void;
5420 abstract setText(renderNode: any, text: string): void;
5421 abstract animate(element: any, startingStyles: any, keyframes: any[], duration: number, delay: number, easing: string, previousPlayers?: any[]): any;
5422}
5423
5424/**
5425 * Extend this base class to implement custom rendering. By default, Angular
5426 * renders a template into DOM. You can use custom rendering to intercept
5427 * rendering calls, or to render to something other than DOM.
5428 *
5429 * Create your custom renderer using `RendererFactory2`.
5430 *
5431 * Use a custom renderer to bypass Angular's templating and
5432 * make custom UI changes that can't be expressed declaratively.
5433 * For example if you need to set a property or an attribute whose name is
5434 * not statically known, use the `setProperty()` or
5435 * `setAttribute()` method.
5436 *
5437 * @publicApi
5438 */
5439export declare abstract class Renderer2 {
5440 /**
5441 * Use to store arbitrary developer-defined data on a renderer instance,
5442 * as an object containing key-value pairs.
5443 * This is useful for renderers that delegate to other renderers.
5444 */
5445 abstract readonly data: {
5446 [key: string]: any;
5447 };
5448 /**
5449 * Implement this callback to destroy the renderer or the host element.
5450 */
5451 abstract destroy(): void;
5452 /**
5453 * Implement this callback to create an instance of the host element.
5454 * @param name An identifying name for the new element, unique within the namespace.
5455 * @param namespace The namespace for the new element.
5456 * @returns The new element.
5457 */
5458 abstract createElement(name: string, namespace?: string | null): any;
5459 /**
5460 * Implement this callback to add a comment to the DOM of the host element.
5461 * @param value The comment text.
5462 * @returns The modified element.
5463 */
5464 abstract createComment(value: string): any;
5465 /**
5466 * Implement this callback to add text to the DOM of the host element.
5467 * @param value The text string.
5468 * @returns The modified element.
5469 */
5470 abstract createText(value: string): any;
5471 /**
5472 * If null or undefined, the view engine won't call it.
5473 * This is used as a performance optimization for production mode.
5474 */
5475 destroyNode: ((node: any) => void) | null;
5476 /**
5477 * Appends a child to a given parent node in the host element DOM.
5478 * @param parent The parent node.
5479 * @param newChild The new child node.
5480 */
5481 abstract appendChild(parent: any, newChild: any): void;
5482 /**
5483 * Implement this callback to insert a child node at a given position in a parent node
5484 * in the host element DOM.
5485 * @param parent The parent node.
5486 * @param newChild The new child nodes.
5487 * @param refChild The existing child node that should precede the new node.
5488 */
5489 abstract insertBefore(parent: any, newChild: any, refChild: any): void;
5490 /**
5491 * Implement this callback to remove a child node from the host element's DOM.
5492 * @param parent The parent node.
5493 * @param oldChild The child node to remove.
5494 * @param isHostElement Optionally signal to the renderer whether this element is a host element
5495 * or not
5496 */
5497 abstract removeChild(parent: any, oldChild: any, isHostElement?: boolean): void;
5498 /**
5499 * Implement this callback to prepare an element to be bootstrapped
5500 * as a root element, and return the element instance.
5501 * @param selectorOrNode The DOM element.
5502 * @param preserveContent Whether the contents of the root element
5503 * should be preserved, or cleared upon bootstrap (default behavior).
5504 * Use with `ViewEncapsulation.ShadowDom` to allow simple native
5505 * content projection via `<slot>` elements.
5506 * @returns The root element.
5507 */
5508 abstract selectRootElement(selectorOrNode: string | any, preserveContent?: boolean): any;
5509 /**
5510 * Implement this callback to get the parent of a given node
5511 * in the host element's DOM.
5512 * @param node The child node to query.
5513 * @returns The parent node, or null if there is no parent.
5514 * For WebWorkers, always returns true.
5515 * This is because the check is synchronous,
5516 * and the caller can't rely on checking for null.
5517 */
5518 abstract parentNode(node: any): any;
5519 /**
5520 * Implement this callback to get the next sibling node of a given node
5521 * in the host element's DOM.
5522 * @returns The sibling node, or null if there is no sibling.
5523 * For WebWorkers, always returns a value.
5524 * This is because the check is synchronous,
5525 * and the caller can't rely on checking for null.
5526 */
5527 abstract nextSibling(node: any): any;
5528 /**
5529 * Implement this callback to set an attribute value for an element in the DOM.
5530 * @param el The element.
5531 * @param name The attribute name.
5532 * @param value The new value.
5533 * @param namespace The namespace.
5534 */
5535 abstract setAttribute(el: any, name: string, value: string, namespace?: string | null): void;
5536 /**
5537 * Implement this callback to remove an attribute from an element in the DOM.
5538 * @param el The element.
5539 * @param name The attribute name.
5540 * @param namespace The namespace.
5541 */
5542 abstract removeAttribute(el: any, name: string, namespace?: string | null): void;
5543 /**
5544 * Implement this callback to add a class to an element in the DOM.
5545 * @param el The element.
5546 * @param name The class name.
5547 */
5548 abstract addClass(el: any, name: string): void;
5549 /**
5550 * Implement this callback to remove a class from an element in the DOM.
5551 * @param el The element.
5552 * @param name The class name.
5553 */
5554 abstract removeClass(el: any, name: string): void;
5555 /**
5556 * Implement this callback to set a CSS style for an element in the DOM.
5557 * @param el The element.
5558 * @param style The name of the style.
5559 * @param value The new value.
5560 * @param flags Flags for style variations. No flags are set by default.
5561 */
5562 abstract setStyle(el: any, style: string, value: any, flags?: RendererStyleFlags2): void;
5563 /**
5564 * Implement this callback to remove the value from a CSS style for an element in the DOM.
5565 * @param el The element.
5566 * @param style The name of the style.
5567 * @param flags Flags for style variations to remove, if set. ???
5568 */
5569 abstract removeStyle(el: any, style: string, flags?: RendererStyleFlags2): void;
5570 /**
5571 * Implement this callback to set the value of a property of an element in the DOM.
5572 * @param el The element.
5573 * @param name The property name.
5574 * @param value The new value.
5575 */
5576 abstract setProperty(el: any, name: string, value: any): void;
5577 /**
5578 * Implement this callback to set the value of a node in the host element.
5579 * @param node The node.
5580 * @param value The new value.
5581 */
5582 abstract setValue(node: any, value: string): void;
5583 /**
5584 * Implement this callback to start an event listener.
5585 * @param target The context in which to listen for events. Can be
5586 * the entire window or document, the body of the document, or a specific
5587 * DOM element.
5588 * @param eventName The event to listen for.
5589 * @param callback A handler function to invoke when the event occurs.
5590 * @returns An "unlisten" function for disposing of this handler.
5591 */
5592 abstract listen(target: 'window' | 'document' | 'body' | any, eventName: string, callback: (event: any) => boolean | void): () => void;
5593}
5594
5595declare type Renderer3 = ObjectOrientedRenderer3 | ProceduralRenderer3;
5596
5597declare const RENDERER_FACTORY = 11;
5598
5599/**
5600 * Creates and initializes a custom renderer that implements the `Renderer2` base class.
5601 *
5602 * @publicApi
5603 */
5604export declare abstract class RendererFactory2 {
5605 /**
5606 * Creates and initializes a custom renderer for a host DOM element.
5607 * @param hostElement The element to render.
5608 * @param type The base class to implement.
5609 * @returns The new custom renderer instance.
5610 */
5611 abstract createRenderer(hostElement: any, type: RendererType2 | null): Renderer2;
5612 /**
5613 * A callback invoked when rendering has begun.
5614 */
5615 abstract begin?(): void;
5616 /**
5617 * A callback invoked when rendering has completed.
5618 */
5619 abstract end?(): void;
5620 /**
5621 * Use with animations test-only mode. Notifies the test when rendering has completed.
5622 * @returns The asynchronous result of the developer-defined function.
5623 */
5624 abstract whenRenderingDone?(): Promise<any>;
5625}
5626
5627declare interface RendererFactory3 {
5628 createRenderer(hostElement: RElement | null, rendererType: RendererType2 | null): Renderer3;
5629 begin?(): void;
5630 end?(): void;
5631}
5632
5633/**
5634 * Flags for renderer-specific style modifiers.
5635 * @publicApi
5636 */
5637export declare enum RendererStyleFlags2 {
5638 /**
5639 * Marks a style as important.
5640 */
5641 Important = 1,
5642 /**
5643 * Marks a style as using dash case naming (this-is-dash-case).
5644 */
5645 DashCase = 2
5646}
5647
5648declare enum RendererStyleFlags3 {
5649 Important = 1,
5650 DashCase = 2
5651}
5652
5653/**
5654 * Used by `RendererFactory2` to associate custom rendering data and styles
5655 * with a rendering implementation.
5656 * @publicApi
5657 */
5658export declare interface RendererType2 {
5659 /**
5660 * A unique identifying string for the new renderer, used when creating
5661 * unique styles for encapsulation.
5662 */
5663 id: string;
5664 /**
5665 * The view encapsulation type, which determines how styles are applied to
5666 * DOM elements. One of
5667 * - `Emulated` (default): Emulate native scoping of styles.
5668 * - `Native`: Use the native encapsulation mechanism of the renderer.
5669 * - `ShadowDom`: Use modern [Shadow
5670 * DOM](https://w3c.github.io/webcomponents/spec/shadow/) and
5671 * create a ShadowRoot for component's host element.
5672 * - `None`: Do not provide any template or style encapsulation.
5673 */
5674 encapsulation: ViewEncapsulation;
5675 /**
5676 * Defines CSS styles to be stored on a renderer instance.
5677 */
5678 styles: (string | any[])[];
5679 /**
5680 * Defines arbitrary developer-defined data to be stored on a renderer instance.
5681 * This is useful for renderers that delegate to other renderers.
5682 */
5683 data: {
5684 [kind: string]: any;
5685 };
5686}
5687
5688/**
5689 * An internal resolved representation of a factory function created by resolving `Provider`.
5690 * @publicApi
5691 */
5692export declare class ResolvedReflectiveFactory {
5693 /**
5694 * Factory function which can return an instance of an object represented by a key.
5695 */
5696 factory: Function;
5697 /**
5698 * Arguments (dependencies) to the `factory` function.
5699 */
5700 dependencies: ɵangular_packages_core_core_d[];
5701 constructor(
5702 /**
5703 * Factory function which can return an instance of an object represented by a key.
5704 */
5705 factory: Function,
5706 /**
5707 * Arguments (dependencies) to the `factory` function.
5708 */
5709 dependencies: ɵangular_packages_core_core_d[]);
5710}
5711
5712/**
5713 * An internal resolved representation of a `Provider` used by the `Injector`.
5714 *
5715 * @usageNotes
5716 * This is usually created automatically by `Injector.resolveAndCreate`.
5717 *
5718 * It can be created manually, as follows:
5719 *
5720 * ### Example
5721 *
5722 * ```typescript
5723 * var resolvedProviders = Injector.resolve([{ provide: 'message', useValue: 'Hello' }]);
5724 * var injector = Injector.fromResolvedProviders(resolvedProviders);
5725 *
5726 * expect(injector.get('message')).toEqual('Hello');
5727 * ```
5728 *
5729 * @publicApi
5730 */
5731export declare interface ResolvedReflectiveProvider {
5732 /**
5733 * A key, usually a `Type<any>`.
5734 */
5735 key: ReflectiveKey;
5736 /**
5737 * Factory function which can return an instance of an object represented by a key.
5738 */
5739 resolvedFactories: ResolvedReflectiveFactory[];
5740 /**
5741 * Indicates if the provider is a multi-provider or a regular provider.
5742 */
5743 multiProvider: boolean;
5744}
5745
5746/**
5747 * Lazily retrieves the reference value from a forwardRef.
5748 *
5749 * Acts as the identity function when given a non-forward-ref value.
5750 *
5751 * @usageNotes
5752 * ### Example
5753 *
5754 * {@example core/di/ts/forward_ref/forward_ref_spec.ts region='resolve_forward_ref'}
5755 *
5756 * @see `forwardRef`
5757 * @publicApi
5758 */
5759export declare function resolveForwardRef<T>(type: T): T;
5760
5761/** Subset of API needed for appending elements and text nodes. */
5762declare interface RNode {
5763 /**
5764 * Returns the parent Element, Document, or DocumentFragment
5765 */
5766 parentNode: RNode | null;
5767 /**
5768 * Returns the parent Element if there is one
5769 */
5770 parentElement: RElement | null;
5771 /**
5772 * Gets the Node immediately following this one in the parent's childNodes
5773 */
5774 nextSibling: RNode | null;
5775 /**
5776 * Removes a child from the current node and returns the removed node
5777 * @param oldChild the child node to remove
5778 */
5779 removeChild(oldChild: RNode): RNode;
5780 /**
5781 * Insert a child node.
5782 *
5783 * Used exclusively for adding View root nodes into ViewAnchor location.
5784 */
5785 insertBefore(newChild: RNode, refChild: RNode | null, isViewRoot: boolean): void;
5786 /**
5787 * Append a child node.
5788 *
5789 * Used exclusively for building up DOM which are static (ie not View roots)
5790 */
5791 appendChild(newChild: RNode): RNode;
5792}
5793
5794/**
5795 * RootContext contains information which is shared for all components which
5796 * were bootstrapped with {@link renderComponent}.
5797 */
5798declare interface RootContext {
5799 /**
5800 * A function used for scheduling change detection in the future. Usually
5801 * this is `requestAnimationFrame`.
5802 */
5803 scheduler: (workFn: () => void) => void;
5804 /**
5805 * A promise which is resolved when all components are considered clean (not dirty).
5806 *
5807 * This promise is overwritten every time a first call to {@link markDirty} is invoked.
5808 */
5809 clean: Promise<null>;
5810 /**
5811 * RootComponents - The components that were instantiated by the call to
5812 * {@link renderComponent}.
5813 */
5814 components: {}[];
5815 /**
5816 * The player flushing handler to kick off all animations
5817 */
5818 playerHandler: ɵPlayerHandler | null;
5819 /**
5820 * What render-related operations to run once a scheduler has been set
5821 */
5822 flags: RootContextFlags;
5823}
5824
5825declare const enum RootContextFlags {
5826 Empty = 0,
5827 DetectChanges = 1,
5828 FlushPlayers = 2
5829}
5830
5831declare interface RootData {
5832 injector: Injector;
5833 ngModule: NgModuleRef<any>;
5834 projectableNodes: any[][];
5835 selectorOrNode: any;
5836 renderer: Renderer2;
5837 rendererFactory: RendererFactory2;
5838 errorHandler: ErrorHandler;
5839 sanitizer: Sanitizer;
5840}
5841
5842/**
5843 * Injectable service that provides a low-level interface for modifying the UI.
5844 *
5845 * Use this service to bypass Angular's templating and make custom UI changes that can't be
5846 * expressed declaratively. For example if you need to set a property or an attribute whose name is
5847 * not statically known, use {@link Renderer#setElementProperty setElementProperty} or
5848 * {@link Renderer#setElementAttribute setElementAttribute} respectively.
5849 *
5850 * If you are implementing a custom renderer, you must implement this interface.
5851 *
5852 * The default Renderer implementation is `DomRenderer`. Also available is `WebWorkerRenderer`.
5853 *
5854 * @deprecated Use `RendererFactory2` instead.
5855 * @publicApi
5856 */
5857export declare abstract class RootRenderer {
5858 abstract renderComponent(componentType: RenderComponentType): Renderer;
5859}
5860
5861declare interface RText extends RNode {
5862 textContent: string | null;
5863}
5864
5865declare const SANITIZER = 13;
5866
5867/**
5868 * Sanitizer is used by the views to sanitize potentially dangerous values.
5869 *
5870 * @publicApi
5871 */
5872export declare abstract class Sanitizer {
5873 abstract sanitize(context: SecurityContext, value: {} | string | null): string | null;
5874}
5875
5876
5877/**
5878 * Function used to sanitize the value before writing it into the renderer.
5879 */
5880declare type SanitizerFn = (value: any, tagName?: string, propName?: string) => string;
5881
5882
5883/**
5884 * A schema definition associated with an NgModule.
5885 *
5886 * @see `@NgModule`, `CUSTOM_ELEMENTS_SCHEMA`, `NO_ERRORS_SCHEMA`
5887 *
5888 * @param name The name of a defined schema.
5889 *
5890 * @publicApi
5891 */
5892export declare interface SchemaMetadata {
5893 name: string;
5894}
5895
5896declare interface Scope {
5897 (...args: any[] /** TODO #9100 */): any;
5898}
5899
5900
5901/**
5902 * A SecurityContext marks a location that has dangerous security implications, e.g. a DOM property
5903 * like `innerHTML` that could cause Cross Site Scripting (XSS) security bugs when improperly
5904 * handled.
5905 *
5906 * See DomSanitizer for more details on security in Angular applications.
5907 *
5908 * @publicApi
5909 */
5910export declare enum SecurityContext {
5911 NONE = 0,
5912 HTML = 1,
5913 STYLE = 2,
5914 SCRIPT = 3,
5915 URL = 4,
5916 RESOURCE_URL = 5
5917}
5918
5919/** Flags used to build up CssSelectors */
5920declare const enum SelectorFlags {
5921 /** Indicates this is the beginning of a new negative selector */
5922 NOT = 1,
5923 /** Mode for matching attributes */
5924 ATTRIBUTE = 2,
5925 /** Mode for matching tag names */
5926 ELEMENT = 4,
5927 /** Mode for matching class names */
5928 CLASS = 8
5929}
5930
5931/**
5932 * Type of the Self metadata.
5933 *
5934 * @publicApi
5935 */
5936export declare interface Self {
5937}
5938
5939/**
5940 * Self decorator and metadata.
5941 *
5942 * @Annotation
5943 * @publicApi
5944 */
5945export declare const Self: SelfDecorator;
5946
5947/**
5948 * Type of the Self decorator / constructor function.
5949 *
5950 * @publicApi
5951 */
5952export declare interface SelfDecorator {
5953 /**
5954 * Parameter decorator to be used on constructor parameters,
5955 * which tells the DI framework to start dependency resolution from the local injector.
5956 *
5957 * Resolution works upward through the injector hierarchy, so the children
5958 * of this class must configure their own providers or be prepared for a null result.
5959 *
5960 * @usageNotes
5961 *
5962 * In the following example, the dependency can be resolved
5963 * by the local injector when instantiating the class itself, but not
5964 * when instantiating a child.
5965 *
5966 * <code-example path="core/di/ts/metadata_spec.ts" region="Self">
5967 * </code-example>
5968 *
5969 *
5970 * @see `SkipSelf`
5971 * @see `Optional`
5972 *
5973 */
5974 (): any;
5975 new (): Self;
5976}
5977
5978/**
5979 * Set the {@link GetTestability} implementation used by the Angular testing framework.
5980 * @publicApi
5981 */
5982export declare function setTestabilityGetter(getter: GetTestability): void;
5983
5984
5985/**
5986 * Represents a basic change from a previous to a new value for a single
5987 * property on a directive instance. Passed as a value in a
5988 * {@link SimpleChanges} object to the `ngOnChanges` hook.
5989 *
5990 * @see `OnChanges`
5991 *
5992 * @publicApi
5993 */
5994export declare class SimpleChange {
5995 previousValue: any;
5996 currentValue: any;
5997 firstChange: boolean;
5998 constructor(previousValue: any, currentValue: any, firstChange: boolean);
5999 /**
6000 * Check whether the new value is the first value assigned.
6001 */
6002 isFirstChange(): boolean;
6003}
6004
6005/**
6006 * A hashtable of changes represented by {@link SimpleChange} objects stored
6007 * at the declared property name they belong to on a Directive or Component. This is
6008 * the type passed to the `ngOnChanges` hook.
6009 *
6010 * @see `OnChanges`
6011 *
6012 * @publicApi
6013 */
6014export declare interface SimpleChanges {
6015 [propName: string]: SimpleChange;
6016}
6017
6018/**
6019 * Type of the SkipSelf metadata.
6020 *
6021 * @publicApi
6022 */
6023export declare interface SkipSelf {
6024}
6025
6026/**
6027 * SkipSelf decorator and metadata.
6028 *
6029 * @Annotation
6030 * @publicApi
6031 */
6032export declare const SkipSelf: SkipSelfDecorator;
6033
6034/**
6035 * Type of the SkipSelf decorator / constructor function.
6036 *
6037 * @publicApi
6038 */
6039export declare interface SkipSelfDecorator {
6040 /**
6041 * Parameter decorator to be used on constructor parameters,
6042 * which tells the DI framework to start dependency resolution from the parent injector.
6043 * Resolution works upward through the injector hierarchy, so the local injector
6044 * is not checked for a provider.
6045 *
6046 * @usageNotes
6047 *
6048 * In the following example, the dependency can be resolved when
6049 * instantiating a child, but not when instantiating the class itself.
6050 *
6051 * <code-example path="core/di/ts/metadata_spec.ts" region="SkipSelf">
6052 * </code-example>
6053 *
6054 * Learn more in the
6055 * [Dependency Injection guide](guide/dependency-injection-in-action#skip).
6056 *
6057 * @see `Self`
6058 * @see `Optional`
6059 *
6060 */
6061 (): any;
6062 new (): SkipSelf;
6063}
6064
6065/**
6066 * Configures the `Injector` to return an instance of `useClass` for a token.
6067 * @see ["Dependency Injection Guide"](guide/dependency-injection).
6068 *
6069 * @usageNotes
6070 *
6071 * {@example core/di/ts/provider_spec.ts region='StaticClassProvider'}
6072 *
6073 * Note that following two providers are not equal:
6074 *
6075 * {@example core/di/ts/provider_spec.ts region='StaticClassProviderDifference'}
6076 *
6077 * ### Multi-value example
6078 *
6079 * {@example core/di/ts/provider_spec.ts region='MultiProviderAspect'}
6080 *
6081 * @publicApi
6082 */
6083export declare interface StaticClassProvider extends StaticClassSansProvider {
6084 /**
6085 * An injection token. Typically an instance of `Type` or `InjectionToken`, but can be `any`.
6086 */
6087 provide: any;
6088 /**
6089 * When true, injector returns an array of instances. This is useful to allow multiple
6090 * providers spread across many files to provide configuration information to a common token.
6091 */
6092 multi?: boolean;
6093}
6094
6095/**
6096 * Configures the `Injector` to return an instance of `useClass` for a token.
6097 * Base for `StaticClassProvider` decorator.
6098 *
6099 * @publicApi
6100 */
6101export declare interface StaticClassSansProvider {
6102 /**
6103 * An optional class to instantiate for the `token`. By default, the `provide`
6104 * class is instantiated.
6105 */
6106 useClass: Type<any>;
6107 /**
6108 * A list of `token`s to be resolved by the injector. The list of values is then
6109 * used as arguments to the `useClass` constructor.
6110 */
6111 deps: any[];
6112}
6113
6114/**
6115 * Describes how the `Injector` should be configured as static (that is, without reflection).
6116 * @see ["Dependency Injection Guide"](guide/dependency-injection).
6117 *
6118 * @publicApi
6119 */
6120export declare type StaticProvider = ValueProvider | ExistingProvider | StaticClassProvider | ConstructorProvider | FactoryProvider | any[];
6121
6122/**
6123 * Used to intercept and sanitize style values before they are written to the renderer.
6124 *
6125 * This function is designed to be called in two modes. When a value is not provided
6126 * then the function will return a boolean whether a property will be sanitized later.
6127 * If a value is provided then the sanitized version of that will be returned.
6128 */
6129declare interface StyleSanitizeFn {
6130 (prop: string, value: string | null, mode?: StyleSanitizeMode): any;
6131}
6132
6133/**
6134 * A series of flags to instruct a style sanitizer to either validate
6135 * or sanitize a value.
6136 *
6137 * Because sanitization is dependent on the style property (i.e. style
6138 * sanitization for `width` is much different than for `background-image`)
6139 * the sanitization function (e.g. `StyleSanitizerFn`) needs to check a
6140 * property value first before it actually sanitizes any values.
6141 *
6142 * This enum exist to allow a style sanitization function to either only
6143 * do validation (check the property to see whether a value will be
6144 * sanitized or not) or to sanitize the value (or both).
6145 *
6146 * @publicApi
6147 */
6148declare const enum StyleSanitizeMode {
6149 /** Just check to see if the property is required to be sanitized or not */
6150 ValidateProperty = 1,
6151 /** Skip checking the property; just sanitize the value */
6152 SanitizeOnly = 2,
6153 /** Check the property and (if true) then sanitize the value */
6154 ValidateAndSanitize = 3
6155}
6156
6157/**
6158 * Array-based representation of a key/value array.
6159 *
6160 * The format of the array is "property", "value", "property2",
6161 * "value2", etc...
6162 *
6163 * The first value in the array is reserved to store the instance
6164 * of the key/value array that was used to populate the property/
6165 * value entries that take place in the remainder of the array.
6166 */
6167declare interface StylingMapArray extends Array<{} | string | number | null> {
6168 [StylingMapArrayIndex.RawValuePosition]: {} | string | null;
6169}
6170
6171/**
6172 * An index of position and offset points for any data stored within a `StylingMapArray` instance.
6173 */
6174declare const enum StylingMapArrayIndex {
6175 /** The location of the raw key/value map instance used last to populate the array entries */
6176 RawValuePosition = 0,
6177 /** Where the values start in the array */
6178 ValuesStartPosition = 1,
6179 /** The size of each property/value entry */
6180 TupleSize = 2,
6181 /** The offset for the property entry in the tuple */
6182 PropOffset = 0,
6183 /** The offset for the value entry in the tuple */
6184 ValueOffset = 1
6185}
6186
6187/**
6188 * NgModuleFactoryLoader that uses SystemJS to load NgModuleFactory
6189 * @publicApi
6190 * @deprecated the `string` form of `loadChildren` is deprecated, and `SystemJsNgModuleLoader` is
6191 * part of its implementation. See `LoadChildren` for more details.
6192 */
6193export declare class SystemJsNgModuleLoader implements NgModuleFactoryLoader {
6194 private _compiler;
6195 private _config;
6196 constructor(_compiler: Compiler, config?: SystemJsNgModuleLoaderConfig);
6197 load(path: string): Promise<NgModuleFactory<any>>;
6198 private loadAndCompile;
6199 private loadFactory;
6200}
6201
6202/**
6203 * Configuration for SystemJsNgModuleLoader.
6204 * token.
6205 *
6206 * @publicApi
6207 * @deprecated the `string` form of `loadChildren` is deprecated, and `SystemJsNgModuleLoaderConfig`
6208 * is part of its implementation. See `LoadChildren` for more details.
6209 */
6210export declare abstract class SystemJsNgModuleLoaderConfig {
6211 /**
6212 * Prefix to add when computing the name of the factory module for a given module name.
6213 */
6214 factoryPathPrefix: string;
6215 /**
6216 * Suffix to add when computing the name of the factory module for a given module name.
6217 */
6218 factoryPathSuffix: string;
6219}
6220
6221declare const T_HOST = 6;
6222
6223/**
6224 * A combination of:
6225 * - Attribute names and values.
6226 * - Special markers acting as flags to alter attributes processing.
6227 * - Parsed ngProjectAs selectors.
6228 */
6229declare type TAttributes = (string | ɵAttributeMarker | CssSelector)[];
6230
6231/** Static data for an LContainer */
6232declare interface TContainerNode extends TNode {
6233 /**
6234 * Index in the data[] array.
6235 *
6236 * If it's -1, this is a dynamically created container node that isn't stored in
6237 * data[] (e.g. when you inject ViewContainerRef) .
6238 */
6239 index: number;
6240 child: null;
6241 /**
6242 * Container nodes will have parents unless:
6243 *
6244 * - They are the first node of a component or embedded view
6245 * - They are dynamically created
6246 */
6247 parent: ɵangular_packages_core_core_bf | TElementContainerNode | null;
6248 tViews: TView | TView[] | null;
6249 projection: null;
6250}
6251
6252/**
6253 * Static data that corresponds to the instance-specific data array on an LView.
6254 *
6255 * Each node's static data is stored in tData at the same index that it's stored
6256 * in the data array. Any nodes that do not have static data store a null value in
6257 * tData to avoid a sparse array.
6258 *
6259 * Each pipe's definition is stored here at the same index as its pipe instance in
6260 * the data array.
6261 *
6262 * Each host property's name is stored here at the same index as its value in the
6263 * data array.
6264 *
6265 * Each property binding name is stored here at the same index as its value in
6266 * the data array. If the binding is an interpolation, the static string values
6267 * are stored parallel to the dynamic values. Example:
6268 *
6269 * id="prefix {{ v0 }} a {{ v1 }} b {{ v2 }} suffix"
6270 *
6271 * LView | TView.data
6272 *------------------------
6273 * v0 value | 'a'
6274 * v1 value | 'b'
6275 * v2 value | id � prefix � suffix
6276 *
6277 * Injector bloom filters are also stored here.
6278 */
6279declare type TData = (TNode | ɵPipeDef<any> | ɵDirectiveDef<any> | ɵComponentDef<any> | number | Type<any> | InjectionToken<any> | TI18n | I18nUpdateOpCodes | null | string)[];
6280
6281/** Static data for an <ng-container> */
6282declare interface TElementContainerNode extends TNode {
6283 /** Index in the LView[] array. */
6284 index: number;
6285 child: ɵangular_packages_core_core_bf | TTextNode | TContainerNode | TElementContainerNode | TProjectionNode | null;
6286 parent: ɵangular_packages_core_core_bf | TElementContainerNode | null;
6287 tViews: null;
6288 projection: null;
6289}
6290
6291/**
6292 * Represents an embedded template that can be used to instantiate embedded views.
6293 * To instantiate embedded views based on a template, use the `ViewContainerRef`
6294 * method `createEmbeddedView()`.
6295 *
6296 * Access a `TemplateRef` instance by placing a directive on an `<ng-template>`
6297 * element (or directive prefixed with `*`). The `TemplateRef` for the embedded view
6298 * is injected into the constructor of the directive,
6299 * using the `TemplateRef` token.
6300 *
6301 * You can also use a `Query` to find a `TemplateRef` associated with
6302 * a component or a directive.
6303 *
6304 * @see `ViewContainerRef`
6305 * @see [Navigate the Component Tree with DI](guide/dependency-injection-navtree)
6306 *
6307 * @publicApi
6308 */
6309export declare abstract class TemplateRef<C> {
6310 /**
6311 * The anchor element in the parent view for this embedded view.
6312 *
6313 * The data-binding and injection contexts of embedded views created from this `TemplateRef`
6314 * inherit from the contexts of this location.
6315 *
6316 * Typically new embedded views are attached to the view container of this location, but in
6317 * advanced use-cases, the view can be attached to a different container while keeping the
6318 * data-binding and injection context from the original location.
6319 *
6320 */
6321 abstract readonly elementRef: ElementRef;
6322 /**
6323 * Instantiates an embedded view based on this template,
6324 * and attaches it to the view container.
6325 * @param context The data-binding context of the embedded view, as declared
6326 * in the `<ng-template>` usage.
6327 * @returns The new embedded view object.
6328 */
6329 abstract createEmbeddedView(context: C): EmbeddedViewRef<C>;
6330}
6331
6332/**
6333 * The Testability service provides testing hooks that can be accessed from
6334 * the browser and by services such as Protractor. Each bootstrapped Angular
6335 * application on the page will have an instance of Testability.
6336 * @publicApi
6337 */
6338export declare class Testability implements PublicTestability {
6339 private _ngZone;
6340 private _pendingCount;
6341 private _isZoneStable;
6342 private _callbacks;
6343 private taskTrackingZone;
6344 constructor(_ngZone: NgZone);
6345 private _watchAngularEvents;
6346 /**
6347 * Increases the number of pending request
6348 * @deprecated pending requests are now tracked with zones.
6349 */
6350 increasePendingRequestCount(): number;
6351 /**
6352 * Decreases the number of pending request
6353 * @deprecated pending requests are now tracked with zones
6354 */
6355 decreasePendingRequestCount(): number;
6356 /**
6357 * Whether an associated application is stable
6358 */
6359 isStable(): boolean;
6360 private _runCallbacksIfReady;
6361 private getPendingTasks;
6362 private addCallback;
6363 /**
6364 * Wait for the application to be stable with a timeout. If the timeout is reached before that
6365 * happens, the callback receives a list of the macro tasks that were pending, otherwise null.
6366 *
6367 * @param doneCb The callback to invoke when Angular is stable or the timeout expires
6368 * whichever comes first.
6369 * @param timeout Optional. The maximum time to wait for Angular to become stable. If not
6370 * specified, whenStable() will wait forever.
6371 * @param updateCb Optional. If specified, this callback will be invoked whenever the set of
6372 * pending macrotasks changes. If this callback returns true doneCb will not be invoked
6373 * and no further updates will be issued.
6374 */
6375 whenStable(doneCb: Function, timeout?: number, updateCb?: Function): void;
6376 /**
6377 * Get the number of pending requests
6378 * @deprecated pending requests are now tracked with zones
6379 */
6380 getPendingRequestCount(): number;
6381 /**
6382 * Find providers by name
6383 * @param using The root element to search from
6384 * @param provider The name of binding variable
6385 * @param exactMatch Whether using exactMatch
6386 */
6387 findProviders(using: any, provider: string, exactMatch: boolean): any[];
6388}
6389
6390/**
6391 * A global registry of {@link Testability} instances for specific elements.
6392 * @publicApi
6393 */
6394export declare class TestabilityRegistry {
6395 constructor();
6396 /**
6397 * Registers an application with a testability hook so that it can be tracked
6398 * @param token token of application, root element
6399 * @param testability Testability hook
6400 */
6401 registerApplication(token: any, testability: Testability): void;
6402 /**
6403 * Unregisters an application.
6404 * @param token token of application, root element
6405 */
6406 unregisterApplication(token: any): void;
6407 /**
6408 * Unregisters all applications
6409 */
6410 unregisterAllApplications(): void;
6411 /**
6412 * Get a testability hook associated with the application
6413 * @param elem root element
6414 */
6415 getTestability(elem: any): Testability | null;
6416 /**
6417 * Get all registered testabilities
6418 */
6419 getAllTestabilities(): Testability[];
6420 /**
6421 * Get all registered applications(root elements)
6422 */
6423 getAllRootElements(): any[];
6424 /**
6425 * Find testability of a node in the Tree
6426 * @param elem node
6427 * @param findInAncestors whether finding testability in ancestors if testability was not found in
6428 * current node
6429 */
6430 findTestabilityInTree(elem: Node, findInAncestors?: boolean): Testability | null;
6431}
6432
6433declare interface TextDef {
6434 prefix: string;
6435}
6436
6437/**
6438 * Store information for the i18n translation block.
6439 */
6440declare interface TI18n {
6441 /**
6442 * Number of slots to allocate in expando.
6443 *
6444 * This is the max number of DOM elements which will be created by this i18n + ICU blocks. When
6445 * the DOM elements are being created they are stored in the EXPANDO, so that update OpCodes can
6446 * write into them.
6447 */
6448 vars: number;
6449 /**
6450 * A set of OpCodes which will create the Text Nodes and ICU anchors for the translation blocks.
6451 *
6452 * NOTE: The ICU anchors are filled in with ICU Update OpCode.
6453 */
6454 create: I18nMutateOpCodes;
6455 /**
6456 * A set of OpCodes which will be executed on each change detection to determine if any changes to
6457 * DOM are required.
6458 */
6459 update: I18nUpdateOpCodes;
6460 /**
6461 * A list of ICUs in a translation block (or `null` if block has no ICUs).
6462 *
6463 * Example:
6464 * Given: `<div i18n>You have {count, plural, ...} and {state, switch, ...}</div>`
6465 * There would be 2 ICUs in this array.
6466 * 1. `{count, plural, ...}`
6467 * 2. `{state, switch, ...}`
6468 */
6469 icus: TIcu[] | null;
6470}
6471
6472declare interface TIcu {
6473 /**
6474 * Defines the ICU type of `select` or `plural`
6475 */
6476 type: IcuType;
6477 /**
6478 * Number of slots to allocate in expando for each case.
6479 *
6480 * This is the max number of DOM elements which will be created by this i18n + ICU blocks. When
6481 * the DOM elements are being created they are stored in the EXPANDO, so that update OpCodes can
6482 * write into them.
6483 */
6484 vars: number[];
6485 /**
6486 * An optional array of child/sub ICUs.
6487 *
6488 * In case of nested ICUs such as:
6489 * ```
6490 * {�0�, plural,
6491 * =0 {zero}
6492 * other {�0� {�1�, select,
6493 * cat {cats}
6494 * dog {dogs}
6495 * other {animals}
6496 * }!
6497 * }
6498 * }
6499 * ```
6500 * When the parent ICU is changing it must clean up child ICUs as well. For this reason it needs
6501 * to know which child ICUs to run clean up for as well.
6502 *
6503 * In the above example this would be:
6504 * ```ts
6505 * [
6506 * [], // `=0` has no sub ICUs
6507 * [1], // `other` has one subICU at `1`st index.
6508 * ]
6509 * ```
6510 *
6511 * The reason why it is Array of Arrays is because first array represents the case, and second
6512 * represents the child ICUs to clean up. There may be more than one child ICUs per case.
6513 */
6514 childIcus: number[][];
6515 /**
6516 * A list of case values which the current ICU will try to match.
6517 *
6518 * The last value is `other`
6519 */
6520 cases: any[];
6521 /**
6522 * A set of OpCodes to apply in order to build up the DOM render tree for the ICU
6523 */
6524 create: I18nMutateOpCodes[];
6525 /**
6526 * A set of OpCodes to apply in order to destroy the DOM render tree for the ICU.
6527 */
6528 remove: I18nMutateOpCodes[];
6529 /**
6530 * A set of OpCodes to apply in order to update the DOM render tree for the ICU bindings.
6531 */
6532 update: I18nUpdateOpCodes[];
6533}
6534
6535/**
6536 * Binding data (flyweight) for a particular node that is shared between all templates
6537 * of a specific type.
6538 *
6539 * If a property is:
6540 * - PropertyAliases: that property's data was generated and this is it
6541 * - Null: that property's data was already generated and nothing was found.
6542 * - Undefined: that property's data has not yet been generated
6543 *
6544 * see: https://en.wikipedia.org/wiki/Flyweight_pattern for more on the Flyweight pattern
6545 */
6546declare interface TNode {
6547 /** The type of the TNode. See TNodeType. */
6548 type: TNodeType;
6549 /**
6550 * Index of the TNode in TView.data and corresponding native element in LView.
6551 *
6552 * This is necessary to get from any TNode to its corresponding native element when
6553 * traversing the node tree.
6554 *
6555 * If index is -1, this is a dynamically created container node or embedded view node.
6556 */
6557 index: number;
6558 /**
6559 * The index of the closest injector in this node's LView.
6560 *
6561 * If the index === -1, there is no injector on this node or any ancestor node in this view.
6562 *
6563 * If the index !== -1, it is the index of this node's injector OR the index of a parent injector
6564 * in the same view. We pass the parent injector index down the node tree of a view so it's
6565 * possible to find the parent injector without walking a potentially deep node tree. Injector
6566 * indices are not set across view boundaries because there could be multiple component hosts.
6567 *
6568 * If tNode.injectorIndex === tNode.parent.injectorIndex, then the index belongs to a parent
6569 * injector.
6570 */
6571 injectorIndex: number;
6572 /**
6573 * Stores starting index of the directives.
6574 */
6575 directiveStart: number;
6576 /**
6577 * Stores final exclusive index of the directives.
6578 */
6579 directiveEnd: number;
6580 /**
6581 * Stores the first index where property binding metadata is stored for
6582 * this node.
6583 */
6584 propertyMetadataStartIndex: number;
6585 /**
6586 * Stores the exclusive final index where property binding metadata is
6587 * stored for this node.
6588 */
6589 propertyMetadataEndIndex: number;
6590 /**
6591 * Stores if Node isComponent, isProjected, hasContentQuery, hasClassInput and hasStyleInput
6592 */
6593 flags: TNodeFlags;
6594 /**
6595 * This number stores two values using its bits:
6596 *
6597 * - the index of the first provider on that node (first 16 bits)
6598 * - the count of view providers from the component on this node (last 16 bits)
6599 */
6600 providerIndexes: TNodeProviderIndexes;
6601 /** The tag name associated with this node. */
6602 tagName: string | null;
6603 /**
6604 * Attributes associated with an element. We need to store attributes to support various use-cases
6605 * (attribute injection, content projection with selectors, directives matching).
6606 * Attributes are stored statically because reading them from the DOM would be way too slow for
6607 * content projection and queries.
6608 *
6609 * Since attrs will always be calculated first, they will never need to be marked undefined by
6610 * other instructions.
6611 *
6612 * For regular attributes a name of an attribute and its value alternate in the array.
6613 * e.g. ['role', 'checkbox']
6614 * This array can contain flags that will indicate "special attributes" (attributes with
6615 * namespaces, attributes extracted from bindings and outputs).
6616 */
6617 attrs: TAttributes | null;
6618 /**
6619 * A set of local names under which a given element is exported in a template and
6620 * visible to queries. An entry in this array can be created for different reasons:
6621 * - an element itself is referenced, ex.: `<div #foo>`
6622 * - a component is referenced, ex.: `<my-cmpt #foo>`
6623 * - a directive is referenced, ex.: `<my-cmpt #foo="directiveExportAs">`.
6624 *
6625 * A given element might have different local names and those names can be associated
6626 * with a directive. We store local names at even indexes while odd indexes are reserved
6627 * for directive index in a view (or `-1` if there is no associated directive).
6628 *
6629 * Some examples:
6630 * - `<div #foo>` => `["foo", -1]`
6631 * - `<my-cmpt #foo>` => `["foo", myCmptIdx]`
6632 * - `<my-cmpt #foo #bar="directiveExportAs">` => `["foo", myCmptIdx, "bar", directiveIdx]`
6633 * - `<div #foo #bar="directiveExportAs">` => `["foo", -1, "bar", directiveIdx]`
6634 */
6635 localNames: (string | number)[] | null;
6636 /** Information about input properties that need to be set once from attribute data. */
6637 initialInputs: InitialInputData | null | undefined;
6638 /**
6639 * Input data for all directives on this node.
6640 *
6641 * - `undefined` means that the prop has not been initialized yet,
6642 * - `null` means that the prop has been initialized but no inputs have been found.
6643 */
6644 inputs: PropertyAliases | null | undefined;
6645 /**
6646 * Output data for all directives on this node.
6647 *
6648 * - `undefined` means that the prop has not been initialized yet,
6649 * - `null` means that the prop has been initialized but no outputs have been found.
6650 */
6651 outputs: PropertyAliases | null | undefined;
6652 /**
6653 * The TView or TViews attached to this node.
6654 *
6655 * If this TNode corresponds to an LContainer with inline views, the container will
6656 * need to store separate static data for each of its view blocks (TView[]). Otherwise,
6657 * nodes in inline views with the same index as nodes in their parent views will overwrite
6658 * each other, as they are in the same template.
6659 *
6660 * Each index in this array corresponds to the static data for a certain
6661 * view. So if you had V(0) and V(1) in a container, you might have:
6662 *
6663 * [
6664 * [{tagName: 'div', attrs: ...}, null], // V(0) TView
6665 * [{tagName: 'button', attrs ...}, null] // V(1) TView
6666 *
6667 * If this TNode corresponds to an LContainer with a template (e.g. structural
6668 * directive), the template's TView will be stored here.
6669 *
6670 * If this TNode corresponds to an element, tViews will be null .
6671 */
6672 tViews: TView | TView[] | null;
6673 /**
6674 * The next sibling node. Necessary so we can propagate through the root nodes of a view
6675 * to insert them or remove them from the DOM.
6676 */
6677 next: TNode | null;
6678 /**
6679 * The next projected sibling. Since in Angular content projection works on the node-by-node basis
6680 * the act of projecting nodes might change nodes relationship at the insertion point (target
6681 * view). At the same time we need to keep initial relationship between nodes as expressed in
6682 * content view.
6683 */
6684 projectionNext: TNode | null;
6685 /**
6686 * First child of the current node.
6687 *
6688 * For component nodes, the child will always be a ContentChild (in same view).
6689 * For embedded view nodes, the child will be in their child view.
6690 */
6691 child: TNode | null;
6692 /**
6693 * Parent node (in the same view only).
6694 *
6695 * We need a reference to a node's parent so we can append the node to its parent's native
6696 * element at the appropriate time.
6697 *
6698 * If the parent would be in a different view (e.g. component host), this property will be null.
6699 * It's important that we don't try to cross component boundaries when retrieving the parent
6700 * because the parent will change (e.g. index, attrs) depending on where the component was
6701 * used (and thus shouldn't be stored on TNode). In these cases, we retrieve the parent through
6702 * LView.node instead (which will be instance-specific).
6703 *
6704 * If this is an inline view node (V), the parent will be its container.
6705 */
6706 parent: ɵangular_packages_core_core_bf | TContainerNode | null;
6707 /**
6708 * List of projected TNodes for a given component host element OR index into the said nodes.
6709 *
6710 * For easier discussion assume this example:
6711 * `<parent>`'s view definition:
6712 * ```
6713 * <child id="c1">content1</child>
6714 * <child id="c2"><span>content2</span></child>
6715 * ```
6716 * `<child>`'s view definition:
6717 * ```
6718 * <ng-content id="cont1"></ng-content>
6719 * ```
6720 *
6721 * If `Array.isArray(projection)` then `TNode` is a host element:
6722 * - `projection` stores the content nodes which are to be projected.
6723 * - The nodes represent categories defined by the selector: For example:
6724 * `<ng-content/><ng-content select="abc"/>` would represent the heads for `<ng-content/>`
6725 * and `<ng-content select="abc"/>` respectively.
6726 * - The nodes we store in `projection` are heads only, we used `.next` to get their
6727 * siblings.
6728 * - The nodes `.next` is sorted/rewritten as part of the projection setup.
6729 * - `projection` size is equal to the number of projections `<ng-content>`. The size of
6730 * `c1` will be `1` because `<child>` has only one `<ng-content>`.
6731 * - we store `projection` with the host (`c1`, `c2`) rather than the `<ng-content>` (`cont1`)
6732 * because the same component (`<child>`) can be used in multiple locations (`c1`, `c2`) and as
6733 * a result have different set of nodes to project.
6734 * - without `projection` it would be difficult to efficiently traverse nodes to be projected.
6735 *
6736 * If `typeof projection == 'number'` then `TNode` is a `<ng-content>` element:
6737 * - `projection` is an index of the host's `projection`Nodes.
6738 * - This would return the first head node to project:
6739 * `getHost(currentTNode).projection[currentTNode.projection]`.
6740 * - When projecting nodes the parent node retrieved may be a `<ng-content>` node, in which case
6741 * the process is recursive in nature.
6742 *
6743 * If `projection` is of type `RNode[][]` than we have a collection of native nodes passed as
6744 * projectable nodes during dynamic component creation.
6745 */
6746 projection: (TNode | RNode[])[] | number | null;
6747 /**
6748 * A collection of all style bindings and/or static style values for an element.
6749 *
6750 * This field will be populated if and when:
6751 *
6752 * - There are one or more initial styles on an element (e.g. `<div style="width:200px">`)
6753 * - There are one or more style bindings on an element (e.g. `<div [style.width]="w">`)
6754 *
6755 * If and when there are only initial styles (no bindings) then an instance of `StylingMapArray`
6756 * will be used here. Otherwise an instance of `TStylingContext` will be created when there
6757 * are one or more style bindings on an element.
6758 *
6759 * During element creation this value is likely to be populated with an instance of
6760 * `StylingMapArray` and only when the bindings are evaluated (which happens during
6761 * update mode) then it will be converted to a `TStylingContext` if any style bindings
6762 * are encountered. If and when this happens then the existing `StylingMapArray` value
6763 * will be placed into the initial styling slot in the newly created `TStylingContext`.
6764 */
6765 styles: StylingMapArray | TStylingContext | null;
6766 /**
6767 * A collection of all class bindings and/or static class values for an element.
6768 *
6769 * This field will be populated if and when:
6770 *
6771 * - There are one or more initial classes on an element (e.g. `<div class="one two three">`)
6772 * - There are one or more class bindings on an element (e.g. `<div [class.foo]="f">`)
6773 *
6774 * If and when there are only initial classes (no bindings) then an instance of `StylingMapArray`
6775 * will be used here. Otherwise an instance of `TStylingContext` will be created when there
6776 * are one or more class bindings on an element.
6777 *
6778 * During element creation this value is likely to be populated with an instance of
6779 * `StylingMapArray` and only when the bindings are evaluated (which happens during
6780 * update mode) then it will be converted to a `TStylingContext` if any class bindings
6781 * are encountered. If and when this happens then the existing `StylingMapArray` value
6782 * will be placed into the initial styling slot in the newly created `TStylingContext`.
6783 */
6784 classes: StylingMapArray | TStylingContext | null;
6785}
6786
6787/**
6788 * Corresponds to the TNode.flags property.
6789 */
6790declare const enum TNodeFlags {
6791 /** This bit is set if the node is a component */
6792 isComponent = 1,
6793 /** This bit is set if the node has been projected */
6794 isProjected = 2,
6795 /** This bit is set if any directive on this node has content queries */
6796 hasContentQuery = 4,
6797 /** This bit is set if the node has any "class" inputs */
6798 hasClassInput = 8,
6799 /** This bit is set if the node has any "style" inputs */
6800 hasStyleInput = 16,
6801 /** This bit is set if the node has been detached by i18n */
6802 isDetached = 32
6803}
6804
6805/**
6806 * Corresponds to the TNode.providerIndexes property.
6807 */
6808declare const enum TNodeProviderIndexes {
6809 /** The index of the first provider on this node is encoded on the least significant bits */
6810 ProvidersStartIndexMask = 65535,
6811 /** The count of view providers from the component on this node is encoded on the 16 most
6812 significant bits */
6813 CptViewProvidersCountShift = 16,
6814 CptViewProvidersCountShifter = 65536
6815}
6816
6817/**
6818 * TNodeType corresponds to the {@link TNode} `type` property.
6819 */
6820declare const enum TNodeType {
6821 /**
6822 * The TNode contains information about an {@link LContainer} for embedded views.
6823 */
6824 Container = 0,
6825 /**
6826 * The TNode contains information about an `<ng-content>` projection
6827 */
6828 Projection = 1,
6829 /**
6830 * The TNode contains information about an {@link LView}
6831 */
6832 View = 2,
6833 /**
6834 * The TNode contains information about a DOM element aka {@link RNode}.
6835 */
6836 Element = 3,
6837 /**
6838 * The TNode contains information about an `<ng-container>` element {@link RNode}.
6839 */
6840 ElementContainer = 4,
6841 /**
6842 * The TNode contains information about an ICU comment used in `i18n`.
6843 */
6844 IcuContainer = 5
6845}
6846
6847/**
6848 * Type representing a set of TNodes that can have local refs (`#foo`) placed on them.
6849 */
6850declare type TNodeWithLocalRefs = TContainerNode | ɵangular_packages_core_core_bf | TElementContainerNode;
6851
6852/** Static data for an LProjectionNode */
6853declare interface TProjectionNode extends TNode {
6854 /** Index in the data[] array */
6855 child: null;
6856 /**
6857 * Projection nodes will have parents unless they are the first node of a component
6858 * or embedded view (which means their parent is in a different view and must be
6859 * retrieved using LView.node).
6860 */
6861 parent: ɵangular_packages_core_core_bf | TElementContainerNode | null;
6862 tViews: null;
6863 /** Index of the projection node. (See TNode.projection for more info.) */
6864 projection: number;
6865}
6866
6867/**
6868 * TQueries represent a collection of individual TQuery objects tracked in a given view. Most of the
6869 * methods on this interface are simple proxy methods to the corresponding functionality on TQuery.
6870 */
6871declare interface TQueries {
6872 /**
6873 * Adds a new TQuery to a collection of queries tracked in a given view.
6874 * @param tQuery
6875 */
6876 track(tQuery: TQuery): void;
6877 /**
6878 * Returns a TQuery instance for at the given index in the queries array.
6879 * @param index
6880 */
6881 getByIndex(index: number): TQuery;
6882 /**
6883 * Returns the number of queries tracked in a given view.
6884 */
6885 length: number;
6886 /**
6887 * A proxy method that iterates over all the TQueries in a given TView and calls the corresponding
6888 * `elementStart` on each and every TQuery.
6889 * @param tView
6890 * @param tNode
6891 */
6892 elementStart(tView: TView, tNode: TNode): void;
6893 /**
6894 * A proxy method that iterates over all the TQueries in a given TView and calls the corresponding
6895 * `elementEnd` on each and every TQuery.
6896 * @param tNode
6897 */
6898 elementEnd(tNode: TNode): void;
6899 /**
6900 * A proxy method that iterates over all the TQueries in a given TView and calls the corresponding
6901 * `template` on each and every TQuery.
6902 * @param tView
6903 * @param tNode
6904 */
6905 template(tView: TView, tNode: TNode): void;
6906 /**
6907 * A proxy method that iterates over all the TQueries in a given TView and calls the corresponding
6908 * `embeddedTView` on each and every TQuery.
6909 * @param tNode
6910 */
6911 embeddedTView(tNode: TNode): TQueries | null;
6912}
6913
6914/**
6915 * TQuery objects represent all the query-related data that remain the same from one view instance
6916 * to another and can be determined on the very first template pass. Most notably TQuery holds all
6917 * the matches for a given view.
6918 */
6919declare interface TQuery {
6920 /**
6921 * Query metadata extracted from query annotations.
6922 */
6923 metadata: TQueryMetadata;
6924 /**
6925 * Index of a query in a declaration view in case of queries propagated to en embedded view, -1
6926 * for queries declared in a given view. We are storing this index so we can find a parent query
6927 * to clone for an embedded view (when an embedded view is created).
6928 */
6929 indexInDeclarationView: number;
6930 /**
6931 * Matches collected on the first template pass. Each match is a pair of:
6932 * - TNode index;
6933 * - match index;
6934 *
6935 * A TNode index can be either:
6936 * - a positive number (the most common case) to indicate a matching TNode;
6937 * - a negative number to indicate that a given query is crossing a <ng-template> element and
6938 * results from views created based on TemplateRef should be inserted at this place.
6939 *
6940 * A match index is a number used to find an actual value (for a given node) when query results
6941 * are materialized. This index can have one of the following values:
6942 * - -2 - indicates that we need to read a special token (TemplateRef, ViewContainerRef etc.);
6943 * - -1 - indicates that we need to read a default value based on the node type (TemplateRef for
6944 * ng-template and ElementRef for other elements);
6945 * - a positive number - index of an injectable to be read from the element injector.
6946 */
6947 matches: number[] | null;
6948 /**
6949 * A flag indicating if a given query crosses an <ng-template> element. This flag exists for
6950 * performance reasons: we can notice that queries not crossing any <ng-template> elements will
6951 * have matches from a given view only (and adapt processing accordingly).
6952 */
6953 crossesNgTemplate: boolean;
6954 /**
6955 * A method call when a given query is crossing an element (or element container). This is where a
6956 * given TNode is matched against a query predicate.
6957 * @param tView
6958 * @param tNode
6959 */
6960 elementStart(tView: TView, tNode: TNode): void;
6961 /**
6962 * A method called when processing the elementEnd instruction - this is mostly useful to determine
6963 * if a given content query should match any nodes past this point.
6964 * @param tNode
6965 */
6966 elementEnd(tNode: TNode): void;
6967 /**
6968 * A method called when processing the template instruction. This is where a
6969 * given TContainerNode is matched against a query predicate.
6970 * @param tView
6971 * @param tNode
6972 */
6973 template(tView: TView, tNode: TNode): void;
6974 /**
6975 * A query-related method called when an embedded TView is created based on the content of a
6976 * <ng-template> element. We call this method to determine if a given query should be propagated
6977 * to the embedded view and if so - return a cloned TQuery for this embedded view.
6978 * @param tNode
6979 * @param childQueryIndex
6980 */
6981 embeddedTView(tNode: TNode, childQueryIndex: number): TQuery | null;
6982}
6983
6984/**
6985 * An object representing query metadata extracted from query annotations.
6986 */
6987declare interface TQueryMetadata {
6988 predicate: Type<any> | string[];
6989 descendants: boolean;
6990 read: any;
6991 isStatic: boolean;
6992}
6993
6994/**
6995 * An optional function passed into the `NgForOf` directive that defines how to track
6996 * changes for items in an iterable.
6997 * The function takes the iteration index and item ID.
6998 * When supplied, Angular tracks changes by the return value of the function.
6999 *
7000 * @publicApi
7001 */
7002export declare interface TrackByFunction<T> {
7003 (index: number, item: T): any;
7004}
7005
7006/**
7007 * Use this token at bootstrap to provide the content of your translation file (`xtb`,
7008 * `xlf` or `xlf2`) when you want to translate your application in another language.
7009 *
7010 * See the [i18n guide](guide/i18n#merge) for more information.
7011 *
7012 * @usageNotes
7013 * ### Example
7014 *
7015 * ```typescript
7016 * import { TRANSLATIONS } from '@angular/core';
7017 * import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';
7018 * import { AppModule } from './app/app.module';
7019 *
7020 * // content of your translation file
7021 * const translations = '....';
7022 *
7023 * platformBrowserDynamic().bootstrapModule(AppModule, {
7024 * providers: [{provide: TRANSLATIONS, useValue: translations }]
7025 * });
7026 * ```
7027 *
7028 * @publicApi
7029 */
7030export declare const TRANSLATIONS: InjectionToken<string>;
7031
7032/**
7033 * Provide this token at bootstrap to set the format of your {@link TRANSLATIONS}: `xtb`,
7034 * `xlf` or `xlf2`.
7035 *
7036 * See the [i18n guide](guide/i18n#merge) for more information.
7037 *
7038 * @usageNotes
7039 * ### Example
7040 *
7041 * ```typescript
7042 * import { TRANSLATIONS_FORMAT } from '@angular/core';
7043 * import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';
7044 * import { AppModule } from './app/app.module';
7045 *
7046 * platformBrowserDynamic().bootstrapModule(AppModule, {
7047 * providers: [{provide: TRANSLATIONS_FORMAT, useValue: 'xlf' }]
7048 * });
7049 * ```
7050 *
7051 * @publicApi
7052 */
7053export declare const TRANSLATIONS_FORMAT: InjectionToken<string>;
7054
7055/**
7056 * A branded trusted string used with sanitization of `html` strings.
7057 *
7058 * See: {@link bypassSanitizationTrustHtml} and {@link htmlSanitizer}.
7059 */
7060declare interface TrustedHtmlString extends TrustedString {
7061 [BRAND]: BypassType.Html;
7062}
7063
7064/**
7065 * A branded trusted string used with sanitization of `resourceUrl` strings.
7066 *
7067 * See: {@link bypassSanitizationTrustResourceUrl} and {@link resourceUrlSanitizer}.
7068 */
7069declare interface TrustedResourceUrlString extends TrustedString {
7070 [BRAND]: BypassType.ResourceUrl;
7071}
7072
7073/**
7074 * A branded trusted string used with sanitization of `url` strings.
7075 *
7076 * See: {@link bypassSanitizationTrustScript} and {@link scriptSanitizer}.
7077 */
7078declare interface TrustedScriptString extends TrustedString {
7079 [BRAND]: BypassType.Script;
7080}
7081
7082/**
7083 * A branded trusted string used with sanitization.
7084 *
7085 * See: {@link TrustedHtmlString}, {@link TrustedResourceUrlString}, {@link TrustedScriptString},
7086 * {@link TrustedStyleString}, {@link TrustedUrlString}
7087 */
7088declare interface TrustedString extends String {
7089 [BRAND]: BypassType;
7090}
7091
7092/**
7093 * A branded trusted string used with sanitization of `style` strings.
7094 *
7095 * See: {@link bypassSanitizationTrustStyle} and {@link styleSanitizer}.
7096 */
7097declare interface TrustedStyleString extends TrustedString {
7098 [BRAND]: BypassType.Style;
7099}
7100
7101/**
7102 * A branded trusted string used with sanitization of `url` strings.
7103 *
7104 * See: {@link bypassSanitizationTrustUrl} and {@link urlSanitizer}.
7105 */
7106declare interface TrustedUrlString extends TrustedString {
7107 [BRAND]: BypassType.Url;
7108}
7109
7110/**
7111 * Tsickle has a bug where it creates an infinite loop for a function returning itself.
7112 * This is a temporary type that will be removed when the issue is resolved.
7113 * https://github.com/angular/tsickle/issues/1009)
7114 */
7115declare type TsickleIssue1009 = any;
7116
7117/**
7118 * A series of flags used to configure the config value present within a
7119 * `TStylingContext` value.
7120 */
7121declare const enum TStylingConfigFlags {
7122 /**
7123 * The initial state of the styling context config
7124 */
7125 Initial = 0,
7126 /**
7127 * A flag which marks the context as being locked.
7128 *
7129 * The styling context is constructed across an element template
7130 * function as well as any associated hostBindings functions. When
7131 * this occurs, the context itself is open to mutation and only once
7132 * it has been flushed once then it will be locked for good (no extra
7133 * bindings can be added to it).
7134 */
7135 Locked = 1,
7136 /**
7137 * Whether or not to store the state between updates in a global storage map.
7138 *
7139 * This flag helps the algorithm avoid storing all state values temporarily in
7140 * a storage map (that lives in `state.ts`). The flag is only flipped to true if
7141 * and when an element contains style/class bindings that exist both on the
7142 * template-level as well as within host bindings on the same element. This is a
7143 * rare case, and a storage map is required so that the state values can be restored
7144 * between the template code running and the host binding code executing.
7145 */
7146 PersistStateValues = 2,
7147 /** A Mask of all the configurations */
7148 Mask = 3,
7149 /** Total amount of configuration bits used */
7150 TotalBits = 2
7151}
7152
7153/**
7154 * --------
7155 *
7156 * This file contains the core interfaces for styling in Angular.
7157 *
7158 * To learn more about the algorithm see `TStylingContext`.
7159 *
7160 * --------
7161 */
7162/**
7163 * A static-level representation of all style or class bindings/values
7164 * associated with a `TNode`.
7165 *
7166 * The `TStylingContext` unites all template styling bindings (i.e.
7167 * `[class]` and `[style]` bindings) as well as all host-level
7168 * styling bindings (for components and directives) together into
7169 * a single manifest. It is used each time there are one or more
7170 * styling bindings present for an element.
7171 *
7172 * The styling context is stored on a `TNode` on and there are
7173 * two instances of it: one for classes and another for styles.
7174 *
7175 * ```typescript
7176 * tNode.styles = [ ... a context only for styles ... ];
7177 * tNode.classes = [ ... a context only for classes ... ];
7178 * ```
7179 *
7180 * `tNode.styles` and `tNode.classes` can be an instance of the following:
7181 *
7182 * ```typescript
7183 * tNode.styles = null; // no static styling or styling bindings active
7184 * tNode.styles = StylingMapArray; // only static values present (e.g. `<div style="width:200">`)
7185 * tNode.styles = TStylingContext; // one or more styling bindings present (e.g. `<div
7186 * [style.width]>`)
7187 * ```
7188 *
7189 * Both `tNode.styles` and `tNode.classes` are instantiated when anything
7190 * styling-related is active on an element. They are first created from
7191 * from the any of the element-level instructions (e.g. `element`,
7192 * `elementStart`, `elementHostAttrs`). When any static style/class
7193 * values are encountered they are registered on the `tNode.styles`
7194 * and `tNode.classes` data-structures. By default (when any static
7195 * values are encountered) the `tNode.styles` or `tNode.classes` values
7196 * are instances of a `StylingMapArray`. Only when style/class bindings
7197 * are detected then that styling map is converted into an instance of
7198 * `TStylingContext`.
7199 *
7200 * Due to the fact the the `TStylingContext` is stored on a `TNode`
7201 * this means that all data within the context is static. Instead of
7202 * storing actual styling binding values, the lView binding index values
7203 * are stored within the context. (static nature means it is more compact.)
7204 *
7205 * ```typescript
7206 * // <div [class.active]="c" // lView binding index = 20
7207 * // [style.width]="x" // lView binding index = 21
7208 * // [style.height]="y"> // lView binding index = 22
7209 * tNode.stylesContext = [
7210 * [], // initial values array
7211 * 0, // the context config value
7212 *
7213 * 0b001, // guard mask for width
7214 * 2, // total entries for width
7215 * 'width', // the property name
7216 * 21, // the binding location for the "x" binding in the lView
7217 * null,
7218 *
7219 * 0b010, // guard mask for height
7220 * 2, // total entries for height
7221 * 'height', // the property name
7222 * 22, // the binding location for the "y" binding in the lView
7223 * null,
7224 * ];
7225 *
7226 * tNode.classesContext = [
7227 * [], // initial values array
7228 * 0, // the context config value
7229 *
7230 * 0b001, // guard mask for active
7231 * 2, // total entries for active
7232 * 'active', // the property name
7233 * 20, // the binding location for the "c" binding in the lView
7234 * null,
7235 * ];
7236 * ```
7237 *
7238 * Entry value present in an entry (called a tuple) within the
7239 * styling context is as follows:
7240 *
7241 * ```typescript
7242 * context = [
7243 * CONFIG, // the styling context config value
7244 * //...
7245 * guardMask,
7246 * totalEntries,
7247 * propName,
7248 * bindingIndices...,
7249 * defaultValue
7250 * ];
7251 * ```
7252 *
7253 * Below is a breakdown of each value:
7254 *
7255 * - **guardMask**:
7256 * A numeric value where each bit represents a binding index
7257 * location. Each binding index location is assigned based on
7258 * a local counter value that increments each time an instruction
7259 * is called:
7260 *
7261 * ```
7262 * <div [style.width]="x" // binding index = 21 (counter index = 0)
7263 * [style.height]="y"> // binding index = 22 (counter index = 1)
7264 * ```
7265 *
7266 * In the example code above, if the `width` value where to change
7267 * then the first bit in the local bit mask value would be flipped
7268 * (and the second bit for when `height`).
7269 *
7270 * If and when there are more than 32 binding sources in the context
7271 * (more than 32 `[style/class]` bindings) then the bit masking will
7272 * overflow and we are left with a situation where a `-1` value will
7273 * represent the bit mask. Due to the way that JavaScript handles
7274 * negative values, when the bit mask is `-1` then all bits within
7275 * that value will be automatically flipped (this is a quick and
7276 * efficient way to flip all bits on the mask when a special kind
7277 * of caching scenario occurs or when there are more than 32 bindings).
7278 *
7279 * - **totalEntries**:
7280 * Each property present in the contains various binding sources of
7281 * where the styling data could come from. This includes template
7282 * level bindings, directive/component host bindings as well as the
7283 * default value (or static value) all writing to the same property.
7284 * This value depicts how many binding source entries exist for the
7285 * property.
7286 *
7287 * The reason why the totalEntries value is needed is because the
7288 * styling context is dynamic in size and it's not possible
7289 * for the flushing or update algorithms to know when and where
7290 * a property starts and ends without it.
7291 *
7292 * - **propName**:
7293 * The CSS property name or class name (e.g `width` or `active`).
7294 *
7295 * - **bindingIndices...**:
7296 * A series of numeric binding values that reflect where in the
7297 * lView to find the style/class values associated with the property.
7298 * Each value is in order in terms of priority (templates are first,
7299 * then directives and then components). When the context is flushed
7300 * and the style/class values are applied to the element (this happens
7301 * inside of the `stylingApply` instruction) then the flushing code
7302 * will keep checking each binding index against the associated lView
7303 * to find the first style/class value that is non-null.
7304 *
7305 * - **defaultValue**:
7306 * This is the default that will always be applied to the element if
7307 * and when all other binding sources return a result that is null.
7308 * Usually this value is null but it can also be a static value that
7309 * is intercepted when the tNode is first constructured (e.g.
7310 * `<div style="width:200px">` has a default value of `200px` for
7311 * the `width` property).
7312 *
7313 * Each time a new binding is encountered it is registered into the
7314 * context. The context then is continually updated until the first
7315 * styling apply call has been called (this is triggered by the
7316 * `stylingApply()` instruction for the active element).
7317 *
7318 * # How Styles/Classes are Rendered
7319 * Each time a styling instruction (e.g. `[class.name]`, `[style.prop]`,
7320 * etc...) is executed, the associated `lView` for the view is updated
7321 * at the current binding location. Also, when this happens, a local
7322 * counter value is incremented. If the binding value has changed then
7323 * a local `bitMask` variable is updated with the specific bit based
7324 * on the counter value.
7325 *
7326 * Below is a lightweight example of what happens when a single style
7327 * property is updated (i.e. `<div [style.prop]="val">`):
7328 *
7329 * ```typescript
7330 * function updateStyleProp(prop: string, value: string) {
7331 * const lView = getLView();
7332 * const bindingIndex = BINDING_INDEX++;
7333 * const indexForStyle = localStylesCounter++;
7334 * if (lView[bindingIndex] !== value) {
7335 * lView[bindingIndex] = value;
7336 * localBitMaskForStyles |= 1 << indexForStyle;
7337 * }
7338 * }
7339 * ```
7340 *
7341 * ## The Apply Algorithm
7342 * As explained above, each time a binding updates its value, the resulting
7343 * value is stored in the `lView` array. These styling values have yet to
7344 * be flushed to the element.
7345 *
7346 * Once all the styling instructions have been evaluated, then the styling
7347 * context(s) are flushed to the element. When this happens, the context will
7348 * be iterated over (property by property) and each binding source will be
7349 * examined and the first non-null value will be applied to the element.
7350 *
7351 * Let's say that we the following template code:
7352 *
7353 * ```html
7354 * <div [style.width]="w1" dir-that-set-width="w2"></div>
7355 * ```
7356 *
7357 * There are two styling bindings in the code above and they both write
7358 * to the `width` property. When styling is flushed on the element, the
7359 * algorithm will try and figure out which one of these values to write
7360 * to the element.
7361 *
7362 * In order to figure out which value to apply, the following
7363 * binding prioritization is adhered to:
7364 *
7365 * 1. First template-level styling bindings are applied (if present).
7366 * This includes things like `[style.width]` and `[class.active]`.
7367 *
7368 * 2. Second are styling-level host bindings present in directives.
7369 * (if there are sub/super directives present then the sub directives
7370 * are applied first).
7371 *
7372 * 3. Third are styling-level host bindings present in components.
7373 * (if there are sub/super components present then the sub directives
7374 * are applied first).
7375 *
7376 * This means that in the code above the styling binding present in the
7377 * template is applied first and, only if its falsy, then the directive
7378 * styling binding for width will be applied.
7379 *
7380 * ### What about map-based styling bindings?
7381 * Map-based styling bindings are activated when there are one or more
7382 * `[style]` and/or `[class]` bindings present on an element. When this
7383 * code is activated, the apply algorithm will iterate over each map
7384 * entry and apply each styling value to the element with the same
7385 * prioritization rules as above.
7386 *
7387 * For the algorithm to apply styling values efficiently, the
7388 * styling map entries must be applied in sync (property by property)
7389 * with prop-based bindings. (The map-based algorithm is described
7390 * more inside of the `render3/styling_next/map_based_bindings.ts` file.)
7391 *
7392 * ## Sanitization
7393 * Sanitization is used to prevent invalid style values from being applied to
7394 * the element.
7395 *
7396 * It is enabled in two cases:
7397 *
7398 * 1. The `styleSanitizer(sanitizerFn)` instruction was called (just before any other
7399 * styling instructions are run).
7400 *
7401 * 2. The component/directive `LView` instance has a sanitizer object attached to it
7402 * (this happens when `renderComponent` is executed with a `sanitizer` value or
7403 * if the ngModule contains a sanitizer provider attached to it).
7404 *
7405 * If and when sanitization is active then all property/value entries will be evaluated
7406 * through the active sanitizer before they are applied to the element (or the styling
7407 * debug handler).
7408 *
7409 * If a `Sanitizer` object is used (via the `LView[SANITIZER]` value) then that object
7410 * will be used for every property.
7411 *
7412 * If a `StyleSanitizerFn` function is used (via the `styleSanitizer`) then it will be
7413 * called in two ways:
7414 *
7415 * 1. property validation mode: this will be called early to mark whether a property
7416 * should be sanitized or not at during the flushing stage.
7417 *
7418 * 2. value sanitization mode: this will be called during the flushing stage and will
7419 * run the sanitizer function against the value before applying it to the element.
7420 *
7421 * If sanitization returns an empty value then that empty value will be applied
7422 * to the element.
7423 */
7424declare interface TStylingContext extends Array<number | string | number | boolean | null | StylingMapArray | {}> {
7425 /** Initial value position for static styles */
7426 [TStylingContextIndex.InitialStylingValuePosition]: StylingMapArray;
7427 /** Configuration data for the context */
7428 [TStylingContextIndex.ConfigPosition]: TStylingConfigFlags;
7429 /** Temporary value used to track directive index entries until
7430 the old styling code is fully removed. The reason why this
7431 is required is to figure out which directive is last and,
7432 when encountered, trigger a styling flush to happen */
7433 [TStylingContextIndex.LastDirectiveIndexPosition]: number;
7434 /** The bit guard value for all map-based bindings on an element */
7435 [TStylingContextIndex.MapBindingsBitGuardPosition]: number;
7436 /** The total amount of map-based bindings present on an element */
7437 [TStylingContextIndex.MapBindingsValuesCountPosition]: number;
7438 /** The prop value for map-based bindings (there actually isn't a
7439 * value at all, but this is just used in the context to avoid
7440 * having any special code to update the binding information for
7441 * map-based entries). */
7442 [TStylingContextIndex.MapBindingsPropPosition]: string;
7443}
7444
7445/**
7446 * An index of position and offset values used to natigate the `TStylingContext`.
7447 */
7448declare const enum TStylingContextIndex {
7449 InitialStylingValuePosition = 0,
7450 ConfigPosition = 1,
7451 LastDirectiveIndexPosition = 2,
7452 MapBindingsPosition = 3,
7453 MapBindingsBitGuardPosition = 3,
7454 MapBindingsValuesCountPosition = 4,
7455 MapBindingsPropPosition = 5,
7456 MapBindingsBindingsStartPosition = 6,
7457 ConfigAndGuardOffset = 0,
7458 ValuesCountOffset = 1,
7459 PropOffset = 2,
7460 BindingsStartOffset = 3,
7461 MinTupleLength = 4
7462}
7463
7464/** Static data for a text node */
7465declare interface TTextNode extends TNode {
7466 /** Index in the data[] array */
7467 index: number;
7468 child: null;
7469 /**
7470 * Text nodes will have parents unless they are the first node of a component or
7471 * embedded view (which means their parent is in a different view and must be
7472 * retrieved using LView.node).
7473 */
7474 parent: ɵangular_packages_core_core_bf | TElementContainerNode | null;
7475 tViews: null;
7476 projection: null;
7477}
7478
7479declare const TVIEW = 1;
7480
7481/**
7482 * The static data for an LView (shared between all templates of a
7483 * given type).
7484 *
7485 * Stored on the `ComponentDef.tView`.
7486 */
7487declare interface TView {
7488 /**
7489 * ID for inline views to determine whether a view is the same as the previous view
7490 * in a certain position. If it's not, we know the new view needs to be inserted
7491 * and the one that exists needs to be removed (e.g. if/else statements)
7492 *
7493 * If this is -1, then this is a component view or a dynamically created view.
7494 */
7495 readonly id: number;
7496 /**
7497 * This is a blueprint used to generate LView instances for this TView. Copying this
7498 * blueprint is faster than creating a new LView from scratch.
7499 */
7500 blueprint: ɵangular_packages_core_core_bj;
7501 /**
7502 * The template function used to refresh the view of dynamically created views
7503 * and components. Will be null for inline views.
7504 */
7505 template: ComponentTemplate<{}> | null;
7506 /**
7507 * A function containing query-related instructions.
7508 */
7509 viewQuery: ViewQueriesFunction<{}> | null;
7510 /**
7511 * Pointer to the host `TNode` (not part of this TView).
7512 *
7513 * If this is a `TViewNode` for an `LViewNode`, this is an embedded view of a container.
7514 * We need this pointer to be able to efficiently find this node when inserting the view
7515 * into an anchor.
7516 *
7517 * If this is a `TElementNode`, this is the view of a root component. It has exactly one
7518 * root TNode.
7519 *
7520 * If this is null, this is the view of a component that is not at root. We do not store
7521 * the host TNodes for child component views because they can potentially have several
7522 * different host TNodes, depending on where the component is being used. These host
7523 * TNodes cannot be shared (due to different indices, etc).
7524 */
7525 node: TViewNode | ɵangular_packages_core_core_bf | null;
7526 /** Whether or not this template has been processed. */
7527 firstTemplatePass: boolean;
7528 /** Static data equivalent of LView.data[]. Contains TNodes, PipeDefInternal or TI18n. */
7529 data: TData;
7530 /**
7531 * The binding start index is the index at which the data array
7532 * starts to store bindings only. Saving this value ensures that we
7533 * will begin reading bindings at the correct point in the array when
7534 * we are in update mode.
7535 */
7536 bindingStartIndex: number;
7537 /**
7538 * The index where the "expando" section of `LView` begins. The expando
7539 * section contains injectors, directive instances, and host binding values.
7540 * Unlike the "consts" and "vars" sections of `LView`, the length of this
7541 * section cannot be calculated at compile-time because directives are matched
7542 * at runtime to preserve locality.
7543 *
7544 * We store this start index so we know where to start checking host bindings
7545 * in `setHostBindings`.
7546 */
7547 expandoStartIndex: number;
7548 /**
7549 * Whether or not there are any static view queries tracked on this view.
7550 *
7551 * We store this so we know whether or not we should do a view query
7552 * refresh after creation mode to collect static query results.
7553 */
7554 staticViewQueries: boolean;
7555 /**
7556 * Whether or not there are any static content queries tracked on this view.
7557 *
7558 * We store this so we know whether or not we should do a content query
7559 * refresh after creation mode to collect static query results.
7560 */
7561 staticContentQueries: boolean;
7562 /**
7563 * A reference to the first child node located in the view.
7564 */
7565 firstChild: TNode | null;
7566 /**
7567 * Set of instructions used to process host bindings efficiently.
7568 *
7569 * See VIEW_DATA.md for more information.
7570 */
7571 expandoInstructions: ExpandoInstructions | null;
7572 /**
7573 * Full registry of directives and components that may be found in this view.
7574 *
7575 * It's necessary to keep a copy of the full def list on the TView so it's possible
7576 * to render template functions without a host component.
7577 */
7578 directiveRegistry: DirectiveDefList | null;
7579 /**
7580 * Full registry of pipes that may be found in this view.
7581 *
7582 * The property is either an array of `PipeDefs`s or a function which returns the array of
7583 * `PipeDefs`s. The function is necessary to be able to support forward declarations.
7584 *
7585 * It's necessary to keep a copy of the full def list on the TView so it's possible
7586 * to render template functions without a host component.
7587 */
7588 pipeRegistry: PipeDefList | null;
7589 /**
7590 * Array of ngOnInit, ngOnChanges and ngDoCheck hooks that should be executed for this view in
7591 * creation mode.
7592 *
7593 * Even indices: Directive index
7594 * Odd indices: Hook function
7595 */
7596 preOrderHooks: HookData | null;
7597 /**
7598 * Array of ngOnChanges and ngDoCheck hooks that should be executed for this view in update mode.
7599 *
7600 * Even indices: Directive index
7601 * Odd indices: Hook function
7602 */
7603 preOrderCheckHooks: HookData | null;
7604 /**
7605 * Array of ngAfterContentInit and ngAfterContentChecked hooks that should be executed
7606 * for this view in creation mode.
7607 *
7608 * Even indices: Directive index
7609 * Odd indices: Hook function
7610 */
7611 contentHooks: HookData | null;
7612 /**
7613 * Array of ngAfterContentChecked hooks that should be executed for this view in update
7614 * mode.
7615 *
7616 * Even indices: Directive index
7617 * Odd indices: Hook function
7618 */
7619 contentCheckHooks: HookData | null;
7620 /**
7621 * Array of ngAfterViewInit and ngAfterViewChecked hooks that should be executed for
7622 * this view in creation mode.
7623 *
7624 * Even indices: Directive index
7625 * Odd indices: Hook function
7626 */
7627 viewHooks: HookData | null;
7628 /**
7629 * Array of ngAfterViewChecked hooks that should be executed for this view in
7630 * update mode.
7631 *
7632 * Even indices: Directive index
7633 * Odd indices: Hook function
7634 */
7635 viewCheckHooks: HookData | null;
7636 /**
7637 * Array of ngOnDestroy hooks that should be executed when this view is destroyed.
7638 *
7639 * Even indices: Directive index
7640 * Odd indices: Hook function
7641 */
7642 destroyHooks: HookData | null;
7643 /**
7644 * When a view is destroyed, listeners need to be released and outputs need to be
7645 * unsubscribed. This cleanup array stores both listener data (in chunks of 4)
7646 * and output data (in chunks of 2) for a particular view. Combining the arrays
7647 * saves on memory (70 bytes per array) and on a few bytes of code size (for two
7648 * separate for loops).
7649 *
7650 * If it's a native DOM listener or output subscription being stored:
7651 * 1st index is: event name `name = tView.cleanup[i+0]`
7652 * 2nd index is: index of native element or a function that retrieves global target (window,
7653 * document or body) reference based on the native element:
7654 * `typeof idxOrTargetGetter === 'function'`: global target getter function
7655 * `typeof idxOrTargetGetter === 'number'`: index of native element
7656 *
7657 * 3rd index is: index of listener function `listener = lView[CLEANUP][tView.cleanup[i+2]]`
7658 * 4th index is: `useCaptureOrIndx = tView.cleanup[i+3]`
7659 * `typeof useCaptureOrIndx == 'boolean' : useCapture boolean
7660 * `typeof useCaptureOrIndx == 'number':
7661 * `useCaptureOrIndx >= 0` `removeListener = LView[CLEANUP][useCaptureOrIndx]`
7662 * `useCaptureOrIndx < 0` `subscription = LView[CLEANUP][-useCaptureOrIndx]`
7663 *
7664 * If it's an output subscription or query list destroy hook:
7665 * 1st index is: output unsubscribe function / query list destroy function
7666 * 2nd index is: index of function context in LView.cleanupInstances[]
7667 * `tView.cleanup[i+0].call(lView[CLEANUP][tView.cleanup[i+1]])`
7668 */
7669 cleanup: any[] | null;
7670 /**
7671 * A list of element indices for child components that will need to be
7672 * refreshed when the current view has finished its check. These indices have
7673 * already been adjusted for the HEADER_OFFSET.
7674 *
7675 */
7676 components: number[] | null;
7677 /**
7678 * A collection of queries tracked in a given view.
7679 */
7680 queries: TQueries | null;
7681 /**
7682 * An array of indices pointing to directives with content queries alongside with the
7683 * corresponding
7684 * query index. Each entry in this array is a tuple of:
7685 * - index of the first content query index declared by a given directive;
7686 * - index of a directive.
7687 *
7688 * We are storing those indexes so we can refresh content queries as part of a view refresh
7689 * process.
7690 */
7691 contentQueries: number[] | null;
7692 /**
7693 * Set of schemas that declare elements to be allowed inside the view.
7694 */
7695 schemas: SchemaMetadata[] | null;
7696}
7697
7698/** Static data for a view */
7699declare interface TViewNode extends TNode {
7700 /** If -1, it's a dynamically created view. Otherwise, it is the view block ID. */
7701 index: number;
7702 child: ɵangular_packages_core_core_bf | TTextNode | TElementContainerNode | TContainerNode | TProjectionNode | null;
7703 parent: TContainerNode | null;
7704 tViews: null;
7705 projection: null;
7706}
7707
7708/**
7709 * Special location which allows easy identification of type. If we have an array which was
7710 * retrieved from the `LView` and that array has `true` at `TYPE` location, we know it is
7711 * `LContainer`.
7712 */
7713declare const TYPE = 1;
7714
7715/**
7716 * @description
7717 *
7718 * Represents a type that a Component or other object is instances of.
7719 *
7720 * An example of a `Type` is `MyCustomComponent` class, which in JavaScript is be represented by
7721 * the `MyCustomComponent` constructor function.
7722 *
7723 * @publicApi
7724 */
7725export declare const Type: FunctionConstructor;
7726
7727export declare interface Type<T> extends Function {
7728 new (...args: any[]): T;
7729}
7730
7731/**
7732 * An interface implemented by all Angular type decorators, which allows them to be used as
7733 * decorators as well as Angular syntax.
7734 *
7735 * ```
7736 * @ng.Component({...})
7737 * class MyClass {...}
7738 * ```
7739 *
7740 * @publicApi
7741 */
7742export declare interface TypeDecorator {
7743 /**
7744 * Invoke as decorator.
7745 */
7746 <T extends Type<any>>(type: T): T;
7747 (target: Object, propertyKey?: string | symbol, parameterIndex?: number): void;
7748}
7749
7750/**
7751 * Configures the `Injector` to return an instance of `Type` when `Type' is used as the token.
7752 *
7753 * Create an instance by invoking the `new` operator and supplying additional arguments.
7754 * This form is a short form of `TypeProvider`;
7755 *
7756 * For more details, see the ["Dependency Injection Guide"](guide/dependency-injection).
7757 *
7758 * @usageNotes
7759 *
7760 * {@example core/di/ts/provider_spec.ts region='TypeProvider'}
7761 *
7762 * @publicApi
7763 */
7764export declare interface TypeProvider extends Type<any> {
7765}
7766
7767/**
7768 * Configures the `Injector` to return a value for a token.
7769 * @see ["Dependency Injection Guide"](guide/dependency-injection).
7770 *
7771 * @usageNotes
7772 *
7773 * ### Example
7774 *
7775 * {@example core/di/ts/provider_spec.ts region='ValueProvider'}
7776 *
7777 * ### Multi-value example
7778 *
7779 * {@example core/di/ts/provider_spec.ts region='MultiProviderAspect'}
7780 *
7781 * @publicApi
7782 */
7783export declare interface ValueProvider extends ValueSansProvider {
7784 /**
7785 * An injection token. Typically an instance of `Type` or `InjectionToken`, but can be `any`.
7786 */
7787 provide: any;
7788 /**
7789 * When true, injector returns an array of instances. This is useful to allow multiple
7790 * providers spread across many files to provide configuration information to a common token.
7791 */
7792 multi?: boolean;
7793}
7794
7795/**
7796 * Configures the `Injector` to return a value for a token.
7797 * Base for `ValueProvider` decorator.
7798 *
7799 * @publicApi
7800 */
7801export declare interface ValueSansProvider {
7802 /**
7803 * The value to inject.
7804 */
7805 useValue: any;
7806}
7807
7808/**
7809 * @publicApi
7810 */
7811export declare const VERSION: Version;
7812
7813
7814/**
7815 * @description Represents the version of Angular
7816 *
7817 * @publicApi
7818 */
7819export declare class Version {
7820 full: string;
7821 readonly major: string;
7822 readonly minor: string;
7823 readonly patch: string;
7824 constructor(full: string);
7825}
7826
7827declare const VIEW_REFS = 8;
7828
7829/**
7830 * Type of the ViewChild metadata.
7831 *
7832 * @publicApi
7833 */
7834export declare type ViewChild = Query;
7835
7836/**
7837 * ViewChild decorator and metadata.
7838 *
7839 * @Annotation
7840 * @publicApi
7841 */
7842export declare const ViewChild: ViewChildDecorator;
7843
7844/**
7845 * Type of the ViewChild decorator / constructor function.
7846 *
7847 * @see `ViewChild`.
7848 * @publicApi
7849 */
7850export declare interface ViewChildDecorator {
7851 /**
7852 * @description
7853 * Property decorator that configures a view query.
7854 * The change detector looks for the first element or the directive matching the selector
7855 * in the view DOM. If the view DOM changes, and a new child matches the selector,
7856 * the property is updated.
7857 *
7858 * View queries are set before the `ngAfterViewInit` callback is called.
7859 *
7860 * **Metadata Properties**:
7861 *
7862 * * **selector** - The directive type or the name used for querying.
7863 * * **read** - True to read a different token from the queried elements.
7864 * * **static** - True to resolve query results before change detection runs
7865 *
7866 * When `static` is not provided, uses query results to determine the timing of query
7867 * resolution. If any query results are inside a nested view (such as `*ngIf`), the query is
7868 * resolved after change detection runs. Otherwise, it is resolved before change detection
7869 * runs.
7870 *
7871 * The following selectors are supported.
7872 * * Any class with the `@Component` or `@Directive` decorator
7873 * * A template reference variable as a string (e.g. query `<my-component #cmp></my-component>`
7874 * with `@ViewChild('cmp')`)
7875 * * Any provider defined in the child component tree of the current component (e.g.
7876 * `@ViewChild(SomeService) someService: SomeService`)
7877 * * Any provider defined through a string token (e.g. `@ViewChild('someToken') someTokenVal:
7878 * any`)
7879 * * A `TemplateRef` (e.g. query `<ng-template></ng-template>` with `@ViewChild(TemplateRef)
7880 * template;`)
7881 *
7882 * @usageNotes
7883 *
7884 * {@example core/di/ts/viewChild/view_child_example.ts region='Component'}
7885 *
7886 * ### Example 2
7887 *
7888 * {@example core/di/ts/viewChild/view_child_howto.ts region='HowTo'}
7889 *
7890 * @Annotation
7891 */
7892 (selector: Type<any> | Function | string, opts: {
7893 read?: any;
7894 static: boolean;
7895 }): any;
7896 new (selector: Type<any> | Function | string, opts: {
7897 read?: any;
7898 static: boolean;
7899 }): ViewChild;
7900}
7901
7902/**
7903 * Type of the ViewChildren metadata.
7904 *
7905 * @publicApi
7906 */
7907export declare type ViewChildren = Query;
7908
7909/**
7910 * ViewChildren decorator and metadata.
7911 *
7912 * @Annotation
7913 * @publicApi
7914 */
7915export declare const ViewChildren: ViewChildrenDecorator;
7916
7917/**
7918 * Type of the ViewChildren decorator / constructor function.
7919 *
7920 * @see `ViewChildren`.
7921 *
7922 * @publicApi
7923 */
7924export declare interface ViewChildrenDecorator {
7925 /**
7926 * Parameter decorator that configures a view query.
7927 *
7928 * Use to get the `QueryList` of elements or directives from the view DOM.
7929 * Any time a child element is added, removed, or moved, the query list will be updated,
7930 * and the changes observable of the query list will emit a new value.
7931 *
7932 * View queries are set before the `ngAfterViewInit` callback is called.
7933 *
7934 * **Metadata Properties**:
7935 *
7936 * * **selector** - The directive type or the name used for querying.
7937 * * **read** - True to read a different token from the queried elements.
7938 *
7939 * @usageNotes
7940 *
7941 * {@example core/di/ts/viewChildren/view_children_howto.ts region='HowTo'}
7942 *
7943 * ### Another example
7944 *
7945 * {@example core/di/ts/viewChildren/view_children_example.ts region='Component'}
7946 *
7947 * @Annotation
7948 */
7949 (selector: Type<any> | Function | string, opts?: {
7950 read?: any;
7951 }): any;
7952 new (selector: Type<any> | Function | string, opts?: {
7953 read?: any;
7954 }): ViewChildren;
7955}
7956
7957/**
7958 * Represents a container where one or more views can be attached to a component.
7959 *
7960 * Can contain *host views* (created by instantiating a
7961 * component with the `createComponent()` method), and *embedded views*
7962 * (created by instantiating a `TemplateRef` with the `createEmbeddedView()` method).
7963 *
7964 * A view container instance can contain other view containers,
7965 * creating a [view hierarchy](guide/glossary#view-tree).
7966 *
7967 * @see `ComponentRef`
7968 * @see `EmbeddedViewRef`
7969 *
7970 * @publicApi
7971 */
7972export declare abstract class ViewContainerRef {
7973 /**
7974 * Anchor element that specifies the location of this container in the containing view.
7975 * Each view container can have only one anchor element, and each anchor element
7976 * can have only a single view container.
7977 *
7978 * Root elements of views attached to this container become siblings of the anchor element in
7979 * the rendered view.
7980 *
7981 * Access the `ViewContainerRef` of an element by placing a `Directive` injected
7982 * with `ViewContainerRef` on the element, or use a `ViewChild` query.
7983 *
7984 * <!-- TODO: rename to anchorElement -->
7985 */
7986 abstract readonly element: ElementRef;
7987 /**
7988 * The [dependency injector](guide/glossary#injector) for this view container.
7989 */
7990 abstract readonly injector: Injector;
7991 /** @deprecated No replacement */
7992 abstract readonly parentInjector: Injector;
7993 /**
7994 * Destroys all views in this container.
7995 */
7996 abstract clear(): void;
7997 /**
7998 * Retrieves a view from this container.
7999 * @param index The 0-based index of the view to retrieve.
8000 * @returns The `ViewRef` instance, or null if the index is out of range.
8001 */
8002 abstract get(index: number): ViewRef | null;
8003 /**
8004 * Reports how many views are currently attached to this container.
8005 * @returns The number of views.
8006 */
8007 abstract readonly length: number;
8008 /**
8009 * Instantiates an embedded view and inserts it
8010 * into this container.
8011 * @param templateRef The HTML template that defines the view.
8012 * @param index The 0-based index at which to insert the new view into this container.
8013 * If not specified, appends the new view as the last entry.
8014 *
8015 * @returns The `ViewRef` instance for the newly created view.
8016 */
8017 abstract createEmbeddedView<C>(templateRef: TemplateRef<C>, context?: C, index?: number): EmbeddedViewRef<C>;
8018 /**
8019 * Instantiates a single component and inserts its host view into this container.
8020 *
8021 * @param componentFactory The factory to use.
8022 * @param index The index at which to insert the new component's host view into this container.
8023 * If not specified, appends the new view as the last entry.
8024 * @param injector The injector to use as the parent for the new component.
8025 * @param projectableNodes
8026 * @param ngModule
8027 *
8028 * @returns The new component instance, containing the host view.
8029 *
8030 */
8031 abstract createComponent<C>(componentFactory: ComponentFactory<C>, index?: number, injector?: Injector, projectableNodes?: any[][], ngModule?: NgModuleRef<any>): ComponentRef<C>;
8032 /**
8033 * Inserts a view into this container.
8034 * @param viewRef The view to insert.
8035 * @param index The 0-based index at which to insert the view.
8036 * If not specified, appends the new view as the last entry.
8037 * @returns The inserted `ViewRef` instance.
8038 *
8039 */
8040 abstract insert(viewRef: ViewRef, index?: number): ViewRef;
8041 /**
8042 * Moves a view to a new location in this container.
8043 * @param viewRef The view to move.
8044 * @param index The 0-based index of the new location.
8045 * @returns The moved `ViewRef` instance.
8046 */
8047 abstract move(viewRef: ViewRef, currentIndex: number): ViewRef;
8048 /**
8049 * Returns the index of a view within the current container.
8050 * @param viewRef The view to query.
8051 * @returns The 0-based index of the view's position in this container,
8052 * or `-1` if this container doesn't contain the view.
8053 */
8054 abstract indexOf(viewRef: ViewRef): number;
8055 /**
8056 * Destroys a view attached to this container
8057 * @param index The 0-based index of the view to destroy.
8058 * If not specified, the last view in the container is removed.
8059 */
8060 abstract remove(index?: number): void;
8061 /**
8062 * Detaches a view from this container without destroying it.
8063 * Use along with `insert()` to move a view within the current container.
8064 * @param index The 0-based index of the view to detach.
8065 * If not specified, the last view in the container is detached.
8066 */
8067 abstract detach(index?: number): ViewRef | null;
8068}
8069
8070/**
8071 * View instance data.
8072 * Attention: Adding fields to this is performance sensitive!
8073 */
8074declare interface ViewData {
8075 def: ɵViewDefinition;
8076 root: RootData;
8077 renderer: Renderer2;
8078 parentNodeDef: NodeDef | null;
8079 parent: ViewData | null;
8080 viewContainerParent: ViewData | null;
8081 component: any;
8082 context: any;
8083 nodes: {
8084 [key: number]: NodeData;
8085 };
8086 state: ViewState;
8087 oldValues: any[];
8088 disposables: DisposableFn[] | null;
8089 initIndex: number;
8090}
8091
8092declare interface ViewDefinitionFactory extends DefinitionFactory<ɵViewDefinition> {
8093}
8094
8095
8096/**
8097 * Defines template and style encapsulation options available for Component's {@link Component}.
8098 *
8099 * See {@link Component#encapsulation encapsulation}.
8100 *
8101 * @usageNotes
8102 * ### Example
8103 *
8104 * {@example core/ts/metadata/encapsulation.ts region='longform'}
8105 *
8106 * @publicApi
8107 */
8108export declare enum ViewEncapsulation {
8109 /**
8110 * Emulate `Native` scoping of styles by adding an attribute containing surrogate id to the Host
8111 * Element and pre-processing the style rules provided via {@link Component#styles styles} or
8112 * {@link Component#styleUrls styleUrls}, and adding the new Host Element attribute to all
8113 * selectors.
8114 *
8115 * This is the default option.
8116 */
8117 Emulated = 0,
8118 /**
8119 * @deprecated v6.1.0 - use {ViewEncapsulation.ShadowDom} instead.
8120 * Use the native encapsulation mechanism of the renderer.
8121 *
8122 * For the DOM this means using the deprecated [Shadow DOM
8123 * v0](https://w3c.github.io/webcomponents/spec/shadow/) and
8124 * creating a ShadowRoot for Component's Host Element.
8125 */
8126 Native = 1,
8127 /**
8128 * Don't provide any template or style encapsulation.
8129 */
8130 None = 2,
8131 /**
8132 * Use Shadow DOM to encapsulate styles.
8133 *
8134 * For the DOM this means using modern [Shadow
8135 * DOM](https://w3c.github.io/webcomponents/spec/shadow/) and
8136 * creating a ShadowRoot for Component's Host Element.
8137 */
8138 ShadowDom = 3
8139}
8140
8141declare interface viewEngine_ChangeDetectorRef_interface extends ChangeDetectorRef {
8142}
8143
8144declare interface ViewHandleEventFn {
8145 (view: ViewData, nodeIndex: number, eventName: string, event: any): boolean;
8146}
8147
8148/**
8149 * Definition of what a view queries function should look like.
8150 */
8151declare type ViewQueriesFunction<T> = <U extends T>(rf: ɵRenderFlags, ctx: U) => void;
8152
8153/**
8154 * Represents an Angular [view](guide/glossary#view),
8155 * specifically the [host view](guide/glossary#view-tree) that is defined by a component.
8156 * Also serves as the base class
8157 * that adds destroy methods for [embedded views](guide/glossary#view-tree).
8158 *
8159 * @see `EmbeddedViewRef`
8160 *
8161 * @publicApi
8162 */
8163export declare abstract class ViewRef extends ChangeDetectorRef {
8164 /**
8165 * Destroys this view and all of the data structures associated with it.
8166 */
8167 abstract destroy(): void;
8168 /**
8169 * Reports whether this view has been destroyed.
8170 * @returns True after the `destroy()` method has been called, false otherwise.
8171 */
8172 abstract readonly destroyed: boolean;
8173 /**
8174 * A lifecycle hook that provides additional developer-defined cleanup
8175 * functionality for views.
8176 * @param callback A handler function that cleans up developer-defined data
8177 * associated with a view. Called when the `destroy()` method is invoked.
8178 */
8179 abstract onDestroy(callback: Function): any /** TODO #9100 */;
8180}
8181
8182declare class ViewRef_2<T> implements EmbeddedViewRef<T>, InternalViewRef, viewEngine_ChangeDetectorRef_interface {
8183 private _context;
8184 private _componentIndex;
8185 private _appRef;
8186 private _viewContainerRef;
8187 readonly rootNodes: any[];
8188 constructor(_lView: ɵangular_packages_core_core_bj, _context: T | null, _componentIndex: number);
8189 readonly context: T;
8190 readonly destroyed: boolean;
8191 destroy(): void;
8192 onDestroy(callback: Function): void;
8193 /**
8194 * Marks a view and all of its ancestors dirty.
8195 *
8196 * It also triggers change detection by calling `scheduleTick` internally, which coalesces
8197 * multiple `markForCheck` calls to into one change detection run.
8198 *
8199 * This can be used to ensure an {@link ChangeDetectionStrategy#OnPush OnPush} component is
8200 * checked when it needs to be re-rendered but the two normal triggers haven't marked it
8201 * dirty (i.e. inputs haven't changed and events haven't fired in the view).
8202 *
8203 * <!-- TODO: Add a link to a chapter on OnPush components -->
8204 *
8205 * @usageNotes
8206 * ### Example
8207 *
8208 * ```typescript
8209 * @Component({
8210 * selector: 'my-app',
8211 * template: `Number of ticks: {{numberOfTicks}}`
8212 * changeDetection: ChangeDetectionStrategy.OnPush,
8213 * })
8214 * class AppComponent {
8215 * numberOfTicks = 0;
8216 *
8217 * constructor(private ref: ChangeDetectorRef) {
8218 * setInterval(() => {
8219 * this.numberOfTicks++;
8220 * // the following is required, otherwise the view will not be updated
8221 * this.ref.markForCheck();
8222 * }, 1000);
8223 * }
8224 * }
8225 * ```
8226 */
8227 markForCheck(): void;
8228 /**
8229 * Detaches the view from the change detection tree.
8230 *
8231 * Detached views will not be checked during change detection runs until they are
8232 * re-attached, even if they are dirty. `detach` can be used in combination with
8233 * {@link ChangeDetectorRef#detectChanges detectChanges} to implement local change
8234 * detection checks.
8235 *
8236 * <!-- TODO: Add a link to a chapter on detach/reattach/local digest -->
8237 * <!-- TODO: Add a live demo once ref.detectChanges is merged into master -->
8238 *
8239 * @usageNotes
8240 * ### Example
8241 *
8242 * The following example defines a component with a large list of readonly data.
8243 * Imagine the data changes constantly, many times per second. For performance reasons,
8244 * we want to check and update the list every five seconds. We can do that by detaching
8245 * the component's change detector and doing a local check every five seconds.
8246 *
8247 * ```typescript
8248 * class DataProvider {
8249 * // in a real application the returned data will be different every time
8250 * get data() {
8251 * return [1,2,3,4,5];
8252 * }
8253 * }
8254 *
8255 * @Component({
8256 * selector: 'giant-list',
8257 * template: `
8258 * <li *ngFor="let d of dataProvider.data">Data {{d}}</li>
8259 * `,
8260 * })
8261 * class GiantList {
8262 * constructor(private ref: ChangeDetectorRef, private dataProvider: DataProvider) {
8263 * ref.detach();
8264 * setInterval(() => {
8265 * this.ref.detectChanges();
8266 * }, 5000);
8267 * }
8268 * }
8269 *
8270 * @Component({
8271 * selector: 'app',
8272 * providers: [DataProvider],
8273 * template: `
8274 * <giant-list><giant-list>
8275 * `,
8276 * })
8277 * class App {
8278 * }
8279 * ```
8280 */
8281 detach(): void;
8282 /**
8283 * Re-attaches a view to the change detection tree.
8284 *
8285 * This can be used to re-attach views that were previously detached from the tree
8286 * using {@link ChangeDetectorRef#detach detach}. Views are attached to the tree by default.
8287 *
8288 * <!-- TODO: Add a link to a chapter on detach/reattach/local digest -->
8289 *
8290 * @usageNotes
8291 * ### Example
8292 *
8293 * The following example creates a component displaying `live` data. The component will detach
8294 * its change detector from the main change detector tree when the component's live property
8295 * is set to false.
8296 *
8297 * ```typescript
8298 * class DataProvider {
8299 * data = 1;
8300 *
8301 * constructor() {
8302 * setInterval(() => {
8303 * this.data = this.data * 2;
8304 * }, 500);
8305 * }
8306 * }
8307 *
8308 * @Component({
8309 * selector: 'live-data',
8310 * inputs: ['live'],
8311 * template: 'Data: {{dataProvider.data}}'
8312 * })
8313 * class LiveData {
8314 * constructor(private ref: ChangeDetectorRef, private dataProvider: DataProvider) {}
8315 *
8316 * set live(value) {
8317 * if (value) {
8318 * this.ref.reattach();
8319 * } else {
8320 * this.ref.detach();
8321 * }
8322 * }
8323 * }
8324 *
8325 * @Component({
8326 * selector: 'my-app',
8327 * providers: [DataProvider],
8328 * template: `
8329 * Live Update: <input type="checkbox" [(ngModel)]="live">
8330 * <live-data [live]="live"><live-data>
8331 * `,
8332 * })
8333 * class AppComponent {
8334 * live = true;
8335 * }
8336 * ```
8337 */
8338 reattach(): void;
8339 /**
8340 * Checks the view and its children.
8341 *
8342 * This can also be used in combination with {@link ChangeDetectorRef#detach detach} to implement
8343 * local change detection checks.
8344 *
8345 * <!-- TODO: Add a link to a chapter on detach/reattach/local digest -->
8346 * <!-- TODO: Add a live demo once ref.detectChanges is merged into master -->
8347 *
8348 * @usageNotes
8349 * ### Example
8350 *
8351 * The following example defines a component with a large list of readonly data.
8352 * Imagine, the data changes constantly, many times per second. For performance reasons,
8353 * we want to check and update the list every five seconds.
8354 *
8355 * We can do that by detaching the component's change detector and doing a local change detection
8356 * check every five seconds.
8357 *
8358 * See {@link ChangeDetectorRef#detach detach} for more information.
8359 */
8360 detectChanges(): void;
8361 /**
8362 * Checks the change detector and its children, and throws if any changes are detected.
8363 *
8364 * This is used in development mode to verify that running change detection doesn't
8365 * introduce other changes.
8366 */
8367 checkNoChanges(): void;
8368 attachToViewContainerRef(vcRef: ViewContainerRef): void;
8369 detachFromAppRef(): void;
8370 attachToAppRef(appRef: ApplicationRef): void;
8371 private _lookUpContext;
8372}
8373
8374/**
8375 * Bitmask of states
8376 */
8377declare const enum ViewState {
8378 BeforeFirstCheck = 1,
8379 FirstCheck = 2,
8380 Attached = 4,
8381 ChecksEnabled = 8,
8382 IsProjectedView = 16,
8383 CheckProjectedView = 32,
8384 CheckProjectedViews = 64,
8385 Destroyed = 128,
8386 InitState_Mask = 1792,
8387 InitState_BeforeInit = 0,
8388 InitState_CallingOnInit = 256,
8389 InitState_CallingAfterContentInit = 512,
8390 InitState_CallingAfterViewInit = 768,
8391 InitState_AfterInit = 1024,
8392 CatDetectChanges = 12,
8393 CatInit = 13
8394}
8395
8396declare interface ViewUpdateFn {
8397 (check: NodeCheckFn, view: ViewData): void;
8398}
8399
8400/**
8401 * Indicates that the result of a {@link Pipe} transformation has changed even though the
8402 * reference has not changed.
8403 *
8404 * Wrapped values are unwrapped automatically during the change detection, and the unwrapped value
8405 * is stored.
8406 *
8407 * Example:
8408 *
8409 * ```
8410 * if (this._latestValue === this._latestReturnedValue) {
8411 * return this._latestReturnedValue;
8412 * } else {
8413 * this._latestReturnedValue = this._latestValue;
8414 * return WrappedValue.wrap(this._latestValue); // this will force update
8415 * }
8416 * ```
8417 *
8418 * @publicApi
8419 */
8420export declare class WrappedValue {
8421 /** @deprecated from 5.3, use `unwrap()` instead - will switch to protected */
8422 wrapped: any;
8423 constructor(value: any);
8424 /** Creates a wrapped value. */
8425 static wrap(value: any): WrappedValue;
8426 /**
8427 * Returns the underlying value of a wrapped value.
8428 * Returns the given `value` when it is not wrapped.
8429 **/
8430 static unwrap(value: any): any;
8431 /** Returns true if `value` is a wrapped value. */
8432 static isWrapped(value: any): value is WrappedValue;
8433}
8434
8435/**
8436 * Create trace scope.
8437 *
8438 * Scopes must be strictly nested and are analogous to stack frames, but
8439 * do not have to follow the stack frames. Instead it is recommended that they follow logical
8440 * nesting. You may want to use
8441 * [Event
8442 * Signatures](http://google.github.io/tracing-framework/instrumenting-code.html#custom-events)
8443 * as they are defined in WTF.
8444 *
8445 * Used to mark scope entry. The return value is used to leave the scope.
8446 *
8447 * var myScope = wtfCreateScope('MyClass#myMethod(ascii someVal)');
8448 *
8449 * someMethod() {
8450 * var s = myScope('Foo'); // 'Foo' gets stored in tracing UI
8451 * // DO SOME WORK HERE
8452 * return wtfLeave(s, 123); // Return value 123
8453 * }
8454 *
8455 * Note, adding try-finally block around the work to ensure that `wtfLeave` gets called can
8456 * negatively impact the performance of your application. For this reason we recommend that
8457 * you don't add them to ensure that `wtfLeave` gets called. In production `wtfLeave` is a noop and
8458 * so try-finally block has no value. When debugging perf issues, skipping `wtfLeave`, do to
8459 * exception, will produce incorrect trace, but presence of exception signifies logic error which
8460 * needs to be fixed before the app should be profiled. Add try-finally only when you expect that
8461 * an exception is expected during normal execution while profiling.
8462 *
8463 * @publicApi
8464 * @deprecated the Web Tracing Framework is no longer supported in Angular
8465 */
8466export declare const wtfCreateScope: (signature: string, flags?: any) => WtfScopeFn;
8467
8468/**
8469 * Ends a async time range operation.
8470 * [range] is the return value from [wtfStartTimeRange] Async ranges only work if WTF has been
8471 * enabled.
8472 * @publicApi
8473 * @deprecated the Web Tracing Framework is no longer supported in Angular
8474 */
8475export declare const wtfEndTimeRange: (range: any) => void;
8476
8477/**
8478 * Used to mark end of Scope.
8479 *
8480 * - `scope` to end.
8481 * - `returnValue` (optional) to be passed to the WTF.
8482 *
8483 * Returns the `returnValue for easy chaining.
8484 * @publicApi
8485 * @deprecated the Web Tracing Framework is no longer supported in Angular
8486 */
8487export declare const wtfLeave: <T>(scope: any, returnValue?: T) => T;
8488
8489
8490/**
8491 * A scope function for the Web Tracing Framework (WTF).
8492 *
8493 * @publicApi
8494 * @deprecated the Web Tracing Framework is no longer supported in Angular
8495 */
8496export declare interface WtfScopeFn {
8497 (arg0?: any, arg1?: any): any;
8498}
8499
8500/**
8501 * Used to mark Async start. Async are similar to scope but they don't have to be strictly nested.
8502 * The return value is used in the call to [endAsync]. Async ranges only work if WTF has been
8503 * enabled.
8504 *
8505 * someMethod() {
8506 * var s = wtfStartTimeRange('HTTP:GET', 'some.url');
8507 * var future = new Future.delay(5).then((_) {
8508 * wtfEndTimeRange(s);
8509 * });
8510 * }
8511 * @publicApi
8512 * @deprecated the Web Tracing Framework is no longer supported in Angular
8513 */
8514export declare const wtfStartTimeRange: (rangeType: string, action: string) => any;
8515
8516/**
8517 * Sanitizes the given unsafe, untrusted HTML fragment, and returns HTML text that is safe to add to
8518 * the DOM in a browser environment.
8519 */
8520export declare function ɵ_sanitizeHtml(defaultDoc: any, unsafeHtmlInput: string): string;
8521
8522
8523/**
8524 * Sanitizes the given untrusted CSS style property value (i.e. not an entire object, just a single
8525 * value) and returns a value that is safe to use in a browser environment.
8526 */
8527export declare function ɵ_sanitizeStyle(value: string): string;
8528
8529
8530export declare function ɵ_sanitizeUrl(url: string): string;
8531
8532export declare const ɵALLOW_MULTIPLE_PLATFORMS: InjectionToken<boolean>;
8533
8534export declare function ɵand(flags: ɵNodeFlags, matchedQueriesDsl: null | [string | number, ɵQueryValueType][], ngContentIndex: null | number, childCount: number, handleEvent?: null | ElementHandleEventFn, templateFactory?: ViewDefinitionFactory): NodeDef;
8535
8536export declare function ɵangular_packages_core_core_a<T>(token: Type<T> | InjectionToken<T>): T;
8537
8538export declare function ɵangular_packages_core_core_a<T>(token: Type<T> | InjectionToken<T>, flags?: InjectFlags): T | null;
8539
8540export declare class ɵangular_packages_core_core_b implements Injector {
8541 get(token: any, notFoundValue?: any): any;
8542}
8543
8544/**
8545 * A change detection scheduler token for {@link RootContext}. This token is the default value used
8546 * for the default `RootContext` found in the {@link ROOT_CONTEXT} token.
8547 */
8548export declare const ɵangular_packages_core_core_ba: InjectionToken<(fn: () => void) => void>;
8549
8550/**
8551 * Inject static attribute value into directive constructor.
8552 *
8553 * This method is used with `factory` functions which are generated as part of
8554 * `defineDirective` or `defineComponent`. The method retrieves the static value
8555 * of an attribute. (Dynamic attributes are not supported since they are not resolved
8556 * at the time of injection and can change over time.)
8557 *
8558 * # Example
8559 * Given:
8560 * ```
8561 * @Component(...)
8562 * class MyComponent {
8563 * constructor(@Attribute('title') title: string) { ... }
8564 * }
8565 * ```
8566 * When instantiated with
8567 * ```
8568 * <my-component title="Hello"></my-component>
8569 * ```
8570 *
8571 * Then factory method generated is:
8572 * ```
8573 * MyComponent.ngComponentDef = defineComponent({
8574 * factory: () => new MyComponent(injectAttribute('title'))
8575 * ...
8576 * })
8577 * ```
8578 *
8579 * @publicApi
8580 */
8581export declare function ɵangular_packages_core_core_bb(tNode: TNode, attrNameToInject: string): string | null;
8582
8583export declare function ɵangular_packages_core_core_bc(): ɵangular_packages_core_core_bj;
8584
8585export declare function ɵangular_packages_core_core_bd(): TNode;
8586
8587export declare function ɵangular_packages_core_core_be<T = any>(level?: number): T;
8588
8589/** Static data for an element */
8590export declare interface ɵangular_packages_core_core_bf extends TNode {
8591 /** Index in the data[] array */
8592 index: number;
8593 child: ɵangular_packages_core_core_bf | TTextNode | TElementContainerNode | TContainerNode | TProjectionNode | null;
8594 /**
8595 * Element nodes will have parents unless they are the first node of a component or
8596 * embedded view (which means their parent is in a different view and must be
8597 * retrieved using viewData[HOST_NODE]).
8598 */
8599 parent: ɵangular_packages_core_core_bf | TElementContainerNode | null;
8600 tViews: null;
8601 /**
8602 * If this is a component TNode with projection, this will be an array of projected
8603 * TNodes or native nodes (see TNode.projection for more info). If it's a regular element node or
8604 * a component without projection, it will be null.
8605 */
8606 projection: (TNode | RNode[])[] | null;
8607}
8608
8609/**
8610 * Detects which sanitizer to use for URL property, based on tag name and prop name.
8611 *
8612 * The rules are based on the RESOURCE_URL context config from
8613 * `packages/compiler/src/schema/dom_security_schema.ts`.
8614 * If tag and prop names don't match Resource URL schema, use URL sanitizer.
8615 */
8616export declare function ɵangular_packages_core_core_bg(tag: string, prop: string): typeof ɵɵsanitizeResourceUrl;
8617
8618export declare function ɵangular_packages_core_core_bh(name: string, props?: (...args: any[]) => any, parentClass?: any): any;
8619
8620export declare function ɵangular_packages_core_core_bi(name: string, props?: (...args: any[]) => any, parentClass?: any, additionalProcessing?: (target: any, name: string, ...args: any[]) => void): any;
8621
8622/**
8623 * `LView` stores all of the information needed to process the instructions as
8624 * they are invoked from the template. Each embedded view and component view has its
8625 * own `LView`. When processing a particular view, we set the `viewData` to that
8626 * `LView`. When that view is done processing, the `viewData` is set back to
8627 * whatever the original `viewData` was before (the parent `LView`).
8628 *
8629 * Keeping separate state for each view facilities view insertion / deletion, so we
8630 * don't have to edit the data array based on which views are present.
8631 */
8632export declare interface ɵangular_packages_core_core_bj extends Array<any> {
8633 /**
8634 * The host node for this LView instance, if this is a component view.
8635 * If this is an embedded view, HOST will be null.
8636 */
8637 [HOST]: RElement | null;
8638 /**
8639 * The static data for this view. We need a reference to this so we can easily walk up the
8640 * node tree in DI and get the TView.data array associated with a node (where the
8641 * directive defs are stored).
8642 */
8643 readonly [TVIEW]: TView;
8644 /** Flags for this view. See LViewFlags for more info. */
8645 [FLAGS]: LViewFlags;
8646 /**
8647 * This may store an {@link LView} or {@link LContainer}.
8648 *
8649 * `LView` - The parent view. This is needed when we exit the view and must restore the previous
8650 * LView. Without this, the render method would have to keep a stack of
8651 * views as it is recursively rendering templates.
8652 *
8653 * `LContainer` - The current view is part of a container, and is an embedded view.
8654 */
8655 [PARENT]: ɵangular_packages_core_core_bj | LContainer | null;
8656 /**
8657 *
8658 * The next sibling LView or LContainer.
8659 *
8660 * Allows us to propagate between sibling view states that aren't in the same
8661 * container. Embedded views already have a node.next, but it is only set for
8662 * views in the same container. We need a way to link component views and views
8663 * across containers as well.
8664 */
8665 [NEXT]: ɵangular_packages_core_core_bj | LContainer | null;
8666 /** Queries active for this view - nodes from a view are reported to those queries. */
8667 [QUERIES]: LQueries | null;
8668 /**
8669 * Pointer to the `TViewNode` or `TElementNode` which represents the root of the view.
8670 *
8671 * If `TViewNode`, this is an embedded view of a container. We need this to be able to
8672 * efficiently find the `LViewNode` when inserting the view into an anchor.
8673 *
8674 * If `TElementNode`, this is the LView of a component.
8675 *
8676 * If null, this is the root view of an application (root component is in this view).
8677 */
8678 [T_HOST]: TViewNode | ɵangular_packages_core_core_bf | null;
8679 /**
8680 * The binding index we should access next.
8681 *
8682 * This is stored so that bindings can continue where they left off
8683 * if a view is left midway through processing bindings (e.g. if there is
8684 * a setter that creates an embedded view, like in ngIf).
8685 */
8686 [BINDING_INDEX]: number;
8687 /**
8688 * When a view is destroyed, listeners need to be released and outputs need to be
8689 * unsubscribed. This context array stores both listener functions wrapped with
8690 * their context and output subscription instances for a particular view.
8691 *
8692 * These change per LView instance, so they cannot be stored on TView. Instead,
8693 * TView.cleanup saves an index to the necessary context in this array.
8694 */
8695 [CLEANUP]: any[] | null;
8696 /**
8697 * - For dynamic views, this is the context with which to render the template (e.g.
8698 * `NgForContext`), or `{}` if not defined explicitly.
8699 * - For root view of the root component the context contains change detection data.
8700 * - For non-root components, the context is the component instance,
8701 * - For inline views, the context is null.
8702 */
8703 [CONTEXT]: {} | RootContext | null;
8704 /** An optional Module Injector to be used as fall back after Element Injectors are consulted. */
8705 readonly [INJECTOR_2]: Injector | null;
8706 /** Renderer to be used for this view. */
8707 [RENDERER_FACTORY]: RendererFactory3;
8708 /** Renderer to be used for this view. */
8709 [RENDERER]: Renderer3;
8710 /** An optional custom sanitizer. */
8711 [SANITIZER]: Sanitizer | null;
8712 /**
8713 * Reference to the first LView or LContainer beneath this LView in
8714 * the hierarchy.
8715 *
8716 * Necessary to store this so views can traverse through their nested views
8717 * to remove listeners and call onDestroy callbacks.
8718 */
8719 [CHILD_HEAD]: ɵangular_packages_core_core_bj | LContainer | null;
8720 /**
8721 * The last LView or LContainer beneath this LView in the hierarchy.
8722 *
8723 * The tail allows us to quickly add a new state to the end of the view list
8724 * without having to propagate starting from the first child.
8725 */
8726 [CHILD_TAIL]: ɵangular_packages_core_core_bj | LContainer | null;
8727 /**
8728 * View where this view's template was declared.
8729 *
8730 * Only applicable for dynamically created views. Will be null for inline/component views.
8731 *
8732 * The template for a dynamically created view may be declared in a different view than
8733 * it is inserted. We already track the "insertion view" (view where the template was
8734 * inserted) in LView[PARENT], but we also need access to the "declaration view"
8735 * (view where the template was declared). Otherwise, we wouldn't be able to call the
8736 * view's template function with the proper contexts. Context should be inherited from
8737 * the declaration view tree, not the insertion view tree.
8738 *
8739 * Example (AppComponent template):
8740 *
8741 * <ng-template #foo></ng-template> <-- declared here -->
8742 * <some-comp [tpl]="foo"></some-comp> <-- inserted inside this component -->
8743 *
8744 * The <ng-template> above is declared in the AppComponent template, but it will be passed into
8745 * SomeComp and inserted there. In this case, the declaration view would be the AppComponent,
8746 * but the insertion view would be SomeComp. When we are removing views, we would want to
8747 * traverse through the insertion view to clean up listeners. When we are calling the
8748 * template function during change detection, we need the declaration view to get inherited
8749 * context.
8750 */
8751 [DECLARATION_VIEW]: ɵangular_packages_core_core_bj | null;
8752 /**
8753 * A declaration point of embedded views (ones instantiated based on the content of a
8754 * <ng-template>), null for other types of views.
8755 *
8756 * We need to track all embedded views created from a given declaration point so we can prepare
8757 * query matches in a proper order (query matches are ordered based on their declaration point and
8758 * _not_ the insertion point).
8759 */
8760 [DECLARATION_LCONTAINER]: LContainer | null;
8761 /**
8762 * More flags for this view. See PreOrderHookFlags for more info.
8763 */
8764 [PREORDER_HOOK_FLAGS]: PreOrderHookFlags;
8765}
8766
8767
8768/**
8769 * Convince closure compiler that the wrapped function has no side-effects.
8770 *
8771 * Closure compiler always assumes that `toString` has no side-effects. We use this quirk to
8772 * allow us to execute a function but have closure compiler mark the call as no-side-effects.
8773 * It is important that the return value for the `noSideEffects` function be assigned
8774 * to something which is retained otherwise the call to `noSideEffects` will be removed by closure
8775 * compiler.
8776 */
8777export declare function ɵangular_packages_core_core_bk(fn: () => void): string;
8778
8779/** Retrieves a value from any `LView` or `TData`. */
8780export declare function ɵangular_packages_core_core_bl<T>(view: ɵangular_packages_core_core_bj | TData, index: number): T;
8781
8782/**
8783 * Returns the `RootContext` instance that is associated with
8784 * the application where the target is situated. It does this by walking the parent views until it
8785 * gets to the root view, then getting the context off of that.
8786 *
8787 * @param viewOrComponent the `LView` or component to get the root context for.
8788 */
8789export declare function ɵangular_packages_core_core_bm(viewOrComponent: ɵangular_packages_core_core_bj | {}): RootContext;
8790
8791
8792export declare function ɵangular_packages_core_core_bn<T>(objWithPropertyToExtract: T): string;
8793
8794export declare class ɵangular_packages_core_core_c implements ReflectiveInjector {
8795 private static INJECTOR_KEY;
8796 readonly parent: Injector | null;
8797 keyIds: number[];
8798 objs: any[];
8799 /**
8800 * Private
8801 */
8802 constructor(_providers: ResolvedReflectiveProvider[], _parent?: Injector);
8803 get(token: any, notFoundValue?: any): any;
8804 resolveAndCreateChild(providers: Provider[]): ReflectiveInjector;
8805 createChildFromResolved(providers: ResolvedReflectiveProvider[]): ReflectiveInjector;
8806 resolveAndInstantiate(provider: Provider): any;
8807 instantiateResolved(provider: ResolvedReflectiveProvider): any;
8808 getProviderAtIndex(index: number): ResolvedReflectiveProvider;
8809 private _getMaxNumberOfObjects;
8810 private _instantiateProvider;
8811 private _instantiate;
8812 private _getByReflectiveDependency;
8813 private _getByKey;
8814 private _getObjByKeyId;
8815 readonly displayName: string;
8816 toString(): string;
8817}
8818
8819/**
8820 * `Dependency` is used by the framework to extend DI.
8821 * This is internal to Angular and should not be used directly.
8822 */
8823export declare class ɵangular_packages_core_core_d {
8824 key: ReflectiveKey;
8825 optional: boolean;
8826 visibility: Self | SkipSelf | null;
8827 constructor(key: ReflectiveKey, optional: boolean, visibility: Self | SkipSelf | null);
8828 static fromKey(key: ReflectiveKey): ɵangular_packages_core_core_d;
8829}
8830
8831/**
8832 * Resolve a list of Providers.
8833 */
8834export declare function ɵangular_packages_core_core_e(providers: Provider[]): ResolvedReflectiveProvider[];
8835
8836export declare function ɵangular_packages_core_core_f(): string;
8837
8838/**
8839 * Creates an ElementRef given a node.
8840 *
8841 * @param ElementRefToken The ElementRef type
8842 * @param tNode The node for which you'd like an ElementRef
8843 * @param view The view to which the node belongs
8844 * @returns The ElementRef instance to use
8845 */
8846export declare function ɵangular_packages_core_core_g(ElementRefToken: typeof ElementRef, tNode: TNode, view: ɵangular_packages_core_core_bj): ElementRef;
8847
8848/**
8849 * Creates a TemplateRef and stores it on the injector.
8850 *
8851 * @param TemplateRefToken The TemplateRef type
8852 * @param ElementRefToken The ElementRef type
8853 * @param hostTNode The node on which a TemplateRef is requested
8854 * @param hostView The view to which the node belongs
8855 * @returns The TemplateRef instance or null if we can't create a TemplateRef on a given node type
8856 */
8857export declare function ɵangular_packages_core_core_h<T>(TemplateRefToken: typeof TemplateRef, ElementRefToken: typeof ElementRef, hostTNode: TNode, hostView: ɵangular_packages_core_core_bj): TemplateRef<T> | null;
8858
8859export declare function ɵangular_packages_core_core_i(id: string): NgModuleFactory<any>;
8860
8861export declare class ɵangular_packages_core_core_j {
8862 readonly listeners: DebugEventListener[];
8863 readonly parent: DebugElement | null;
8864 readonly nativeNode: any;
8865 private readonly _debugContext;
8866 constructor(nativeNode: any, parent: DebugNode | null, _debugContext: ɵangular_packages_core_core_z);
8867 readonly injector: Injector;
8868 readonly componentInstance: any;
8869 readonly context: any;
8870 readonly references: {
8871 [key: string]: any;
8872 };
8873 readonly providerTokens: any[];
8874}
8875
8876export declare class ɵangular_packages_core_core_k extends ɵangular_packages_core_core_j implements DebugElement {
8877 readonly name: string;
8878 readonly properties: {
8879 [key: string]: any;
8880 };
8881 readonly attributes: {
8882 [key: string]: string | null;
8883 };
8884 readonly classes: {
8885 [key: string]: boolean;
8886 };
8887 readonly styles: {
8888 [key: string]: string | null;
8889 };
8890 readonly childNodes: DebugNode[];
8891 readonly nativeElement: any;
8892 constructor(nativeNode: any, parent: any, _debugContext: ɵangular_packages_core_core_z);
8893 addChild(child: DebugNode): void;
8894 removeChild(child: DebugNode): void;
8895 insertChildrenAfter(child: DebugNode, newChildren: DebugNode[]): void;
8896 insertBefore(refChild: DebugNode, newChild: DebugNode): void;
8897 query(predicate: Predicate<DebugElement>): DebugElement;
8898 queryAll(predicate: Predicate<DebugElement>): DebugElement[];
8899 queryAllNodes(predicate: Predicate<DebugNode>): DebugNode[];
8900 readonly children: DebugElement[];
8901 triggerEventHandler(eventName: string, eventObj: any): void;
8902}
8903
8904export declare class ɵangular_packages_core_core_l implements IterableDifferFactory {
8905 constructor();
8906 supports(obj: Object | null | undefined): boolean;
8907 create<V>(trackByFn?: TrackByFunction<V>): DefaultIterableDiffer<V>;
8908}
8909
8910export declare class ɵangular_packages_core_core_m<K, V> implements KeyValueDifferFactory {
8911 constructor();
8912 supports(obj: any): boolean;
8913 create<K, V>(): KeyValueDiffer<K, V>;
8914}
8915
8916export declare function ɵangular_packages_core_core_n(): IterableDiffers;
8917
8918export declare function ɵangular_packages_core_core_o(): KeyValueDiffers;
8919
8920export declare function ɵangular_packages_core_core_p(locale?: string): string;
8921
8922/**
8923 * A built-in [dependency injection token](guide/glossary#di-token)
8924 * that is used to configure the root injector for bootstrapping.
8925 */
8926export declare const ɵangular_packages_core_core_q: StaticProvider[];
8927
8928/**
8929 * Schedule work at next available slot.
8930 *
8931 * In Ivy this is just `requestAnimationFrame`. For compatibility reasons when bootstrapped
8932 * using `platformRef.bootstrap` we need to use `NgZone.onStable` as the scheduling mechanism.
8933 * This overrides the scheduling mechanism in Ivy to `NgZone.onStable`.
8934 *
8935 * @param ngZone NgZone to use for scheduling.
8936 */
8937export declare function ɵangular_packages_core_core_r(ngZone: NgZone): (fn: () => void) => void;
8938
8939/**
8940 * True if WTF is enabled.
8941 */
8942export declare const ɵangular_packages_core_core_s: boolean;
8943
8944export declare function ɵangular_packages_core_core_t(): boolean;
8945
8946export declare function ɵangular_packages_core_core_u(signature: string, flags?: any): any;
8947
8948export declare function ɵangular_packages_core_core_v<T>(scope: Scope): void;
8949
8950export declare function ɵangular_packages_core_core_v<T>(scope: Scope, returnValue?: T): T;
8951
8952export declare function ɵangular_packages_core_core_w(rangeType: string, action: string): Range;
8953
8954export declare function ɵangular_packages_core_core_x(range: Range): void;
8955
8956export declare function ɵangular_packages_core_core_y(checkIndex: number, flags: ɵNodeFlags, matchedQueriesDsl: [string | number, ɵQueryValueType][] | null, childCount: number, token: any, value: any, deps: ([ɵDepFlags, any] | any)[], bindings?: BindingDef[], outputs?: OutputDef[]): NodeDef;
8957
8958export declare abstract class ɵangular_packages_core_core_z {
8959 abstract readonly view: ViewData;
8960 abstract readonly nodeIndex: number | null;
8961 abstract readonly injector: Injector;
8962 abstract readonly component: any;
8963 abstract readonly providerTokens: any[];
8964 abstract readonly references: {
8965 [key: string]: any;
8966 };
8967 abstract readonly context: any;
8968 abstract readonly componentRenderElement: any;
8969 abstract readonly renderNode: any;
8970 abstract logError(console: Console, ...values: any[]): void;
8971}
8972
8973/**
8974 * Providers that will generate a random APP_ID_TOKEN.
8975 * @publicApi
8976 */
8977export declare const ɵAPP_ID_RANDOM_PROVIDER: {
8978 provide: InjectionToken<string>;
8979 useFactory: typeof ɵangular_packages_core_core_f;
8980 deps: any[];
8981};
8982
8983/**
8984 * An internal token whose presence in an injector indicates that the injector should treat itself
8985 * as a root scoped injector when processing requests for unknown tokens which may indicate
8986 * they are provided in the root scope.
8987 */
8988export declare const ɵAPP_ROOT: InjectionToken<boolean>;
8989
8990export declare const enum ɵArgumentType {
8991 Inline = 0,
8992 Dynamic = 1
8993}
8994
8995/**
8996 * A set of marker values to be used in the attributes arrays. These markers indicate that some
8997 * items are not regular attributes and the processing should be adapted accordingly.
8998 */
8999export declare const enum ɵAttributeMarker {
9000 /**
9001 * Marker indicates that the following 3 values in the attributes array are:
9002 * namespaceUri, attributeName, attributeValue
9003 * in that order.
9004 */
9005 NamespaceURI = 0,
9006 /**
9007 * Signals class declaration.
9008 *
9009 * Each value following `Classes` designates a class name to include on the element.
9010 * ## Example:
9011 *
9012 * Given:
9013 * ```
9014 * <div class="foo bar baz">...<d/vi>
9015 * ```
9016 *
9017 * the generated code is:
9018 * ```
9019 * var _c1 = [AttributeMarker.Classes, 'foo', 'bar', 'baz'];
9020 * ```
9021 */
9022 Classes = 1,
9023 /**
9024 * Signals style declaration.
9025 *
9026 * Each pair of values following `Styles` designates a style name and value to include on the
9027 * element.
9028 * ## Example:
9029 *
9030 * Given:
9031 * ```
9032 * <div style="width:100px; height:200px; color:red">...</div>
9033 * ```
9034 *
9035 * the generated code is:
9036 * ```
9037 * var _c1 = [AttributeMarker.Styles, 'width', '100px', 'height'. '200px', 'color', 'red'];
9038 * ```
9039 */
9040 Styles = 2,
9041 /**
9042 * Signals that the following attribute names were extracted from input or output bindings.
9043 *
9044 * For example, given the following HTML:
9045 *
9046 * ```
9047 * <div moo="car" [foo]="exp" (bar)="doSth()">
9048 * ```
9049 *
9050 * the generated code is:
9051 *
9052 * ```
9053 * var _c1 = ['moo', 'car', AttributeMarker.Bindings, 'foo', 'bar'];
9054 * ```
9055 */
9056 Bindings = 3,
9057 /**
9058 * Signals that the following attribute names were hoisted from an inline-template declaration.
9059 *
9060 * For example, given the following HTML:
9061 *
9062 * ```
9063 * <div *ngFor="let value of values; trackBy:trackBy" dirA [dirB]="value">
9064 * ```
9065 *
9066 * the generated code for the `template()` instruction would include:
9067 *
9068 * ```
9069 * ['dirA', '', AttributeMarker.Bindings, 'dirB', AttributeMarker.Template, 'ngFor', 'ngForOf',
9070 * 'ngForTrackBy', 'let-value']
9071 * ```
9072 *
9073 * while the generated code for the `element()` instruction inside the template function would
9074 * include:
9075 *
9076 * ```
9077 * ['dirA', '', AttributeMarker.Bindings, 'dirB']
9078 * ```
9079 */
9080 Template = 4,
9081 /**
9082 * Signals that the following attribute is `ngProjectAs` and its value is a parsed `CssSelector`.
9083 *
9084 * For example, given the following HTML:
9085 *
9086 * ```
9087 * <h1 attr="value" ngProjectAs="[title]">
9088 * ```
9089 *
9090 * the generated code for the `element()` instruction would include:
9091 *
9092 * ```
9093 * ['attr', 'value', AttributeMarker.ProjectAs, ['', 'title', '']]
9094 * ```
9095 */
9096 ProjectAs = 5,
9097 /**
9098 * Signals that the following attribute will be translated by runtime i18n
9099 *
9100 * For example, given the following HTML:
9101 *
9102 * ```
9103 * <div moo="car" foo="value" i18n-foo [bar]="binding" i18n-bar>
9104 * ```
9105 *
9106 * the generated code is:
9107 *
9108 * ```
9109 * var _c1 = ['moo', 'car', AttributeMarker.I18n, 'foo', 'bar'];
9110 */
9111 I18n = 6
9112}
9113
9114export declare const enum ɵBindingFlags {
9115 TypeElementAttribute = 1,
9116 TypeElementClass = 2,
9117 TypeElementStyle = 4,
9118 TypeProperty = 8,
9119 SyntheticProperty = 16,
9120 SyntheticHostProperty = 32,
9121 CatSyntheticProperty = 48,
9122 Types = 15
9123}
9124
9125/**
9126 * Mark `html` string as trusted.
9127 *
9128 * This function wraps the trusted string in `String` and brands it in a way which makes it
9129 * recognizable to {@link htmlSanitizer} to be trusted implicitly.
9130 *
9131 * @param trustedHtml `html` string which needs to be implicitly trusted.
9132 * @returns a `html` `String` which has been branded to be implicitly trusted.
9133 */
9134export declare function ɵbypassSanitizationTrustHtml(trustedHtml: string): TrustedHtmlString;
9135
9136/**
9137 * Mark `url` string as trusted.
9138 *
9139 * This function wraps the trusted string in `String` and brands it in a way which makes it
9140 * recognizable to {@link resourceUrlSanitizer} to be trusted implicitly.
9141 *
9142 * @param trustedResourceUrl `url` string which needs to be implicitly trusted.
9143 * @returns a `url` `String` which has been branded to be implicitly trusted.
9144 */
9145export declare function ɵbypassSanitizationTrustResourceUrl(trustedResourceUrl: string): TrustedResourceUrlString;
9146
9147/**
9148 * Mark `script` string as trusted.
9149 *
9150 * This function wraps the trusted string in `String` and brands it in a way which makes it
9151 * recognizable to {@link scriptSanitizer} to be trusted implicitly.
9152 *
9153 * @param trustedScript `script` string which needs to be implicitly trusted.
9154 * @returns a `script` `String` which has been branded to be implicitly trusted.
9155 */
9156export declare function ɵbypassSanitizationTrustScript(trustedScript: string): TrustedScriptString;
9157
9158/**
9159 * Mark `style` string as trusted.
9160 *
9161 * This function wraps the trusted string in `String` and brands it in a way which makes it
9162 * recognizable to {@link styleSanitizer} to be trusted implicitly.
9163 *
9164 * @param trustedStyle `style` string which needs to be implicitly trusted.
9165 * @returns a `style` `String` which has been branded to be implicitly trusted.
9166 */
9167export declare function ɵbypassSanitizationTrustStyle(trustedStyle: string): TrustedStyleString;
9168
9169/**
9170 * Mark `url` string as trusted.
9171 *
9172 * This function wraps the trusted string in `String` and brands it in a way which makes it
9173 * recognizable to {@link urlSanitizer} to be trusted implicitly.
9174 *
9175 * @param trustedUrl `url` string which needs to be implicitly trusted.
9176 * @returns a `url` `String` which has been branded to be implicitly trusted.
9177 */
9178export declare function ɵbypassSanitizationTrustUrl(trustedUrl: string): TrustedUrlString;
9179
9180export declare function ɵccf(selector: string, componentType: Type<any>, viewDefFactory: ViewDefinitionFactory, inputs: {
9181 [propName: string]: string;
9182} | null, outputs: {
9183 [propName: string]: string;
9184}, ngContentSelectors: string[]): ComponentFactory<any>;
9185
9186/**
9187 * Defines the possible states of the default change detector.
9188 * @see `ChangeDetectorRef`
9189 */
9190export declare enum ɵChangeDetectorStatus {
9191 /**
9192 * A state in which, after calling `detectChanges()`, the change detector
9193 * state becomes `Checked`, and must be explicitly invoked or reactivated.
9194 */
9195 CheckOnce = 0,
9196 /**
9197 * A state in which change detection is skipped until the change detector mode
9198 * becomes `CheckOnce`.
9199 */
9200 Checked = 1,
9201 /**
9202 * A state in which change detection continues automatically until explicitly
9203 * deactivated.
9204 */
9205 CheckAlways = 2,
9206 /**
9207 * A state in which a change detector sub tree is not a part of the main tree and
9208 * should be skipped.
9209 */
9210 Detached = 3,
9211 /**
9212 * Indicates that the change detector encountered an error checking a binding
9213 * or calling a directive lifecycle method and is now in an inconsistent state. Change
9214 * detectors in this state do not detect changes.
9215 */
9216 Errored = 4,
9217 /**
9218 * Indicates that the change detector has been destroyed.
9219 */
9220 Destroyed = 5
9221}
9222
9223export declare function ɵclearOverrides(): void;
9224
9225export declare function ɵclearResolutionOfComponentResourcesQueue(): Map<Type<any>, Component>;
9226
9227export declare function ɵcmf(ngModuleType: Type<any>, bootstrapComponents: Type<any>[], defFactory: NgModuleDefinitionFactory): NgModuleFactory<any>;
9228
9229export declare class ɵCodegenComponentFactoryResolver implements ComponentFactoryResolver {
9230 private _parent;
9231 private _ngModule;
9232 private _factories;
9233 constructor(factories: ComponentFactory<any>[], _parent: ComponentFactoryResolver, _ngModule: NgModuleRef<any>);
9234 resolveComponentFactory<T>(component: {
9235 new (...args: any[]): T;
9236 }): ComponentFactory<T>;
9237}
9238
9239/**
9240 * Compile an Angular component according to its decorator metadata, and patch the resulting
9241 * ngComponentDef onto the component type.
9242 *
9243 * Compilation may be asynchronous (due to the need to resolve URLs for the component template or
9244 * other resources, for example). In the event that compilation is not immediate, `compileComponent`
9245 * will enqueue resource resolution into a global queue and will fail to return the `ngComponentDef`
9246 * until the global queue has been resolved with a call to `resolveComponentResources`.
9247 */
9248export declare function ɵcompileComponent(type: Type<any>, metadata: Component): void;
9249
9250/**
9251 * Compile an Angular directive according to its decorator metadata, and patch the resulting
9252 * ngDirectiveDef onto the component type.
9253 *
9254 * In the event that compilation is not immediate, `compileDirective` will return a `Promise` which
9255 * will resolve when compilation completes and the directive becomes usable.
9256 */
9257export declare function ɵcompileDirective(type: Type<any>, directive: Directive): void;
9258
9259/**
9260 * Compiles a module in JIT mode.
9261 *
9262 * This function automatically gets called when a class has a `@NgModule` decorator.
9263 */
9264export declare function ɵcompileNgModule(moduleType: Type<any>, ngModule?: NgModule): void;
9265
9266/**
9267 * Compiles and adds the `ngModuleDef` and `ngInjectorDef` properties to the module class.
9268 *
9269 * It's possible to compile a module via this API which will allow duplicate declarations in its
9270 * root.
9271 */
9272export declare function ɵcompileNgModuleDefs(moduleType: ɵNgModuleType, ngModule: NgModule, allowDuplicateDeclarationsInRoot?: boolean): void;
9273
9274export declare function ɵcompileNgModuleFactory__POST_R3__<M>(injector: Injector, options: CompilerOptions, moduleType: Type<M>): Promise<NgModuleFactory<M>>;
9275
9276export declare function ɵcompilePipe(type: Type<any>, meta: Pipe): void;
9277
9278export declare const ɵCompiler_compileModuleAndAllComponentsAsync__POST_R3__: <T>(moduleType: Type<T>) => Promise<ModuleWithComponentFactories<T>>;
9279
9280export declare const ɵCompiler_compileModuleAndAllComponentsSync__POST_R3__: <T>(moduleType: Type<T>) => ModuleWithComponentFactories<T>;
9281
9282export declare const ɵCompiler_compileModuleAsync__POST_R3__: <T>(moduleType: Type<T>) => Promise<NgModuleFactory<T>>;
9283
9284export declare const ɵCompiler_compileModuleSync__POST_R3__: <T>(moduleType: Type<T>) => NgModuleFactory<T>;
9285
9286/**
9287 * Runtime link information for Components.
9288 *
9289 * This is internal data structure used by the render to link
9290 * components into templates.
9291 *
9292 * NOTE: Always use `defineComponent` function to create this object,
9293 * never create the object directly since the shape of this object
9294 * can change between versions.
9295 *
9296 * See: {@link defineComponent}
9297 */
9298export declare interface ɵComponentDef<T> extends ɵDirectiveDef<T> {
9299 /**
9300 * Runtime unique component ID.
9301 */
9302 readonly id: string;
9303 /**
9304 * The View template of the component.
9305 */
9306 readonly template: ComponentTemplate<T>;
9307 /**
9308 * An array of `ngContent[selector]` values that were found in the template.
9309 */
9310 readonly ngContentSelectors?: string[];
9311 /**
9312 * A set of styles that the component needs to be present for component to render correctly.
9313 */
9314 readonly styles: string[];
9315 /**
9316 * The number of nodes, local refs, and pipes in this component template.
9317 *
9318 * Used to calculate the length of the component's LView array, so we
9319 * can pre-fill the array and set the binding start index.
9320 */
9321 readonly consts: number;
9322 /**
9323 * The number of bindings in this component template (including pure fn bindings).
9324 *
9325 * Used to calculate the length of the component's LView array, so we
9326 * can pre-fill the array and set the host binding start index.
9327 */
9328 readonly vars: number;
9329 /**
9330 * Query-related instructions for a component.
9331 */
9332 viewQuery: ViewQueriesFunction<T> | null;
9333 /**
9334 * The view encapsulation type, which determines how styles are applied to
9335 * DOM elements. One of
9336 * - `Emulated` (default): Emulate native scoping of styles.
9337 * - `Native`: Use the native encapsulation mechanism of the renderer.
9338 * - `ShadowDom`: Use modern [ShadowDOM](https://w3c.github.io/webcomponents/spec/shadow/) and
9339 * create a ShadowRoot for component's host element.
9340 * - `None`: Do not provide any template or style encapsulation.
9341 */
9342 readonly encapsulation: ViewEncapsulation;
9343 /**
9344 * Defines arbitrary developer-defined data to be stored on a renderer instance.
9345 * This is useful for renderers that delegate to other renderers.
9346 */
9347 readonly data: {
9348 [kind: string]: any;
9349 };
9350 /** Whether or not this component's ChangeDetectionStrategy is OnPush */
9351 readonly onPush: boolean;
9352 /**
9353 * Registry of directives and components that may be found in this view.
9354 *
9355 * The property is either an array of `DirectiveDef`s or a function which returns the array of
9356 * `DirectiveDef`s. The function is necessary to be able to support forward declarations.
9357 */
9358 directiveDefs: DirectiveDefListOrFactory | null;
9359 /**
9360 * Registry of pipes that may be found in this view.
9361 *
9362 * The property is either an array of `PipeDefs`s or a function which returns the array of
9363 * `PipeDefs`s. The function is necessary to be able to support forward declarations.
9364 */
9365 pipeDefs: PipeDefListOrFactory | null;
9366 /**
9367 * The set of schemas that declare elements to be allowed in the component's template.
9368 */
9369 schemas: SchemaMetadata[] | null;
9370 /**
9371 * Ivy runtime uses this place to store the computed tView for the component. This gets filled on
9372 * the first run of component.
9373 */
9374 tView: TView | null;
9375 /**
9376 * Used to store the result of `noSideEffects` function so that it is not removed by closure
9377 * compiler. The property should never be read.
9378 */
9379 readonly _?: never;
9380}
9381
9382/**
9383 * A subclass of `Type` which has a static `ngComponentDef`:`ComponentDef` field making it
9384 * consumable for rendering.
9385 */
9386export declare interface ɵComponentType<T> extends Type<T> {
9387 ngComponentDef: never;
9388}
9389
9390
9391export declare class ɵConsole {
9392 log(message: string): void;
9393 warn(message: string): void;
9394}
9395
9396/**
9397 * Create a new `Injector` which is configured using a `defType` of `InjectorType<any>`s.
9398 *
9399 * @publicApi
9400 */
9401export declare function ɵcreateInjector(defType: any, parent?: Injector | null, additionalProviders?: StaticProvider[] | null, name?: string): Injector;
9402
9403export declare function ɵcrt(values: {
9404 styles: (string | any[])[];
9405 encapsulation: ViewEncapsulation;
9406 data: {
9407 [kind: string]: any[];
9408 };
9409}): RendererType2;
9410
9411/**
9412 * A list of CssSelectors.
9413 *
9414 * A directive or component can have multiple selectors. This type is used for
9415 * directive defs so any of the selectors in the list will match that directive.
9416 *
9417 * Original: 'form, [ngForm]'
9418 * Parsed: [['form'], ['', 'ngForm', '']]
9419 */
9420export declare type ɵCssSelectorList = CssSelector[];
9421
9422/**
9423 * The locale id that the application is using by default (for translations and ICU expressions).
9424 */
9425export declare const ɵDEFAULT_LOCALE_ID = "en-US";
9426
9427export declare const ɵdefaultIterableDiffers: IterableDiffers;
9428
9429export declare const ɵdefaultKeyValueDiffers: KeyValueDiffers;
9430
9431/**
9432 * Bitmask for DI flags
9433 */
9434export declare const enum ɵDepFlags {
9435 None = 0,
9436 SkipSelf = 1,
9437 Optional = 2,
9438 Self = 4,
9439 Value = 8
9440}
9441
9442
9443/**
9444 * Synchronously perform change detection on a component (and possibly its sub-components).
9445 *
9446 * This function triggers change detection in a synchronous way on a component. There should
9447 * be very little reason to call this function directly since a preferred way to do change
9448 * detection is to {@link markDirty} the component and wait for the scheduler to call this method
9449 * at some future point in time. This is because a single user action often results in many
9450 * components being invalidated and calling change detection on each component synchronously
9451 * would be inefficient. It is better to wait until all components are marked as dirty and
9452 * then perform single change detection across all of the components
9453 *
9454 * @param component The component which the change detection should be performed on.
9455 */
9456export declare function ɵdetectChanges<T>(component: T): void;
9457
9458
9459export declare function ɵdevModeEqual(a: any, b: any): boolean;
9460
9461export declare function ɵdid(checkIndex: number, flags: ɵNodeFlags, matchedQueries: null | [string | number, ɵQueryValueType][], childCount: number, ctor: any, deps: ([ɵDepFlags, any] | any)[], props?: null | {
9462 [name: string]: [number, string];
9463}, outputs?: null | {
9464 [name: string]: string;
9465}): NodeDef;
9466
9467/**
9468 * Runtime link information for Directives.
9469 *
9470 * This is internal data structure used by the render to link
9471 * directives into templates.
9472 *
9473 * NOTE: Always use `defineDirective` function to create this object,
9474 * never create the object directly since the shape of this object
9475 * can change between versions.
9476 *
9477 * @param Selector type metadata specifying the selector of the directive or component
9478 *
9479 * See: {@link defineDirective}
9480 */
9481export declare interface ɵDirectiveDef<T> extends ɵɵBaseDef<T> {
9482 /** Token representing the directive. Used by DI. */
9483 type: Type<T>;
9484 /** Function that resolves providers and publishes them into the DI system. */
9485 providersResolver: (<U extends T>(def: ɵDirectiveDef<U>, processProvidersFn?: ProcessProvidersFunction) => void) | null;
9486 /** The selectors that will be used to match nodes to this directive. */
9487 readonly selectors: ɵCssSelectorList;
9488 /**
9489 * Name under which the directive is exported (for use with local references in template)
9490 */
9491 readonly exportAs: string[] | null;
9492 /**
9493 * Factory function used to create a new directive instance.
9494 */
9495 factory: FactoryFn<T>;
9496 onChanges: (() => void) | null;
9497 onInit: (() => void) | null;
9498 doCheck: (() => void) | null;
9499 afterContentInit: (() => void) | null;
9500 afterContentChecked: (() => void) | null;
9501 afterViewInit: (() => void) | null;
9502 afterViewChecked: (() => void) | null;
9503 onDestroy: (() => void) | null;
9504 /**
9505 * The features applied to this directive
9506 */
9507 readonly features: DirectiveDefFeature[] | null;
9508 setInput: (<U extends T>(this: ɵDirectiveDef<U>, instance: U, value: any, publicName: string, privateName: string) => void) | null;
9509}
9510
9511/**
9512 * A subclass of `Type` which has a static `ngDirectiveDef`:`DirectiveDef` field making it
9513 * consumable for rendering.
9514 */
9515export declare interface ɵDirectiveType<T> extends Type<T> {
9516 ngDirectiveDef: never;
9517}
9518
9519/**
9520 * @deprecated Use the `Renderer2` instead.
9521 */
9522export declare interface ɵDirectRenderer {
9523 remove(node: any): void;
9524 appendChild(node: any, parent: any): void;
9525 insertBefore(node: any, refNode: any): void;
9526 nextSibling(node: any): any;
9527 parentElement(node: any): any;
9528}
9529
9530export declare function ɵeld(checkIndex: number, flags: ɵNodeFlags, matchedQueriesDsl: null | [string | number, ɵQueryValueType][], ngContentIndex: null | number, childCount: number, namespaceAndName: string | null, fixedAttrs?: null | [string, string][], bindings?: null | [ɵBindingFlags, string, string | SecurityContext | null][], outputs?: null | ([string, string])[], handleEvent?: null | ElementHandleEventFn, componentView?: null | ViewDefinitionFactory, componentRendererType?: RendererType2 | null): NodeDef;
9531
9532export declare const ɵEMPTY_ARRAY: any[];
9533
9534export declare const ɵEMPTY_MAP: {
9535 [key: string]: any;
9536};
9537
9538/**
9539 * Finds the locale data for a given locale.
9540 *
9541 * @param locale The locale code.
9542 * @returns The locale data.
9543 * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n)
9544 */
9545export declare function ɵfindLocaleData(locale: string): any;
9546
9547/**
9548 * Loops over queued module definitions, if a given module definition has all of its
9549 * declarations resolved, it dequeues that module definition and sets the scope on
9550 * its declarations.
9551 */
9552export declare function ɵflushModuleScopingQueueAsMuchAsPossible(): void;
9553
9554export declare function ɵgetComponentViewDefinitionFactory(componentFactory: ComponentFactory<any>): ViewDefinitionFactory;
9555
9556export declare function ɵgetDebugNode__POST_R3__(nativeNode: Element): DebugElement__POST_R3__;
9557
9558export declare function ɵgetDebugNode__POST_R3__(nativeNode: Node): DebugNode__POST_R3__;
9559
9560export declare function ɵgetDebugNode__POST_R3__(nativeNode: null): null;
9561
9562/**
9563 * Retrieves directives associated with a given DOM host element.
9564 *
9565 * @param target A DOM element, component or directive instance.
9566 *
9567 * @publicApi
9568 */
9569export declare function ɵgetDirectives(target: {}): Array<{}>;
9570
9571/**
9572 * Retrieve the host element of the component.
9573 *
9574 * Use this function to retrieve the host element of the component. The host
9575 * element is the element which the component is associated with.
9576 *
9577 * @param directive Component or Directive for which the host element should be retrieved.
9578 *
9579 * @publicApi
9580 */
9581export declare function ɵgetHostElement<T>(directive: T): Element;
9582
9583/**
9584 * Read the `ngInjectableDef` for `type` in a way which is immune to accidentally reading inherited
9585 * value.
9586 *
9587 * @param type A type which may have its own (non-inherited) `ngInjectableDef`.
9588 */
9589export declare function ɵgetInjectableDef<T>(type: any): ɵɵInjectableDef<T> | null;
9590
9591/** Returns the matching `LContext` data for a given DOM node, directive or component instance.
9592 *
9593 * This function will examine the provided DOM element, component, or directive instance\'s
9594 * monkey-patched property to derive the `LContext` data. Once called then the monkey-patched
9595 * value will be that of the newly created `LContext`.
9596 *
9597 * If the monkey-patched value is the `LView` instance then the context value for that
9598 * target will be created and the monkey-patch reference will be updated. Therefore when this
9599 * function is called it may mutate the provided element\'s, component\'s or any of the associated
9600 * directive\'s monkey-patch values.
9601 *
9602 * If the monkey-patch value is not detected then the code will walk up the DOM until an element
9603 * is found which contains a monkey-patch reference. When that occurs then the provided element
9604 * will be updated with a new context (which is then returned). If the monkey-patch value is not
9605 * detected for a component/directive instance then it will throw an error (all components and
9606 * directives should be automatically monkey-patched by ivy).
9607 *
9608 * @param target Component, Directive or DOM Node.
9609 */
9610export declare function ɵgetLContext(target: any): ɵLContext | null;
9611
9612
9613/**
9614 * Retrieves the plural function used by ICU expressions to determine the plural case to use
9615 * for a given locale.
9616 * @param locale A locale code for the locale format rules to use.
9617 * @returns The plural function for the locale.
9618 * @see `NgPlural`
9619 * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n)
9620 */
9621export declare function ɵgetLocalePluralCase(locale: string): (value: number) => number;
9622
9623export declare function ɵgetModuleFactory__POST_R3__(id: string): NgModuleFactory<any>;
9624
9625export declare type ɵGetterFn = (obj: any) => any;
9626
9627
9628export declare const ɵglobal: any;
9629
9630/**
9631 * Set the configuration for `i18nLocalize`.
9632 *
9633 * @deprecated this method is temporary & should not be used as it will be removed soon
9634 */
9635export declare function ɵi18nConfigureLocalize(options?: I18nLocalizeOptions): void;
9636
9637export declare function ɵinitServicesIfNeeded(): void;
9638
9639export declare function ɵINJECTOR_IMPL__POST_R3__(providers: StaticProvider[], parent: Injector | undefined, name: string): Injector;
9640
9641export declare function ɵinlineInterpolate(valueCount: number, c0: string, a1: any, c1: string, a2?: any, c2?: string, a3?: any, c3?: string, a4?: any, c4?: string, a5?: any, c5?: string, a6?: any, c6?: string, a7?: any, c7?: string, a8?: any, c8?: string, a9?: any, c9?: string): string;
9642
9643export declare function ɵinterpolate(valueCount: number, constAndInterp: string[]): string;
9644
9645export declare function ɵisBoundToModule__POST_R3__<C>(cf: ComponentFactory<C>): boolean;
9646
9647/**
9648 * Reports whether a given strategy is currently the default for change detection.
9649 * @param changeDetectionStrategy The strategy to check.
9650 * @returns True if the given strategy is the current default, false otherwise.
9651 * @see `ChangeDetectorStatus`
9652 * @see `ChangeDetectorRef`
9653 */
9654export declare function ɵisDefaultChangeDetectionStrategy(changeDetectionStrategy: ChangeDetectionStrategy): boolean;
9655
9656export declare function ɵisListLikeIterable(obj: any): boolean;
9657
9658/**
9659 * Determine if the argument is an Observable
9660 */
9661export declare function ɵisObservable(obj: any | Observable<any>): obj is Observable<any>;
9662
9663/**
9664 * Determine if the argument is shaped like a Promise
9665 */
9666export declare function ɵisPromise(obj: any): obj is Promise<any>;
9667
9668export declare const ɵivyEnabled = false;
9669
9670/**
9671 * The internal view context which is specific to a given DOM element, directive or
9672 * component instance. Each value in here (besides the LView and element node details)
9673 * can be present, null or undefined. If undefined then it implies the value has not been
9674 * looked up yet, otherwise, if null, then a lookup was executed and nothing was found.
9675 *
9676 * Each value will get filled when the respective value is examined within the getContext
9677 * function. The component, element and each directive instance will share the same instance
9678 * of the context.
9679 */
9680export declare interface ɵLContext {
9681 /**
9682 * The component's parent view data.
9683 */
9684 lView: ɵangular_packages_core_core_bj;
9685 /**
9686 * The index instance of the node.
9687 */
9688 nodeIndex: number;
9689 /**
9690 * The instance of the DOM node that is attached to the lNode.
9691 */
9692 native: RNode;
9693 /**
9694 * The instance of the Component node.
9695 */
9696 component: {} | null | undefined;
9697 /**
9698 * The list of active directives that exist on this element.
9699 */
9700 directives: any[] | null | undefined;
9701 /**
9702 * The map of local references (local reference name => element or directive instance) that exist
9703 * on this element.
9704 */
9705 localRefs: {
9706 [key: string]: any;
9707 } | null | undefined;
9708}
9709
9710/**
9711 * Used to enable lifecycle hooks on the root component.
9712 *
9713 * Include this feature when calling `renderComponent` if the root component
9714 * you are rendering has lifecycle hooks defined. Otherwise, the hooks won't
9715 * be called properly.
9716 *
9717 * Example:
9718 *
9719 * ```
9720 * renderComponent(AppComponent, {features: [RootLifecycleHooks]});
9721 * ```
9722 */
9723export declare function ɵLifecycleHooksFeature(component: any, def: ɵComponentDef<any>): void;
9724
9725/**
9726 * This const is used to store the locale data registered with `registerLocaleData`
9727 */
9728export declare const ɵLOCALE_DATA: {
9729 [localeId: string]: any;
9730};
9731
9732/**
9733 * Index of each type of locale data from the locale data array
9734 */
9735export declare enum ɵLocaleDataIndex {
9736 LocaleId = 0,
9737 DayPeriodsFormat = 1,
9738 DayPeriodsStandalone = 2,
9739 DaysFormat = 3,
9740 DaysStandalone = 4,
9741 MonthsFormat = 5,
9742 MonthsStandalone = 6,
9743 Eras = 7,
9744 FirstDayOfWeek = 8,
9745 WeekendRange = 9,
9746 DateFormat = 10,
9747 TimeFormat = 11,
9748 DateTimeFormat = 12,
9749 NumberSymbols = 13,
9750 NumberFormats = 14,
9751 CurrencySymbol = 15,
9752 CurrencyName = 16,
9753 Currencies = 17,
9754 PluralCase = 18,
9755 ExtraData = 19
9756}
9757
9758
9759export declare function ɵlooseIdentical(a: any, b: any): boolean;
9760
9761/**
9762 * @suppress {globalThis}
9763 */
9764export declare function ɵmakeDecorator<T>(name: string, props?: (...args: any[]) => any, parentClass?: any, additionalProcessing?: (type: Type<T>) => void, typeFn?: (type: Type<T>, ...args: any[]) => void): {
9765 new (...args: any[]): any;
9766 (...args: any[]): any;
9767 (...args: any[]): (cls: any) => any;
9768};
9769
9770/**
9771 * Mark the component as dirty (needing change detection).
9772 *
9773 * Marking a component dirty will schedule a change detection on this
9774 * component at some point in the future. Marking an already dirty
9775 * component as dirty is a noop. Only one outstanding change detection
9776 * can be scheduled per component tree. (Two components bootstrapped with
9777 * separate `renderComponent` will have separate schedulers)
9778 *
9779 * When the root component is bootstrapped with `renderComponent`, a scheduler
9780 * can be provided.
9781 *
9782 * @param component Component to mark as dirty.
9783 *
9784 * @publicApi
9785 */
9786export declare function ɵmarkDirty<T>(component: T): void;
9787
9788export declare type ɵMethodFn = (obj: any, args: any[]) => any;
9789
9790export declare function ɵmod(providers: NgModuleProviderDef[]): NgModuleDefinition;
9791
9792export declare function ɵmpd(flags: ɵNodeFlags, token: any, value: any, deps: ([ɵDepFlags, any] | any)[]): NgModuleProviderDef;
9793
9794export declare function ɵncd(ngContentIndex: null | number, index: number): NodeDef;
9795
9796export declare const ɵNG_BASE_DEF: string;
9797
9798
9799export declare const ɵNG_COMPONENT_DEF: string;
9800
9801export declare const ɵNG_DIRECTIVE_DEF: string;
9802
9803/**
9804 * If a directive is diPublic, bloomAdd sets a property on the type with this constant as
9805 * the key and the directive's unique ID as the value. This allows us to map directives to their
9806 * bloom filter bit for DI.
9807 */
9808export declare const ɵNG_ELEMENT_ID: string;
9809
9810export declare const ɵNG_INJECTABLE_DEF: string;
9811
9812export declare const ɵNG_INJECTOR_DEF: string;
9813
9814export declare const ɵNG_MODULE_DEF: string;
9815
9816export declare const ɵNG_PIPE_DEF: string;
9817
9818/**
9819 * Runtime link information for NgModules.
9820 *
9821 * This is the internal data structure used by the runtime to assemble components, directives,
9822 * pipes, and injectors.
9823 *
9824 * NOTE: Always use `ɵɵdefineNgModule` function to create this object,
9825 * never create the object directly since the shape of this object
9826 * can change between versions.
9827 */
9828export declare interface ɵNgModuleDef<T> {
9829 /** Token representing the module. Used by DI. */
9830 type: T;
9831 /** List of components to bootstrap. */
9832 bootstrap: Type<any>[] | (() => Type<any>[]);
9833 /** List of components, directives, and pipes declared by this module. */
9834 declarations: Type<any>[] | (() => Type<any>[]);
9835 /** List of modules or `ModuleWithProviders` imported by this module. */
9836 imports: Type<any>[] | (() => Type<any>[]);
9837 /**
9838 * List of modules, `ModuleWithProviders`, components, directives, or pipes exported by this
9839 * module.
9840 */
9841 exports: Type<any>[] | (() => Type<any>[]);
9842 /**
9843 * Cached value of computed `transitiveCompileScopes` for this module.
9844 *
9845 * This should never be read directly, but accessed via `transitiveScopesFor`.
9846 */
9847 transitiveCompileScopes: ɵNgModuleTransitiveScopes | null;
9848 /** The set of schemas that declare elements to be allowed in the NgModule. */
9849 schemas: SchemaMetadata[] | null;
9850 /** Unique ID for the module with which it should be registered. */
9851 id: string | null;
9852}
9853
9854export declare class ɵNgModuleFactory<T> extends NgModuleFactory<T> {
9855 moduleType: Type<T>;
9856 constructor(moduleType: Type<T>);
9857 create(parentInjector: Injector | null): NgModuleRef<T>;
9858}
9859
9860/**
9861 * Represents the expansion of an `NgModule` into its scopes.
9862 *
9863 * A scope is a set of directives and pipes that are visible in a particular context. Each
9864 * `NgModule` has two scopes. The `compilation` scope is the set of directives and pipes that will
9865 * be recognized in the templates of components declared by the module. The `exported` scope is the
9866 * set of directives and pipes exported by a module (that is, module B's exported scope gets added
9867 * to module A's compilation scope when module A imports B).
9868 */
9869export declare interface ɵNgModuleTransitiveScopes {
9870 compilation: {
9871 directives: Set<any>;
9872 pipes: Set<any>;
9873 };
9874 exported: {
9875 directives: Set<any>;
9876 pipes: Set<any>;
9877 };
9878 schemas: SchemaMetadata[] | null;
9879}
9880
9881export declare interface ɵNgModuleType<T = any> extends Type<T> {
9882 ngModuleDef: ɵNgModuleDef<T>;
9883}
9884
9885
9886export declare interface ɵNO_CHANGE {
9887 brand: 'NO_CHANGE';
9888}
9889
9890/** A special value which designates that a value has not changed. */
9891export declare const ɵNO_CHANGE: ɵNO_CHANGE;
9892
9893/**
9894 * Bitmask for NodeDef.flags.
9895 * Naming convention:
9896 * - `Type...`: flags that are mutually exclusive
9897 * - `Cat...`: union of multiple `Type...` (short for category).
9898 */
9899export declare const enum ɵNodeFlags {
9900 None = 0,
9901 TypeElement = 1,
9902 TypeText = 2,
9903 ProjectedTemplate = 4,
9904 CatRenderNode = 3,
9905 TypeNgContent = 8,
9906 TypePipe = 16,
9907 TypePureArray = 32,
9908 TypePureObject = 64,
9909 TypePurePipe = 128,
9910 CatPureExpression = 224,
9911 TypeValueProvider = 256,
9912 TypeClassProvider = 512,
9913 TypeFactoryProvider = 1024,
9914 TypeUseExistingProvider = 2048,
9915 LazyProvider = 4096,
9916 PrivateProvider = 8192,
9917 TypeDirective = 16384,
9918 Component = 32768,
9919 CatProviderNoDirective = 3840,
9920 CatProvider = 20224,
9921 OnInit = 65536,
9922 OnDestroy = 131072,
9923 DoCheck = 262144,
9924 OnChanges = 524288,
9925 AfterContentInit = 1048576,
9926 AfterContentChecked = 2097152,
9927 AfterViewInit = 4194304,
9928 AfterViewChecked = 8388608,
9929 EmbeddedViews = 16777216,
9930 ComponentView = 33554432,
9931 TypeContentQuery = 67108864,
9932 TypeViewQuery = 134217728,
9933 StaticQuery = 268435456,
9934 DynamicQuery = 536870912,
9935 TypeNgModule = 1073741824,
9936 CatQuery = 201326592,
9937 Types = 201347067
9938}
9939
9940/**
9941 * Provides a noop implementation of `NgZone` which does nothing. This zone requires explicit calls
9942 * to framework to perform rendering.
9943 */
9944export declare class ɵNoopNgZone implements NgZone {
9945 readonly hasPendingMicrotasks: boolean;
9946 readonly hasPendingMacrotasks: boolean;
9947 readonly isStable: boolean;
9948 readonly onUnstable: EventEmitter<any>;
9949 readonly onMicrotaskEmpty: EventEmitter<any>;
9950 readonly onStable: EventEmitter<any>;
9951 readonly onError: EventEmitter<any>;
9952 run(fn: () => any): any;
9953 runGuarded(fn: () => any): any;
9954 runOutsideAngular(fn: () => any): any;
9955 runTask<T>(fn: () => any): any;
9956}
9957
9958export declare const ɵNOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR: {};
9959
9960export declare function ɵnov(view: ViewData, index: number): any;
9961
9962export declare function ɵoverrideComponentView(comp: Type<any>, componentFactory: ComponentFactory<any>): void;
9963
9964export declare function ɵoverrideProvider(override: ProviderOverride): void;
9965
9966export declare function ɵpad(checkIndex: number, argCount: number): NodeDef;
9967
9968/**
9969 * Patch the definition of a component with directives and pipes from the compilation scope of
9970 * a given module.
9971 */
9972export declare function ɵpatchComponentDefWithScope<C>(componentDef: ɵComponentDef<C>, transitiveScopes: ɵNgModuleTransitiveScopes): void;
9973
9974export declare function ɵpid(flags: ɵNodeFlags, ctor: any, deps: ([ɵDepFlags, any] | any)[]): NodeDef;
9975
9976/**
9977 * Runtime link information for Pipes.
9978 *
9979 * This is internal data structure used by the renderer to link
9980 * pipes into templates.
9981 *
9982 * NOTE: Always use `definePipe` function to create this object,
9983 * never create the object directly since the shape of this object
9984 * can change between versions.
9985 *
9986 * See: {@link definePipe}
9987 */
9988export declare interface ɵPipeDef<T> {
9989 /**
9990 * Pipe name.
9991 *
9992 * Used to resolve pipe in templates.
9993 */
9994 readonly name: string;
9995 /**
9996 * Factory function used to create a new pipe instance.
9997 */
9998 factory: FactoryFn<T>;
9999 /**
10000 * Whether or not the pipe is pure.
10001 *
10002 * Pure pipes result only depends on the pipe input and not on internal
10003 * state of the pipe.
10004 */
10005 readonly pure: boolean;
10006 onDestroy: (() => void) | null;
10007}
10008
10009
10010/**
10011 * A shared interface which contains an animation player
10012 */
10013export declare interface ɵPlayer {
10014 parent?: ɵPlayer | null;
10015 state: ɵPlayState;
10016 play(): void;
10017 pause(): void;
10018 finish(): void;
10019 destroy(): void;
10020 addEventListener(state: ɵPlayState | string, cb: (data?: any) => any): void;
10021}
10022
10023/**
10024 * Used as a reference to build a player from a styling template binding
10025 * (`[style]` and `[class]`).
10026 *
10027 * The `fn` function will be called once any styling-related changes are
10028 * evaluated on an element and is expected to return a player that will
10029 * be then run on the element.
10030 *
10031 * `[style]`, `[style.prop]`, `[class]` and `[class.name]` template bindings
10032 * all accept a `PlayerFactory` as input and this player factories.
10033 */
10034export declare interface ɵPlayerFactory {
10035 '__brand__': 'Brand for PlayerFactory that nothing will match';
10036}
10037
10038/**
10039 * Designed to be used as an injection service to capture all animation players.
10040 *
10041 * When present all animation players will be passed into the flush method below.
10042 * This feature is designed to service application-wide animation testing, live
10043 * debugging as well as custom animation choreographing tools.
10044 */
10045export declare interface ɵPlayerHandler {
10046 /**
10047 * Designed to kick off the player at the end of change detection
10048 */
10049 flushPlayers(): void;
10050 /**
10051 * @param player The player that has been scheduled to run within the application.
10052 * @param context The context as to where the player was bound to
10053 */
10054 queuePlayer(player: ɵPlayer, context: ComponentInstance | DirectiveInstance | HTMLElement): void;
10055}
10056
10057/**
10058 * The state of a given player
10059 *
10060 * Do not change the increasing nature of the numbers since the player
10061 * code may compare state by checking if a number is higher or lower than
10062 * a certain numeric value.
10063 */
10064export declare const enum ɵPlayState {
10065 Pending = 0,
10066 Running = 1,
10067 Paused = 2,
10068 Finished = 100,
10069 Destroyed = 200
10070}
10071
10072export declare function ɵpod(checkIndex: number, propToIndex: {
10073 [p: string]: number;
10074}): NodeDef;
10075
10076export declare function ɵppd(checkIndex: number, argCount: number): NodeDef;
10077
10078export declare function ɵprd(flags: ɵNodeFlags, matchedQueries: null | [string | number, ɵQueryValueType][], token: any, value: any, deps: ([ɵDepFlags, any] | any)[]): NodeDef;
10079
10080/**
10081 * Publishes a collection of default debug tools onto`window.ng`.
10082 *
10083 * These functions are available globally when Angular is in development
10084 * mode and are automatically stripped away from prod mode is on.
10085 */
10086export declare function ɵpublishDefaultGlobalUtils(): void;
10087
10088/**
10089 * Publishes the given function to `window.ng` so that it can be
10090 * used from the browser console when an application is not in production.
10091 */
10092export declare function ɵpublishGlobalUtil(name: string, fn: Function): void;
10093
10094export declare function ɵqud(flags: ɵNodeFlags, id: number, bindings: {
10095 [propName: string]: ɵQueryBindingType;
10096}): NodeDef;
10097
10098export declare const enum ɵQueryBindingType {
10099 First = 0,
10100 All = 1
10101}
10102
10103export declare const enum ɵQueryValueType {
10104 ElementRef = 0,
10105 RenderElement = 1,
10106 TemplateRef = 2,
10107 ViewContainerRef = 3,
10108 Provider = 4
10109}
10110
10111export declare class ɵReflectionCapabilities implements PlatformReflectionCapabilities {
10112 private _reflect;
10113 constructor(reflect?: any);
10114 isReflectionEnabled(): boolean;
10115 factory<T>(t: Type<T>): (args: any[]) => T;
10116 private _ownParameters;
10117 parameters(type: Type<any>): any[][];
10118 private _ownAnnotations;
10119 annotations(typeOrFunc: Type<any>): any[];
10120 private _ownPropMetadata;
10121 propMetadata(typeOrFunc: any): {
10122 [key: string]: any[];
10123 };
10124 ownPropMetadata(typeOrFunc: any): {
10125 [key: string]: any[];
10126 };
10127 hasLifecycleHook(type: any, lcProperty: string): boolean;
10128 guards(type: any): {
10129 [key: string]: any;
10130 };
10131 getter(name: string): ɵGetterFn;
10132 setter(name: string): ɵSetterFn;
10133 method(name: string): ɵMethodFn;
10134 importUri(type: any): string;
10135 resourceUri(type: any): string;
10136 resolveIdentifier(name: string, moduleUrl: string, members: string[], runtime: any): any;
10137 resolveEnum(enumIdentifier: any, name: string): any;
10138}
10139
10140/**
10141 * Registers a loaded module. Should only be called from generated NgModuleFactory code.
10142 * @publicApi
10143 */
10144export declare function ɵregisterModuleFactory(id: string, factory: NgModuleFactory<any>): void;
10145
10146export declare function ɵregisterNgModuleType(ngModuleType: ɵNgModuleType): void;
10147
10148/**
10149 * Render3 implementation of {@link viewEngine_ComponentFactory}.
10150 */
10151export declare class ɵRender3ComponentFactory<T> extends ComponentFactory<T> {
10152 private componentDef;
10153 private ngModule?;
10154 selector: string;
10155 componentType: Type<any>;
10156 ngContentSelectors: string[];
10157 isBoundToModule: boolean;
10158 readonly inputs: {
10159 propName: string;
10160 templateName: string;
10161 }[];
10162 readonly outputs: {
10163 propName: string;
10164 templateName: string;
10165 }[];
10166 /**
10167 * @param componentDef The component definition.
10168 * @param ngModule The NgModuleRef to which the factory is bound.
10169 */
10170 constructor(componentDef: ɵComponentDef<any>, ngModule?: NgModuleRef<any> | undefined);
10171 create(injector: Injector, projectableNodes?: any[][] | undefined, rootSelectorOrNode?: any, ngModule?: NgModuleRef<any> | undefined): ComponentRef<T>;
10172}
10173
10174/**
10175 * Represents an instance of a Component created via a {@link ComponentFactory}.
10176 *
10177 * `ComponentRef` provides access to the Component Instance as well other objects related to this
10178 * Component Instance and allows you to destroy the Component Instance via the {@link #destroy}
10179 * method.
10180 *
10181 */
10182export declare class ɵRender3ComponentRef<T> extends ComponentRef<T> {
10183 location: ElementRef;
10184 private _rootLView;
10185 private _tNode;
10186 destroyCbs: (() => void)[] | null;
10187 instance: T;
10188 hostView: ViewRef_2<T>;
10189 changeDetectorRef: ChangeDetectorRef;
10190 componentType: Type<T>;
10191 constructor(componentType: Type<T>, instance: T, location: ElementRef, _rootLView: ɵangular_packages_core_core_bj, _tNode: ɵangular_packages_core_core_bf | TContainerNode | TElementContainerNode);
10192 readonly injector: Injector;
10193 destroy(): void;
10194 onDestroy(callback: () => void): void;
10195}
10196
10197export declare class ɵRender3NgModuleRef<T> extends NgModuleRef<T> implements InternalNgModuleRef<T> {
10198 _parent: Injector | null;
10199 _bootstrapComponents: Type<any>[];
10200 _r3Injector: R3Injector;
10201 injector: Injector;
10202 instance: T;
10203 destroyCbs: (() => void)[] | null;
10204 constructor(ngModuleType: Type<T>, _parent: Injector | null);
10205 get(token: any, notFoundValue?: any, injectFlags?: InjectFlags): any;
10206 readonly componentFactoryResolver: ComponentFactoryResolver;
10207 destroy(): void;
10208 onDestroy(callback: () => void): void;
10209}
10210
10211/**
10212 * Bootstraps a Component into an existing host element and returns an instance
10213 * of the component.
10214 *
10215 * Use this function to bootstrap a component into the DOM tree. Each invocation
10216 * of this function will create a separate tree of components, injectors and
10217 * change detection cycles and lifetimes. To dynamically insert a new component
10218 * into an existing tree such that it shares the same injection, change detection
10219 * and object lifetime, use {@link ViewContainer#createComponent}.
10220 *
10221 * @param componentType Component to bootstrap
10222 * @param options Optional parameters which control bootstrapping
10223 */
10224export declare function ɵrenderComponent<T>(componentType: ɵComponentType<T> | Type<T>, opts?: CreateComponentOptions): T;
10225
10226/**
10227 * @deprecated Debug info is handled internally in the view engine now.
10228 */
10229export declare abstract class ɵRenderDebugInfo {
10230 abstract readonly injector: Injector;
10231 abstract readonly component: any;
10232 abstract readonly providerTokens: any[];
10233 abstract readonly references: {
10234 [key: string]: any;
10235 };
10236 abstract readonly context: any;
10237 abstract readonly source: string;
10238}
10239
10240/**
10241 * Flags passed into template functions to determine which blocks (i.e. creation, update)
10242 * should be executed.
10243 *
10244 * Typically, a template runs both the creation block and the update block on initialization and
10245 * subsequent runs only execute the update block. However, dynamically created views require that
10246 * the creation block be executed separately from the update block (for backwards compat).
10247 */
10248export declare const enum ɵRenderFlags {
10249 Create = 1,
10250 Update = 2
10251}
10252
10253export declare function ɵresetCompiledComponents(): void;
10254
10255/**
10256 * Used to resolve resource URLs on `@Component` when used with JIT compilation.
10257 *
10258 * Example:
10259 * ```
10260 * @Component({
10261 * selector: 'my-comp',
10262 * templateUrl: 'my-comp.html', // This requires asynchronous resolution
10263 * })
10264 * class MyComponent{
10265 * }
10266 *
10267 * // Calling `renderComponent` will fail because `renderComponent` is a synchronous process
10268 * // and `MyComponent`'s `@Component.templateUrl` needs to be resolved asynchronously.
10269 *
10270 * // Calling `resolveComponentResources()` will resolve `@Component.templateUrl` into
10271 * // `@Component.template`, which allows `renderComponent` to proceed in a synchronous manner.
10272 *
10273 * // Use browser's `fetch()` function as the default resource resolution strategy.
10274 * resolveComponentResources(fetch).then(() => {
10275 * // After resolution all URLs have been converted into `template` strings.
10276 * renderComponent(MyComponent);
10277 * });
10278 *
10279 * ```
10280 *
10281 * NOTE: In AOT the resolution happens during compilation, and so there should be no need
10282 * to call this method outside JIT mode.
10283 *
10284 * @param resourceResolver a function which is responsible for returning a `Promise` to the
10285 * contents of the resolved URL. Browser's `fetch()` method is a good default implementation.
10286 */
10287export declare function ɵresolveComponentResources(resourceResolver: (url: string) => (Promise<string | {
10288 text(): Promise<string>;
10289}>)): Promise<void>;
10290
10291/**
10292 * Adds decorator, constructor, and property metadata to a given type via static metadata fields
10293 * on the type.
10294 *
10295 * These metadata fields can later be read with Angular's `ReflectionCapabilities` API.
10296 *
10297 * Calls to `setClassMetadata` can be marked as pure, resulting in the metadata assignments being
10298 * tree-shaken away during production builds.
10299 */
10300export declare function ɵsetClassMetadata(type: Type<any>, decorators: any[] | null, ctorParameters: (() => any[]) | null, propDecorators: {
10301 [field: string]: any;
10302} | null): void;
10303
10304export declare function ɵsetCurrentInjector(injector: Injector | null | undefined): Injector | undefined | null;
10305
10306/**
10307 * Sets the locale id that will be used for translations and ICU expressions.
10308 * This is the ivy version of `LOCALE_ID` that was defined as an injection token for the view engine
10309 * but is now defined as a global value.
10310 *
10311 * @param localeId
10312 */
10313export declare function ɵsetLocaleId(localeId: string): void;
10314
10315
10316export declare type ɵSetterFn = (obj: any, value: any) => void;
10317
10318/** Store a value in the `data` at a given `index`. */
10319export declare function ɵstore<T>(index: number, value: T): void;
10320
10321
10322export declare function ɵstringify(token: any): string;
10323
10324export declare const ɵSWITCH_CHANGE_DETECTOR_REF_FACTORY__POST_R3__: typeof injectChangeDetectorRef;
10325
10326export declare const ɵSWITCH_COMPILE_COMPONENT__POST_R3__: typeof ɵcompileComponent;
10327
10328export declare const ɵSWITCH_COMPILE_DIRECTIVE__POST_R3__: typeof ɵcompileDirective;
10329
10330export declare const ɵSWITCH_COMPILE_INJECTABLE__POST_R3__: typeof compileInjectable;
10331
10332export declare const ɵSWITCH_COMPILE_NGMODULE__POST_R3__: typeof ɵcompileNgModule;
10333
10334export declare const ɵSWITCH_COMPILE_PIPE__POST_R3__: typeof ɵcompilePipe;
10335
10336export declare const ɵSWITCH_ELEMENT_REF_FACTORY__POST_R3__: typeof injectElementRef;
10337
10338
10339export declare const ɵSWITCH_IVY_ENABLED__POST_R3__ = true;
10340
10341export declare const ɵSWITCH_RENDERER2_FACTORY__POST_R3__: typeof injectRenderer2;
10342
10343export declare const ɵSWITCH_TEMPLATE_REF_FACTORY__POST_R3__: typeof injectTemplateRef;
10344
10345export declare const ɵSWITCH_VIEW_CONTAINER_REF_FACTORY__POST_R3__: typeof injectViewContainerRef;
10346
10347export declare function ɵted(checkIndex: number, ngContentIndex: number | null, staticText: string[]): NodeDef;
10348
10349/**
10350 * Compute the pair of transitive scopes (compilation scope and exported scope) for a given module.
10351 *
10352 * This operation is memoized and the result is cached on the module's definition. It can be called
10353 * on modules with components that have not fully compiled yet, but the result should not be used
10354 * until they have.
10355 */
10356export declare function ɵtransitiveScopesFor<T>(moduleType: Type<T>, processNgModuleFn?: (ngModule: ɵNgModuleType) => void): ɵNgModuleTransitiveScopes;
10357
10358export declare function ɵunv(view: ViewData, nodeIdx: number, bindingIdx: number, value: any): any;
10359
10360export declare function ɵvid(flags: ɵViewFlags, nodes: NodeDef[], updateDirectives?: null | ViewUpdateFn, updateRenderer?: null | ViewUpdateFn): ɵViewDefinition;
10361
10362export declare interface ɵViewDefinition extends Definition<ViewDefinitionFactory> {
10363 flags: ɵViewFlags;
10364 updateDirectives: ViewUpdateFn;
10365 updateRenderer: ViewUpdateFn;
10366 handleEvent: ViewHandleEventFn;
10367 /**
10368 * Order: Depth first.
10369 * Especially providers are before elements / anchors.
10370 */
10371 nodes: NodeDef[];
10372 /** aggregated NodeFlags for all nodes **/
10373 nodeFlags: ɵNodeFlags;
10374 rootNodeFlags: ɵNodeFlags;
10375 lastRenderRootNode: NodeDef | null;
10376 bindingCount: number;
10377 outputCount: number;
10378 /**
10379 * Binary or of all query ids that are matched by one of the nodes.
10380 * This includes query ids from templates as well.
10381 * Used as a bloom filter.
10382 */
10383 nodeMatchedQueries: number;
10384}
10385
10386/**
10387 * Bitmask for ViewDefinition.flags.
10388 */
10389export declare const enum ɵViewFlags {
10390 None = 0,
10391 OnPush = 2
10392}
10393
10394/**
10395 * Wait on component until it is rendered.
10396 *
10397 * This function returns a `Promise` which is resolved when the component's
10398 * change detection is executed. This is determined by finding the scheduler
10399 * associated with the `component`'s render tree and waiting until the scheduler
10400 * flushes. If nothing is scheduled, the function returns a resolved promise.
10401 *
10402 * Example:
10403 * ```
10404 * await whenRendered(myComponent);
10405 * ```
10406 *
10407 * @param component Component to wait upon
10408 * @returns Promise which resolves when the component is rendered.
10409 */
10410export declare function ɵwhenRendered(component: any): Promise<null>;
10411
10412
10413/**
10414 * Allocates the necessary amount of slots for host vars.
10415 *
10416 * @param count Amount of vars to be allocated
10417 *
10418 * @codeGenApi
10419 */
10420export declare function ɵɵallocHostVars(count: number): void;
10421
10422/**
10423 * Updates the value of or removes a bound attribute on an Element.
10424 *
10425 * Used in the case of `[attr.title]="value"`
10426 *
10427 * @param name name The name of the attribute.
10428 * @param value value The attribute is removed when value is `null` or `undefined`.
10429 * Otherwise the attribute value is set to the stringified value.
10430 * @param sanitizer An optional function used to sanitize the value.
10431 * @param namespace Optional namespace to use when setting the attribute.
10432 *
10433 * @codeGenApi
10434 */
10435export declare function ɵɵattribute(name: string, value: any, sanitizer?: SanitizerFn | null, namespace?: string): TsickleIssue1009;
10436
10437/**
10438 *
10439 * Update an interpolated attribute on an element with single bound value surrounded by text.
10440 *
10441 * Used when the value passed to a property has 1 interpolated value in it:
10442 *
10443 * ```html
10444 * <div attr.title="prefix{{v0}}suffix"></div>
10445 * ```
10446 *
10447 * Its compiled representation is::
10448 *
10449 * ```ts
10450 * ɵɵattributeInterpolate1('title', 'prefix', v0, 'suffix');
10451 * ```
10452 *
10453 * @param attrName The name of the attribute to update
10454 * @param prefix Static value used for concatenation only.
10455 * @param v0 Value checked for change.
10456 * @param suffix Static value used for concatenation only.
10457 * @param sanitizer An optional sanitizer function
10458 * @returns itself, so that it may be chained.
10459 * @codeGenApi
10460 */
10461export declare function ɵɵattributeInterpolate1(attrName: string, prefix: string, v0: any, suffix: string, sanitizer?: SanitizerFn, namespace?: string): TsickleIssue1009;
10462
10463/**
10464 *
10465 * Update an interpolated attribute on an element with 2 bound values surrounded by text.
10466 *
10467 * Used when the value passed to a property has 2 interpolated values in it:
10468 *
10469 * ```html
10470 * <div attr.title="prefix{{v0}}-{{v1}}suffix"></div>
10471 * ```
10472 *
10473 * Its compiled representation is::
10474 *
10475 * ```ts
10476 * ɵɵattributeInterpolate2('title', 'prefix', v0, '-', v1, 'suffix');
10477 * ```
10478 *
10479 * @param attrName The name of the attribute to update
10480 * @param prefix Static value used for concatenation only.
10481 * @param v0 Value checked for change.
10482 * @param i0 Static value used for concatenation only.
10483 * @param v1 Value checked for change.
10484 * @param suffix Static value used for concatenation only.
10485 * @param sanitizer An optional sanitizer function
10486 * @returns itself, so that it may be chained.
10487 * @codeGenApi
10488 */
10489export declare function ɵɵattributeInterpolate2(attrName: string, prefix: string, v0: any, i0: string, v1: any, suffix: string, sanitizer?: SanitizerFn, namespace?: string): TsickleIssue1009;
10490
10491/**
10492 *
10493 * Update an interpolated attribute on an element with 3 bound values surrounded by text.
10494 *
10495 * Used when the value passed to a property has 3 interpolated values in it:
10496 *
10497 * ```html
10498 * <div attr.title="prefix{{v0}}-{{v1}}-{{v2}}suffix"></div>
10499 * ```
10500 *
10501 * Its compiled representation is::
10502 *
10503 * ```ts
10504 * ɵɵattributeInterpolate3(
10505 * 'title', 'prefix', v0, '-', v1, '-', v2, 'suffix');
10506 * ```
10507 *
10508 * @param attrName The name of the attribute to update
10509 * @param prefix Static value used for concatenation only.
10510 * @param v0 Value checked for change.
10511 * @param i0 Static value used for concatenation only.
10512 * @param v1 Value checked for change.
10513 * @param i1 Static value used for concatenation only.
10514 * @param v2 Value checked for change.
10515 * @param suffix Static value used for concatenation only.
10516 * @param sanitizer An optional sanitizer function
10517 * @returns itself, so that it may be chained.
10518 * @codeGenApi
10519 */
10520export declare function ɵɵattributeInterpolate3(attrName: string, prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, suffix: string, sanitizer?: SanitizerFn, namespace?: string): TsickleIssue1009;
10521
10522/**
10523 *
10524 * Update an interpolated attribute on an element with 4 bound values surrounded by text.
10525 *
10526 * Used when the value passed to a property has 4 interpolated values in it:
10527 *
10528 * ```html
10529 * <div attr.title="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}suffix"></div>
10530 * ```
10531 *
10532 * Its compiled representation is::
10533 *
10534 * ```ts
10535 * ɵɵattributeInterpolate4(
10536 * 'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, 'suffix');
10537 * ```
10538 *
10539 * @param attrName The name of the attribute to update
10540 * @param prefix Static value used for concatenation only.
10541 * @param v0 Value checked for change.
10542 * @param i0 Static value used for concatenation only.
10543 * @param v1 Value checked for change.
10544 * @param i1 Static value used for concatenation only.
10545 * @param v2 Value checked for change.
10546 * @param i2 Static value used for concatenation only.
10547 * @param v3 Value checked for change.
10548 * @param suffix Static value used for concatenation only.
10549 * @param sanitizer An optional sanitizer function
10550 * @returns itself, so that it may be chained.
10551 * @codeGenApi
10552 */
10553export declare function ɵɵattributeInterpolate4(attrName: string, prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string, v3: any, suffix: string, sanitizer?: SanitizerFn, namespace?: string): TsickleIssue1009;
10554
10555/**
10556 *
10557 * Update an interpolated attribute on an element with 5 bound values surrounded by text.
10558 *
10559 * Used when the value passed to a property has 5 interpolated values in it:
10560 *
10561 * ```html
10562 * <div attr.title="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}suffix"></div>
10563 * ```
10564 *
10565 * Its compiled representation is::
10566 *
10567 * ```ts
10568 * ɵɵattributeInterpolate5(
10569 * 'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, 'suffix');
10570 * ```
10571 *
10572 * @param attrName The name of the attribute to update
10573 * @param prefix Static value used for concatenation only.
10574 * @param v0 Value checked for change.
10575 * @param i0 Static value used for concatenation only.
10576 * @param v1 Value checked for change.
10577 * @param i1 Static value used for concatenation only.
10578 * @param v2 Value checked for change.
10579 * @param i2 Static value used for concatenation only.
10580 * @param v3 Value checked for change.
10581 * @param i3 Static value used for concatenation only.
10582 * @param v4 Value checked for change.
10583 * @param suffix Static value used for concatenation only.
10584 * @param sanitizer An optional sanitizer function
10585 * @returns itself, so that it may be chained.
10586 * @codeGenApi
10587 */
10588export declare function ɵɵattributeInterpolate5(attrName: string, prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string, v3: any, i3: string, v4: any, suffix: string, sanitizer?: SanitizerFn, namespace?: string): TsickleIssue1009;
10589
10590/**
10591 *
10592 * Update an interpolated attribute on an element with 6 bound values surrounded by text.
10593 *
10594 * Used when the value passed to a property has 6 interpolated values in it:
10595 *
10596 * ```html
10597 * <div attr.title="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}suffix"></div>
10598 * ```
10599 *
10600 * Its compiled representation is::
10601 *
10602 * ```ts
10603 * ɵɵattributeInterpolate6(
10604 * 'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, 'suffix');
10605 * ```
10606 *
10607 * @param attrName The name of the attribute to update
10608 * @param prefix Static value used for concatenation only.
10609 * @param v0 Value checked for change.
10610 * @param i0 Static value used for concatenation only.
10611 * @param v1 Value checked for change.
10612 * @param i1 Static value used for concatenation only.
10613 * @param v2 Value checked for change.
10614 * @param i2 Static value used for concatenation only.
10615 * @param v3 Value checked for change.
10616 * @param i3 Static value used for concatenation only.
10617 * @param v4 Value checked for change.
10618 * @param i4 Static value used for concatenation only.
10619 * @param v5 Value checked for change.
10620 * @param suffix Static value used for concatenation only.
10621 * @param sanitizer An optional sanitizer function
10622 * @returns itself, so that it may be chained.
10623 * @codeGenApi
10624 */
10625export declare function ɵɵattributeInterpolate6(attrName: string, prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string, v3: any, i3: string, v4: any, i4: string, v5: any, suffix: string, sanitizer?: SanitizerFn, namespace?: string): TsickleIssue1009;
10626
10627/**
10628 *
10629 * Update an interpolated attribute on an element with 7 bound values surrounded by text.
10630 *
10631 * Used when the value passed to a property has 7 interpolated values in it:
10632 *
10633 * ```html
10634 * <div attr.title="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}suffix"></div>
10635 * ```
10636 *
10637 * Its compiled representation is::
10638 *
10639 * ```ts
10640 * ɵɵattributeInterpolate7(
10641 * 'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, 'suffix');
10642 * ```
10643 *
10644 * @param attrName The name of the attribute to update
10645 * @param prefix Static value used for concatenation only.
10646 * @param v0 Value checked for change.
10647 * @param i0 Static value used for concatenation only.
10648 * @param v1 Value checked for change.
10649 * @param i1 Static value used for concatenation only.
10650 * @param v2 Value checked for change.
10651 * @param i2 Static value used for concatenation only.
10652 * @param v3 Value checked for change.
10653 * @param i3 Static value used for concatenation only.
10654 * @param v4 Value checked for change.
10655 * @param i4 Static value used for concatenation only.
10656 * @param v5 Value checked for change.
10657 * @param i5 Static value used for concatenation only.
10658 * @param v6 Value checked for change.
10659 * @param suffix Static value used for concatenation only.
10660 * @param sanitizer An optional sanitizer function
10661 * @returns itself, so that it may be chained.
10662 * @codeGenApi
10663 */
10664export declare function ɵɵattributeInterpolate7(attrName: string, prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string, v3: any, i3: string, v4: any, i4: string, v5: any, i5: string, v6: any, suffix: string, sanitizer?: SanitizerFn, namespace?: string): TsickleIssue1009;
10665
10666/**
10667 *
10668 * Update an interpolated attribute on an element with 8 bound values surrounded by text.
10669 *
10670 * Used when the value passed to a property has 8 interpolated values in it:
10671 *
10672 * ```html
10673 * <div attr.title="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}-{{v7}}suffix"></div>
10674 * ```
10675 *
10676 * Its compiled representation is::
10677 *
10678 * ```ts
10679 * ɵɵattributeInterpolate8(
10680 * 'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, '-', v7, 'suffix');
10681 * ```
10682 *
10683 * @param attrName The name of the attribute to update
10684 * @param prefix Static value used for concatenation only.
10685 * @param v0 Value checked for change.
10686 * @param i0 Static value used for concatenation only.
10687 * @param v1 Value checked for change.
10688 * @param i1 Static value used for concatenation only.
10689 * @param v2 Value checked for change.
10690 * @param i2 Static value used for concatenation only.
10691 * @param v3 Value checked for change.
10692 * @param i3 Static value used for concatenation only.
10693 * @param v4 Value checked for change.
10694 * @param i4 Static value used for concatenation only.
10695 * @param v5 Value checked for change.
10696 * @param i5 Static value used for concatenation only.
10697 * @param v6 Value checked for change.
10698 * @param i6 Static value used for concatenation only.
10699 * @param v7 Value checked for change.
10700 * @param suffix Static value used for concatenation only.
10701 * @param sanitizer An optional sanitizer function
10702 * @returns itself, so that it may be chained.
10703 * @codeGenApi
10704 */
10705export declare function ɵɵattributeInterpolate8(attrName: string, prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string, v3: any, i3: string, v4: any, i4: string, v5: any, i5: string, v6: any, i6: string, v7: any, suffix: string, sanitizer?: SanitizerFn, namespace?: string): TsickleIssue1009;
10706
10707/**
10708 * Update an interpolated attribute on an element with 8 or more bound values surrounded by text.
10709 *
10710 * Used when the number of interpolated values exceeds 7.
10711 *
10712 * ```html
10713 * <div
10714 * title="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}-{{v7}}-{{v8}}-{{v9}}suffix"></div>
10715 * ```
10716 *
10717 * Its compiled representation is::
10718 *
10719 * ```ts
10720 * ɵɵattributeInterpolateV(
10721 * 'title', ['prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, '-', v7, '-', v9,
10722 * 'suffix']);
10723 * ```
10724 *
10725 * @param attrName The name of the attribute to update.
10726 * @param values The a collection of values and the strings in-between those values, beginning with
10727 * a string prefix and ending with a string suffix.
10728 * (e.g. `['prefix', value0, '-', value1, '-', value2, ..., value99, 'suffix']`)
10729 * @param sanitizer An optional sanitizer function
10730 * @returns itself, so that it may be chained.
10731 * @codeGenApi
10732 */
10733export declare function ɵɵattributeInterpolateV(attrName: string, values: any[], sanitizer?: SanitizerFn, namespace?: string): TsickleIssue1009;
10734
10735/**
10736 * Runtime information for classes that are inherited by components or directives
10737 * that aren't defined as components or directives.
10738 *
10739 * This is an internal data structure used by the renderer to determine what inputs
10740 * and outputs should be inherited.
10741 *
10742 * See: {@link defineBase}
10743 *
10744 * @codeGenApi
10745 */
10746export declare interface ɵɵBaseDef<T> {
10747 /**
10748 * A dictionary mapping the inputs' minified property names to their public API names, which
10749 * are their aliases if any, or their original unminified property names
10750 * (as in `@Input('alias') propertyName: any;`).
10751 */
10752 readonly inputs: {
10753 [P in keyof T]: string;
10754 };
10755 /**
10756 * @deprecated This is only here because `NgOnChanges` incorrectly uses declared name instead of
10757 * public or minified name.
10758 */
10759 readonly declaredInputs: {
10760 [P in keyof T]: string;
10761 };
10762 /**
10763 * A dictionary mapping the outputs' minified property names to their public API names, which
10764 * are their aliases if any, or their original unminified property names
10765 * (as in `@Output('alias') propertyName: any;`).
10766 */
10767 readonly outputs: {
10768 [P in keyof T]: string;
10769 };
10770 /**
10771 * Function to create and refresh content queries associated with a given directive.
10772 */
10773 contentQueries: ContentQueriesFunction<T> | null;
10774 /**
10775 * Query-related instructions for a directive. Note that while directives don't have a
10776 * view and as such view queries won't necessarily do anything, there might be
10777 * components that extend the directive.
10778 */
10779 viewQuery: ViewQueriesFunction<T> | null;
10780 /**
10781 * Refreshes host bindings on the associated directive.
10782 */
10783 hostBindings: HostBindingsFunction<T> | null;
10784}
10785
10786/**
10787 * Update class bindings using an object literal or class-string on an element.
10788 *
10789 * This instruction is meant to apply styling via the `[class]="exp"` template bindings.
10790 * When classes are applied to the element they will then be updated with
10791 * respect to any styles/classes set via `classProp`. If any
10792 * classes are set to falsy then they will be removed from the element.
10793 *
10794 * Note that the styling instruction will not be applied until `stylingApply` is called.
10795 * Note that this will the provided classMap value to the host element if this function is called
10796 * within a host binding.
10797 *
10798 * @param classes A key/value map or string of CSS classes that will be added to the
10799 * given element. Any missing classes (that have already been applied to the element
10800 * beforehand) will be removed (unset) from the element's list of CSS classes.
10801 *
10802 * @codeGenApi
10803 */
10804export declare function ɵɵclassMap(classes: {
10805 [className: string]: any;
10806} | ɵNO_CHANGE | string | null): void;
10807
10808
10809/**
10810 *
10811 * Update an interpolated class on an element with single bound value surrounded by text.
10812 *
10813 * Used when the value passed to a property has 1 interpolated value in it:
10814 *
10815 * ```html
10816 * <div class="prefix{{v0}}suffix"></div>
10817 * ```
10818 *
10819 * Its compiled representation is:
10820 *
10821 * ```ts
10822 * ɵɵclassMapInterpolate1('prefix', v0, 'suffix');
10823 * ```
10824 *
10825 * @param prefix Static value used for concatenation only.
10826 * @param v0 Value checked for change.
10827 * @param suffix Static value used for concatenation only.
10828 * @codeGenApi
10829 */
10830export declare function ɵɵclassMapInterpolate1(prefix: string, v0: any, suffix: string): void;
10831
10832/**
10833 *
10834 * Update an interpolated class on an element with 2 bound values surrounded by text.
10835 *
10836 * Used when the value passed to a property has 2 interpolated values in it:
10837 *
10838 * ```html
10839 * <div class="prefix{{v0}}-{{v1}}suffix"></div>
10840 * ```
10841 *
10842 * Its compiled representation is:
10843 *
10844 * ```ts
10845 * ɵɵclassMapInterpolate2('prefix', v0, '-', v1, 'suffix');
10846 * ```
10847 *
10848 * @param prefix Static value used for concatenation only.
10849 * @param v0 Value checked for change.
10850 * @param i0 Static value used for concatenation only.
10851 * @param v1 Value checked for change.
10852 * @param suffix Static value used for concatenation only.
10853 * @codeGenApi
10854 */
10855export declare function ɵɵclassMapInterpolate2(prefix: string, v0: any, i0: string, v1: any, suffix: string): void;
10856
10857/**
10858 *
10859 * Update an interpolated class on an element with 3 bound values surrounded by text.
10860 *
10861 * Used when the value passed to a property has 3 interpolated values in it:
10862 *
10863 * ```html
10864 * <div class="prefix{{v0}}-{{v1}}-{{v2}}suffix"></div>
10865 * ```
10866 *
10867 * Its compiled representation is:
10868 *
10869 * ```ts
10870 * ɵɵclassMapInterpolate3(
10871 * 'prefix', v0, '-', v1, '-', v2, 'suffix');
10872 * ```
10873 *
10874 * @param prefix Static value used for concatenation only.
10875 * @param v0 Value checked for change.
10876 * @param i0 Static value used for concatenation only.
10877 * @param v1 Value checked for change.
10878 * @param i1 Static value used for concatenation only.
10879 * @param v2 Value checked for change.
10880 * @param suffix Static value used for concatenation only.
10881 * @codeGenApi
10882 */
10883export declare function ɵɵclassMapInterpolate3(prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, suffix: string): void;
10884
10885/**
10886 *
10887 * Update an interpolated class on an element with 4 bound values surrounded by text.
10888 *
10889 * Used when the value passed to a property has 4 interpolated values in it:
10890 *
10891 * ```html
10892 * <div class="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}suffix"></div>
10893 * ```
10894 *
10895 * Its compiled representation is:
10896 *
10897 * ```ts
10898 * ɵɵclassMapInterpolate4(
10899 * 'prefix', v0, '-', v1, '-', v2, '-', v3, 'suffix');
10900 * ```
10901 *
10902 * @param prefix Static value used for concatenation only.
10903 * @param v0 Value checked for change.
10904 * @param i0 Static value used for concatenation only.
10905 * @param v1 Value checked for change.
10906 * @param i1 Static value used for concatenation only.
10907 * @param v2 Value checked for change.
10908 * @param i2 Static value used for concatenation only.
10909 * @param v3 Value checked for change.
10910 * @param suffix Static value used for concatenation only.
10911 * @codeGenApi
10912 */
10913export declare function ɵɵclassMapInterpolate4(prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string, v3: any, suffix: string): void;
10914
10915/**
10916 *
10917 * Update an interpolated class on an element with 5 bound values surrounded by text.
10918 *
10919 * Used when the value passed to a property has 5 interpolated values in it:
10920 *
10921 * ```html
10922 * <div class="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}suffix"></div>
10923 * ```
10924 *
10925 * Its compiled representation is:
10926 *
10927 * ```ts
10928 * ɵɵclassMapInterpolate5(
10929 * 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, 'suffix');
10930 * ```
10931 *
10932 * @param prefix Static value used for concatenation only.
10933 * @param v0 Value checked for change.
10934 * @param i0 Static value used for concatenation only.
10935 * @param v1 Value checked for change.
10936 * @param i1 Static value used for concatenation only.
10937 * @param v2 Value checked for change.
10938 * @param i2 Static value used for concatenation only.
10939 * @param v3 Value checked for change.
10940 * @param i3 Static value used for concatenation only.
10941 * @param v4 Value checked for change.
10942 * @param suffix Static value used for concatenation only.
10943 * @codeGenApi
10944 */
10945export declare function ɵɵclassMapInterpolate5(prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string, v3: any, i3: string, v4: any, suffix: string): void;
10946
10947/**
10948 *
10949 * Update an interpolated class on an element with 6 bound values surrounded by text.
10950 *
10951 * Used when the value passed to a property has 6 interpolated values in it:
10952 *
10953 * ```html
10954 * <div class="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}suffix"></div>
10955 * ```
10956 *
10957 * Its compiled representation is:
10958 *
10959 * ```ts
10960 * ɵɵclassMapInterpolate6(
10961 * 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, 'suffix');
10962 * ```
10963 *
10964 * @param prefix Static value used for concatenation only.
10965 * @param v0 Value checked for change.
10966 * @param i0 Static value used for concatenation only.
10967 * @param v1 Value checked for change.
10968 * @param i1 Static value used for concatenation only.
10969 * @param v2 Value checked for change.
10970 * @param i2 Static value used for concatenation only.
10971 * @param v3 Value checked for change.
10972 * @param i3 Static value used for concatenation only.
10973 * @param v4 Value checked for change.
10974 * @param i4 Static value used for concatenation only.
10975 * @param v5 Value checked for change.
10976 * @param suffix Static value used for concatenation only.
10977 * @codeGenApi
10978 */
10979export declare function ɵɵclassMapInterpolate6(prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string, v3: any, i3: string, v4: any, i4: string, v5: any, suffix: string): void;
10980
10981/**
10982 *
10983 * Update an interpolated class on an element with 7 bound values surrounded by text.
10984 *
10985 * Used when the value passed to a property has 7 interpolated values in it:
10986 *
10987 * ```html
10988 * <div class="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}suffix"></div>
10989 * ```
10990 *
10991 * Its compiled representation is:
10992 *
10993 * ```ts
10994 * ɵɵclassMapInterpolate7(
10995 * 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, 'suffix');
10996 * ```
10997 *
10998 * @param prefix Static value used for concatenation only.
10999 * @param v0 Value checked for change.
11000 * @param i0 Static value used for concatenation only.
11001 * @param v1 Value checked for change.
11002 * @param i1 Static value used for concatenation only.
11003 * @param v2 Value checked for change.
11004 * @param i2 Static value used for concatenation only.
11005 * @param v3 Value checked for change.
11006 * @param i3 Static value used for concatenation only.
11007 * @param v4 Value checked for change.
11008 * @param i4 Static value used for concatenation only.
11009 * @param v5 Value checked for change.
11010 * @param i5 Static value used for concatenation only.
11011 * @param v6 Value checked for change.
11012 * @param suffix Static value used for concatenation only.
11013 * @codeGenApi
11014 */
11015export declare function ɵɵclassMapInterpolate7(prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string, v3: any, i3: string, v4: any, i4: string, v5: any, i5: string, v6: any, suffix: string): void;
11016
11017/**
11018 *
11019 * Update an interpolated class on an element with 8 bound values surrounded by text.
11020 *
11021 * Used when the value passed to a property has 8 interpolated values in it:
11022 *
11023 * ```html
11024 * <div class="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}-{{v7}}suffix"></div>
11025 * ```
11026 *
11027 * Its compiled representation is:
11028 *
11029 * ```ts
11030 * ɵɵclassMapInterpolate8(
11031 * 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, '-', v7, 'suffix');
11032 * ```
11033 *
11034 * @param prefix Static value used for concatenation only.
11035 * @param v0 Value checked for change.
11036 * @param i0 Static value used for concatenation only.
11037 * @param v1 Value checked for change.
11038 * @param i1 Static value used for concatenation only.
11039 * @param v2 Value checked for change.
11040 * @param i2 Static value used for concatenation only.
11041 * @param v3 Value checked for change.
11042 * @param i3 Static value used for concatenation only.
11043 * @param v4 Value checked for change.
11044 * @param i4 Static value used for concatenation only.
11045 * @param v5 Value checked for change.
11046 * @param i5 Static value used for concatenation only.
11047 * @param v6 Value checked for change.
11048 * @param i6 Static value used for concatenation only.
11049 * @param v7 Value checked for change.
11050 * @param suffix Static value used for concatenation only.
11051 * @codeGenApi
11052 */
11053export declare function ɵɵclassMapInterpolate8(prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string, v3: any, i3: string, v4: any, i4: string, v5: any, i5: string, v6: any, i6: string, v7: any, suffix: string): void;
11054
11055/**
11056 * Update an interpolated class on an element with 8 or more bound values surrounded by text.
11057 *
11058 * Used when the number of interpolated values exceeds 7.
11059 *
11060 * ```html
11061 * <div
11062 * class="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}-{{v7}}-{{v8}}-{{v9}}suffix"></div>
11063 * ```
11064 *
11065 * Its compiled representation is:
11066 *
11067 * ```ts
11068 * ɵɵclassMapInterpolateV(
11069 * ['prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, '-', v7, '-', v9,
11070 * 'suffix']);
11071 * ```
11072 *.
11073 * @param values The a collection of values and the strings in-between those values, beginning with
11074 * a string prefix and ending with a string suffix.
11075 * (e.g. `['prefix', value0, '-', value1, '-', value2, ..., value99, 'suffix']`)
11076 * @codeGenApi
11077 */
11078export declare function ɵɵclassMapInterpolateV(values: any[]): void;
11079
11080/**
11081 * Update a class binding on an element with the provided value.
11082 *
11083 * This instruction is meant to handle the `[class.foo]="exp"` case and,
11084 * therefore, the class binding itself must already be allocated using
11085 * `styling` within the creation block.
11086 *
11087 * @param prop A valid CSS class (only one).
11088 * @param value A true/false value which will turn the class on or off.
11089 *
11090 * Note that this will apply the provided class value to the host element if this function
11091 * is called within a host binding.
11092 *
11093 * @codeGenApi
11094 */
11095export declare function ɵɵclassProp(className: string, value: boolean | null): void;
11096
11097/**
11098 * @codeGenApi
11099 */
11100export declare type ɵɵComponentDefWithMeta<T, Selector extends String, ExportAs extends string[], InputMap extends {
11101 [key: string]: string;
11102}, OutputMap extends {
11103 [key: string]: string;
11104}, QueryFields extends string[]> = ɵComponentDef<T>;
11105
11106/**
11107* Registers a synthetic host listener (e.g. `(@foo.start)`) on a component.
11108*
11109* This instruction is for compatibility purposes and is designed to ensure that a
11110* synthetic host listener (e.g. `@HostListener('@foo.start')`) properly gets rendered
11111* in the component's renderer. Normally all host listeners are evaluated with the
11112* parent component's renderer, but, in the case of animation @triggers, they need
11113* to be evaluated with the sub component's renderer (because that's where the
11114* animation triggers are defined).
11115*
11116* Do not use this instruction as a replacement for `listener`. This instruction
11117* only exists to ensure compatibility with the ViewEngine's host binding behavior.
11118*
11119* @param eventName Name of the event
11120* @param listenerFn The function to be called when event emits
11121* @param useCapture Whether or not to use capture in event listener
11122* @param eventTargetResolver Function that returns global target information in case this listener
11123* should be attached to a global object like window, document or body
11124 *
11125 * @codeGenApi
11126*/
11127export declare function ɵɵcomponentHostSyntheticListener(eventName: string, listenerFn: (e?: any) => any, useCapture?: boolean, eventTargetResolver?: GlobalTargetResolver): void;
11128
11129/**
11130 * Creates an LContainer for inline views, e.g.
11131 *
11132 * % if (showing) {
11133 * <div></div>
11134 * % }
11135 *
11136 * @param index The index of the container in the data array
11137 *
11138 * @codeGenApi
11139 */
11140export declare function ɵɵcontainer(index: number): void;
11141
11142/**
11143 * Marks the end of the LContainer.
11144 *
11145 * Marking the end of LContainer is the time when to child views get inserted or removed.
11146 *
11147 * @codeGenApi
11148 */
11149export declare function ɵɵcontainerRefreshEnd(): void;
11150
11151/**
11152 * Sets a container up to receive views.
11153 *
11154 * @param index The index of the container in the data array
11155 *
11156 * @codeGenApi
11157 */
11158export declare function ɵɵcontainerRefreshStart(index: number): void;
11159
11160/**
11161 * Registers a QueryList, associated with a content query, for later refresh (part of a view
11162 * refresh).
11163 *
11164 * @param directiveIndex Current directive index
11165 * @param predicate The type for which the query will search
11166 * @param descend Whether or not to descend into children
11167 * @param read What to save in the query
11168 * @returns QueryList<T>
11169 *
11170 * @codeGenApi
11171 */
11172export declare function ɵɵcontentQuery<T>(directiveIndex: number, predicate: Type<any> | string[], descend: boolean, read?: any): void;
11173
11174/**
11175 * The default style sanitizer will handle sanitization for style properties by
11176 * sanitizing any CSS property that can include a `url` value (usually image-based properties)
11177 *
11178 * @publicApi
11179 */
11180export declare const ɵɵdefaultStyleSanitizer: StyleSanitizeFn;
11181
11182/**
11183 * Create a base definition
11184 *
11185 * # Example
11186 * ```ts
11187 * class ShouldBeInherited {
11188 * static ngBaseDef = ɵɵdefineBase({
11189 * ...
11190 * })
11191 * }
11192 * ```
11193 *
11194 * @param baseDefinition The base definition parameters
11195 *
11196 * @codeGenApi
11197 */
11198export declare function ɵɵdefineBase<T>(baseDefinition: {
11199 /**
11200 * A map of input names.
11201 *
11202 * The format is in: `{[actualPropertyName: string]:(string|[string, string])}`.
11203 *
11204 * Given:
11205 * ```
11206 * class MyComponent {
11207 * @Input()
11208 * publicInput1: string;
11209 *
11210 * @Input('publicInput2')
11211 * declaredInput2: string;
11212 * }
11213 * ```
11214 *
11215 * is described as:
11216 * ```
11217 * {
11218 * publicInput1: 'publicInput1',
11219 * declaredInput2: ['declaredInput2', 'publicInput2'],
11220 * }
11221 * ```
11222 *
11223 * Which the minifier may translate to:
11224 * ```
11225 * {
11226 * minifiedPublicInput1: 'publicInput1',
11227 * minifiedDeclaredInput2: [ 'declaredInput2', 'publicInput2'],
11228 * }
11229 * ```
11230 *
11231 * This allows the render to re-construct the minified, public, and declared names
11232 * of properties.
11233 *
11234 * NOTE:
11235 * - Because declared and public name are usually same we only generate the array
11236 * `['declared', 'public']` format when they differ.
11237 * - The reason why this API and `outputs` API is not the same is that `NgOnChanges` has
11238 * inconsistent behavior in that it uses declared names rather than minified or public. For
11239 * this reason `NgOnChanges` will be deprecated and removed in future version and this
11240 * API will be simplified to be consistent with `outputs`.
11241 */
11242 inputs?: {
11243 [P in keyof T]?: string | [string, string];
11244 };
11245 /**
11246 * A map of output names.
11247 *
11248 * The format is in: `{[actualPropertyName: string]:string}`.
11249 *
11250 * Which the minifier may translate to: `{[minifiedPropertyName: string]:string}`.
11251 *
11252 * This allows the render to re-construct the minified and non-minified names
11253 * of properties.
11254 */
11255 outputs?: {
11256 [P in keyof T]?: string;
11257 };
11258 /**
11259 * Function to create instances of content queries associated with a given directive.
11260 */
11261 contentQueries?: ContentQueriesFunction<T> | null;
11262 /**
11263 * Additional set of instructions specific to view query processing. This could be seen as a
11264 * set of instructions to be inserted into the template function.
11265 */
11266 viewQuery?: ViewQueriesFunction<T> | null;
11267 /**
11268 * Function executed by the parent template to allow children to apply host bindings.
11269 */
11270 hostBindings?: HostBindingsFunction<T>;
11271}): ɵɵBaseDef<T>;
11272
11273/**
11274 * Create a component definition object.
11275 *
11276 *
11277 * # Example
11278 * ```
11279 * class MyDirective {
11280 * // Generated by Angular Template Compiler
11281 * // [Symbol] syntax will not be supported by TypeScript until v2.7
11282 * static ngComponentDef = defineComponent({
11283 * ...
11284 * });
11285 * }
11286 * ```
11287 * @codeGenApi
11288 */
11289export declare function ɵɵdefineComponent<T>(componentDefinition: {
11290 /**
11291 * Directive type, needed to configure the injector.
11292 */
11293 type: Type<T>;
11294 /** The selectors that will be used to match nodes to this component. */
11295 selectors: ɵCssSelectorList;
11296 /**
11297 * Factory method used to create an instance of directive.
11298 */
11299 factory: FactoryFn<T>;
11300 /**
11301 * The number of nodes, local refs, and pipes in this component template.
11302 *
11303 * Used to calculate the length of this component's LView array, so we
11304 * can pre-fill the array and set the binding start index.
11305 */
11306 consts: number;
11307 /**
11308 * The number of bindings in this component template (including pure fn bindings).
11309 *
11310 * Used to calculate the length of this component's LView array, so we
11311 * can pre-fill the array and set the host binding start index.
11312 */
11313 vars: number;
11314 /**
11315 * A map of input names.
11316 *
11317 * The format is in: `{[actualPropertyName: string]:(string|[string, string])}`.
11318 *
11319 * Given:
11320 * ```
11321 * class MyComponent {
11322 * @Input()
11323 * publicInput1: string;
11324 *
11325 * @Input('publicInput2')
11326 * declaredInput2: string;
11327 * }
11328 * ```
11329 *
11330 * is described as:
11331 * ```
11332 * {
11333 * publicInput1: 'publicInput1',
11334 * declaredInput2: ['publicInput2', 'declaredInput2'],
11335 * }
11336 * ```
11337 *
11338 * Which the minifier may translate to:
11339 * ```
11340 * {
11341 * minifiedPublicInput1: 'publicInput1',
11342 * minifiedDeclaredInput2: ['publicInput2', 'declaredInput2'],
11343 * }
11344 * ```
11345 *
11346 * This allows the render to re-construct the minified, public, and declared names
11347 * of properties.
11348 *
11349 * NOTE:
11350 * - Because declared and public name are usually same we only generate the array
11351 * `['public', 'declared']` format when they differ.
11352 * - The reason why this API and `outputs` API is not the same is that `NgOnChanges` has
11353 * inconsistent behavior in that it uses declared names rather than minified or public. For
11354 * this reason `NgOnChanges` will be deprecated and removed in future version and this
11355 * API will be simplified to be consistent with `output`.
11356 */
11357 inputs?: {
11358 [P in keyof T]?: string | [string, string];
11359 };
11360 /**
11361 * A map of output names.
11362 *
11363 * The format is in: `{[actualPropertyName: string]:string}`.
11364 *
11365 * Which the minifier may translate to: `{[minifiedPropertyName: string]:string}`.
11366 *
11367 * This allows the render to re-construct the minified and non-minified names
11368 * of properties.
11369 */
11370 outputs?: {
11371 [P in keyof T]?: string;
11372 };
11373 /**
11374 * Function executed by the parent template to allow child directive to apply host bindings.
11375 */
11376 hostBindings?: HostBindingsFunction<T>;
11377 /**
11378 * Function to create instances of content queries associated with a given directive.
11379 */
11380 contentQueries?: ContentQueriesFunction<T>;
11381 /**
11382 * Defines the name that can be used in the template to assign this directive to a variable.
11383 *
11384 * See: {@link Directive.exportAs}
11385 */
11386 exportAs?: string[];
11387 /**
11388 * Template function use for rendering DOM.
11389 *
11390 * This function has following structure.
11391 *
11392 * ```
11393 * function Template<T>(ctx:T, creationMode: boolean) {
11394 * if (creationMode) {
11395 * // Contains creation mode instructions.
11396 * }
11397 * // Contains binding update instructions
11398 * }
11399 * ```
11400 *
11401 * Common instructions are:
11402 * Creation mode instructions:
11403 * - `elementStart`, `elementEnd`
11404 * - `text`
11405 * - `container`
11406 * - `listener`
11407 *
11408 * Binding update instructions:
11409 * - `bind`
11410 * - `elementAttribute`
11411 * - `elementProperty`
11412 * - `elementClass`
11413 * - `elementStyle`
11414 *
11415 */
11416 template: ComponentTemplate<T>;
11417 /**
11418 * An array of `ngContent[selector]` values that were found in the template.
11419 */
11420 ngContentSelectors?: string[];
11421 /**
11422 * Additional set of instructions specific to view query processing. This could be seen as a
11423 * set of instruction to be inserted into the template function.
11424 *
11425 * Query-related instructions need to be pulled out to a specific function as a timing of
11426 * execution is different as compared to all other instructions (after change detection hooks but
11427 * before view hooks).
11428 */
11429 viewQuery?: ViewQueriesFunction<T> | null;
11430 /**
11431 * A list of optional features to apply.
11432 *
11433 * See: {@link NgOnChangesFeature}, {@link ProvidersFeature}
11434 */
11435 features?: ComponentDefFeature[];
11436 /**
11437 * Defines template and style encapsulation options available for Component's {@link Component}.
11438 */
11439 encapsulation?: ViewEncapsulation;
11440 /**
11441 * Defines arbitrary developer-defined data to be stored on a renderer instance.
11442 * This is useful for renderers that delegate to other renderers.
11443 *
11444 * see: animation
11445 */
11446 data?: {
11447 [kind: string]: any;
11448 };
11449 /**
11450 * A set of styles that the component needs to be present for component to render correctly.
11451 */
11452 styles?: string[];
11453 /**
11454 * The strategy that the default change detector uses to detect changes.
11455 * When set, takes effect the next time change detection is triggered.
11456 */
11457 changeDetection?: ChangeDetectionStrategy;
11458 /**
11459 * Registry of directives and components that may be found in this component's view.
11460 *
11461 * The property is either an array of `DirectiveDef`s or a function which returns the array of
11462 * `DirectiveDef`s. The function is necessary to be able to support forward declarations.
11463 */
11464 directives?: DirectiveTypesOrFactory | null;
11465 /**
11466 * Registry of pipes that may be found in this component's view.
11467 *
11468 * The property is either an array of `PipeDefs`s or a function which returns the array of
11469 * `PipeDefs`s. The function is necessary to be able to support forward declarations.
11470 */
11471 pipes?: PipeTypesOrFactory | null;
11472 /**
11473 * The set of schemas that declare elements to be allowed in the component's template.
11474 */
11475 schemas?: SchemaMetadata[] | null;
11476}): never;
11477
11478/**
11479 * Create a directive definition object.
11480 *
11481 * # Example
11482 * ```ts
11483 * class MyDirective {
11484 * // Generated by Angular Template Compiler
11485 * // [Symbol] syntax will not be supported by TypeScript until v2.7
11486 * static ngDirectiveDef = ɵɵdefineDirective({
11487 * ...
11488 * });
11489 * }
11490 * ```
11491 *
11492 * @codeGenApi
11493 */
11494export declare const ɵɵdefineDirective: <T>(directiveDefinition: {
11495 /**
11496 * Directive type, needed to configure the injector.
11497 */
11498 type: Type<T>;
11499 /** The selectors that will be used to match nodes to this directive. */
11500 selectors: (string | SelectorFlags)[][];
11501 /**
11502 * Factory method used to create an instance of directive.
11503 */
11504 factory: FactoryFn<T>;
11505 /**
11506 * A map of input names.
11507 *
11508 * The format is in: `{[actualPropertyName: string]:(string|[string, string])}`.
11509 *
11510 * Given:
11511 * ```
11512 * class MyComponent {
11513 * @Input()
11514 * publicInput1: string;
11515 *
11516 * @Input('publicInput2')
11517 * declaredInput2: string;
11518 * }
11519 * ```
11520 *
11521 * is described as:
11522 * ```
11523 * {
11524 * publicInput1: 'publicInput1',
11525 * declaredInput2: ['declaredInput2', 'publicInput2'],
11526 * }
11527 * ```
11528 *
11529 * Which the minifier may translate to:
11530 * ```
11531 * {
11532 * minifiedPublicInput1: 'publicInput1',
11533 * minifiedDeclaredInput2: [ 'publicInput2', 'declaredInput2'],
11534 * }
11535 * ```
11536 *
11537 * This allows the render to re-construct the minified, public, and declared names
11538 * of properties.
11539 *
11540 * NOTE:
11541 * - Because declared and public name are usually same we only generate the array
11542 * `['declared', 'public']` format when they differ.
11543 * - The reason why this API and `outputs` API is not the same is that `NgOnChanges` has
11544 * inconsistent behavior in that it uses declared names rather than minified or public. For
11545 * this reason `NgOnChanges` will be deprecated and removed in future version and this
11546 * API will be simplified to be consistent with `output`.
11547 */
11548 inputs?: { [P in keyof T]?: string | [string, string] | undefined; } | undefined;
11549 /**
11550 * A map of output names.
11551 *
11552 * The format is in: `{[actualPropertyName: string]:string}`.
11553 *
11554 * Which the minifier may translate to: `{[minifiedPropertyName: string]:string}`.
11555 *
11556 * This allows the render to re-construct the minified and non-minified names
11557 * of properties.
11558 */
11559 outputs?: { [P in keyof T]?: string | undefined; } | undefined;
11560 /**
11561 * A list of optional features to apply.
11562 *
11563 * See: {@link NgOnChangesFeature}, {@link ProvidersFeature}, {@link InheritDefinitionFeature}
11564 */
11565 features?: DirectiveDefFeature[] | undefined;
11566 /**
11567 * Function executed by the parent template to allow child directive to apply host bindings.
11568 */
11569 hostBindings?: HostBindingsFunction<T> | undefined;
11570 /**
11571 * Function to create instances of content queries associated with a given directive.
11572 */
11573 contentQueries?: ContentQueriesFunction<T> | undefined;
11574 /**
11575 * Additional set of instructions specific to view query processing. This could be seen as a
11576 * set of instructions to be inserted into the template function.
11577 */
11578 viewQuery?: ViewQueriesFunction<T> | null | undefined;
11579 /**
11580 * Defines the name that can be used in the template to assign this directive to a variable.
11581 *
11582 * See: {@link Directive.exportAs}
11583 */
11584 exportAs?: string[] | undefined;
11585}) => never;
11586
11587/**
11588 * Construct an `InjectableDef` which defines how a token will be constructed by the DI system, and
11589 * in which injectors (if any) it will be available.
11590 *
11591 * This should be assigned to a static `ngInjectableDef` field on a type, which will then be an
11592 * `InjectableType`.
11593 *
11594 * Options:
11595 * * `providedIn` determines which injectors will include the injectable, by either associating it
11596 * with an `@NgModule` or other `InjectorType`, or by specifying that this injectable should be
11597 * provided in the `'root'` injector, which will be the application-level injector in most apps.
11598 * * `factory` gives the zero argument function which will create an instance of the injectable.
11599 * The factory can call `inject` to access the `Injector` and request injection of dependencies.
11600 *
11601 * @codeGenApi
11602 */
11603export declare function ɵɵdefineInjectable<T>(opts: {
11604 token: unknown;
11605 providedIn?: Type<any> | 'root' | 'any' | null;
11606 factory: () => T;
11607}): never;
11608
11609/**
11610 * Construct an `InjectorDef` which configures an injector.
11611 *
11612 * This should be assigned to a static `ngInjectorDef` field on a type, which will then be an
11613 * `InjectorType`.
11614 *
11615 * Options:
11616 *
11617 * * `factory`: an `InjectorType` is an instantiable type, so a zero argument `factory` function to
11618 * create the type must be provided. If that factory function needs to inject arguments, it can
11619 * use the `inject` function.
11620 * * `providers`: an optional array of providers to add to the injector. Each provider must
11621 * either have a factory or point to a type which has an `ngInjectableDef` static property (the
11622 * type must be an `InjectableType`).
11623 * * `imports`: an optional array of imports of other `InjectorType`s or `InjectorTypeWithModule`s
11624 * whose providers will also be added to the injector. Locally provided types will override
11625 * providers from imports.
11626 *
11627 * @publicApi
11628 */
11629export declare function ɵɵdefineInjector(options: {
11630 factory: () => any;
11631 providers?: any[];
11632 imports?: any[];
11633}): never;
11634
11635/**
11636 * @codeGenApi
11637 */
11638export declare function ɵɵdefineNgModule<T>(def: {
11639 /** Token representing the module. Used by DI. */
11640 type: T;
11641 /** List of components to bootstrap. */
11642 bootstrap?: Type<any>[] | (() => Type<any>[]);
11643 /** List of components, directives, and pipes declared by this module. */
11644 declarations?: Type<any>[] | (() => Type<any>[]);
11645 /** List of modules or `ModuleWithProviders` imported by this module. */
11646 imports?: Type<any>[] | (() => Type<any>[]);
11647 /**
11648 * List of modules, `ModuleWithProviders`, components, directives, or pipes exported by this
11649 * module.
11650 */
11651 exports?: Type<any>[] | (() => Type<any>[]);
11652 /** The set of schemas that declare elements to be allowed in the NgModule. */
11653 schemas?: SchemaMetadata[] | null;
11654 /** Unique ID for the module that is used with `getModuleFactory`. */
11655 id?: string | null;
11656}): never;
11657
11658/**
11659 * Create a pipe definition object.
11660 *
11661 * # Example
11662 * ```
11663 * class MyPipe implements PipeTransform {
11664 * // Generated by Angular Template Compiler
11665 * static ngPipeDef = definePipe({
11666 * ...
11667 * });
11668 * }
11669 * ```
11670 * @param pipeDef Pipe definition generated by the compiler
11671 *
11672 * @codeGenApi
11673 */
11674export declare function ɵɵdefinePipe<T>(pipeDef: {
11675 /** Name of the pipe. Used for matching pipes in template to pipe defs. */
11676 name: string;
11677 /** Pipe class reference. Needed to extract pipe lifecycle hooks. */
11678 type: Type<T>;
11679 /** A factory for creating a pipe instance. */
11680 factory: FactoryFn<T>;
11681 /** Whether the pipe is pure. */
11682 pure?: boolean;
11683}): never;
11684
11685/**
11686 * @codeGenApi
11687 */
11688export declare type ɵɵDirectiveDefWithMeta<T, Selector extends string, ExportAs extends string[], InputMap extends {
11689 [key: string]: string;
11690}, OutputMap extends {
11691 [key: string]: string;
11692}, QueryFields extends string[]> = ɵDirectiveDef<T>;
11693
11694/**
11695 * Returns the value associated to the given token from the injectors.
11696 *
11697 * `directiveInject` is intended to be used for directive, component and pipe factories.
11698 * All other injection use `inject` which does not walk the node injector tree.
11699 *
11700 * Usage example (in factory function):
11701 *
11702 * ```ts
11703 * class SomeDirective {
11704 * constructor(directive: DirectiveA) {}
11705 *
11706 * static ngDirectiveDef = ɵɵdefineDirective({
11707 * type: SomeDirective,
11708 * factory: () => new SomeDirective(ɵɵdirectiveInject(DirectiveA))
11709 * });
11710 * }
11711 * ```
11712 * @param token the type or token to inject
11713 * @param flags Injection flags
11714 * @returns the value from the injector or `null` when not found
11715 *
11716 * @codeGenApi
11717 */
11718export declare function ɵɵdirectiveInject<T>(token: Type<T> | InjectionToken<T>): T;
11719
11720export declare function ɵɵdirectiveInject<T>(token: Type<T> | InjectionToken<T>, flags: InjectFlags): T;
11721
11722/**
11723 * Disables directive matching on element.
11724 *
11725 * * Example:
11726 * ```
11727 * <my-comp my-directive>
11728 * Should match component / directive.
11729 * </my-comp>
11730 * <div ngNonBindable>
11731 * <!-- ɵɵdisableBindings() -->
11732 * <my-comp my-directive>
11733 * Should not match component / directive because we are in ngNonBindable.
11734 * </my-comp>
11735 * <!-- ɵɵenableBindings() -->
11736 * </div>
11737 * ```
11738 *
11739 * @codeGenApi
11740 */
11741export declare function ɵɵdisableBindings(): void;
11742
11743/**
11744 * Creates an empty element using {@link elementStart} and {@link elementEnd}
11745 *
11746 * @param index Index of the element in the data array
11747 * @param name Name of the DOM Node
11748 * @param attrs Statically bound set of attributes, classes, and styles to be written into the DOM
11749 * element on creation. Use [AttributeMarker] to denote the meaning of this array.
11750 * @param localRefs A set of local reference bindings on the element.
11751 *
11752 * @codeGenApi
11753 */
11754export declare function ɵɵelement(index: number, name: string, attrs?: TAttributes | null, localRefs?: string[] | null): void;
11755
11756/**
11757 * Creates an empty logical container using {@link elementContainerStart}
11758 * and {@link elementContainerEnd}
11759 *
11760 * @param index Index of the element in the LView array
11761 * @param attrs Set of attributes to be used when matching directives.
11762 * @param localRefs A set of local reference bindings on the element.
11763 *
11764 * @codeGenApi
11765 */
11766export declare function ɵɵelementContainer(index: number, attrs?: TAttributes | null, localRefs?: string[] | null): void;
11767
11768/**
11769 * Mark the end of the <ng-container>.
11770 *
11771 * @codeGenApi
11772 */
11773export declare function ɵɵelementContainerEnd(): void;
11774
11775/**
11776 * Creates a logical container for other nodes (<ng-container>) backed by a comment node in the DOM.
11777 * The instruction must later be followed by `elementContainerEnd()` call.
11778 *
11779 * @param index Index of the element in the LView array
11780 * @param attrs Set of attributes to be used when matching directives.
11781 * @param localRefs A set of local reference bindings on the element.
11782 *
11783 * Even if this instruction accepts a set of attributes no actual attribute values are propagated to
11784 * the DOM (as a comment node can't have attributes). Attributes are here only for directive
11785 * matching purposes and setting initial inputs of directives.
11786 *
11787 * @codeGenApi
11788 */
11789export declare function ɵɵelementContainerStart(index: number, attrs?: TAttributes | null, localRefs?: string[] | null): void;
11790
11791/**
11792 * Mark the end of the element.
11793 *
11794 * @codeGenApi
11795 */
11796export declare function ɵɵelementEnd(): void;
11797
11798/**
11799 * Assign static attribute values to a host element.
11800 *
11801 * This instruction will assign static attribute values as well as class and style
11802 * values to an element within the host bindings function. Since attribute values
11803 * can consist of different types of values, the `attrs` array must include the values in
11804 * the following format:
11805 *
11806 * attrs = [
11807 * // static attributes (like `title`, `name`, `id`...)
11808 * attr1, value1, attr2, value,
11809 *
11810 * // a single namespace value (like `x:id`)
11811 * NAMESPACE_MARKER, namespaceUri1, name1, value1,
11812 *
11813 * // another single namespace value (like `x:name`)
11814 * NAMESPACE_MARKER, namespaceUri2, name2, value2,
11815 *
11816 * // a series of CSS classes that will be applied to the element (no spaces)
11817 * CLASSES_MARKER, class1, class2, class3,
11818 *
11819 * // a series of CSS styles (property + value) that will be applied to the element
11820 * STYLES_MARKER, prop1, value1, prop2, value2
11821 * ]
11822 *
11823 * All non-class and non-style attributes must be defined at the start of the list
11824 * first before all class and style values are set. When there is a change in value
11825 * type (like when classes and styles are introduced) a marker must be used to separate
11826 * the entries. The marker values themselves are set via entries found in the
11827 * [AttributeMarker] enum.
11828 *
11829 * NOTE: This instruction is meant to used from `hostBindings` function only.
11830 *
11831 * @param directive A directive instance the styling is associated with.
11832 * @param attrs An array of static values (attributes, classes and styles) with the correct marker
11833 * values.
11834 *
11835 * @codeGenApi
11836 */
11837export declare function ɵɵelementHostAttrs(attrs: TAttributes): void;
11838
11839/**
11840 * Create DOM element. The instruction must later be followed by `elementEnd()` call.
11841 *
11842 * @param index Index of the element in the LView array
11843 * @param name Name of the DOM Node
11844 * @param attrs Statically bound set of attributes, classes, and styles to be written into the DOM
11845 * element on creation. Use [AttributeMarker] to denote the meaning of this array.
11846 * @param localRefs A set of local reference bindings on the element.
11847 *
11848 * Attributes and localRefs are passed as an array of strings where elements with an even index
11849 * hold an attribute name and elements with an odd index hold an attribute value, ex.:
11850 * ['id', 'warning5', 'class', 'alert']
11851 *
11852 * @codeGenApi
11853 */
11854export declare function ɵɵelementStart(index: number, name: string, attrs?: TAttributes | null, localRefs?: string[] | null): void;
11855
11856/**
11857 * Marks the end of an embedded view.
11858 *
11859 * @codeGenApi
11860 */
11861export declare function ɵɵembeddedViewEnd(): void;
11862
11863/**
11864 * Marks the start of an embedded view.
11865 *
11866 * @param viewBlockId The ID of this view
11867 * @return boolean Whether or not this view is in creation mode
11868 *
11869 * @codeGenApi
11870 */
11871export declare function ɵɵembeddedViewStart(viewBlockId: number, consts: number, vars: number): ɵRenderFlags;
11872
11873/**
11874 * Enables directive matching on elements.
11875 *
11876 * * Example:
11877 * ```
11878 * <my-comp my-directive>
11879 * Should match component / directive.
11880 * </my-comp>
11881 * <div ngNonBindable>
11882 * <!-- ɵɵdisableBindings() -->
11883 * <my-comp my-directive>
11884 * Should not match component / directive because we are in ngNonBindable.
11885 * </my-comp>
11886 * <!-- ɵɵenableBindings() -->
11887 * </div>
11888 * ```
11889 *
11890 * @codeGenApi
11891 */
11892export declare function ɵɵenableBindings(): void;
11893
11894/**
11895 * Returns the current OpaqueViewState instance.
11896 *
11897 * Used in conjunction with the restoreView() instruction to save a snapshot
11898 * of the current view and restore it when listeners are invoked. This allows
11899 * walking the declaration view tree in listeners to get vars from parent views.
11900 *
11901 * @codeGenApi
11902 */
11903export declare function ɵɵgetCurrentView(): OpaqueViewState;
11904
11905/**
11906 * @codeGenApi
11907 */
11908export declare function ɵɵgetFactoryOf<T>(type: Type<any>): FactoryFn<T> | null;
11909
11910/**
11911 * @codeGenApi
11912 */
11913export declare function ɵɵgetInheritedFactory<T>(type: Type<any>): (type: Type<T>) => T;
11914
11915/**
11916 * Update a property on a host element. Only applies to native node properties, not inputs.
11917 *
11918 * Operates on the element selected by index via the {@link select} instruction.
11919 *
11920 * @param propName Name of property. Because it is going to DOM, this is not subject to
11921 * renaming as part of minification.
11922 * @param value New value to write.
11923 * @param sanitizer An optional function used to sanitize the value.
11924 * @returns This function returns itself so that it may be chained
11925 * (e.g. `property('name', ctx.name)('title', ctx.title)`)
11926 *
11927 * @codeGenApi
11928 */
11929export declare function ɵɵhostProperty<T>(propName: string, value: T, sanitizer?: SanitizerFn | null): TsickleIssue1009;
11930
11931/**
11932 *
11933 * Use this instruction to create a translation block that doesn't contain any placeholder.
11934 * It calls both {@link i18nStart} and {@link i18nEnd} in one instruction.
11935 *
11936 * The translation `message` is the value which is locale specific. The translation string may
11937 * contain placeholders which associate inner elements and sub-templates within the translation.
11938 *
11939 * The translation `message` placeholders are:
11940 * - `�{index}(:{block})�`: *Binding Placeholder*: Marks a location where an expression will be
11941 * interpolated into. The placeholder `index` points to the expression binding index. An optional
11942 * `block` that matches the sub-template in which it was declared.
11943 * - `�#{index}(:{block})�`/`�/#{index}(:{block})�`: *Element Placeholder*: Marks the beginning
11944 * and end of DOM element that were embedded in the original translation block. The placeholder
11945 * `index` points to the element index in the template instructions set. An optional `block` that
11946 * matches the sub-template in which it was declared.
11947 * - `�*{index}:{block}�`/`�/*{index}:{block}�`: *Sub-template Placeholder*: Sub-templates must be
11948 * split up and translated separately in each angular template function. The `index` points to the
11949 * `template` instruction index. A `block` that matches the sub-template in which it was declared.
11950 *
11951 * @param index A unique index of the translation in the static block.
11952 * @param message The translation message.
11953 * @param subTemplateIndex Optional sub-template index in the `message`.
11954 *
11955 * @codeGenApi
11956 */
11957export declare function ɵɵi18n(index: number, message: string, subTemplateIndex?: number): void;
11958
11959/**
11960 * Updates a translation block or an i18n attribute when the bindings have changed.
11961 *
11962 * @param index Index of either {@link i18nStart} (translation block) or {@link i18nAttributes}
11963 * (i18n attribute) on which it should update the content.
11964 *
11965 * @codeGenApi
11966 */
11967export declare function ɵɵi18nApply(index: number): void;
11968
11969/**
11970 * Marks a list of attributes as translatable.
11971 *
11972 * @param index A unique index in the static block
11973 * @param values
11974 *
11975 * @codeGenApi
11976 */
11977export declare function ɵɵi18nAttributes(index: number, values: string[]): void;
11978
11979/**
11980 * Translates a translation block marked by `i18nStart` and `i18nEnd`. It inserts the text/ICU nodes
11981 * into the render tree, moves the placeholder nodes and removes the deleted nodes.
11982 *
11983 * @codeGenApi
11984 */
11985export declare function ɵɵi18nEnd(): void;
11986
11987/**
11988 * Stores the values of the bindings during each update cycle in order to determine if we need to
11989 * update the translated nodes.
11990 *
11991 * @param value The binding's value
11992 * @returns This function returns itself so that it may be chained
11993 * (e.g. `i18nExp(ctx.name)(ctx.title)`)
11994 *
11995 * @codeGenApi
11996 */
11997export declare function ɵɵi18nExp<T>(value: T): TsickleIssue1009;
11998
11999/**
12000 * A goog.getMsg-like function for users that do not use Closure.
12001 *
12002 * This method is required as a *temporary* measure to prevent i18n tests from being blocked while
12003 * running outside of Closure Compiler. This method will not be needed once runtime translation
12004 * service support is introduced.
12005 *
12006 * @codeGenApi
12007 * @deprecated this method is temporary & should not be used as it will be removed soon
12008 */
12009export declare function ɵɵi18nLocalize(input: string, placeholders?: {
12010 [key: string]: string;
12011}): string;
12012
12013/**
12014 * Handles message string post-processing for internationalization.
12015 *
12016 * Handles message string post-processing by transforming it from intermediate
12017 * format (that might contain some markers that we need to replace) to the final
12018 * form, consumable by i18nStart instruction. Post processing steps include:
12019 *
12020 * 1. Resolve all multi-value cases (like [�*1:1��#2:1�|�#4:1�|�5�])
12021 * 2. Replace all ICU vars (like "VAR_PLURAL")
12022 * 3. Replace all placeholders used inside ICUs in a form of {PLACEHOLDER}
12023 * 4. Replace all ICU references with corresponding values (like �ICU_EXP_ICU_1�)
12024 * in case multiple ICUs have the same placeholder name
12025 *
12026 * @param message Raw translation string for post processing
12027 * @param replacements Set of replacements that should be applied
12028 *
12029 * @returns Transformed string that can be consumed by i18nStart instruction
12030 *
12031 * @codeGenApi
12032 */
12033export declare function ɵɵi18nPostprocess(message: string, replacements?: {
12034 [key: string]: (string | string[]);
12035}): string;
12036
12037/**
12038 * Marks a block of text as translatable.
12039 *
12040 * The instructions `i18nStart` and `i18nEnd` mark the translation block in the template.
12041 * The translation `message` is the value which is locale specific. The translation string may
12042 * contain placeholders which associate inner elements and sub-templates within the translation.
12043 *
12044 * The translation `message` placeholders are:
12045 * - `�{index}(:{block})�`: *Binding Placeholder*: Marks a location where an expression will be
12046 * interpolated into. The placeholder `index` points to the expression binding index. An optional
12047 * `block` that matches the sub-template in which it was declared.
12048 * - `�#{index}(:{block})�`/`�/#{index}(:{block})�`: *Element Placeholder*: Marks the beginning
12049 * and end of DOM element that were embedded in the original translation block. The placeholder
12050 * `index` points to the element index in the template instructions set. An optional `block` that
12051 * matches the sub-template in which it was declared.
12052 * - `�!{index}(:{block})�`/`�/!{index}(:{block})�`: *Projection Placeholder*: Marks the
12053 * beginning and end of <ng-content> that was embedded in the original translation block.
12054 * The placeholder `index` points to the element index in the template instructions set.
12055 * An optional `block` that matches the sub-template in which it was declared.
12056 * - `�*{index}:{block}�`/`�/*{index}:{block}�`: *Sub-template Placeholder*: Sub-templates must be
12057 * split up and translated separately in each angular template function. The `index` points to the
12058 * `template` instruction index. A `block` that matches the sub-template in which it was declared.
12059 *
12060 * @param index A unique index of the translation in the static block.
12061 * @param message The translation message.
12062 * @param subTemplateIndex Optional sub-template index in the `message`.
12063 *
12064 * @codeGenApi
12065 */
12066export declare function ɵɵi18nStart(index: number, message: string, subTemplateIndex?: number): void;
12067
12068/**
12069 * Merges the definition from a super class to a sub class.
12070 * @param definition The definition that is a SubClass of another directive of component
12071 *
12072 * @codeGenApi
12073 */
12074export declare function ɵɵInheritDefinitionFeature(definition: ɵDirectiveDef<any> | ɵComponentDef<any>): void;
12075
12076/**
12077 * Generated instruction: Injects a token from the currently active injector.
12078 *
12079 * Must be used in the context of a factory function such as one defined for an
12080 * `InjectionToken`. Throws an error if not called from such a context.
12081 *
12082 * (Additional documentation moved to `inject`, as it is the public API, and an alias for this instruction)
12083 *
12084 * @see inject
12085 * @codeGenApi
12086 */
12087export declare function ɵɵinject<T>(token: Type<T> | InjectionToken<T>): T;
12088
12089export declare function ɵɵinject<T>(token: Type<T> | InjectionToken<T>, flags?: InjectFlags): T | null;
12090
12091/**
12092 * Information about how a type or `InjectionToken` interfaces with the DI system.
12093 *
12094 * At a minimum, this includes a `factory` which defines how to create the given type `T`, possibly
12095 * requesting injection of other types if necessary.
12096 *
12097 * Optionally, a `providedIn` parameter specifies that the given type belongs to a particular
12098 * `InjectorDef`, `NgModule`, or a special scope (e.g. `'root'`). A value of `null` indicates
12099 * that the injectable does not belong to any scope.
12100 *
12101 * NOTE: This is a private type and should not be exported
12102 *
12103 * @publicApi
12104 */
12105export declare interface ɵɵInjectableDef<T> {
12106 /**
12107 * Specifies that the given type belongs to a particular injector:
12108 * - `InjectorType` such as `NgModule`,
12109 * - `'root'` the root injector
12110 * - `'any'` all injectors.
12111 * - `null`, does not belong to any injector. Must be explicitly listed in the injector
12112 * `providers`.
12113 */
12114 providedIn: InjectorType<any> | 'root' | 'any' | null;
12115 /**
12116 * The token to which this definition belongs.
12117 *
12118 * Note that this may not be the same as the type that the `factory` will create.
12119 */
12120 token: unknown;
12121 /**
12122 * Factory method to execute to create an instance of the injectable.
12123 */
12124 factory: (t?: Type<any>) => T;
12125 /**
12126 * In a case of no explicit injector, a location where the instance of the injectable is stored.
12127 */
12128 value: T | undefined;
12129}
12130
12131/**
12132 * Facade for the attribute injection from DI.
12133 *
12134 * @codeGenApi
12135 */
12136export declare function ɵɵinjectAttribute(attrNameToInject: string): string | null;
12137
12138/**
12139 * Information about the providers to be included in an `Injector` as well as how the given type
12140 * which carries the information should be created by the DI system.
12141 *
12142 * An `InjectorDef` can import other types which have `InjectorDefs`, forming a deep nested
12143 * structure of providers with a defined priority (identically to how `NgModule`s also have
12144 * an import/dependency structure).
12145 *
12146 * NOTE: This is a private type and should not be exported
12147 *
12148 * @publicApi
12149 */
12150export declare interface ɵɵInjectorDef<T> {
12151 factory: () => T;
12152 providers: (Type<any> | ValueProvider | ExistingProvider | FactoryProvider | ConstructorProvider | StaticClassProvider | ClassProvider | any[])[];
12153 imports: (InjectorType<any> | InjectorTypeWithProviders<any>)[];
12154}
12155
12156/**
12157 * Returns the appropriate `ChangeDetectorRef` for a pipe.
12158 *
12159 * @codeGenApi
12160 */
12161export declare function ɵɵinjectPipeChangeDetectorRef(flags?: InjectFlags): ChangeDetectorRef | null;
12162
12163/**
12164 * Adds an event listener to the current node.
12165 *
12166 * If an output exists on one of the node's directives, it also subscribes to the output
12167 * and saves the subscription for later cleanup.
12168 *
12169 * @param eventName Name of the event
12170 * @param listenerFn The function to be called when event emits
12171 * @param useCapture Whether or not to use capture in event listener
12172 * @param eventTargetResolver Function that returns global target information in case this listener
12173 * should be attached to a global object like window, document or body
12174 *
12175 * @codeGenApi
12176 */
12177export declare function ɵɵlistener(eventName: string, listenerFn: (e?: any) => any, useCapture?: boolean, eventTargetResolver?: GlobalTargetResolver): void;
12178
12179/**
12180 * Retrieves a value from current `viewData`.
12181 *
12182 * @codeGenApi
12183 */
12184export declare function ɵɵload<T>(index: number): T;
12185
12186/**
12187 * Loads a QueryList corresponding to the current content query.
12188 *
12189 * @codeGenApi
12190 */
12191export declare function ɵɵloadContentQuery<T>(): QueryList<T>;
12192
12193/**
12194 * Loads a QueryList corresponding to the current view query.
12195 *
12196 * @codeGenApi
12197 */
12198export declare function ɵɵloadViewQuery<T>(): QueryList<T>;
12199
12200/**
12201 * Sets the namespace used to create elements to `null`, which forces element creation to use
12202 * `createElement` rather than `createElementNS`.
12203 *
12204 * @codeGenApi
12205 */
12206export declare function ɵɵnamespaceHTML(): void;
12207
12208/**
12209 * Sets the namespace used to create elements to `'http://www.w3.org/1998/MathML/'` in global state.
12210 *
12211 * @codeGenApi
12212 */
12213export declare function ɵɵnamespaceMathML(): void;
12214
12215/**
12216 * Sets the namespace used to create elements to `'http://www.w3.org/2000/svg'` in global state.
12217 *
12218 * @codeGenApi
12219 */
12220export declare function ɵɵnamespaceSVG(): void;
12221
12222/**
12223 * Retrieves a context at the level specified and saves it as the global, contextViewData.
12224 * Will get the next level up if level is not specified.
12225 *
12226 * This is used to save contexts of parent views so they can be bound in embedded views, or
12227 * in conjunction with reference() to bind a ref from a parent view.
12228 *
12229 * @param level The relative level of the view from which to grab context compared to contextVewData
12230 * @returns context
12231 *
12232 * @codeGenApi
12233 */
12234export declare function ɵɵnextContext<T = any>(level?: number): T;
12235
12236/**
12237 * @publicApi
12238 */
12239export declare type ɵɵNgModuleDefWithMeta<T, Declarations, Imports, Exports> = ɵNgModuleDef<T>;
12240
12241/**
12242 * The NgOnChangesFeature decorates a component with support for the ngOnChanges
12243 * lifecycle hook, so it should be included in any component that implements
12244 * that hook.
12245 *
12246 * If the component or directive uses inheritance, the NgOnChangesFeature MUST
12247 * be included as a feature AFTER {@link InheritDefinitionFeature}, otherwise
12248 * inherited properties will not be propagated to the ngOnChanges lifecycle
12249 * hook.
12250 *
12251 * Example usage:
12252 *
12253 * ```
12254 * static ngComponentDef = defineComponent({
12255 * ...
12256 * inputs: {name: 'publicName'},
12257 * features: [NgOnChangesFeature()]
12258 * });
12259 * ```
12260 *
12261 * @codeGenApi
12262 */
12263export declare function ɵɵNgOnChangesFeature<T>(): DirectiveDefFeature;
12264
12265
12266/**
12267 * Create a pipe.
12268 *
12269 * @param index Pipe index where the pipe will be stored.
12270 * @param pipeName The name of the pipe
12271 * @returns T the instance of the pipe.
12272 *
12273 * @codeGenApi
12274 */
12275export declare function ɵɵpipe(index: number, pipeName: string): any;
12276
12277/**
12278 * Invokes a pipe with 1 arguments.
12279 *
12280 * This instruction acts as a guard to {@link PipeTransform#transform} invoking
12281 * the pipe only when an input to the pipe changes.
12282 *
12283 * @param index Pipe index where the pipe was stored on creation.
12284 * @param slotOffset the offset in the reserved slot space
12285 * @param v1 1st argument to {@link PipeTransform#transform}.
12286 *
12287 * @codeGenApi
12288 */
12289export declare function ɵɵpipeBind1(index: number, slotOffset: number, v1: any): any;
12290
12291/**
12292 * Invokes a pipe with 2 arguments.
12293 *
12294 * This instruction acts as a guard to {@link PipeTransform#transform} invoking
12295 * the pipe only when an input to the pipe changes.
12296 *
12297 * @param index Pipe index where the pipe was stored on creation.
12298 * @param slotOffset the offset in the reserved slot space
12299 * @param v1 1st argument to {@link PipeTransform#transform}.
12300 * @param v2 2nd argument to {@link PipeTransform#transform}.
12301 *
12302 * @codeGenApi
12303 */
12304export declare function ɵɵpipeBind2(index: number, slotOffset: number, v1: any, v2: any): any;
12305
12306/**
12307 * Invokes a pipe with 3 arguments.
12308 *
12309 * This instruction acts as a guard to {@link PipeTransform#transform} invoking
12310 * the pipe only when an input to the pipe changes.
12311 *
12312 * @param index Pipe index where the pipe was stored on creation.
12313 * @param slotOffset the offset in the reserved slot space
12314 * @param v1 1st argument to {@link PipeTransform#transform}.
12315 * @param v2 2nd argument to {@link PipeTransform#transform}.
12316 * @param v3 4rd argument to {@link PipeTransform#transform}.
12317 *
12318 * @codeGenApi
12319 */
12320export declare function ɵɵpipeBind3(index: number, slotOffset: number, v1: any, v2: any, v3: any): any;
12321
12322/**
12323 * Invokes a pipe with 4 arguments.
12324 *
12325 * This instruction acts as a guard to {@link PipeTransform#transform} invoking
12326 * the pipe only when an input to the pipe changes.
12327 *
12328 * @param index Pipe index where the pipe was stored on creation.
12329 * @param slotOffset the offset in the reserved slot space
12330 * @param v1 1st argument to {@link PipeTransform#transform}.
12331 * @param v2 2nd argument to {@link PipeTransform#transform}.
12332 * @param v3 3rd argument to {@link PipeTransform#transform}.
12333 * @param v4 4th argument to {@link PipeTransform#transform}.
12334 *
12335 * @codeGenApi
12336 */
12337export declare function ɵɵpipeBind4(index: number, slotOffset: number, v1: any, v2: any, v3: any, v4: any): any;
12338
12339/**
12340 * Invokes a pipe with variable number of arguments.
12341 *
12342 * This instruction acts as a guard to {@link PipeTransform#transform} invoking
12343 * the pipe only when an input to the pipe changes.
12344 *
12345 * @param index Pipe index where the pipe was stored on creation.
12346 * @param slotOffset the offset in the reserved slot space
12347 * @param values Array of arguments to pass to {@link PipeTransform#transform} method.
12348 *
12349 * @codeGenApi
12350 */
12351export declare function ɵɵpipeBindV(index: number, slotOffset: number, values: [any, ...any[]]): any;
12352
12353/**
12354 * @codeGenApi
12355 */
12356export declare type ɵɵPipeDefWithMeta<T, Name extends string> = ɵPipeDef<T>;
12357
12358/**
12359 * Inserts previously re-distributed projected nodes. This instruction must be preceded by a call
12360 * to the projectionDef instruction.
12361 *
12362 * @param nodeIndex
12363 * @param selectorIndex:
12364 * - 0 when the selector is `*` (or unspecified as this is the default value),
12365 * - 1 based index of the selector from the {@link projectionDef}
12366 *
12367 * @codeGenApi
12368*/
12369export declare function ɵɵprojection(nodeIndex: number, selectorIndex?: number, attrs?: TAttributes): void;
12370
12371/**
12372 * Instruction to distribute projectable nodes among <ng-content> occurrences in a given template.
12373 * It takes all the selectors from the entire component's template and decides where
12374 * each projected node belongs (it re-distributes nodes among "buckets" where each "bucket" is
12375 * backed by a selector).
12376 *
12377 * This function requires CSS selectors to be provided in 2 forms: parsed (by a compiler) and text,
12378 * un-parsed form.
12379 *
12380 * The parsed form is needed for efficient matching of a node against a given CSS selector.
12381 * The un-parsed, textual form is needed for support of the ngProjectAs attribute.
12382 *
12383 * Having a CSS selector in 2 different formats is not ideal, but alternatives have even more
12384 * drawbacks:
12385 * - having only a textual form would require runtime parsing of CSS selectors;
12386 * - we can't have only a parsed as we can't re-construct textual form from it (as entered by a
12387 * template author).
12388 *
12389 * @param projectionSlots? A collection of projection slots. A projection slot can be based
12390 * on a parsed CSS selectors or set to the wildcard selector ("*") in order to match
12391 * all nodes which do not match any selector. If not specified, a single wildcard
12392 * selector projection slot will be defined.
12393 *
12394 * @codeGenApi
12395 */
12396export declare function ɵɵprojectionDef(projectionSlots?: ProjectionSlots): void;
12397
12398/**
12399 * Update a property on a selected element.
12400 *
12401 * Operates on the element selected by index via the {@link select} instruction.
12402 *
12403 * If the property name also exists as an input property on one of the element's directives,
12404 * the component property will be set instead of the element property. This check must
12405 * be conducted at runtime so child components that add new `@Inputs` don't have to be re-compiled
12406 *
12407 * @param propName Name of property. Because it is going to DOM, this is not subject to
12408 * renaming as part of minification.
12409 * @param value New value to write.
12410 * @param sanitizer An optional function used to sanitize the value.
12411 * @returns This function returns itself so that it may be chained
12412 * (e.g. `property('name', ctx.name)('title', ctx.title)`)
12413 *
12414 * @codeGenApi
12415 */
12416export declare function ɵɵproperty<T>(propName: string, value: T, sanitizer?: SanitizerFn | null): TsickleIssue1009;
12417
12418/**
12419 *
12420 * Update an interpolated property on an element with a lone bound value
12421 *
12422 * Used when the value passed to a property has 1 interpolated value in it, an no additional text
12423 * surrounds that interpolated value:
12424 *
12425 * ```html
12426 * <div title="{{v0}}"></div>
12427 * ```
12428 *
12429 * Its compiled representation is::
12430 *
12431 * ```ts
12432 * ɵɵpropertyInterpolate('title', v0);
12433 * ```
12434 *
12435 * If the property name also exists as an input property on one of the element's directives,
12436 * the component property will be set instead of the element property. This check must
12437 * be conducted at runtime so child components that add new `@Inputs` don't have to be re-compiled.
12438 *
12439 * @param propName The name of the property to update
12440 * @param prefix Static value used for concatenation only.
12441 * @param v0 Value checked for change.
12442 * @param suffix Static value used for concatenation only.
12443 * @param sanitizer An optional sanitizer function
12444 * @returns itself, so that it may be chained.
12445 * @codeGenApi
12446 */
12447export declare function ɵɵpropertyInterpolate(propName: string, v0: any, sanitizer?: SanitizerFn): TsickleIssue1009;
12448
12449/**
12450 *
12451 * Update an interpolated property on an element with single bound value surrounded by text.
12452 *
12453 * Used when the value passed to a property has 1 interpolated value in it:
12454 *
12455 * ```html
12456 * <div title="prefix{{v0}}suffix"></div>
12457 * ```
12458 *
12459 * Its compiled representation is::
12460 *
12461 * ```ts
12462 * ɵɵpropertyInterpolate1('title', 'prefix', v0, 'suffix');
12463 * ```
12464 *
12465 * If the property name also exists as an input property on one of the element's directives,
12466 * the component property will be set instead of the element property. This check must
12467 * be conducted at runtime so child components that add new `@Inputs` don't have to be re-compiled.
12468 *
12469 * @param propName The name of the property to update
12470 * @param prefix Static value used for concatenation only.
12471 * @param v0 Value checked for change.
12472 * @param suffix Static value used for concatenation only.
12473 * @param sanitizer An optional sanitizer function
12474 * @returns itself, so that it may be chained.
12475 * @codeGenApi
12476 */
12477export declare function ɵɵpropertyInterpolate1(propName: string, prefix: string, v0: any, suffix: string, sanitizer?: SanitizerFn): TsickleIssue1009;
12478
12479/**
12480 *
12481 * Update an interpolated property on an element with 2 bound values surrounded by text.
12482 *
12483 * Used when the value passed to a property has 2 interpolated values in it:
12484 *
12485 * ```html
12486 * <div title="prefix{{v0}}-{{v1}}suffix"></div>
12487 * ```
12488 *
12489 * Its compiled representation is::
12490 *
12491 * ```ts
12492 * ɵɵpropertyInterpolate2('title', 'prefix', v0, '-', v1, 'suffix');
12493 * ```
12494 *
12495 * If the property name also exists as an input property on one of the element's directives,
12496 * the component property will be set instead of the element property. This check must
12497 * be conducted at runtime so child components that add new `@Inputs` don't have to be re-compiled.
12498 *
12499 * @param propName The name of the property to update
12500 * @param prefix Static value used for concatenation only.
12501 * @param v0 Value checked for change.
12502 * @param i0 Static value used for concatenation only.
12503 * @param v1 Value checked for change.
12504 * @param suffix Static value used for concatenation only.
12505 * @param sanitizer An optional sanitizer function
12506 * @returns itself, so that it may be chained.
12507 * @codeGenApi
12508 */
12509export declare function ɵɵpropertyInterpolate2(propName: string, prefix: string, v0: any, i0: string, v1: any, suffix: string, sanitizer?: SanitizerFn): TsickleIssue1009;
12510
12511/**
12512 *
12513 * Update an interpolated property on an element with 3 bound values surrounded by text.
12514 *
12515 * Used when the value passed to a property has 3 interpolated values in it:
12516 *
12517 * ```html
12518 * <div title="prefix{{v0}}-{{v1}}-{{v2}}suffix"></div>
12519 * ```
12520 *
12521 * Its compiled representation is::
12522 *
12523 * ```ts
12524 * ɵɵpropertyInterpolate3(
12525 * 'title', 'prefix', v0, '-', v1, '-', v2, 'suffix');
12526 * ```
12527 *
12528 * If the property name also exists as an input property on one of the element's directives,
12529 * the component property will be set instead of the element property. This check must
12530 * be conducted at runtime so child components that add new `@Inputs` don't have to be re-compiled.
12531 *
12532 * @param propName The name of the property to update
12533 * @param prefix Static value used for concatenation only.
12534 * @param v0 Value checked for change.
12535 * @param i0 Static value used for concatenation only.
12536 * @param v1 Value checked for change.
12537 * @param i1 Static value used for concatenation only.
12538 * @param v2 Value checked for change.
12539 * @param suffix Static value used for concatenation only.
12540 * @param sanitizer An optional sanitizer function
12541 * @returns itself, so that it may be chained.
12542 * @codeGenApi
12543 */
12544export declare function ɵɵpropertyInterpolate3(propName: string, prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, suffix: string, sanitizer?: SanitizerFn): TsickleIssue1009;
12545
12546/**
12547 *
12548 * Update an interpolated property on an element with 4 bound values surrounded by text.
12549 *
12550 * Used when the value passed to a property has 4 interpolated values in it:
12551 *
12552 * ```html
12553 * <div title="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}suffix"></div>
12554 * ```
12555 *
12556 * Its compiled representation is::
12557 *
12558 * ```ts
12559 * ɵɵpropertyInterpolate4(
12560 * 'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, 'suffix');
12561 * ```
12562 *
12563 * If the property name also exists as an input property on one of the element's directives,
12564 * the component property will be set instead of the element property. This check must
12565 * be conducted at runtime so child components that add new `@Inputs` don't have to be re-compiled.
12566 *
12567 * @param propName The name of the property to update
12568 * @param prefix Static value used for concatenation only.
12569 * @param v0 Value checked for change.
12570 * @param i0 Static value used for concatenation only.
12571 * @param v1 Value checked for change.
12572 * @param i1 Static value used for concatenation only.
12573 * @param v2 Value checked for change.
12574 * @param i2 Static value used for concatenation only.
12575 * @param v3 Value checked for change.
12576 * @param suffix Static value used for concatenation only.
12577 * @param sanitizer An optional sanitizer function
12578 * @returns itself, so that it may be chained.
12579 * @codeGenApi
12580 */
12581export declare function ɵɵpropertyInterpolate4(propName: string, prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string, v3: any, suffix: string, sanitizer?: SanitizerFn): TsickleIssue1009;
12582
12583/**
12584 *
12585 * Update an interpolated property on an element with 5 bound values surrounded by text.
12586 *
12587 * Used when the value passed to a property has 5 interpolated values in it:
12588 *
12589 * ```html
12590 * <div title="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}suffix"></div>
12591 * ```
12592 *
12593 * Its compiled representation is::
12594 *
12595 * ```ts
12596 * ɵɵpropertyInterpolate5(
12597 * 'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, 'suffix');
12598 * ```
12599 *
12600 * If the property name also exists as an input property on one of the element's directives,
12601 * the component property will be set instead of the element property. This check must
12602 * be conducted at runtime so child components that add new `@Inputs` don't have to be re-compiled.
12603 *
12604 * @param propName The name of the property to update
12605 * @param prefix Static value used for concatenation only.
12606 * @param v0 Value checked for change.
12607 * @param i0 Static value used for concatenation only.
12608 * @param v1 Value checked for change.
12609 * @param i1 Static value used for concatenation only.
12610 * @param v2 Value checked for change.
12611 * @param i2 Static value used for concatenation only.
12612 * @param v3 Value checked for change.
12613 * @param i3 Static value used for concatenation only.
12614 * @param v4 Value checked for change.
12615 * @param suffix Static value used for concatenation only.
12616 * @param sanitizer An optional sanitizer function
12617 * @returns itself, so that it may be chained.
12618 * @codeGenApi
12619 */
12620export declare function ɵɵpropertyInterpolate5(propName: string, prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string, v3: any, i3: string, v4: any, suffix: string, sanitizer?: SanitizerFn): TsickleIssue1009;
12621
12622/**
12623 *
12624 * Update an interpolated property on an element with 6 bound values surrounded by text.
12625 *
12626 * Used when the value passed to a property has 6 interpolated values in it:
12627 *
12628 * ```html
12629 * <div title="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}suffix"></div>
12630 * ```
12631 *
12632 * Its compiled representation is::
12633 *
12634 * ```ts
12635 * ɵɵpropertyInterpolate6(
12636 * 'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, 'suffix');
12637 * ```
12638 *
12639 * If the property name also exists as an input property on one of the element's directives,
12640 * the component property will be set instead of the element property. This check must
12641 * be conducted at runtime so child components that add new `@Inputs` don't have to be re-compiled.
12642 *
12643 * @param propName The name of the property to update
12644 * @param prefix Static value used for concatenation only.
12645 * @param v0 Value checked for change.
12646 * @param i0 Static value used for concatenation only.
12647 * @param v1 Value checked for change.
12648 * @param i1 Static value used for concatenation only.
12649 * @param v2 Value checked for change.
12650 * @param i2 Static value used for concatenation only.
12651 * @param v3 Value checked for change.
12652 * @param i3 Static value used for concatenation only.
12653 * @param v4 Value checked for change.
12654 * @param i4 Static value used for concatenation only.
12655 * @param v5 Value checked for change.
12656 * @param suffix Static value used for concatenation only.
12657 * @param sanitizer An optional sanitizer function
12658 * @returns itself, so that it may be chained.
12659 * @codeGenApi
12660 */
12661export declare function ɵɵpropertyInterpolate6(propName: string, prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string, v3: any, i3: string, v4: any, i4: string, v5: any, suffix: string, sanitizer?: SanitizerFn): TsickleIssue1009;
12662
12663/**
12664 *
12665 * Update an interpolated property on an element with 7 bound values surrounded by text.
12666 *
12667 * Used when the value passed to a property has 7 interpolated values in it:
12668 *
12669 * ```html
12670 * <div title="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}suffix"></div>
12671 * ```
12672 *
12673 * Its compiled representation is::
12674 *
12675 * ```ts
12676 * ɵɵpropertyInterpolate7(
12677 * 'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, 'suffix');
12678 * ```
12679 *
12680 * If the property name also exists as an input property on one of the element's directives,
12681 * the component property will be set instead of the element property. This check must
12682 * be conducted at runtime so child components that add new `@Inputs` don't have to be re-compiled.
12683 *
12684 * @param propName The name of the property to update
12685 * @param prefix Static value used for concatenation only.
12686 * @param v0 Value checked for change.
12687 * @param i0 Static value used for concatenation only.
12688 * @param v1 Value checked for change.
12689 * @param i1 Static value used for concatenation only.
12690 * @param v2 Value checked for change.
12691 * @param i2 Static value used for concatenation only.
12692 * @param v3 Value checked for change.
12693 * @param i3 Static value used for concatenation only.
12694 * @param v4 Value checked for change.
12695 * @param i4 Static value used for concatenation only.
12696 * @param v5 Value checked for change.
12697 * @param i5 Static value used for concatenation only.
12698 * @param v6 Value checked for change.
12699 * @param suffix Static value used for concatenation only.
12700 * @param sanitizer An optional sanitizer function
12701 * @returns itself, so that it may be chained.
12702 * @codeGenApi
12703 */
12704export declare function ɵɵpropertyInterpolate7(propName: string, prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string, v3: any, i3: string, v4: any, i4: string, v5: any, i5: string, v6: any, suffix: string, sanitizer?: SanitizerFn): TsickleIssue1009;
12705
12706/**
12707 *
12708 * Update an interpolated property on an element with 8 bound values surrounded by text.
12709 *
12710 * Used when the value passed to a property has 8 interpolated values in it:
12711 *
12712 * ```html
12713 * <div title="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}-{{v7}}suffix"></div>
12714 * ```
12715 *
12716 * Its compiled representation is::
12717 *
12718 * ```ts
12719 * ɵɵpropertyInterpolate8(
12720 * 'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, '-', v7, 'suffix');
12721 * ```
12722 *
12723 * If the property name also exists as an input property on one of the element's directives,
12724 * the component property will be set instead of the element property. This check must
12725 * be conducted at runtime so child components that add new `@Inputs` don't have to be re-compiled.
12726 *
12727 * @param propName The name of the property to update
12728 * @param prefix Static value used for concatenation only.
12729 * @param v0 Value checked for change.
12730 * @param i0 Static value used for concatenation only.
12731 * @param v1 Value checked for change.
12732 * @param i1 Static value used for concatenation only.
12733 * @param v2 Value checked for change.
12734 * @param i2 Static value used for concatenation only.
12735 * @param v3 Value checked for change.
12736 * @param i3 Static value used for concatenation only.
12737 * @param v4 Value checked for change.
12738 * @param i4 Static value used for concatenation only.
12739 * @param v5 Value checked for change.
12740 * @param i5 Static value used for concatenation only.
12741 * @param v6 Value checked for change.
12742 * @param i6 Static value used for concatenation only.
12743 * @param v7 Value checked for change.
12744 * @param suffix Static value used for concatenation only.
12745 * @param sanitizer An optional sanitizer function
12746 * @returns itself, so that it may be chained.
12747 * @codeGenApi
12748 */
12749export declare function ɵɵpropertyInterpolate8(propName: string, prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string, v3: any, i3: string, v4: any, i4: string, v5: any, i5: string, v6: any, i6: string, v7: any, suffix: string, sanitizer?: SanitizerFn): TsickleIssue1009;
12750
12751/**
12752 * Update an interpolated property on an element with 8 or more bound values surrounded by text.
12753 *
12754 * Used when the number of interpolated values exceeds 7.
12755 *
12756 * ```html
12757 * <div
12758 * title="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}-{{v7}}-{{v8}}-{{v9}}suffix"></div>
12759 * ```
12760 *
12761 * Its compiled representation is::
12762 *
12763 * ```ts
12764 * ɵɵpropertyInterpolateV(
12765 * 'title', ['prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, '-', v7, '-', v9,
12766 * 'suffix']);
12767 * ```
12768 *
12769 * If the property name also exists as an input property on one of the element's directives,
12770 * the component property will be set instead of the element property. This check must
12771 * be conducted at runtime so child components that add new `@Inputs` don't have to be re-compiled.
12772 *
12773 * @param propName The name of the property to update.
12774 * @param values The a collection of values and the strings inbetween those values, beginning with a
12775 * string prefix and ending with a string suffix.
12776 * (e.g. `['prefix', value0, '-', value1, '-', value2, ..., value99, 'suffix']`)
12777 * @param sanitizer An optional sanitizer function
12778 * @returns itself, so that it may be chained.
12779 * @codeGenApi
12780 */
12781export declare function ɵɵpropertyInterpolateV(propName: string, values: any[], sanitizer?: SanitizerFn): TsickleIssue1009;
12782
12783/**
12784 * This feature resolves the providers of a directive (or component),
12785 * and publish them into the DI system, making it visible to others for injection.
12786 *
12787 * For example:
12788 * ```ts
12789 * class ComponentWithProviders {
12790 * constructor(private greeter: GreeterDE) {}
12791 *
12792 * static ngComponentDef = defineComponent({
12793 * type: ComponentWithProviders,
12794 * selectors: [['component-with-providers']],
12795 * factory: () => new ComponentWithProviders(directiveInject(GreeterDE as any)),
12796 * consts: 1,
12797 * vars: 1,
12798 * template: function(fs: RenderFlags, ctx: ComponentWithProviders) {
12799 * if (fs & RenderFlags.Create) {
12800 * ɵɵtext(0);
12801 * }
12802 * if (fs & RenderFlags.Update) {
12803 * ɵɵselect(0);
12804 * ɵɵtextBinding(ctx.greeter.greet());
12805 * }
12806 * },
12807 * features: [ProvidersFeature([GreeterDE])]
12808 * });
12809 * }
12810 * ```
12811 *
12812 * @param definition
12813 *
12814 * @codeGenApi
12815 */
12816export declare function ɵɵProvidersFeature<T>(providers: Provider[], viewProviders?: Provider[]): (definition: ɵDirectiveDef<T>) => void;
12817
12818
12819/**
12820 * Bindings for pure functions are stored after regular bindings.
12821 *
12822 * |------consts------|---------vars---------| |----- hostVars (dir1) ------|
12823 * ------------------------------------------------------------------------------------------
12824 * | nodes/refs/pipes | bindings | fn slots | injector | dir1 | host bindings | host slots |
12825 * ------------------------------------------------------------------------------------------
12826 * ^ ^
12827 * TView.bindingStartIndex TView.expandoStartIndex
12828 *
12829 * Pure function instructions are given an offset from the binding root. Adding the offset to the
12830 * binding root gives the first index where the bindings are stored. In component views, the binding
12831 * root is the bindingStartIndex. In host bindings, the binding root is the expandoStartIndex +
12832 * any directive instances + any hostVars in directives evaluated before it.
12833 *
12834 * See VIEW_DATA.md for more information about host binding resolution.
12835 */
12836/**
12837 * If the value hasn't been saved, calls the pure function to store and return the
12838 * value. If it has been saved, returns the saved value.
12839 *
12840 * @param slotOffset the offset from binding root to the reserved slot
12841 * @param pureFn Function that returns a value
12842 * @param thisArg Optional calling context of pureFn
12843 * @returns value
12844 *
12845 * @codeGenApi
12846 */
12847export declare function ɵɵpureFunction0<T>(slotOffset: number, pureFn: () => T, thisArg?: any): T;
12848
12849/**
12850 * If the value of the provided exp has changed, calls the pure function to return
12851 * an updated value. Or if the value has not changed, returns cached value.
12852 *
12853 * @param slotOffset the offset from binding root to the reserved slot
12854 * @param pureFn Function that returns an updated value
12855 * @param exp Updated expression value
12856 * @param thisArg Optional calling context of pureFn
12857 * @returns Updated or cached value
12858 *
12859 * @codeGenApi
12860 */
12861export declare function ɵɵpureFunction1(slotOffset: number, pureFn: (v: any) => any, exp: any, thisArg?: any): any;
12862
12863/**
12864 * If the value of any provided exp has changed, calls the pure function to return
12865 * an updated value. Or if no values have changed, returns cached value.
12866 *
12867 * @param slotOffset the offset from binding root to the reserved slot
12868 * @param pureFn
12869 * @param exp1
12870 * @param exp2
12871 * @param thisArg Optional calling context of pureFn
12872 * @returns Updated or cached value
12873 *
12874 * @codeGenApi
12875 */
12876export declare function ɵɵpureFunction2(slotOffset: number, pureFn: (v1: any, v2: any) => any, exp1: any, exp2: any, thisArg?: any): any;
12877
12878/**
12879 * If the value of any provided exp has changed, calls the pure function to return
12880 * an updated value. Or if no values have changed, returns cached value.
12881 *
12882 * @param slotOffset the offset from binding root to the reserved slot
12883 * @param pureFn
12884 * @param exp1
12885 * @param exp2
12886 * @param exp3
12887 * @param thisArg Optional calling context of pureFn
12888 * @returns Updated or cached value
12889 *
12890 * @codeGenApi
12891 */
12892export declare function ɵɵpureFunction3(slotOffset: number, pureFn: (v1: any, v2: any, v3: any) => any, exp1: any, exp2: any, exp3: any, thisArg?: any): any;
12893
12894/**
12895 * If the value of any provided exp has changed, calls the pure function to return
12896 * an updated value. Or if no values have changed, returns cached value.
12897 *
12898 * @param slotOffset the offset from binding root to the reserved slot
12899 * @param pureFn
12900 * @param exp1
12901 * @param exp2
12902 * @param exp3
12903 * @param exp4
12904 * @param thisArg Optional calling context of pureFn
12905 * @returns Updated or cached value
12906 *
12907 * @codeGenApi
12908 */
12909export declare function ɵɵpureFunction4(slotOffset: number, pureFn: (v1: any, v2: any, v3: any, v4: any) => any, exp1: any, exp2: any, exp3: any, exp4: any, thisArg?: any): any;
12910
12911/**
12912 * If the value of any provided exp has changed, calls the pure function to return
12913 * an updated value. Or if no values have changed, returns cached value.
12914 *
12915 * @param slotOffset the offset from binding root to the reserved slot
12916 * @param pureFn
12917 * @param exp1
12918 * @param exp2
12919 * @param exp3
12920 * @param exp4
12921 * @param exp5
12922 * @param thisArg Optional calling context of pureFn
12923 * @returns Updated or cached value
12924 *
12925 * @codeGenApi
12926 */
12927export declare function ɵɵpureFunction5(slotOffset: number, pureFn: (v1: any, v2: any, v3: any, v4: any, v5: any) => any, exp1: any, exp2: any, exp3: any, exp4: any, exp5: any, thisArg?: any): any;
12928
12929/**
12930 * If the value of any provided exp has changed, calls the pure function to return
12931 * an updated value. Or if no values have changed, returns cached value.
12932 *
12933 * @param slotOffset the offset from binding root to the reserved slot
12934 * @param pureFn
12935 * @param exp1
12936 * @param exp2
12937 * @param exp3
12938 * @param exp4
12939 * @param exp5
12940 * @param exp6
12941 * @param thisArg Optional calling context of pureFn
12942 * @returns Updated or cached value
12943 *
12944 * @codeGenApi
12945 */
12946export declare function ɵɵpureFunction6(slotOffset: number, pureFn: (v1: any, v2: any, v3: any, v4: any, v5: any, v6: any) => any, exp1: any, exp2: any, exp3: any, exp4: any, exp5: any, exp6: any, thisArg?: any): any;
12947
12948/**
12949 * If the value of any provided exp has changed, calls the pure function to return
12950 * an updated value. Or if no values have changed, returns cached value.
12951 *
12952 * @param slotOffset the offset from binding root to the reserved slot
12953 * @param pureFn
12954 * @param exp1
12955 * @param exp2
12956 * @param exp3
12957 * @param exp4
12958 * @param exp5
12959 * @param exp6
12960 * @param exp7
12961 * @param thisArg Optional calling context of pureFn
12962 * @returns Updated or cached value
12963 *
12964 * @codeGenApi
12965 */
12966export declare function ɵɵpureFunction7(slotOffset: number, pureFn: (v1: any, v2: any, v3: any, v4: any, v5: any, v6: any, v7: any) => any, exp1: any, exp2: any, exp3: any, exp4: any, exp5: any, exp6: any, exp7: any, thisArg?: any): any;
12967
12968/**
12969 * If the value of any provided exp has changed, calls the pure function to return
12970 * an updated value. Or if no values have changed, returns cached value.
12971 *
12972 * @param slotOffset the offset from binding root to the reserved slot
12973 * @param pureFn
12974 * @param exp1
12975 * @param exp2
12976 * @param exp3
12977 * @param exp4
12978 * @param exp5
12979 * @param exp6
12980 * @param exp7
12981 * @param exp8
12982 * @param thisArg Optional calling context of pureFn
12983 * @returns Updated or cached value
12984 *
12985 * @codeGenApi
12986 */
12987export declare function ɵɵpureFunction8(slotOffset: number, pureFn: (v1: any, v2: any, v3: any, v4: any, v5: any, v6: any, v7: any, v8: any) => any, exp1: any, exp2: any, exp3: any, exp4: any, exp5: any, exp6: any, exp7: any, exp8: any, thisArg?: any): any;
12988
12989/**
12990 * pureFunction instruction that can support any number of bindings.
12991 *
12992 * If the value of any provided exp has changed, calls the pure function to return
12993 * an updated value. Or if no values have changed, returns cached value.
12994 *
12995 * @param slotOffset the offset from binding root to the reserved slot
12996 * @param pureFn A pure function that takes binding values and builds an object or array
12997 * containing those values.
12998 * @param exps An array of binding values
12999 * @param thisArg Optional calling context of pureFn
13000 * @returns Updated or cached value
13001 *
13002 * @codeGenApi
13003 */
13004export declare function ɵɵpureFunctionV(slotOffset: number, pureFn: (...v: any[]) => any, exps: any[], thisArg?: any): any;
13005
13006/**
13007 * Refreshes a query by combining matches from all active views and removing matches from deleted
13008 * views.
13009 *
13010 * @returns `true` if a query got dirty during change detection or if this is a static query
13011 * resolving in creation mode, `false` otherwise.
13012 *
13013 * @codeGenApi
13014 */
13015export declare function ɵɵqueryRefresh(queryList: QueryList<any>): boolean;
13016
13017/**
13018 * Retrieves a local reference from the current contextViewData.
13019 *
13020 * If the reference to retrieve is in a parent view, this instruction is used in conjunction
13021 * with a nextContext() call, which walks up the tree and updates the contextViewData instance.
13022 *
13023 * @param index The index of the local ref in contextViewData.
13024 *
13025 * @codeGenApi
13026 */
13027export declare function ɵɵreference<T>(index: number): T;
13028
13029/**
13030 *
13031 * @codeGenApi
13032 */
13033export declare function ɵɵresolveBody(element: RElement & {
13034 ownerDocument: Document;
13035}): {
13036 name: string;
13037 target: HTMLElement;
13038};
13039
13040/**
13041 *
13042 * @codeGenApi
13043 */
13044export declare function ɵɵresolveDocument(element: RElement & {
13045 ownerDocument: Document;
13046}): {
13047 name: string;
13048 target: Document;
13049};
13050
13051/**
13052 *
13053 * @codeGenApi
13054 */
13055export declare function ɵɵresolveWindow(element: RElement & {
13056 ownerDocument: Document;
13057}): {
13058 name: string;
13059 target: Window | null;
13060};
13061
13062/**
13063 * Restores `contextViewData` to the given OpaqueViewState instance.
13064 *
13065 * Used in conjunction with the getCurrentView() instruction to save a snapshot
13066 * of the current view and restore it when listeners are invoked. This allows
13067 * walking the declaration view tree in listeners to get vars from parent views.
13068 *
13069 * @param viewToRestore The OpaqueViewState instance to restore.
13070 *
13071 * @codeGenApi
13072 */
13073export declare function ɵɵrestoreView(viewToRestore: OpaqueViewState): void;
13074
13075/**
13076 * An `html` sanitizer which converts untrusted `html` **string** into trusted string by removing
13077 * dangerous content.
13078 *
13079 * This method parses the `html` and locates potentially dangerous content (such as urls and
13080 * javascript) and removes it.
13081 *
13082 * It is possible to mark a string as trusted by calling {@link bypassSanitizationTrustHtml}.
13083 *
13084 * @param unsafeHtml untrusted `html`, typically from the user.
13085 * @returns `html` string which is safe to display to user, because all of the dangerous javascript
13086 * and urls have been removed.
13087 *
13088 * @publicApi
13089 */
13090export declare function ɵɵsanitizeHtml(unsafeHtml: any): string;
13091
13092/**
13093 * A `url` sanitizer which only lets trusted `url`s through.
13094 *
13095 * This passes only `url`s marked trusted by calling {@link bypassSanitizationTrustResourceUrl}.
13096 *
13097 * @param unsafeResourceUrl untrusted `url`, typically from the user.
13098 * @returns `url` string which is safe to bind to the `src` properties such as `<img src>`, because
13099 * only trusted `url`s have been allowed to pass.
13100 *
13101 * @publicApi
13102 */
13103export declare function ɵɵsanitizeResourceUrl(unsafeResourceUrl: any): string;
13104
13105/**
13106 * A `script` sanitizer which only lets trusted javascript through.
13107 *
13108 * This passes only `script`s marked trusted by calling {@link
13109 * bypassSanitizationTrustScript}.
13110 *
13111 * @param unsafeScript untrusted `script`, typically from the user.
13112 * @returns `url` string which is safe to bind to the `<script>` element such as `<img src>`,
13113 * because only trusted `scripts` have been allowed to pass.
13114 *
13115 * @publicApi
13116 */
13117export declare function ɵɵsanitizeScript(unsafeScript: any): string;
13118
13119/**
13120 * A `style` sanitizer which converts untrusted `style` **string** into trusted string by removing
13121 * dangerous content.
13122 *
13123 * This method parses the `style` and locates potentially dangerous content (such as urls and
13124 * javascript) and removes it.
13125 *
13126 * It is possible to mark a string as trusted by calling {@link bypassSanitizationTrustStyle}.
13127 *
13128 * @param unsafeStyle untrusted `style`, typically from the user.
13129 * @returns `style` string which is safe to bind to the `style` properties, because all of the
13130 * dangerous javascript and urls have been removed.
13131 *
13132 * @publicApi
13133 */
13134export declare function ɵɵsanitizeStyle(unsafeStyle: any): string;
13135
13136/**
13137 * A `url` sanitizer which converts untrusted `url` **string** into trusted string by removing
13138 * dangerous
13139 * content.
13140 *
13141 * This method parses the `url` and locates potentially dangerous content (such as javascript) and
13142 * removes it.
13143 *
13144 * It is possible to mark a string as trusted by calling {@link bypassSanitizationTrustUrl}.
13145 *
13146 * @param unsafeUrl untrusted `url`, typically from the user.
13147 * @returns `url` string which is safe to bind to the `src` properties such as `<img src>`, because
13148 * all of the dangerous javascript has been removed.
13149 *
13150 * @publicApi
13151 */
13152export declare function ɵɵsanitizeUrl(unsafeUrl: any): string;
13153
13154/**
13155 * Sanitizes URL, selecting sanitizer function based on tag and property names.
13156 *
13157 * This function is used in case we can't define security context at compile time, when only prop
13158 * name is available. This happens when we generate host bindings for Directives/Components. The
13159 * host element is unknown at compile time, so we defer calculation of specific sanitizer to
13160 * runtime.
13161 *
13162 * @param unsafeUrl untrusted `url`, typically from the user.
13163 * @param tag target element tag name.
13164 * @param prop name of the property that contains the value.
13165 * @returns `url` string which is safe to bind.
13166 *
13167 * @publicApi
13168 */
13169export declare function ɵɵsanitizeUrlOrResourceUrl(unsafeUrl: any, tag: string, prop: string): any;
13170
13171/**
13172 * Selects an element for later binding instructions.
13173 *
13174 * Used in conjunction with instructions like {@link property} to act on elements with specified
13175 * indices, for example those created with {@link element} or {@link elementStart}.
13176 *
13177 * ```ts
13178 * (rf: RenderFlags, ctx: any) => {
13179 * if (rf & 1) {
13180 * element(0, 'div');
13181 * }
13182 * if (rf & 2) {
13183 * select(0); // Select the <div/> created above.
13184 * property('title', 'test');
13185 * }
13186 * }
13187 * ```
13188 * @param index the index of the item to act on with the following instructions
13189 *
13190 * @codeGenApi
13191 */
13192export declare function ɵɵselect(index: number): void;
13193
13194/**
13195 * @codeGenApi
13196 */
13197export declare function ɵɵsetComponentScope(type: ɵComponentType<any>, directives: Type<any>[], pipes: Type<any>[]): void;
13198
13199/**
13200 * Adds the module metadata that is necessary to compute the module's transitive scope to an
13201 * existing module definition.
13202 *
13203 * Scope metadata of modules is not used in production builds, so calls to this function can be
13204 * marked pure to tree-shake it from the bundle, allowing for all referenced declarations
13205 * to become eligible for tree-shaking as well.
13206 *
13207 * @codeGenApi
13208 */
13209export declare function ɵɵsetNgModuleScope(type: any, scope: {
13210 /** List of components, directives, and pipes declared by this module. */
13211 declarations?: Type<any>[] | (() => Type<any>[]);
13212 /** List of modules or `ModuleWithProviders` imported by this module. */
13213 imports?: Type<any>[] | (() => Type<any>[]);
13214 /**
13215 * List of modules, `ModuleWithProviders`, components, directives, or pipes exported by this
13216 * module.
13217 */
13218 exports?: Type<any>[] | (() => Type<any>[]);
13219}): void;
13220
13221/**
13222 * Registers a QueryList, associated with a static content query, for later refresh
13223 * (part of a view refresh).
13224 *
13225 * @param directiveIndex Current directive index
13226 * @param predicate The type for which the query will search
13227 * @param descend Whether or not to descend into children
13228 * @param read What to save in the query
13229 * @returns QueryList<T>
13230 *
13231 * @codeGenApi
13232 */
13233export declare function ɵɵstaticContentQuery<T>(directiveIndex: number, predicate: Type<any> | string[], descend: boolean, read?: any): void;
13234
13235/**
13236 * Creates new QueryList for a static view query.
13237 *
13238 * @param predicate The type for which the query will search
13239 * @param descend Whether or not to descend into children
13240 * @param read What to save in the query
13241 *
13242 * @codeGenApi
13243 */
13244export declare function ɵɵstaticViewQuery<T>(predicate: Type<any> | string[], descend: boolean, read?: any): void;
13245
13246/**
13247 * Update style bindings using an object literal on an element.
13248 *
13249 * This instruction is meant to apply styling via the `[style]="exp"` template bindings.
13250 * When styles are applied to the element they will then be updated with respect to
13251 * any styles/classes set via `styleProp`. If any styles are set to falsy
13252 * then they will be removed from the element.
13253 *
13254 * Note that the styling instruction will not be applied until `stylingApply` is called.
13255 *
13256 * @param styles A key/value style map of the styles that will be applied to the given element.
13257 * Any missing styles (that have already been applied to the element beforehand) will be
13258 * removed (unset) from the element's styling.
13259 *
13260 * Note that this will apply the provided styleMap value to the host element if this function
13261 * is called within a host binding.
13262 *
13263 * @codeGenApi
13264 */
13265export declare function ɵɵstyleMap(styles: {
13266 [styleName: string]: any;
13267} | ɵNO_CHANGE | null): void;
13268
13269/**
13270 * Update a style binding on an element with the provided value.
13271 *
13272 * If the style value is falsy then it will be removed from the element
13273 * (or assigned a different value depending if there are any styles placed
13274 * on the element with `styleMap` or any static styles that are
13275 * present from when the element was created with `styling`).
13276 *
13277 * Note that the styling element is updated as part of `stylingApply`.
13278 *
13279 * @param prop A valid CSS property.
13280 * @param value New value to write (`null` or an empty string to remove).
13281 * @param suffix Optional suffix. Used with scalar values to add unit such as `px`.
13282 * Note that when a suffix is provided then the underlying sanitizer will
13283 * be ignored.
13284 *
13285 * Note that this will apply the provided style value to the host element if this function is called
13286 * within a host binding.
13287 *
13288 * @codeGenApi
13289 */
13290export declare function ɵɵstyleProp(prop: string, value: string | number | String | null, suffix?: string | null): void;
13291
13292/**
13293 *
13294 * Update an interpolated style property on an element with single bound value surrounded by text.
13295 *
13296 * Used when the value passed to a property has 1 interpolated value in it:
13297 *
13298 * ```html
13299 * <div style.color="prefix{{v0}}suffix"></div>
13300 * ```
13301 *
13302 * Its compiled representation is:
13303 *
13304 * ```ts
13305 * ɵɵstylePropInterpolate1(0, 'prefix', v0, 'suffix');
13306 * ```
13307 *
13308 * @param styleIndex Index of style to update. This index value refers to the
13309 * index of the style in the style bindings array that was passed into
13310 * `styling`.
13311 * @param prefix Static value used for concatenation only.
13312 * @param v0 Value checked for change.
13313 * @param suffix Static value used for concatenation only.
13314 * @param valueSuffix Optional suffix. Used with scalar values to add unit such as `px`.
13315 * @returns itself, so that it may be chained.
13316 * @codeGenApi
13317 */
13318export declare function ɵɵstylePropInterpolate1(prop: string, prefix: string, v0: any, suffix: string, valueSuffix?: string | null): TsickleIssue1009;
13319
13320/**
13321 *
13322 * Update an interpolated style property on an element with 2 bound values surrounded by text.
13323 *
13324 * Used when the value passed to a property has 2 interpolated values in it:
13325 *
13326 * ```html
13327 * <div style.color="prefix{{v0}}-{{v1}}suffix"></div>
13328 * ```
13329 *
13330 * Its compiled representation is:
13331 *
13332 * ```ts
13333 * ɵɵstylePropInterpolate2(0, 'prefix', v0, '-', v1, 'suffix');
13334 * ```
13335 *
13336 * @param styleIndex Index of style to update. This index value refers to the
13337 * index of the style in the style bindings array that was passed into
13338 * `styling`.
13339 * @param prefix Static value used for concatenation only.
13340 * @param v0 Value checked for change.
13341 * @param i0 Static value used for concatenation only.
13342 * @param v1 Value checked for change.
13343 * @param suffix Static value used for concatenation only.
13344 * @param valueSuffix Optional suffix. Used with scalar values to add unit such as `px`.
13345 * @returns itself, so that it may be chained.
13346 * @codeGenApi
13347 */
13348export declare function ɵɵstylePropInterpolate2(prop: string, prefix: string, v0: any, i0: string, v1: any, suffix: string, valueSuffix?: string | null): TsickleIssue1009;
13349
13350/**
13351 *
13352 * Update an interpolated style property on an element with 3 bound values surrounded by text.
13353 *
13354 * Used when the value passed to a property has 3 interpolated values in it:
13355 *
13356 * ```html
13357 * <div style.color="prefix{{v0}}-{{v1}}-{{v2}}suffix"></div>
13358 * ```
13359 *
13360 * Its compiled representation is:
13361 *
13362 * ```ts
13363 * ɵɵstylePropInterpolate3(0, 'prefix', v0, '-', v1, '-', v2, 'suffix');
13364 * ```
13365 *
13366 * @param styleIndex Index of style to update. This index value refers to the
13367 * index of the style in the style bindings array that was passed into
13368 * `styling`.
13369 * @param prefix Static value used for concatenation only.
13370 * @param v0 Value checked for change.
13371 * @param i0 Static value used for concatenation only.
13372 * @param v1 Value checked for change.
13373 * @param i1 Static value used for concatenation only.
13374 * @param v2 Value checked for change.
13375 * @param suffix Static value used for concatenation only.
13376 * @param valueSuffix Optional suffix. Used with scalar values to add unit such as `px`.
13377 * @returns itself, so that it may be chained.
13378 * @codeGenApi
13379 */
13380export declare function ɵɵstylePropInterpolate3(prop: string, prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, suffix: string, valueSuffix?: string | null): TsickleIssue1009;
13381
13382/**
13383 *
13384 * Update an interpolated style property on an element with 4 bound values surrounded by text.
13385 *
13386 * Used when the value passed to a property has 4 interpolated values in it:
13387 *
13388 * ```html
13389 * <div style.color="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}suffix"></div>
13390 * ```
13391 *
13392 * Its compiled representation is:
13393 *
13394 * ```ts
13395 * ɵɵstylePropInterpolate4(0, 'prefix', v0, '-', v1, '-', v2, '-', v3, 'suffix');
13396 * ```
13397 *
13398 * @param styleIndex Index of style to update. This index value refers to the
13399 * index of the style in the style bindings array that was passed into
13400 * `styling`.
13401 * @param prefix Static value used for concatenation only.
13402 * @param v0 Value checked for change.
13403 * @param i0 Static value used for concatenation only.
13404 * @param v1 Value checked for change.
13405 * @param i1 Static value used for concatenation only.
13406 * @param v2 Value checked for change.
13407 * @param i2 Static value used for concatenation only.
13408 * @param v3 Value checked for change.
13409 * @param suffix Static value used for concatenation only.
13410 * @param valueSuffix Optional suffix. Used with scalar values to add unit such as `px`.
13411 * @returns itself, so that it may be chained.
13412 * @codeGenApi
13413 */
13414export declare function ɵɵstylePropInterpolate4(prop: string, prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string, v3: any, suffix: string, valueSuffix?: string | null): TsickleIssue1009;
13415
13416/**
13417 *
13418 * Update an interpolated style property on an element with 5 bound values surrounded by text.
13419 *
13420 * Used when the value passed to a property has 5 interpolated values in it:
13421 *
13422 * ```html
13423 * <div style.color="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}suffix"></div>
13424 * ```
13425 *
13426 * Its compiled representation is:
13427 *
13428 * ```ts
13429 * ɵɵstylePropInterpolate5(0, 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, 'suffix');
13430 * ```
13431 *
13432 * @param styleIndex Index of style to update. This index value refers to the
13433 * index of the style in the style bindings array that was passed into
13434 * `styling`.
13435 * @param prefix Static value used for concatenation only.
13436 * @param v0 Value checked for change.
13437 * @param i0 Static value used for concatenation only.
13438 * @param v1 Value checked for change.
13439 * @param i1 Static value used for concatenation only.
13440 * @param v2 Value checked for change.
13441 * @param i2 Static value used for concatenation only.
13442 * @param v3 Value checked for change.
13443 * @param i3 Static value used for concatenation only.
13444 * @param v4 Value checked for change.
13445 * @param suffix Static value used for concatenation only.
13446 * @param valueSuffix Optional suffix. Used with scalar values to add unit such as `px`.
13447 * @returns itself, so that it may be chained.
13448 * @codeGenApi
13449 */
13450export declare function ɵɵstylePropInterpolate5(prop: string, prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string, v3: any, i3: string, v4: any, suffix: string, valueSuffix?: string | null): TsickleIssue1009;
13451
13452/**
13453 *
13454 * Update an interpolated style property on an element with 6 bound values surrounded by text.
13455 *
13456 * Used when the value passed to a property has 6 interpolated values in it:
13457 *
13458 * ```html
13459 * <div style.color="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}suffix"></div>
13460 * ```
13461 *
13462 * Its compiled representation is:
13463 *
13464 * ```ts
13465 * ɵɵstylePropInterpolate6(0, 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, 'suffix');
13466 * ```
13467 *
13468 * @param styleIndex Index of style to update. This index value refers to the
13469 * index of the style in the style bindings array that was passed into
13470 * `styling`.
13471 * @param prefix Static value used for concatenation only.
13472 * @param v0 Value checked for change.
13473 * @param i0 Static value used for concatenation only.
13474 * @param v1 Value checked for change.
13475 * @param i1 Static value used for concatenation only.
13476 * @param v2 Value checked for change.
13477 * @param i2 Static value used for concatenation only.
13478 * @param v3 Value checked for change.
13479 * @param i3 Static value used for concatenation only.
13480 * @param v4 Value checked for change.
13481 * @param i4 Static value used for concatenation only.
13482 * @param v5 Value checked for change.
13483 * @param suffix Static value used for concatenation only.
13484 * @param valueSuffix Optional suffix. Used with scalar values to add unit such as `px`.
13485 * @returns itself, so that it may be chained.
13486 * @codeGenApi
13487 */
13488export declare function ɵɵstylePropInterpolate6(prop: string, prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string, v3: any, i3: string, v4: any, i4: string, v5: any, suffix: string, valueSuffix?: string | null): TsickleIssue1009;
13489
13490/**
13491 *
13492 * Update an interpolated style property on an element with 7 bound values surrounded by text.
13493 *
13494 * Used when the value passed to a property has 7 interpolated values in it:
13495 *
13496 * ```html
13497 * <div style.color="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}suffix"></div>
13498 * ```
13499 *
13500 * Its compiled representation is:
13501 *
13502 * ```ts
13503 * ɵɵstylePropInterpolate7(
13504 * 0, 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, 'suffix');
13505 * ```
13506 *
13507 * @param styleIndex Index of style to update. This index value refers to the
13508 * index of the style in the style bindings array that was passed into
13509 * `styling`.
13510 * @param prefix Static value used for concatenation only.
13511 * @param v0 Value checked for change.
13512 * @param i0 Static value used for concatenation only.
13513 * @param v1 Value checked for change.
13514 * @param i1 Static value used for concatenation only.
13515 * @param v2 Value checked for change.
13516 * @param i2 Static value used for concatenation only.
13517 * @param v3 Value checked for change.
13518 * @param i3 Static value used for concatenation only.
13519 * @param v4 Value checked for change.
13520 * @param i4 Static value used for concatenation only.
13521 * @param v5 Value checked for change.
13522 * @param i5 Static value used for concatenation only.
13523 * @param v6 Value checked for change.
13524 * @param suffix Static value used for concatenation only.
13525 * @param valueSuffix Optional suffix. Used with scalar values to add unit such as `px`.
13526 * @returns itself, so that it may be chained.
13527 * @codeGenApi
13528 */
13529export declare function ɵɵstylePropInterpolate7(prop: string, prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string, v3: any, i3: string, v4: any, i4: string, v5: any, i5: string, v6: any, suffix: string, valueSuffix?: string | null): TsickleIssue1009;
13530
13531/**
13532 *
13533 * Update an interpolated style property on an element with 8 bound values surrounded by text.
13534 *
13535 * Used when the value passed to a property has 8 interpolated values in it:
13536 *
13537 * ```html
13538 * <div style.color="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}-{{v7}}suffix"></div>
13539 * ```
13540 *
13541 * Its compiled representation is:
13542 *
13543 * ```ts
13544 * ɵɵstylePropInterpolate8(0, 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6,
13545 * '-', v7, 'suffix');
13546 * ```
13547 *
13548 * @param styleIndex Index of style to update. This index value refers to the
13549 * index of the style in the style bindings array that was passed into
13550 * `styling`.
13551 * @param prefix Static value used for concatenation only.
13552 * @param v0 Value checked for change.
13553 * @param i0 Static value used for concatenation only.
13554 * @param v1 Value checked for change.
13555 * @param i1 Static value used for concatenation only.
13556 * @param v2 Value checked for change.
13557 * @param i2 Static value used for concatenation only.
13558 * @param v3 Value checked for change.
13559 * @param i3 Static value used for concatenation only.
13560 * @param v4 Value checked for change.
13561 * @param i4 Static value used for concatenation only.
13562 * @param v5 Value checked for change.
13563 * @param i5 Static value used for concatenation only.
13564 * @param v6 Value checked for change.
13565 * @param i6 Static value used for concatenation only.
13566 * @param v7 Value checked for change.
13567 * @param suffix Static value used for concatenation only.
13568 * @param valueSuffix Optional suffix. Used with scalar values to add unit such as `px`.
13569 * @returns itself, so that it may be chained.
13570 * @codeGenApi
13571 */
13572export declare function ɵɵstylePropInterpolate8(prop: string, prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string, v3: any, i3: string, v4: any, i4: string, v5: any, i5: string, v6: any, i6: string, v7: any, suffix: string, valueSuffix?: string | null): TsickleIssue1009;
13573
13574/**
13575 * Update an interpolated style property on an element with 8 or more bound values surrounded by
13576 * text.
13577 *
13578 * Used when the number of interpolated values exceeds 7.
13579 *
13580 * ```html
13581 * <div
13582 * style.color="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}-{{v7}}-{{v8}}-{{v9}}suffix">
13583 * </div>
13584 * ```
13585 *
13586 * Its compiled representation is:
13587 *
13588 * ```ts
13589 * ɵɵstylePropInterpolateV(
13590 * 0, ['prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, '-', v7, '-', v9,
13591 * 'suffix']);
13592 * ```
13593 *
13594 * @param styleIndex Index of style to update. This index value refers to the
13595 * index of the style in the style bindings array that was passed into
13596 * `styling`..
13597 * @param values The a collection of values and the strings in-between those values, beginning with
13598 * a string prefix and ending with a string suffix.
13599 * (e.g. `['prefix', value0, '-', value1, '-', value2, ..., value99, 'suffix']`)
13600 * @param valueSuffix Optional suffix. Used with scalar values to add unit such as `px`.
13601 * @returns itself, so that it may be chained.
13602 * @codeGenApi
13603 */
13604export declare function ɵɵstylePropInterpolateV(prop: string, values: any[], valueSuffix?: string | null): TsickleIssue1009;
13605
13606/**
13607 * Sets the current style sanitizer function which will then be used
13608 * within all follow-up prop and map-based style binding instructions
13609 * for the given element.
13610 *
13611 * Note that once styling has been applied to the element (i.e. once
13612 * `select(n)` is executed or the hostBindings/template function exits)
13613 * then the active `sanitizerFn` will be set to `null`. This means that
13614 * once styling is applied to another element then a another call to
13615 * `styleSanitizer` will need to be made.
13616 *
13617 * @param sanitizerFn The sanitization function that will be used to
13618 * process style prop/value entries.
13619 *
13620 * @codeGenApi
13621 */
13622export declare function ɵɵstyleSanitizer(sanitizer: StyleSanitizeFn | null): void;
13623
13624/**
13625 * --------
13626 *
13627 * This file contains the core logic for how styling instructions are processed in Angular.
13628 *
13629 * To learn more about the algorithm see `TStylingContext`.
13630 *
13631 * --------
13632 */
13633/**
13634 * Temporary function to bridge styling functionality between this new
13635 * refactor (which is here inside of `styling_next/`) and the old
13636 * implementation (which lives inside of `styling/`).
13637 *
13638 * This function is executed during the creation block of an element.
13639 * Because the existing styling implementation issues a call to the
13640 * `styling()` instruction, this instruction will also get run. The
13641 * central idea here is that the directive index values are bound
13642 * into the context. The directive index is temporary and is only
13643 * required until the `select(n)` instruction is fully functional.
13644 *
13645 * @codeGenApi
13646 */
13647export declare function ɵɵstyling(): void;
13648
13649/**
13650 * Flushes all styling code to the element.
13651 *
13652 * This function is designed to be called from the template and hostBindings
13653 * functions and may be called multiple times depending whether multiple
13654 * sources of styling exist. If called multiple times, only the last call
13655 * to `stlyingApply()` will render styling to the element.
13656 *
13657 * @codeGenApi
13658 */
13659export declare function ɵɵstylingApply(): void;
13660
13661/**
13662 * Creates an LContainer for an ng-template (dynamically-inserted view), e.g.
13663 *
13664 * <ng-template #foo>
13665 * <div></div>
13666 * </ng-template>
13667 *
13668 * @param index The index of the container in the data array
13669 * @param templateFn Inline template
13670 * @param consts The number of nodes, local refs, and pipes for this template
13671 * @param vars The number of bindings for this template
13672 * @param tagName The name of the container element, if applicable
13673 * @param attrs The attrs attached to the container, if applicable
13674 * @param localRefs A set of local reference bindings on the element.
13675 * @param localRefExtractor A function which extracts local-refs values from the template.
13676 * Defaults to the current element associated with the local-ref.
13677 *
13678 * @codeGenApi
13679 */
13680export declare function ɵɵtemplate(index: number, templateFn: ComponentTemplate<any> | null, consts: number, vars: number, tagName?: string | null, attrs?: TAttributes | null, localRefs?: string[] | null, localRefExtractor?: LocalRefExtractor): void;
13681
13682/**
13683 * Retrieves `TemplateRef` instance from `Injector` when a local reference is placed on the
13684 * `<ng-template>` element.
13685 *
13686 * @codeGenApi
13687 */
13688export declare function ɵɵtemplateRefExtractor(tNode: TNode, currentView: ɵangular_packages_core_core_bj): TemplateRef<unknown> | null;
13689
13690/**
13691 * Create static text node
13692 *
13693 * @param index Index of the node in the data array
13694 * @param value Value to write. This value will be stringified.
13695 *
13696 * @codeGenApi
13697 */
13698export declare function ɵɵtext(index: number, value?: any): void;
13699
13700/**
13701 * Create text node with binding
13702 * Bindings should be handled externally with the proper interpolation(1-8) method
13703 *
13704 * @param value Stringified value to write.
13705 *
13706 * @codeGenApi
13707 */
13708export declare function ɵɵtextBinding<T>(value: T | ɵNO_CHANGE): void;
13709
13710/**
13711 *
13712 * Update text content with a lone bound value
13713 *
13714 * Used when a text node has 1 interpolated value in it, an no additional text
13715 * surrounds that interpolated value:
13716 *
13717 * ```html
13718 * <div>{{v0}}</div>
13719 * ```
13720 *
13721 * Its compiled representation is:
13722 *
13723 * ```ts
13724 * ɵɵtextInterpolate(v0);
13725 * ```
13726 * @returns itself, so that it may be chained.
13727 * @see textInterpolateV
13728 * @codeGenApi
13729 */
13730export declare function ɵɵtextInterpolate(v0: any): TsickleIssue1009;
13731
13732/**
13733 *
13734 * Update text content with single bound value surrounded by other text.
13735 *
13736 * Used when a text node has 1 interpolated value in it:
13737 *
13738 * ```html
13739 * <div>prefix{{v0}}suffix</div>
13740 * ```
13741 *
13742 * Its compiled representation is:
13743 *
13744 * ```ts
13745 * ɵɵtextInterpolate1('prefix', v0, 'suffix');
13746 * ```
13747 * @returns itself, so that it may be chained.
13748 * @see textInterpolateV
13749 * @codeGenApi
13750 */
13751export declare function ɵɵtextInterpolate1(prefix: string, v0: any, suffix: string): TsickleIssue1009;
13752
13753/**
13754 *
13755 * Update text content with 2 bound values surrounded by other text.
13756 *
13757 * Used when a text node has 2 interpolated values in it:
13758 *
13759 * ```html
13760 * <div>prefix{{v0}}-{{v1}}suffix</div>
13761 * ```
13762 *
13763 * Its compiled representation is:
13764 *
13765 * ```ts
13766 * ɵɵtextInterpolate2('prefix', v0, '-', v1, 'suffix');
13767 * ```
13768 * @returns itself, so that it may be chained.
13769 * @see textInterpolateV
13770 * @codeGenApi
13771 */
13772export declare function ɵɵtextInterpolate2(prefix: string, v0: any, i0: string, v1: any, suffix: string): TsickleIssue1009;
13773
13774/**
13775 *
13776 * Update text content with 3 bound values surrounded by other text.
13777 *
13778 * Used when a text node has 3 interpolated values in it:
13779 *
13780 * ```html
13781 * <div>prefix{{v0}}-{{v1}}-{{v2}}suffix</div>
13782 * ```
13783 *
13784 * Its compiled representation is:
13785 *
13786 * ```ts
13787 * ɵɵtextInterpolate3(
13788 * 'prefix', v0, '-', v1, '-', v2, 'suffix');
13789 * ```
13790 * @returns itself, so that it may be chained.
13791 * @see textInterpolateV
13792 * @codeGenApi
13793 */
13794export declare function ɵɵtextInterpolate3(prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, suffix: string): TsickleIssue1009;
13795
13796/**
13797 *
13798 * Update text content with 4 bound values surrounded by other text.
13799 *
13800 * Used when a text node has 4 interpolated values in it:
13801 *
13802 * ```html
13803 * <div>prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}suffix</div>
13804 * ```
13805 *
13806 * Its compiled representation is:
13807 *
13808 * ```ts
13809 * ɵɵtextInterpolate4(
13810 * 'prefix', v0, '-', v1, '-', v2, '-', v3, 'suffix');
13811 * ```
13812 * @returns itself, so that it may be chained.
13813 * @see ɵɵtextInterpolateV
13814 * @codeGenApi
13815 */
13816export declare function ɵɵtextInterpolate4(prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string, v3: any, suffix: string): TsickleIssue1009;
13817
13818/**
13819 *
13820 * Update text content with 5 bound values surrounded by other text.
13821 *
13822 * Used when a text node has 5 interpolated values in it:
13823 *
13824 * ```html
13825 * <div>prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}suffix</div>
13826 * ```
13827 *
13828 * Its compiled representation is:
13829 *
13830 * ```ts
13831 * ɵɵtextInterpolate5(
13832 * 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, 'suffix');
13833 * ```
13834 * @returns itself, so that it may be chained.
13835 * @see textInterpolateV
13836 * @codeGenApi
13837 */
13838export declare function ɵɵtextInterpolate5(prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string, v3: any, i3: string, v4: any, suffix: string): TsickleIssue1009;
13839
13840/**
13841 *
13842 * Update text content with 6 bound values surrounded by other text.
13843 *
13844 * Used when a text node has 6 interpolated values in it:
13845 *
13846 * ```html
13847 * <div>prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}suffix</div>
13848 * ```
13849 *
13850 * Its compiled representation is:
13851 *
13852 * ```ts
13853 * ɵɵtextInterpolate6(
13854 * 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, 'suffix');
13855 * ```
13856 *
13857 * @param i4 Static value used for concatenation only.
13858 * @param v5 Value checked for change. @returns itself, so that it may be chained.
13859 * @see textInterpolateV
13860 * @codeGenApi
13861 */
13862export declare function ɵɵtextInterpolate6(prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string, v3: any, i3: string, v4: any, i4: string, v5: any, suffix: string): TsickleIssue1009;
13863
13864/**
13865 *
13866 * Update text content with 7 bound values surrounded by other text.
13867 *
13868 * Used when a text node has 7 interpolated values in it:
13869 *
13870 * ```html
13871 * <div>prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}suffix</div>
13872 * ```
13873 *
13874 * Its compiled representation is:
13875 *
13876 * ```ts
13877 * ɵɵtextInterpolate7(
13878 * 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, 'suffix');
13879 * ```
13880 * @returns itself, so that it may be chained.
13881 * @see textInterpolateV
13882 * @codeGenApi
13883 */
13884export declare function ɵɵtextInterpolate7(prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string, v3: any, i3: string, v4: any, i4: string, v5: any, i5: string, v6: any, suffix: string): TsickleIssue1009;
13885
13886/**
13887 *
13888 * Update text content with 8 bound values surrounded by other text.
13889 *
13890 * Used when a text node has 8 interpolated values in it:
13891 *
13892 * ```html
13893 * <div>prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}-{{v7}}suffix</div>
13894 * ```
13895 *
13896 * Its compiled representation is:
13897 *
13898 * ```ts
13899 * ɵɵtextInterpolate8(
13900 * 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, '-', v7, 'suffix');
13901 * ```
13902 * @returns itself, so that it may be chained.
13903 * @see textInterpolateV
13904 * @codeGenApi
13905 */
13906export declare function ɵɵtextInterpolate8(prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string, v3: any, i3: string, v4: any, i4: string, v5: any, i5: string, v6: any, i6: string, v7: any, suffix: string): TsickleIssue1009;
13907
13908/**
13909 * Update text content with 9 or more bound values other surrounded by text.
13910 *
13911 * Used when the number of interpolated values exceeds 8.
13912 *
13913 * ```html
13914 * <div>prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}-{{v7}}-{{v8}}-{{v9}}suffix</div>
13915 * ```
13916 *
13917 * Its compiled representation is:
13918 *
13919 * ```ts
13920 * ɵɵtextInterpolateV(
13921 * ['prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, '-', v7, '-', v9,
13922 * 'suffix']);
13923 * ```
13924 *.
13925 * @param values The a collection of values and the strings in between those values, beginning with
13926 * a string prefix and ending with a string suffix.
13927 * (e.g. `['prefix', value0, '-', value1, '-', value2, ..., value99, 'suffix']`)
13928 *
13929 * @returns itself, so that it may be chained.
13930 * @codeGenApi
13931 */
13932export declare function ɵɵtextInterpolateV(values: any[]): TsickleIssue1009;
13933
13934/**
13935 * Updates a synthetic host binding (e.g. `[@foo]`) on a component.
13936 *
13937 * This instruction is for compatibility purposes and is designed to ensure that a
13938 * synthetic host binding (e.g. `@HostBinding('@foo')`) properly gets rendered in
13939 * the component's renderer. Normally all host bindings are evaluated with the parent
13940 * component's renderer, but, in the case of animation @triggers, they need to be
13941 * evaluated with the sub component's renderer (because that's where the animation
13942 * triggers are defined).
13943 *
13944 * Do not use this instruction as a replacement for `elementProperty`. This instruction
13945 * only exists to ensure compatibility with the ViewEngine's host binding behavior.
13946 *
13947 * @param index The index of the element to update in the data array
13948 * @param propName Name of property. Because it is going to DOM, this is not subject to
13949 * renaming as part of minification.
13950 * @param value New value to write.
13951 * @param sanitizer An optional function used to sanitize the value.
13952 *
13953 * @codeGenApi
13954 */
13955export declare function ɵɵupdateSyntheticHostBinding<T>(propName: string, value: T | ɵNO_CHANGE, sanitizer?: SanitizerFn | null): TsickleIssue1009;
13956
13957/**
13958 * Creates new QueryList, stores the reference in LView and returns QueryList.
13959 *
13960 * @param predicate The type for which the query will search
13961 * @param descend Whether or not to descend into children
13962 * @param read What to save in the query
13963 *
13964 * @codeGenApi
13965 */
13966export declare function ɵɵviewQuery<T>(predicate: Type<any> | string[], descend: boolean, read?: any): void;
13967
13968export { }