import type { EurobonusTier } from "@/types/user"

export const FriendsMembershipLevels = [
  "L1",
  "L2",
  "L3",
  "L4",
  "L5",
  "L6",
  "L7",
] as const

export enum membershipLevels {
  L1 = 1,
  L2 = 2,
  L3 = 3,
  L4 = 4,
  L5 = 5,
  L6 = 6,
  L7 = 7,
}

export enum MembershipLevelEnum {
  L1 = "L1",
  L2 = "L2",
  L3 = "L3",
  L4 = "L4",
  L5 = "L5",
  L6 = "L6",
  L7 = "L7",
}

/**
 * @note Membership levels should always be in English.
 */
export const TIER_TO_FRIEND_MAP: Record<MembershipLevelEnum, string> = {
  [MembershipLevelEnum.L1]: "New Friend",
  [MembershipLevelEnum.L2]: "Good Friend",
  [MembershipLevelEnum.L3]: "Close Friend",
  [MembershipLevelEnum.L4]: "Dear Friend",
  [MembershipLevelEnum.L5]: "Loyal Friend",
  [MembershipLevelEnum.L6]: "True Friend",
  [MembershipLevelEnum.L7]: "Best Friend",
}

export type MembershipLevel = keyof typeof MembershipLevelEnum

export const SAS_EUROBONUS_TIER_TO_NAME_MAP: Record<EurobonusTier, string> = {
  EBB: "Member",
  EBS: "Silver",
  EBG: "Gold",
  EBD: "Diamond",
  EBP: "Pandion",
}
