@angular/core 20.0.0-next.0 → 20.0.0-next.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/fesm2022/core.mjs +3307 -4479
- package/fesm2022/core.mjs.map +1 -1
- package/fesm2022/primitives/di.mjs +45 -0
- package/fesm2022/primitives/di.mjs.map +1 -0
- package/fesm2022/primitives/event-dispatch.mjs +3 -590
- package/fesm2022/primitives/event-dispatch.mjs.map +1 -1
- package/fesm2022/primitives/signals.mjs +19 -9
- package/fesm2022/primitives/signals.mjs.map +1 -1
- package/fesm2022/rxjs-interop.mjs +8 -33
- package/fesm2022/rxjs-interop.mjs.map +1 -1
- package/fesm2022/testing.mjs +392 -250
- package/fesm2022/testing.mjs.map +1 -1
- package/fesm2022/weak_ref-DrMdAIDh.mjs +12 -0
- package/fesm2022/weak_ref-DrMdAIDh.mjs.map +1 -0
- package/index.d.ts +14339 -15134
- package/navigation_types.d-u4EOrrdZ.d.ts +121 -0
- package/package.json +11 -1
- package/primitives/di/index.d.ts +91 -0
- package/primitives/event-dispatch/index.d.ts +206 -310
- package/primitives/signals/index.d.ts +159 -196
- package/rxjs-interop/index.d.ts +72 -92
- package/schematics/bundles/{apply_import_manager-0959b78c.js → apply_import_manager-CyRT0UvU.js} +13 -17
- package/schematics/bundles/{checker-cf6f7980.js → checker-DF8ZaFW5.js} +3363 -1289
- package/schematics/bundles/cleanup-unused-imports.js +22 -28
- package/schematics/bundles/{compiler_host-cc1379e9.js → compiler_host-Da636uJ8.js} +20 -24
- package/schematics/bundles/control-flow-migration.js +82 -39
- package/schematics/bundles/{imports-31a38653.js → imports-CIX-JgAN.js} +10 -15
- package/schematics/bundles/{index-42d84d69.js → index-DnkWgagp.js} +56 -60
- package/schematics/bundles/{index-6675d6bc.js → index-vGJcp5M7.js} +5 -5
- package/schematics/bundles/inject-flags.js +181 -0
- package/schematics/bundles/inject-migration.js +122 -128
- package/schematics/bundles/{leading_space-6e7a8ec6.js → leading_space-D9nQ8UQC.js} +2 -2
- package/schematics/bundles/{migrate_ts_type_references-5089e4ef.js → migrate_ts_type_references-DtkOnnv0.js} +113 -120
- package/schematics/bundles/{ng_decorators-6878e227.js → ng_decorators-DznZ5jMl.js} +5 -9
- package/schematics/bundles/{nodes-ffdce442.js → nodes-B16H9JUd.js} +3 -7
- package/schematics/bundles/output-migration.js +40 -46
- package/schematics/bundles/{program-362689f0.js → program-BZk27Ndu.js} +846 -2653
- package/schematics/bundles/{project_paths-7d2daa1e.js → project_paths-Jtbi76Bs.js} +26 -24
- package/schematics/bundles/{project_tsconfig_paths-6c9cde78.js → project_tsconfig_paths-CDVxT6Ov.js} +2 -2
- package/schematics/bundles/{property_name-42030525.js → property_name-BBwFuqMe.js} +4 -8
- package/schematics/bundles/route-lazy-loading.js +36 -42
- package/schematics/bundles/self-closing-tags-migration.js +55 -45
- package/schematics/bundles/signal-input-migration.js +61 -68
- package/schematics/bundles/signal-queries-migration.js +48 -55
- package/schematics/bundles/signals.js +10 -12
- package/schematics/bundles/standalone-migration.js +179 -185
- package/schematics/migrations.json +4 -15
- package/testing/index.d.ts +309 -478
- package/weak_ref.d-ttyj86RV.d.ts +9 -0
- package/schematics/bundles/explicit-standalone-flag.js +0 -184
- package/schematics/bundles/pending-tasks.js +0 -103
- package/schematics/bundles/provide-initializer.js +0 -186
|
@@ -0,0 +1,121 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license Angular v20.0.0-next.2
|
|
3
|
+
* (c) 2010-2025 Google LLC. https://angular.io/
|
|
4
|
+
* License: MIT
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
interface NavigationEventMap {
|
|
8
|
+
navigate: NavigateEvent;
|
|
9
|
+
navigatesuccess: Event;
|
|
10
|
+
navigateerror: ErrorEvent;
|
|
11
|
+
currententrychange: NavigationCurrentEntryChangeEvent;
|
|
12
|
+
}
|
|
13
|
+
interface NavigationResult {
|
|
14
|
+
committed: Promise<NavigationHistoryEntry>;
|
|
15
|
+
finished: Promise<NavigationHistoryEntry>;
|
|
16
|
+
}
|
|
17
|
+
declare class Navigation extends EventTarget {
|
|
18
|
+
entries(): NavigationHistoryEntry[];
|
|
19
|
+
readonly currentEntry: NavigationHistoryEntry | null;
|
|
20
|
+
updateCurrentEntry(options: NavigationUpdateCurrentEntryOptions): void;
|
|
21
|
+
readonly transition: NavigationTransition | null;
|
|
22
|
+
readonly canGoBack: boolean;
|
|
23
|
+
readonly canGoForward: boolean;
|
|
24
|
+
navigate(url: string, options?: NavigationNavigateOptions): NavigationResult;
|
|
25
|
+
reload(options?: NavigationReloadOptions): NavigationResult;
|
|
26
|
+
traverseTo(key: string, options?: NavigationOptions): NavigationResult;
|
|
27
|
+
back(options?: NavigationOptions): NavigationResult;
|
|
28
|
+
forward(options?: NavigationOptions): NavigationResult;
|
|
29
|
+
onnavigate: ((this: Navigation, ev: NavigateEvent) => any) | null;
|
|
30
|
+
onnavigatesuccess: ((this: Navigation, ev: Event) => any) | null;
|
|
31
|
+
onnavigateerror: ((this: Navigation, ev: ErrorEvent) => any) | null;
|
|
32
|
+
oncurrententrychange: ((this: Navigation, ev: NavigationCurrentEntryChangeEvent) => any) | null;
|
|
33
|
+
addEventListener<K extends keyof NavigationEventMap>(type: K, listener: (this: Navigation, ev: NavigationEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
|
|
34
|
+
addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
|
|
35
|
+
removeEventListener<K extends keyof NavigationEventMap>(type: K, listener: (this: Navigation, ev: NavigationEventMap[K]) => any, options?: boolean | EventListenerOptions): void;
|
|
36
|
+
removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
|
|
37
|
+
}
|
|
38
|
+
declare class NavigationTransition {
|
|
39
|
+
readonly navigationType: NavigationTypeString;
|
|
40
|
+
readonly from: NavigationHistoryEntry;
|
|
41
|
+
readonly finished: Promise<void>;
|
|
42
|
+
}
|
|
43
|
+
interface NavigationHistoryEntryEventMap {
|
|
44
|
+
dispose: Event;
|
|
45
|
+
}
|
|
46
|
+
declare class NavigationHistoryEntry extends EventTarget {
|
|
47
|
+
readonly key: string;
|
|
48
|
+
readonly id: string;
|
|
49
|
+
readonly url: string | null;
|
|
50
|
+
readonly index: number;
|
|
51
|
+
readonly sameDocument: boolean;
|
|
52
|
+
getState(): unknown;
|
|
53
|
+
ondispose: ((this: NavigationHistoryEntry, ev: Event) => any) | null;
|
|
54
|
+
addEventListener<K extends keyof NavigationHistoryEntryEventMap>(type: K, listener: (this: NavigationHistoryEntry, ev: NavigationHistoryEntryEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
|
|
55
|
+
addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
|
|
56
|
+
removeEventListener<K extends keyof NavigationHistoryEntryEventMap>(type: K, listener: (this: NavigationHistoryEntry, ev: NavigationHistoryEntryEventMap[K]) => any, options?: boolean | EventListenerOptions): void;
|
|
57
|
+
removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
|
|
58
|
+
}
|
|
59
|
+
type NavigationTypeString = 'reload' | 'push' | 'replace' | 'traverse';
|
|
60
|
+
interface NavigationUpdateCurrentEntryOptions {
|
|
61
|
+
state: unknown;
|
|
62
|
+
}
|
|
63
|
+
interface NavigationOptions {
|
|
64
|
+
info?: unknown;
|
|
65
|
+
}
|
|
66
|
+
interface NavigationNavigateOptions extends NavigationOptions {
|
|
67
|
+
state?: unknown;
|
|
68
|
+
history?: 'auto' | 'push' | 'replace';
|
|
69
|
+
}
|
|
70
|
+
interface NavigationReloadOptions extends NavigationOptions {
|
|
71
|
+
state?: unknown;
|
|
72
|
+
}
|
|
73
|
+
declare class NavigationCurrentEntryChangeEvent extends Event {
|
|
74
|
+
constructor(type: string, eventInit?: NavigationCurrentEntryChangeEventInit);
|
|
75
|
+
readonly navigationType: NavigationTypeString | null;
|
|
76
|
+
readonly from: NavigationHistoryEntry;
|
|
77
|
+
}
|
|
78
|
+
interface NavigationCurrentEntryChangeEventInit extends EventInit {
|
|
79
|
+
navigationType?: NavigationTypeString | null;
|
|
80
|
+
from: NavigationHistoryEntry;
|
|
81
|
+
}
|
|
82
|
+
declare class NavigateEvent extends Event {
|
|
83
|
+
constructor(type: string, eventInit?: NavigateEventInit);
|
|
84
|
+
readonly navigationType: NavigationTypeString;
|
|
85
|
+
readonly canIntercept: boolean;
|
|
86
|
+
readonly userInitiated: boolean;
|
|
87
|
+
readonly hashChange: boolean;
|
|
88
|
+
readonly destination: NavigationDestination;
|
|
89
|
+
readonly signal: AbortSignal;
|
|
90
|
+
readonly formData: FormData | null;
|
|
91
|
+
readonly downloadRequest: string | null;
|
|
92
|
+
readonly info?: unknown;
|
|
93
|
+
intercept(options?: NavigationInterceptOptions): void;
|
|
94
|
+
scroll(): void;
|
|
95
|
+
}
|
|
96
|
+
interface NavigateEventInit extends EventInit {
|
|
97
|
+
navigationType?: NavigationTypeString;
|
|
98
|
+
canIntercept?: boolean;
|
|
99
|
+
userInitiated?: boolean;
|
|
100
|
+
hashChange?: boolean;
|
|
101
|
+
destination: NavigationDestination;
|
|
102
|
+
signal: AbortSignal;
|
|
103
|
+
formData?: FormData | null;
|
|
104
|
+
downloadRequest?: string | null;
|
|
105
|
+
info?: unknown;
|
|
106
|
+
}
|
|
107
|
+
interface NavigationInterceptOptions {
|
|
108
|
+
handler?: () => Promise<void>;
|
|
109
|
+
focusReset?: 'after-transition' | 'manual';
|
|
110
|
+
scroll?: 'after-transition' | 'manual';
|
|
111
|
+
}
|
|
112
|
+
declare class NavigationDestination {
|
|
113
|
+
readonly url: string;
|
|
114
|
+
readonly key: string | null;
|
|
115
|
+
readonly id: string | null;
|
|
116
|
+
readonly index: number;
|
|
117
|
+
readonly sameDocument: boolean;
|
|
118
|
+
getState(): unknown;
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
export { NavigateEvent as N, Navigation as a, NavigationCurrentEntryChangeEvent as b, NavigationHistoryEntry as c, type NavigationNavigateOptions as d, type NavigationOptions as e, type NavigationReloadOptions as f, type NavigationResult as g, NavigationTransition as h, type NavigationUpdateCurrentEntryOptions as i, type NavigationTypeString as j, type NavigationInterceptOptions as k, NavigationDestination as l };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@angular/core",
|
|
3
|
-
"version": "20.0.0-next.
|
|
3
|
+
"version": "20.0.0-next.2",
|
|
4
4
|
"description": "Angular - the core framework",
|
|
5
5
|
"author": "angular",
|
|
6
6
|
"license": "MIT",
|
|
@@ -21,6 +21,10 @@
|
|
|
21
21
|
"types": "./index.d.ts",
|
|
22
22
|
"default": "./fesm2022/core.mjs"
|
|
23
23
|
},
|
|
24
|
+
"./primitives/di": {
|
|
25
|
+
"types": "./primitives/di/index.d.ts",
|
|
26
|
+
"default": "./fesm2022/primitives/di.mjs"
|
|
27
|
+
},
|
|
24
28
|
"./primitives/event-dispatch": {
|
|
25
29
|
"types": "./primitives/event-dispatch/index.d.ts",
|
|
26
30
|
"default": "./fesm2022/primitives/event-dispatch.mjs"
|
|
@@ -42,9 +46,15 @@
|
|
|
42
46
|
"tslib": "^2.3.0"
|
|
43
47
|
},
|
|
44
48
|
"peerDependencies": {
|
|
49
|
+
"@angular/compiler": "20.0.0-next.2",
|
|
45
50
|
"rxjs": "^6.5.3 || ^7.4.0",
|
|
46
51
|
"zone.js": "~0.15.0"
|
|
47
52
|
},
|
|
53
|
+
"peerDependenciesMeta": {
|
|
54
|
+
"@angular/compiler": {
|
|
55
|
+
"optional": true
|
|
56
|
+
}
|
|
57
|
+
},
|
|
48
58
|
"repository": {
|
|
49
59
|
"type": "git",
|
|
50
60
|
"url": "https://github.com/angular/angular.git",
|
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license Angular v20.0.0-next.2
|
|
3
|
+
* (c) 2010-2025 Google LLC. https://angular.io/
|
|
4
|
+
* License: MIT
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* @description
|
|
9
|
+
*
|
|
10
|
+
* Represents a type that a Component or other object is instances of.
|
|
11
|
+
*
|
|
12
|
+
* An example of a `Type` is `MyCustomComponent` class, which in JavaScript is represented by
|
|
13
|
+
* the `MyCustomComponent` constructor function.
|
|
14
|
+
*
|
|
15
|
+
* @publicApi
|
|
16
|
+
*/
|
|
17
|
+
declare const Type: FunctionConstructor;
|
|
18
|
+
interface Type<T> extends Function {
|
|
19
|
+
new (...args: any[]): T;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
/**
|
|
23
|
+
* Information about how a type or `InjectionToken` interfaces with the DI system.
|
|
24
|
+
*
|
|
25
|
+
* At a minimum, this includes a `factory` which defines how to create the given type `T`, possibly
|
|
26
|
+
* requesting injection of other types if necessary.
|
|
27
|
+
*
|
|
28
|
+
* Optionally, a `providedIn` parameter specifies that the given type belongs to a particular
|
|
29
|
+
* `Injector`, `NgModule`, or a special scope (e.g. `'root'`). A value of `null` indicates
|
|
30
|
+
* that the injectable does not belong to any scope.
|
|
31
|
+
*/
|
|
32
|
+
interface ɵɵInjectableDeclaration<T> {
|
|
33
|
+
/**
|
|
34
|
+
* Specifies that the given type belongs to a particular injector:
|
|
35
|
+
*/
|
|
36
|
+
providedIn: Type<any> | 'root' | 'platform' | 'any' | null;
|
|
37
|
+
/**
|
|
38
|
+
* The token to which this definition belongs.
|
|
39
|
+
*
|
|
40
|
+
* Note that this may not be the same as the type that the `factory` will create.
|
|
41
|
+
*/
|
|
42
|
+
token: unknown;
|
|
43
|
+
/**
|
|
44
|
+
* Factory method to execute to create an instance of the injectable.
|
|
45
|
+
*/
|
|
46
|
+
factory: (t?: Type<any>) => T;
|
|
47
|
+
/**
|
|
48
|
+
* In a case of no explicit injector, a location where the instance of the injectable is stored.
|
|
49
|
+
*/
|
|
50
|
+
value: T | undefined;
|
|
51
|
+
}
|
|
52
|
+
/**
|
|
53
|
+
* A `Type` which has a `ɵprov: ɵɵInjectableDeclaration` static field.
|
|
54
|
+
*
|
|
55
|
+
* `InjectableType`s contain their own Dependency Injection metadata and are usable in an
|
|
56
|
+
* `InjectorDef`-based `StaticInjector`.
|
|
57
|
+
*
|
|
58
|
+
* @publicApi
|
|
59
|
+
*/
|
|
60
|
+
interface InjectionToken<T> {
|
|
61
|
+
ɵprov: ɵɵInjectableDeclaration<T>;
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
/**
|
|
65
|
+
* Value returned if the key-value pair couldn't be found in the context
|
|
66
|
+
* hierarchy.
|
|
67
|
+
*/
|
|
68
|
+
declare const NOT_FOUND: unique symbol;
|
|
69
|
+
/**
|
|
70
|
+
* Error thrown when the key-value pair couldn't be found in the context
|
|
71
|
+
* hierarchy. Context can be attached below.
|
|
72
|
+
*/
|
|
73
|
+
declare class NotFoundError extends Error {
|
|
74
|
+
constructor(message: string);
|
|
75
|
+
}
|
|
76
|
+
/**
|
|
77
|
+
* Type guard for checking if an unknown value is a NotFound.
|
|
78
|
+
*/
|
|
79
|
+
declare function isNotFound(e: unknown): e is NotFound;
|
|
80
|
+
/**
|
|
81
|
+
* Type union of NotFound and NotFoundError.
|
|
82
|
+
*/
|
|
83
|
+
type NotFound = typeof NOT_FOUND | NotFoundError;
|
|
84
|
+
|
|
85
|
+
interface Injector {
|
|
86
|
+
retrieve<T>(token: InjectionToken<T>, options?: unknown): T | NotFound;
|
|
87
|
+
}
|
|
88
|
+
declare function getCurrentInjector(): Injector | undefined | null;
|
|
89
|
+
declare function setCurrentInjector(injector: Injector | null | undefined): Injector | undefined | null;
|
|
90
|
+
|
|
91
|
+
export { type InjectionToken, type Injector, NOT_FOUND, type NotFound, NotFoundError, getCurrentInjector, isNotFound, setCurrentInjector, type ɵɵInjectableDeclaration };
|