/** * Next.js App Router helpers for Athena Auth UI. * * Server-safe surface only (no React client boundary): * - path resolvers for `auth/[[...path]]` and `settings/[path]` * - strict redirect parsers (`parseAthenaRedirectTarget`) * - auth proxy handlers (`athenaAuthHandlers`) * * For the App Router client provider (`router.push` / `router.replace`), * import `AthenaNextAuthProvider` from * `@xylex-group/athena-auth-ui/next/client`. This entry does not export it. * * UI shells remain on the root / `./pages` export (`AuthPage`, `SettingsPage`). * * @example * ```ts * // app/api/auth/[...all]/route.ts * export const { DELETE, GET, HEAD, PATCH, POST, PUT } = athenaAuthHandlers({ * rewriteSetCookiesToRequestOrigin: true, * }) * ``` * * @example * ```tsx * // app/auth/[[...path]]/page.tsx * import { AuthPage } from "@xylex-group/athena-auth-ui" * import { resolveAthenaAuthViewPath } from "@xylex-group/athena-auth-ui/next" * * export default async function Page({ * params, * }: { * params: Promise<{ path?: string[] }> * }) { * const { path } = await params * return * } * ``` */ export { type AthenaAuthProxyHandlersOptions, type AthenaAuthProxyOptions, athenaAuthHandlers, createAthenaAuthProxyHandlers, proxyAthenaAuthRequest, readCookieValue, readCookieValueFromRequest } from './lib/athena/proxy.js'; export { parseAthenaRedirectTarget, resolveAthenaRedirectTarget } from './lib/athena/redirect-target.js'; export { resolveAthenaAuthViewPath, resolveAthenaSettingsPath } from './next/path.js';