import { z } from "zod"

import { nullableStringValidator } from "@/utils/zod/stringValidator"

export const rateDefinitionSchema = z.object({
  breakfastIncluded: z.boolean(),
  cancellationRule: z.string(),
  cancellationText: nullableStringValidator,
  displayPriceRed: z.boolean().default(false),
  generalTerms: z.array(z.string()),
  isCampaignRate: z.boolean().default(false),
  isMemberRate: z.boolean().default(false),
  isPackageRate: z.boolean().default(false),
  mustBeGuaranteed: z.boolean(),
  rateCode: z.string(),
  rateType: nullableStringValidator,
  title: z.string(),
})
