import * as react_jsx_runtime from 'react/jsx-runtime'; import React from 'react'; import { LinkProps } from 'react-router'; import { L as LinguiRouterConfig } from './shared/lingui-react-router.DBElLmau.mjs'; export { a as LocaleManifest, R as RedirectBehavior, n as normalizeLocaleKey } from './shared/lingui-react-router.DBElLmau.mjs'; import { R as RouteLocale, u as useRouteLocale } from './shared/lingui-react-router.DWN5Xbd0.mjs'; export { a as RouteLocaleContext, c as createLocalePathContext, f as findLocale, s as stripPathnameLocalePrefix } from './shared/lingui-react-router.DWN5Xbd0.mjs'; /** * The I18nApp component provides internationalization context to the application. * It should be used within a layout component. * * It is recommended to split Layout into two components, otherwise useLingui() won't work * properly. * * @example * // root.tsx * function RootLayout({ children }: Readonly<{ children: ReactNode }>) { * const { i18n } = useLingui() * return ( * * * * * * * * {children} * * * * * ) * } * * export function Layout({ children }: Readonly<{ children: ReactNode }>) { * return ( * * {children} * * ) * } * * @param props - The component props * @param props.children - The child components to be rendered within the i18n context */ declare function I18nApp({ children }: Readonly<{ children: React.ReactNode; }>): react_jsx_runtime.JSX.Element; /** * A drop-in replacement for react-router's Link that automatically prefixes the * current request locale to the target URL. * * If no locale is present in the current request (e.g., navigating from the * default root, "/"), it falls back to rendering a standard Link without * modification. * * - If `to` is a string, the component renders `/${locale}${to}`. * - If `to` is a location object, it prefixes `pathname` with `/${locale}`. */ declare function LocaleLink(props: LinkProps & React.RefAttributes): React.ReactNode; /** * Preloads the locale script on the client. Add to your HTML `` section. * * @example * * * * * */ declare function LocalePreload(): React.DetailedReactHTMLElement<{ rel: string; href: any; as: string; }, HTMLElement> | null; /** * Runtime configuration and utilities for Lingui React Router. */ declare const config: Readonly; /** * The default locale used when no locale can be detected. */ declare const defaultLocale: string; /** * An array of all user-defined locales. */ declare const userLocales: readonly string[]; /** * @deprecated Renamed to RouteLocale, will be removed in a 2.x release */ type PathLocale = RouteLocale; /** * @deprecated Renamed to useRouteLocale, will be removed in a 2.x release */ declare const usePathLocale: typeof useRouteLocale; export { I18nApp, LinguiRouterConfig, LocaleLink, LocalePreload, RouteLocale, config, defaultLocale, usePathLocale, useRouteLocale, userLocales }; export type { PathLocale };