1 | /**
|
2 | * @license Angular v17.3.7
|
3 | * (c) 2010-2024 Google LLC. https://angular.io/
|
4 | * License: MIT
|
5 | */
|
6 |
|
7 |
|
8 | import { ANIMATION_MODULE_TYPE } from '@angular/core';
|
9 | import { AnimationDriver } from '@angular/animations/browser';
|
10 | import * as i0 from '@angular/core';
|
11 | import * as i1 from '@angular/platform-browser';
|
12 | import { ModuleWithProviders } from '@angular/core';
|
13 | import { OnDestroy } from '@angular/core';
|
14 | import { Provider } from '@angular/core';
|
15 | import { ɵAnimationEngine } from '@angular/animations/browser';
|
16 | import { ɵAnimationStyleNormalizer } from '@angular/animations/browser';
|
17 |
|
18 | export { ANIMATION_MODULE_TYPE }
|
19 |
|
20 | /**
|
21 | * Exports `BrowserModule` with additional [dependency-injection providers](guide/glossary#provider)
|
22 | * for use with animations. See [Animations](guide/animations).
|
23 | * @publicApi
|
24 | */
|
25 | export declare class BrowserAnimationsModule {
|
26 | /**
|
27 | * Configures the module based on the specified object.
|
28 | *
|
29 | * @param config Object used to configure the behavior of the `BrowserAnimationsModule`.
|
30 | * @see {@link BrowserAnimationsModuleConfig}
|
31 | *
|
32 | * @usageNotes
|
33 | * When registering the `BrowserAnimationsModule`, you can use the `withConfig`
|
34 | * function as follows:
|
35 | * ```
|
36 | * @NgModule({
|
37 | * imports: [BrowserAnimationsModule.withConfig(config)]
|
38 | * })
|
39 | * class MyNgModule {}
|
40 | * ```
|
41 | */
|
42 | static withConfig(config: BrowserAnimationsModuleConfig): ModuleWithProviders<BrowserAnimationsModule>;
|
43 | static ɵfac: i0.ɵɵFactoryDeclaration<BrowserAnimationsModule, never>;
|
44 | static ɵmod: i0.ɵɵNgModuleDeclaration<BrowserAnimationsModule, never, never, [typeof i1.BrowserModule]>;
|
45 | static ɵinj: i0.ɵɵInjectorDeclaration<BrowserAnimationsModule>;
|
46 | }
|
47 |
|
48 | /**
|
49 | * Object used to configure the behavior of {@link BrowserAnimationsModule}
|
50 | * @publicApi
|
51 | */
|
52 | export declare interface BrowserAnimationsModuleConfig {
|
53 | /**
|
54 | * Whether animations should be disabled. Passing this is identical to providing the
|
55 | * `NoopAnimationsModule`, but it can be controlled based on a runtime value.
|
56 | */
|
57 | disableAnimations?: boolean;
|
58 | }
|
59 |
|
60 | /**
|
61 | * A null player that must be imported to allow disabling of animations.
|
62 | * @publicApi
|
63 | */
|
64 | export declare class NoopAnimationsModule {
|
65 | static ɵfac: i0.ɵɵFactoryDeclaration<NoopAnimationsModule, never>;
|
66 | static ɵmod: i0.ɵɵNgModuleDeclaration<NoopAnimationsModule, never, never, [typeof i1.BrowserModule]>;
|
67 | static ɵinj: i0.ɵɵInjectorDeclaration<NoopAnimationsModule>;
|
68 | }
|
69 |
|
70 | /**
|
71 | * Returns the set of [dependency-injection providers](guide/glossary#provider)
|
72 | * to enable animations in an application. See [animations guide](guide/animations)
|
73 | * to learn more about animations in Angular.
|
74 | *
|
75 | * @usageNotes
|
76 | *
|
77 | * The function is useful when you want to enable animations in an application
|
78 | * bootstrapped using the `bootstrapApplication` function. In this scenario there
|
79 | * is no need to import the `BrowserAnimationsModule` NgModule at all, just add
|
80 | * providers returned by this function to the `providers` list as show below.
|
81 | *
|
82 | * ```typescript
|
83 | * bootstrapApplication(RootComponent, {
|
84 | * providers: [
|
85 | * provideAnimations()
|
86 | * ]
|
87 | * });
|
88 | * ```
|
89 | *
|
90 | * @publicApi
|
91 | */
|
92 | export declare function provideAnimations(): Provider[];
|
93 |
|
94 | /**
|
95 | * Returns the set of [dependency-injection providers](guide/glossary#provider)
|
96 | * to disable animations in an application. See [animations guide](guide/animations)
|
97 | * to learn more about animations in Angular.
|
98 | *
|
99 | * @usageNotes
|
100 | *
|
101 | * The function is useful when you want to bootstrap an application using
|
102 | * the `bootstrapApplication` function, but you need to disable animations
|
103 | * (for example, when running tests).
|
104 | *
|
105 | * ```typescript
|
106 | * bootstrapApplication(RootComponent, {
|
107 | * providers: [
|
108 | * provideNoopAnimations()
|
109 | * ]
|
110 | * });
|
111 | * ```
|
112 | *
|
113 | * @publicApi
|
114 | */
|
115 | export declare function provideNoopAnimations(): Provider[];
|
116 |
|
117 | export declare class ɵInjectableAnimationEngine extends ɵAnimationEngine implements OnDestroy {
|
118 | constructor(doc: Document, driver: AnimationDriver, normalizer: ɵAnimationStyleNormalizer);
|
119 | ngOnDestroy(): void;
|
120 | static ɵfac: i0.ɵɵFactoryDeclaration<ɵInjectableAnimationEngine, never>;
|
121 | static ɵprov: i0.ɵɵInjectableDeclaration<ɵInjectableAnimationEngine>;
|
122 | }
|
123 |
|
124 | export { }
|