A stub authentication provider that provides fallback mock authentication state when real auth is unavailable, designed for UI kit development and testing scenarios. ## Key Components - **`AuthContext`** - React context providing user state and loading status - **`setRealAuthHook()`** - Function to inject a real authentication hook when available - **`useAuth()`** - Hook that returns real auth data if available, otherwise falls back to mock user - **`AuthProvider`** - Context provider component that wraps children with mock auth state ## Usage Example ```typescript // In UI kit or standalone component development import { AuthProvider, useAuth } from './auth-stub'; function MyComponent() { const { user, isLoading } = useAuth(); return (

User: {user?.name}

Loading: {isLoading ? 'Yes' : 'No'}

); } // Wrap your app during development function App() { return ( ); } // In production, inject real auth import { setRealAuthHook } from './auth-stub'; import { useRealAuth } from './real-auth'; setRealAuthHook(useRealAuth); ``` The stub automatically provides a mock user (`{ id: 'mock-user-id', name: 'Mock User' }`) when no real authentication is available, enabling seamless development and testing of auth-dependent components.