Files
petfeed/src/lib/milestone-meta.ts
T

53 lines
1.8 KiB
TypeScript

import { MilestoneType } from "@prisma/client";
import {
Cake,
Heart,
Leaf,
Stethoscope,
Milk,
Trophy,
Star,
Award,
type LucideIcon,
} from "lucide-react";
export interface MilestoneMeta {
label: string;
icon: LucideIcon;
}
/**
* Maps every MilestoneType to a display label and Lucide icon (D-09, UI-SPEC).
* Used by MilestoneCard and MilestoneForm.
*/
export const MILESTONE_META: Record<MilestoneType, MilestoneMeta> = {
BIRTHDAY: { label: "Birthday", icon: Cake },
ADOPTION_DAY: { label: "Adoption Day", icon: Heart },
FIRST_OUTING: { label: "First Outing", icon: Leaf },
VET_VISIT: { label: "Vet Visit", icon: Stethoscope },
LITTER: { label: "New Litter", icon: Milk },
FOLLOWERS_500: { label: "500 Followers", icon: Trophy },
FOLLOWERS_1K: { label: "1,000 Followers", icon: Trophy },
FOLLOWERS_2_5K: { label: "2,500 Followers", icon: Trophy },
FOLLOWERS_5K: { label: "5,000 Followers", icon: Trophy },
FOLLOWERS_10K: { label: "10,000 Followers", icon: Star },
FOLLOWERS_25K: { label: "25,000 Followers", icon: Star },
FOLLOWERS_50K: { label: "50,000 Followers", icon: Star },
FOLLOWERS_100K: { label: "100,000 Followers", icon: Star },
FOLLOWERS_250K: { label: "250,000 Followers", icon: Award },
FOLLOWERS_500K: { label: "500,000 Followers", icon: Award },
FOLLOWERS_1M: { label: "1,000,000 Followers", icon: Award },
};
/**
* The 5 user-initiated milestone types shown in the creation picker.
* Follower-threshold types are auto-triggered (D-10) and excluded from the form.
*/
export const USER_INITIATED_MILESTONE_TYPES = [
MilestoneType.BIRTHDAY,
MilestoneType.ADOPTION_DAY,
MilestoneType.FIRST_OUTING,
MilestoneType.VET_VISIT,
MilestoneType.LITTER,
] as const;