/**
 * BuildingType Enum
 * Backend values are numeric (0, 1, 2)
 * Used in: PropertyInformation.buildingType
 */
const BuildingType = Object.freeze({
  APARTMENT: 0,
  VILLA: 1,
  HOUSE: 2,
});

// Map numeric value → Arabic label
const BuildingTypeLabels = Object.freeze({
  [BuildingType.APARTMENT]: 'شقة',
  [BuildingType.VILLA]: 'فيلا',
  [BuildingType.HOUSE]: 'بيت',
});

// Map numeric value → English key (for UI filters)
const BuildingTypeKeys = Object.freeze({
  [BuildingType.APARTMENT]: 'apartment',
  [BuildingType.VILLA]: 'villa',
  [BuildingType.HOUSE]: 'house',
});

// Reverse map: English key → numeric value
const BuildingTypeByKey = Object.freeze({
  apartment: BuildingType.APARTMENT,
  villa: BuildingType.VILLA,
  house: BuildingType.HOUSE,
});

export { BuildingType, BuildingTypeLabels, BuildingTypeKeys, BuildingTypeByKey };
