Legend:
- Unmodified
- Added
- Removed
-
imaps-frontend/node_modules/react-router/dist/react-router.development.js
rd565449 r0c6b92a 1 1 /** 2 * React Router v6.2 6.02 * React Router v6.28.0 3 3 * 4 4 * Copyright (c) Remix Software Inc. … … 50 50 * custom links that are also accessible and preserve right-click behavior. 51 51 * 52 * @see https://reactrouter.com/ hooks/use-href52 * @see https://reactrouter.com/v6/hooks/use-href 53 53 */ 54 54 function useHref(to, { … … 87 87 * Returns true if this component is a descendant of a `<Router>`. 88 88 * 89 * @see https://reactrouter.com/ hooks/use-in-router-context89 * @see https://reactrouter.com/v6/hooks/use-in-router-context 90 90 */ 91 91 function useInRouterContext() { … … 100 100 * be able to provide something higher-level to better suit your needs. 101 101 * 102 * @see https://reactrouter.com/ hooks/use-location102 * @see https://reactrouter.com/v6/hooks/use-location 103 103 */ 104 104 function useLocation() { … … 113 113 * the current location, either by a pop, push, or replace on the history stack. 114 114 * 115 * @see https://reactrouter.com/ hooks/use-navigation-type115 * @see https://reactrouter.com/v6/hooks/use-navigation-type 116 116 */ 117 117 function useNavigationType() { … … 123 123 * `<NavLink>`. 124 124 * 125 * @see https://reactrouter.com/ hooks/use-match125 * @see https://reactrouter.com/v6/hooks/use-match 126 126 */ 127 127 function useMatch(pattern) { … … 150 150 * may also be used by other elements to change the location. 151 151 * 152 * @see https://reactrouter.com/ hooks/use-navigate152 * @see https://reactrouter.com/v6/hooks/use-navigate 153 153 */ 154 154 function useNavigate() { … … 209 209 * Returns the context (if provided) for the child route at this level of the route 210 210 * hierarchy. 211 * @see https://reactrouter.com/ hooks/use-outlet-context211 * @see https://reactrouter.com/v6/hooks/use-outlet-context 212 212 */ 213 213 function useOutletContext() { … … 218 218 * hierarchy. Used internally by `<Outlet>` to render child routes. 219 219 * 220 * @see https://reactrouter.com/ hooks/use-outlet220 * @see https://reactrouter.com/v6/hooks/use-outlet 221 221 */ 222 222 function useOutlet(context) { … … 233 233 * URL that were matched by the route path. 234 234 * 235 * @see https://reactrouter.com/ hooks/use-params235 * @see https://reactrouter.com/v6/hooks/use-params 236 236 */ 237 237 function useParams() { … … 245 245 * Resolves the pathname of the given `to` value against the current location. 246 246 * 247 * @see https://reactrouter.com/ hooks/use-resolved-path247 * @see https://reactrouter.com/v6/hooks/use-resolved-path 248 248 */ 249 249 function useResolvedPath(to, { … … 268 268 * element. 269 269 * 270 * @see https://reactrouter.com/ hooks/use-routes270 * @see https://reactrouter.com/v6/hooks/use-routes 271 271 */ 272 272 function useRoutes(routes, locationArg) { … … 489 489 } else if (future?.v7_partialHydration && parentMatches.length === 0 && !dataRouterState.initialized && dataRouterState.matches.length > 0) { 490 490 // Don't bail if we're initializing with partial hydration and we have 491 // router matches. That means we're actively running `patchRoutesOn Miss`491 // router matches. That means we're actively running `patchRoutesOnNavigation` 492 492 // so we should render down the partial matches to the appropriate 493 493 // `HydrateFallback`. We only do this if `parentMatches` is empty so it … … 626 626 })(DataRouterStateHook || (DataRouterStateHook = {})); 627 627 function getDataRouterConsoleError(hookName) { 628 return `${hookName} must be used within a data router. See https://reactrouter.com/ routers/picking-a-router.`;628 return `${hookName} must be used within a data router. See https://reactrouter.com/v6/routers/picking-a-router.`; 629 629 } 630 630 function useDataRouterContext(hookName) { … … 835 835 return navigate; 836 836 } 837 const alreadyWarned$1 = {}; 838 function warningOnce(key, cond, message) { 839 if (!cond && !alreadyWarned$1[key]) { 840 alreadyWarned$1[key] = true; 841 UNSAFE_warning(false, message) ; 842 } 843 } 844 837 845 const alreadyWarned = {}; 838 function warningOnce(key, cond, message) { 839 if (!cond && !alreadyWarned[key]) { 840 alreadyWarned[key] = true; 841 UNSAFE_warning(false, message) ; 846 function warnOnce(key, message) { 847 if (!alreadyWarned[message]) { 848 alreadyWarned[message] = true; 849 console.warn(message); 850 } 851 } 852 const logDeprecation = (flag, msg, link) => warnOnce(flag, `⚠️ React Router Future Flag Warning: ${msg}. ` + `You can use the \`${flag}\` future flag to opt-in early. ` + `For more information, see ${link}.`); 853 function logV6DeprecationWarnings(renderFuture, routerFuture) { 854 if (!renderFuture?.v7_startTransition) { 855 logDeprecation("v7_startTransition", "React Router will begin wrapping state updates in `React.startTransition` in v7", "https://reactrouter.com/v6/upgrading/future#v7_starttransition"); 856 } 857 if (!renderFuture?.v7_relativeSplatPath && (!routerFuture || !routerFuture.v7_relativeSplatPath)) { 858 logDeprecation("v7_relativeSplatPath", "Relative route resolution within Splat routes is changing in v7", "https://reactrouter.com/v6/upgrading/future#v7_relativesplatpath"); 859 } 860 if (routerFuture) { 861 if (!routerFuture.v7_fetcherPersist) { 862 logDeprecation("v7_fetcherPersist", "The persistence behavior of fetchers is changing in v7", "https://reactrouter.com/v6/upgrading/future#v7_fetcherpersist"); 863 } 864 if (!routerFuture.v7_normalizeFormMethod) { 865 logDeprecation("v7_normalizeFormMethod", "Casing of `formMethod` fields is being normalized to uppercase in v7", "https://reactrouter.com/v6/upgrading/future#v7_normalizeformmethod"); 866 } 867 if (!routerFuture.v7_partialHydration) { 868 logDeprecation("v7_partialHydration", "`RouterProvider` hydration behavior is changing in v7", "https://reactrouter.com/v6/upgrading/future#v7_partialhydration"); 869 } 870 if (!routerFuture.v7_skipActionErrorRevalidation) { 871 logDeprecation("v7_skipActionErrorRevalidation", "The revalidation behavior after 4xx/5xx `action` responses is changing in v7", "https://reactrouter.com/v6/upgrading/future#v7_skipactionerrorrevalidation"); 872 } 842 873 } 843 874 } … … 916 947 basename 917 948 }), [router, navigator, basename]); 949 React.useEffect(() => logV6DeprecationWarnings(future, router.future), [router, future]); 918 950 // The fragment and {null} here are important! We need them to keep React 18's 919 951 // useId happy when we are server-rendering since we may have a <script> here … … 950 982 * A `<Router>` that stores all entries in memory. 951 983 * 952 * @see https://reactrouter.com/ router-components/memory-router984 * @see https://reactrouter.com/v6/router-components/memory-router 953 985 */ 954 986 function MemoryRouter({ … … 979 1011 }, [setStateImpl, v7_startTransition]); 980 1012 React.useLayoutEffect(() => history.listen(setState), [history, setState]); 1013 React.useEffect(() => logV6DeprecationWarnings(future), [future]); 981 1014 return /*#__PURE__*/React.createElement(Router, { 982 1015 basename: basename, … … 995 1028 * `useNavigate` hook instead. 996 1029 * 997 * @see https://reactrouter.com/ components/navigate1030 * @see https://reactrouter.com/v6/components/navigate 998 1031 */ 999 1032 function Navigate({ … … 1033 1066 * Renders the child route's element, if there is one. 1034 1067 * 1035 * @see https://reactrouter.com/ components/outlet1068 * @see https://reactrouter.com/v6/components/outlet 1036 1069 */ 1037 1070 function Outlet(props) { … … 1041 1074 * Declares an element that should be rendered at a certain URL path. 1042 1075 * 1043 * @see https://reactrouter.com/ components/route1076 * @see https://reactrouter.com/v6/components/route 1044 1077 */ 1045 1078 function Route(_props) { … … 1053 1086 * in web browsers or a `<StaticRouter>` for server rendering. 1054 1087 * 1055 * @see https://reactrouter.com/ router-components/router1088 * @see https://reactrouter.com/v6/router-components/router 1056 1089 */ 1057 1090 function Router({ … … 1118 1151 * that best matches the current location. 1119 1152 * 1120 * @see https://reactrouter.com/ components/routes1153 * @see https://reactrouter.com/v6/components/routes 1121 1154 */ 1122 1155 function Routes({ … … 1252 1285 * `<Routes>` to create a route config from its children. 1253 1286 * 1254 * @see https://reactrouter.com/ utils/create-routes-from-children1287 * @see https://reactrouter.com/v6/utils/create-routes-from-children 1255 1288 */ 1256 1289 function createRoutesFromChildren(children, parentPath = []) { … … 1355 1388 routes, 1356 1389 mapRouteProperties, 1357 unstable_dataStrategy: opts?.unstable_dataStrategy,1358 unstable_patchRoutesOnMiss: opts?.unstable_patchRoutesOnMiss1390 dataStrategy: opts?.dataStrategy, 1391 patchRoutesOnNavigation: opts?.patchRoutesOnNavigation 1359 1392 }).initialize(); 1360 1393 } 1361 1394 1362 export { Await, MemoryRouter, Navigate, Outlet, Route, Router, RouterProvider, Routes, DataRouterContext as UNSAFE_DataRouterContext, DataRouterStateContext as UNSAFE_DataRouterStateContext, LocationContext as UNSAFE_LocationContext, NavigationContext as UNSAFE_NavigationContext, RouteContext as UNSAFE_RouteContext, mapRouteProperties as UNSAFE_mapRouteProperties, useRouteId as UNSAFE_useRouteId, useRoutesImpl as UNSAFE_useRoutesImpl, createMemoryRouter, createRoutesFromChildren, createRoutesFromChildren as createRoutesFromElements, renderMatches, useActionData, useAsyncError, useAsyncValue, useBlocker, useHref, useInRouterContext, useLoaderData, useLocation, useMatch, useMatches, useNavigate, useNavigation, useNavigationType, useOutlet, useOutletContext, useParams, useResolvedPath, useRevalidator, useRouteError, useRouteLoaderData, useRoutes };1395 export { Await, MemoryRouter, Navigate, Outlet, Route, Router, RouterProvider, Routes, DataRouterContext as UNSAFE_DataRouterContext, DataRouterStateContext as UNSAFE_DataRouterStateContext, LocationContext as UNSAFE_LocationContext, NavigationContext as UNSAFE_NavigationContext, RouteContext as UNSAFE_RouteContext, logV6DeprecationWarnings as UNSAFE_logV6DeprecationWarnings, mapRouteProperties as UNSAFE_mapRouteProperties, useRouteId as UNSAFE_useRouteId, useRoutesImpl as UNSAFE_useRoutesImpl, createMemoryRouter, createRoutesFromChildren, createRoutesFromChildren as createRoutesFromElements, renderMatches, useActionData, useAsyncError, useAsyncValue, useBlocker, useHref, useInRouterContext, useLoaderData, useLocation, useMatch, useMatches, useNavigate, useNavigation, useNavigationType, useOutlet, useOutletContext, useParams, useResolvedPath, useRevalidator, useRouteError, useRouteLoaderData, useRoutes }; 1363 1396 //# sourceMappingURL=react-router.development.js.map
Note:
See TracChangeset
for help on using the changeset viewer.