feat: Add kiosk management, artist selection, and schedule management

- Add KiosksManagement component with full CRUD for kiosks
- Add ScheduleManagement for staff schedules with break reminders
- Update booking flow to allow artist selection by customers
- Add staff_services API for assigning services to artists
- Update staff management UI with service assignment dialog
- Add auto-break reminder when schedule >= 8 hours
- Update availability API to filter artists by service
- Add kiosk management to Aperture dashboard
- Clean up ralphy artifacts and logs
This commit is contained in:
Marco Gallegos
2026-01-21 13:02:06 -06:00
parent 24e5af3860
commit d27354fd5a
71 changed files with 3353 additions and 2701 deletions

View File

@@ -5,8 +5,15 @@ import { useRouter, usePathname } from 'next/navigation'
import { useAuth } from '@/lib/auth/context'
/**
* AuthGuard component that shows loading state while authentication is being determined
* Redirect logic is now handled by AuthProvider to avoid conflicts
* @description Authentication guard component that protects routes requiring login
* @param {Object} props - Component props
* @param {React.ReactNode} props.children - Child components to render when authenticated
* @returns {JSX.Element} Loading state while auth is determined, or children when authenticated
* @audit BUSINESS RULE: AuthGuard is a client-side guard for protected routes
* @audit SECURITY: Prevents rendering protected content until authentication verified
* @audit Validate: Loading state shown while auth provider determines user session
* @audit PERFORMANCE: No API calls - relies on AuthProvider's cached session state
* @audit Note: Actual redirect logic handled by AuthProvider to avoid conflicts
*/
export function AuthGuard({ children }: { children: React.ReactNode }) {
const { loading: authLoading } = useAuth()