@loozo/angular-router 0.0.7 → 0.0.9
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/README.md +178 -39
- package/fesm2022/loozo-angular-router-_core.mjs +33 -2
- package/fesm2022/loozo-angular-router-_core.mjs.map +1 -1
- package/fesm2022/loozo-angular-router-_generated.mjs +196 -43
- package/fesm2022/loozo-angular-router-_generated.mjs.map +1 -1
- package/fesm2022/loozo-angular-router.mjs +2 -2
- package/node/src/builders/serve.js +82 -87
- package/node/src/generation/emit.js +29 -3
- package/node/src/generation/files.d.ts +1 -0
- package/node/src/generation/files.js +13 -2
- package/node/src/generation/overlay.js +9 -2
- package/node/src/generation/sources.js +12 -5
- package/package.json +1 -1
- package/snippets/generated/destinations.generated.ts +25 -1
- package/snippets/src/routes/products/$productId/route.generated.ts +4 -2
- package/snippets/src/routes/reports/$reportId/route.generated.ts +4 -2
- package/snippets/src/routes/teams/$teamId/items/$id/inputs.ts +2 -1
- package/snippets/src/routes/teams/$teamId/items/$id/links.ts +6 -4
- package/snippets/src/routes/teams/$teamId/items/$id/page.spec.ts +29 -0
- package/snippets/src/routes/teams/$teamId/items/$id/route.generated.ts +4 -2
- package/snippets/src/routes/teams/$teamId/members/$memberId/route.generated.ts +4 -2
- package/snippets/src/routes/teams/$teamId/route.generated.ts +4 -2
- package/snippets/src/routes/teams/$teamId/route.ts +3 -0
- package/snippets/src/shell.ts +39 -3
- package/types/loozo-angular-router-_core.d.ts +135 -53
- package/types/loozo-angular-router-_generated.d.ts +111 -61
- package/types/loozo-angular-router.d.ts +2 -2
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ActivatedRouteSnapshot, PartialMatchRouteSnapshot, RedirectFunction, Route, UrlTree } from "@angular/router";
|
|
2
|
-
import { AnyRoute, ParamsOf, SearchOf, UrlValues } from "@loozo/angular-router/_core";
|
|
1
|
+
import { ActivatedRoute, ActivatedRouteSnapshot, NavigationBehaviorOptions, PartialMatchRouteSnapshot, RedirectFunction, Route, Router, UrlTree } from "@angular/router";
|
|
2
|
+
import { AnyRoute, FragmentsOf, ParamsOf, PathUrlValues, PathlessUrlValues, SearchFieldOf, SearchOf, TitleOf, UrlValues } from "@loozo/angular-router/_core";
|
|
3
3
|
import { Signal } from "@angular/core";
|
|
4
4
|
interface RecordBinding {
|
|
5
5
|
readonly definition: () => AnyRoute;
|
|
@@ -23,6 +23,8 @@ interface Job {
|
|
|
23
23
|
parse(raw: string): unknown;
|
|
24
24
|
};
|
|
25
25
|
}
|
|
26
|
+
/** The generated declaration identity carried as the record's own route data, if any. */
|
|
27
|
+
declare function routeIdentity(snapshot: Pick<ActivatedRouteSnapshot, "routeConfig">): unknown;
|
|
26
28
|
declare function hasIdentity(snapshot: Pick<ActivatedRouteSnapshot, "routeConfig">, id: string): boolean;
|
|
27
29
|
export declare function assertIdentity(snapshot: Pick<ActivatedRouteSnapshot, "routeConfig">, id: string): void;
|
|
28
30
|
declare function validateRaw(key: string, raws: readonly unknown[], array: boolean): asserts raws is readonly string[];
|
|
@@ -34,6 +36,7 @@ declare function runPathJobs(jobs: readonly Job[]): Readonly<Record<string, unkn
|
|
|
34
36
|
/**
|
|
35
37
|
* Parses a declaration's effective search. It never fails on input: a missing,
|
|
36
38
|
* repeated or invalid value reads as the key's fallback, or leaves it absent.
|
|
39
|
+
* An array key reads every value, or `[]` when it is missing or any value is invalid.
|
|
37
40
|
*/
|
|
38
41
|
declare function parseSearch(definition: AnyRoute, snapshot: Pick<ActivatedRouteSnapshot, "queryParamMap">): Readonly<Record<string, unknown>>;
|
|
39
42
|
/** The effective inputs of a complete snapshot, shared by guards, resolvers and handles. */
|
|
@@ -57,12 +60,39 @@ declare function pathInputs(set: RouteSet, id: string, snapshot: PartialMatchRou
|
|
|
57
60
|
declare function matchingInputs(set: RouteSet, id: string, snapshot: PartialMatchRouteSnapshot): Parsed | undefined;
|
|
58
61
|
export declare function callbacks(set: RouteSet, id: string): Pick<Route, "canActivate" | "canActivateChild" | "canMatch" | "resolve" | "title">;
|
|
59
62
|
export declare function redirect(definition: () => AnyRoute): RedirectFunction;
|
|
63
|
+
/**
|
|
64
|
+
* One reader of the deepest active primary-outlet route of the set.
|
|
65
|
+
*
|
|
66
|
+
* @remarks
|
|
67
|
+
* The selection changes only after a navigation commits: the computed tracks
|
|
68
|
+
* `lastSuccessfulNavigation`, and a reader first read before its tree has committed
|
|
69
|
+
* returns undefined until the running navigation ends. The reader reads itself at each
|
|
70
|
+
* `NavigationEnd`, so it reconciles every commit even without a live consumer. It owns
|
|
71
|
+
* one entry per active ActivatedRoute, reused while that record stays in the chain;
|
|
72
|
+
* departed entries are released at the commit and keep their last values. Destroying
|
|
73
|
+
* the injection context releases the rest; the reader then keeps its last selection.
|
|
74
|
+
*/
|
|
75
|
+
export declare function injectGeneratedActiveRoute<Active>(set: RouteSet): Signal<Active | undefined>;
|
|
76
|
+
interface RouteView {
|
|
77
|
+
readonly params: Signal<Readonly<Record<string, unknown>>>;
|
|
78
|
+
readonly search: Signal<Readonly<Record<string, unknown>>>;
|
|
79
|
+
readonly data: Signal<Readonly<Record<PropertyKey, unknown>>>;
|
|
80
|
+
readonly title: Signal<string | undefined>;
|
|
81
|
+
}
|
|
82
|
+
/**
|
|
83
|
+
* Signals of the route's committed snapshot. Angular replaces ActivatedRoute.snapshot
|
|
84
|
+
* only when a navigation activates, so a pending, cancelled or failed navigation
|
|
85
|
+
* leaves the values alone; params, search, data and title change together, from one snapshot.
|
|
86
|
+
* The caller owns the lifetime: `teardown` receives the function that stops following
|
|
87
|
+
* the route, after which the signals keep their last values.
|
|
88
|
+
*/
|
|
89
|
+
declare function observeRoute(set: RouteSet, id: string, activated: ActivatedRoute, router: Router, teardown: (release: () => void) => void): RouteView;
|
|
60
90
|
declare const destinationBrand: unique symbol;
|
|
61
91
|
/**
|
|
62
92
|
* An inert nominal reference exported as `destination` by a route-local facade.
|
|
63
93
|
*
|
|
64
94
|
* @remarks
|
|
65
|
-
*
|
|
95
|
+
* Pass the exported object as `to` in a handle's link/navigate record; no injection
|
|
66
96
|
* context or target activation is needed. It selects its exact declaration,
|
|
67
97
|
* not a canonical pathless winner. Only references from the caller's generated
|
|
68
98
|
* set are accepted. Copies, spreads, fakes and authored routes are not references.
|
|
@@ -85,32 +115,53 @@ export declare class Destination<Target extends AnyRoute, Set = unknown, Id exte
|
|
|
85
115
|
};
|
|
86
116
|
}
|
|
87
117
|
export declare function createDestination<Target extends AnyRoute, Set, Id extends string>(getSet: () => RouteSet, id: Id): Destination<Target, Set, Id>;
|
|
118
|
+
/** The declaration a genuine destination of this set references. */
|
|
119
|
+
export declare function destinationId(set: RouteSet, destination: unknown): string;
|
|
88
120
|
type DataOf<Target> = Target extends {
|
|
89
121
|
readonly __data?: infer Data;
|
|
90
122
|
} ? Readonly<Data> : never;
|
|
91
123
|
type IsUnion<Value, Whole = Value> = Value extends unknown ? [Whole] extends [Value] ? false : true : never;
|
|
124
|
+
interface PathlessOwnLink<Search, Fragment> extends PathlessUrlValues<Search, Fragment> {
|
|
125
|
+
/** Omitted: this exact declaration, not its pathless winner. */
|
|
126
|
+
readonly to?: undefined;
|
|
127
|
+
}
|
|
128
|
+
interface PathOwnLink<Params, Search, Fragment> extends PathUrlValues<Params, Search, Fragment> {
|
|
129
|
+
/** Omitted: this exact declaration, not its pathless winner. */
|
|
130
|
+
readonly to?: undefined;
|
|
131
|
+
}
|
|
132
|
+
interface PathlessOwnNavigation<Search, Fragment> extends PathlessOwnLink<Search, Fragment>, NavigationBehaviorOptions {}
|
|
133
|
+
interface PathOwnNavigation<Params, Search, Fragment> extends PathOwnLink<Params, Search, Fragment>, NavigationBehaviorOptions {}
|
|
134
|
+
type OwnLink<Target extends AnyRoute, Keys extends keyof SearchOf<Target>> = keyof ParamsOf<Target> extends never ? PathlessOwnLink<SearchFieldOf<Target, Keys>, FragmentsOf<Target>> : PathOwnLink<ParamsOf<Target>, SearchFieldOf<Target, Keys>, FragmentsOf<Target>>;
|
|
135
|
+
type OwnNavigation<Target extends AnyRoute, Keys extends keyof SearchOf<Target>> = keyof ParamsOf<Target> extends never ? PathlessOwnNavigation<SearchFieldOf<Target, Keys>, FragmentsOf<Target>> : PathOwnNavigation<ParamsOf<Target>, SearchFieldOf<Target, Keys>, FragmentsOf<Target>>;
|
|
92
136
|
/**
|
|
93
137
|
* The noncallable typed handle returned by a colocated `injectRoute()` facade.
|
|
94
138
|
*
|
|
95
139
|
* @remarks
|
|
96
140
|
* Obtain it in an Angular injection context for the exact generated activated
|
|
97
141
|
* record. Params, search and data are readonly Angular Signals of the route's
|
|
98
|
-
* committed snapshot, with values from the first read. Data
|
|
99
|
-
*
|
|
142
|
+
* committed snapshot, with values from the first read. Data holds the resolver
|
|
143
|
+
* results of the route's whole chain, ancestors first, a nearer key hiding an
|
|
144
|
+
* ancestor's key of the same name; native static data and the title stay out.
|
|
145
|
+
* Title is the resolved title of the nearest route in the chain that declares
|
|
146
|
+
* one: `string` when the route or an ancestor declares it, else `undefined`.
|
|
100
147
|
*
|
|
101
148
|
* While a navigation is pending, the signals keep the current snapshot's values;
|
|
102
|
-
* when a navigation commits a new snapshot for this route,
|
|
149
|
+
* when a navigation commits a new snapshot for this route, they change
|
|
103
150
|
* together. Cancellation, failure or a same-URL skip leaves them unchanged. For
|
|
104
151
|
* pending-navigation UI, read Angular's `Router.currentNavigation()`. There is no
|
|
105
152
|
* resolved-data cache. Reading params or search throws only when a path codec
|
|
106
153
|
* rejects a value it accepted while matching, a programming error.
|
|
107
154
|
*
|
|
108
|
-
*
|
|
109
|
-
*
|
|
110
|
-
*
|
|
111
|
-
*
|
|
112
|
-
*
|
|
113
|
-
*
|
|
155
|
+
* `link` and `navigate` take one target record. Its `to` selects the
|
|
156
|
+
* destination: omitted for this exact declaration, not its pathless winner; a
|
|
157
|
+
* single known absolute authored literal, never a concrete URL or string union;
|
|
158
|
+
* `..` for the parent route, the nearest ancestor with a shorter path or the
|
|
159
|
+
* root for a top-level route; or a same-set generated destination. Literal and
|
|
160
|
+
* `..` selectors use generated canonical targets. `params`, `search` and
|
|
161
|
+
* `fragment` are the destination's complete explicit values; there is no
|
|
162
|
+
* current-value reuse or implicit query merge. For `navigate`, the record's
|
|
163
|
+
* other keys are Angular's `NavigationBehaviorOptions`, passed to
|
|
164
|
+
* `Router.navigateByUrl` as given; `link` takes none, so set them on RouterLink.
|
|
114
165
|
*
|
|
115
166
|
* @typeParam Target - The bound declaration's schema.
|
|
116
167
|
* @typeParam Absolute - Absolute literal selectors and their target schemas.
|
|
@@ -124,8 +175,9 @@ type IsUnion<Value, Whole = Value> = Value extends unknown ? [Whole] extends [Va
|
|
|
124
175
|
* import { destination as report } from "../report/route.generated.js";
|
|
125
176
|
*
|
|
126
177
|
* const route = injectRoute(); // Inside an Angular injection context.
|
|
127
|
-
* const link = route.link(report,
|
|
128
|
-
* // Bind link to Angular RouterLink, or
|
|
178
|
+
* const link = route.link({ to: report, params: { reportId: 42 } });
|
|
179
|
+
* // Bind link to Angular RouterLink, or navigate with the same record and behavior options:
|
|
180
|
+
* void route.navigate({ to: report, params: { reportId: 42 }, replaceUrl: true });
|
|
129
181
|
* ```
|
|
130
182
|
*/
|
|
131
183
|
export interface Handle<Target extends AnyRoute, Absolute extends Record<string, AnyRoute> = {}, Parent extends AnyRoute = never, Set = unknown, References extends Record<string, AnyRoute> = {}> {
|
|
@@ -133,97 +185,95 @@ export interface Handle<Target extends AnyRoute, Absolute extends Record<string,
|
|
|
133
185
|
readonly params: Signal<Readonly<ParamsOf<Target>>>;
|
|
134
186
|
/** Effective declared search, from the same snapshot as params; absent keys have no value or fallback. */
|
|
135
187
|
readonly search: Signal<Readonly<SearchOf<Target>>>;
|
|
136
|
-
/**
|
|
188
|
+
/** Effective resolver results of the route and its ancestors, from the same snapshot as params. */
|
|
137
189
|
readonly data: Signal<DataOf<Target>>;
|
|
190
|
+
/** Resolved title of the nearest route in the chain that declares one, from the same snapshot as params. */
|
|
191
|
+
readonly title: Signal<TitleOf<Target>>;
|
|
138
192
|
/**
|
|
139
|
-
* Creates a native UrlTree for this exact declaration without navigating.
|
|
193
|
+
* Creates a native UrlTree for this exact declaration, not its pathless winner, without navigating.
|
|
140
194
|
*
|
|
141
|
-
* @param
|
|
195
|
+
* @param target - No `to`, and this declaration's explicit params/search and optional own fragment.
|
|
142
196
|
* @returns Router.parseUrl's result, suitable for Angular RouterLink.
|
|
143
|
-
* @throws Synchronous URL validation, encoding or stringifier failures before Angular.
|
|
197
|
+
* @throws Synchronous URL validation, encoding or stringifier failures, or a behavior option, before Angular.
|
|
144
198
|
*/
|
|
145
|
-
link<Keys extends keyof SearchOf<Target> = never>(
|
|
146
|
-
/**
|
|
147
|
-
* Creates a UrlTree for the exact bound declaration, not its pathless winner.
|
|
148
|
-
*
|
|
149
|
-
* @param selector - The exact-current literal `.`.
|
|
150
|
-
* @param values - Explicit values for this declaration, with no current-input reuse.
|
|
151
|
-
* @returns Router.parseUrl's result without navigating.
|
|
152
|
-
* @throws Synchronous URL validation, encoding or stringifier failures before Angular.
|
|
153
|
-
*/
|
|
154
|
-
link<Keys extends keyof SearchOf<Target> = never>(selector: ".", values: UrlValues<Target, Keys>): UrlTree;
|
|
199
|
+
link<Keys extends keyof SearchOf<Target> = never>(target: OwnLink<Target, Keys>): UrlTree;
|
|
155
200
|
/**
|
|
156
201
|
* Creates a UrlTree for a statically admitted absolute authored selector.
|
|
157
202
|
*
|
|
158
|
-
* @param
|
|
159
|
-
* @param values - The selected target's complete explicit values.
|
|
203
|
+
* @param target - `to`, a single known template literal, never a concrete URL, and the selected target's complete explicit values.
|
|
160
204
|
* @returns Router.parseUrl's result without navigating.
|
|
161
|
-
* @throws Synchronously for unknown selectors
|
|
205
|
+
* @throws Synchronously for unknown selectors, invalid URL values or a behavior option.
|
|
162
206
|
*/
|
|
163
|
-
link<const Selector extends keyof Absolute & string, Keys extends keyof SearchOf<NoInfer<Absolute[Selector]>> = never>(
|
|
207
|
+
link<const Selector extends keyof Absolute & string, Keys extends keyof SearchOf<NoInfer<Absolute[Selector]>> = never>(target: {
|
|
208
|
+
/** A single known absolute authored selector, never a concrete URL. */
|
|
209
|
+
readonly to: Selector & (IsUnion<Selector> extends true ? never : unknown);
|
|
210
|
+
} & UrlValues<NoInfer<Absolute[Selector]>, Keys>): UrlTree;
|
|
164
211
|
/**
|
|
165
212
|
* Creates a UrlTree for the parent route, when the bound declaration has one.
|
|
166
213
|
*
|
|
167
|
-
* @param
|
|
168
|
-
* @param values - The parent route's complete explicit values.
|
|
214
|
+
* @param target - `to: ".."` and the parent route's complete explicit values.
|
|
169
215
|
* @returns Router.parseUrl's result without navigating.
|
|
170
|
-
* @throws Synchronously for invalid URL values.
|
|
216
|
+
* @throws Synchronously for invalid URL values or a behavior option.
|
|
171
217
|
*/
|
|
172
|
-
link<Keys extends keyof SearchOf<Parent> = never>(
|
|
218
|
+
link<Keys extends keyof SearchOf<Parent> = never>(target: {
|
|
219
|
+
/** The parent route: the nearest ancestor with a shorter path, or the root. */
|
|
220
|
+
readonly to: [Parent] extends [never] ? never : "..";
|
|
221
|
+
} & UrlValues<Parent, Keys>): UrlTree;
|
|
173
222
|
/**
|
|
174
223
|
* Creates a UrlTree for a generated reference's own exact declaration.
|
|
175
224
|
*
|
|
176
|
-
* @param
|
|
177
|
-
* @param values - The referenced declaration's complete explicit values.
|
|
225
|
+
* @param target - `to`, a genuine destination exported by a facade in this route set, and the referenced declaration's complete explicit values.
|
|
178
226
|
* @returns Router.parseUrl's result without navigating.
|
|
179
|
-
* @throws Synchronously for foreign/fake references
|
|
227
|
+
* @throws Synchronously for foreign/fake references, invalid URL values or a behavior option.
|
|
180
228
|
*/
|
|
181
|
-
link<const Id extends keyof References & string, Keys extends keyof SearchOf<NoInfer<References[Id]>> = never>(
|
|
229
|
+
link<const Id extends keyof References & string, Keys extends keyof SearchOf<NoInfer<References[Id]>> = never>(target: {
|
|
230
|
+
/** A genuine destination exported by a facade in this route set. */
|
|
231
|
+
readonly to: Destination<NoInfer<References[Id]>, Set, Id> & (IsUnion<Id> extends true ? never : unknown);
|
|
232
|
+
} & UrlValues<NoInfer<References[Id]>, Keys>): UrlTree;
|
|
182
233
|
/**
|
|
183
|
-
* Navigates to this exact declaration via Router.navigateByUrl.
|
|
234
|
+
* Navigates to this exact declaration, not its pathless winner, via Router.navigateByUrl.
|
|
184
235
|
*
|
|
185
|
-
* @param
|
|
236
|
+
* @param target - No `to`; this declaration's explicit params/search and optional own fragment; and Angular's navigation behavior options.
|
|
186
237
|
* @returns Angular's identical Promise; Angular owns skips, redirects and failures.
|
|
187
238
|
* @throws Synchronous URL validation, encoding or stringifier failures before Angular.
|
|
188
239
|
*/
|
|
189
|
-
navigate<Keys extends keyof SearchOf<Target> = never>(
|
|
190
|
-
/**
|
|
191
|
-
* Navigates to the exact bound declaration, not its pathless winner.
|
|
192
|
-
*
|
|
193
|
-
* @param selector - The exact-current literal `.`.
|
|
194
|
-
* @param values - Explicit values for this declaration, with no current-input reuse.
|
|
195
|
-
* @returns Angular's identical Router.navigateByUrl Promise.
|
|
196
|
-
* @throws Synchronous URL validation, encoding or stringifier failures before Angular.
|
|
197
|
-
*/
|
|
198
|
-
navigate<Keys extends keyof SearchOf<Target> = never>(selector: ".", values: UrlValues<Target, Keys>): Promise<boolean>;
|
|
240
|
+
navigate<Keys extends keyof SearchOf<Target> = never>(target: OwnNavigation<Target, Keys>): Promise<boolean>;
|
|
199
241
|
/**
|
|
200
242
|
* Navigates to a statically admitted absolute authored selector.
|
|
201
243
|
*
|
|
202
|
-
* @param
|
|
203
|
-
* @param values - The selected target's complete explicit values.
|
|
244
|
+
* @param target - `to`, a single known template literal, never a concrete URL; the selected target's complete explicit values; and Angular's navigation behavior options.
|
|
204
245
|
* @returns Angular's identical Router.navigateByUrl Promise.
|
|
205
246
|
* @throws Synchronously for unknown selectors or invalid URL values.
|
|
206
247
|
*/
|
|
207
|
-
navigate<const Selector extends keyof Absolute & string, Keys extends keyof SearchOf<NoInfer<Absolute[Selector]>> = never>(
|
|
248
|
+
navigate<const Selector extends keyof Absolute & string, Keys extends keyof SearchOf<NoInfer<Absolute[Selector]>> = never>(target: {
|
|
249
|
+
/** A single known absolute authored selector, never a concrete URL. */
|
|
250
|
+
readonly to: Selector & (IsUnion<Selector> extends true ? never : unknown);
|
|
251
|
+
} & UrlValues<NoInfer<Absolute[Selector]>, Keys> & NavigationBehaviorOptions): Promise<boolean>;
|
|
208
252
|
/**
|
|
209
253
|
* Navigates to the parent route, when the bound declaration has one.
|
|
210
254
|
*
|
|
211
|
-
* @param
|
|
212
|
-
* @param values - The parent route's complete explicit values.
|
|
255
|
+
* @param target - `to: ".."`, the parent route's complete explicit values and Angular's navigation behavior options.
|
|
213
256
|
* @returns Angular's identical Router.navigateByUrl Promise.
|
|
214
257
|
* @throws Synchronously for invalid URL values.
|
|
215
258
|
*/
|
|
216
|
-
navigate<Keys extends keyof SearchOf<Parent> = never>(
|
|
259
|
+
navigate<Keys extends keyof SearchOf<Parent> = never>(target: {
|
|
260
|
+
/** The parent route: the nearest ancestor with a shorter path, or the root. */
|
|
261
|
+
readonly to: [Parent] extends [never] ? never : "..";
|
|
262
|
+
} & UrlValues<Parent, Keys> & NavigationBehaviorOptions): Promise<boolean>;
|
|
217
263
|
/**
|
|
218
264
|
* Navigates to a generated reference's own exact declaration.
|
|
219
265
|
*
|
|
220
|
-
* @param
|
|
221
|
-
* @param values - The referenced declaration's complete explicit values.
|
|
266
|
+
* @param target - `to`, a genuine destination exported by a facade in this route set; the referenced declaration's complete explicit values; and Angular's navigation behavior options.
|
|
222
267
|
* @returns Angular's identical Router.navigateByUrl Promise.
|
|
223
268
|
* @throws Synchronously for foreign/fake references or invalid URL values.
|
|
224
269
|
*/
|
|
225
|
-
navigate<const Id extends keyof References & string, Keys extends keyof SearchOf<NoInfer<References[Id]>> = never>(
|
|
270
|
+
navigate<const Id extends keyof References & string, Keys extends keyof SearchOf<NoInfer<References[Id]>> = never>(target: {
|
|
271
|
+
/** A genuine destination exported by a facade in this route set. */
|
|
272
|
+
readonly to: Destination<NoInfer<References[Id]>, Set, Id> & (IsUnion<Id> extends true ? never : unknown);
|
|
273
|
+
} & UrlValues<NoInfer<References[Id]>, Keys> & NavigationBehaviorOptions): Promise<boolean>;
|
|
226
274
|
}
|
|
227
275
|
export declare function nativeOptions(definition: AnyRoute): Record<string, unknown>;
|
|
228
276
|
export declare function injectGeneratedRoute<Target extends AnyRoute, Absolute extends Record<string, AnyRoute>, Parent extends AnyRoute, Set, References extends Record<string, AnyRoute>>(set: RouteSet, id: string): Handle<Target, Absolute, Parent, Set, References>;
|
|
277
|
+
/** A declaration's handle over the signals of one activated record. */
|
|
278
|
+
export declare function createHandle<Target extends AnyRoute, Absolute extends Record<string, AnyRoute>, Parent extends AnyRoute, Set, References extends Record<string, AnyRoute>>(set: RouteSet, id: string, router: Router, view: RouteView): Handle<Target, Absolute, Parent, Set, References>;
|
|
229
279
|
export type { RecordBinding, RouteSet };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { ParamCodec, Route, booleanParam, createUrl, defineRoute, enumParam, numberParam, stringParam, withFallback } from "@loozo/angular-router/_core";
|
|
2
|
-
export { type ParamCodec, type Route, booleanParam, createUrl, defineRoute, enumParam, numberParam, stringParam, withFallback };
|
|
1
|
+
import { ParamCodec, Route, arrayParam, booleanParam, createUrl, defineRoute, enumParam, numberParam, stringParam, withFallback } from "@loozo/angular-router/_core";
|
|
2
|
+
export { type ParamCodec, type Route, arrayParam, booleanParam, createUrl, defineRoute, enumParam, numberParam, stringParam, withFallback };
|