import type { EventStatus } from '@/types/event' const STATUS_ORDER: Record = { draft: 0, published: 1, registration_open: 2, buildup: 3, showday: 4, teardown: 5, closed: 6, } export const EVENT_STATUS_LABEL_NL: Record = { draft: 'Concept', published: 'Gepubliceerd', registration_open: 'Registratie open', buildup: 'Opbouw', showday: 'Showdag', teardown: 'Afbouw', closed: 'Afgesloten', } export function eventStatusLabelNl(status: EventStatus): string { return EVENT_STATUS_LABEL_NL[status] } /** UI styling: forward in lifecycle, rollback, or closing the event. */ export function transitionVisualKind( currentStatus: EventStatus, targetStatus: EventStatus, ): 'forward' | 'backward' | 'dangerous' { if (targetStatus === 'closed') return 'dangerous' const current = STATUS_ORDER[currentStatus] const next = STATUS_ORDER[targetStatus] return next < current ? 'backward' : 'forward' }