Merged in feat/SW-1065-meetings-page (pull request #1287)
Feat(SW-1065): Meetings hotel subpage Approved-by: Erik Tiekstra
This commit is contained in:
@@ -0,0 +1,79 @@
|
||||
import type { IntlShape } from "react-intl/src/types"
|
||||
|
||||
import { RoomLighting, SeatingType } from "@/types/enums/meetingRooms"
|
||||
|
||||
export function translateRoomLighting(option: string, intl: IntlShape) {
|
||||
switch (option) {
|
||||
case RoomLighting.WindowsNaturalDaylight:
|
||||
return intl.formatMessage({
|
||||
id: "Windows with natural daylight",
|
||||
})
|
||||
case RoomLighting.IndoorWindowsExcellentLighting:
|
||||
return intl.formatMessage({
|
||||
id: "Indoor windows and excellent lighting",
|
||||
})
|
||||
case RoomLighting.IndoorWindowsFacingHotel:
|
||||
return intl.formatMessage({
|
||||
id: "Indoor windows facing the hotel",
|
||||
})
|
||||
case RoomLighting.NoWindows:
|
||||
return intl.formatMessage({
|
||||
id: "No windows",
|
||||
})
|
||||
case RoomLighting.NoWindowsExcellentLighting:
|
||||
return intl.formatMessage({
|
||||
id: "No windows but excellent lighting",
|
||||
})
|
||||
case RoomLighting.WindowsNaturalDaylightBlackoutFacilities:
|
||||
return intl.formatMessage({
|
||||
id: "Windows natural daylight and blackout facilities",
|
||||
})
|
||||
case RoomLighting.WindowsNaturalDaylightExcellentView:
|
||||
return intl.formatMessage({
|
||||
id: "Windows natural daylight and excellent view",
|
||||
})
|
||||
default:
|
||||
console.warn(`Unsupported conference room ligthing option: ${option}`)
|
||||
return intl.formatMessage({ id: "N/A" })
|
||||
}
|
||||
}
|
||||
|
||||
export function translateSeatingType(type: string, intl: IntlShape) {
|
||||
switch (type) {
|
||||
case SeatingType.Boardroom:
|
||||
return intl.formatMessage({
|
||||
id: "Boardroom",
|
||||
})
|
||||
case SeatingType.Cabaret:
|
||||
return intl.formatMessage({
|
||||
id: "Cabaret seating",
|
||||
})
|
||||
case SeatingType.Classroom:
|
||||
return intl.formatMessage({
|
||||
id: "Classroom",
|
||||
})
|
||||
case SeatingType.FullCircle:
|
||||
return intl.formatMessage({
|
||||
id: "Full circle",
|
||||
})
|
||||
case SeatingType.HalfCircle:
|
||||
return intl.formatMessage({
|
||||
id: "Half circle",
|
||||
})
|
||||
case SeatingType.StandingTable:
|
||||
return intl.formatMessage({
|
||||
id: "Standing table",
|
||||
})
|
||||
case SeatingType.Theatre:
|
||||
return intl.formatMessage({
|
||||
id: "Theatre",
|
||||
})
|
||||
case SeatingType.UShape:
|
||||
return intl.formatMessage({
|
||||
id: "U-shape",
|
||||
})
|
||||
default:
|
||||
console.warn(`Unsupported conference room type : ${type}`)
|
||||
return intl.formatMessage({ id: "N/A" })
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user