@real-router/react 0.27.0 → 0.27.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/{Await-whr-pcvo.d.ts → Await-D2oCO8nH.d.ts} +1 -1
- package/dist/cjs/{Await-whr-pcvo.d.ts.map → Await-D2oCO8nH.d.ts.map} +1 -1
- package/dist/cjs/{HttpStatusProvider-Dh6cMr95.d.ts → HttpStatusProvider-DfsVxZba.d.ts} +1 -1
- package/dist/cjs/{HttpStatusProvider-Dh6cMr95.d.ts.map → HttpStatusProvider-DfsVxZba.d.ts.map} +1 -1
- package/dist/cjs/{Link-BbOfYYdl.js → Link-CyDwbrFA.js} +2 -2
- package/dist/cjs/{Link-BbOfYYdl.js.map → Link-CyDwbrFA.js.map} +1 -1
- package/dist/cjs/{RouterErrorBoundary-BlJmaoyr.d.ts → RouterErrorBoundary-3UhUelqY.d.ts} +1 -1
- package/dist/cjs/{RouterErrorBoundary-BlJmaoyr.d.ts.map → RouterErrorBoundary-3UhUelqY.d.ts.map} +1 -1
- package/dist/cjs/{RouterProvider-mVFghB3a.js → RouterProvider-CPsCmrRw.js} +2 -2
- package/dist/cjs/{RouterProvider-mVFghB3a.js.map → RouterProvider-CPsCmrRw.js.map} +1 -1
- package/dist/cjs/{RouterProvider-cLYBGwc5.d.ts → RouterProvider-lgNarto1.d.ts} +2 -2
- package/dist/cjs/{RouterProvider-cLYBGwc5.d.ts.map → RouterProvider-lgNarto1.d.ts.map} +1 -1
- package/dist/cjs/{createHttpStatusSink-D_6IiR5E.js → createHttpStatusSink-ChfBL87y.js} +2 -2
- package/dist/cjs/{createHttpStatusSink-D_6IiR5E.js.map → createHttpStatusSink-ChfBL87y.js.map} +1 -1
- package/dist/cjs/index.d.ts +4 -4
- package/dist/cjs/index.js +1 -1
- package/dist/cjs/index.react-server.d.ts +2 -2
- package/dist/cjs/ink.d.ts +2 -2
- package/dist/cjs/ink.js +1 -1
- package/dist/cjs/legacy.d.ts +3 -3
- package/dist/cjs/legacy.js +1 -1
- package/dist/cjs/legacy.ssr.d.ts +2 -2
- package/dist/cjs/legacy.ssr.js +1 -1
- package/dist/cjs/ssr.d.ts +3 -3
- package/dist/cjs/ssr.js +1 -1
- package/dist/cjs/ssr.react-server.d.ts +2 -2
- package/dist/cjs/{useDeferred-DE5YUsfa.d.ts → useDeferred-2fAqMTwr.d.ts} +1 -1
- package/dist/cjs/{useDeferred-DE5YUsfa.d.ts.map → useDeferred-2fAqMTwr.d.ts.map} +1 -1
- package/dist/cjs/useRoute-D2vAzKWM.js +2 -0
- package/dist/cjs/{useRoute-Dudo2K_0.js.map → useRoute-D2vAzKWM.js.map} +1 -1
- package/dist/cjs/{useRouteEnter-gfy65W0D.d.ts → useRouteEnter-CqO9sPPD.d.ts} +1 -1
- package/dist/cjs/{useRouteEnter-gfy65W0D.d.ts.map → useRouteEnter-CqO9sPPD.d.ts.map} +1 -1
- package/dist/cjs/{useRouterTransition-BfayPs0h.d.ts → useRouterTransition-D5nwRENd.d.ts} +2 -2
- package/dist/cjs/{useRouterTransition-BfayPs0h.d.ts.map → useRouterTransition-D5nwRENd.d.ts.map} +1 -1
- package/dist/esm/{Await-qSmJ-ZuN.d.mts → Await-D2oCO8nH.d.mts} +1 -1
- package/dist/esm/{Await-qSmJ-ZuN.d.mts.map → Await-D2oCO8nH.d.mts.map} +1 -1
- package/dist/esm/{HttpStatusProvider-Cy9GSANm.d.mts → HttpStatusProvider-DfsVxZba.d.mts} +1 -1
- package/dist/esm/{HttpStatusProvider-Cy9GSANm.d.mts.map → HttpStatusProvider-DfsVxZba.d.mts.map} +1 -1
- package/dist/esm/{Link-CQr9OFJ7.mjs → Link-uERoM4yk.mjs} +2 -2
- package/dist/esm/{Link-CQr9OFJ7.mjs.map → Link-uERoM4yk.mjs.map} +1 -1
- package/dist/esm/{RouterErrorBoundary-C-MH_yrP.d.mts → RouterErrorBoundary-3UhUelqY.d.mts} +1 -1
- package/dist/esm/{RouterErrorBoundary-C-MH_yrP.d.mts.map → RouterErrorBoundary-3UhUelqY.d.mts.map} +1 -1
- package/dist/esm/{RouterProvider-Dm7104-y.d.mts → RouterProvider-DCchvq4n.d.mts} +2 -2
- package/dist/esm/{RouterProvider-Dm7104-y.d.mts.map → RouterProvider-DCchvq4n.d.mts.map} +1 -1
- package/dist/esm/{RouterProvider-DTZrTBp6.mjs → RouterProvider-DgHypQTJ.mjs} +2 -2
- package/dist/esm/{RouterProvider-DTZrTBp6.mjs.map → RouterProvider-DgHypQTJ.mjs.map} +1 -1
- package/dist/esm/{createHttpStatusSink-BXWVamHE.mjs → createHttpStatusSink-CCocjF4h.mjs} +2 -2
- package/dist/esm/{createHttpStatusSink-BXWVamHE.mjs.map → createHttpStatusSink-CCocjF4h.mjs.map} +1 -1
- package/dist/esm/index.d.mts +4 -4
- package/dist/esm/index.mjs +1 -1
- package/dist/esm/index.react-server.d.mts +2 -2
- package/dist/esm/ink.d.mts +2 -2
- package/dist/esm/ink.mjs +1 -1
- package/dist/esm/legacy.d.mts +3 -3
- package/dist/esm/legacy.mjs +1 -1
- package/dist/esm/legacy.ssr.d.mts +2 -2
- package/dist/esm/legacy.ssr.mjs +1 -1
- package/dist/esm/ssr.d.mts +3 -3
- package/dist/esm/ssr.mjs +1 -1
- package/dist/esm/ssr.react-server.d.mts +2 -2
- package/dist/esm/{useDeferred-B5Qy7ttQ.d.mts → useDeferred-2fAqMTwr.d.mts} +1 -1
- package/dist/esm/{useDeferred-B5Qy7ttQ.d.mts.map → useDeferred-2fAqMTwr.d.mts.map} +1 -1
- package/dist/esm/{useRoute-Bta1jyl2.mjs → useRoute-5MF3j-9P.mjs} +1 -1
- package/dist/esm/{useRoute-Bta1jyl2.mjs.map → useRoute-5MF3j-9P.mjs.map} +1 -1
- package/dist/esm/{useRouteEnter-CxjYofFa.d.mts → useRouteEnter-CqO9sPPD.d.mts} +1 -1
- package/dist/esm/{useRouteEnter-CxjYofFa.d.mts.map → useRouteEnter-CqO9sPPD.d.mts.map} +1 -1
- package/dist/esm/{useRouterTransition-CI1P95ZQ.d.mts → useRouterTransition-PCwA_qj1.d.mts} +2 -2
- package/dist/esm/{useRouterTransition-CI1P95ZQ.d.mts.map → useRouterTransition-PCwA_qj1.d.mts.map} +1 -1
- package/package.json +5 -5
- package/dist/cjs/useRoute-Dudo2K_0.js +0 -2
package/dist/esm/ink.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{n as e,r as t,t as n}from"./useRoute-
|
|
1
|
+
import{n as e,r as t,t as n}from"./useRoute-5MF3j-9P.mjs";import{a as r,f as i,i as a,n as o,o as s,p as c,r as l,t as u,u as d}from"./RouterProvider-DgHypQTJ.mjs";import{memo as f}from"react";import{jsx as p}from"react/jsx-runtime";import{Text as m,useFocus as h,useInput as g}from"ink";function _(e,t,n,r,i){return e?n??r??i:t?r??i:i}function v(e,t){return e.routeName===t.routeName&&e.activeStrict===t.activeStrict&&e.ignoreQueryParams===t.ignoreQueryParams&&e.color===t.color&&e.activeColor===t.activeColor&&e.focusColor===t.focusColor&&e.inverse===t.inverse&&e.activeInverse===t.activeInverse&&e.focusInverse===t.focusInverse&&e.id===t.id&&e.autoFocus===t.autoFocus&&e.onSelect===t.onSelect&&e.children===t.children&&d(e.routeParams,t.routeParams)&&d(e.routeOptions,t.routeOptions)}const y=f(({routeName:n,routeParams:r=t,routeOptions:i=e,activeStrict:a=!1,ignoreQueryParams:o=!0,color:l,activeColor:u,focusColor:d,inverse:f,activeInverse:v,focusInverse:y,id:b,autoFocus:x,onSelect:S,children:C})=>{let w=c(),{isFocused:T}=h({...b!==void 0&&{id:b},...x!==void 0&&{autoFocus:x}}),E=s(n,r,a,o);g((e,t)=>{t.return&&(S?.(),w.navigate(n,r,i).catch(()=>{}))},{isActive:T});let D=_(T,E,d,u,l),O=_(T,E,y,v,f),k={};return D!==void 0&&(k.color=D),O!==void 0&&(k.inverse=O),p(m,{...k,children:C})},v);y.displayName=`InkLink`;const b=({router:e,children:t})=>p(u,{router:e,children:t});export{y as InkLink,b as InkRouterProvider,r as RouterErrorBoundary,a as useNavigator,n as useRoute,i as useRouteNode,l as useRouteUtils,c as useRouter,o as useRouterTransition};
|
|
2
2
|
//# sourceMappingURL=ink.mjs.map
|
package/dist/esm/legacy.d.mts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { n as RouterErrorBoundaryProps, r as LinkProps, t as RouterErrorBoundary } from "./RouterErrorBoundary-
|
|
2
|
-
import { n as Link, t as RouterProvider } from "./RouterProvider-
|
|
3
|
-
import { a as useNavigator, i as useRouteUtils, n as useRouteNode, o as useRouter, r as useRoute, t as useRouterTransition } from "./useRouterTransition-
|
|
1
|
+
import { n as RouterErrorBoundaryProps, r as LinkProps, t as RouterErrorBoundary } from "./RouterErrorBoundary-3UhUelqY.mjs";
|
|
2
|
+
import { n as Link, t as RouterProvider } from "./RouterProvider-DCchvq4n.mjs";
|
|
3
|
+
import { a as useNavigator, i as useRouteUtils, n as useRouteNode, o as useRouter, r as useRoute, t as useRouterTransition } from "./useRouterTransition-PCwA_qj1.mjs";
|
|
4
4
|
import { Navigator } from "@real-router/core";
|
|
5
5
|
import { RouterTransitionSnapshot } from "@real-router/sources";
|
|
6
6
|
export { Link, type LinkProps, type Navigator, RouterErrorBoundary, type RouterErrorBoundaryProps, RouterProvider, type RouterTransitionSnapshot, useNavigator, useRoute, useRouteNode, useRouteUtils, useRouter, useRouterTransition };
|
package/dist/esm/legacy.mjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{t as e}from"./useRoute-
|
|
1
|
+
import{t as e}from"./useRoute-5MF3j-9P.mjs";import{a as t,f as n,i as r,n as i,p as a,r as o,t as s}from"./RouterProvider-DgHypQTJ.mjs";import{t as c}from"./Link-uERoM4yk.mjs";export{c as Link,t as RouterErrorBoundary,s as RouterProvider,r as useNavigator,e as useRoute,n as useRouteNode,o as useRouteUtils,a as useRouter,i as useRouterTransition};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { a as HttpStatusCode, c as StreamedProps, d as ClientOnly, f as ClientOnlyProps, i as createHttpStatusSink, l as ServerOnly, n as HttpStatusProviderProps, o as HttpStatusCodeProps, r as HttpStatusSink, s as Streamed, t as HttpStatusProvider, u as ServerOnlyProps } from "./HttpStatusProvider-
|
|
2
|
-
import { t as useDeferred } from "./useDeferred-
|
|
1
|
+
import { a as HttpStatusCode, c as StreamedProps, d as ClientOnly, f as ClientOnlyProps, i as createHttpStatusSink, l as ServerOnly, n as HttpStatusProviderProps, o as HttpStatusCodeProps, r as HttpStatusSink, s as Streamed, t as HttpStatusProvider, u as ServerOnlyProps } from "./HttpStatusProvider-DfsVxZba.mjs";
|
|
2
|
+
import { t as useDeferred } from "./useDeferred-2fAqMTwr.mjs";
|
|
3
3
|
export { ClientOnly, type ClientOnlyProps, HttpStatusCode, type HttpStatusCodeProps, HttpStatusProvider, type HttpStatusProviderProps, type HttpStatusSink, ServerOnly, type ServerOnlyProps, Streamed, type StreamedProps, createHttpStatusSink, useDeferred };
|
package/dist/esm/legacy.ssr.mjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as e,i as t,n,o as r,r as i,s as a,t as o}from"./createHttpStatusSink-
|
|
1
|
+
import{a as e,i as t,n,o as r,r as i,s as a,t as o}from"./createHttpStatusSink-CCocjF4h.mjs";export{a as ClientOnly,n as HttpStatusCode,i as HttpStatusProvider,r as ServerOnly,t as Streamed,o as createHttpStatusSink,e as useDeferred};
|
package/dist/esm/ssr.d.mts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { a as HttpStatusCode, c as StreamedProps, d as ClientOnly, f as ClientOnlyProps, i as createHttpStatusSink, l as ServerOnly, n as HttpStatusProviderProps, o as HttpStatusCodeProps, r as HttpStatusSink, s as Streamed, t as HttpStatusProvider, u as ServerOnlyProps } from "./HttpStatusProvider-
|
|
2
|
-
import { t as useDeferred } from "./useDeferred-
|
|
3
|
-
import { n as AwaitProps, t as Await } from "./Await-
|
|
1
|
+
import { a as HttpStatusCode, c as StreamedProps, d as ClientOnly, f as ClientOnlyProps, i as createHttpStatusSink, l as ServerOnly, n as HttpStatusProviderProps, o as HttpStatusCodeProps, r as HttpStatusSink, s as Streamed, t as HttpStatusProvider, u as ServerOnlyProps } from "./HttpStatusProvider-DfsVxZba.mjs";
|
|
2
|
+
import { t as useDeferred } from "./useDeferred-2fAqMTwr.mjs";
|
|
3
|
+
import { n as AwaitProps, t as Await } from "./Await-D2oCO8nH.mjs";
|
|
4
4
|
export { Await, type AwaitProps, ClientOnly, type ClientOnlyProps, HttpStatusCode, type HttpStatusCodeProps, HttpStatusProvider, type HttpStatusProviderProps, type HttpStatusSink, ServerOnly, type ServerOnlyProps, Streamed, type StreamedProps, createHttpStatusSink, useDeferred };
|
package/dist/esm/ssr.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as e,i as t,n,o as r,r as i,s as a,t as o}from"./createHttpStatusSink-
|
|
1
|
+
import{a as e,i as t,n,o as r,r as i,s as a,t as o}from"./createHttpStatusSink-CCocjF4h.mjs";import{use as s}from"react";function c({name:t,children:n}){return n(s(e(t)))}export{c as Await,a as ClientOnly,n as HttpStatusCode,i as HttpStatusProvider,r as ServerOnly,t as Streamed,o as createHttpStatusSink,e as useDeferred};
|
|
2
2
|
//# sourceMappingURL=ssr.mjs.map
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { c as StreamedProps, f as ClientOnlyProps, n as HttpStatusProviderProps, o as HttpStatusCodeProps, r as HttpStatusSink, u as ServerOnlyProps } from "./HttpStatusProvider-
|
|
2
|
-
import { n as AwaitProps } from "./Await-
|
|
1
|
+
import { c as StreamedProps, f as ClientOnlyProps, n as HttpStatusProviderProps, o as HttpStatusCodeProps, r as HttpStatusSink, u as ServerOnlyProps } from "./HttpStatusProvider-DfsVxZba.mjs";
|
|
2
|
+
import { n as AwaitProps } from "./Await-D2oCO8nH.mjs";
|
|
3
3
|
export type { AwaitProps, ClientOnlyProps, HttpStatusCodeProps, HttpStatusProviderProps, HttpStatusSink, ServerOnlyProps, StreamedProps };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useDeferred-
|
|
1
|
+
{"version":3,"file":"useDeferred-2fAqMTwr.d.mts","names":[],"sources":["../../src/hooks/useDeferred.tsx"],"mappings":";;AA0BA;;;;;;;;;AAAgE;;;;;;;;;iBAAhD,WAAA,aAAA,CAAyB,GAAA,WAAc,OAAO,CAAC,CAAA"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import{createContext as e,useContext as t}from"react";const n=e(null),r=e(null),i=e(null),a=Object.freeze({}),o=Object.freeze({}),s=new Promise(()=>{}),c=()=>{let e=t(n);if(!e)throw Error(`useRoute must be used within a RouterProvider`);if(!e.route)throw Error(`useRoute called with no active route. Did you forget to await router.start() before rendering, or is the router stopped/disposed?`);return e};export{i as a,s as i,o as n,n as o,a as r,r as s,c as t};
|
|
2
|
-
//# sourceMappingURL=useRoute-
|
|
2
|
+
//# sourceMappingURL=useRoute-5MF3j-9P.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useRoute-
|
|
1
|
+
{"version":3,"file":"useRoute-5MF3j-9P.mjs","names":[],"sources":["../../src/context.ts","../../src/constants.ts","../../src/hooks/useRoute.tsx"],"sourcesContent":["import { createContext } from \"react\";\n\nimport type { RouteContext as RouteContextType } from \"./types\";\nimport type { Router, Navigator } from \"@real-router/core\";\n\n// All three contexts use the `<T | null>` shape with a `null` default. Hooks\n// (useRouter / useRoute / useNavigator) treat a `null` read as\n// \"RouterProvider missing\" and throw — this surfaces wiring mistakes loudly\n// instead of letting consumers chase an undefined router instance.\nexport const RouteContext = createContext<RouteContextType | null>(null);\n\nexport const RouterContext = createContext<Router | null>(null);\n\nexport const NavigatorContext = createContext<Navigator | null>(null);\n","export const EMPTY_PARAMS = Object.freeze({});\n\nexport const EMPTY_OPTIONS = Object.freeze({});\n\n// Singleton forever-pending promise — module-scope so `useDeferred(unknownKey)`\n// returns a stable reference across calls (Suspense boundary doesn't retry).\nexport const NEVER_PROMISE = new Promise<never>(() => {\n // Intentionally never resolves — surfaces a forever-pending Suspense boundary\n // when a key is requested that the loader never declared.\n});\n","import { useContext } from \"react\";\n\nimport { RouteContext } from \"../context\";\n\nimport type { RouteContext as RouteContextType } from \"../types\";\nimport type { Params, State } from \"@real-router/core\";\n\n/**\n * Return shape of `useRoute<P>()` — the context with `route` narrowed to\n * `State<P>` (non-nullable). Promoting the intersection to a named alias\n * keeps the function signature and the cast site in sync.\n */\ntype RouteHookResult<P extends Params = Params> = Omit<\n RouteContextType<P>,\n \"route\"\n> & { route: State<P> };\n\nexport const useRoute = <P extends Params = Params>(): RouteHookResult<P> => {\n const routeContext = useContext(RouteContext);\n\n if (!routeContext) {\n throw new Error(\"useRoute must be used within a RouterProvider\");\n }\n\n if (!routeContext.route) {\n throw new Error(\n \"useRoute called with no active route. Did you forget to await router.start() before rendering, or is the router stopped/disposed?\",\n );\n }\n\n return routeContext as RouteHookResult<P>;\n};\n"],"mappings":"sDASA,MAAa,EAAe,EAAuC,IAAI,EAE1D,EAAgB,EAA6B,IAAI,EAEjD,EAAmB,EAAgC,IAAI,ECbvD,EAAe,OAAO,OAAO,CAAC,CAAC,EAE/B,EAAgB,OAAO,OAAO,CAAC,CAAC,EAIhC,EAAgB,IAAI,YAAqB,CAGtD,CAAC,ECQY,MAAgE,CAC3E,IAAM,EAAe,EAAW,CAAY,EAE5C,GAAI,CAAC,EACH,MAAU,MAAM,+CAA+C,EAGjE,GAAI,CAAC,EAAa,MAChB,MAAU,MACR,mIACF,EAGF,OAAO,CACT"}
|
|
@@ -276,4 +276,4 @@ interface UseRouteEnterOptions {
|
|
|
276
276
|
declare function useRouteEnter(handler: RouteEnterHandler, options?: UseRouteEnterOptions): void;
|
|
277
277
|
//#endregion
|
|
278
278
|
export { RouteExitContext as a, useRouteExit as c, NotFoundProps as d, RouteViewProps as f, useRouteEnter as i, RouteView as l, RouteEnterHandler as n, RouteExitHandler as o, SelfProps as p, UseRouteEnterOptions as r, UseRouteExitOptions as s, RouteEnterContext as t, MatchProps as u };
|
|
279
|
-
//# sourceMappingURL=useRouteEnter-
|
|
279
|
+
//# sourceMappingURL=useRouteEnter-CqO9sPPD.d.mts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useRouteEnter-
|
|
1
|
+
{"version":3,"file":"useRouteEnter-CqO9sPPD.d.mts","names":[],"sources":["../../src/components/modern/RouteView/types.ts","../../src/components/modern/RouteView/components.tsx","../../src/components/modern/RouteView/RouteView.tsx","../../src/hooks/useRouteExit.tsx","../../src/hooks/useRouteEnter.tsx"],"mappings":";;;;UAEiB,cAAA;;WAEN,QAAA;EAFM;EAAA,SAIN,QAAA,EAAU,SAAS;AAAA;AAAA,UAGb,UAAA;EALN;EAAA,SAOA,OAAA;EALU;EAAA,SAOV,KAAA;EAPmB;EAAA,SASnB,SAAA;EANgB;EAAA,SAQhB,QAAA,GAAW,SAAA;EAEQ;EAAA,SAAnB,QAAA,EAAU,SAAS;AAAA;AAAA,UAGb,SAAA;EALN;;;;;AAEmB;EAFnB,SAYA,QAAA,GAAW,SAAA;EAPI;EAAA,SASf,QAAA,EAAU,SAAS;AAAA;AAAA,UAGb,aAAA;EALK;EAAA,SAOX,QAAA,EAAU,SAAS;AAAA;;;iBClCd,KAAA,CAAM,MAAkB,EAAV,UAAU;AAAA,kBAAxB,KAAA;EAAA,IAAK,WAAA;AAAA;AAAA,iBAML,IAAA,CAAK,MAAiB,EAAT,SAAS;AAAA,kBAAtB,IAAA;EAAA,IAAI,WAAA;AAAA;AAAA,iBAMJ,QAAA,CAAS,MAAqB,EAAb,aAAa;AAAA,kBAA9B,QAAA;EAAA,IAAQ,WAAA;AAAA;;;iBCLf,aAAA,CAAA;EACP,QAAA;EACA;AAAA,GACC,QAAA,CAAS,cAAA,IAAkB,YAAA;AAAA,kBAHrB,aAAA;EAAA,IAAa,WAAA;AAAA;AAAA,cAgDT,SAAA,SAAS,aAAA;;;;;;;UCnDL,gBAAA;;EAEf,KAAA,EAAO,KAAA;EHNQ;EGQf,SAAA,EAAW,KAAA;;;;;;;AHJiB;EGY5B,MAAA,EAAQ,WAAA;AAAA;AAAA,UAGO,mBAAA;EHFa;;;;;EGQ5B,aAAa;AAAA;AAAA,KAGH,gBAAA,IACV,OAAA,EAAS,gBAAA,YACC,OAAO;;AHbW;AAG9B;;;;;;;;;AAS8B;AAG9B;;;;AAE8B;;;;AClC9B;;;;AAAwC;;;;;;AAMxC;;;;AAAsC;;;;;;AAMtC;;;;AAA8C;;;;;;;;;ACPJ;;;;;;;;;;;;;;;;;;AAKA;AAAA;;;;;AA6C1C;;;;;;;;;;iBCgEgB,YAAA,CACd,OAAA,EAAS,gBAAA,EACT,OAAA,GAAU,mBAAmB;;;UCrHd,iBAAA;;EAEf,KAAA,EAAO,KAAA;EJNQ;EIQf,aAAA,EAAe,KAAK;AAAA;AAAA,KAGV,iBAAA,IAAqB,OAA0B,EAAjB,iBAAiB;AAAA,UAE1C,oBAAA;EJTN;;;AAAmB;AAG9B;EIYE,aAAa;AAAA;;;;;;;;;;AJFe;AAG9B;;;;;;;;;AAS8B;AAG9B;;;;AAE8B;;;;AClC9B;;;;AAAwC;;;;;;AAMxC;;;;AAAsC;;;;;;AAMtC;;;;AAA8C;;;;;;;;;ACPJ;;;;;;;;;;;;;;;;;;AAKA;iBE4F1B,aAAA,CACd,OAAA,EAAS,iBAAA,EACT,OAAA,GAAU,oBAAoB"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { i as RouteContext } from "./RouterErrorBoundary-
|
|
1
|
+
import { i as RouteContext } from "./RouterErrorBoundary-3UhUelqY.mjs";
|
|
2
2
|
import { Navigator, Params, Router, State } from "@real-router/core";
|
|
3
3
|
import { RouteUtils } from "@real-router/route-utils";
|
|
4
4
|
import { RouterTransitionSnapshot } from "@real-router/sources";
|
|
@@ -53,4 +53,4 @@ declare function useRouteNode(nodeName: string): RouteContext;
|
|
|
53
53
|
declare function useRouterTransition(): RouterTransitionSnapshot;
|
|
54
54
|
//#endregion
|
|
55
55
|
export { useNavigator as a, useRouteUtils as i, useRouteNode as n, useRouter as o, useRoute as r, useRouterTransition as t };
|
|
56
|
-
//# sourceMappingURL=useRouterTransition-
|
|
56
|
+
//# sourceMappingURL=useRouterTransition-PCwA_qj1.d.mts.map
|
package/dist/esm/{useRouterTransition-CI1P95ZQ.d.mts.map → useRouterTransition-PCwA_qj1.d.mts.map}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useRouterTransition-
|
|
1
|
+
{"version":3,"file":"useRouterTransition-PCwA_qj1.d.mts","names":[],"sources":["../../src/hooks/useRouter.tsx","../../src/hooks/useNavigator.tsx","../../src/hooks/useRouteUtils.tsx","../../src/hooks/useRoute.tsx","../../src/hooks/useRouteNode.tsx","../../src/hooks/useRouterTransition.tsx"],"mappings":";;;;;;cAMa,SAAA,QAAgB,MAQ5B;;;cCRY,YAAA,QAAmB,SAQ/B;;;;;;;;ADRD;;;;AAQC;;;;ACRD;;;;AAQC;;;;ACgBD;;cAAa,aAAA,QAAoB,UAIhC;;;;;;;AF5BD;KGMK,eAAA,WAA0B,MAAA,GAAS,MAAA,IAAU,IAAA,CAChD,YAAA,CAAiB,CAAA;EAEb,KAAA,EAAO,KAAA,CAAM,CAAA;AAAA;AAAA,cAEN,QAAA,aAAsB,MAAA,GAAS,MAAA,OAAW,eAAA,CAAgB,CAAA;;;iBCTvD,YAAA,CAAa,QAAA,WAAmB,YAAY;;;iBCD5C,mBAAA,CAAA,GAAuB,wBAAwB"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@real-router/react",
|
|
3
|
-
"version": "0.27.
|
|
3
|
+
"version": "0.27.1",
|
|
4
4
|
"type": "commonjs",
|
|
5
5
|
"description": "React integration for Real-Router",
|
|
6
6
|
"main": "./dist/cjs/index.js",
|
|
@@ -118,19 +118,19 @@
|
|
|
118
118
|
"license": "MIT",
|
|
119
119
|
"sideEffects": false,
|
|
120
120
|
"dependencies": {
|
|
121
|
-
"@real-router/core": "^0.
|
|
121
|
+
"@real-router/core": "^0.55.0",
|
|
122
122
|
"@real-router/route-utils": "^0.2.2",
|
|
123
|
-
"@real-router/sources": "^0.8.
|
|
123
|
+
"@real-router/sources": "^0.8.4"
|
|
124
124
|
},
|
|
125
125
|
"devDependencies": {
|
|
126
126
|
"@testing-library/dom": "10.4.1",
|
|
127
127
|
"@testing-library/jest-dom": "6.9.1",
|
|
128
128
|
"@testing-library/react": "16.3.2",
|
|
129
129
|
"@testing-library/user-event": "14.6.1",
|
|
130
|
-
"ink": "7.0.
|
|
130
|
+
"ink": "7.0.5",
|
|
131
131
|
"ink-testing-library": "4.0.0",
|
|
132
132
|
"vitest-react-profiler": "1.12.0",
|
|
133
|
-
"@real-router/browser-plugin": "^0.17.
|
|
133
|
+
"@real-router/browser-plugin": "^0.17.5"
|
|
134
134
|
},
|
|
135
135
|
"peerDependencies": {
|
|
136
136
|
"@types/react": ">=18.0.0",
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
let e=require(`react`);const t=(0,e.createContext)(null),n=(0,e.createContext)(null),r=(0,e.createContext)(null),i=Object.freeze({}),a=Object.freeze({}),o=new Promise(()=>{}),s=()=>{let n=(0,e.useContext)(t);if(!n)throw Error(`useRoute must be used within a RouterProvider`);if(!n.route)throw Error(`useRoute called with no active route. Did you forget to await router.start() before rendering, or is the router stopped/disposed?`);return n};Object.defineProperty(exports,`a`,{enumerable:!0,get:function(){return r}}),Object.defineProperty(exports,`i`,{enumerable:!0,get:function(){return o}}),Object.defineProperty(exports,`n`,{enumerable:!0,get:function(){return a}}),Object.defineProperty(exports,`o`,{enumerable:!0,get:function(){return t}}),Object.defineProperty(exports,`r`,{enumerable:!0,get:function(){return i}}),Object.defineProperty(exports,`s`,{enumerable:!0,get:function(){return n}}),Object.defineProperty(exports,`t`,{enumerable:!0,get:function(){return s}});
|
|
2
|
-
//# sourceMappingURL=useRoute-Dudo2K_0.js.map
|