Merged in feat/SW-826-sidebar-updates (pull request #888)

Feat/SW-826 sidebar updates

Approved-by: Niclas Edenvin
This commit is contained in:
Pontus Dreij
2024-11-13 19:44:47 +00:00
10 changed files with 34 additions and 11 deletions

View File

@@ -46,3 +46,9 @@
flex-direction: column;
justify-content: center;
}
.googleMaps {
text-decoration: none;
font-family: var(--typography-Body-Regular-fontFamily);
color: var(--Base-Text-Medium-contrast);
}

View File

@@ -32,9 +32,13 @@ export default function Contact({ hotel }: ContactProps) {
<span className={styles.heading}>
{intl.formatMessage({ id: "Driving directions" })}
</span>
<Link href="#" color="peach80">
<a
href={`https://www.google.com/maps/dir/?api=1&destination=${hotel.location.latitude},${hotel.location.longitude}`}
className={styles.googleMaps}
target="_blank"
>
Google Maps
</Link>
</a>
</li>
<li>
<span className={styles.heading}>

View File

@@ -108,6 +108,7 @@ export default function HotelCard({
label={intl.formatMessage({ id: "See hotel details" })}
hotelId={hotelData.operaId}
hotel={hotelData}
showCTA={true}
/>
</section>
<section className={styles.prices}>

View File

@@ -10,12 +10,12 @@ import styles from "./readMore.module.css"
import { ReadMoreProps } from "@/types/components/hotelReservation/selectHotel/selectHotel"
import { SidePeekEnum } from "@/types/components/hotelReservation/sidePeek"
export default function ReadMore({ label, hotelId }: ReadMoreProps) {
export default function ReadMore({ label, hotelId, showCTA }: ReadMoreProps) {
const openSidePeek = useSidePeekStore((state) => state.openSidePeek)
return (
<Button
onPress={() => {
openSidePeek({ key: SidePeekEnum.hotelDetails, hotelId })
openSidePeek({ key: SidePeekEnum.hotelDetails, hotelId, showCTA })
}}
intent="text"
theme="base"

View File

@@ -81,6 +81,7 @@ export default function HotelInfoCard({ hotelData }: HotelInfoCardProps) {
label={intl.formatMessage({ id: "Show all amenities" })}
hotelId={hotelAttributes.operaId}
hotel={hotelAttributes}
showCTA={false}
/>
</div>
</div>

View File

@@ -17,6 +17,7 @@ export default function HotelReservationSidePeek({
const activeSidePeek = useSidePeekStore((state) => state.activeSidePeek)
const hotelId = useSidePeekStore((state) => state.hotelId)
const roomTypeCode = useSidePeekStore((state) => state.roomTypeCode)
const showCTA = useSidePeekStore((state) => state.showCTA)
const close = useSidePeekStore((state) => state.closeSidePeek)
const lang = useLang()
@@ -43,6 +44,7 @@ export default function HotelReservationSidePeek({
hotel={hotelData.data?.attributes}
activeSidePeek={activeSidePeek}
close={close}
showCTA={showCTA}
/>
)}
{selectedRoom && (