react-router 0.0.0-experimental-bafa092e7 → 0.0.0-experimental-47ed76689

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 (40) hide show
  1. package/CHANGELOG.md +7 -0
  2. package/dist/development/{browser-BM9EKN98.d.mts → browser-DQVA_cmy.d.mts} +2 -1
  3. package/dist/development/{chunk-Q2DCDB5W.mjs → chunk-3HEPNEJL.mjs} +35 -25
  4. package/dist/development/dom-export.d.mts +2 -2
  5. package/dist/development/dom-export.js +1 -1
  6. package/dist/development/dom-export.mjs +2 -2
  7. package/dist/development/index.d.mts +14 -5
  8. package/dist/development/index.d.ts +13 -3
  9. package/dist/development/index.js +40 -28
  10. package/dist/development/index.mjs +6 -2
  11. package/dist/development/lib/types/internal.d.mts +7 -71
  12. package/dist/development/lib/types/internal.d.ts +7 -71
  13. package/dist/development/lib/types/internal.js +1 -1
  14. package/dist/development/lib/types/internal.mjs +1 -1
  15. package/dist/{production/register-B0EYMBux.d.ts → development/register-BEmY26MO.d.ts} +68 -2
  16. package/dist/{production/route-data-B3YkvRuy.d.mts → development/route-data-C8_wxpLo.d.mts} +68 -2
  17. package/dist/development/rsc-export.d.mts +36 -1
  18. package/dist/development/rsc-export.d.ts +36 -1
  19. package/dist/development/rsc-export.js +13 -8
  20. package/dist/development/rsc-export.mjs +13 -8
  21. package/dist/production/{browser-BM9EKN98.d.mts → browser-DQVA_cmy.d.mts} +2 -1
  22. package/dist/production/{chunk-PBF6AAQR.mjs → chunk-JSJTITMT.mjs} +35 -25
  23. package/dist/production/dom-export.d.mts +2 -2
  24. package/dist/production/dom-export.js +1 -1
  25. package/dist/production/dom-export.mjs +2 -2
  26. package/dist/production/index.d.mts +14 -5
  27. package/dist/production/index.d.ts +13 -3
  28. package/dist/production/index.js +40 -28
  29. package/dist/production/index.mjs +6 -2
  30. package/dist/production/lib/types/internal.d.mts +7 -71
  31. package/dist/production/lib/types/internal.d.ts +7 -71
  32. package/dist/production/lib/types/internal.js +1 -1
  33. package/dist/production/lib/types/internal.mjs +1 -1
  34. package/dist/{development/register-B0EYMBux.d.ts → production/register-BEmY26MO.d.ts} +68 -2
  35. package/dist/{development/route-data-B3YkvRuy.d.mts → production/route-data-C8_wxpLo.d.mts} +68 -2
  36. package/dist/production/rsc-export.d.mts +36 -1
  37. package/dist/production/rsc-export.d.ts +36 -1
  38. package/dist/production/rsc-export.js +13 -8
  39. package/dist/production/rsc-export.mjs +13 -8
  40. package/package.json +1 -1
package/CHANGELOG.md CHANGED
@@ -1,5 +1,12 @@
1
1
  # `react-router`
2
2
 
3
+ ## 7.6.2
4
+
5
+ ### Patch Changes
6
+
7
+ - Avoid additional `with-props` chunk in Framework Mode by moving route module component prop logic from the Vite plugin to `react-router` ([#13650](https://github.com/remix-run/react-router/pull/13650))
8
+ - \[INTERNAL] Slight refactor of internal `headers()` function processing for use with RSC ([#13639](https://github.com/remix-run/react-router/pull/13639))
9
+
3
10
  ## 7.6.1
4
11
 
5
12
  ### Patch Changes
@@ -1,4 +1,4 @@
1
- import { aR as RouteManifest, aS as ServerRouteModule, h as MiddlewareEnabled, a9 as unstable_RouterContextProvider, i as AppLoadContext, Y as LoaderFunctionArgs, y as ActionFunctionArgs, b as RouteModules, S as StaticHandlerContext, H as HydrationState, k as DataRouteObject, l as ClientLoaderFunction, T as To, aq as NavigateOptions, s as BlockerFunction, B as Blocker, aT as SerializeFrom, r as RelativeRoutingType, L as Location, _ as ParamParseKey, m as Path, a2 as PathPattern, a0 as PathMatch, a7 as UIMatch, p as Navigation, aa as Action, $ as Params, a as Router$1, c as RouteObject, e as IndexRouteObject, X as LazyRouteFunction, N as NonIndexRouteObject, R as RouterInit, F as FutureConfig$1, I as InitialEntry, D as DataStrategyFunction, P as PatchRoutesOnNavigationFunction, ar as Navigator, at as RouteMatch, W as HTMLFormMethod, U as FormEncType, aB as PageLinkDescriptor, aU as History, n as GetScrollRestorationKeyFunction, o as Fetcher, au as ClientActionFunction, g as LinksFunction, M as MetaFunction, a5 as ShouldRevalidateFunction } from './route-data-B3YkvRuy.mjs';
1
+ import { aR as RouteManifest, aS as ServerRouteModule, h as MiddlewareEnabled, a9 as unstable_RouterContextProvider, i as AppLoadContext, Y as LoaderFunctionArgs, y as ActionFunctionArgs, b as RouteModules, S as StaticHandlerContext, H as HydrationState, k as DataRouteObject, l as ClientLoaderFunction, T as To, aq as NavigateOptions, s as BlockerFunction, B as Blocker, aT as SerializeFrom, r as RelativeRoutingType, L as Location, _ as ParamParseKey, m as Path, a2 as PathPattern, a0 as PathMatch, a7 as UIMatch, p as Navigation, aa as Action, $ as Params, a as Router$1, c as RouteObject, e as IndexRouteObject, X as LazyRouteFunction, N as NonIndexRouteObject, R as RouterInit, F as FutureConfig$1, I as InitialEntry, D as DataStrategyFunction, P as PatchRoutesOnNavigationFunction, ar as Navigator, at as RouteMatch, W as HTMLFormMethod, U as FormEncType, aB as PageLinkDescriptor, aU as History, n as GetScrollRestorationKeyFunction, o as Fetcher, au as ClientActionFunction, g as LinksFunction, M as MetaFunction, a5 as ShouldRevalidateFunction } from './route-data-C8_wxpLo.mjs';
2
2
  import * as React from 'react';
3
3
 
4
4
  type ServerRouteManifest = RouteManifest<Omit<ServerRoute, "children">>;
@@ -2141,6 +2141,7 @@ type RenderedRoute = {
2141
2141
  errorElement?: React.ReactElement;
2142
2142
  handle?: any;
2143
2143
  hasAction: boolean;
2144
+ hasComponent: boolean;
2144
2145
  hasErrorBoundary: boolean;
2145
2146
  hasLoader: boolean;
2146
2147
  hydrateFallbackElement?: React.ReactElement;
@@ -1,5 +1,5 @@
1
1
  /**
2
- * react-router v0.0.0-experimental-bafa092e7
2
+ * react-router v0.0.0-experimental-47ed76689
3
3
  *
4
4
  * Copyright (c) Remix Software Inc.
5
5
  *
@@ -2719,7 +2719,7 @@ function createStaticHandler(routes, opts) {
2719
2719
  return stream ? stream(
2720
2720
  requestContext,
2721
2721
  () => Promise.resolve(ctx)
2722
- ) : respond ? respond(ctx) : void 0;
2722
+ ) : respond ? respond(ctx) : ctx;
2723
2723
  };
2724
2724
  if (!isValidMethod(method) && method !== "HEAD") {
2725
2725
  let error = getInternalRouterError(405, { method });
@@ -2737,7 +2737,7 @@ function createStaticHandler(routes, opts) {
2737
2737
  loaderHeaders: {},
2738
2738
  actionHeaders: {}
2739
2739
  };
2740
- return respondOrStreamStaticContext(staticContext) || staticContext;
2740
+ return respondOrStreamStaticContext(staticContext);
2741
2741
  } else if (!matches) {
2742
2742
  let error = getInternalRouterError(404, { pathname: location2.pathname });
2743
2743
  let { matches: notFoundMatches, route } = getShortCircuitMatches(dataRoutes);
@@ -2754,7 +2754,7 @@ function createStaticHandler(routes, opts) {
2754
2754
  loaderHeaders: {},
2755
2755
  actionHeaders: {}
2756
2756
  };
2757
- return respondOrStreamStaticContext(staticContext) || staticContext;
2757
+ return respondOrStreamStaticContext(staticContext);
2758
2758
  }
2759
2759
  if (stream || respond && matches.some(
2760
2760
  (m) => m.route.unstable_middleware || typeof m.route.lazy === "object" && m.route.lazy.unstable_middleware
@@ -2834,7 +2834,7 @@ function createStaticHandler(routes, opts) {
2834
2834
  error,
2835
2835
  skipLoaderErrorBubbling ? routeId : findNearestBoundary(matches, routeId).route.id
2836
2836
  );
2837
- return respondOrStreamStaticContext(staticContext) || staticContext;
2837
+ return respondOrStreamStaticContext(staticContext);
2838
2838
  } else {
2839
2839
  let boundaryRouteId = skipLoaderErrorBubbling ? routeId : findNearestBoundary(
2840
2840
  matches,
@@ -2855,7 +2855,7 @@ function createStaticHandler(routes, opts) {
2855
2855
  actionHeaders: {},
2856
2856
  loaderHeaders: {}
2857
2857
  };
2858
- return respondOrStreamStaticContext(staticContext) || staticContext;
2858
+ return respondOrStreamStaticContext(staticContext);
2859
2859
  }
2860
2860
  }
2861
2861
  );
@@ -4845,6 +4845,10 @@ var DataRouterContext = React.createContext(null);
4845
4845
  DataRouterContext.displayName = "DataRouter";
4846
4846
  var DataRouterStateContext = React.createContext(null);
4847
4847
  DataRouterStateContext.displayName = "DataRouterState";
4848
+ var RSCRouterContext = React.createContext(false);
4849
+ function useIsRSCRouterContext() {
4850
+ return React.useContext(RSCRouterContext);
4851
+ }
4848
4852
  var ViewTransitionContext = React.createContext({
4849
4853
  isTransitioning: false
4850
4854
  });
@@ -5018,6 +5022,7 @@ function useRoutesImpl(routes, locationArg, dataRouterState, future) {
5018
5022
  // router loaded. We can help them understand how to avoid that.
5019
5023
  `useRoutes() may be used only in the context of a <Router> component.`
5020
5024
  );
5025
+ let isRSCRouterContext = useIsRSCRouterContext();
5021
5026
  let { navigator } = React2.useContext(NavigationContext);
5022
5027
  let { matches: parentMatches } = React2.useContext(RouteContext);
5023
5028
  let routeMatch = parentMatches[parentMatches.length - 1];
@@ -5083,7 +5088,8 @@ Please change the parent <Route path="${parentPath}"> to <Route path="${parentPa
5083
5088
  ),
5084
5089
  parentMatches,
5085
5090
  dataRouterState,
5086
- future
5091
+ future,
5092
+ isRSCRouterContext
5087
5093
  );
5088
5094
  if (locationArg && renderedMatches) {
5089
5095
  return /* @__PURE__ */ React2.createElement(
@@ -5174,7 +5180,7 @@ function RenderedRoute({ routeContext, match, children }) {
5174
5180
  }
5175
5181
  return /* @__PURE__ */ React2.createElement(RouteContext.Provider, { value: routeContext }, children);
5176
5182
  }
5177
- function _renderMatches(matches, parentMatches = [], dataRouterState = null, future = null) {
5183
+ function _renderMatches(matches, parentMatches = [], dataRouterState = null, future = null, isRSCRouterContext = false) {
5178
5184
  if (matches == null) {
5179
5185
  if (!dataRouterState) {
5180
5186
  return null;
@@ -5264,7 +5270,9 @@ function _renderMatches(matches, parentMatches = [], dataRouterState = null, fut
5264
5270
  } else {
5265
5271
  children = outlet;
5266
5272
  }
5267
- children = /* @__PURE__ */ React2.createElement(RedirectBoundary, null, children);
5273
+ if (isRSCRouterContext) {
5274
+ children = /* @__PURE__ */ React2.createElement(RedirectBoundary, null, children);
5275
+ }
5268
5276
  return /* @__PURE__ */ React2.createElement(
5269
5277
  RenderedRoute,
5270
5278
  {
@@ -8796,7 +8804,7 @@ function mergeRefs(...refs) {
8796
8804
  var isBrowser = typeof window !== "undefined" && typeof window.document !== "undefined" && typeof window.document.createElement !== "undefined";
8797
8805
  try {
8798
8806
  if (isBrowser) {
8799
- window.__reactRouterVersion = "0.0.0-experimental-bafa092e7";
8807
+ window.__reactRouterVersion = "0.0.0-experimental-47ed76689";
8800
8808
  }
8801
8809
  } catch (e) {
8802
8810
  }
@@ -11680,6 +11688,7 @@ function getRSCSingleFetchDataStrategy(getRouter, ssr, basename, decode2) {
11680
11688
  return {
11681
11689
  hasLoader: M.route.hasLoader,
11682
11690
  hasClientLoader: M.route.hasClientLoader,
11691
+ hasComponent: M.route.hasComponent,
11683
11692
  hasAction: M.route.hasAction,
11684
11693
  hasClientAction: M.route.hasClientAction,
11685
11694
  hasShouldRevalidate: M.route.hasShouldRevalidate
@@ -11689,12 +11698,13 @@ function getRSCSingleFetchDataStrategy(getRouter, ssr, basename, decode2) {
11689
11698
  getFetchAndDecodeViaRSC(decode2),
11690
11699
  ssr,
11691
11700
  basename,
11692
- // If we don't have an element, we need to hit the server loader flow
11693
- // regardless of whether the client loader calls `serverLoader` or not,
11694
- // otherwise we'll have nothing to render.
11695
- // TODO: Do we need to account for API routes? Do we need a
11696
- // `match.hasComponent` flag?
11697
- (match) => match.route.element != null
11701
+ // If the route has a component but we don't have an element, we need to hit
11702
+ // the server loader flow regardless of whether the client loader calls
11703
+ // `serverLoader` or not, otherwise we'll have nothing to render.
11704
+ (match) => {
11705
+ let M = match;
11706
+ return M.route.hasComponent && !M.route.element;
11707
+ }
11698
11708
  );
11699
11709
  return async (args) => args.unstable_runClientMiddleware(async () => {
11700
11710
  let context = args.context;
@@ -11855,19 +11865,17 @@ function RSCHydratedRouter({
11855
11865
  routeDiscovery: { mode: "lazy", manifestPath: "/__manifest" },
11856
11866
  routeModules: {}
11857
11867
  };
11858
- return /* @__PURE__ */ React14.createElement(FrameworkContext.Provider, { value: frameworkContext }, /* @__PURE__ */ React14.createElement(RouterProvider, { router, flushSync: ReactDOM.flushSync }));
11868
+ return /* @__PURE__ */ React14.createElement(RSCRouterContext.Provider, { value: true }, /* @__PURE__ */ React14.createElement(FrameworkContext.Provider, { value: frameworkContext }, /* @__PURE__ */ React14.createElement(RouterProvider, { router, flushSync: ReactDOM.flushSync })));
11859
11869
  }
11860
11870
  function createRouteFromServerManifest(match, payload) {
11861
11871
  let hasInitialData = payload && match.id in payload.loaderData;
11862
11872
  let initialData = payload?.loaderData[match.id];
11863
11873
  let hasInitialError = payload?.errors && match.id in payload.errors;
11864
11874
  let initialError = payload?.errors?.[match.id];
11865
- let isHydrationRequest = match.clientLoader?.hydrate === true || !match.hasLoader || // If we don't have an element, we need to hit the server loader flow
11866
- // regardless of whether the client loader calls `serverLoader` or not,
11867
- // otherwise we'll have nothing to render.
11868
- // TODO: Do we need to account for API routes? Do we need a
11869
- // `match.hasComponent` flag?
11870
- !match.element;
11875
+ let isHydrationRequest = match.clientLoader?.hydrate === true || !match.hasLoader || // If the route has a component but we don't have an element, we need to hit
11876
+ // the server loader flow regardless of whether the client loader calls
11877
+ // `serverLoader` or not, otherwise we'll have nothing to render.
11878
+ match.hasComponent && !match.element;
11871
11879
  let dataRoute = {
11872
11880
  id: match.id,
11873
11881
  element: match.element,
@@ -12218,7 +12226,7 @@ function RSCStaticRouter({
12218
12226
  routeDiscovery: { mode: "lazy", manifestPath: "/__manifest" },
12219
12227
  routeModules: {}
12220
12228
  };
12221
- return /* @__PURE__ */ React15.createElement(FrameworkContext.Provider, { value: frameworkContext }, /* @__PURE__ */ React15.createElement(
12229
+ return /* @__PURE__ */ React15.createElement(RSCRouterContext.Provider, { value: true }, /* @__PURE__ */ React15.createElement(FrameworkContext.Provider, { value: frameworkContext }, /* @__PURE__ */ React15.createElement(
12222
12230
  StaticRouterProvider,
12223
12231
  {
12224
12232
  context,
@@ -12226,7 +12234,7 @@ function RSCStaticRouter({
12226
12234
  hydrate: false,
12227
12235
  nonce: payload.nonce
12228
12236
  }
12229
- ));
12237
+ )));
12230
12238
  }
12231
12239
  function isReactServerRequest(url) {
12232
12240
  return url.pathname.endsWith(".rsc");
@@ -12379,6 +12387,8 @@ export {
12379
12387
  getTurboStreamSingleFetchDataStrategy,
12380
12388
  decodeViaTurboStream,
12381
12389
  RemixErrorBoundary,
12390
+ RemixRootDefaultErrorBoundary,
12391
+ RemixRootDefaultHydrateFallback,
12382
12392
  createClientRoutesWithHMRRevalidationOptOut,
12383
12393
  createClientRoutes,
12384
12394
  shouldHydrateRouteLoader,
@@ -1,6 +1,6 @@
1
1
  import * as React from 'react';
2
- import { R as RouterProviderProps$1 } from './browser-BM9EKN98.mjs';
3
- import { R as RouterInit } from './route-data-B3YkvRuy.mjs';
2
+ import { R as RouterProviderProps$1 } from './browser-DQVA_cmy.mjs';
3
+ import { R as RouterInit } from './route-data-C8_wxpLo.mjs';
4
4
 
5
5
  type RouterProviderProps = Omit<RouterProviderProps$1, "flushSync">;
6
6
  declare function RouterProvider(props: Omit<RouterProviderProps, "flushSync">): React.JSX.Element;
@@ -1,5 +1,5 @@
1
1
  /**
2
- * react-router v0.0.0-experimental-bafa092e7
2
+ * react-router v0.0.0-experimental-47ed76689
3
3
  *
4
4
  * Copyright (c) Remix Software Inc.
5
5
  *
@@ -1,5 +1,5 @@
1
1
  /**
2
- * react-router v0.0.0-experimental-bafa092e7
2
+ * react-router v0.0.0-experimental-47ed76689
3
3
  *
4
4
  * Copyright (c) Remix Software Inc.
5
5
  *
@@ -26,7 +26,7 @@ import {
26
26
  invariant,
27
27
  mapRouteProperties,
28
28
  useFogOFWarDiscovery
29
- } from "./chunk-Q2DCDB5W.mjs";
29
+ } from "./chunk-3HEPNEJL.mjs";
30
30
 
31
31
  // lib/dom-export/dom-router-provider.tsx
32
32
  import * as React from "react";
@@ -1,7 +1,7 @@
1
- import { a as Router, b as RouteModules, D as DataStrategyFunction, L as Location, S as StaticHandlerContext, c as RouteObject, C as CreateStaticHandlerOptions$1, d as StaticHandler, F as FutureConfig, I as InitialEntry, H as HydrationState, e as IndexRouteObject, f as LoaderFunction, A as ActionFunction, M as MetaFunction, g as LinksFunction, N as NonIndexRouteObject, u as unstable_InitialContext, h as MiddlewareEnabled, i as AppLoadContext, E as Equal, j as RouterState, P as PatchRoutesOnNavigationFunction, k as DataRouteObject, l as ClientLoaderFunction, m as Path } from './route-data-B3YkvRuy.mjs';
2
- export { y as ActionFunctionArgs, B as Blocker, s as BlockerFunction, au as ClientActionFunction, av as ClientActionFunctionArgs, aw as ClientLoaderFunctionArgs, ap as DataRouteMatch, z as DataStrategyFunctionArgs, J as DataStrategyMatch, K as DataStrategyResult, Q as ErrorResponse, o as Fetcher, U as FormEncType, V as FormMethod, aE as Future, G as GetScrollPositionFunction, n as GetScrollRestorationKeyFunction, W as HTMLFormMethod, ax as HeadersArgs, ay as HeadersFunction, aC as HtmlLinkDescriptor, af as IDLE_BLOCKER, ae as IDLE_FETCHER, ad as IDLE_NAVIGATION, X as LazyRouteFunction, aD as LinkDescriptor, Y as LoaderFunctionArgs, az as MetaArgs, aA as MetaDescriptor, aq as NavigateOptions, p as Navigation, q as NavigationStates, aa as NavigationType, ar as Navigator, aB as PageLinkDescriptor, _ as ParamParseKey, $ as Params, as as PatchRoutesOnNavigationFunctionArgs, a0 as PathMatch, a1 as PathParam, a2 as PathPattern, a3 as RedirectFunction, r as RelativeRoutingType, x as RevalidationState, at as RouteMatch, w as RouterFetchOptions, R as RouterInit, v as RouterNavigateOptions, t as RouterSubscriber, a5 as ShouldRevalidateFunction, a6 as ShouldRevalidateFunctionArgs, T as To, a7 as UIMatch, aK as UNSAFE_DataRouterContext, aL as UNSAFE_DataRouterStateContext, O as UNSAFE_DataWithResponseInit, aJ as UNSAFE_ErrorResponseImpl, aM as UNSAFE_FetchersContext, aN as UNSAFE_LocationContext, aO as UNSAFE_NavigationContext, aP as UNSAFE_RouteContext, aQ as UNSAFE_ViewTransitionContext, aG as UNSAFE_createBrowserHistory, aI as UNSAFE_createRouter, aH as UNSAFE_invariant, ab as createPath, ag as data, ah as generatePath, ai as isRouteErrorResponse, aj as matchPath, ak as matchRoutes, ac as parsePath, al as redirect, am as redirectDocument, an as replace, ao as resolvePath, Z as unstable_MiddlewareFunction, a4 as unstable_RouterContext, a9 as unstable_RouterContextProvider, aF as unstable_SerializesTo, a8 as unstable_createContext } from './route-data-B3YkvRuy.mjs';
3
- import { A as AssetsManifest, E as EntryContext, F as FutureConfig$1, a as RouteComponentType, H as HydrateFallbackType, b as ErrorBoundaryType, S as ServerBuild, c as ServerPayload } from './browser-BM9EKN98.mjs';
4
- export { i as Await, d as AwaitProps, ag as BrowserRouter, a0 as BrowserRouterProps, a1 as DOMRouterOpts, a7 as FetcherFormProps, ac as FetcherSubmitFunction, aw as FetcherSubmitOptions, ad as FetcherWithComponents, al as Form, a8 as FormProps, aH as HandleDataRequestFunction, aI as HandleDocumentRequestFunction, aJ as HandleErrorFunction, ah as HashRouter, a2 as HashRouterProps, a3 as HistoryRouterProps, I as IndexRouteProps, L as LayoutRouteProps, ai as Link, a4 as LinkProps, aD as Links, j as MemoryRouter, M as MemoryRouterOpts, e as MemoryRouterProps, aC as Meta, ak as NavLink, a5 as NavLinkProps, a6 as NavLinkRenderProps, k as Navigate, u as NavigateFunction, N as NavigateProps, l as Outlet, O as OutletProps, ax as ParamKeyValuePair, P as PathRouteProps, aF as PrefetchPageLinks, m as Route, f as RouteProps, n as Router, g as RouterProps, o as RouterProvider, R as RouterProviderProps, p as Routes, h as RoutesProps, aE as Scripts, aG as ScriptsProps, am as ScrollRestoration, a9 as ScrollRestorationProps, aK as ServerEntryModule, aa as SetURLSearchParams, ab as SubmitFunction, ay as SubmitOptions, aA as SubmitTarget, aV as UNSAFE_FrameworkContext, aW as UNSAFE_createClientRoutes, aX as UNSAFE_createClientRoutesWithHMRRevalidationOptOut, aQ as UNSAFE_hydrationRouteProperties, aR as UNSAFE_mapRouteProperties, aY as UNSAFE_shouldHydrateRouteLoader, aZ as UNSAFE_useScrollRestoration, aS as UNSAFE_withComponentProps, aU as UNSAFE_withErrorBoundaryProps, aT as UNSAFE_withHydrateFallbackProps, az as URLSearchParamsInit, ae as createBrowserRouter, af as createHashRouter, q as createMemoryRouter, r as createRoutesFromChildren, s as createRoutesFromElements, aB as createSearchParams, t as renderMatches, aL as unstable_DecodeServerResponseFunction, aM as unstable_EncodeActionFunction, aj as unstable_HistoryRouter, aO as unstable_RSCHydratedRouter, aN as unstable_createCallServer, aP as unstable_getServerStream, au as unstable_usePrompt, w as useActionData, x as useAsyncError, y as useAsyncValue, at as useBeforeUnload, v as useBlocker, ar as useFetcher, as as useFetchers, aq as useFormAction, z as useHref, B as useInRouterContext, an as useLinkClickHandler, C as useLoaderData, D as useLocation, G as useMatch, J as useMatches, K as useNavigate, Q as useNavigation, T as useNavigationType, U as useOutlet, V as useOutletContext, W as useParams, X as useResolvedPath, Y as useRevalidator, Z as useRouteError, _ as useRouteLoaderData, $ as useRoutes, ao as useSearchParams, ap as useSubmit, av as useViewTransitionState } from './browser-BM9EKN98.mjs';
1
+ import { a as Router, b as RouteModules, D as DataStrategyFunction, L as Location, S as StaticHandlerContext, c as RouteObject, C as CreateStaticHandlerOptions$1, d as StaticHandler, F as FutureConfig, I as InitialEntry, H as HydrationState, e as IndexRouteObject, f as LoaderFunction, A as ActionFunction, M as MetaFunction, g as LinksFunction, N as NonIndexRouteObject, u as unstable_InitialContext, h as MiddlewareEnabled, i as AppLoadContext, E as Equal, j as RouterState, P as PatchRoutesOnNavigationFunction, k as DataRouteObject, l as ClientLoaderFunction, m as Path } from './route-data-C8_wxpLo.mjs';
2
+ export { y as ActionFunctionArgs, B as Blocker, s as BlockerFunction, au as ClientActionFunction, av as ClientActionFunctionArgs, aw as ClientLoaderFunctionArgs, ap as DataRouteMatch, z as DataStrategyFunctionArgs, J as DataStrategyMatch, K as DataStrategyResult, Q as ErrorResponse, o as Fetcher, U as FormEncType, V as FormMethod, aE as Future, G as GetScrollPositionFunction, n as GetScrollRestorationKeyFunction, W as HTMLFormMethod, ax as HeadersArgs, ay as HeadersFunction, aC as HtmlLinkDescriptor, af as IDLE_BLOCKER, ae as IDLE_FETCHER, ad as IDLE_NAVIGATION, X as LazyRouteFunction, aD as LinkDescriptor, Y as LoaderFunctionArgs, az as MetaArgs, aA as MetaDescriptor, aq as NavigateOptions, p as Navigation, q as NavigationStates, aa as NavigationType, ar as Navigator, aB as PageLinkDescriptor, _ as ParamParseKey, $ as Params, as as PatchRoutesOnNavigationFunctionArgs, a0 as PathMatch, a1 as PathParam, a2 as PathPattern, a3 as RedirectFunction, r as RelativeRoutingType, x as RevalidationState, at as RouteMatch, w as RouterFetchOptions, R as RouterInit, v as RouterNavigateOptions, t as RouterSubscriber, a5 as ShouldRevalidateFunction, a6 as ShouldRevalidateFunctionArgs, T as To, a7 as UIMatch, aK as UNSAFE_DataRouterContext, aL as UNSAFE_DataRouterStateContext, O as UNSAFE_DataWithResponseInit, aJ as UNSAFE_ErrorResponseImpl, aM as UNSAFE_FetchersContext, aN as UNSAFE_LocationContext, aO as UNSAFE_NavigationContext, aP as UNSAFE_RouteContext, aQ as UNSAFE_ViewTransitionContext, aG as UNSAFE_createBrowserHistory, aI as UNSAFE_createRouter, aH as UNSAFE_invariant, ab as createPath, ag as data, ah as generatePath, ai as isRouteErrorResponse, aj as matchPath, ak as matchRoutes, ac as parsePath, al as redirect, am as redirectDocument, an as replace, ao as resolvePath, Z as unstable_MiddlewareFunction, a4 as unstable_RouterContext, a9 as unstable_RouterContextProvider, aF as unstable_SerializesTo, a8 as unstable_createContext } from './route-data-C8_wxpLo.mjs';
3
+ import { A as AssetsManifest, E as EntryContext, F as FutureConfig$1, a as RouteComponentType, H as HydrateFallbackType, b as ErrorBoundaryType, S as ServerBuild, c as ServerPayload } from './browser-DQVA_cmy.mjs';
4
+ export { i as Await, d as AwaitProps, ag as BrowserRouter, a0 as BrowserRouterProps, a1 as DOMRouterOpts, a7 as FetcherFormProps, ac as FetcherSubmitFunction, aw as FetcherSubmitOptions, ad as FetcherWithComponents, al as Form, a8 as FormProps, aH as HandleDataRequestFunction, aI as HandleDocumentRequestFunction, aJ as HandleErrorFunction, ah as HashRouter, a2 as HashRouterProps, a3 as HistoryRouterProps, I as IndexRouteProps, L as LayoutRouteProps, ai as Link, a4 as LinkProps, aD as Links, j as MemoryRouter, M as MemoryRouterOpts, e as MemoryRouterProps, aC as Meta, ak as NavLink, a5 as NavLinkProps, a6 as NavLinkRenderProps, k as Navigate, u as NavigateFunction, N as NavigateProps, l as Outlet, O as OutletProps, ax as ParamKeyValuePair, P as PathRouteProps, aF as PrefetchPageLinks, m as Route, f as RouteProps, n as Router, g as RouterProps, o as RouterProvider, R as RouterProviderProps, p as Routes, h as RoutesProps, aE as Scripts, aG as ScriptsProps, am as ScrollRestoration, a9 as ScrollRestorationProps, aK as ServerEntryModule, aa as SetURLSearchParams, ab as SubmitFunction, ay as SubmitOptions, aA as SubmitTarget, aV as UNSAFE_FrameworkContext, aW as UNSAFE_createClientRoutes, aX as UNSAFE_createClientRoutesWithHMRRevalidationOptOut, aQ as UNSAFE_hydrationRouteProperties, aR as UNSAFE_mapRouteProperties, aY as UNSAFE_shouldHydrateRouteLoader, aZ as UNSAFE_useScrollRestoration, aS as UNSAFE_withComponentProps, aU as UNSAFE_withErrorBoundaryProps, aT as UNSAFE_withHydrateFallbackProps, az as URLSearchParamsInit, ae as createBrowserRouter, af as createHashRouter, q as createMemoryRouter, r as createRoutesFromChildren, s as createRoutesFromElements, aB as createSearchParams, t as renderMatches, aL as unstable_DecodeServerResponseFunction, aM as unstable_EncodeActionFunction, aj as unstable_HistoryRouter, aO as unstable_RSCHydratedRouter, aN as unstable_createCallServer, aP as unstable_getServerStream, au as unstable_usePrompt, w as useActionData, x as useAsyncError, y as useAsyncValue, at as useBeforeUnload, v as useBlocker, ar as useFetcher, as as useFetchers, aq as useFormAction, z as useHref, B as useInRouterContext, an as useLinkClickHandler, C as useLoaderData, D as useLocation, G as useMatch, J as useMatches, K as useNavigate, Q as useNavigation, T as useNavigationType, U as useOutlet, V as useOutletContext, W as useParams, X as useResolvedPath, Y as useRevalidator, Z as useRouteError, _ as useRouteLoaderData, $ as useRoutes, ao as useSearchParams, ap as useSubmit, av as useViewTransitionState } from './browser-DQVA_cmy.mjs';
5
5
  import * as React from 'react';
6
6
  import { ReactElement } from 'react';
7
7
  import { ParseOptions, SerializeOptions } from 'cookie';
@@ -416,6 +416,15 @@ declare class RemixErrorBoundary extends React.Component<RemixErrorBoundaryProps
416
416
  };
417
417
  render(): string | number | boolean | Iterable<React.ReactNode> | React.JSX.Element | null | undefined;
418
418
  }
419
+ /**
420
+ * When app's don't provide a root level ErrorBoundary, we default to this.
421
+ */
422
+ declare function RemixRootDefaultErrorBoundary({ error, isOutsideRemixApp, }: {
423
+ error: unknown;
424
+ isOutsideRemixApp?: boolean;
425
+ }): React.JSX.Element;
426
+
427
+ declare function RemixRootDefaultHydrateFallback(): React.JSX.Element;
419
428
 
420
429
  declare function getPatchRoutesOnNavigationFunction(manifest: AssetsManifest, routeModules: RouteModules, ssr: boolean, routeDiscovery: ServerBuild["routeDiscovery"], isSpaMode: boolean, basename: string | undefined): PatchRoutesOnNavigationFunction | undefined;
421
430
  declare function useFogOFWarDiscovery(router: Router, manifest: AssetsManifest, routeModules: RouteModules, ssr: boolean, routeDiscovery: ServerBuild["routeDiscovery"], isSpaMode: boolean): void;
@@ -430,4 +439,4 @@ declare function getHydrationData(state: {
430
439
  hasHydrateFallback: boolean;
431
440
  }, location: Path, basename: string | undefined, isSpaMode: boolean): HydrationState;
432
441
 
433
- export { ActionFunction, AppLoadContext, ClientLoaderFunction, type Cookie, type CookieOptions, type CookieSignatureOptions, type CreateRequestHandlerFunction, DataRouteObject, Router as DataRouter, DataStrategyFunction, EntryContext, type FlashSessionData, HydrationState, IndexRouteObject, InitialEntry, type IsCookieFunction, type IsSessionFunction, LinksFunction, LoaderFunction, Location, MetaFunction, NonIndexRouteObject, PatchRoutesOnNavigationFunction, Path, type RequestHandler, RouteObject, RouterState, type RoutesTestStubProps, ServerBuild, ServerRouter, type ServerRouterProps, type Session, type SessionData, type SessionIdStorageStrategy, type SessionStorage, StaticHandler, StaticHandlerContext, StaticRouter, type StaticRouterProps, StaticRouterProvider, type StaticRouterProviderProps, AssetsManifest as UNSAFE_AssetsManifest, MiddlewareEnabled as UNSAFE_MiddlewareEnabled, RemixErrorBoundary as UNSAFE_RemixErrorBoundary, RouteModules as UNSAFE_RouteModules, ServerMode as UNSAFE_ServerMode, SingleFetchRedirectSymbol as UNSAFE_SingleFetchRedirectSymbol, decodeViaTurboStream as UNSAFE_decodeViaTurboStream, deserializeErrors as UNSAFE_deserializeErrors, getHydrationData as UNSAFE_getHydrationData, getPatchRoutesOnNavigationFunction as UNSAFE_getPatchRoutesOnNavigationFunction, getTurboStreamSingleFetchDataStrategy as UNSAFE_getTurboStreamSingleFetchDataStrategy, useFogOFWarDiscovery as UNSAFE_useFogOFWarDiscovery, createCookie, createCookieSessionStorage, createMemorySessionStorage, createRequestHandler, createRoutesStub, createSession, createSessionStorage, createStaticHandler, createStaticRouter, href, isCookie, isSession, unstable_InitialContext, RSCStaticRouter as unstable_RSCStaticRouter, routeRSCServerRequest as unstable_routeRSCServerRequest, setDevServerHooks as unstable_setDevServerHooks };
442
+ export { ActionFunction, AppLoadContext, ClientLoaderFunction, type Cookie, type CookieOptions, type CookieSignatureOptions, type CreateRequestHandlerFunction, DataRouteObject, Router as DataRouter, DataStrategyFunction, EntryContext, type FlashSessionData, HydrationState, IndexRouteObject, InitialEntry, type IsCookieFunction, type IsSessionFunction, LinksFunction, LoaderFunction, Location, MetaFunction, NonIndexRouteObject, PatchRoutesOnNavigationFunction, Path, type RequestHandler, RouteObject, RouterState, type RoutesTestStubProps, ServerBuild, ServerRouter, type ServerRouterProps, type Session, type SessionData, type SessionIdStorageStrategy, type SessionStorage, StaticHandler, StaticHandlerContext, StaticRouter, type StaticRouterProps, StaticRouterProvider, type StaticRouterProviderProps, AssetsManifest as UNSAFE_AssetsManifest, MiddlewareEnabled as UNSAFE_MiddlewareEnabled, RemixErrorBoundary as UNSAFE_RemixErrorBoundary, RemixRootDefaultErrorBoundary as UNSAFE_RootDefaultErrorBoundary, RemixRootDefaultHydrateFallback as UNSAFE_RootDefaultHydrateFallback, RouteModules as UNSAFE_RouteModules, ServerMode as UNSAFE_ServerMode, SingleFetchRedirectSymbol as UNSAFE_SingleFetchRedirectSymbol, decodeViaTurboStream as UNSAFE_decodeViaTurboStream, deserializeErrors as UNSAFE_deserializeErrors, getHydrationData as UNSAFE_getHydrationData, getPatchRoutesOnNavigationFunction as UNSAFE_getPatchRoutesOnNavigationFunction, getTurboStreamSingleFetchDataStrategy as UNSAFE_getTurboStreamSingleFetchDataStrategy, useFogOFWarDiscovery as UNSAFE_useFogOFWarDiscovery, createCookie, createCookieSessionStorage, createMemorySessionStorage, createRequestHandler, createRoutesStub, createSession, createSessionStorage, createStaticHandler, createStaticRouter, href, isCookie, isSession, unstable_InitialContext, RSCStaticRouter as unstable_RSCStaticRouter, routeRSCServerRequest as unstable_routeRSCServerRequest, setDevServerHooks as unstable_setDevServerHooks };
@@ -1,5 +1,5 @@
1
- import { R as RouteManifest, S as ServerRouteModule, M as MiddlewareEnabled, u as unstable_RouterContextProvider, A as AppLoadContext, L as LoaderFunctionArgs, a as ActionFunctionArgs, b as RouteModules, c as StaticHandlerContext, H as HydrationState, D as DataRouteObject, C as ClientLoaderFunction, d as Router$1, e as DataStrategyFunction, T as To, N as NavigateOptions, B as BlockerFunction, f as Blocker, g as SerializeFrom, h as RelativeRoutingType, i as Location, P as ParamParseKey, j as Path, k as PathPattern, l as PathMatch, U as UIMatch, m as Navigation, n as Action, o as Params, p as RouteObject, I as IndexRouteObject, q as LazyRouteFunction, r as NonIndexRouteObject, s as RouterInit, F as FutureConfig$1, t as InitialEntry, v as PatchRoutesOnNavigationFunction, w as Navigator, x as RouteMatch, y as HTMLFormMethod, z as FormEncType, E as PageLinkDescriptor, G as History, J as GetScrollRestorationKeyFunction, K as Fetcher, O as CreateStaticHandlerOptions$1, Q as StaticHandler, V as LoaderFunction, W as ActionFunction, X as MetaFunction, Y as LinksFunction, Z as unstable_InitialContext, _ as Pages, $ as Equal, a0 as ClientActionFunction, a1 as ShouldRevalidateFunction, a2 as RouterState } from './register-B0EYMBux.js';
2
- export { aB as ClientActionFunctionArgs, aC as ClientLoaderFunctionArgs, az as DataRouteMatch, a9 as DataStrategyFunctionArgs, aa as DataStrategyMatch, ab as DataStrategyResult, ad as ErrorResponse, ae as FormMethod, aJ as Future, a3 as GetScrollPositionFunction, aD as HeadersArgs, aE as HeadersFunction, aH as HtmlLinkDescriptor, ap as IDLE_BLOCKER, ao as IDLE_FETCHER, an as IDLE_NAVIGATION, aI as LinkDescriptor, aF as MetaArgs, aG as MetaDescriptor, a4 as NavigationStates, aA as PatchRoutesOnNavigationFunctionArgs, ag as PathParam, ah as RedirectFunction, aL as Register, a8 as RevalidationState, a7 as RouterFetchOptions, a6 as RouterNavigateOptions, a5 as RouterSubscriber, aj as ShouldRevalidateFunctionArgs, aQ as UNSAFE_DataRouterContext, aR as UNSAFE_DataRouterStateContext, ac as UNSAFE_DataWithResponseInit, aP as UNSAFE_ErrorResponseImpl, aS as UNSAFE_FetchersContext, aT as UNSAFE_LocationContext, aU as UNSAFE_NavigationContext, aV as UNSAFE_RouteContext, aW as UNSAFE_ViewTransitionContext, aM as UNSAFE_createBrowserHistory, aO as UNSAFE_createRouter, aN as UNSAFE_invariant, al as createPath, aq as data, ar as generatePath, as as isRouteErrorResponse, at as matchPath, au as matchRoutes, am as parsePath, av as redirect, aw as redirectDocument, ax as replace, ay as resolvePath, af as unstable_MiddlewareFunction, ai as unstable_RouterContext, aK as unstable_SerializesTo, ak as unstable_createContext } from './register-B0EYMBux.js';
1
+ import { R as RouteManifest, S as ServerRouteModule, M as MiddlewareEnabled, u as unstable_RouterContextProvider, A as AppLoadContext, L as LoaderFunctionArgs, a as ActionFunctionArgs, b as RouteModules, c as StaticHandlerContext, H as HydrationState, D as DataRouteObject, C as ClientLoaderFunction, d as Router$1, e as DataStrategyFunction, T as To, N as NavigateOptions, B as BlockerFunction, f as Blocker, g as SerializeFrom, h as RelativeRoutingType, i as Location, P as ParamParseKey, j as Path, k as PathPattern, l as PathMatch, U as UIMatch, m as Navigation, n as Action, o as Params, p as RouteObject, I as IndexRouteObject, q as LazyRouteFunction, r as NonIndexRouteObject, s as RouterInit, F as FutureConfig$1, t as InitialEntry, v as PatchRoutesOnNavigationFunction, w as Navigator, x as RouteMatch, y as HTMLFormMethod, z as FormEncType, E as PageLinkDescriptor, G as History, J as GetScrollRestorationKeyFunction, K as Fetcher, O as CreateStaticHandlerOptions$1, Q as StaticHandler, V as LoaderFunction, W as ActionFunction, X as MetaFunction, Y as LinksFunction, Z as unstable_InitialContext, _ as Pages, $ as Equal, a0 as ClientActionFunction, a1 as ShouldRevalidateFunction, a2 as RouterState } from './register-BEmY26MO.js';
2
+ export { aB as ClientActionFunctionArgs, aC as ClientLoaderFunctionArgs, az as DataRouteMatch, a9 as DataStrategyFunctionArgs, aa as DataStrategyMatch, ab as DataStrategyResult, ad as ErrorResponse, ae as FormMethod, aJ as Future, a3 as GetScrollPositionFunction, aD as HeadersArgs, aE as HeadersFunction, aH as HtmlLinkDescriptor, ap as IDLE_BLOCKER, ao as IDLE_FETCHER, an as IDLE_NAVIGATION, aI as LinkDescriptor, aF as MetaArgs, aG as MetaDescriptor, a4 as NavigationStates, aA as PatchRoutesOnNavigationFunctionArgs, ag as PathParam, ah as RedirectFunction, aL as Register, a8 as RevalidationState, a7 as RouterFetchOptions, a6 as RouterNavigateOptions, a5 as RouterSubscriber, aj as ShouldRevalidateFunctionArgs, aQ as UNSAFE_DataRouterContext, aR as UNSAFE_DataRouterStateContext, ac as UNSAFE_DataWithResponseInit, aP as UNSAFE_ErrorResponseImpl, aS as UNSAFE_FetchersContext, aT as UNSAFE_LocationContext, aU as UNSAFE_NavigationContext, aV as UNSAFE_RouteContext, aW as UNSAFE_ViewTransitionContext, aM as UNSAFE_createBrowserHistory, aO as UNSAFE_createRouter, aN as UNSAFE_invariant, al as createPath, aq as data, ar as generatePath, as as isRouteErrorResponse, at as matchPath, au as matchRoutes, am as parsePath, av as redirect, aw as redirectDocument, ax as replace, ay as resolvePath, af as unstable_MiddlewareFunction, ai as unstable_RouterContext, aK as unstable_SerializesTo, ak as unstable_createContext } from './register-BEmY26MO.js';
3
3
  import * as React from 'react';
4
4
  import { ReactElement } from 'react';
5
5
  import { ParseOptions, SerializeOptions } from 'cookie';
@@ -2519,6 +2519,7 @@ type RenderedRoute = {
2519
2519
  errorElement?: React.ReactElement;
2520
2520
  handle?: any;
2521
2521
  hasAction: boolean;
2522
+ hasComponent: boolean;
2522
2523
  hasErrorBoundary: boolean;
2523
2524
  hasLoader: boolean;
2524
2525
  hydrateFallbackElement?: React.ReactElement;
@@ -2623,6 +2624,15 @@ declare class RemixErrorBoundary extends React.Component<RemixErrorBoundaryProps
2623
2624
  };
2624
2625
  render(): string | number | boolean | Iterable<React.ReactNode> | React.JSX.Element | null | undefined;
2625
2626
  }
2627
+ /**
2628
+ * When app's don't provide a root level ErrorBoundary, we default to this.
2629
+ */
2630
+ declare function RemixRootDefaultErrorBoundary({ error, isOutsideRemixApp, }: {
2631
+ error: unknown;
2632
+ isOutsideRemixApp?: boolean;
2633
+ }): React.JSX.Element;
2634
+
2635
+ declare function RemixRootDefaultHydrateFallback(): React.JSX.Element;
2626
2636
 
2627
2637
  declare function getPatchRoutesOnNavigationFunction(manifest: AssetsManifest, routeModules: RouteModules, ssr: boolean, routeDiscovery: ServerBuild["routeDiscovery"], isSpaMode: boolean, basename: string | undefined): PatchRoutesOnNavigationFunction | undefined;
2628
2638
  declare function useFogOFWarDiscovery(router: Router$1, manifest: AssetsManifest, routeModules: RouteModules, ssr: boolean, routeDiscovery: ServerBuild["routeDiscovery"], isSpaMode: boolean): void;
@@ -2637,4 +2647,4 @@ declare function getHydrationData(state: {
2637
2647
  hasHydrateFallback: boolean;
2638
2648
  }, location: Path, basename: string | undefined, isSpaMode: boolean): HydrationState;
2639
2649
 
2640
- export { ActionFunction, ActionFunctionArgs, AppLoadContext, Await, type AwaitProps, Blocker, BlockerFunction, BrowserRouter, type BrowserRouterProps, ClientActionFunction, ClientLoaderFunction, type Cookie, type CookieOptions, type CookieSignatureOptions, type CreateRequestHandlerFunction, type DOMRouterOpts, DataRouteObject, Router$1 as DataRouter, DataStrategyFunction, type EntryContext, Fetcher, type FetcherFormProps, type FetcherSubmitFunction, type FetcherSubmitOptions, type FetcherWithComponents, type FlashSessionData, Form, FormEncType, type FormProps, GetScrollRestorationKeyFunction, HTMLFormMethod, type HandleDataRequestFunction, type HandleDocumentRequestFunction, type HandleErrorFunction, HashRouter, type HashRouterProps, type HistoryRouterProps, HydrationState, IndexRouteObject, type IndexRouteProps, InitialEntry, type IsCookieFunction, type IsSessionFunction, type LayoutRouteProps, LazyRouteFunction, Link, type LinkProps, Links, LinksFunction, LoaderFunction, LoaderFunctionArgs, Location, MemoryRouter, type MemoryRouterOpts, type MemoryRouterProps, Meta, MetaFunction, NavLink, type NavLinkProps, type NavLinkRenderProps, Navigate, type NavigateFunction, NavigateOptions, type NavigateProps, Navigation, Action as NavigationType, Navigator, NonIndexRouteObject, Outlet, type OutletProps, PageLinkDescriptor, type ParamKeyValuePair, ParamParseKey, Params, PatchRoutesOnNavigationFunction, Path, PathMatch, PathPattern, type PathRouteProps, PrefetchPageLinks, RelativeRoutingType, type RequestHandler, Route, RouteMatch, RouteObject, type RouteProps, Router, RouterInit, type RouterProps, RouterProvider, type RouterProviderProps, RouterState, Routes, type RoutesProps, type RoutesTestStubProps, Scripts, type ScriptsProps, ScrollRestoration, type ScrollRestorationProps, type ServerBuild, type ServerEntryModule, ServerRouter, type ServerRouterProps, type Session, type SessionData, type SessionIdStorageStrategy, type SessionStorage, type SetURLSearchParams, ShouldRevalidateFunction, StaticHandler, StaticHandlerContext, StaticRouter, type StaticRouterProps, StaticRouterProvider, type StaticRouterProviderProps, type SubmitFunction, type SubmitOptions, type SubmitTarget, To, UIMatch, type AssetsManifest as UNSAFE_AssetsManifest, FrameworkContext as UNSAFE_FrameworkContext, MiddlewareEnabled as UNSAFE_MiddlewareEnabled, RemixErrorBoundary as UNSAFE_RemixErrorBoundary, RouteModules as UNSAFE_RouteModules, ServerMode as UNSAFE_ServerMode, SingleFetchRedirectSymbol as UNSAFE_SingleFetchRedirectSymbol, createClientRoutes as UNSAFE_createClientRoutes, createClientRoutesWithHMRRevalidationOptOut as UNSAFE_createClientRoutesWithHMRRevalidationOptOut, decodeViaTurboStream as UNSAFE_decodeViaTurboStream, deserializeErrors as UNSAFE_deserializeErrors, getHydrationData as UNSAFE_getHydrationData, getPatchRoutesOnNavigationFunction as UNSAFE_getPatchRoutesOnNavigationFunction, getTurboStreamSingleFetchDataStrategy as UNSAFE_getTurboStreamSingleFetchDataStrategy, hydrationRouteProperties as UNSAFE_hydrationRouteProperties, mapRouteProperties as UNSAFE_mapRouteProperties, shouldHydrateRouteLoader as UNSAFE_shouldHydrateRouteLoader, useFogOFWarDiscovery as UNSAFE_useFogOFWarDiscovery, useScrollRestoration as UNSAFE_useScrollRestoration, withComponentProps as UNSAFE_withComponentProps, withErrorBoundaryProps as UNSAFE_withErrorBoundaryProps, withHydrateFallbackProps as UNSAFE_withHydrateFallbackProps, type URLSearchParamsInit, createBrowserRouter, createCookie, createCookieSessionStorage, createHashRouter, createMemoryRouter, createMemorySessionStorage, createRequestHandler, createRoutesFromChildren, createRoutesFromElements, createRoutesStub, createSearchParams, createSession, createSessionStorage, createStaticHandler, createStaticRouter, href, isCookie, isSession, renderMatches, type DecodeServerResponseFunction as unstable_DecodeServerResponseFunction, type EncodeActionFunction as unstable_EncodeActionFunction, HistoryRouter as unstable_HistoryRouter, unstable_InitialContext, RSCHydratedRouter as unstable_RSCHydratedRouter, RSCStaticRouter as unstable_RSCStaticRouter, unstable_RouterContextProvider, createCallServer as unstable_createCallServer, getServerStream as unstable_getServerStream, routeRSCServerRequest as unstable_routeRSCServerRequest, setDevServerHooks as unstable_setDevServerHooks, usePrompt as unstable_usePrompt, useActionData, useAsyncError, useAsyncValue, useBeforeUnload, useBlocker, useFetcher, useFetchers, useFormAction, useHref, useInRouterContext, useLinkClickHandler, useLoaderData, useLocation, useMatch, useMatches, useNavigate, useNavigation, useNavigationType, useOutlet, useOutletContext, useParams, useResolvedPath, useRevalidator, useRouteError, useRouteLoaderData, useRoutes, useSearchParams, useSubmit, useViewTransitionState };
2650
+ export { ActionFunction, ActionFunctionArgs, AppLoadContext, Await, type AwaitProps, Blocker, BlockerFunction, BrowserRouter, type BrowserRouterProps, ClientActionFunction, ClientLoaderFunction, type Cookie, type CookieOptions, type CookieSignatureOptions, type CreateRequestHandlerFunction, type DOMRouterOpts, DataRouteObject, Router$1 as DataRouter, DataStrategyFunction, type EntryContext, Fetcher, type FetcherFormProps, type FetcherSubmitFunction, type FetcherSubmitOptions, type FetcherWithComponents, type FlashSessionData, Form, FormEncType, type FormProps, GetScrollRestorationKeyFunction, HTMLFormMethod, type HandleDataRequestFunction, type HandleDocumentRequestFunction, type HandleErrorFunction, HashRouter, type HashRouterProps, type HistoryRouterProps, HydrationState, IndexRouteObject, type IndexRouteProps, InitialEntry, type IsCookieFunction, type IsSessionFunction, type LayoutRouteProps, LazyRouteFunction, Link, type LinkProps, Links, LinksFunction, LoaderFunction, LoaderFunctionArgs, Location, MemoryRouter, type MemoryRouterOpts, type MemoryRouterProps, Meta, MetaFunction, NavLink, type NavLinkProps, type NavLinkRenderProps, Navigate, type NavigateFunction, NavigateOptions, type NavigateProps, Navigation, Action as NavigationType, Navigator, NonIndexRouteObject, Outlet, type OutletProps, PageLinkDescriptor, type ParamKeyValuePair, ParamParseKey, Params, PatchRoutesOnNavigationFunction, Path, PathMatch, PathPattern, type PathRouteProps, PrefetchPageLinks, RelativeRoutingType, type RequestHandler, Route, RouteMatch, RouteObject, type RouteProps, Router, RouterInit, type RouterProps, RouterProvider, type RouterProviderProps, RouterState, Routes, type RoutesProps, type RoutesTestStubProps, Scripts, type ScriptsProps, ScrollRestoration, type ScrollRestorationProps, type ServerBuild, type ServerEntryModule, ServerRouter, type ServerRouterProps, type Session, type SessionData, type SessionIdStorageStrategy, type SessionStorage, type SetURLSearchParams, ShouldRevalidateFunction, StaticHandler, StaticHandlerContext, StaticRouter, type StaticRouterProps, StaticRouterProvider, type StaticRouterProviderProps, type SubmitFunction, type SubmitOptions, type SubmitTarget, To, UIMatch, type AssetsManifest as UNSAFE_AssetsManifest, FrameworkContext as UNSAFE_FrameworkContext, MiddlewareEnabled as UNSAFE_MiddlewareEnabled, RemixErrorBoundary as UNSAFE_RemixErrorBoundary, RemixRootDefaultErrorBoundary as UNSAFE_RootDefaultErrorBoundary, RemixRootDefaultHydrateFallback as UNSAFE_RootDefaultHydrateFallback, RouteModules as UNSAFE_RouteModules, ServerMode as UNSAFE_ServerMode, SingleFetchRedirectSymbol as UNSAFE_SingleFetchRedirectSymbol, createClientRoutes as UNSAFE_createClientRoutes, createClientRoutesWithHMRRevalidationOptOut as UNSAFE_createClientRoutesWithHMRRevalidationOptOut, decodeViaTurboStream as UNSAFE_decodeViaTurboStream, deserializeErrors as UNSAFE_deserializeErrors, getHydrationData as UNSAFE_getHydrationData, getPatchRoutesOnNavigationFunction as UNSAFE_getPatchRoutesOnNavigationFunction, getTurboStreamSingleFetchDataStrategy as UNSAFE_getTurboStreamSingleFetchDataStrategy, hydrationRouteProperties as UNSAFE_hydrationRouteProperties, mapRouteProperties as UNSAFE_mapRouteProperties, shouldHydrateRouteLoader as UNSAFE_shouldHydrateRouteLoader, useFogOFWarDiscovery as UNSAFE_useFogOFWarDiscovery, useScrollRestoration as UNSAFE_useScrollRestoration, withComponentProps as UNSAFE_withComponentProps, withErrorBoundaryProps as UNSAFE_withErrorBoundaryProps, withHydrateFallbackProps as UNSAFE_withHydrateFallbackProps, type URLSearchParamsInit, createBrowserRouter, createCookie, createCookieSessionStorage, createHashRouter, createMemoryRouter, createMemorySessionStorage, createRequestHandler, createRoutesFromChildren, createRoutesFromElements, createRoutesStub, createSearchParams, createSession, createSessionStorage, createStaticHandler, createStaticRouter, href, isCookie, isSession, renderMatches, type DecodeServerResponseFunction as unstable_DecodeServerResponseFunction, type EncodeActionFunction as unstable_EncodeActionFunction, HistoryRouter as unstable_HistoryRouter, unstable_InitialContext, RSCHydratedRouter as unstable_RSCHydratedRouter, RSCStaticRouter as unstable_RSCStaticRouter, unstable_RouterContextProvider, createCallServer as unstable_createCallServer, getServerStream as unstable_getServerStream, routeRSCServerRequest as unstable_routeRSCServerRequest, setDevServerHooks as unstable_setDevServerHooks, usePrompt as unstable_usePrompt, useActionData, useAsyncError, useAsyncValue, useBeforeUnload, useBlocker, useFetcher, useFetchers, useFormAction, useHref, useInRouterContext, useLinkClickHandler, useLoaderData, useLocation, useMatch, useMatches, useNavigate, useNavigation, useNavigationType, useOutlet, useOutletContext, useParams, useResolvedPath, useRevalidator, useRouteError, useRouteLoaderData, useRoutes, useSearchParams, useSubmit, useViewTransitionState };
@@ -1,5 +1,5 @@
1
1
  /**
2
- * react-router v0.0.0-experimental-bafa092e7
2
+ * react-router v0.0.0-experimental-47ed76689
3
3
  *
4
4
  * Copyright (c) Remix Software Inc.
5
5
  *
@@ -45,8 +45,8 @@ var __privateGet = (obj, member, getter) => (__accessCheck(obj, member, "read fr
45
45
  var __privateAdd = (obj, member, value) => member.has(obj) ? __typeError("Cannot add the same private member more than once") : member instanceof WeakSet ? member.add(obj) : member.set(obj, value);
46
46
 
47
47
  // index.ts
48
- var react_router_exports = {};
49
- __export(react_router_exports, {
48
+ var index_exports = {};
49
+ __export(index_exports, {
50
50
  Await: () => Await,
51
51
  BrowserRouter: () => BrowserRouter,
52
52
  Form: () => Form,
@@ -80,6 +80,8 @@ __export(react_router_exports, {
80
80
  UNSAFE_LocationContext: () => LocationContext,
81
81
  UNSAFE_NavigationContext: () => NavigationContext,
82
82
  UNSAFE_RemixErrorBoundary: () => RemixErrorBoundary,
83
+ UNSAFE_RootDefaultErrorBoundary: () => RemixRootDefaultErrorBoundary,
84
+ UNSAFE_RootDefaultHydrateFallback: () => RemixRootDefaultHydrateFallback,
83
85
  UNSAFE_RouteContext: () => RouteContext,
84
86
  UNSAFE_ServerMode: () => ServerMode,
85
87
  UNSAFE_SingleFetchRedirectSymbol: () => SingleFetchRedirectSymbol,
@@ -172,7 +174,7 @@ __export(react_router_exports, {
172
174
  useSubmit: () => useSubmit,
173
175
  useViewTransitionState: () => useViewTransitionState
174
176
  });
175
- module.exports = __toCommonJS(react_router_exports);
177
+ module.exports = __toCommonJS(index_exports);
176
178
 
177
179
  // lib/router/history.ts
178
180
  var Action = /* @__PURE__ */ ((Action2) => {
@@ -2878,7 +2880,7 @@ function createStaticHandler(routes, opts) {
2878
2880
  return stream ? stream(
2879
2881
  requestContext,
2880
2882
  () => Promise.resolve(ctx)
2881
- ) : respond ? respond(ctx) : void 0;
2883
+ ) : respond ? respond(ctx) : ctx;
2882
2884
  };
2883
2885
  if (!isValidMethod(method) && method !== "HEAD") {
2884
2886
  let error = getInternalRouterError(405, { method });
@@ -2896,7 +2898,7 @@ function createStaticHandler(routes, opts) {
2896
2898
  loaderHeaders: {},
2897
2899
  actionHeaders: {}
2898
2900
  };
2899
- return respondOrStreamStaticContext(staticContext) || staticContext;
2901
+ return respondOrStreamStaticContext(staticContext);
2900
2902
  } else if (!matches) {
2901
2903
  let error = getInternalRouterError(404, { pathname: location2.pathname });
2902
2904
  let { matches: notFoundMatches, route } = getShortCircuitMatches(dataRoutes);
@@ -2913,7 +2915,7 @@ function createStaticHandler(routes, opts) {
2913
2915
  loaderHeaders: {},
2914
2916
  actionHeaders: {}
2915
2917
  };
2916
- return respondOrStreamStaticContext(staticContext) || staticContext;
2918
+ return respondOrStreamStaticContext(staticContext);
2917
2919
  }
2918
2920
  if (stream || respond && matches.some(
2919
2921
  (m) => m.route.unstable_middleware || typeof m.route.lazy === "object" && m.route.lazy.unstable_middleware
@@ -2993,7 +2995,7 @@ function createStaticHandler(routes, opts) {
2993
2995
  error,
2994
2996
  skipLoaderErrorBubbling ? routeId : findNearestBoundary(matches, routeId).route.id
2995
2997
  );
2996
- return respondOrStreamStaticContext(staticContext) || staticContext;
2998
+ return respondOrStreamStaticContext(staticContext);
2997
2999
  } else {
2998
3000
  let boundaryRouteId = skipLoaderErrorBubbling ? routeId : findNearestBoundary(
2999
3001
  matches,
@@ -3014,7 +3016,7 @@ function createStaticHandler(routes, opts) {
3014
3016
  actionHeaders: {},
3015
3017
  loaderHeaders: {}
3016
3018
  };
3017
- return respondOrStreamStaticContext(staticContext) || staticContext;
3019
+ return respondOrStreamStaticContext(staticContext);
3018
3020
  }
3019
3021
  }
3020
3022
  );
@@ -5004,6 +5006,10 @@ var DataRouterContext = React.createContext(null);
5004
5006
  DataRouterContext.displayName = "DataRouter";
5005
5007
  var DataRouterStateContext = React.createContext(null);
5006
5008
  DataRouterStateContext.displayName = "DataRouterState";
5009
+ var RSCRouterContext = React.createContext(false);
5010
+ function useIsRSCRouterContext() {
5011
+ return React.useContext(RSCRouterContext);
5012
+ }
5007
5013
  var ViewTransitionContext = React.createContext({
5008
5014
  isTransitioning: false
5009
5015
  });
@@ -5177,6 +5183,7 @@ function useRoutesImpl(routes, locationArg, dataRouterState, future) {
5177
5183
  // router loaded. We can help them understand how to avoid that.
5178
5184
  `useRoutes() may be used only in the context of a <Router> component.`
5179
5185
  );
5186
+ let isRSCRouterContext = useIsRSCRouterContext();
5180
5187
  let { navigator } = React2.useContext(NavigationContext);
5181
5188
  let { matches: parentMatches } = React2.useContext(RouteContext);
5182
5189
  let routeMatch = parentMatches[parentMatches.length - 1];
@@ -5242,7 +5249,8 @@ Please change the parent <Route path="${parentPath}"> to <Route path="${parentPa
5242
5249
  ),
5243
5250
  parentMatches,
5244
5251
  dataRouterState,
5245
- future
5252
+ future,
5253
+ isRSCRouterContext
5246
5254
  );
5247
5255
  if (locationArg && renderedMatches) {
5248
5256
  return /* @__PURE__ */ React2.createElement(
@@ -5333,7 +5341,7 @@ function RenderedRoute({ routeContext, match, children }) {
5333
5341
  }
5334
5342
  return /* @__PURE__ */ React2.createElement(RouteContext.Provider, { value: routeContext }, children);
5335
5343
  }
5336
- function _renderMatches(matches, parentMatches = [], dataRouterState = null, future = null) {
5344
+ function _renderMatches(matches, parentMatches = [], dataRouterState = null, future = null, isRSCRouterContext = false) {
5337
5345
  if (matches == null) {
5338
5346
  if (!dataRouterState) {
5339
5347
  return null;
@@ -5423,7 +5431,9 @@ function _renderMatches(matches, parentMatches = [], dataRouterState = null, fut
5423
5431
  } else {
5424
5432
  children = outlet;
5425
5433
  }
5426
- children = /* @__PURE__ */ React2.createElement(RedirectBoundary, null, children);
5434
+ if (isRSCRouterContext) {
5435
+ children = /* @__PURE__ */ React2.createElement(RedirectBoundary, null, children);
5436
+ }
5427
5437
  return /* @__PURE__ */ React2.createElement(
5428
5438
  RenderedRoute,
5429
5439
  {
@@ -8955,7 +8965,7 @@ function mergeRefs(...refs) {
8955
8965
  var isBrowser = typeof window !== "undefined" && typeof window.document !== "undefined" && typeof window.document.createElement !== "undefined";
8956
8966
  try {
8957
8967
  if (isBrowser) {
8958
- window.__reactRouterVersion = "0.0.0-experimental-bafa092e7";
8968
+ window.__reactRouterVersion = "0.0.0-experimental-47ed76689";
8959
8969
  }
8960
8970
  } catch (e) {
8961
8971
  }
@@ -11839,6 +11849,7 @@ function getRSCSingleFetchDataStrategy(getRouter, ssr, basename, decode2) {
11839
11849
  return {
11840
11850
  hasLoader: M.route.hasLoader,
11841
11851
  hasClientLoader: M.route.hasClientLoader,
11852
+ hasComponent: M.route.hasComponent,
11842
11853
  hasAction: M.route.hasAction,
11843
11854
  hasClientAction: M.route.hasClientAction,
11844
11855
  hasShouldRevalidate: M.route.hasShouldRevalidate
@@ -11848,12 +11859,13 @@ function getRSCSingleFetchDataStrategy(getRouter, ssr, basename, decode2) {
11848
11859
  getFetchAndDecodeViaRSC(decode2),
11849
11860
  ssr,
11850
11861
  basename,
11851
- // If we don't have an element, we need to hit the server loader flow
11852
- // regardless of whether the client loader calls `serverLoader` or not,
11853
- // otherwise we'll have nothing to render.
11854
- // TODO: Do we need to account for API routes? Do we need a
11855
- // `match.hasComponent` flag?
11856
- (match) => match.route.element != null
11862
+ // If the route has a component but we don't have an element, we need to hit
11863
+ // the server loader flow regardless of whether the client loader calls
11864
+ // `serverLoader` or not, otherwise we'll have nothing to render.
11865
+ (match) => {
11866
+ let M = match;
11867
+ return M.route.hasComponent && !M.route.element;
11868
+ }
11857
11869
  );
11858
11870
  return async (args) => args.unstable_runClientMiddleware(async () => {
11859
11871
  let context = args.context;
@@ -12014,19 +12026,17 @@ function RSCHydratedRouter({
12014
12026
  routeDiscovery: { mode: "lazy", manifestPath: "/__manifest" },
12015
12027
  routeModules: {}
12016
12028
  };
12017
- return /* @__PURE__ */ React14.createElement(FrameworkContext.Provider, { value: frameworkContext }, /* @__PURE__ */ React14.createElement(RouterProvider, { router, flushSync: ReactDOM.flushSync }));
12029
+ return /* @__PURE__ */ React14.createElement(RSCRouterContext.Provider, { value: true }, /* @__PURE__ */ React14.createElement(FrameworkContext.Provider, { value: frameworkContext }, /* @__PURE__ */ React14.createElement(RouterProvider, { router, flushSync: ReactDOM.flushSync })));
12018
12030
  }
12019
12031
  function createRouteFromServerManifest(match, payload) {
12020
12032
  let hasInitialData = payload && match.id in payload.loaderData;
12021
12033
  let initialData = payload?.loaderData[match.id];
12022
12034
  let hasInitialError = payload?.errors && match.id in payload.errors;
12023
12035
  let initialError = payload?.errors?.[match.id];
12024
- let isHydrationRequest = match.clientLoader?.hydrate === true || !match.hasLoader || // If we don't have an element, we need to hit the server loader flow
12025
- // regardless of whether the client loader calls `serverLoader` or not,
12026
- // otherwise we'll have nothing to render.
12027
- // TODO: Do we need to account for API routes? Do we need a
12028
- // `match.hasComponent` flag?
12029
- !match.element;
12036
+ let isHydrationRequest = match.clientLoader?.hydrate === true || !match.hasLoader || // If the route has a component but we don't have an element, we need to hit
12037
+ // the server loader flow regardless of whether the client loader calls
12038
+ // `serverLoader` or not, otherwise we'll have nothing to render.
12039
+ match.hasComponent && !match.element;
12030
12040
  let dataRoute = {
12031
12041
  id: match.id,
12032
12042
  element: match.element,
@@ -12377,7 +12387,7 @@ function RSCStaticRouter({
12377
12387
  routeDiscovery: { mode: "lazy", manifestPath: "/__manifest" },
12378
12388
  routeModules: {}
12379
12389
  };
12380
- return /* @__PURE__ */ React15.createElement(FrameworkContext.Provider, { value: frameworkContext }, /* @__PURE__ */ React15.createElement(
12390
+ return /* @__PURE__ */ React15.createElement(RSCRouterContext.Provider, { value: true }, /* @__PURE__ */ React15.createElement(FrameworkContext.Provider, { value: frameworkContext }, /* @__PURE__ */ React15.createElement(
12381
12391
  StaticRouterProvider,
12382
12392
  {
12383
12393
  context,
@@ -12385,7 +12395,7 @@ function RSCStaticRouter({
12385
12395
  hydrate: false,
12386
12396
  nonce: payload.nonce
12387
12397
  }
12388
- ));
12398
+ )));
12389
12399
  }
12390
12400
  function isReactServerRequest(url) {
12391
12401
  return url.pathname.endsWith(".rsc");
@@ -12500,6 +12510,8 @@ function deserializeErrors2(errors) {
12500
12510
  UNSAFE_LocationContext,
12501
12511
  UNSAFE_NavigationContext,
12502
12512
  UNSAFE_RemixErrorBoundary,
12513
+ UNSAFE_RootDefaultErrorBoundary,
12514
+ UNSAFE_RootDefaultHydrateFallback,
12503
12515
  UNSAFE_RouteContext,
12504
12516
  UNSAFE_ServerMode,
12505
12517
  UNSAFE_SingleFetchRedirectSymbol,
@@ -1,5 +1,5 @@
1
1
  /**
2
- * react-router v0.0.0-experimental-bafa092e7
2
+ * react-router v0.0.0-experimental-47ed76689
3
3
  *
4
4
  * Copyright (c) Remix Software Inc.
5
5
  *
@@ -37,6 +37,8 @@ import {
37
37
  RSCHydratedRouter,
38
38
  RSCStaticRouter,
39
39
  RemixErrorBoundary,
40
+ RemixRootDefaultErrorBoundary,
41
+ RemixRootDefaultHydrateFallback,
40
42
  Route,
41
43
  RouteContext,
42
44
  Router,
@@ -134,7 +136,7 @@ import {
134
136
  withComponentProps,
135
137
  withErrorBoundaryProps,
136
138
  withHydrateFallbackProps
137
- } from "./chunk-Q2DCDB5W.mjs";
139
+ } from "./chunk-3HEPNEJL.mjs";
138
140
  export {
139
141
  Await,
140
142
  BrowserRouter,
@@ -169,6 +171,8 @@ export {
169
171
  LocationContext as UNSAFE_LocationContext,
170
172
  NavigationContext as UNSAFE_NavigationContext,
171
173
  RemixErrorBoundary as UNSAFE_RemixErrorBoundary,
174
+ RemixRootDefaultErrorBoundary as UNSAFE_RootDefaultErrorBoundary,
175
+ RemixRootDefaultHydrateFallback as UNSAFE_RootDefaultHydrateFallback,
172
176
  RouteContext as UNSAFE_RouteContext,
173
177
  ServerMode as UNSAFE_ServerMode,
174
178
  SingleFetchRedirectSymbol as UNSAFE_SingleFetchRedirectSymbol,