import * as React from 'react';

interface AuthUser {
    sub: string;
    email: string;
    name: string | null;
    image: string | null;
    role: string;
    permissions: string[];
    organizationId: string | null;
    mfaEnabled?: boolean;
}
interface PlatformPreferences {
    theme: 'light' | 'dark';
    resolvedTheme: 'light' | 'dark';
    setTheme: (t: 'light' | 'dark') => void;
    dockEnabled: boolean;
    setDockEnabled: (v: boolean) => void;
    dockPosition: 'left' | 'right' | 'bottom';
    setDockPosition: (v: 'left' | 'right' | 'bottom') => void;
    dockAutoHide: boolean;
    setDockAutoHide: (v: boolean) => void;
}
type AuthClient = any;
interface LoginResult {
    success: boolean;
    mfaRequired?: boolean;
    mfaToken?: string;
    error?: string;
}
interface UiAuthContextValue {
    user: AuthUser | null;
    status: 'loading' | 'authenticated' | 'unauthenticated';
    client: AuthClient;
    logout: (returnTo?: string) => Promise<void> | void;
    refresh: () => Promise<boolean> | void;
    getAccessToken: () => Promise<string | null> | string | null;
    loginWithCredentials: (email: string, password: string) => Promise<LoginResult>;
    loginWithProvider: (provider: string, options?: {
        returnTo?: string;
    }) => void | Promise<void>;
    verifyMFA: (mfaToken: string, code: string) => Promise<LoginResult>;
    logoutInFlight?: boolean;
}
declare const UiAuthProvider: React.Provider<UiAuthContextValue | null>;
declare const UiPrefsProvider: React.Provider<PlatformPreferences | null>;
declare function usePlatformPreferences(): PlatformPreferences;

export { type AuthUser as A, type PlatformPreferences as P, type UiAuthContextValue as U, UiAuthProvider as a, UiPrefsProvider as b, usePlatformPreferences as u };
