export const AnnouncementTargetRoles = ['mahasiswa', 'dosen'] as const;

export type AnnouncementTargetRole = (typeof AnnouncementTargetRoles)[number];

export const AnnouncementTargetRoleLabels: Record<
    AnnouncementTargetRole,
    string
> = {
    mahasiswa: 'Mahasiswa',
    dosen: 'Dosen',
};

export type AnnouncementCreator = {
    id: number;
    profile: { full_name: string } | null;
};

export type Announcement = {
    id: number;
    title: string;
    content: string;
    target_roles: AnnouncementTargetRole[];
    created_by: number | null;
    creator: AnnouncementCreator | null;
    created_at: string;
    updated_at: string;
};
