import React__default from 'react'; import { ImageProps } from 'next/image'; import { c as NajmUIProviderProps } from '../NajmUIProvider-wCcltXO6.js'; import '../design-types-CJYLgxmw.js'; import '../paginationLabels-dZLSNxfo.js'; import 'class-variance-authority/types'; import 'class-variance-authority'; import '../NIcon-D73-C51g.js'; interface NextLinkAdapterProps extends Record { href: string; children: React__default.ReactNode; className?: string; [key: string]: any; } declare function NextLinkAdapter({ children, ...props }: NextLinkAdapterProps): React__default.DetailedReactHTMLElement<{ [key: string]: any; href: string; className?: string; }, HTMLElement>; declare function useNextNavigationAdapter(): { pathname: string; push: (path: string) => void; replace: (path: string) => void; }; interface NNextImageProps extends Omit { src: string; /** Swapped in once `src` fails to load. Tried exactly once. */ fallbackSrc?: string; onError?: ImageProps['onError']; } /** * `next/image` with the fallback behavior of `NImage`, for applications that * want the optimizer, the layout reservation, and `fill`/`sizes`. * * Lives only in `najm-kit/next`. The root entry must stay installable without * Next, which is why this cannot be a prop on `NImage`. * * It classifies nothing. An application that serves an asset from a route the * browser must reach directly — an authenticated one, say — passes * `unoptimized` at the call site, because whether a route is protected is the * application's fact and not something a URL shape can be read for. Note also * what `unoptimized` is not: it changes delivery mechanics only. Session * validation, permissions, and what bytes come back remain entirely the * backend's. */ declare function NNextImage({ src, fallbackSrc, loading, priority, onError, ...props }: NNextImageProps): React__default.JSX.Element; /** Where `NajmNextUIProvider` POSTs each preference. */ interface NajmNextUIEndpoints { /** Defaults to `/api/ui-theme`. Receives `{ theme }`. */ theme?: string; /** Defaults to `/api/ui-timezone`. Receives `{ timeZone }`. */ timeZone?: string; } interface NajmNextUIProviderProps extends Omit { endpoints?: NajmNextUIEndpoints; /** * Call `router.refresh()` after a preference is persisted, so server * components re-render against the new cookie. Defaults to `true`. */ refreshOnChange?: boolean; } /** * `NajmUIProvider` with the Next wiring supplied: preferences are POSTed to * cookie route handlers and the router is refreshed so server components see * the change. * * The route handlers are the application's — this package calls them, it does * not ship them. Each takes a JSON body (`{ theme }` / `{ timeZone }`), sets * its cookie, and returns any 2xx. * * This is the only module in the package that imports `next`, which is why * `next` is an *optional* peer dependency: consumers of the root entry never * reach this file. */ declare function NajmNextUIProvider({ endpoints, refreshOnChange, ...props }: NajmNextUIProviderProps): React__default.JSX.Element; export { NNextImage, type NNextImageProps, type NajmNextUIEndpoints, NajmNextUIProvider, type NajmNextUIProviderProps, NextLinkAdapter, type NextLinkAdapterProps, useNextNavigationAdapter };