/** * CODAI Authentication Provider * * React context provider for authentication state management * with automatic token refresh and session validation. */ import React, { ReactNode } from 'react'; import type { AuthContextType } from './types'; export declare function useAuthContext(): AuthContextType; interface AuthProviderProps { children: ReactNode; config?: { autoRefresh?: boolean; refreshInterval?: number; validateOnMount?: boolean; redirectOnExpiry?: string; enableDevMode?: boolean; }; } /** * Authentication Provider Component * * Provides authentication state and methods to the entire application. * Handles automatic token refresh, session validation, and error management. */ export declare function AuthProvider({ children, config }: AuthProviderProps): import("react/jsx-runtime").JSX.Element; /** * Higher-order component for authentication */ export declare function withAuth

(Component: React.ComponentType

, options?: { redirectTo?: string; requiredPermissions?: string[]; requiredRole?: string; showLoading?: boolean; fallback?: React.ComponentType; }): (props: P) => import("react/jsx-runtime").JSX.Element | null; /** * Hook for requiring authentication */ export declare function useRequireAuth(options?: { redirectTo?: string; requiredPermissions?: string[]; requiredRole?: string; }): { isAuthenticated: boolean; isLoading: boolean; hasAccess: any; }; /** * Component for protecting routes */ interface ProtectedRouteProps { children: ReactNode; fallback?: ReactNode; redirectTo?: string; requiredPermissions?: string[]; requiredRole?: string; showLoading?: boolean; } export declare function ProtectedRoute({ children, fallback, redirectTo, requiredPermissions, requiredRole, showLoading, }: ProtectedRouteProps): string | number | bigint | true | import("react/jsx-runtime").JSX.Element | Iterable | Promise> | Iterable | null | undefined> | null; /** * Component for guest-only routes (login, register, etc.) */ interface GuestOnlyRouteProps { children: ReactNode; redirectTo?: string; } export declare function GuestOnlyRoute({ children, redirectTo, }: GuestOnlyRouteProps): import("react/jsx-runtime").JSX.Element | null; export {}; //# sourceMappingURL=provider-complex.d.ts.map