From ad7402f2e2782a4bef090137ff62d725492762b0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matilda=20Landstr=C3=B6m?= Date: Tue, 11 Feb 2025 08:27:09 +0000 Subject: [PATCH] Merged in feat/SW-1573-subpage-url (pull request #1297) Feat(SW-1573): Use pageInUrl for hotel subpages * feat(SW-1573): use pageInUrl for hotel subpages Approved-by: Erik Tiekstra Approved-by: Fredrik Thorsson --- .../Accessibility/index.tsx | 10 +++---- .../AccordionAmenities/Parking/index.tsx | 11 +++----- .../HotelPage/SidePeeks/Amenities/index.tsx | 6 ++--- .../SidePeeks/WellnessAndExercise/index.tsx | 9 +++---- components/ContentType/HotelPage/index.tsx | 13 +++++++--- .../HotelSubpage/AdditionalContent/index.tsx | 14 +++------- .../HotelSubpage/Sidebar/index.tsx | 19 +++++--------- components/ContentType/HotelSubpage/index.tsx | 6 ++++- components/ContentType/HotelSubpage/utils.ts | 16 +++--------- constants/routes/hotelSubpages.ts | 26 ------------------- .../routers/hotels/schemas/additionalData.ts | 1 + .../hotelPage/sidepeek/accessibility.ts | 2 +- .../components/hotelPage/sidepeek/parking.ts | 2 +- .../hotelPage/sidepeek/wellnessAndExercise.ts | 2 +- 14 files changed, 45 insertions(+), 92 deletions(-) delete mode 100644 constants/routes/hotelSubpages.ts diff --git a/components/ContentType/HotelPage/SidePeeks/Amenities/AccordionAmenities/Accessibility/index.tsx b/components/ContentType/HotelPage/SidePeeks/Amenities/AccordionAmenities/Accessibility/index.tsx index 595544ef7..12a7e449f 100644 --- a/components/ContentType/HotelPage/SidePeeks/Amenities/AccordionAmenities/Accessibility/index.tsx +++ b/components/ContentType/HotelPage/SidePeeks/Amenities/AccordionAmenities/Accessibility/index.tsx @@ -1,11 +1,8 @@ -import { accessibilitySubPage } from "@/constants/routes/hotelSubpages" - import { ArrowRightIcon } from "@/components/Icons" import AccordionItem from "@/components/TempDesignSystem/Accordion/AccordionItem" import Link from "@/components/TempDesignSystem/Link" import Body from "@/components/TempDesignSystem/Text/Body" import { getIntl } from "@/i18n" -import { getLang } from "@/i18n/serverContext" import styles from "./accessibilityAmenity.module.css" @@ -14,10 +11,9 @@ import { IconName } from "@/types/components/icon" export default async function AccessibilityAmenity({ elevatorPitch, - hasExtraAccessibilityPage, + accessibilityPageUrl, }: AccessibilityAmenityProps) { const intl = await getIntl() - const lang = getLang() return ( {elevatorPitch} )} - {hasExtraAccessibilityPage && ( + {accessibilityPageUrl && ( ( ))} - {hasExtraParkingPage && ( + {parkingPageUrl && ( )} - {wellnessExerciseButton && ( + {wellnessExercisePageUrl && (