fix(BOOK-293): changed variants and props on IconButton component * fix(BOOK-293): changed variants and props on IconButton component * fix(BOOK-293): inherit color for icon Approved-by: Bianca Widstam Approved-by: Christel Westerberg
38 lines
1.0 KiB
TypeScript
38 lines
1.0 KiB
TypeScript
"use client"
|
|
import { useIntl } from "react-intl"
|
|
|
|
import ButtonLink from "@scandic-hotels/design-system/ButtonLink"
|
|
import { MaterialIcon } from "@scandic-hotels/design-system/Icons/MaterialIcon"
|
|
|
|
import { useMyStayStore } from "@/stores/my-stay"
|
|
|
|
import ManageStay from "./ManageStay"
|
|
|
|
export default function Upcoming() {
|
|
const intl = useIntl()
|
|
const hotel = useMyStayStore((state) => state.hotel)
|
|
|
|
const directionsUrl = `https://www.google.com/maps/dir/?api=1&destination=${encodeURIComponent(
|
|
`${hotel.name}, ${hotel.address.streetAddress}, ${hotel.address.zipCode} ${hotel.address.city}`
|
|
)}`
|
|
return (
|
|
<>
|
|
<ManageStay />
|
|
<ButtonLink
|
|
variant="Secondary"
|
|
size="md"
|
|
target="_blank"
|
|
href={directionsUrl}
|
|
>
|
|
<span>
|
|
{intl.formatMessage({
|
|
id: "myStay.referenceCard.actions.findUs",
|
|
defaultMessage: "Find us",
|
|
})}
|
|
</span>
|
|
<MaterialIcon color="CurrentColor" icon="location_on" />
|
|
</ButtonLink>
|
|
</>
|
|
)
|
|
}
|