import type { ReactNode } from 'react' import { Chip, Loader } from '@sim/emcn' import { AUTH_BUTTON_CLASS } from '@/app/(auth)/components/constants' interface AuthSubmitButtonProps { children: ReactNode /** Label shown beside the spinner while the action is in flight. */ loadingLabel: string loading?: boolean disabled?: boolean type?: 'submit' | 'button' onClick?: () => void } /** * The canonical full-width primary auth action — a `primary`-variant {@link Chip} * with the shared in-flight spinner, so the primary CTA chrome lives in * exactly one place. */ export function AuthSubmitButton({ children, loadingLabel, loading = false, disabled = false, type = 'submit', onClick, }: AuthSubmitButtonProps) { return ( {loading ? ( {loadingLabel} ) : ( children )} ) }