import { Badge } from '@ballerine/ui'; import { ASSESSMENT_STATUSES_MAP } from '@ballerine/common'; import { ctw } from '@/common/utils/ctw/ctw'; import { useEllipsesWithTitle } from '@/common/hooks/useEllipsesWithTitle/useEllipsesWithTitle'; export const statusToData = { [ASSESSMENT_STATUSES_MAP['in-progress']]: { variant: 'gray', title: 'Case in progress', text: '', }, [ASSESSMENT_STATUSES_MAP['pending-review']]: { variant: 'gray', title: 'Pending Review', text: 'The review process has not yet started', }, [ASSESSMENT_STATUSES_MAP['under-review']]: { variant: 'info', title: 'Under Review', text: 'The merchant is currently being assessed', }, [ASSESSMENT_STATUSES_MAP['approved']]: { variant: 'success', title: 'Approved', text: 'Merchant reviewed and found compliant or low risk', }, [ASSESSMENT_STATUSES_MAP['rejected']]: { variant: 'destructive', title: 'Rejected', text: 'Merchant reviewed and confirmed non-compliant or high risk', }, } as const; export const KybAndOwnershipAssessmentStatusBadge = ({ status, disabled = false, ...props }: { status: keyof typeof statusToData; disabled?: boolean; }) => { const isInProgress = status === ASSESSMENT_STATUSES_MAP['in-progress']; const { ref, styles } = useEllipsesWithTitle(); return (   {statusToData[status].title} ); }; KybAndOwnershipAssessmentStatusBadge.displayName = 'KybAndOwnershipAssessmentStatusBadge';