From 5bddaff04d1c8d769894d6755bdd675325932f86 Mon Sep 17 00:00:00 2001 From: Arvid Norlin Date: Fri, 18 Oct 2024 09:26:22 +0200 Subject: [PATCH] fix: handle non-escaped newlines --- .../HotelReservation/EnterDetails/SidePeek/index.tsx | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/components/HotelReservation/EnterDetails/SidePeek/index.tsx b/components/HotelReservation/EnterDetails/SidePeek/index.tsx index abbad2dec..f7d280fed 100644 --- a/components/HotelReservation/EnterDetails/SidePeek/index.tsx +++ b/components/HotelReservation/EnterDetails/SidePeek/index.tsx @@ -33,8 +33,12 @@ export default function EnterDetailsSidePeek({ hotel }: SidePeekProps) {
{hotel.hotelContent.texts.descriptions.medium} - - {hotel.hotelContent.texts.facilityInformation} + {hotel.hotelContent.texts.facilityInformation + .split(/[\n\r]/g) + .filter((p) => p) + .map((paragraph, idx) => ( + {paragraph} + ))}