autotel-tanstack 1.13.30 → 1.13.31

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.
Files changed (150) hide show
  1. package/dist/auto.d.ts +8 -35
  2. package/dist/auto.d.ts.map +1 -0
  3. package/dist/auto.js +41 -22
  4. package/dist/auto.js.map +1 -1
  5. package/dist/browser/context.d.ts +50 -0
  6. package/dist/browser/context.d.ts.map +1 -0
  7. package/dist/browser/context.js +54 -2
  8. package/dist/browser/context.js.map +1 -1
  9. package/dist/browser/debug-headers.d.ts +10 -0
  10. package/dist/browser/debug-headers.d.ts.map +1 -0
  11. package/dist/browser/debug-headers.js +12 -2
  12. package/dist/browser/debug-headers.js.map +1 -1
  13. package/dist/browser/error-reporting.d.ts +39 -0
  14. package/dist/browser/error-reporting.d.ts.map +1 -0
  15. package/dist/browser/error-reporting.js +35 -2
  16. package/dist/browser/error-reporting.js.map +1 -1
  17. package/dist/browser/handlers.d.ts +14 -0
  18. package/dist/browser/handlers.d.ts.map +1 -0
  19. package/dist/browser/handlers.js +10 -2
  20. package/dist/browser/handlers.js.map +1 -1
  21. package/dist/browser/index.d.ts +11 -0
  22. package/dist/browser/index.js +12 -12
  23. package/dist/browser/loaders.d.ts +31 -0
  24. package/dist/browser/loaders.d.ts.map +1 -0
  25. package/dist/browser/loaders.js +29 -2
  26. package/dist/browser/loaders.js.map +1 -1
  27. package/dist/browser/metrics.d.ts +56 -0
  28. package/dist/browser/metrics.d.ts.map +1 -0
  29. package/dist/browser/metrics.js +48 -2
  30. package/dist/browser/metrics.js.map +1 -1
  31. package/dist/browser/middleware.d.ts +42 -0
  32. package/dist/browser/middleware.d.ts.map +1 -0
  33. package/dist/browser/middleware.js +36 -2
  34. package/dist/browser/middleware.js.map +1 -1
  35. package/dist/browser/server-functions.d.ts +14 -0
  36. package/dist/browser/server-functions.d.ts.map +1 -0
  37. package/dist/browser/server-functions.js +16 -2
  38. package/dist/browser/server-functions.js.map +1 -1
  39. package/dist/browser/testing.d.ts +85 -0
  40. package/dist/browser/testing.d.ts.map +1 -0
  41. package/dist/browser/testing.js +43 -2
  42. package/dist/browser/testing.js.map +1 -1
  43. package/dist/browser/types.d.ts +2 -0
  44. package/dist/browser/types.js +37 -2
  45. package/dist/browser/types.js.map +1 -1
  46. package/dist/context.d.ts +5 -3
  47. package/dist/context.d.ts.map +1 -0
  48. package/dist/context.js +112 -3
  49. package/dist/context.js.map +1 -1
  50. package/dist/debug-headers.d.ts +14 -14
  51. package/dist/debug-headers.d.ts.map +1 -0
  52. package/dist/debug-headers.js +62 -4
  53. package/dist/debug-headers.js.map +1 -1
  54. package/dist/env-BpFWNnpL.js +30 -0
  55. package/dist/env-BpFWNnpL.js.map +1 -0
  56. package/dist/error-reporting.d.ts +37 -37
  57. package/dist/error-reporting.d.ts.map +1 -0
  58. package/dist/error-reporting.js +154 -3
  59. package/dist/error-reporting.js.map +1 -1
  60. package/dist/handlers.d.ts +5 -4
  61. package/dist/handlers.d.ts.map +1 -0
  62. package/dist/handlers.js +192 -6
  63. package/dist/handlers.js.map +1 -1
  64. package/dist/index.d.ts +15 -16
  65. package/dist/index.d.ts.map +1 -0
  66. package/dist/index.js +14 -16
  67. package/dist/instrument-DS7YCE1R.d.ts +10 -0
  68. package/dist/instrument-DS7YCE1R.d.ts.map +1 -0
  69. package/dist/instrument-DdLlMfRi.js +80 -0
  70. package/dist/instrument-DdLlMfRi.js.map +1 -0
  71. package/dist/loaders-DrVVY25K.d.ts +2402 -0
  72. package/dist/loaders-DrVVY25K.d.ts.map +1 -0
  73. package/dist/loaders.d.ts +2 -116
  74. package/dist/loaders.js +234 -5
  75. package/dist/loaders.js.map +1 -1
  76. package/dist/metrics.d.ts +39 -39
  77. package/dist/metrics.d.ts.map +1 -0
  78. package/dist/metrics.js +144 -3
  79. package/dist/metrics.js.map +1 -1
  80. package/dist/middleware.d.ts +16 -15
  81. package/dist/middleware.d.ts.map +1 -0
  82. package/dist/middleware.js +290 -7
  83. package/dist/middleware.js.map +1 -1
  84. package/dist/route-filter-dLg-j3jR.js +33 -0
  85. package/dist/route-filter-dLg-j3jR.js.map +1 -0
  86. package/dist/server-functions.d.ts +4 -3
  87. package/dist/server-functions.d.ts.map +1 -0
  88. package/dist/server-functions.js +133 -5
  89. package/dist/server-functions.js.map +1 -1
  90. package/dist/testing.d.ts +164 -65
  91. package/dist/testing.d.ts.map +1 -0
  92. package/dist/testing.js +212 -147
  93. package/dist/testing.js.map +1 -1
  94. package/dist/types-BJ7FyVoX.d.ts +87 -0
  95. package/dist/types-BJ7FyVoX.d.ts.map +1 -0
  96. package/dist/types-BrccP0yX.js +38 -0
  97. package/dist/types-BrccP0yX.js.map +1 -0
  98. package/dist/types-pQgmQa4j.d.ts +154 -0
  99. package/dist/types-pQgmQa4j.d.ts.map +1 -0
  100. package/package.json +7 -7
  101. package/dist/browser/index.js.map +0 -1
  102. package/dist/chunk-7OXOAS64.js +0 -41
  103. package/dist/chunk-7OXOAS64.js.map +0 -1
  104. package/dist/chunk-A7WMQ2BC.js +0 -25
  105. package/dist/chunk-A7WMQ2BC.js.map +0 -1
  106. package/dist/chunk-CCME55EK.js +0 -28
  107. package/dist/chunk-CCME55EK.js.map +0 -1
  108. package/dist/chunk-CSFIPJC2.js +0 -11
  109. package/dist/chunk-CSFIPJC2.js.map +0 -1
  110. package/dist/chunk-DTZCOB4W.js +0 -32
  111. package/dist/chunk-DTZCOB4W.js.map +0 -1
  112. package/dist/chunk-EFSKEYDJ.js +0 -20
  113. package/dist/chunk-EFSKEYDJ.js.map +0 -1
  114. package/dist/chunk-EGRHWZRV.js +0 -3
  115. package/dist/chunk-EGRHWZRV.js.map +0 -1
  116. package/dist/chunk-ESU66L3L.js +0 -92
  117. package/dist/chunk-ESU66L3L.js.map +0 -1
  118. package/dist/chunk-EUYFVNYE.js +0 -16
  119. package/dist/chunk-EUYFVNYE.js.map +0 -1
  120. package/dist/chunk-FFQ4FJKE.js +0 -185
  121. package/dist/chunk-FFQ4FJKE.js.map +0 -1
  122. package/dist/chunk-G526TOMY.js +0 -96
  123. package/dist/chunk-G526TOMY.js.map +0 -1
  124. package/dist/chunk-I4LX3LOG.js +0 -35
  125. package/dist/chunk-I4LX3LOG.js.map +0 -1
  126. package/dist/chunk-JXO7H6KO.js +0 -10
  127. package/dist/chunk-JXO7H6KO.js.map +0 -1
  128. package/dist/chunk-KPXGFKPU.js +0 -193
  129. package/dist/chunk-KPXGFKPU.js.map +0 -1
  130. package/dist/chunk-LRA2UVVS.js +0 -210
  131. package/dist/chunk-LRA2UVVS.js.map +0 -1
  132. package/dist/chunk-MFYOV2SF.js +0 -32
  133. package/dist/chunk-MFYOV2SF.js.map +0 -1
  134. package/dist/chunk-MNP65ZX7.js +0 -21
  135. package/dist/chunk-MNP65ZX7.js.map +0 -1
  136. package/dist/chunk-NTY64BKS.js +0 -38
  137. package/dist/chunk-NTY64BKS.js.map +0 -1
  138. package/dist/chunk-UMEJU65Q.js +0 -34
  139. package/dist/chunk-UMEJU65Q.js.map +0 -1
  140. package/dist/chunk-UTPW3QRT.js +0 -52
  141. package/dist/chunk-UTPW3QRT.js.map +0 -1
  142. package/dist/chunk-V3RO5N2M.js +0 -8
  143. package/dist/chunk-V3RO5N2M.js.map +0 -1
  144. package/dist/chunk-XXBHZR3M.js +0 -99
  145. package/dist/chunk-XXBHZR3M.js.map +0 -1
  146. package/dist/chunk-YQYYPJCK.js +0 -37
  147. package/dist/chunk-YQYYPJCK.js.map +0 -1
  148. package/dist/index.js.map +0 -1
  149. package/dist/instrument-DRR7VL63.d.ts +0 -46
  150. package/dist/types-m5OjZJ-4.d.ts +0 -152
@@ -0,0 +1,2402 @@
1
+ import { i as TraceLoaderConfig } from "./types-pQgmQa4j.js";
2
+ import * as React$2 from "react";
3
+ import React$1 from "react";
4
+
5
+ //#region ../../node_modules/.pnpm/@tanstack+history@1.162.0/node_modules/@tanstack/history/dist/esm/index.d.ts
6
+ interface NavigateOptions$1 {
7
+ ignoreBlocker?: boolean;
8
+ }
9
+ type SubscriberHistoryAction = {
10
+ type: Exclude<HistoryAction, 'GO'>;
11
+ } | {
12
+ type: 'GO';
13
+ index: number;
14
+ };
15
+ type SubscriberArgs = {
16
+ location: HistoryLocation$1;
17
+ action: SubscriberHistoryAction;
18
+ };
19
+ interface RouterHistory {
20
+ location: HistoryLocation$1;
21
+ length: number;
22
+ subscribers: Set<(opts: SubscriberArgs) => void>;
23
+ subscribe: (cb: (opts: SubscriberArgs) => void) => () => void;
24
+ push: (path: string, state?: any, navigateOpts?: NavigateOptions$1) => void;
25
+ replace: (path: string, state?: any, navigateOpts?: NavigateOptions$1) => void;
26
+ go: (index: number, navigateOpts?: NavigateOptions$1) => void;
27
+ back: (navigateOpts?: NavigateOptions$1) => void;
28
+ forward: (navigateOpts?: NavigateOptions$1) => void;
29
+ canGoBack: () => boolean;
30
+ createHref: (href: string) => string;
31
+ block: (blocker: NavigationBlocker) => () => void;
32
+ flush: () => void;
33
+ destroy: () => void;
34
+ notify: (action: SubscriberHistoryAction) => void;
35
+ _ignoreSubscribers?: boolean;
36
+ }
37
+ interface HistoryLocation$1 extends ParsedPath {
38
+ state: ParsedHistoryState;
39
+ }
40
+ interface ParsedPath {
41
+ href: string;
42
+ pathname: string;
43
+ search: string;
44
+ hash: string;
45
+ }
46
+ interface HistoryState {}
47
+ type ParsedHistoryState = HistoryState & {
48
+ key?: string;
49
+ __TSR_key?: string;
50
+ __TSR_index: number;
51
+ };
52
+ type ShouldAllowNavigation = any;
53
+ type HistoryAction = 'PUSH' | 'REPLACE' | 'FORWARD' | 'BACK' | 'GO';
54
+ type BlockerFnArgs = {
55
+ currentLocation: HistoryLocation$1;
56
+ nextLocation: HistoryLocation$1;
57
+ action: HistoryAction;
58
+ };
59
+ type BlockerFn = (args: BlockerFnArgs) => Promise<ShouldAllowNavigation> | ShouldAllowNavigation;
60
+ type NavigationBlocker = {
61
+ blockerFn: BlockerFn;
62
+ enableBeforeUnload?: (() => boolean) | boolean;
63
+ };
64
+ //#endregion
65
+ //#region ../../node_modules/.pnpm/@tanstack+router-core@1.171.13/node_modules/@tanstack/router-core/dist/esm/fileRoute.d.ts
66
+ interface FileRouteTypes {
67
+ fileRoutesByFullPath: any;
68
+ fullPaths: any;
69
+ to: any;
70
+ fileRoutesByTo: any;
71
+ id: any;
72
+ fileRoutesById: any;
73
+ }
74
+ type InferFileRouteTypes<TRouteTree extends AnyRoute> = unknown extends TRouteTree['types']['fileRouteTypes'] ? never : TRouteTree['types']['fileRouteTypes'] extends FileRouteTypes ? TRouteTree['types']['fileRouteTypes'] : never;
75
+ type LazyRouteOptions = Pick<UpdatableRouteOptions<AnyRoute, string, string, AnyPathParams, AnyValidator, {}, AnyContext, AnyContext, AnyContext, AnyContext>, 'component' | 'errorComponent' | 'pendingComponent' | 'notFoundComponent'>;
76
+ interface LazyRoute<in out TRoute extends AnyRoute> {
77
+ options: {
78
+ id: string;
79
+ } & LazyRouteOptions;
80
+ }
81
+ //#endregion
82
+ //#region ../../node_modules/.pnpm/@tanstack+router-core@1.171.13/node_modules/@tanstack/router-core/dist/esm/utils.d.ts
83
+ type Awaitable<T> = T | Promise<T>;
84
+ type NoInfer<T> = [T][T extends any ? 0 : never];
85
+ type PickAsRequired<TValue, TKey extends keyof TValue> = Omit<TValue, TKey> & Required<Pick<TValue, TKey>>;
86
+ type Expand<T> = T extends object ? T extends infer O ? O extends Function ? O : { [K in keyof O]: O[K] } : never : T;
87
+ type MakeDifferenceOptional<TLeft, TRight> = keyof TLeft & keyof TRight extends never ? TRight : Omit<TRight, keyof TLeft & keyof TRight> & { [K in keyof TLeft & keyof TRight]?: TRight[K] };
88
+ type IsNonEmptyObject<T> = T extends object ? keyof T extends never ? false : true : false;
89
+ type Assign<TLeft, TRight> = TLeft extends any ? TRight extends any ? IsNonEmptyObject<TLeft> extends false ? TRight : IsNonEmptyObject<TRight> extends false ? TLeft : keyof TLeft & keyof TRight extends never ? TLeft & TRight : Omit<TLeft, keyof TRight> & TRight : never : never;
90
+ type IntersectAssign<TLeft, TRight> = TLeft extends any ? TRight extends any ? IsNonEmptyObject<TLeft> extends false ? TRight : IsNonEmptyObject<TRight> extends false ? TLeft : TRight & TLeft : never : never;
91
+ type Updater<TPrevious, TResult = TPrevious> = TResult | ((prev?: TPrevious) => TResult);
92
+ type NonNullableUpdater<TPrevious, TResult = TPrevious> = TResult | ((prev: TPrevious) => TResult);
93
+ type ExtractObjects<TUnion> = TUnion extends MergeAllPrimitive ? never : TUnion;
94
+ type PartialMergeAllObject<TUnion> = ExtractObjects<TUnion> extends infer TObj ? [TObj] extends [never] ? never : { [TKey in TObj extends any ? keyof TObj : never]?: TObj extends any ? TKey extends keyof TObj ? TObj[TKey] : never : never } : never;
95
+ type MergeAllPrimitive = ReadonlyArray<any> | number | string | bigint | boolean | symbol | undefined | null;
96
+ type ExtractPrimitives<TUnion> = TUnion extends MergeAllPrimitive ? TUnion : TUnion extends object ? never : TUnion;
97
+ type PartialMergeAll<TUnion> = ExtractPrimitives<TUnion> | PartialMergeAllObject<TUnion>;
98
+ type Constrain<T, TConstraint, TDefault = TConstraint> = (T extends TConstraint ? T : never) | TDefault;
99
+ type ConstrainLiteral<T, TConstraint, TDefault = TConstraint> = (T & TConstraint) | TDefault;
100
+ type ValidateJSON<T> = ((...args: Array<any>) => any) extends T ? unknown extends T ? never : 'Function is not serializable' : { [K in keyof T]: ValidateJSON<T[K]> };
101
+ type LooseReturnType<T> = T extends ((...args: Array<any>) => infer TReturn) ? TReturn : never;
102
+ type LooseAsyncReturnType<T> = T extends ((...args: Array<any>) => infer TReturn) ? TReturn extends Promise<infer TReturn> ? TReturn : TReturn : never;
103
+ type ControlledPromise<T> = Promise<T> & {
104
+ resolve: (value: T) => void;
105
+ reject: (value: any) => void;
106
+ status: 'pending' | 'resolved' | 'rejected';
107
+ value?: T;
108
+ };
109
+ //#endregion
110
+ //#region ../../node_modules/.pnpm/@tanstack+router-core@1.171.13/node_modules/@tanstack/router-core/dist/esm/link.d.ts
111
+ type IsRequiredParams<TParams> = Record<never, never> extends TParams ? never : true;
112
+ interface ParsePathParamsResult<in out TRequired, in out TOptional, in out TRest> {
113
+ required: TRequired;
114
+ optional: TOptional;
115
+ rest: TRest;
116
+ }
117
+ type ParsePathParamsBoundaryStart<T extends string> = T extends `${infer TLeft}{-${infer TRight}` ? ParsePathParamsResult<ParsePathParams<TLeft>['required'], ParsePathParams<TLeft>['optional'] | ParsePathParams<TRight>['required'] | ParsePathParams<TRight>['optional'], ParsePathParams<TRight>['rest']> : T extends `${infer TLeft}{${infer TRight}` ? ParsePathParamsResult<ParsePathParams<TLeft>['required'] | ParsePathParams<TRight>['required'], ParsePathParams<TLeft>['optional'] | ParsePathParams<TRight>['optional'], ParsePathParams<TRight>['rest']> : never;
118
+ type ParsePathParamsSymbol<T extends string> = T extends `${string}$${infer TRight}` ? TRight extends `${string}/${string}` ? TRight extends `${infer TParam}/${infer TRest}` ? TParam extends '' ? ParsePathParamsResult<ParsePathParams<TRest>['required'], '_splat' | ParsePathParams<TRest>['optional'], ParsePathParams<TRest>['rest']> : ParsePathParamsResult<TParam | ParsePathParams<TRest>['required'], ParsePathParams<TRest>['optional'], ParsePathParams<TRest>['rest']> : never : TRight extends '' ? ParsePathParamsResult<never, '_splat', never> : ParsePathParamsResult<TRight, never, never> : never;
119
+ type ParsePathParamsBoundaryEnd<T extends string> = T extends `${infer TLeft}}${infer TRight}` ? ParsePathParamsResult<ParsePathParams<TLeft>['required'] | ParsePathParams<TRight>['required'], ParsePathParams<TLeft>['optional'] | ParsePathParams<TRight>['optional'], ParsePathParams<TRight>['rest']> : never;
120
+ type ParsePathParamsEscapeStart<T extends string> = T extends `${infer TLeft}[${infer TRight}` ? ParsePathParamsResult<ParsePathParams<TLeft>['required'] | ParsePathParams<TRight>['required'], ParsePathParams<TLeft>['optional'] | ParsePathParams<TRight>['optional'], ParsePathParams<TRight>['rest']> : never;
121
+ type ParsePathParamsEscapeEnd<T extends string> = T extends `${string}]${infer TRight}` ? ParsePathParams<TRight> : never;
122
+ type ParsePathParams<T extends string> = T extends `${string}[${string}` ? ParsePathParamsEscapeStart<T> : T extends `${string}]${string}` ? ParsePathParamsEscapeEnd<T> : T extends `${string}}${string}` ? ParsePathParamsBoundaryEnd<T> : T extends `${string}{${string}` ? ParsePathParamsBoundaryStart<T> : T extends `${string}$${string}` ? ParsePathParamsSymbol<T> : never;
123
+ type AddTrailingSlash<T> = T extends `${string}/` ? T : `${T & string}/`;
124
+ type RemoveTrailingSlashes<T> = T & `${string}/` extends never ? T : T extends `${infer R}/` ? R : T;
125
+ type AddLeadingSlash<T> = T & `/${string}` extends never ? `/${T & string}` : T;
126
+ type RemoveLeadingSlashes<T> = T & `/${string}` extends never ? T : T extends `/${infer R}` ? R : T;
127
+ type JoinPath<TLeft extends string, TRight extends string> = TRight extends '' ? TLeft : TLeft extends '' ? TRight : `${RemoveTrailingSlashes<TLeft>}/${RemoveLeadingSlashes<TRight>}`;
128
+ type RemoveLastSegment<T extends string, TAcc extends string = ''> = T extends `${infer TSegment}/${infer TRest}` ? TRest & `${string}/${string}` extends never ? TRest extends '' ? TAcc : `${TAcc}${TSegment}` : RemoveLastSegment<TRest, `${TAcc}${TSegment}/`> : TAcc;
129
+ type ResolveCurrentPath<TFrom extends string, TTo extends string> = TTo extends '.' ? TFrom : TTo extends './' ? AddTrailingSlash<TFrom> : TTo & `./${string}` extends never ? never : TTo extends `./${infer TRest}` ? AddLeadingSlash<JoinPath<TFrom, TRest>> : never;
130
+ type ResolveParentPath<TFrom extends string, TTo extends string> = TTo extends '../' | '..' ? TFrom extends '' | '/' ? never : AddLeadingSlash<RemoveLastSegment<TFrom>> : TTo & `../${string}` extends never ? AddLeadingSlash<JoinPath<TFrom, TTo>> : TFrom extends '' | '/' ? never : TTo extends `../${infer ToRest}` ? ResolveParentPath<RemoveLastSegment<TFrom>, ToRest> : AddLeadingSlash<JoinPath<TFrom, TTo>>;
131
+ type ResolveRelativePath<TFrom, TTo = '.'> = string extends TFrom ? TTo : string extends TTo ? TFrom : undefined extends TTo ? TFrom : TTo extends string ? TFrom extends string ? TTo extends `/${string}` ? TTo : TTo extends `..${string}` ? ResolveParentPath<TFrom, TTo> : TTo extends `.${string}` ? ResolveCurrentPath<TFrom, TTo> : AddLeadingSlash<JoinPath<TFrom, TTo>> : never : never;
132
+ type FindDescendantToPaths<TRouter extends AnyRouter, TPrefix extends string> = `${TPrefix}/${string}` & RouteToPath<TRouter>;
133
+ type InferDescendantToPaths<TRouter extends AnyRouter, TPrefix extends string, TPaths = FindDescendantToPaths<TRouter, TPrefix>> = TPaths extends `${TPrefix}/` ? never : TPaths extends `${TPrefix}/${infer TRest}` ? TRest : never;
134
+ type RelativeToPath<TRouter extends AnyRouter, TTo extends string, TResolvedPath extends string> = (TResolvedPath & RouteToPath<TRouter> extends never ? never : ToPath<TRouter, TTo>) | `${RemoveTrailingSlashes<TTo>}/${InferDescendantToPaths<TRouter, RemoveTrailingSlashes<TResolvedPath>>}`;
135
+ type RelativeToParentPath<TRouter extends AnyRouter, TFrom extends string, TTo extends string, TResolvedPath extends string = ResolveRelativePath<TFrom, TTo>> = RelativeToPath<TRouter, TTo, TResolvedPath> | (TTo extends `${string}..` | `${string}../` ? TResolvedPath extends '/' | '' ? never : FindDescendantToPaths<TRouter, RemoveTrailingSlashes<TResolvedPath>> extends never ? never : `${RemoveTrailingSlashes<TTo>}/${ParentPath<TRouter>}` : never);
136
+ type RelativeToCurrentPath<TRouter extends AnyRouter, TFrom extends string, TTo extends string, TResolvedPath extends string = ResolveRelativePath<TFrom, TTo>> = RelativeToPath<TRouter, TTo, TResolvedPath> | CurrentPath<TRouter>;
137
+ type AbsoluteToPath<TRouter extends AnyRouter, TFrom extends string> = (string extends TFrom ? CurrentPath<TRouter> : TFrom extends `/` ? never : CurrentPath<TRouter>) | (string extends TFrom ? ParentPath<TRouter> : TFrom extends `/` ? never : ParentPath<TRouter>) | RouteToPath<TRouter> | (TFrom extends '/' ? never : string extends TFrom ? never : InferDescendantToPaths<TRouter, RemoveTrailingSlashes<TFrom>>);
138
+ type RelativeToPathAutoComplete<TRouter extends AnyRouter, TFrom extends string, TTo extends string> = string extends TTo ? string : string extends TFrom ? AbsoluteToPath<TRouter, TFrom> : TTo & `..${string}` extends never ? TTo & `.${string}` extends never ? AbsoluteToPath<TRouter, TFrom> : RelativeToCurrentPath<TRouter, TFrom, TTo> : RelativeToParentPath<TRouter, TFrom, TTo>;
139
+ type NavigateOptions<TRouter extends AnyRouter = RegisteredRouter, TFrom extends string = string, TTo extends string | undefined = '.', TMaskFrom extends string = TFrom, TMaskTo extends string = '.'> = ToOptions<TRouter, TFrom, TTo, TMaskFrom, TMaskTo> & NavigateOptionProps;
140
+ /**
141
+ * The NavigateOptions type is used to describe the options that can be used when describing a navigation action in TanStack Router.
142
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/NavigateOptionsType)
143
+ */
144
+ interface NavigateOptionProps {
145
+ /**
146
+ * If set to `true`, the router will scroll the element with an id matching the hash into view with default `ScrollIntoViewOptions`.
147
+ * If set to `false`, the router will not scroll the element with an id matching the hash into view.
148
+ * If set to `ScrollIntoViewOptions`, the router will scroll the element with an id matching the hash into view with the provided options.
149
+ * @default true
150
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/NavigateOptionsType#hashscrollintoview)
151
+ * @see [MDN](https://developer.mozilla.org/en-US/docs/Web/API/Element/scrollIntoView)
152
+ */
153
+ hashScrollIntoView?: boolean | ScrollIntoViewOptions;
154
+ /**
155
+ * `replace` is a boolean that determines whether the navigation should replace the current history entry or push a new one.
156
+ * @default false
157
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/NavigateOptionsType#replace)
158
+ */
159
+ replace?: boolean;
160
+ /**
161
+ * Defaults to `true` so that the scroll position will be reset to 0,0 after the location is committed to the browser history.
162
+ * If `false`, the scroll position will not be reset to 0,0 after the location is committed to history.
163
+ * @default true
164
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/NavigateOptionsType#resetscroll)
165
+ */
166
+ resetScroll?: boolean;
167
+ /** @deprecated All navigations now use startTransition under the hood */
168
+ startTransition?: boolean;
169
+ /**
170
+ * If set to `true`, the router will wrap the resulting navigation in a `document.startViewTransition()` call.
171
+ * If `ViewTransitionOptions`, route navigations will be called using `document.startViewTransition({update, types})`
172
+ * where `types` will be the strings array passed with `ViewTransitionOptions["types"]`.
173
+ * If the browser does not support viewTransition types, the navigation will fall back to normal `document.startTransition()`, same as if `true` was passed.
174
+ *
175
+ * If the browser does not support this api, this option will be ignored.
176
+ * @default false
177
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/NavigateOptionsType#viewtransition)
178
+ * @see [MDN](https://developer.mozilla.org/en-US/docs/Web/API/Document/startViewTransition)
179
+ * @see [Google](https://developer.chrome.com/docs/web-platform/view-transitions/same-document#view-transition-types)
180
+ */
181
+ viewTransition?: boolean | ViewTransitionOptions;
182
+ /**
183
+ * If `true`, navigation will ignore any blockers that might prevent it.
184
+ * @default false
185
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/NavigateOptionsType#ignoreblocker)
186
+ */
187
+ ignoreBlocker?: boolean;
188
+ /**
189
+ * If `true`, navigation to a route inside of router will trigger a full page load instead of the traditional SPA navigation.
190
+ * @default false
191
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/NavigateOptionsType#reloaddocument)
192
+ */
193
+ reloadDocument?: boolean;
194
+ /**
195
+ * This can be used instead of `to` to navigate to a fully built href, e.g. pointing to an external target.
196
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/NavigateOptionsType#href)
197
+ */
198
+ href?: string;
199
+ }
200
+ type ToOptions<TRouter extends AnyRouter = RegisteredRouter, TFrom extends string = string, TTo extends string | undefined = '.', TMaskFrom extends string = TFrom, TMaskTo extends string = '.'> = ToSubOptions<TRouter, TFrom, TTo> & MaskOptions<TRouter, TMaskFrom, TMaskTo>;
201
+ interface MaskOptions<in out TRouter extends AnyRouter, in out TMaskFrom extends string, in out TMaskTo extends string> {
202
+ _fromLocation?: ParsedLocation;
203
+ mask?: ToMaskOptions<TRouter, TMaskFrom, TMaskTo>;
204
+ }
205
+ type ToMaskOptions<TRouter extends AnyRouter = RegisteredRouter, TMaskFrom extends string = string, TMaskTo extends string = '.'> = ToSubOptions<TRouter, TMaskFrom, TMaskTo> & {
206
+ unmaskOnReload?: boolean;
207
+ };
208
+ type ToSubOptions<TRouter extends AnyRouter = RegisteredRouter, TFrom extends string = string, TTo extends string | undefined = '.'> = ToSubOptionsProps<TRouter, TFrom, TTo> & SearchParamOptions<TRouter, TFrom, TTo> & PathParamOptions<TRouter, TFrom, TTo>;
209
+ interface RequiredToOptions<in out TRouter extends AnyRouter, in out TFrom extends string, in out TTo extends string | undefined> {
210
+ /**
211
+ * The internal route path to navigate to. This should be a relative or absolute path within your application.
212
+ * For external URLs, use the `href` property instead.
213
+ * @example "/dashboard" or "../profile"
214
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/NavigateOptionsType#href)
215
+ */
216
+ to: ToPathOption<TRouter, TFrom, TTo> & {};
217
+ }
218
+ interface OptionalToOptions<in out TRouter extends AnyRouter, in out TFrom extends string, in out TTo extends string | undefined> {
219
+ /**
220
+ * The internal route path to navigate to. This should be a relative or absolute path within your application.
221
+ * For external URLs, use the `href` property instead.
222
+ * @example "/dashboard" or "../profile"
223
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/NavigateOptionsType#href)
224
+ */
225
+ to?: ToPathOption<TRouter, TFrom, TTo> & {};
226
+ }
227
+ type MakeToRequired<TRouter extends AnyRouter, TFrom extends string, TTo extends string | undefined> = string extends TFrom ? string extends TTo ? OptionalToOptions<TRouter, TFrom, TTo> : TTo & CatchAllPaths<TRouter> extends never ? RequiredToOptions<TRouter, TFrom, TTo> : OptionalToOptions<TRouter, TFrom, TTo> : OptionalToOptions<TRouter, TFrom, TTo>;
228
+ type ToSubOptionsProps<TRouter extends AnyRouter = RegisteredRouter, TFrom extends RoutePaths<TRouter['routeTree']> | string = string, TTo extends string | undefined = '.'> = MakeToRequired<TRouter, TFrom, TTo> & {
229
+ hash?: true | Updater<string>;
230
+ state?: true | NonNullableUpdater<ParsedHistoryState, HistoryState>;
231
+ from?: FromPathOption<TRouter, TFrom> & {};
232
+ unsafeRelative?: 'path';
233
+ };
234
+ type ParamsReducerFn<in out TRouter extends AnyRouter, in out TParamVariant extends ParamVariant, in out TFrom, in out TTo> = (current: Expand<ResolveFromParams<TRouter, TParamVariant, TFrom>>) => Expand<ResolveRelativeToParams<TRouter, TParamVariant, TFrom, TTo>>;
235
+ type ParamsReducer<TRouter extends AnyRouter, TParamVariant extends ParamVariant, TFrom, TTo> = Expand<ResolveRelativeToParams<TRouter, TParamVariant, TFrom, TTo>> | (ParamsReducerFn<TRouter, TParamVariant, TFrom, TTo> & {});
236
+ type ParamVariant = 'PATH' | 'SEARCH';
237
+ type ResolveRoute<TRouter extends AnyRouter, TFrom, TTo, TPath = ResolveRelativePath<TFrom, TTo>> = TPath extends string ? TFrom extends TPath ? RouteByPath<TRouter['routeTree'], TPath> : RouteByToPath<TRouter, TPath> : never;
238
+ type ResolveFromParamType<TParamVariant extends ParamVariant> = TParamVariant extends 'PATH' ? 'allParams' : 'fullSearchSchema';
239
+ type ResolveFromAllParams<TRouter extends AnyRouter, TParamVariant extends ParamVariant> = TParamVariant extends 'PATH' ? AllParams<TRouter['routeTree']> : FullSearchSchema<TRouter['routeTree']>;
240
+ type ResolveFromParams<TRouter extends AnyRouter, TParamVariant extends ParamVariant, TFrom> = string extends TFrom ? ResolveFromAllParams<TRouter, TParamVariant> : RouteByPath<TRouter['routeTree'], TFrom>['types'][ResolveFromParamType<TParamVariant>];
241
+ type ResolveToParamType<TParamVariant extends ParamVariant> = TParamVariant extends 'PATH' ? 'allParams' : 'fullSearchSchemaInput';
242
+ type ResolveAllToParams<TRouter extends AnyRouter, TParamVariant extends ParamVariant> = TParamVariant extends 'PATH' ? AllParams<TRouter['routeTree']> : FullSearchSchemaInput<TRouter['routeTree']>;
243
+ type ResolveToParams<TRouter extends AnyRouter, TParamVariant extends ParamVariant, TFrom, TTo> = ResolveRelativePath<TFrom, TTo> extends infer TPath ? undefined extends TPath ? never : string extends TPath ? ResolveAllToParams<TRouter, TParamVariant> : TPath extends CatchAllPaths<TRouter> ? ResolveAllToParams<TRouter, TParamVariant> : ResolveRoute<TRouter, TFrom, TTo>['types'][ResolveToParamType<TParamVariant>] : never;
244
+ type ResolveRelativeToParams<TRouter extends AnyRouter, TParamVariant extends ParamVariant, TFrom, TTo, TToParams = ResolveToParams<TRouter, TParamVariant, TFrom, TTo>> = TParamVariant extends 'SEARCH' ? TToParams : string extends TFrom ? TToParams : MakeDifferenceOptional<ResolveFromParams<TRouter, TParamVariant, TFrom>, TToParams>;
245
+ interface MakeOptionalSearchParams<in out TRouter extends AnyRouter, in out TFrom, in out TTo> {
246
+ search?: true | (ParamsReducer<TRouter, 'SEARCH', TFrom, TTo> & {});
247
+ }
248
+ interface MakeOptionalPathParams<in out TRouter extends AnyRouter, in out TFrom, in out TTo> {
249
+ params?: true | (ParamsReducer<TRouter, 'PATH', TFrom, TTo> & {});
250
+ }
251
+ type MakeRequiredParamsReducer<TRouter extends AnyRouter, TParamVariant extends ParamVariant, TFrom, TTo> = (string extends TFrom ? never : ResolveFromParams<TRouter, TParamVariant, TFrom> extends ResolveRelativeToParams<TRouter, TParamVariant, TFrom, TTo> ? true : never) | (ParamsReducer<TRouter, TParamVariant, TFrom, TTo> & {});
252
+ interface MakeRequiredPathParams<in out TRouter extends AnyRouter, in out TFrom, in out TTo> {
253
+ params: MakeRequiredParamsReducer<TRouter, 'PATH', TFrom, TTo> & {};
254
+ }
255
+ interface MakeRequiredSearchParams<in out TRouter extends AnyRouter, in out TFrom, in out TTo> {
256
+ search: MakeRequiredParamsReducer<TRouter, 'SEARCH', TFrom, TTo> & {};
257
+ }
258
+ type IsRequired<TRouter extends AnyRouter, TParamVariant extends ParamVariant, TFrom, TTo> = ResolveRelativePath<TFrom, TTo> extends infer TPath ? undefined extends TPath ? never : TPath extends CatchAllPaths<TRouter> ? never : IsRequiredParams<ResolveRelativeToParams<TRouter, TParamVariant, TFrom, TTo>> : never;
259
+ type SearchParamOptions<TRouter extends AnyRouter, TFrom, TTo> = IsRequired<TRouter, 'SEARCH', TFrom, TTo> extends never ? MakeOptionalSearchParams<TRouter, TFrom, TTo> : MakeRequiredSearchParams<TRouter, TFrom, TTo>;
260
+ type PathParamOptions<TRouter extends AnyRouter, TFrom, TTo> = IsRequired<TRouter, 'PATH', TFrom, TTo> extends never ? MakeOptionalPathParams<TRouter, TFrom, TTo> : MakeRequiredPathParams<TRouter, TFrom, TTo>;
261
+ type ToPathOption<TRouter extends AnyRouter = AnyRouter, TFrom extends string = string, TTo extends string | undefined = string> = ConstrainLiteral<TTo, RelativeToPathAutoComplete<TRouter, NoInfer<TFrom> extends string ? NoInfer<TFrom> : '', NoInfer<TTo> & string>>;
262
+ type FromPathOption<TRouter extends AnyRouter, TFrom> = ConstrainLiteral<TFrom, RoutePaths<TRouter['routeTree']>>;
263
+ /**
264
+ * @link [Guide](https://tanstack.com/router/latest/docs/framework/react/guide/navigation#active-options)
265
+ */
266
+ interface ActiveOptions {
267
+ /**
268
+ * If true, the link will be active if the current route matches the `to` route path exactly (no children routes)
269
+ * @default false
270
+ */
271
+ exact?: boolean;
272
+ /**
273
+ * If true, the link will only be active if the current URL hash matches the `hash` prop
274
+ * @default false
275
+ */
276
+ includeHash?: boolean;
277
+ /**
278
+ * If true, the link will only be active if the current URL search params inclusively match the `search` prop
279
+ * @default true
280
+ */
281
+ includeSearch?: boolean;
282
+ /**
283
+ * This modifies the `includeSearch` behavior.
284
+ * If true, properties in `search` that are explicitly `undefined` must NOT be present in the current URL search params for the link to be active.
285
+ * @default false
286
+ */
287
+ explicitUndefined?: boolean;
288
+ }
289
+ interface LinkOptionsProps {
290
+ /**
291
+ * The standard anchor tag target attribute
292
+ */
293
+ target?: HTMLAnchorElement['target'];
294
+ /**
295
+ * Configurable options to determine if the link should be considered active or not
296
+ * @default {exact:true,includeHash:true}
297
+ */
298
+ activeOptions?: ActiveOptions;
299
+ /**
300
+ * The preloading strategy for this link
301
+ * - `false` - No preloading
302
+ * - `'intent'` - Preload the linked route on hover and cache it for this many milliseconds in hopes that the user will eventually navigate there.
303
+ * - `'viewport'` - Preload the linked route when it enters the viewport
304
+ */
305
+ preload?: false | 'intent' | 'viewport' | 'render';
306
+ /**
307
+ * When a preload strategy is set, this delays the preload by this many milliseconds.
308
+ * If the user exits the link before this delay, the preload will be cancelled.
309
+ */
310
+ preloadDelay?: number;
311
+ /**
312
+ * Control whether the link should be disabled or not
313
+ * If set to `true`, the link will be rendered without an `href` attribute
314
+ * @default false
315
+ */
316
+ disabled?: boolean;
317
+ /**
318
+ * When the preload strategy is set to `intent`, this controls the proximity of the link to the cursor before it is preloaded.
319
+ * If the user exits this proximity before this delay, the preload will be cancelled.
320
+ */
321
+ preloadIntentProximity?: number;
322
+ }
323
+ type LinkOptions<TRouter extends AnyRouter = RegisteredRouter, TFrom extends string = string, TTo extends string | undefined = '.', TMaskFrom extends string = TFrom, TMaskTo extends string = '.'> = NavigateOptions<TRouter, TFrom, TTo, TMaskFrom, TMaskTo> & LinkOptionsProps;
324
+ //#endregion
325
+ //#region ../../node_modules/.pnpm/@tanstack+router-core@1.171.13/node_modules/@tanstack/router-core/dist/esm/routeInfo.d.ts
326
+ type ParseRoute<TRouteTree, TAcc = TRouteTree> = TRouteTree extends {
327
+ types: {
328
+ children: infer TChildren;
329
+ };
330
+ } ? unknown extends TChildren ? TAcc : TChildren extends ReadonlyArray<any> ? ParseRoute<TChildren[number], TAcc | TChildren[number]> : ParseRoute<TChildren[keyof TChildren], TAcc | TChildren[keyof TChildren]> : TAcc;
331
+ type ParseRouteWithoutBranches<TRouteTree> = ParseRoute<TRouteTree> extends infer TRoute extends AnyRoute ? TRoute extends any ? unknown extends TRoute['types']['children'] ? TRoute : TRoute['types']['children'] extends ReadonlyArray<any> ? '/' extends TRoute['types']['children'][number]['path'] ? never : TRoute : '/' extends TRoute['types']['children'][keyof TRoute['types']['children']]['path'] ? never : TRoute : never : never;
332
+ type CodeRoutesById<TRouteTree extends AnyRoute> = ParseRoute<TRouteTree> extends infer TRoutes extends AnyRoute ? { [K in TRoutes as K['id']]: K } : never;
333
+ type RoutesById<TRouteTree extends AnyRoute> = InferFileRouteTypes<TRouteTree> extends never ? CodeRoutesById<TRouteTree> : InferFileRouteTypes<TRouteTree>['fileRoutesById'];
334
+ type RouteById<TRouteTree extends AnyRoute, TId> = Extract<RoutesById<TRouteTree>[TId & keyof RoutesById<TRouteTree>], AnyRoute>;
335
+ type CodeRouteIds<TRouteTree extends AnyRoute> = ParseRoute<TRouteTree> extends infer TRoutes extends AnyRoute ? TRoutes['id'] : never;
336
+ type RouteIds<TRouteTree extends AnyRoute> = InferFileRouteTypes<TRouteTree> extends never ? CodeRouteIds<TRouteTree> : InferFileRouteTypes<TRouteTree>['id'];
337
+ type ParentPath<TRouter extends AnyRouter> = TrailingSlashOptionByRouter<TRouter> extends 'always' ? '../' : TrailingSlashOptionByRouter<TRouter> extends 'never' ? '..' : '../' | '..';
338
+ type CurrentPath<TRouter extends AnyRouter> = TrailingSlashOptionByRouter<TRouter> extends 'always' ? './' : TrailingSlashOptionByRouter<TRouter> extends 'never' ? '.' : './' | '.';
339
+ type ToPath<TRouter extends AnyRouter, TTo extends string> = TrailingSlashOptionByRouter<TRouter> extends 'always' ? AddTrailingSlash<TTo> : TrailingSlashOptionByRouter<TRouter> extends 'never' ? RemoveTrailingSlashes<TTo> : AddTrailingSlash<TTo> | RemoveTrailingSlashes<TTo>;
340
+ type CatchAllPaths<TRouter extends AnyRouter> = CurrentPath<TRouter> | ParentPath<TRouter>;
341
+ type CodeRoutesByPath<TRouteTree extends AnyRoute> = ParseRoute<TRouteTree> extends infer TRoutes extends AnyRoute ? { [K in TRoutes as K['fullPath']]: K } : never;
342
+ type RoutesByPath<TRouteTree extends AnyRoute> = InferFileRouteTypes<TRouteTree> extends never ? CodeRoutesByPath<TRouteTree> : InferFileRouteTypes<TRouteTree>['fileRoutesByFullPath'];
343
+ type RouteByPath<TRouteTree extends AnyRoute, TPath> = Extract<RoutesByPath<TRouteTree>[TPath & keyof RoutesByPath<TRouteTree>], AnyRoute>;
344
+ type CodeRoutePaths<TRouteTree extends AnyRoute> = ParseRoute<TRouteTree> extends infer TRoutes extends AnyRoute ? TRoutes['fullPath'] : never;
345
+ type RoutePaths<TRouteTree extends AnyRoute> = unknown extends TRouteTree ? string : (InferFileRouteTypes<TRouteTree> extends never ? CodeRoutePaths<TRouteTree> : InferFileRouteTypes<TRouteTree>['fullPaths']) | '/';
346
+ type RouteToPathAlwaysTrailingSlash<TRoute extends AnyRoute> = TRoute['path'] extends '/' ? TRoute['fullPath'] : TRoute['fullPath'] extends '/' ? TRoute['fullPath'] : `${TRoute['fullPath']}/`;
347
+ type RouteToPathNeverTrailingSlash<TRoute extends AnyRoute> = TRoute['path'] extends '/' ? TRoute['fullPath'] extends '/' ? TRoute['fullPath'] : RemoveTrailingSlashes<TRoute['fullPath']> : TRoute['fullPath'];
348
+ type RouteToPathPreserveTrailingSlash<TRoute extends AnyRoute> = RouteToPathNeverTrailingSlash<TRoute> | RouteToPathAlwaysTrailingSlash<TRoute>;
349
+ type RouteToPathByTrailingSlashOption<TRoute extends AnyRoute> = {
350
+ always: RouteToPathAlwaysTrailingSlash<TRoute>;
351
+ preserve: RouteToPathPreserveTrailingSlash<TRoute>;
352
+ never: RouteToPathNeverTrailingSlash<TRoute>;
353
+ };
354
+ type TrailingSlashOptionByRouter<TRouter extends AnyRouter> = TrailingSlashOption extends TRouter['options']['trailingSlash'] ? 'never' : NonNullable<TRouter['options']['trailingSlash']>;
355
+ type RouteToByRouter<TRouter extends AnyRouter, TRoute extends AnyRoute> = RouteToPathByTrailingSlashOption<TRoute>[TrailingSlashOptionByRouter<TRouter>];
356
+ type CodeRouteToPath<TRouter extends AnyRouter> = ParseRouteWithoutBranches<TRouter['routeTree']> extends infer TRoute extends AnyRoute ? TRoute extends any ? RouteToByRouter<TRouter, TRoute> : never : never;
357
+ type FileRouteToPath<TRouter extends AnyRouter, TTo = InferFileRouteTypes<TRouter['routeTree']>['to'], TTrailingSlashOption = TrailingSlashOptionByRouter<TRouter>> = 'never' extends TTrailingSlashOption ? TTo : 'always' extends TTrailingSlashOption ? AddTrailingSlash<TTo> : TTo | AddTrailingSlash<TTo>;
358
+ type RouteToPath<TRouter extends AnyRouter> = unknown extends TRouter ? string : InferFileRouteTypes<TRouter['routeTree']> extends never ? CodeRouteToPath<TRouter> : FileRouteToPath<TRouter>;
359
+ type CodeRoutesByToPath<TRouter extends AnyRouter> = ParseRouteWithoutBranches<TRouter['routeTree']> extends infer TRoutes extends AnyRoute ? { [TRoute in TRoutes as RouteToByRouter<TRouter, TRoute>]: TRoute } : never;
360
+ type RoutesByToPath<TRouter extends AnyRouter> = InferFileRouteTypes<TRouter['routeTree']> extends never ? CodeRoutesByToPath<TRouter> : InferFileRouteTypes<TRouter['routeTree']>['fileRoutesByTo'];
361
+ type CodeRouteByToPath<TRouter extends AnyRouter, TTo> = Extract<RoutesByToPath<TRouter>[TTo & keyof RoutesByToPath<TRouter>], AnyRoute>;
362
+ type FileRouteByToPath<TRouter extends AnyRouter, TTo> = 'never' extends TrailingSlashOptionByRouter<TRouter> ? CodeRouteByToPath<TRouter, TTo> : 'always' extends TrailingSlashOptionByRouter<TRouter> ? TTo extends '/' ? CodeRouteByToPath<TRouter, TTo> : TTo extends `${infer TPath}/` ? CodeRouteByToPath<TRouter, TPath> : never : CodeRouteByToPath<TRouter, TTo extends '/' ? TTo : RemoveTrailingSlashes<TTo>>;
363
+ type RouteByToPath<TRouter extends AnyRouter, TTo> = InferFileRouteTypes<TRouter['routeTree']> extends never ? CodeRouteByToPath<TRouter, TTo> : FileRouteByToPath<TRouter, TTo>;
364
+ type FullSearchSchema<TRouteTree extends AnyRoute> = ParseRoute<TRouteTree> extends infer TRoutes extends AnyRoute ? PartialMergeAll<TRoutes['types']['fullSearchSchema']> : never;
365
+ type FullSearchSchemaInput<TRouteTree extends AnyRoute> = ParseRoute<TRouteTree> extends infer TRoutes extends AnyRoute ? PartialMergeAll<TRoutes['types']['fullSearchSchemaInput']> : never;
366
+ type AllParams<TRouteTree extends AnyRoute> = ParseRoute<TRouteTree> extends infer TRoutes extends AnyRoute ? PartialMergeAll<TRoutes['types']['allParams']> : never;
367
+ type AllContext<TRouteTree extends AnyRoute> = ParseRoute<TRouteTree> extends infer TRoutes extends AnyRoute ? PartialMergeAll<TRoutes['types']['allContext']> : never;
368
+ type AllLoaderData<TRouteTree extends AnyRoute> = ParseRoute<TRouteTree> extends infer TRoutes extends AnyRoute ? PartialMergeAll<TRoutes['types']['loaderData']> : never;
369
+ //#endregion
370
+ //#region ../../node_modules/.pnpm/@tanstack+router-core@1.171.13/node_modules/@tanstack/router-core/dist/esm/redirect.d.ts
371
+ type AnyRedirect = Redirect<any, any, any, any, any>;
372
+ /**
373
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RedirectType)
374
+ */
375
+ type Redirect<TRouter extends AnyRouter = RegisteredRouter, TFrom extends string = string, TTo extends string | undefined = undefined, TMaskFrom extends string = TFrom, TMaskTo extends string = '.'> = Response & {
376
+ options: NavigateOptions<TRouter, TFrom, TTo, TMaskFrom, TMaskTo> & {};
377
+ redirectHandled?: boolean;
378
+ };
379
+ type RedirectOptions<TRouter extends AnyRouter = RegisteredRouter, TFrom extends string = string, TTo extends string | undefined = undefined, TMaskFrom extends string = TFrom, TMaskTo extends string = '.'> = {
380
+ href?: string;
381
+ /**
382
+ * @deprecated Use `statusCode` instead
383
+ **/
384
+ code?: number;
385
+ /**
386
+ * The HTTP status code to use when redirecting.
387
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RedirectType#statuscode-property)
388
+ */
389
+ statusCode?: number;
390
+ /**
391
+ * If provided, will throw the redirect object instead of returning it. This can be useful in places where `throwing` in a function might cause it to have a return type of `never`. In that case, you can use `redirect({ throw: true })` to throw the redirect object instead of returning it.
392
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RedirectType#throw-property)
393
+ */
394
+ throw?: any;
395
+ /**
396
+ * The HTTP headers to use when redirecting.
397
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RedirectType#headers-property)
398
+ */
399
+ headers?: HeadersInit;
400
+ } & NavigateOptions<TRouter, TFrom, TTo, TMaskFrom, TMaskTo>;
401
+ /**
402
+ * Options for route-bound redirect, where 'from' is automatically set.
403
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RedirectType)
404
+ */
405
+ type RedirectOptionsRoute<TDefaultFrom extends string = string, TRouter extends AnyRouter = RegisteredRouter, TTo extends string | undefined = undefined, TMaskTo extends string = ''> = Omit<RedirectOptions<TRouter, TDefaultFrom, TTo, TDefaultFrom, TMaskTo>, 'from'>;
406
+ /**
407
+ * A redirect function bound to a specific route, with 'from' pre-set to the route's fullPath.
408
+ * This enables relative redirects like `Route.redirect({ to: './overview' })`.
409
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RedirectType)
410
+ */
411
+ interface RedirectFnRoute<in out TDefaultFrom extends string = string> {
412
+ <TRouter extends AnyRouter = RegisteredRouter, const TTo extends string | undefined = undefined, const TMaskTo extends string = ''>(opts: RedirectOptionsRoute<TDefaultFrom, TRouter, TTo, TMaskTo>): Redirect<TRouter, TDefaultFrom, TTo, TDefaultFrom, TMaskTo>;
413
+ }
414
+ //#endregion
415
+ //#region ../../node_modules/.pnpm/@tanstack+router-core@1.171.13/node_modules/@tanstack/router-core/dist/esm/Matches.d.ts
416
+ interface DefaultRouteMatchExtensions {
417
+ scripts?: unknown;
418
+ links?: unknown;
419
+ headScripts?: unknown;
420
+ meta?: unknown;
421
+ styles?: unknown;
422
+ }
423
+ interface RouteMatchExtensions extends DefaultRouteMatchExtensions {}
424
+ interface RouteMatch$1<out TRouteId, out TFullPath, out TAllParams, out TFullSearchSchema, out TLoaderData, out TAllContext, out TLoaderDeps> extends RouteMatchExtensions {
425
+ id: string;
426
+ routeId: TRouteId;
427
+ fullPath: TFullPath;
428
+ index: number;
429
+ pathname: string;
430
+ params: TAllParams;
431
+ _strictParams: TAllParams;
432
+ status: 'pending' | 'success' | 'error' | 'redirected' | 'notFound';
433
+ isFetching: false | 'beforeLoad' | 'loader';
434
+ error: unknown;
435
+ paramsError: unknown;
436
+ searchError: unknown;
437
+ updatedAt: number;
438
+ _nonReactive: {
439
+ loadPromise?: ControlledPromise<void>;
440
+ displayPendingPromise?: Promise<void>;
441
+ minPendingPromise?: ControlledPromise<void>;
442
+ dehydrated?: boolean;
443
+ };
444
+ loaderData?: TLoaderData;
445
+ context: TAllContext;
446
+ search: TFullSearchSchema;
447
+ _strictSearch: TFullSearchSchema;
448
+ fetchCount: number;
449
+ abortController: AbortController;
450
+ cause: 'preload' | 'enter' | 'stay';
451
+ loaderDeps: TLoaderDeps;
452
+ preload: boolean;
453
+ invalid: boolean;
454
+ headers?: Record<string, string>;
455
+ globalNotFound?: boolean;
456
+ staticData: StaticDataRouteOption;
457
+ /** This attribute is not reactive */
458
+ ssr?: SSROption;
459
+ _forcePending?: boolean;
460
+ _displayPending?: boolean;
461
+ }
462
+ interface PreValidationErrorHandlingRouteMatch<TRouteId, TFullPath, TAllParams, TFullSearchSchema> {
463
+ id: string;
464
+ routeId: TRouteId;
465
+ fullPath: TFullPath;
466
+ index: number;
467
+ pathname: string;
468
+ search: {
469
+ status: 'success';
470
+ value: TFullSearchSchema;
471
+ } | {
472
+ status: 'error';
473
+ error: unknown;
474
+ };
475
+ params: {
476
+ status: 'success';
477
+ value: TAllParams;
478
+ } | {
479
+ status: 'error';
480
+ error: unknown;
481
+ };
482
+ staticData: StaticDataRouteOption;
483
+ ssr?: boolean | 'data-only';
484
+ }
485
+ type MakePreValidationErrorHandlingRouteMatchUnion<TRouter extends AnyRouter = RegisteredRouter, TRoute extends AnyRoute = ParseRoute<TRouter['routeTree']>> = TRoute extends any ? PreValidationErrorHandlingRouteMatch<TRoute['id'], TRoute['fullPath'], TRoute['types']['allParams'], TRoute['types']['fullSearchSchema']> : never;
486
+ type MakeRouteMatchFromRoute<TRoute extends AnyRoute> = RouteMatch$1<TRoute['types']['id'], TRoute['types']['fullPath'], TRoute['types']['allParams'], TRoute['types']['fullSearchSchema'], TRoute['types']['loaderData'], TRoute['types']['allContext'], TRoute['types']['loaderDeps']>;
487
+ type MakeRouteMatch<TRouteTree extends AnyRoute = RegisteredRouter['routeTree'], TRouteId = RouteIds<TRouteTree>, TStrict extends boolean = true> = RouteMatch$1<TRouteId, RouteById<TRouteTree, TRouteId>['types']['fullPath'], TStrict extends false ? AllParams<TRouteTree> : RouteById<TRouteTree, TRouteId>['types']['allParams'], TStrict extends false ? FullSearchSchema<TRouteTree> : RouteById<TRouteTree, TRouteId>['types']['fullSearchSchema'], TStrict extends false ? AllLoaderData<TRouteTree> : RouteById<TRouteTree, TRouteId>['types']['loaderData'], TStrict extends false ? AllContext<TRouteTree> : RouteById<TRouteTree, TRouteId>['types']['allContext'], RouteById<TRouteTree, TRouteId>['types']['loaderDeps']>;
488
+ type AnyRouteMatch = RouteMatch$1<any, any, any, any, any, any, any>;
489
+ type MakeRouteMatchUnion<TRouter extends AnyRouter = RegisteredRouter, TRoute extends AnyRoute = ParseRoute<TRouter['routeTree']>> = TRoute extends any ? RouteMatch$1<TRoute['id'], TRoute['fullPath'], TRoute['types']['allParams'], TRoute['types']['fullSearchSchema'], TRoute['types']['loaderData'], TRoute['types']['allContext'], TRoute['types']['loaderDeps']> : never;
490
+ /**
491
+ * The `MatchRouteOptions` type is used to describe the options that can be used when matching a route.
492
+ *
493
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/MatchRouteOptionsType#matchrouteoptions-type)
494
+ */
495
+ interface MatchRouteOptions {
496
+ /**
497
+ * If `true`, will match against pending location instead of the current location.
498
+ *
499
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/MatchRouteOptionsType#pending-property)
500
+ */
501
+ pending?: boolean;
502
+ /**
503
+ * If `true`, will match against the current location with case sensitivity.
504
+ *
505
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/MatchRouteOptionsType#casesensitive-property)
506
+ *
507
+ * @deprecated Declare case sensitivity in the route definition instead, or globally for all routes using the `caseSensitive` option on the router.
508
+ */
509
+ caseSensitive?: boolean;
510
+ /**
511
+ * If `true`, will match against the current location's search params using a deep inclusive check. e.g. `{ a: 1 }` will match for a current location of `{ a: 1, b: 2 }`.
512
+ *
513
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/MatchRouteOptionsType#includesearch-property)
514
+ */
515
+ includeSearch?: boolean;
516
+ /**
517
+ * If `true`, will match against the current location using a fuzzy match. e.g. `/posts` will match for a current location of `/posts/123`.
518
+ *
519
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/MatchRouteOptionsType#fuzzy-property)
520
+ */
521
+ fuzzy?: boolean;
522
+ }
523
+ //#endregion
524
+ //#region ../../node_modules/.pnpm/@tanstack+router-core@1.171.13/node_modules/@tanstack/router-core/dist/esm/root.d.ts
525
+ /** Stable identifier used for the root route in a route tree. */
526
+ declare const rootRouteId = "__root__";
527
+ type RootRouteId = typeof rootRouteId;
528
+ //#endregion
529
+ //#region ../../node_modules/.pnpm/@tanstack+router-core@1.171.13/node_modules/@tanstack/router-core/dist/esm/RouterProvider.d.ts
530
+ interface CommitLocationOptions {
531
+ replace?: boolean;
532
+ resetScroll?: boolean;
533
+ hashScrollIntoView?: boolean | ScrollIntoViewOptions;
534
+ viewTransition?: boolean | ViewTransitionOptions;
535
+ /**
536
+ * @deprecated All navigations use transitions under the hood now
537
+ **/
538
+ startTransition?: boolean;
539
+ ignoreBlocker?: boolean;
540
+ }
541
+ type NavigateFn = <TRouter extends RegisteredRouter, TTo extends string | undefined, TFrom extends RoutePaths<TRouter['routeTree']> | string = string, TMaskFrom extends RoutePaths<TRouter['routeTree']> | string = TFrom, TMaskTo extends string = ''>(opts: NavigateOptions<TRouter, TFrom, TTo, TMaskFrom, TMaskTo>) => Promise<void>;
542
+ type BuildLocationFn = <TRouter extends RegisteredRouter, TTo extends string | undefined, TFrom extends RoutePaths<TRouter['routeTree']> | string = string, TMaskFrom extends RoutePaths<TRouter['routeTree']> | string = TFrom, TMaskTo extends string = ''>(opts: ToOptions<TRouter, TFrom, TTo, TMaskFrom, TMaskTo> & {
543
+ leaveParams?: boolean;
544
+ _includeValidateSearch?: boolean;
545
+ _isNavigate?: boolean;
546
+ }) => ParsedLocation;
547
+ //#endregion
548
+ //#region ../../node_modules/.pnpm/@tanstack+router-core@1.171.13/node_modules/@tanstack/router-core/dist/esm/ssr/serializer/RawStream.d.ts
549
+ /**
550
+ * Hint for RawStream encoding strategy during SSR serialization.
551
+ * - 'binary': Always use base64 encoding (best for binary data like files, images)
552
+ * - 'text': Try UTF-8 first, fallback to base64 (best for text-heavy data like RSC payloads)
553
+ */
554
+ type RawStreamHint = 'binary' | 'text';
555
+ /**
556
+ * Options for RawStream configuration.
557
+ */
558
+ interface RawStreamOptions {
559
+ /**
560
+ * Encoding hint for SSR serialization.
561
+ * - 'binary' (default): Always use base64 encoding
562
+ * - 'text': Try UTF-8 first, fallback to base64 for invalid UTF-8 chunks
563
+ */
564
+ hint?: RawStreamHint;
565
+ }
566
+ /**
567
+ * Marker class for ReadableStream<Uint8Array> that should be serialized
568
+ * with base64 encoding (SSR) or binary framing (server functions).
569
+ *
570
+ * Wrap your binary streams with this to get efficient serialization:
571
+ * ```ts
572
+ * // For binary data (files, images, etc.)
573
+ * return { data: new RawStream(file.stream()) }
574
+ *
575
+ * // For text-heavy data (RSC payloads, etc.)
576
+ * return { data: new RawStream(rscStream, { hint: 'text' }) }
577
+ * ```
578
+ */
579
+ declare class RawStream {
580
+ readonly stream: ReadableStream<Uint8Array>;
581
+ readonly hint: RawStreamHint;
582
+ constructor(stream: ReadableStream<Uint8Array>, options?: RawStreamOptions);
583
+ }
584
+ //#endregion
585
+ //#region ../../node_modules/.pnpm/@tanstack+router-core@1.171.13/node_modules/@tanstack/router-core/dist/esm/ssr/serializer/transformer.d.ts
586
+ declare const TSR_SERIALIZABLE: unique symbol;
587
+ type TSR_SERIALIZABLE = typeof TSR_SERIALIZABLE;
588
+ type TsrSerializable = {
589
+ [TSR_SERIALIZABLE]: true;
590
+ };
591
+ interface DefaultSerializable {
592
+ number: number;
593
+ string: string;
594
+ boolean: boolean;
595
+ null: null;
596
+ undefined: undefined;
597
+ bigint: bigint;
598
+ Date: Date;
599
+ Uint8Array: Uint8Array;
600
+ RawStream: RawStream;
601
+ TsrSerializable: TsrSerializable;
602
+ void: void;
603
+ }
604
+ interface SerializableExtensions extends DefaultSerializable {}
605
+ type Serializable = SerializableExtensions[keyof SerializableExtensions];
606
+ type UnionizeSerializationAdaptersInput<TAdapters extends ReadonlyArray<AnySerializationAdapter>> = TAdapters[number]['~types']['input'];
607
+ type ValidateSerializable<T, TSerializable> = T extends TSerializable ? T : T extends ((...args: Array<any>) => any) ? SerializationError<'Function may not be serializable'> : T extends RegisteredReadableStream ? SerializationError<'JSX is not be serializable'> : T extends ReadonlyArray<any> ? ValidateSerializableArray<T, TSerializable> : T extends Promise<any> ? ValidateSerializablePromise<T, TSerializable> : T extends ReadableStream<any> ? ValidateReadableStream<T, TSerializable> : T extends Set<any> ? ValidateSerializableSet<T, TSerializable> : T extends Map<any, any> ? ValidateSerializableMap<T, TSerializable> : T extends AsyncGenerator<any, any> ? ValidateSerializableAsyncGenerator<T, TSerializable> : T extends object ? ValidateSerializableMapped<T, TSerializable> : SerializationError<'Type may not be serializable'>;
608
+ type ValidateSerializableAsyncGenerator<T, TSerializable> = T extends AsyncGenerator<infer T, infer TReturn, infer TNext> ? AsyncGenerator<ValidateSerializable<T, TSerializable>, ValidateSerializable<TReturn, TSerializable>, TNext> : never;
609
+ type ValidateSerializablePromise<T, TSerializable> = T extends Promise<infer TAwaited> ? Promise<ValidateSerializable<TAwaited, TSerializable>> : never;
610
+ type ValidateReadableStream<T, TSerializable> = T extends ReadableStream<infer TStreamed> ? ReadableStream<ValidateSerializable<TStreamed, TSerializable>> : never;
611
+ type ValidateSerializableSet<T, TSerializable> = T extends Set<infer TItem> ? Set<ValidateSerializable<TItem, TSerializable>> : never;
612
+ type ValidateSerializableMap<T, TSerializable> = T extends Map<infer TKey, infer TValue> ? Map<ValidateSerializable<TKey, TSerializable>, ValidateSerializable<TValue, TSerializable>> : never;
613
+ type ValidateSerializableArray<T, TSerializable> = T extends readonly [any, ...Array<any>] ? ValidateSerializableMapped<T, TSerializable> : T extends Array<infer U> ? Array<ValidateSerializable<U, TSerializable>> : T extends ReadonlyArray<infer U> ? ReadonlyArray<ValidateSerializable<U, TSerializable>> : never;
614
+ type ValidateSerializableMapped<T, TSerializable> = { [K in keyof T]: ValidateSerializable<T[K], TSerializable> };
615
+ declare const SERIALIZATION_ERROR: unique symbol;
616
+ interface SerializationError<in out TMessage extends string> {
617
+ [SERIALIZATION_ERROR]: TMessage;
618
+ }
619
+ interface SerializationAdapter<TInput, TOutput, TExtendsAdapters extends ReadonlyArray<AnySerializationAdapter>> {
620
+ '~types': SerializationAdapterTypes<TInput, TOutput, TExtendsAdapters>;
621
+ key: string;
622
+ extends?: TExtendsAdapters;
623
+ test: (value: unknown) => value is TInput;
624
+ toSerializable: (value: TInput) => TOutput;
625
+ fromSerializable: (value: TOutput) => TInput;
626
+ }
627
+ interface SerializationAdapterTypes<TInput, TOutput, TExtendsAdapters extends ReadonlyArray<AnySerializationAdapter>> {
628
+ input: TInput | UnionizeSerializationAdaptersInput<TExtendsAdapters>;
629
+ output: TOutput;
630
+ extends: TExtendsAdapters;
631
+ }
632
+ type AnySerializationAdapter = SerializationAdapter<any, any, any>;
633
+ type ValidateSerializableInput<TRegister, T> = ValidateSerializable<T, RegisteredSerializableInput<TRegister>>;
634
+ type RegisteredSerializableInput<TRegister> = (unknown extends RegisteredSerializationAdapters<TRegister> ? never : RegisteredSerializationAdapters<TRegister> extends ReadonlyArray<AnySerializationAdapter> ? RegisteredSerializationAdapters<TRegister>[number]['~types']['input'] : never) | Serializable;
635
+ type RegisteredSerializationAdapters<TRegister> = RegisteredConfigType<TRegister, 'serializationAdapters'>;
636
+ type RegisteredSSROption<TRegister> = unknown extends RegisteredConfigType<TRegister, 'defaultSsr'> ? SSROption : RegisteredConfigType<TRegister, 'defaultSsr'>;
637
+ type ValidateSerializableLifecycleResult<TRegister, TParentRoute extends AnyRoute, TSSR, TFn> = false extends RegisteredSsr<TRegister> ? any : ValidateSerializableLifecycleResultSSR<TRegister, TParentRoute, TSSR, TFn> extends infer TInput ? TInput : never;
638
+ type ValidateSerializableLifecycleResultSSR<TRegister, TParentRoute extends AnyRoute, TSSR, TFn> = ResolveAllSSR<TParentRoute, TSSR> extends false ? any : RegisteredSSROption<TRegister> extends false ? any : ValidateSerializableInput<TRegister, LooseReturnType<TFn>>;
639
+ type RegisteredReadableStream = unknown extends SerializerExtensions['ReadableStream'] ? never : SerializerExtensions['ReadableStream'];
640
+ interface DefaultSerializerExtensions {
641
+ ReadableStream: unknown;
642
+ }
643
+ interface SerializerExtensions extends DefaultSerializerExtensions {}
644
+ //#endregion
645
+ //#region ../../node_modules/.pnpm/@tanstack+router-core@1.171.13/node_modules/@tanstack/router-core/dist/esm/route.d.ts
646
+ type AnyPathParams = {};
647
+ type SearchSchemaInput = {
648
+ __TSearchSchemaInput__: 'TSearchSchemaInput';
649
+ };
650
+ type AnyContext = {};
651
+ type RoutePathOptions<TCustomId, TPath> = {
652
+ path: TPath;
653
+ } | {
654
+ id: TCustomId;
655
+ };
656
+ interface StaticDataRouteOption {}
657
+ type SearchFilter<TInput, TResult = TInput> = (prev: TInput) => TResult;
658
+ type SearchMiddlewareMeta = {
659
+ removed?: Map<string, unknown>;
660
+ removedAny?: Set<string>;
661
+ defaulted?: Map<string, unknown>;
662
+ explicit?: unknown;
663
+ };
664
+ type SearchMiddlewareContext<TSearchSchema> = {
665
+ search: TSearchSchema;
666
+ next: (newSearch: TSearchSchema) => TSearchSchema;
667
+ meta?: SearchMiddlewareMeta;
668
+ };
669
+ type SearchMiddleware<TSearchSchema> = (ctx: SearchMiddlewareContext<TSearchSchema>) => TSearchSchema;
670
+ type InferFullSearchSchema<TRoute> = TRoute extends {
671
+ types: {
672
+ fullSearchSchema: infer TFullSearchSchema;
673
+ };
674
+ } ? TFullSearchSchema : {};
675
+ type InferFullSearchSchemaInput<TRoute> = TRoute extends {
676
+ types: {
677
+ fullSearchSchemaInput: infer TFullSearchSchemaInput;
678
+ };
679
+ } ? TFullSearchSchemaInput : {};
680
+ type InferAllParams<TRoute> = TRoute extends {
681
+ types: {
682
+ allParams: infer TAllParams;
683
+ };
684
+ } ? TAllParams : {};
685
+ type InferAllContext<TRoute> = unknown extends TRoute ? TRoute : TRoute extends {
686
+ types: {
687
+ allContext: infer TAllContext;
688
+ };
689
+ } ? TAllContext : {};
690
+ type ResolveRequiredParams<TPath extends string, T> = { [K in ParsePathParams<TPath>['required']]: T };
691
+ type ResolveOptionalParams<TPath extends string, T> = { [K in ParsePathParams<TPath>['optional']]?: T | undefined };
692
+ type ResolveParams<TPath extends string, T = string> = ResolveRequiredParams<TPath, T> & ResolveOptionalParams<TPath, T>;
693
+ type ParseParamsFn<in out TPath extends string, in out TParams> = (rawParams: Expand<ResolveParams<TPath>>) => TParams | false;
694
+ type ValidateParsedParams<TPath extends string, TParams> = [TParams] extends [ResolveParams<TPath, any>] ? unknown : never;
695
+ type StringifyParamsFn<in out TPath extends string, in out TParams> = (params: TParams) => ResolveParams<TPath>;
696
+ type ParamsOptions<in out TPath extends string, in out TParams> = {
697
+ params?: {
698
+ parse?: ParseParamsFn<TPath, TParams> & ValidateParsedParams<TPath, TParams>;
699
+ /**
700
+ * When multiple route candidates use `params.parse` during matching,
701
+ * higher priorities are tried first.
702
+ *
703
+ * @default 0
704
+ */
705
+ priority?: number;
706
+ stringify?: StringifyParamsFn<TPath, TParams>;
707
+ };
708
+ /**
709
+ @deprecated Use params.parse instead
710
+ */
711
+ parseParams?: ParseParamsFn<TPath, TParams> & ValidateParsedParams<TPath, TParams>;
712
+ /**
713
+ @deprecated Use params.stringify instead
714
+ */
715
+ stringifyParams?: StringifyParamsFn<TPath, TParams>;
716
+ };
717
+ interface RequiredStaticDataRouteOption {
718
+ staticData: StaticDataRouteOption;
719
+ }
720
+ interface OptionalStaticDataRouteOption {
721
+ staticData?: StaticDataRouteOption;
722
+ }
723
+ type UpdatableStaticRouteOption = {} extends StaticDataRouteOption ? OptionalStaticDataRouteOption : RequiredStaticDataRouteOption;
724
+ type TrimPathRight<T extends string> = T extends '/' ? '/' : T extends `${infer U}/` ? TrimPathRight<U> : T;
725
+ type ContextReturnType<TContextFn> = unknown extends TContextFn ? TContextFn : LooseReturnType<TContextFn> extends never ? AnyContext : LooseReturnType<TContextFn>;
726
+ type ContextAsyncReturnType<TContextFn> = unknown extends TContextFn ? TContextFn : LooseAsyncReturnType<TContextFn> extends never ? AnyContext : LooseAsyncReturnType<TContextFn>;
727
+ type ResolveRouteContext<TRouteContextFn, TBeforeLoadFn> = Assign<ContextReturnType<TRouteContextFn>, ContextAsyncReturnType<TBeforeLoadFn>>;
728
+ type ResolveRouteLoaderFn<TLoaderFn> = TLoaderFn extends {
729
+ handler: infer THandler;
730
+ } ? THandler : TLoaderFn;
731
+ type RouteLoaderObject<TRegister, TParentRoute extends AnyRoute = AnyRoute, TId extends string = string, TParams = {}, TLoaderDeps = {}, TRouterContext = {}, TRouteContextFn = AnyContext, TBeforeLoadFn = AnyContext, TServerMiddlewares = unknown, THandlers = undefined> = {
732
+ handler: RouteLoaderFn<TRegister, TParentRoute, TId, TParams, TLoaderDeps, TRouterContext, TRouteContextFn, TBeforeLoadFn, TServerMiddlewares, THandlers>;
733
+ staleReloadMode?: LoaderStaleReloadMode;
734
+ };
735
+ type ResolveLoaderData<TLoaderFn> = unknown extends TLoaderFn ? TLoaderFn : LooseAsyncReturnType<ResolveRouteLoaderFn<TLoaderFn>> extends never ? undefined : LooseAsyncReturnType<ResolveRouteLoaderFn<TLoaderFn>>;
736
+ type ResolveFullSearchSchema<TParentRoute extends AnyRoute, TSearchValidator> = unknown extends TParentRoute ? ResolveValidatorOutput<TSearchValidator> : IntersectAssign<InferFullSearchSchema<TParentRoute>, ResolveValidatorOutput<TSearchValidator>>;
737
+ type ResolveFullSearchSchemaInput<TParentRoute extends AnyRoute, TSearchValidator> = IntersectAssign<InferFullSearchSchemaInput<TParentRoute>, ResolveSearchValidatorInput<TSearchValidator>>;
738
+ type ResolveAllParamsFromParent<TParentRoute extends AnyRoute, TParams> = Assign<InferAllParams<TParentRoute>, TParams>;
739
+ type RouteContextParameter<TParentRoute extends AnyRoute, TRouterContext> = unknown extends TParentRoute ? TRouterContext : Assign<TRouterContext, InferAllContext<TParentRoute>>;
740
+ type BeforeLoadContextParameter<TParentRoute extends AnyRoute, TRouterContext, TRouteContextFn> = Assign<RouteContextParameter<TParentRoute, TRouterContext>, ContextReturnType<TRouteContextFn>>;
741
+ type ResolveAllContext<TParentRoute extends AnyRoute, TRouterContext, TRouteContextFn, TBeforeLoadFn> = Assign<BeforeLoadContextParameter<TParentRoute, TRouterContext, TRouteContextFn>, ContextAsyncReturnType<TBeforeLoadFn>>;
742
+ interface FullSearchSchemaOption<in out TParentRoute extends AnyRoute, in out TSearchValidator> {
743
+ search: Expand<ResolveFullSearchSchema<TParentRoute, TSearchValidator>>;
744
+ }
745
+ interface RemountDepsOptions<in out TRouteId, in out TFullSearchSchema, in out TAllParams, in out TLoaderDeps> {
746
+ routeId: TRouteId;
747
+ search: TFullSearchSchema;
748
+ params: TAllParams;
749
+ loaderDeps: TLoaderDeps;
750
+ }
751
+ type MakeRemountDepsOptionsUnion<TRouteTree extends AnyRoute = RegisteredRouter['routeTree']> = ParseRoute<TRouteTree> extends infer TRoute extends AnyRoute ? TRoute extends any ? RemountDepsOptions<TRoute['id'], TRoute['types']['fullSearchSchema'], TRoute['types']['allParams'], TRoute['types']['loaderDeps']> : never : never;
752
+ interface RouteTypes$1<in out TRegister, in out TParentRoute extends AnyRoute, in out TPath extends string, in out TFullPath extends string, in out TCustomId extends string, in out TId extends string, in out TSearchValidator, in out TParams, in out TRouterContext, in out TRouteContextFn, in out TBeforeLoadFn, in out TLoaderDeps, in out TLoaderFn, in out TChildren, in out TFileRouteTypes, in out TSSR, in out TServerMiddlewares, in out THandlers> {
753
+ parentRoute: TParentRoute;
754
+ path: TPath;
755
+ to: TrimPathRight<TFullPath>;
756
+ fullPath: TFullPath;
757
+ customId: TCustomId;
758
+ id: TId;
759
+ searchSchema: ResolveValidatorOutput<TSearchValidator>;
760
+ searchSchemaInput: ResolveSearchValidatorInput<TSearchValidator>;
761
+ searchValidator: TSearchValidator;
762
+ fullSearchSchema: ResolveFullSearchSchema<TParentRoute, TSearchValidator>;
763
+ fullSearchSchemaInput: ResolveFullSearchSchemaInput<TParentRoute, TSearchValidator>;
764
+ params: TParams;
765
+ allParams: ResolveAllParamsFromParent<TParentRoute, TParams>;
766
+ routerContext: TRouterContext;
767
+ routeContext: ResolveRouteContext<TRouteContextFn, TBeforeLoadFn>;
768
+ routeContextFn: TRouteContextFn;
769
+ beforeLoadFn: TBeforeLoadFn;
770
+ allContext: ResolveAllContext<TParentRoute, TRouterContext, TRouteContextFn, TBeforeLoadFn>;
771
+ children: TChildren;
772
+ loaderData: ResolveLoaderData<TLoaderFn>;
773
+ loaderDeps: TLoaderDeps;
774
+ fileRouteTypes: TFileRouteTypes;
775
+ ssr: ResolveSSR<TSSR>;
776
+ allSsr: ResolveAllSSR<TParentRoute, TSSR>;
777
+ }
778
+ type ResolveSSR<TSSR> = TSSR extends ((...args: ReadonlyArray<any>) => any) ? LooseReturnType<TSSR> : TSSR;
779
+ type ResolveAllSSR<TParentRoute extends AnyRoute, TSSR> = unknown extends TParentRoute ? ResolveSSR<TSSR> : unknown extends TSSR ? TParentRoute['types']['allSsr'] : ResolveSSR<TSSR>;
780
+ interface RouteExtensions<in out TId, in out TFullPath> {
781
+ id: TId;
782
+ fullPath: TFullPath;
783
+ }
784
+ type RouteLazyFn<TRoute extends AnyRoute> = (lazyFn: () => Promise<LazyRoute<TRoute>>) => TRoute;
785
+ type RouteAddChildrenFn<in out TRegister, in out TParentRoute extends AnyRoute, in out TPath extends string, in out TFullPath extends string, in out TCustomId extends string, in out TId extends string, in out TSearchValidator, in out TParams, in out TRouterContext, in out TRouteContextFn, in out TBeforeLoadFn, in out TLoaderDeps extends Record<string, any>, in out TLoaderFn, in out TFileRouteTypes, in out TSSR, in out TServerMiddlewares, in out THandlers> = <const TNewChildren>(children: Constrain<TNewChildren, ReadonlyArray<AnyRoute> | Record<string, AnyRoute>>) => Route<TRegister, TParentRoute, TPath, TFullPath, TCustomId, TId, TSearchValidator, TParams, TRouterContext, TRouteContextFn, TBeforeLoadFn, TLoaderDeps, TLoaderFn, TNewChildren, TFileRouteTypes, TSSR, TServerMiddlewares, THandlers>;
786
+ type RouteAddFileChildrenFn<in out TRegister, in out TParentRoute extends AnyRoute, in out TPath extends string, in out TFullPath extends string, in out TCustomId extends string, in out TId extends string, in out TSearchValidator, in out TParams, in out TRouterContext, in out TRouteContextFn, in out TBeforeLoadFn, in out TLoaderDeps extends Record<string, any>, in out TLoaderFn, in out TFileRouteTypes, in out TSSR, in out TServerMiddlewares, in out THandlers> = <const TNewChildren>(children: TNewChildren) => Route<TRegister, TParentRoute, TPath, TFullPath, TCustomId, TId, TSearchValidator, TParams, TRouterContext, TRouteContextFn, TBeforeLoadFn, TLoaderDeps, TLoaderFn, TNewChildren, TFileRouteTypes, TSSR, TServerMiddlewares, THandlers>;
787
+ type RouteAddFileTypesFn<TRegister, TParentRoute extends AnyRoute, TPath extends string, TFullPath extends string, TCustomId extends string, TId extends string, TSearchValidator, TParams, TRouterContext, TRouteContextFn, TBeforeLoadFn, TLoaderDeps extends Record<string, any>, TLoaderFn, TChildren, TSSR, TServerMiddlewares, THandlers> = <TNewFileRouteTypes>() => Route<TRegister, TParentRoute, TPath, TFullPath, TCustomId, TId, TSearchValidator, TParams, TRouterContext, TRouteContextFn, TBeforeLoadFn, TLoaderDeps, TLoaderFn, TChildren, TNewFileRouteTypes, TSSR, TServerMiddlewares, THandlers>;
788
+ interface Route<in out TRegister, in out TParentRoute extends AnyRoute, in out TPath extends string, in out TFullPath extends string, in out TCustomId extends string, in out TId extends string, in out TSearchValidator, in out TParams, in out TRouterContext, in out TRouteContextFn, in out TBeforeLoadFn, in out TLoaderDeps extends Record<string, any>, in out TLoaderFn, in out TChildren, in out TFileRouteTypes, in out TSSR, in out TServerMiddlewares, in out THandlers> extends RouteExtensions<TId, TFullPath> {
789
+ path: TPath;
790
+ parentRoute: TParentRoute;
791
+ children?: TChildren;
792
+ types: RouteTypes$1<TRegister, TParentRoute, TPath, TFullPath, TCustomId, TId, TSearchValidator, TParams, TRouterContext, TRouteContextFn, TBeforeLoadFn, TLoaderDeps, TLoaderFn, TChildren, TFileRouteTypes, TSSR, TServerMiddlewares, THandlers>;
793
+ options: RouteOptions<TRegister, TParentRoute, TId, TCustomId, TFullPath, TPath, TSearchValidator, TParams, TLoaderDeps, TLoaderFn, TRouterContext, TRouteContextFn, TBeforeLoadFn, TSSR, TServerMiddlewares, THandlers>;
794
+ isRoot: TParentRoute extends AnyRoute ? true : false;
795
+ lazyFn?: () => Promise<LazyRoute<Route<TRegister, TParentRoute, TPath, TFullPath, TCustomId, TId, TSearchValidator, TParams, TRouterContext, TRouteContextFn, TBeforeLoadFn, TLoaderDeps, TLoaderFn, TChildren, TFileRouteTypes, TSSR, TServerMiddlewares, THandlers>>>;
796
+ rank: number;
797
+ to: TrimPathRight<TFullPath>;
798
+ init: (opts: {
799
+ originalIndex: number;
800
+ }) => void;
801
+ update: (options: UpdatableRouteOptions<TParentRoute, TCustomId, TFullPath, TParams, TSearchValidator, TLoaderFn, TLoaderDeps, TRouterContext, TRouteContextFn, TBeforeLoadFn>) => this;
802
+ lazy: RouteLazyFn<Route<TRegister, TParentRoute, TPath, TFullPath, TCustomId, TId, TSearchValidator, TParams, TRouterContext, TRouteContextFn, TBeforeLoadFn, TLoaderDeps, TLoaderFn, TChildren, TFileRouteTypes, TSSR, TServerMiddlewares, THandlers>>;
803
+ addChildren: RouteAddChildrenFn<TRegister, TParentRoute, TPath, TFullPath, TCustomId, TId, TSearchValidator, TParams, TRouterContext, TRouteContextFn, TBeforeLoadFn, TLoaderDeps, TLoaderFn, TFileRouteTypes, TSSR, TServerMiddlewares, THandlers>;
804
+ _addFileChildren: RouteAddFileChildrenFn<TRegister, TParentRoute, TPath, TFullPath, TCustomId, TId, TSearchValidator, TParams, TRouterContext, TRouteContextFn, TBeforeLoadFn, TLoaderDeps, TLoaderFn, TFileRouteTypes, TSSR, TServerMiddlewares, THandlers>;
805
+ _addFileTypes: RouteAddFileTypesFn<TRegister, TParentRoute, TPath, TFullPath, TCustomId, TId, TSearchValidator, TParams, TRouterContext, TRouteContextFn, TBeforeLoadFn, TLoaderDeps, TLoaderFn, TChildren, TSSR, TServerMiddlewares, THandlers>;
806
+ /**
807
+ * Create a redirect with `from` automatically set to this route's path.
808
+ * Enables relative redirects like `Route.redirect({ to: './overview' })`.
809
+ * @param opts Redirect options (same as `redirect()` but without `from`)
810
+ * @returns A redirect Response that can be thrown from loaders/beforeLoad
811
+ * @link https://tanstack.com/router/latest/docs/framework/react/api/router/redirectFunction
812
+ */
813
+ redirect: RedirectFnRoute<TFullPath>;
814
+ }
815
+ type AnyRoute = Route<any, any, any, any, any, any, any, any, any, any, any, any, any, any, any, any, any, any>;
816
+ type RouteOptions<TRegister, TParentRoute extends AnyRoute = AnyRoute, TId extends string = string, TCustomId extends string = string, TFullPath extends string = string, TPath extends string = string, TSearchValidator = undefined, TParams = AnyPathParams, TLoaderDeps extends Record<string, any> = {}, TLoaderFn = undefined, TRouterContext = {}, TRouteContextFn = AnyContext, TBeforeLoadFn = AnyContext, TSSR = unknown, TServerMiddlewares = unknown, THandlers = undefined> = BaseRouteOptions<TRegister, TParentRoute, TId, TCustomId, TPath, TSearchValidator, TParams, TLoaderDeps, TLoaderFn, TRouterContext, TRouteContextFn, TBeforeLoadFn, TSSR, TServerMiddlewares, THandlers> & UpdatableRouteOptions<NoInfer<TParentRoute>, NoInfer<TCustomId>, NoInfer<TFullPath>, NoInfer<TParams>, NoInfer<TSearchValidator>, NoInfer<TLoaderFn>, NoInfer<TLoaderDeps>, NoInfer<TRouterContext>, NoInfer<TRouteContextFn>, NoInfer<TBeforeLoadFn>>;
817
+ type FileBaseRouteOptions<TRegister, TParentRoute extends AnyRoute = AnyRoute, TId extends string = string, TPath extends string = string, TSearchValidator = undefined, TParams = {}, TLoaderDeps extends Record<string, any> = {}, TLoaderFn = undefined, TRouterContext = {}, TRouteContextFn = AnyContext, TBeforeLoadFn = AnyContext, TRemountDepsFn = AnyContext, TSSR = unknown, TServerMiddlewares = unknown, THandlers = undefined> = ParamsOptions<TPath, TParams> & FilebaseRouteOptionsInterface<TRegister, TParentRoute, TId, TPath, TSearchValidator, TParams, TLoaderDeps, TLoaderFn, TRouterContext, TRouteContextFn, TBeforeLoadFn, TRemountDepsFn, TSSR, TServerMiddlewares, THandlers>;
818
+ interface FilebaseRouteOptionsInterface<TRegister, TParentRoute extends AnyRoute = AnyRoute, TId extends string = string, TPath extends string = string, TSearchValidator = undefined, TParams = {}, TLoaderDeps extends Record<string, any> = {}, TLoaderFn = undefined, TRouterContext = {}, TRouteContextFn = AnyContext, TBeforeLoadFn = AnyContext, TRemountDepsFn = AnyContext, TSSR = unknown, TServerMiddlewares = unknown, THandlers = undefined> {
819
+ validateSearch?: Constrain<TSearchValidator, AnyValidator, DefaultValidator>;
820
+ shouldReload?: boolean | ((match: LoaderFnContext<TRegister, TParentRoute, TId, TParams, TLoaderDeps, TRouterContext, TRouteContextFn, TBeforeLoadFn, TServerMiddlewares, THandlers>) => any);
821
+ context?: Constrain<TRouteContextFn, (ctx: RouteContextOptions<TParentRoute, TParams, TRouterContext, TLoaderDeps, TId>) => any>;
822
+ ssr?: Constrain<TSSR, undefined | SSROption | ((ctx: SsrContextOptions<TParentRoute, TSearchValidator, TParams>) => Awaitable<undefined | SSROption>)>;
823
+ beforeLoad?: Constrain<TBeforeLoadFn, (ctx: BeforeLoadContextOptions<TRegister, TParentRoute, TSearchValidator, TParams, TRouterContext, TRouteContextFn, TId, TServerMiddlewares, THandlers>) => ValidateSerializableLifecycleResult<TRegister, TParentRoute, TSSR, TBeforeLoadFn>>;
824
+ loaderDeps?: (opts: FullSearchSchemaOption<TParentRoute, TSearchValidator>) => TLoaderDeps;
825
+ remountDeps?: Constrain<TRemountDepsFn, (opt: RemountDepsOptions<TId, ResolveFullSearchSchema<TParentRoute, TSearchValidator>, Expand<ResolveAllParamsFromParent<TParentRoute, TParams>>, TLoaderDeps>) => any>;
826
+ loader?: Constrain<TLoaderFn, RouteLoaderFn<TRegister, TParentRoute, TId, TParams, TLoaderDeps, TRouterContext, TRouteContextFn, TBeforeLoadFn, TServerMiddlewares, THandlers> | RouteLoaderObject<TRegister, TParentRoute, TId, TParams, TLoaderDeps, TRouterContext, TRouteContextFn, TBeforeLoadFn, TServerMiddlewares, THandlers>>;
827
+ }
828
+ type BaseRouteOptions<TRegister, TParentRoute extends AnyRoute = AnyRoute, TId extends string = string, TCustomId extends string = string, TPath extends string = string, TSearchValidator = undefined, TParams = {}, TLoaderDeps extends Record<string, any> = {}, TLoaderFn = undefined, TRouterContext = {}, TRouteContextFn = AnyContext, TBeforeLoadFn = AnyContext, TSSR = unknown, TServerMiddlewares = unknown, THandlers = undefined> = RoutePathOptions<TCustomId, TPath> & FileBaseRouteOptions<TRegister, TParentRoute, TId, TPath, TSearchValidator, TParams, TLoaderDeps, TLoaderFn, TRouterContext, TRouteContextFn, TBeforeLoadFn, AnyContext, TSSR, TServerMiddlewares, THandlers> & {
829
+ getParentRoute: () => TParentRoute;
830
+ };
831
+ interface ContextOptions<in out TParentRoute extends AnyRoute, in out TParams, in out TRouteId> {
832
+ abortController: AbortController;
833
+ preload: boolean;
834
+ params: Expand<ResolveAllParamsFromParent<TParentRoute, TParams>>;
835
+ location: ParsedLocation;
836
+ /**
837
+ * @deprecated Use `throw redirect({ to: '/somewhere' })` instead
838
+ **/
839
+ navigate: NavigateFn;
840
+ buildLocation: BuildLocationFn;
841
+ cause: 'preload' | 'enter' | 'stay';
842
+ matches: Array<MakeRouteMatchUnion>;
843
+ routeId: TRouteId;
844
+ }
845
+ interface RouteContextOptions<in out TParentRoute extends AnyRoute, in out TParams, in out TRouterContext, in out TLoaderDeps, in out TRouteId> extends ContextOptions<TParentRoute, TParams, TRouteId> {
846
+ deps: TLoaderDeps;
847
+ context: Expand<RouteContextParameter<TParentRoute, TRouterContext>>;
848
+ }
849
+ interface SsrContextOptions<in out TParentRoute extends AnyRoute, in out TSearchValidator, in out TParams> {
850
+ params: {
851
+ status: 'success';
852
+ value: Expand<ResolveAllParamsFromParent<TParentRoute, TParams>>;
853
+ } | {
854
+ status: 'error';
855
+ error: unknown;
856
+ };
857
+ search: {
858
+ status: 'success';
859
+ value: Expand<ResolveFullSearchSchema<TParentRoute, TSearchValidator>>;
860
+ } | {
861
+ status: 'error';
862
+ error: unknown;
863
+ };
864
+ location: ParsedLocation;
865
+ matches: Array<MakePreValidationErrorHandlingRouteMatchUnion>;
866
+ }
867
+ interface BeforeLoadContextOptions<in out TRegister, in out TParentRoute extends AnyRoute, in out TSearchValidator, in out TParams, in out TRouterContext, in out TRouteContextFn, in out TRouteId, in out TServerMiddlewares, in out THandlers> extends ContextOptions<TParentRoute, TParams, TRouteId>, FullSearchSchemaOption<TParentRoute, TSearchValidator> {
868
+ context: Expand<BeforeLoadContextParameter<TParentRoute, TRouterContext, TRouteContextFn>>;
869
+ }
870
+ type AssetFnContextOptions<in out TRouteId, in out TFullPath, in out TParentRoute extends AnyRoute, in out TParams, in out TSearchValidator, in out TLoaderFn, in out TRouterContext, in out TRouteContextFn, in out TBeforeLoadFn, in out TLoaderDeps> = {
871
+ ssr?: {
872
+ nonce?: string;
873
+ };
874
+ matches: Array<RouteMatch$1<TRouteId, TFullPath, ResolveAllParamsFromParent<TParentRoute, TParams>, ResolveFullSearchSchema<TParentRoute, TSearchValidator>, ResolveLoaderData<TLoaderFn>, ResolveAllContext<TParentRoute, TRouterContext, TRouteContextFn, TBeforeLoadFn>, TLoaderDeps>>;
875
+ match: RouteMatch$1<TRouteId, TFullPath, ResolveAllParamsFromParent<TParentRoute, TParams>, ResolveFullSearchSchema<TParentRoute, TSearchValidator>, ResolveLoaderData<TLoaderFn>, ResolveAllContext<TParentRoute, TRouterContext, TRouteContextFn, TBeforeLoadFn>, TLoaderDeps>;
876
+ params: ResolveAllParamsFromParent<TParentRoute, TParams>;
877
+ loaderData?: ResolveLoaderData<TLoaderFn>;
878
+ };
879
+ interface DefaultUpdatableRouteOptionsExtensions {
880
+ component?: unknown;
881
+ errorComponent?: unknown;
882
+ notFoundComponent?: unknown;
883
+ pendingComponent?: unknown;
884
+ }
885
+ interface UpdatableRouteOptionsExtensions extends DefaultUpdatableRouteOptionsExtensions {}
886
+ interface UpdatableRouteOptions<in out TParentRoute extends AnyRoute, in out TRouteId, in out TFullPath, in out TParams, in out TSearchValidator, in out TLoaderFn, in out TLoaderDeps, in out TRouterContext, in out TRouteContextFn, in out TBeforeLoadFn> extends UpdatableStaticRouteOption, UpdatableRouteOptionsExtensions {
887
+ /**
888
+ * If true, this route will be matched as case-sensitive
889
+ *
890
+ * @default false
891
+ */
892
+ caseSensitive?: boolean;
893
+ /**
894
+ * If true, this route will be forcefully wrapped in a suspense boundary
895
+ */
896
+ wrapInSuspense?: boolean;
897
+ pendingMs?: number;
898
+ pendingMinMs?: number;
899
+ staleTime?: number;
900
+ gcTime?: number;
901
+ preload?: boolean;
902
+ preloadStaleTime?: number;
903
+ preloadGcTime?: number;
904
+ search?: {
905
+ middlewares?: Array<SearchMiddleware<ResolveFullSearchSchema<TParentRoute, TSearchValidator>>>;
906
+ };
907
+ /**
908
+ @deprecated Use search.middlewares instead
909
+ */
910
+ preSearchFilters?: Array<SearchFilter<ResolveFullSearchSchema<TParentRoute, TSearchValidator>>>;
911
+ /**
912
+ @deprecated Use search.middlewares instead
913
+ */
914
+ postSearchFilters?: Array<SearchFilter<ResolveFullSearchSchema<TParentRoute, TSearchValidator>>>;
915
+ onCatch?: (error: Error) => void;
916
+ onError?: (err: any) => void;
917
+ onEnter?: (match: RouteMatch$1<TRouteId, TFullPath, ResolveAllParamsFromParent<TParentRoute, TParams>, ResolveFullSearchSchema<TParentRoute, TSearchValidator>, ResolveLoaderData<TLoaderFn>, ResolveAllContext<TParentRoute, TRouterContext, TRouteContextFn, TBeforeLoadFn>, TLoaderDeps>) => void;
918
+ onStay?: (match: RouteMatch$1<TRouteId, TFullPath, ResolveAllParamsFromParent<TParentRoute, TParams>, ResolveFullSearchSchema<TParentRoute, TSearchValidator>, ResolveLoaderData<TLoaderFn>, ResolveAllContext<TParentRoute, TRouterContext, TRouteContextFn, TBeforeLoadFn>, TLoaderDeps>) => void;
919
+ onLeave?: (match: RouteMatch$1<TRouteId, TFullPath, ResolveAllParamsFromParent<TParentRoute, TParams>, ResolveFullSearchSchema<TParentRoute, TSearchValidator>, ResolveLoaderData<TLoaderFn>, ResolveAllContext<TParentRoute, TRouterContext, TRouteContextFn, TBeforeLoadFn>, TLoaderDeps>) => void;
920
+ headers?: (ctx: AssetFnContextOptions<TRouteId, TFullPath, TParentRoute, TParams, TSearchValidator, TLoaderFn, TRouterContext, TRouteContextFn, TBeforeLoadFn, TLoaderDeps>) => Awaitable<Record<string, string> | undefined>;
921
+ head?: (ctx: AssetFnContextOptions<TRouteId, TFullPath, TParentRoute, TParams, TSearchValidator, TLoaderFn, TRouterContext, TRouteContextFn, TBeforeLoadFn, TLoaderDeps>) => Awaitable<{
922
+ links?: AnyRouteMatch['links'];
923
+ scripts?: AnyRouteMatch['headScripts'];
924
+ meta?: AnyRouteMatch['meta'];
925
+ styles?: AnyRouteMatch['styles'];
926
+ }>;
927
+ scripts?: (ctx: AssetFnContextOptions<TRouteId, TFullPath, TParentRoute, TParams, TSearchValidator, TLoaderFn, TRouterContext, TRouteContextFn, TBeforeLoadFn, TLoaderDeps>) => Awaitable<AnyRouteMatch['scripts']>;
928
+ codeSplitGroupings?: Array<Array<'loader' | 'component' | 'pendingComponent' | 'notFoundComponent' | 'errorComponent'>>;
929
+ }
930
+ type RouteLoaderFn<in out TRegister, in out TParentRoute extends AnyRoute = AnyRoute, in out TId extends string = string, in out TParams = {}, in out TLoaderDeps = {}, in out TRouterContext = {}, in out TRouteContextFn = AnyContext, in out TBeforeLoadFn = AnyContext, in out TServerMiddlewares = unknown, in out THandlers = undefined> = (match: LoaderFnContext<TRegister, TParentRoute, TId, TParams, TLoaderDeps, TRouterContext, TRouteContextFn, TBeforeLoadFn, TServerMiddlewares, THandlers>) => any;
931
+ type LoaderStaleReloadMode = 'background' | 'blocking';
932
+ interface LoaderFnContext<in out TRegister = unknown, in out TParentRoute extends AnyRoute = AnyRoute, in out TId extends string = string, in out TParams = {}, in out TLoaderDeps = {}, in out TRouterContext = {}, in out TRouteContextFn = AnyContext, in out TBeforeLoadFn = AnyContext, in out TServerMiddlewares = unknown, in out THandlers = undefined> {
933
+ abortController: AbortController;
934
+ preload: boolean;
935
+ params: Expand<ResolveAllParamsFromParent<TParentRoute, TParams>>;
936
+ deps: TLoaderDeps;
937
+ context: Expand<ResolveAllContext<TParentRoute, TRouterContext, TRouteContextFn, TBeforeLoadFn>>;
938
+ location: ParsedLocation;
939
+ /**
940
+ * @deprecated Use `throw redirect({ to: '/somewhere' })` instead
941
+ **/
942
+ navigate: (opts: NavigateOptions<AnyRouter>) => Promise<void> | void;
943
+ parentMatchPromise: TId extends RootRouteId ? never : Promise<MakeRouteMatchFromRoute<TParentRoute>>;
944
+ cause: 'preload' | 'enter' | 'stay';
945
+ route: AnyRoute;
946
+ }
947
+ type RouteMask<TRouteTree extends AnyRoute> = {
948
+ routeTree: TRouteTree;
949
+ from: RoutePaths<TRouteTree>;
950
+ to?: any;
951
+ params?: any;
952
+ search?: any;
953
+ hash?: any;
954
+ state?: any;
955
+ unmaskOnReload?: boolean;
956
+ };
957
+ type ErrorComponentProps<TError = Error> = {
958
+ error: TError;
959
+ info?: {
960
+ componentStack: string;
961
+ };
962
+ reset: () => void;
963
+ };
964
+ type NotFoundRouteProps = {
965
+ data?: unknown;
966
+ isNotFound: boolean;
967
+ routeId: RouteIds<RegisteredRouter['routeTree']>;
968
+ };
969
+ //#endregion
970
+ //#region ../../node_modules/.pnpm/@tanstack+router-core@1.171.13/node_modules/@tanstack/router-core/dist/esm/validators.d.ts
971
+ interface StandardSchemaValidatorProps<TInput, TOutput> {
972
+ readonly types?: StandardSchemaValidatorTypes<TInput, TOutput> | undefined;
973
+ readonly validate: AnyStandardSchemaValidate;
974
+ }
975
+ interface StandardSchemaValidator<TInput, TOutput> {
976
+ readonly '~standard': StandardSchemaValidatorProps<TInput, TOutput>;
977
+ }
978
+ type AnyStandardSchemaValidator = StandardSchemaValidator<any, any>;
979
+ interface StandardSchemaValidatorTypes<TInput, TOutput> {
980
+ readonly input: TInput;
981
+ readonly output: TOutput;
982
+ }
983
+ interface AnyStandardSchemaValidateSuccess {
984
+ readonly value: any;
985
+ readonly issues?: undefined;
986
+ }
987
+ interface AnyStandardSchemaValidateFailure {
988
+ readonly issues: ReadonlyArray<AnyStandardSchemaValidateIssue>;
989
+ }
990
+ interface AnyStandardSchemaValidateIssue {
991
+ readonly message: string;
992
+ }
993
+ type AnyStandardSchemaValidate = (value: unknown) => (AnyStandardSchemaValidateSuccess | AnyStandardSchemaValidateFailure) | Promise<AnyStandardSchemaValidateSuccess | AnyStandardSchemaValidateFailure>;
994
+ interface ValidatorObj<TInput, TOutput> {
995
+ parse: ValidatorFn<TInput, TOutput>;
996
+ }
997
+ type AnyValidatorObj = ValidatorObj<any, any>;
998
+ interface ValidatorAdapter<TInput, TOutput> {
999
+ types: {
1000
+ input: TInput;
1001
+ output: TOutput;
1002
+ };
1003
+ parse: (input: unknown) => TOutput;
1004
+ }
1005
+ type AnyValidatorAdapter = ValidatorAdapter<any, any>;
1006
+ type ValidatorFn<TInput, TOutput> = (input: TInput) => TOutput;
1007
+ type Validator<TInput, TOutput> = ValidatorObj<TInput, TOutput> | ValidatorFn<TInput, TOutput> | ValidatorAdapter<TInput, TOutput> | StandardSchemaValidator<TInput, TOutput> | undefined;
1008
+ type AnyValidator = Validator<any, any>;
1009
+ type AnySchema = {};
1010
+ type DefaultValidator = Validator<Record<string, unknown>, AnySchema>;
1011
+ type ResolveSearchValidatorInputFn<TValidator> = TValidator extends ((input: infer TSchemaInput) => any) ? TSchemaInput extends SearchSchemaInput ? Omit<TSchemaInput, keyof SearchSchemaInput> : ResolveValidatorOutputFn<TValidator> : AnySchema;
1012
+ type ResolveSearchValidatorInput<TValidator> = TValidator extends AnyStandardSchemaValidator ? NonNullable<TValidator['~standard']['types']>['input'] : TValidator extends AnyValidatorAdapter ? TValidator['types']['input'] : TValidator extends AnyValidatorObj ? ResolveSearchValidatorInputFn<TValidator['parse']> : ResolveSearchValidatorInputFn<TValidator>;
1013
+ type ResolveValidatorOutputFn<TValidator> = TValidator extends ((...args: any) => infer TSchema) ? TSchema : AnySchema;
1014
+ type ResolveValidatorOutput<TValidator> = unknown extends TValidator ? TValidator : TValidator extends AnyStandardSchemaValidator ? NonNullable<TValidator['~standard']['types']>['output'] : TValidator extends AnyValidatorAdapter ? TValidator['types']['output'] : TValidator extends AnyValidatorObj ? ResolveValidatorOutputFn<TValidator['parse']> : ResolveValidatorOutputFn<TValidator>;
1015
+ //#endregion
1016
+ //#region ../../node_modules/.pnpm/@tanstack+router-core@1.171.13/node_modules/@tanstack/router-core/dist/esm/location.d.ts
1017
+ interface ParsedLocation<TSearchObj extends AnySchema = {}> {
1018
+ /**
1019
+ * The full path of the location, including pathname, search, and hash.
1020
+ * Does not include the origin. Is the equivalent of calling
1021
+ * `url.replace(url.origin, '')`
1022
+ */
1023
+ href: string;
1024
+ /**
1025
+ * @description The pathname of the location, including the leading slash.
1026
+ */
1027
+ pathname: string;
1028
+ /**
1029
+ * The parsed search parameters of the location in object form.
1030
+ */
1031
+ search: TSearchObj;
1032
+ /**
1033
+ * The search string of the location, including the leading question mark.
1034
+ */
1035
+ searchStr: string;
1036
+ /**
1037
+ * The in-memory state of the location as it *may* exist in the browser's history.
1038
+ */
1039
+ state: ParsedHistoryState;
1040
+ /**
1041
+ * The hash of the location, excluding the leading hash character.
1042
+ * (e.g., '123' instead of '#123')
1043
+ */
1044
+ hash: string;
1045
+ /**
1046
+ * The masked location of the location.
1047
+ */
1048
+ maskedLocation?: ParsedLocation<TSearchObj>;
1049
+ /**
1050
+ * Whether to unmask the location on reload.
1051
+ */
1052
+ unmaskOnReload?: boolean;
1053
+ /**
1054
+ * @private
1055
+ * @description The public href of the location.
1056
+ * If a rewrite is applied, the `href` property will be the rewritten URL.
1057
+ */
1058
+ publicHref: string;
1059
+ /**
1060
+ * @private
1061
+ * @description Whether the publicHref is external (different origin from rewrite).
1062
+ */
1063
+ external: boolean;
1064
+ }
1065
+ //#endregion
1066
+ //#region ../../node_modules/.pnpm/@tanstack+router-core@1.171.13/node_modules/@tanstack/router-core/dist/esm/load-matches.d.ts
1067
+ type RouteComponentType = 'component' | 'errorComponent' | 'pendingComponent' | 'notFoundComponent';
1068
+ declare function loadRouteChunk(route: AnyRoute, componentTypesToLoad?: Array<RouteComponentType>): Promise<void> | undefined;
1069
+ //#endregion
1070
+ //#region ../../node_modules/.pnpm/@tanstack+router-core@1.171.13/node_modules/@tanstack/router-core/dist/esm/lru-cache.d.ts
1071
+ type LRUCache<TKey, TValue> = {
1072
+ get: (key: TKey) => TValue | undefined;
1073
+ set: (key: TKey, value: TValue) => void;
1074
+ clear: () => void;
1075
+ };
1076
+ //#endregion
1077
+ //#region ../../node_modules/.pnpm/@tanstack+router-core@1.171.13/node_modules/@tanstack/router-core/dist/esm/new-process-route-tree.d.ts
1078
+ declare const SEGMENT_TYPE_PATHNAME = 0;
1079
+ declare const SEGMENT_TYPE_PARAM = 1;
1080
+ declare const SEGMENT_TYPE_WILDCARD = 2;
1081
+ declare const SEGMENT_TYPE_OPTIONAL_PARAM = 3;
1082
+ declare const SEGMENT_TYPE_INDEX = 4;
1083
+ declare const SEGMENT_TYPE_PATHLESS = 5;
1084
+ /**
1085
+ * All the kinds of segments that can be present in a route path.
1086
+ */
1087
+ type SegmentKind = typeof SEGMENT_TYPE_PATHNAME | typeof SEGMENT_TYPE_PARAM | typeof SEGMENT_TYPE_WILDCARD | typeof SEGMENT_TYPE_OPTIONAL_PARAM;
1088
+ /**
1089
+ * All the kinds of segments that can be present in the segment tree.
1090
+ */
1091
+ type ExtendedSegmentKind = SegmentKind | typeof SEGMENT_TYPE_INDEX | typeof SEGMENT_TYPE_PATHLESS;
1092
+ type StaticSegmentNode<T extends RouteLike> = SegmentNode<T> & {
1093
+ kind: typeof SEGMENT_TYPE_PATHNAME | typeof SEGMENT_TYPE_PATHLESS | typeof SEGMENT_TYPE_INDEX;
1094
+ };
1095
+ type DynamicSegmentNode<T extends RouteLike> = SegmentNode<T> & {
1096
+ kind: typeof SEGMENT_TYPE_PARAM | typeof SEGMENT_TYPE_WILDCARD | typeof SEGMENT_TYPE_OPTIONAL_PARAM;
1097
+ prefix?: string;
1098
+ suffix?: string;
1099
+ caseSensitive: boolean;
1100
+ };
1101
+ type AnySegmentNode<T extends RouteLike> = StaticSegmentNode<T> | DynamicSegmentNode<T>;
1102
+ type SegmentNode<T extends RouteLike> = {
1103
+ kind: ExtendedSegmentKind;
1104
+ pathless: Array<StaticSegmentNode<T>> | null; /** Exact index segment (highest priority) */
1105
+ index: StaticSegmentNode<T> | null; /** Static segments (2nd priority) */
1106
+ static: Map<string, StaticSegmentNode<T>> | null; /** Case insensitive static segments (3rd highest priority) */
1107
+ staticInsensitive: Map<string, StaticSegmentNode<T>> | null; /** Dynamic segments ($param) */
1108
+ dynamic: Array<DynamicSegmentNode<T>> | null; /** Optional dynamic segments ({-$param}) */
1109
+ optional: Array<DynamicSegmentNode<T>> | null; /** Wildcard segments ($ - lowest priority) */
1110
+ wildcard: Array<DynamicSegmentNode<T>> | null; /** Terminal route (if this path can end here) */
1111
+ route: T | null; /** The full path for this segment node (will only be valid on leaf nodes) */
1112
+ fullPath: string;
1113
+ parent: AnySegmentNode<T> | null;
1114
+ depth: number; /** route.options.params.parse function, set on the last node of the route */
1115
+ parse: null | ((params: Record<string, string>) => unknown); /** route.options.params.priority ?? 0 */
1116
+ priority: number;
1117
+ };
1118
+ type RouteLike = {
1119
+ id?: string;
1120
+ path?: string;
1121
+ children?: Array<RouteLike>;
1122
+ parentRoute?: RouteLike;
1123
+ isRoot?: boolean;
1124
+ options?: {
1125
+ caseSensitive?: boolean;
1126
+ parseParams?: (params: Record<string, string>) => unknown;
1127
+ params?: {
1128
+ parse?: (params: Record<string, string>) => unknown;
1129
+ priority?: number;
1130
+ };
1131
+ };
1132
+ } & ({
1133
+ fullPath: string;
1134
+ from?: never;
1135
+ } | {
1136
+ fullPath?: never;
1137
+ from: string;
1138
+ });
1139
+ type ProcessedTree<TTree extends Extract<RouteLike, {
1140
+ fullPath: string;
1141
+ }>, TFlat extends Extract<RouteLike, {
1142
+ from: string;
1143
+ }>, TSingle extends Extract<RouteLike, {
1144
+ from: string;
1145
+ }>> = {
1146
+ /** a representation of the `routeTree` as a segment tree */segmentTree: AnySegmentNode<TTree>; /** a mini route tree generated from the flat `routeMasks` list */
1147
+ masksTree: AnySegmentNode<TFlat> | null; /** @deprecated keep until v2 so that `router.matchRoute` can keep not caring about the actual route tree */
1148
+ singleCache: LRUCache<string, AnySegmentNode<TSingle>>; /** a cache of route matches from the `segmentTree` */
1149
+ matchCache: LRUCache<string, RouteMatch<TTree> | null>; /** a cache of route matches from the `masksTree` */
1150
+ flatCache: LRUCache<string, ReturnType<typeof findMatch<TFlat>>> | null;
1151
+ };
1152
+ type RouteMatch<T extends Extract<RouteLike, {
1153
+ fullPath: string;
1154
+ }>> = {
1155
+ route: T;
1156
+ rawParams: Record<string, string>;
1157
+ branch: ReadonlyArray<T>;
1158
+ };
1159
+ interface ProcessRouteTreeResult<TRouteLike extends Extract<RouteLike, {
1160
+ fullPath: string;
1161
+ }> & {
1162
+ id: string;
1163
+ }> {
1164
+ /** Should be considered a black box, needs to be provided to all matching functions in this module. */
1165
+ processedTree: ProcessedTree<TRouteLike, any, any>;
1166
+ /** A lookup map of routes by their unique IDs. */
1167
+ routesById: Record<string, TRouteLike>;
1168
+ /** A lookup map of routes by their trimmed full paths. */
1169
+ routesByPath: Record<string, TRouteLike>;
1170
+ }
1171
+ declare function findMatch<T extends RouteLike>(path: string, segmentTree: AnySegmentNode<T>, fuzzy?: boolean): {
1172
+ route: T;
1173
+ /**
1174
+ * The raw (unparsed) params extracted from the path.
1175
+ * This will be the exhaustive list of all params defined in the route's path.
1176
+ */
1177
+ rawParams: Record<string, string>;
1178
+ } | null;
1179
+ //#endregion
1180
+ //#region ../../node_modules/.pnpm/@tanstack+router-core@1.171.13/node_modules/@tanstack/router-core/dist/esm/searchParams.d.ts
1181
+ type SearchSerializer = (searchObj: Record<string, any>) => string;
1182
+ type SearchParser = (searchStr: string) => Record<string, any>;
1183
+ //#endregion
1184
+ //#region ../../node_modules/.pnpm/@tanstack+router-core@1.171.13/node_modules/@tanstack/router-core/dist/esm/manifest.d.ts
1185
+ type AssetCrossOrigin = 'anonymous' | 'use-credentials';
1186
+ type ScriptFormat = 'module' | 'iife';
1187
+ declare const DEV_STYLES_ATTR = "data-tanstack-router-dev-styles";
1188
+ type ManifestAssetLink = string | {
1189
+ href: string;
1190
+ crossOrigin?: AssetCrossOrigin;
1191
+ };
1192
+ type Manifest = {
1193
+ scriptFormat?: ScriptFormat;
1194
+ inlineStyle?: ManifestInlineCss;
1195
+ routes: Record<string, ManifestRoute>;
1196
+ };
1197
+ type ManifestRoute = {
1198
+ filePath?: string;
1199
+ preloads?: Array<ManifestAssetLink>;
1200
+ scripts?: Array<ManifestScript>;
1201
+ css?: Array<ManifestCssLink>;
1202
+ };
1203
+ type ManifestRouteAssets = Pick<ManifestRoute, 'preloads' | 'scripts' | 'css'>;
1204
+ type RouterManagedTitleTag = {
1205
+ tag: 'title';
1206
+ attrs?: Record<string, any>;
1207
+ children: string;
1208
+ };
1209
+ type RouterManagedMetaTag = {
1210
+ tag: 'meta';
1211
+ attrs?: Record<string, any>;
1212
+ children?: never;
1213
+ };
1214
+ type RouterManagedLinkTag = {
1215
+ tag: 'link';
1216
+ attrs?: Record<string, any>;
1217
+ children?: never;
1218
+ };
1219
+ type RouterManagedScriptTag = {
1220
+ tag: 'script';
1221
+ attrs?: Record<string, any>;
1222
+ children?: string;
1223
+ };
1224
+ type ManifestScript = Omit<RouterManagedScriptTag, 'tag'>;
1225
+ type RouterManagedStyleTag = {
1226
+ tag: 'style';
1227
+ attrs?: Record<string, any>;
1228
+ children?: string;
1229
+ inlineCss?: true;
1230
+ };
1231
+ type RouterManagedTag = RouterManagedTitleTag | RouterManagedMetaTag | RouterManagedLinkTag | RouterManagedScriptTag | RouterManagedStyleTag;
1232
+ type ManifestCssLink = string | {
1233
+ href: string;
1234
+ crossOrigin?: AssetCrossOrigin;
1235
+ [DEV_STYLES_ATTR]?: true;
1236
+ };
1237
+ type ManifestInlineCss = {
1238
+ attrs?: Record<string, any>;
1239
+ children?: string;
1240
+ };
1241
+ //#endregion
1242
+ //#region ../../node_modules/.pnpm/@tanstack+router-core@1.171.13/node_modules/@tanstack/router-core/dist/esm/stores.d.ts
1243
+ interface RouterReadableStore<TValue> {
1244
+ get: () => TValue;
1245
+ }
1246
+ interface RouterWritableStore<TValue> extends RouterReadableStore<TValue> {
1247
+ set: ((updater: (prev: TValue) => TValue) => void) & ((value: TValue) => void);
1248
+ }
1249
+ type RouterBatchFn = (fn: () => void) => void;
1250
+ type MutableStoreFactory = <TValue>(initialValue: TValue) => RouterWritableStore<TValue>;
1251
+ type ReadonlyStoreFactory = <TValue>(read: () => TValue) => RouterReadableStore<TValue>;
1252
+ type GetStoreConfig = (opts: {
1253
+ isServer?: boolean;
1254
+ }) => StoreConfig;
1255
+ type StoreConfig = {
1256
+ createMutableStore: MutableStoreFactory;
1257
+ createReadonlyStore: ReadonlyStoreFactory;
1258
+ batch: RouterBatchFn;
1259
+ init?: (stores: RouterStores<AnyRoute>) => void;
1260
+ };
1261
+ type MatchStore = RouterWritableStore<AnyRouteMatch> & {
1262
+ routeId?: string;
1263
+ };
1264
+ type ReadableStore<TValue> = RouterReadableStore<TValue>;
1265
+ /** SSR non-reactive createMutableStore */
1266
+ interface RouterStores<in out TRouteTree extends AnyRoute> {
1267
+ status: RouterWritableStore<RouterState<TRouteTree>['status']>;
1268
+ loadedAt: RouterWritableStore<number>;
1269
+ isLoading: RouterWritableStore<boolean>;
1270
+ isTransitioning: RouterWritableStore<boolean>;
1271
+ location: RouterWritableStore<ParsedLocation<FullSearchSchema<TRouteTree>>>;
1272
+ resolvedLocation: RouterWritableStore<ParsedLocation<FullSearchSchema<TRouteTree>> | undefined>;
1273
+ statusCode: RouterWritableStore<number>;
1274
+ redirect: RouterWritableStore<AnyRedirect | undefined>;
1275
+ matchesId: RouterWritableStore<Array<string>>;
1276
+ pendingIds: RouterWritableStore<Array<string>>;
1277
+ matches: ReadableStore<Array<AnyRouteMatch>>;
1278
+ pendingMatches: ReadableStore<Array<AnyRouteMatch>>;
1279
+ cachedMatches: ReadableStore<Array<AnyRouteMatch>>;
1280
+ firstId: ReadableStore<string | undefined>;
1281
+ hasPending: ReadableStore<boolean>;
1282
+ matchRouteDeps: ReadableStore<{
1283
+ locationHref: string;
1284
+ resolvedLocationHref: string | undefined;
1285
+ status: RouterState<TRouteTree>['status'];
1286
+ }>;
1287
+ __store: RouterReadableStore<RouterState<TRouteTree>>;
1288
+ matchStores: Map<string, MatchStore>;
1289
+ pendingMatchStores: Map<string, MatchStore>;
1290
+ cachedMatchStores: Map<string, MatchStore>;
1291
+ /**
1292
+ * Get a computed store that resolves a routeId to its current match state.
1293
+ * Returns the same cached store instance for repeated calls with the same key.
1294
+ * The computed depends on matchesId + the individual match store, so
1295
+ * subscribers are only notified when the resolved match state changes.
1296
+ */
1297
+ getRouteMatchStore: (routeId: string) => RouterReadableStore<AnyRouteMatch | undefined>;
1298
+ setMatches: (nextMatches: Array<AnyRouteMatch>) => void;
1299
+ setPending: (nextMatches: Array<AnyRouteMatch>) => void;
1300
+ setCached: (nextMatches: Array<AnyRouteMatch>) => void;
1301
+ }
1302
+ //#endregion
1303
+ //#region ../../node_modules/.pnpm/@tanstack+router-core@1.171.13/node_modules/@tanstack/router-core/dist/esm/router.d.ts
1304
+ interface Register {}
1305
+ type RegisteredSsr<TRegister = Register> = TRegister extends {
1306
+ ssr: infer TSSR;
1307
+ } ? TSSR : false;
1308
+ type RegisteredRouter<TRegister = Register> = TRegister extends {
1309
+ router: infer TRouter;
1310
+ } ? TRouter : AnyRouter;
1311
+ type RegisteredConfigType<TRegister, TKey> = TRegister extends {
1312
+ config: infer TConfig;
1313
+ } ? TConfig extends {
1314
+ '~types': infer TTypes;
1315
+ } ? TKey extends keyof TTypes ? TTypes[TKey] : unknown : unknown : unknown;
1316
+ type DefaultRemountDepsFn<TRouteTree extends AnyRoute> = (opts: MakeRemountDepsOptionsUnion<TRouteTree>) => any;
1317
+ interface DefaultRouterOptionsExtensions {}
1318
+ interface RouterOptionsExtensions extends DefaultRouterOptionsExtensions {}
1319
+ type SSROption = boolean | 'data-only';
1320
+ interface RouterOptions<TRouteTree extends AnyRoute, TTrailingSlashOption extends TrailingSlashOption, TDefaultStructuralSharingOption extends boolean = false, TRouterHistory extends RouterHistory = RouterHistory, TDehydrated = undefined> extends RouterOptionsExtensions {
1321
+ /**
1322
+ * The history object that will be used to manage the browser history.
1323
+ *
1324
+ * If not provided, a new createBrowserHistory instance will be created and used.
1325
+ *
1326
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#history-property)
1327
+ * @link [Guide](https://tanstack.com/router/latest/docs/framework/react/guide/history-types)
1328
+ */
1329
+ history?: TRouterHistory;
1330
+ /**
1331
+ * A function that will be used to stringify search params when generating links.
1332
+ *
1333
+ * @default defaultStringifySearch
1334
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#stringifysearch-method)
1335
+ * @link [Guide](https://tanstack.com/router/latest/docs/framework/react/guide/custom-search-param-serialization)
1336
+ */
1337
+ stringifySearch?: SearchSerializer;
1338
+ /**
1339
+ * A function that will be used to parse search params when parsing the current location.
1340
+ *
1341
+ * @default defaultParseSearch
1342
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#parsesearch-method)
1343
+ * @link [Guide](https://tanstack.com/router/latest/docs/framework/react/guide/custom-search-param-serialization)
1344
+ */
1345
+ parseSearch?: SearchParser;
1346
+ /**
1347
+ * If `false`, routes will not be preloaded by default in any way.
1348
+ *
1349
+ * If `'intent'`, routes will be preloaded by default when the user hovers over a link or a `touchstart` event is detected on a `<Link>`.
1350
+ *
1351
+ * If `'viewport'`, routes will be preloaded by default when they are within the viewport.
1352
+ *
1353
+ * @default false
1354
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#defaultpreload-property)
1355
+ * @link [Guide](https://tanstack.com/router/latest/docs/framework/react/guide/preloading)
1356
+ */
1357
+ defaultPreload?: false | 'intent' | 'viewport' | 'render';
1358
+ /**
1359
+ * The delay in milliseconds that a route must be hovered over or touched before it is preloaded.
1360
+ *
1361
+ * @default 50
1362
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#defaultpreloaddelay-property)
1363
+ * @link [Guide](https://tanstack.com/router/latest/docs/framework/react/guide/preloading#preload-delay)
1364
+ */
1365
+ defaultPreloadDelay?: number;
1366
+ /**
1367
+ * The default `preloadIntentProximity` a route should use if no preloadIntentProximity is provided.
1368
+ *
1369
+ * @default 0
1370
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#defaultpreloadintentproximity-property)
1371
+ * @link [Guide](https://tanstack.com/router/latest/docs/framework/react/guide/preloading#preload-intent-proximity)
1372
+ */
1373
+ defaultPreloadIntentProximity?: number;
1374
+ /**
1375
+ * The default `pendingMs` a route should use if no pendingMs is provided.
1376
+ *
1377
+ * @default 1000
1378
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#defaultpendingms-property)
1379
+ * @link [Guide](https://tanstack.com/router/latest/docs/framework/react/guide/data-loading#avoiding-pending-component-flash)
1380
+ */
1381
+ defaultPendingMs?: number;
1382
+ /**
1383
+ * The default `pendingMinMs` a route should use if no pendingMinMs is provided.
1384
+ *
1385
+ * @default 500
1386
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#defaultpendingminms-property)
1387
+ * @link [Guide](https://tanstack.com/router/latest/docs/framework/react/guide/data-loading#avoiding-pending-component-flash)
1388
+ */
1389
+ defaultPendingMinMs?: number;
1390
+ /**
1391
+ * The default `staleTime` a route should use if no staleTime is provided. This is the time in milliseconds that a route will be considered fresh.
1392
+ *
1393
+ * @default 0
1394
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#defaultstaletime-property)
1395
+ * @link [Guide](https://tanstack.com/router/latest/docs/framework/react/guide/data-loading#key-options)
1396
+ */
1397
+ defaultStaleTime?: number;
1398
+ /**
1399
+ * The default stale reload mode a route loader should use if no `loader.staleReloadMode` is provided.
1400
+ *
1401
+ * `'background'` preserves the current stale-while-revalidate behavior.
1402
+ * `'blocking'` waits for stale loader reloads to complete before resolving navigation.
1403
+ *
1404
+ * @default 'background'
1405
+ */
1406
+ defaultStaleReloadMode?: LoaderStaleReloadMode;
1407
+ /**
1408
+ * The default `preloadStaleTime` a route should use if no preloadStaleTime is provided.
1409
+ *
1410
+ * @default 30_000 `(30 seconds)`
1411
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#defaultpreloadstaletime-property)
1412
+ * @link [Guide](https://tanstack.com/router/latest/docs/framework/react/guide/preloading)
1413
+ */
1414
+ defaultPreloadStaleTime?: number;
1415
+ /**
1416
+ * The default `defaultPreloadGcTime` a route should use if no preloadGcTime is provided.
1417
+ *
1418
+ * @default 1_800_000 `(30 minutes)`
1419
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#defaultpreloadgctime-property)
1420
+ * @link [Guide](https://tanstack.com/router/latest/docs/framework/react/guide/preloading)
1421
+ */
1422
+ defaultPreloadGcTime?: number;
1423
+ /**
1424
+ * If `true`, route navigations will called using `document.startViewTransition()`.
1425
+ *
1426
+ * If the browser does not support this api, this option will be ignored.
1427
+ *
1428
+ * See [MDN](https://developer.mozilla.org/en-US/docs/Web/API/Document/startViewTransition) for more information on how this function works.
1429
+ *
1430
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#defaultviewtransition-property)
1431
+ */
1432
+ defaultViewTransition?: boolean | ViewTransitionOptions;
1433
+ /**
1434
+ * The default `hashScrollIntoView` a route should use if no hashScrollIntoView is provided while navigating
1435
+ *
1436
+ * See [MDN](https://developer.mozilla.org/en-US/docs/Web/API/Element/scrollIntoView) for more information on `ScrollIntoViewOptions`.
1437
+ *
1438
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#defaulthashscrollintoview-property)
1439
+ */
1440
+ defaultHashScrollIntoView?: boolean | ScrollIntoViewOptions;
1441
+ /**
1442
+ * @default 'fuzzy'
1443
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#notfoundmode-property)
1444
+ * @link [Guide](https://tanstack.com/router/latest/docs/framework/react/guide/not-found-errors#the-notfoundmode-option)
1445
+ */
1446
+ notFoundMode?: 'root' | 'fuzzy';
1447
+ /**
1448
+ * The default `gcTime` a route should use if no gcTime is provided.
1449
+ *
1450
+ * @default 1_800_000 `(30 minutes)`
1451
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#defaultgctime-property)
1452
+ * @link [Guide](https://tanstack.com/router/latest/docs/framework/react/guide/data-loading#key-options)
1453
+ */
1454
+ defaultGcTime?: number;
1455
+ /**
1456
+ * If `true`, all routes will be matched as case-sensitive.
1457
+ *
1458
+ * @default false
1459
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#casesensitive-property)
1460
+ */
1461
+ caseSensitive?: boolean;
1462
+ /**
1463
+ *
1464
+ * The route tree that will be used to configure the router instance.
1465
+ *
1466
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#routetree-property)
1467
+ * @link [Guide](https://tanstack.com/router/latest/docs/framework/react/routing/route-trees)
1468
+ */
1469
+ routeTree?: TRouteTree;
1470
+ /**
1471
+ * The basepath for then entire router. This is useful for mounting a router instance at a subpath.
1472
+ * ```
1473
+ * @default '/'
1474
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#basepath-property)
1475
+ */
1476
+ basepath?: string;
1477
+ /**
1478
+ * The root context that will be provided to all routes in the route tree.
1479
+ *
1480
+ * This can be used to provide a context to all routes in the tree without having to provide it to each route individually.
1481
+ *
1482
+ * Optional or required if the root route was created with [`createRootRouteWithContext()`](https://tanstack.com/router/latest/docs/framework/react/api/router/createRootRouteWithContextFunction).
1483
+ *
1484
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#context-property)
1485
+ * @link [Guide](https://tanstack.com/router/latest/docs/framework/react/guide/router-context)
1486
+ */
1487
+ context?: InferRouterContext<TRouteTree>;
1488
+ additionalContext?: any;
1489
+ /**
1490
+ * A function that will be called when the router is dehydrated.
1491
+ *
1492
+ * The return value of this function will be serialized and stored in the router's dehydrated state.
1493
+ *
1494
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#dehydrate-method)
1495
+ * @link [Guide](https://tanstack.com/router/latest/docs/framework/react/guide/external-data-loading#critical-dehydrationhydration)
1496
+ */
1497
+ dehydrate?: () => Awaitable<Constrain<TDehydrated, ValidateSerializableInput<Register, TDehydrated>>>;
1498
+ /**
1499
+ * A function that will be called when the router is hydrated.
1500
+ *
1501
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#hydrate-method)
1502
+ * @link [Guide](https://tanstack.com/router/latest/docs/framework/react/guide/external-data-loading#critical-dehydrationhydration)
1503
+ */
1504
+ hydrate?: (dehydrated: TDehydrated) => Awaitable<void>;
1505
+ /**
1506
+ * An array of route masks that will be used to mask routes in the route tree.
1507
+ *
1508
+ * Route masking is when you display a route at a different path than the one it is configured to match, like a modal popup that when shared will unmask to the modal's content instead of the modal's context.
1509
+ *
1510
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#routemasks-property)
1511
+ * @link [Guide](https://tanstack.com/router/latest/docs/framework/react/guide/route-masking)
1512
+ */
1513
+ routeMasks?: Array<RouteMask<TRouteTree>>;
1514
+ /**
1515
+ * If `true`, route masks will, by default, be removed when the page is reloaded.
1516
+ *
1517
+ * This can be overridden on a per-mask basis by setting the `unmaskOnReload` option on the mask, or on a per-navigation basis by setting the `unmaskOnReload` option in the `Navigate` options.
1518
+ *
1519
+ * @default false
1520
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#unmaskonreload-property)
1521
+ * @link [Guide](https://tanstack.com/router/latest/docs/framework/react/guide/route-masking#unmasking-on-page-reload)
1522
+ */
1523
+ unmaskOnReload?: boolean;
1524
+ /**
1525
+ * Use `notFoundComponent` instead.
1526
+ *
1527
+ * @deprecated
1528
+ * See https://tanstack.com/router/v1/docs/guide/not-found-errors#migrating-from-notfoundroute for more info.
1529
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#notfoundroute-property)
1530
+ */
1531
+ notFoundRoute?: AnyRoute;
1532
+ /**
1533
+ * Configures how trailing slashes are treated.
1534
+ *
1535
+ * - `'always'` will add a trailing slash if not present
1536
+ * - `'never'` will remove the trailing slash if present
1537
+ * - `'preserve'` will not modify the trailing slash.
1538
+ *
1539
+ * @default 'never'
1540
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#trailingslash-property)
1541
+ */
1542
+ trailingSlash?: TTrailingSlashOption;
1543
+ /**
1544
+ * While usually automatic, sometimes it can be useful to force the router into a server-side state, e.g. when using the router in a non-browser environment that has access to a global.document object.
1545
+ *
1546
+ * @default typeof document !== 'undefined'
1547
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#isserver-property)
1548
+ */
1549
+ isServer?: boolean;
1550
+ /**
1551
+ * @default false
1552
+ */
1553
+ isShell?: boolean;
1554
+ /**
1555
+ * @default false
1556
+ */
1557
+ isPrerendering?: boolean;
1558
+ /**
1559
+ * The default `ssr` a route should use if no `ssr` is provided.
1560
+ *
1561
+ * @default true
1562
+ */
1563
+ defaultSsr?: SSROption;
1564
+ search?: {
1565
+ /**
1566
+ * Configures how unknown search params (= not returned by any `validateSearch`) are treated.
1567
+ *
1568
+ * @default false
1569
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#search.strict-property)
1570
+ */
1571
+ strict?: boolean;
1572
+ };
1573
+ /**
1574
+ * Configures whether structural sharing is enabled by default for fine-grained selectors.
1575
+ *
1576
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#defaultstructuralsharing-property)
1577
+ */
1578
+ defaultStructuralSharing?: TDefaultStructuralSharingOption;
1579
+ /**
1580
+ * Configures which URI characters are allowed in path params that would ordinarily be escaped by encodeURIComponent.
1581
+ *
1582
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#pathparamsallowedcharacters-property)
1583
+ * @link [Guide](https://tanstack.com/router/latest/docs/framework/react/guide/path-params#allowed-characters)
1584
+ */
1585
+ pathParamsAllowedCharacters?: Array<';' | ':' | '@' | '&' | '=' | '+' | '$' | ','>;
1586
+ defaultRemountDeps?: DefaultRemountDepsFn<TRouteTree>;
1587
+ /**
1588
+ * If `true`, scroll restoration will be enabled
1589
+ *
1590
+ * @default false
1591
+ */
1592
+ scrollRestoration?: boolean | ((opts: {
1593
+ location: ParsedLocation;
1594
+ }) => boolean);
1595
+ /**
1596
+ * A function that will be called to get the key for the scroll restoration cache.
1597
+ *
1598
+ * @default (location) => location.href
1599
+ */
1600
+ getScrollRestorationKey?: (location: ParsedLocation) => string;
1601
+ /**
1602
+ * The default behavior for scroll restoration.
1603
+ *
1604
+ * @default 'auto'
1605
+ */
1606
+ scrollRestorationBehavior?: ScrollBehavior;
1607
+ /**
1608
+ * An array of selectors that will be used to scroll to the top of the page in addition to `window`
1609
+ *
1610
+ * @default ['window']
1611
+ */
1612
+ scrollToTopSelectors?: Array<string | (() => Element | null | undefined)>;
1613
+ /**
1614
+ * When `true`, disables the global catch boundary that normally wraps all route matches.
1615
+ * This allows unhandled errors to bubble up to top-level error handlers in the browser.
1616
+ *
1617
+ * Useful for testing tools (like Storybook Test Runner), error reporting services,
1618
+ * and debugging scenarios where you want errors to reach the browser's global error handlers.
1619
+ *
1620
+ * @default false
1621
+ */
1622
+ disableGlobalCatchBoundary?: boolean;
1623
+ /**
1624
+ * An array of URL protocols to allow in links, redirects, and navigation.
1625
+ * Absolute URLs with protocols not in this list will be rejected.
1626
+ *
1627
+ * @default DEFAULT_PROTOCOL_ALLOWLIST (http:, https:, mailto:, tel:)
1628
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#protocolallowlist-property)
1629
+ */
1630
+ protocolAllowlist?: Array<string>;
1631
+ serializationAdapters?: ReadonlyArray<AnySerializationAdapter>;
1632
+ /**
1633
+ * Configures how the router will rewrite the location between the actual href and the internal href of the router.
1634
+ *
1635
+ * @default undefined
1636
+ * @description You can provide a custom rewrite pair (in/out).
1637
+ * This is useful for shifting data from the origin to the path (for things like subdomain routing), or other advanced use cases.
1638
+ */
1639
+ rewrite?: LocationRewrite;
1640
+ origin?: string;
1641
+ ssr?: {
1642
+ nonce?: string;
1643
+ };
1644
+ }
1645
+ type LocationRewrite = {
1646
+ /**
1647
+ * A function that will be called to rewrite the URL before it is interpreted by the router from the history instance.
1648
+ *
1649
+ * @default undefined
1650
+ */
1651
+ input?: LocationRewriteFunction;
1652
+ /**
1653
+ * A function that will be called to rewrite the URL before it is committed to the actual history instance from the router.
1654
+ *
1655
+ * @default undefined
1656
+ */
1657
+ output?: LocationRewriteFunction;
1658
+ };
1659
+ /**
1660
+ * A function that will be called to rewrite the URL.
1661
+ *
1662
+ * @param url The URL to rewrite.
1663
+ * @returns The rewritten URL (as a URL instance or full href string) or undefined if no rewrite is needed.
1664
+ */
1665
+ type LocationRewriteFunction = ({
1666
+ url
1667
+ }: {
1668
+ url: URL;
1669
+ }) => undefined | string | URL;
1670
+ interface RouterState<in out TRouteTree extends AnyRoute = AnyRoute, in out TRouteMatch = MakeRouteMatchUnion> {
1671
+ status: 'pending' | 'idle';
1672
+ loadedAt: number;
1673
+ isLoading: boolean;
1674
+ isTransitioning: boolean;
1675
+ matches: Array<TRouteMatch>;
1676
+ location: ParsedLocation<FullSearchSchema<TRouteTree>>;
1677
+ resolvedLocation?: ParsedLocation<FullSearchSchema<TRouteTree>>;
1678
+ statusCode: number;
1679
+ redirect?: AnyRedirect;
1680
+ }
1681
+ interface BuildNextOptions {
1682
+ to?: string | number | null;
1683
+ params?: true | Updater<unknown>;
1684
+ search?: true | Updater<unknown>;
1685
+ hash?: true | Updater<string>;
1686
+ state?: true | NonNullableUpdater<ParsedHistoryState, HistoryState>;
1687
+ mask?: {
1688
+ to?: string | number | null;
1689
+ params?: true | Updater<unknown>;
1690
+ search?: true | Updater<unknown>;
1691
+ hash?: true | Updater<string>;
1692
+ state?: true | NonNullableUpdater<ParsedHistoryState, HistoryState>;
1693
+ unmaskOnReload?: boolean;
1694
+ };
1695
+ from?: string;
1696
+ href?: string;
1697
+ _fromLocation?: ParsedLocation;
1698
+ unsafeRelative?: 'path';
1699
+ _isNavigate?: boolean;
1700
+ }
1701
+ type NavigationEventInfo = {
1702
+ fromLocation?: ParsedLocation;
1703
+ toLocation: ParsedLocation;
1704
+ pathChanged: boolean;
1705
+ hrefChanged: boolean;
1706
+ hashChanged: boolean;
1707
+ };
1708
+ interface RouterEvents {
1709
+ onBeforeNavigate: {
1710
+ type: 'onBeforeNavigate';
1711
+ } & NavigationEventInfo;
1712
+ onBeforeLoad: {
1713
+ type: 'onBeforeLoad';
1714
+ } & NavigationEventInfo;
1715
+ onLoad: {
1716
+ type: 'onLoad';
1717
+ } & NavigationEventInfo;
1718
+ onResolved: {
1719
+ type: 'onResolved';
1720
+ } & NavigationEventInfo;
1721
+ onBeforeRouteMount: {
1722
+ type: 'onBeforeRouteMount';
1723
+ } & NavigationEventInfo;
1724
+ onRendered: {
1725
+ type: 'onRendered';
1726
+ } & NavigationEventInfo;
1727
+ }
1728
+ type RouterEvent = RouterEvents[keyof RouterEvents];
1729
+ type ListenerFn<TEvent extends RouterEvent> = (event: TEvent) => void;
1730
+ type RouterListener<TRouterEvent extends RouterEvent> = {
1731
+ eventType: TRouterEvent['type'];
1732
+ fn: ListenerFn<TRouterEvent>;
1733
+ };
1734
+ type SubscribeFn = <TType extends keyof RouterEvents>(eventType: TType, fn: ListenerFn<RouterEvents[TType]>) => () => void;
1735
+ interface MatchRoutesOpts {
1736
+ preload?: boolean;
1737
+ throwOnError?: boolean;
1738
+ dest?: BuildNextOptions;
1739
+ }
1740
+ type InferRouterContext<TRouteTree extends AnyRoute> = TRouteTree['types']['routerContext'];
1741
+ type RouterContextOptions<TRouteTree extends AnyRoute> = AnyContext extends InferRouterContext<TRouteTree> ? {
1742
+ context?: InferRouterContext<TRouteTree>;
1743
+ } : {
1744
+ context: InferRouterContext<TRouteTree>;
1745
+ };
1746
+ type RouterConstructorOptions<TRouteTree extends AnyRoute, TTrailingSlashOption extends TrailingSlashOption, TDefaultStructuralSharingOption extends boolean, TRouterHistory extends RouterHistory, TDehydrated extends Record<string, any>> = Omit<RouterOptions<TRouteTree, TTrailingSlashOption, TDefaultStructuralSharingOption, TRouterHistory, TDehydrated>, 'context' | 'serializationAdapters' | 'defaultSsr'> & RouterContextOptions<TRouteTree>;
1747
+ type PreloadRouteFn<TRouteTree extends AnyRoute, TTrailingSlashOption extends TrailingSlashOption, TDefaultStructuralSharingOption extends boolean, TRouterHistory extends RouterHistory> = <TFrom extends RoutePaths<TRouteTree> | string = string, TTo extends string | undefined = undefined, TMaskFrom extends RoutePaths<TRouteTree> | string = TFrom, TMaskTo extends string = ''>(opts: NavigateOptions<RouterCore<TRouteTree, TTrailingSlashOption, TDefaultStructuralSharingOption, TRouterHistory>, TFrom, TTo, TMaskFrom, TMaskTo> & {}) => Promise<Array<AnyRouteMatch> | undefined>;
1748
+ type MatchRouteFn<TRouteTree extends AnyRoute, TTrailingSlashOption extends TrailingSlashOption, TDefaultStructuralSharingOption extends boolean, TRouterHistory extends RouterHistory> = <TFrom extends RoutePaths<TRouteTree> = '/', TTo extends string | undefined = undefined, TResolved = ResolveRelativePath<TFrom, NoInfer<TTo>>>(location: ToOptions<RouterCore<TRouteTree, TTrailingSlashOption, TDefaultStructuralSharingOption, TRouterHistory>, TFrom, TTo>, opts?: MatchRouteOptions) => false | RouteById<TRouteTree, TResolved>['types']['allParams'];
1749
+ type UpdateFn<TRouteTree extends AnyRoute, TTrailingSlashOption extends TrailingSlashOption, TDefaultStructuralSharingOption extends boolean, TRouterHistory extends RouterHistory, TDehydrated extends Record<string, any>> = (newOptions: RouterConstructorOptions<TRouteTree, TTrailingSlashOption, TDefaultStructuralSharingOption, TRouterHistory, TDehydrated>) => void;
1750
+ type InvalidateFn<TRouter extends AnyRouter> = (opts?: {
1751
+ filter?: (d: MakeRouteMatchUnion<TRouter>) => boolean;
1752
+ sync?: boolean;
1753
+ forcePending?: boolean;
1754
+ }) => Promise<void>;
1755
+ type ParseLocationFn<TRouteTree extends AnyRoute> = (locationToParse: HistoryLocation$1, previousLocation?: ParsedLocation<FullSearchSchema<TRouteTree>>) => ParsedLocation<FullSearchSchema<TRouteTree>>;
1756
+ type GetMatchRoutesFn = (pathname: string) => {
1757
+ matchedRoutes: ReadonlyArray<AnyRoute>; /** exhaustive params, still in their string form */
1758
+ routeParams: Record<string, string>;
1759
+ foundRoute: AnyRoute | undefined;
1760
+ parseError?: unknown;
1761
+ };
1762
+ type EmitFn = (routerEvent: RouterEvent) => void;
1763
+ type LoadFn = (opts?: {
1764
+ sync?: boolean;
1765
+ action?: {
1766
+ type: HistoryAction;
1767
+ };
1768
+ }) => Promise<void>;
1769
+ type CommitLocationFn = ({
1770
+ viewTransition,
1771
+ ignoreBlocker,
1772
+ ...next
1773
+ }: ParsedLocation & CommitLocationOptions) => Promise<void>;
1774
+ type StartTransitionFn = (fn: () => void) => void;
1775
+ interface MatchRoutesFn {
1776
+ (pathname: string, locationSearch?: AnySchema, opts?: MatchRoutesOpts): Array<MakeRouteMatchUnion>;
1777
+ /**
1778
+ * @deprecated use the following signature instead
1779
+ */
1780
+ (next: ParsedLocation, opts?: MatchRoutesOpts): Array<AnyRouteMatch>;
1781
+ (pathnameOrNext: string | ParsedLocation, locationSearchOrOpts?: AnySchema | MatchRoutesOpts, opts?: MatchRoutesOpts): Array<AnyRouteMatch>;
1782
+ }
1783
+ type GetMatchFn = (matchId: string) => AnyRouteMatch | undefined;
1784
+ type UpdateMatchFn = (id: string, updater: (match: AnyRouteMatch) => AnyRouteMatch) => void;
1785
+ type ClearCacheFn<TRouter extends AnyRouter> = (opts?: {
1786
+ filter?: (d: MakeRouteMatchUnion<TRouter>) => boolean;
1787
+ }) => void;
1788
+ interface ServerSsr {
1789
+ /** Framework-only: injects router-owned HTML into the SSR stream. */
1790
+ injectHtml: (html: string) => void;
1791
+ /** Framework-only: injects a router-owned script tag into the SSR stream. */
1792
+ injectScript: (script: string) => void;
1793
+ isDehydrated: () => boolean;
1794
+ isSerializationFinished: () => boolean;
1795
+ /** Framework-only: atomically reserves the pass-through stream path if safe. */
1796
+ reserveStreamFastPath: () => boolean;
1797
+ /** Framework-only. */
1798
+ onInjectedHtml: (listener: () => void) => () => void;
1799
+ /** Framework-only. */
1800
+ onRenderFinished: (listener: () => void) => void;
1801
+ /** Framework-only. */
1802
+ setRenderFinished: () => void;
1803
+ /** Framework-only. */
1804
+ cleanup: () => void;
1805
+ /**
1806
+ * Register a listener invoked when the SSR request lifecycle ends (success,
1807
+ * error, abort, or stream lifetime expiry). Use to tear down per-request
1808
+ * resources whose references would otherwise pin the router (e.g. query
1809
+ * cache subscriptions, gcTime timers, abort controllers).
1810
+ *
1811
+ * Listeners run synchronously and exactly once. Errors are caught and logged.
1812
+ */
1813
+ onCleanup: (listener: () => void) => void;
1814
+ /** Framework-only. */
1815
+ onSerializationFinished: (listener: () => void) => () => void;
1816
+ /** Framework-only. */
1817
+ dehydrate: (opts?: {
1818
+ requestAssets?: ManifestRouteAssets;
1819
+ }) => Promise<void>;
1820
+ /** Framework-only. */
1821
+ takeBufferedScripts: () => RouterManagedTag | undefined;
1822
+ /** Framework-only: takes buffered router-owned HTML. */
1823
+ takeBufferedHtml: () => string | undefined;
1824
+ /** Framework-only. */
1825
+ liftScriptBarrier: () => void;
1826
+ }
1827
+ interface RouterSsrLifecycle {
1828
+ onServerSsrAttach?: Array<(serverSsr: ServerSsr) => void>;
1829
+ }
1830
+ type AnyRouter = RouterCore<any, any, any, any, any>;
1831
+ interface ViewTransitionOptions {
1832
+ types: Array<string> | ((locationChangeInfo: {
1833
+ fromLocation?: ParsedLocation;
1834
+ toLocation: ParsedLocation;
1835
+ pathChanged: boolean;
1836
+ hrefChanged: boolean;
1837
+ hashChanged: boolean;
1838
+ }) => Array<string> | false);
1839
+ }
1840
+ /** Options for configuring trailing-slash behavior. */
1841
+ declare const trailingSlashOptions: {
1842
+ readonly always: "always";
1843
+ readonly never: "never";
1844
+ readonly preserve: "preserve";
1845
+ };
1846
+ type TrailingSlashOption = (typeof trailingSlashOptions)[keyof typeof trailingSlashOptions];
1847
+ declare global {
1848
+ var __TSR_CACHE__: {
1849
+ routeTree: AnyRoute;
1850
+ processRouteTreeResult: ProcessRouteTreeResult<AnyRoute>;
1851
+ resolvePathCache: LRUCache<string, string>;
1852
+ } | undefined;
1853
+ }
1854
+ /**
1855
+ * Core, framework-agnostic router engine that powers TanStack Router.
1856
+ *
1857
+ * Provides navigation, matching, loading, preloading, caching and event APIs
1858
+ * used by framework adapters (React/Solid). Prefer framework helpers like
1859
+ * `createRouter` in app code.
1860
+ *
1861
+ * @link https://tanstack.com/router/latest/docs/framework/react/api/router/RouterType
1862
+ */
1863
+ declare class RouterCore<in out TRouteTree extends AnyRoute, in out TTrailingSlashOption extends TrailingSlashOption, in out TDefaultStructuralSharingOption extends boolean, in out TRouterHistory extends RouterHistory = RouterHistory, in out TDehydrated extends Record<string, any> = Record<string, any>> {
1864
+ tempLocationKey: string | undefined;
1865
+ _scroll: {
1866
+ next: boolean;
1867
+ restoring?: boolean;
1868
+ restoration?: boolean;
1869
+ reset?: boolean;
1870
+ };
1871
+ shouldViewTransition?: boolean | ViewTransitionOptions;
1872
+ isViewTransitionTypesSupported?: boolean;
1873
+ subscribers: Set<RouterListener<RouterEvent>>;
1874
+ viewTransitionPromise?: ControlledPromise<true>;
1875
+ stores: RouterStores<TRouteTree>;
1876
+ private getStoreConfig;
1877
+ batch: (fn: () => void) => void;
1878
+ options: PickAsRequired<RouterOptions<TRouteTree, TTrailingSlashOption, TDefaultStructuralSharingOption, TRouterHistory, TDehydrated>, 'stringifySearch' | 'parseSearch' | 'context'>;
1879
+ history: TRouterHistory;
1880
+ rewrite?: LocationRewrite;
1881
+ origin?: string;
1882
+ latestLocation: ParsedLocation<FullSearchSchema<TRouteTree>>;
1883
+ pendingBuiltLocation?: ParsedLocation<FullSearchSchema<TRouteTree>>;
1884
+ basepath: string;
1885
+ routeTree: TRouteTree;
1886
+ routesById: RoutesById<TRouteTree>;
1887
+ routesByPath: RoutesByPath<TRouteTree>;
1888
+ processedTree: ProcessedTree<TRouteTree, any, any>;
1889
+ resolvePathCache: LRUCache<string, string>;
1890
+ private routeBranchCache;
1891
+ isServer: boolean;
1892
+ pathParamsDecoder?: (encoded: string) => string;
1893
+ protocolAllowlist: Set<string>;
1894
+ /**
1895
+ * @deprecated Use the `createRouter` function instead
1896
+ */
1897
+ constructor(options: RouterConstructorOptions<TRouteTree, TTrailingSlashOption, TDefaultStructuralSharingOption, TRouterHistory, TDehydrated>, getStoreConfig: GetStoreConfig);
1898
+ startTransition: StartTransitionFn;
1899
+ isShell(): boolean;
1900
+ isPrerendering(): boolean;
1901
+ update: UpdateFn<TRouteTree, TTrailingSlashOption, TDefaultStructuralSharingOption, TRouterHistory, TDehydrated>;
1902
+ get state(): RouterState<TRouteTree>;
1903
+ updateLatestLocation: () => void;
1904
+ buildRouteTree: () => ProcessRouteTreeResult<TRouteTree>;
1905
+ setRoutes({
1906
+ routesById,
1907
+ routesByPath,
1908
+ processedTree
1909
+ }: ProcessRouteTreeResult<TRouteTree>): void;
1910
+ /**
1911
+ * Subscribe to router lifecycle events like `onBeforeNavigate`, `onLoad`,
1912
+ * `onResolved`, etc. Returns an unsubscribe function.
1913
+ *
1914
+ * @link https://tanstack.com/router/latest/docs/framework/react/api/router/RouterEventsType
1915
+ */
1916
+ subscribe: SubscribeFn;
1917
+ emit: EmitFn;
1918
+ /**
1919
+ * Parse a HistoryLocation into a strongly-typed ParsedLocation using the
1920
+ * current router options, rewrite rules and search parser/stringifier.
1921
+ */
1922
+ parseLocation: ParseLocationFn<TRouteTree>;
1923
+ /** Resolve a path using the router's trailing-slash policy. */
1924
+ resolvePathWithBase: (from: string, path: string) => string;
1925
+ private getRouteBranch;
1926
+ get looseRoutesById(): Record<string, AnyRoute>;
1927
+ matchRoutes: MatchRoutesFn;
1928
+ private getParentContext;
1929
+ private matchRoutesInternal;
1930
+ getMatchedRoutes: GetMatchRoutesFn;
1931
+ /**
1932
+ * Lightweight route matching for buildLocation.
1933
+ * Only computes fullPath, accumulated search, and params - skipping expensive
1934
+ * operations like AbortController, ControlledPromise, loaderDeps, and full match objects.
1935
+ */
1936
+ private matchRoutesLightweight;
1937
+ cancelMatch: (id: string) => void;
1938
+ cancelMatches: () => void;
1939
+ /**
1940
+ * Build the next ParsedLocation from navigation options without committing.
1941
+ * Resolves `to`/`from`, params/search/hash/state, applies search validation
1942
+ * and middlewares, and returns a stable, stringified location object.
1943
+ *
1944
+ * @link https://tanstack.com/router/latest/docs/framework/react/api/router/RouterType#buildlocation-method
1945
+ */
1946
+ buildLocation: BuildLocationFn;
1947
+ commitLocationPromise: undefined | ControlledPromise<void>;
1948
+ /**
1949
+ * Commit a previously built location to history (push/replace), optionally
1950
+ * using view transitions and scroll restoration options.
1951
+ */
1952
+ commitLocation: CommitLocationFn;
1953
+ /** Convenience helper: build a location from options, then commit it. */
1954
+ buildAndCommitLocation: ({
1955
+ replace,
1956
+ resetScroll,
1957
+ hashScrollIntoView,
1958
+ viewTransition,
1959
+ ignoreBlocker,
1960
+ href,
1961
+ ...rest
1962
+ }?: BuildNextOptions & CommitLocationOptions) => Promise<void>;
1963
+ /**
1964
+ * Imperatively navigate using standard `NavigateOptions`. When `reloadDocument`
1965
+ * or an absolute `href` is provided, performs a full document navigation.
1966
+ * Otherwise, builds and commits a client-side location.
1967
+ *
1968
+ * @link https://tanstack.com/router/latest/docs/framework/react/api/router/NavigateOptionsType
1969
+ */
1970
+ navigate: NavigateFn;
1971
+ latestLoadPromise: undefined | Promise<void>;
1972
+ beforeLoad: () => void;
1973
+ load: LoadFn;
1974
+ startViewTransition: (fn: () => Promise<void>) => void;
1975
+ updateMatch: UpdateMatchFn;
1976
+ getMatch: GetMatchFn;
1977
+ /**
1978
+ * Invalidate the current matches and optionally force them back into a pending state.
1979
+ *
1980
+ * - Marks all matches that pass the optional `filter` as `invalid: true`.
1981
+ * - If `forcePending` is true, or a match is currently in `'error'` or `'notFound'` status,
1982
+ * its status is reset to `'pending'` and its `error` cleared so that the loader is re-run
1983
+ * on the next `load()` call (eg. after HMR or a manual invalidation).
1984
+ */
1985
+ invalidate: InvalidateFn<RouterCore<TRouteTree, TTrailingSlashOption, TDefaultStructuralSharingOption, TRouterHistory, TDehydrated>>;
1986
+ getParsedLocationHref: (location: ParsedLocation) => string;
1987
+ resolveRedirect: (redirect: AnyRedirect) => AnyRedirect;
1988
+ clearCache: ClearCacheFn<this>;
1989
+ clearExpiredCache: () => void;
1990
+ loadRouteChunk: typeof loadRouteChunk;
1991
+ preloadRoute: PreloadRouteFn<TRouteTree, TTrailingSlashOption, TDefaultStructuralSharingOption, TRouterHistory>;
1992
+ matchRoute: MatchRouteFn<TRouteTree, TTrailingSlashOption, TDefaultStructuralSharingOption, TRouterHistory>;
1993
+ ssr?: {
1994
+ manifest: Manifest | undefined;
1995
+ };
1996
+ serverSsr?: ServerSsr;
1997
+ serverSsrLifecycle?: RouterSsrLifecycle;
1998
+ hasNotFoundMatch: () => boolean;
1999
+ }
2000
+ //#endregion
2001
+ //#region ../../node_modules/.pnpm/@tanstack+router-core@1.171.13/node_modules/@tanstack/router-core/dist/esm/global.d.ts
2002
+ declare global {
2003
+ interface Window {
2004
+ __TSR_ROUTER__?: AnyRouter;
2005
+ }
2006
+ }
2007
+ //#endregion
2008
+ //#region ../../node_modules/.pnpm/@tanstack+router-core@1.171.13/node_modules/@tanstack/router-core/dist/esm/structuralSharing.d.ts
2009
+ interface OptionalStructuralSharing<TStructuralSharing, TConstraint> {
2010
+ readonly structuralSharing?: Constrain<TStructuralSharing, TConstraint> | undefined;
2011
+ }
2012
+ //#endregion
2013
+ //#region ../../node_modules/.pnpm/@tanstack+router-core@1.171.13/node_modules/@tanstack/router-core/dist/esm/useRouteContext.d.ts
2014
+ interface UseRouteContextBaseOptions<TRouter extends AnyRouter, TFrom, TStrict extends boolean, TSelected> {
2015
+ select?: (search: ResolveUseRouteContext<TRouter, TFrom, TStrict>) => TSelected;
2016
+ }
2017
+ type ResolveUseRouteContext<TRouter extends AnyRouter, TFrom, TStrict extends boolean> = TStrict extends false ? AllContext<TRouter['routeTree']> : Expand<RouteById<TRouter['routeTree'], TFrom>['types']['allContext']>;
2018
+ type UseRouteContextResult<TRouter extends AnyRouter, TFrom, TStrict extends boolean, TSelected> = unknown extends TSelected ? ResolveUseRouteContext<TRouter, TFrom, TStrict> : TSelected;
2019
+ //#endregion
2020
+ //#region ../../node_modules/.pnpm/@tanstack+router-core@1.171.13/node_modules/@tanstack/router-core/dist/esm/useSearch.d.ts
2021
+ type UseSearchResult<TRouter extends AnyRouter, TFrom, TStrict extends boolean, TSelected> = unknown extends TSelected ? ResolveUseSearch<TRouter, TFrom, TStrict> : TSelected;
2022
+ type ResolveUseSearch<TRouter extends AnyRouter, TFrom, TStrict extends boolean> = TStrict extends false ? FullSearchSchema<TRouter['routeTree']> : Expand<RouteById<TRouter['routeTree'], TFrom>['types']['fullSearchSchema']>;
2023
+ //#endregion
2024
+ //#region ../../node_modules/.pnpm/@tanstack+router-core@1.171.13/node_modules/@tanstack/router-core/dist/esm/useParams.d.ts
2025
+ type ResolveUseParams<TRouter extends AnyRouter, TFrom, TStrict extends boolean> = TStrict extends false ? AllParams<TRouter['routeTree']> : Expand<RouteById<TRouter['routeTree'], TFrom>['types']['allParams']>;
2026
+ type UseParamsResult<TRouter extends AnyRouter, TFrom, TStrict extends boolean, TSelected> = unknown extends TSelected ? ResolveUseParams<TRouter, TFrom, TStrict> : TSelected;
2027
+ //#endregion
2028
+ //#region ../../node_modules/.pnpm/@tanstack+router-core@1.171.13/node_modules/@tanstack/router-core/dist/esm/useNavigate.d.ts
2029
+ type UseNavigateResult<TDefaultFrom extends string> = <TRouter extends RegisteredRouter, TTo extends string | undefined, TFrom extends string = TDefaultFrom, TMaskFrom extends string = TFrom, TMaskTo extends string = ''>({
2030
+ from,
2031
+ ...rest
2032
+ }: NavigateOptions<TRouter, TFrom, TTo, TMaskFrom, TMaskTo>) => Promise<void>;
2033
+ //#endregion
2034
+ //#region ../../node_modules/.pnpm/@tanstack+router-core@1.171.13/node_modules/@tanstack/router-core/dist/esm/useLoaderDeps.d.ts
2035
+ type ResolveUseLoaderDeps<TRouter extends AnyRouter, TFrom> = Expand<RouteById<TRouter['routeTree'], TFrom>['types']['loaderDeps']>;
2036
+ type UseLoaderDepsResult<TRouter extends AnyRouter, TFrom, TSelected> = unknown extends TSelected ? ResolveUseLoaderDeps<TRouter, TFrom> : TSelected;
2037
+ //#endregion
2038
+ //#region ../../node_modules/.pnpm/@tanstack+router-core@1.171.13/node_modules/@tanstack/router-core/dist/esm/useLoaderData.d.ts
2039
+ type ResolveUseLoaderData<TRouter extends AnyRouter, TFrom, TStrict extends boolean> = TStrict extends false ? AllLoaderData<TRouter['routeTree']> : Expand<RouteById<TRouter['routeTree'], TFrom>['types']['loaderData']>;
2040
+ type UseLoaderDataResult<TRouter extends AnyRouter, TFrom, TStrict extends boolean, TSelected> = unknown extends TSelected ? ResolveUseLoaderData<TRouter, TFrom, TStrict> : TSelected;
2041
+ //#endregion
2042
+ //#region ../../node_modules/.pnpm/@tanstack+react-router@1.170.15_react-dom@19.2.7_react@19.2.7__react@19.2.7/node_modules/@tanstack/react-router/dist/esm/structuralSharing.d.ts
2043
+ type DefaultStructuralSharingEnabled<TRouter extends AnyRouter> = boolean extends TRouter['options']['defaultStructuralSharing'] ? false : NonNullable<TRouter['options']['defaultStructuralSharing']>;
2044
+ interface RequiredStructuralSharing<TStructuralSharing, TConstraint> {
2045
+ readonly structuralSharing: Constrain<TStructuralSharing, TConstraint>;
2046
+ }
2047
+ type StructuralSharingOption<TRouter extends AnyRouter, TSelected, TStructuralSharing> = unknown extends TSelected ? OptionalStructuralSharing<TStructuralSharing, boolean> : unknown extends TRouter['routeTree'] ? OptionalStructuralSharing<TStructuralSharing, boolean> : TSelected extends ValidateJSON<TSelected> ? OptionalStructuralSharing<TStructuralSharing, boolean> : DefaultStructuralSharingEnabled<TRouter> extends true ? RequiredStructuralSharing<TStructuralSharing, false> : OptionalStructuralSharing<TStructuralSharing, false>;
2048
+ type StructuralSharingEnabled<TRouter extends AnyRouter, TStructuralSharing> = boolean extends TStructuralSharing ? DefaultStructuralSharingEnabled<TRouter> : TStructuralSharing;
2049
+ type ValidateSelected<TRouter extends AnyRouter, TSelected, TStructuralSharing> = StructuralSharingEnabled<TRouter, TStructuralSharing> extends true ? ValidateJSON<TSelected> : TSelected;
2050
+ //#endregion
2051
+ //#region ../../node_modules/.pnpm/@tanstack+react-router@1.170.15_react-dom@19.2.7_react@19.2.7__react@19.2.7/node_modules/@tanstack/react-router/dist/esm/useLoaderData.d.ts
2052
+ interface UseLoaderDataBaseOptions<TRouter extends AnyRouter, TFrom, TStrict extends boolean, TSelected, TStructuralSharing> {
2053
+ select?: (match: ResolveUseLoaderData<TRouter, TFrom, TStrict>) => ValidateSelected<TRouter, TSelected, TStructuralSharing>;
2054
+ }
2055
+ type UseLoaderDataRoute<out TId> = <TRouter extends AnyRouter = RegisteredRouter, TSelected = unknown, TStructuralSharing extends boolean = boolean>(opts?: UseLoaderDataBaseOptions<TRouter, TId, true, TSelected, TStructuralSharing> & StructuralSharingOption<TRouter, TSelected, TStructuralSharing>) => UseLoaderDataResult<TRouter, TId, true, TSelected>;
2056
+ //#endregion
2057
+ //#region ../../node_modules/.pnpm/@tanstack+react-router@1.170.15_react-dom@19.2.7_react@19.2.7__react@19.2.7/node_modules/@tanstack/react-router/dist/esm/useMatch.d.ts
2058
+ interface UseMatchBaseOptions<TRouter extends AnyRouter, TFrom, TStrict extends boolean, TThrow extends boolean, TSelected, TStructuralSharing extends boolean> {
2059
+ select?: (match: MakeRouteMatch<TRouter['routeTree'], TFrom, TStrict>) => ValidateSelected<TRouter, TSelected, TStructuralSharing>;
2060
+ shouldThrow?: TThrow;
2061
+ }
2062
+ type UseMatchRoute<out TFrom> = <TRouter extends AnyRouter = RegisteredRouter, TSelected = unknown, TStructuralSharing extends boolean = boolean>(opts?: UseMatchBaseOptions<TRouter, TFrom, true, true, TSelected, TStructuralSharing> & StructuralSharingOption<TRouter, TSelected, TStructuralSharing>) => UseMatchResult<TRouter, TFrom, true, TSelected>;
2063
+ type UseMatchResult<TRouter extends AnyRouter, TFrom, TStrict extends boolean, TSelected> = unknown extends TSelected ? TStrict extends true ? MakeRouteMatch<TRouter['routeTree'], TFrom, TStrict> : MakeRouteMatchUnion<TRouter> : TSelected;
2064
+ //#endregion
2065
+ //#region ../../node_modules/.pnpm/@tanstack+react-router@1.170.15_react-dom@19.2.7_react@19.2.7__react@19.2.7/node_modules/@tanstack/react-router/dist/esm/useLoaderDeps.d.ts
2066
+ interface UseLoaderDepsBaseOptions<TRouter extends AnyRouter, TFrom, TSelected, TStructuralSharing> {
2067
+ select?: (deps: ResolveUseLoaderDeps<TRouter, TFrom>) => ValidateSelected<TRouter, TSelected, TStructuralSharing>;
2068
+ }
2069
+ type UseLoaderDepsRoute<out TId> = <TRouter extends AnyRouter = RegisteredRouter, TSelected = unknown, TStructuralSharing extends boolean = boolean>(opts?: UseLoaderDepsBaseOptions<TRouter, TId, TSelected, TStructuralSharing> & StructuralSharingOption<TRouter, TSelected, TStructuralSharing>) => UseLoaderDepsResult<TRouter, TId, TSelected>;
2070
+ //#endregion
2071
+ //#region ../../node_modules/.pnpm/@tanstack+react-router@1.170.15_react-dom@19.2.7_react@19.2.7__react@19.2.7/node_modules/@tanstack/react-router/dist/esm/useParams.d.ts
2072
+ interface UseParamsBaseOptions<TRouter extends AnyRouter, TFrom, TStrict extends boolean, TThrow extends boolean, TSelected, TStructuralSharing> {
2073
+ select?: (params: ResolveUseParams<TRouter, TFrom, TStrict>) => ValidateSelected<TRouter, TSelected, TStructuralSharing>;
2074
+ shouldThrow?: TThrow;
2075
+ }
2076
+ type UseParamsRoute<out TFrom> = <TRouter extends AnyRouter = RegisteredRouter, TSelected = unknown, TStructuralSharing extends boolean = boolean>(opts?: UseParamsBaseOptions<TRouter, TFrom, true, true, TSelected, TStructuralSharing> & StructuralSharingOption<TRouter, TSelected, TStructuralSharing>) => UseParamsResult<TRouter, TFrom, true, TSelected>;
2077
+ //#endregion
2078
+ //#region ../../node_modules/.pnpm/@tanstack+react-router@1.170.15_react-dom@19.2.7_react@19.2.7__react@19.2.7/node_modules/@tanstack/react-router/dist/esm/useSearch.d.ts
2079
+ interface UseSearchBaseOptions<TRouter extends AnyRouter, TFrom, TStrict extends boolean, TThrow extends boolean, TSelected, TStructuralSharing> {
2080
+ select?: (state: ResolveUseSearch<TRouter, TFrom, TStrict>) => ValidateSelected<TRouter, TSelected, TStructuralSharing>;
2081
+ shouldThrow?: TThrow;
2082
+ }
2083
+ type UseSearchRoute<out TFrom> = <TRouter extends AnyRouter = RegisteredRouter, TSelected = unknown, TStructuralSharing extends boolean = boolean>(opts?: UseSearchBaseOptions<TRouter, TFrom, true, true, TSelected, TStructuralSharing> & StructuralSharingOption<TRouter, TSelected, TStructuralSharing>) => UseSearchResult<TRouter, TFrom, true, TSelected>;
2084
+ //#endregion
2085
+ //#region ../../node_modules/.pnpm/@tanstack+react-router@1.170.15_react-dom@19.2.7_react@19.2.7__react@19.2.7/node_modules/@tanstack/react-router/dist/esm/useRouteContext.d.ts
2086
+ type UseRouteContextRoute<out TFrom> = <TRouter extends AnyRouter = RegisteredRouter, TSelected = unknown>(opts?: UseRouteContextBaseOptions<TRouter, TFrom, true, TSelected>) => UseRouteContextResult<TRouter, TFrom, true, TSelected>;
2087
+ //#endregion
2088
+ //#region ../../node_modules/.pnpm/@tanstack+react-router@1.170.15_react-dom@19.2.7_react@19.2.7__react@19.2.7/node_modules/@tanstack/react-router/dist/esm/link.d.ts
2089
+ type UseLinkReactProps<TComp> = TComp extends keyof React$2.JSX.IntrinsicElements ? React$2.JSX.IntrinsicElements[TComp] : TComp extends React$2.ComponentType<any> ? React$2.ComponentPropsWithoutRef<TComp> & React$2.RefAttributes<React$2.ComponentRef<TComp>> : never;
2090
+ type ActiveLinkOptions<TComp = 'a', TRouter extends AnyRouter = RegisteredRouter, TFrom extends string = string, TTo extends string | undefined = '.', TMaskFrom extends string = TFrom, TMaskTo extends string = '.'> = LinkOptions<TRouter, TFrom, TTo, TMaskFrom, TMaskTo> & ActiveLinkOptionProps<TComp>;
2091
+ type ActiveLinkProps<TComp> = Partial<LinkComponentReactProps<TComp> & {
2092
+ [key: `data-${string}`]: unknown;
2093
+ }>;
2094
+ interface ActiveLinkOptionProps<TComp = 'a'> {
2095
+ /**
2096
+ * A function that returns additional props for the `active` state of this link.
2097
+ * These props override other props passed to the link (`style`'s are merged, `className`'s are concatenated)
2098
+ */
2099
+ activeProps?: ActiveLinkProps<TComp> | (() => ActiveLinkProps<TComp>);
2100
+ /**
2101
+ * A function that returns additional props for the `inactive` state of this link.
2102
+ * These props override other props passed to the link (`style`'s are merged, `className`'s are concatenated)
2103
+ */
2104
+ inactiveProps?: ActiveLinkProps<TComp> | (() => ActiveLinkProps<TComp>);
2105
+ }
2106
+ type LinkProps<TComp = 'a', TRouter extends AnyRouter = RegisteredRouter, TFrom extends string = string, TTo extends string | undefined = '.', TMaskFrom extends string = TFrom, TMaskTo extends string = '.'> = ActiveLinkOptions<TComp, TRouter, TFrom, TTo, TMaskFrom, TMaskTo> & LinkPropsChildren;
2107
+ interface LinkPropsChildren {
2108
+ children?: React$2.ReactNode | ((state: {
2109
+ isActive: boolean;
2110
+ isTransitioning: boolean;
2111
+ }) => React$2.ReactNode);
2112
+ }
2113
+ type LinkComponentReactProps<TComp> = Omit<UseLinkReactProps<TComp>, keyof CreateLinkProps>;
2114
+ type LinkComponentProps<TComp = 'a', TRouter extends AnyRouter = RegisteredRouter, TFrom extends string = string, TTo extends string | undefined = '.', TMaskFrom extends string = TFrom, TMaskTo extends string = '.'> = LinkComponentReactProps<TComp> & LinkProps<TComp, TRouter, TFrom, TTo, TMaskFrom, TMaskTo>;
2115
+ type CreateLinkProps = LinkProps<any, any, string, string, string, string>;
2116
+ interface LinkComponentRoute<in out TDefaultFrom extends string = string> {
2117
+ defaultFrom: TDefaultFrom;
2118
+ <TRouter extends AnyRouter = RegisteredRouter, const TTo extends string | undefined = undefined, const TMaskTo extends string = ''>(props: LinkComponentProps<'a', TRouter, this['defaultFrom'], TTo, this['defaultFrom'], TMaskTo>): React$2.ReactElement;
2119
+ }
2120
+ //#endregion
2121
+ //#region ../../node_modules/.pnpm/@tanstack+react-router@1.170.15_react-dom@19.2.7_react@19.2.7__react@19.2.7/node_modules/@tanstack/react-router/dist/esm/route.d.ts
2122
+ declare module '@tanstack/router-core' {
2123
+ interface UpdatableRouteOptionsExtensions {
2124
+ component?: RouteComponent;
2125
+ errorComponent?: false | null | undefined | ErrorRouteComponent;
2126
+ notFoundComponent?: NotFoundRouteComponent;
2127
+ pendingComponent?: RouteComponent;
2128
+ }
2129
+ interface RootRouteOptionsExtensions {
2130
+ shellComponent?: ({
2131
+ children
2132
+ }: {
2133
+ children: React$1.ReactNode;
2134
+ }) => React$1.ReactNode;
2135
+ }
2136
+ interface RouteExtensions<in out TId extends string, in out TFullPath extends string> {
2137
+ useMatch: UseMatchRoute<TId>;
2138
+ useRouteContext: UseRouteContextRoute<TId>;
2139
+ useSearch: UseSearchRoute<TId>;
2140
+ useParams: UseParamsRoute<TId>;
2141
+ useLoaderDeps: UseLoaderDepsRoute<TId>;
2142
+ useLoaderData: UseLoaderDataRoute<TId>;
2143
+ useNavigate: () => UseNavigateResult<TFullPath>;
2144
+ Link: LinkComponentRoute<TFullPath>;
2145
+ }
2146
+ }
2147
+ /**
2148
+ * Returns a route-specific API that exposes type-safe hooks pre-bound
2149
+ * to a single route ID. Useful for consuming a route's APIs from files
2150
+ * where the route object isn't directly imported (e.g. code-split files).
2151
+ *
2152
+ * @param id Route ID string literal for the target route.
2153
+ * @returns A `RouteApi` instance bound to the given route ID.
2154
+ * @link https://tanstack.com/router/latest/docs/framework/react/api/router/getRouteApiFunction
2155
+ */
2156
+ interface DefaultRouteTypes<TProps> {
2157
+ component: ((props: TProps) => any) | React$1.LazyExoticComponent<(props: TProps) => any>;
2158
+ }
2159
+ interface RouteTypes<TProps> extends DefaultRouteTypes<TProps> {}
2160
+ type AsyncRouteComponent<TProps> = RouteTypes<TProps>['component'] & {
2161
+ preload?: () => Promise<void>;
2162
+ };
2163
+ type RouteComponent = AsyncRouteComponent<{}>;
2164
+ type ErrorRouteComponent = AsyncRouteComponent<ErrorComponentProps>;
2165
+ type NotFoundRouteComponent = RouteTypes<NotFoundRouteProps>['component'];
2166
+ //#endregion
2167
+ //#region ../../node_modules/.pnpm/@tanstack+react-router@1.170.15_react-dom@19.2.7_react@19.2.7__react@19.2.7/node_modules/@tanstack/react-router/dist/esm/fileRoute.d.ts
2168
+ declare module '@tanstack/router-core' {
2169
+ interface LazyRoute<in out TRoute extends AnyRoute> {
2170
+ useMatch: UseMatchRoute<TRoute['id']>;
2171
+ useRouteContext: UseRouteContextRoute<TRoute['id']>;
2172
+ useSearch: UseSearchRoute<TRoute['id']>;
2173
+ useParams: UseParamsRoute<TRoute['id']>;
2174
+ useLoaderDeps: UseLoaderDepsRoute<TRoute['id']>;
2175
+ useLoaderData: UseLoaderDataRoute<TRoute['id']>;
2176
+ useNavigate: () => UseNavigateResult<TRoute['fullPath']>;
2177
+ }
2178
+ }
2179
+ //#endregion
2180
+ //#region ../../node_modules/.pnpm/@tanstack+react-router@1.170.15_react-dom@19.2.7_react@19.2.7__react@19.2.7/node_modules/@tanstack/react-router/dist/esm/history.d.ts
2181
+ declare module '@tanstack/history' {
2182
+ interface HistoryState {
2183
+ __tempLocation?: HistoryLocation;
2184
+ __tempKey?: string;
2185
+ __hashScrollIntoViewOptions?: boolean | ScrollIntoViewOptions;
2186
+ }
2187
+ }
2188
+ //#endregion
2189
+ //#region ../../node_modules/.pnpm/@tanstack+react-router@1.170.15_react-dom@19.2.7_react@19.2.7__react@19.2.7/node_modules/@tanstack/react-router/dist/esm/Matches.d.ts
2190
+ declare module '@tanstack/router-core' {
2191
+ interface RouteMatchExtensions {
2192
+ meta?: Array<React$2.JSX.IntrinsicElements['meta'] | undefined>;
2193
+ links?: Array<React$2.JSX.IntrinsicElements['link'] | undefined>;
2194
+ scripts?: Array<React$2.JSX.IntrinsicElements['script'] | undefined>;
2195
+ styles?: Array<React$2.JSX.IntrinsicElements['style'] | undefined>;
2196
+ headScripts?: Array<React$2.JSX.IntrinsicElements['script'] | undefined>;
2197
+ }
2198
+ }
2199
+ /**
2200
+ * Internal component that renders the router's active match tree with
2201
+ * suspense, error, and not-found boundaries. Rendered by `RouterProvider`.
2202
+ */
2203
+ //#endregion
2204
+ //#region ../../node_modules/.pnpm/@tanstack+react-router@1.170.15_react-dom@19.2.7_react@19.2.7__react@19.2.7/node_modules/@tanstack/react-router/dist/esm/router.d.ts
2205
+ declare module '@tanstack/router-core' {
2206
+ interface RouterOptionsExtensions {
2207
+ /**
2208
+ * The default `component` a route should use if no component is provided.
2209
+ *
2210
+ * @default Outlet
2211
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#defaultcomponent-property)
2212
+ */
2213
+ defaultComponent?: RouteComponent;
2214
+ /**
2215
+ * The default `errorComponent` a route should use if no error component is provided.
2216
+ *
2217
+ * @default ErrorComponent
2218
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#defaulterrorcomponent-property)
2219
+ * @link [Guide](https://tanstack.com/router/latest/docs/framework/react/guide/data-loading#handling-errors-with-routeoptionserrorcomponent)
2220
+ */
2221
+ defaultErrorComponent?: ErrorRouteComponent;
2222
+ /**
2223
+ * The default `pendingComponent` a route should use if no pending component is provided.
2224
+ *
2225
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#defaultpendingcomponent-property)
2226
+ * @link [Guide](https://tanstack.com/router/latest/docs/framework/react/guide/data-loading#showing-a-pending-component)
2227
+ */
2228
+ defaultPendingComponent?: RouteComponent;
2229
+ /**
2230
+ * The default `notFoundComponent` a route should use if no notFound component is provided.
2231
+ *
2232
+ * @default NotFound
2233
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#defaultnotfoundcomponent-property)
2234
+ * @link [Guide](https://tanstack.com/router/latest/docs/framework/react/guide/not-found-errors#default-router-wide-not-found-handling)
2235
+ */
2236
+ defaultNotFoundComponent?: NotFoundRouteComponent;
2237
+ /**
2238
+ * A component that will be used to wrap the entire router.
2239
+ *
2240
+ * This is useful for providing a context to the entire router.
2241
+ *
2242
+ * Only non-DOM-rendering components like providers should be used, anything else will cause a hydration error.
2243
+ *
2244
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#wrap-property)
2245
+ */
2246
+ Wrap?: (props: {
2247
+ children: any;
2248
+ }) => React.JSX.Element;
2249
+ /**
2250
+ * A component that will be used to wrap the inner contents of the router.
2251
+ *
2252
+ * This is useful for providing a context to the inner contents of the router where you also need access to the router context and hooks.
2253
+ *
2254
+ * Only non-DOM-rendering components like providers should be used, anything else will cause a hydration error.
2255
+ *
2256
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#innerwrap-property)
2257
+ */
2258
+ InnerWrap?: (props: {
2259
+ children: any;
2260
+ }) => React.JSX.Element;
2261
+ /**
2262
+ * The default `onCatch` handler for errors caught by the Router ErrorBoundary
2263
+ *
2264
+ * @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#defaultoncatch-property)
2265
+ * @link [Guide](https://tanstack.com/router/latest/docs/framework/react/guide/data-loading#handling-errors-with-routeoptionsoncatch)
2266
+ */
2267
+ defaultOnCatch?: (error: Error, errorInfo: React.ErrorInfo) => void;
2268
+ }
2269
+ }
2270
+ /**
2271
+ * Creates a new Router instance for React.
2272
+ *
2273
+ * Pass the returned router to `RouterProvider` to enable routing.
2274
+ * Notable options: `routeTree` (your route definitions) and `context`
2275
+ * (required if the root route was created with `createRootRouteWithContext`).
2276
+ *
2277
+ * @param options Router options used to configure the router.
2278
+ * @returns A Router instance to be provided to `RouterProvider`.
2279
+ * @link https://tanstack.com/router/latest/docs/framework/react/api/router/createRouterFunction
2280
+ */
2281
+ //#endregion
2282
+ //#region ../../node_modules/.pnpm/@tanstack+react-router@1.170.15_react-dom@19.2.7_react@19.2.7__react@19.2.7/node_modules/@tanstack/react-router/dist/esm/ssr/serializer.d.ts
2283
+ declare module '@tanstack/router-core' {
2284
+ interface SerializerExtensions {
2285
+ ReadableStream: React$2.JSX.Element;
2286
+ }
2287
+ }
2288
+ //#endregion
2289
+ //#region src/loaders.d.ts
2290
+ /**
2291
+ * Wrap a TanStack route loader with OpenTelemetry tracing
2292
+ *
2293
+ * This function wraps a loader function to automatically create spans
2294
+ * for each invocation. It captures route ID, params (optionally),
2295
+ * and errors.
2296
+ *
2297
+ * The generic type TLoaderFn preserves the full TanStack Router type inference,
2298
+ * including typed params, context, and return types.
2299
+ *
2300
+ * @param loaderFn - The loader function to wrap
2301
+ * @param config - Configuration options
2302
+ * @returns Wrapped loader function with tracing (preserves original types)
2303
+ *
2304
+ * @example
2305
+ * ```typescript
2306
+ * import { createFileRoute } from '@tanstack/react-router';
2307
+ * import { traceLoader } from 'autotel-tanstack/loaders';
2308
+ *
2309
+ * export const Route = createFileRoute('/users/$userId')({
2310
+ * // Types are fully preserved - params.userId is typed as string
2311
+ * loader: traceLoader(async ({ params }) => {
2312
+ * return await db.users.findUnique({ where: { id: params.userId } });
2313
+ * }),
2314
+ * });
2315
+ * ```
2316
+ *
2317
+ * @example
2318
+ * ```typescript
2319
+ * // Sync loaders are also supported
2320
+ * export const Route = createFileRoute('/static')({
2321
+ * loader: traceLoader(({ context }) => ({
2322
+ * message: `Welcome, ${context.userId}!`,
2323
+ * })),
2324
+ * });
2325
+ * ```
2326
+ */
2327
+ declare function traceLoader<TLoaderFn extends (ctx: any) => any>(loaderFn: TLoaderFn, config?: TraceLoaderConfig): TLoaderFn;
2328
+ /**
2329
+ * Wrap a TanStack route beforeLoad function with OpenTelemetry tracing
2330
+ *
2331
+ * This function wraps a beforeLoad function to automatically create spans.
2332
+ * beforeLoad runs before the route component renders and is typically
2333
+ * used for auth checks, redirects, or data prefetching.
2334
+ *
2335
+ * The generic type TBeforeLoadFn preserves the full TanStack Router type inference,
2336
+ * including typed params, context, search, and return types.
2337
+ *
2338
+ * @param beforeLoadFn - The beforeLoad function to wrap
2339
+ * @param config - Configuration options
2340
+ * @returns Wrapped beforeLoad function with tracing (preserves original types)
2341
+ *
2342
+ * @example
2343
+ * ```typescript
2344
+ * import { createFileRoute, redirect } from '@tanstack/react-router';
2345
+ * import { traceBeforeLoad } from 'autotel-tanstack/loaders';
2346
+ *
2347
+ * export const Route = createFileRoute('/dashboard')({
2348
+ * // Types are fully preserved - context, params, search are all typed
2349
+ * beforeLoad: traceBeforeLoad(async ({ context, params }) => {
2350
+ * if (!context.auth.isAuthenticated) {
2351
+ * throw redirect({ to: '/login' });
2352
+ * }
2353
+ * return { userId: params.userId }; // Return type flows to loader context
2354
+ * }),
2355
+ * loader: ({ context }) => {
2356
+ * // context.userId is typed from beforeLoad return
2357
+ * return { user: context.userId };
2358
+ * },
2359
+ * });
2360
+ * ```
2361
+ */
2362
+ declare function traceBeforeLoad<TBeforeLoadFn extends (opts: any) => any>(beforeLoadFn: TBeforeLoadFn, config?: TraceLoaderConfig): TBeforeLoadFn;
2363
+ /**
2364
+ * Create a traced route configuration helper
2365
+ *
2366
+ * This higher-order function helps create route configurations
2367
+ * with automatic tracing for both loader and beforeLoad.
2368
+ *
2369
+ * @param routeId - The route identifier
2370
+ * @param config - Tracing configuration
2371
+ * @returns Object with traced loader and beforeLoad wrappers
2372
+ *
2373
+ * @example
2374
+ * ```typescript
2375
+ * import { createFileRoute } from '@tanstack/react-router';
2376
+ * import { createTracedRoute } from 'autotel-tanstack/loaders';
2377
+ *
2378
+ * const traced = createTracedRoute('/users/$userId');
2379
+ *
2380
+ * export const Route = createFileRoute('/users/$userId')({
2381
+ * beforeLoad: traced.beforeLoad(async ({ context }) => {
2382
+ * // Auth check
2383
+ * }),
2384
+ * loader: traced.loader(async ({ params }) => {
2385
+ * return await getUser(params.userId);
2386
+ * }),
2387
+ * });
2388
+ * ```
2389
+ */
2390
+ declare function createTracedRoute(routeId: string, config?: Omit<TraceLoaderConfig, 'name'>): {
2391
+ /**
2392
+ * Wrap a loader function with tracing
2393
+ */
2394
+ loader<TLoaderFn extends (ctx: any) => any>(loaderFn: TLoaderFn): TLoaderFn;
2395
+ /**
2396
+ * Wrap a beforeLoad function with tracing
2397
+ */
2398
+ beforeLoad<TBeforeLoadFn extends (opts: any) => any>(beforeLoadFn: TBeforeLoadFn): TBeforeLoadFn;
2399
+ };
2400
+ //#endregion
2401
+ export { LoaderFnContext as i, traceBeforeLoad as n, traceLoader as r, createTracedRoute as t };
2402
+ //# sourceMappingURL=loaders-DrVVY25K.d.ts.map