diff --git a/apps/partner-sas/components/LanguageSwitcher/index.tsx b/apps/partner-sas/components/LanguageSwitcher/index.tsx index c8378893a..71ce795a4 100644 --- a/apps/partner-sas/components/LanguageSwitcher/index.tsx +++ b/apps/partner-sas/components/LanguageSwitcher/index.tsx @@ -61,7 +61,7 @@ export function LanguageSwitcher({ return (
-
{url ? (
- + {intl.formatMessage({ id: "destination.seeHotelDetails", defaultMessage: "See hotel details", diff --git a/apps/scandic-web/components/Blocks/DynamicContent/ManageCookieConsent/CookieConsentButton/index.tsx b/apps/scandic-web/components/Blocks/DynamicContent/ManageCookieConsent/CookieConsentButton/index.tsx index ceef16959..8d800a130 100644 --- a/apps/scandic-web/components/Blocks/DynamicContent/ManageCookieConsent/CookieConsentButton/index.tsx +++ b/apps/scandic-web/components/Blocks/DynamicContent/ManageCookieConsent/CookieConsentButton/index.tsx @@ -21,8 +21,7 @@ export function CookieConsentButton() { return ( diff --git a/apps/scandic-web/components/Blocks/DynamicContent/Rewards/Redeem/index.tsx b/apps/scandic-web/components/Blocks/DynamicContent/Rewards/Redeem/index.tsx index f6edfb824..ae98b1001 100644 --- a/apps/scandic-web/components/Blocks/DynamicContent/Rewards/Redeem/index.tsx +++ b/apps/scandic-web/components/Blocks/DynamicContent/Rewards/Redeem/index.tsx @@ -18,9 +18,9 @@ import { trpc } from "@scandic-hotels/trpc/client" import useLang from "@/hooks/useLang" import { isRestaurantOnSiteTierReward } from "@/utils/rewards" +import { ConfirmClose } from "./ConfirmClose" import RedeemCampaign from "./Flows/Campaign" import RedeemTier from "./Flows/Tier" -import { ConfirmClose } from "./ConfirmClose" import { RedeemContext } from "./useRedeemFlow" import styles from "./redeem.module.css" @@ -70,12 +70,7 @@ export default function Redeem({ reward, membershipNumber }: RedeemProps) { setAnimation(isOpen ? "visible" : "hidden")} > - diff --git a/apps/scandic-web/components/Blocks/DynamicContent/Stays/Upcoming/Carousel/CarouselCard/index.tsx b/apps/scandic-web/components/Blocks/DynamicContent/Stays/Upcoming/Carousel/CarouselCard/index.tsx index a060a3315..1c119b0a8 100644 --- a/apps/scandic-web/components/Blocks/DynamicContent/Stays/Upcoming/Carousel/CarouselCard/index.tsx +++ b/apps/scandic-web/components/Blocks/DynamicContent/Stays/Upcoming/Carousel/CarouselCard/index.tsx @@ -107,7 +107,7 @@ export default function CarouselCard({ stay }: CarouselCardProps) { {intl.formatMessage({ diff --git a/apps/scandic-web/components/Blocks/DynamicContent/Stays/Upcoming/Carousel/SeeAllCard/index.tsx b/apps/scandic-web/components/Blocks/DynamicContent/Stays/Upcoming/Carousel/SeeAllCard/index.tsx index 8cf590234..e22effc1e 100644 --- a/apps/scandic-web/components/Blocks/DynamicContent/Stays/Upcoming/Carousel/SeeAllCard/index.tsx +++ b/apps/scandic-web/components/Blocks/DynamicContent/Stays/Upcoming/Carousel/SeeAllCard/index.tsx @@ -16,12 +16,7 @@ export function SeeAllCard({ onPress }: SeeAllCardProps) { return (
- diff --git a/apps/scandic-web/components/Blocks/DynamicContent/Stays/Upcoming/EmptyUpcomingStays/index.tsx b/apps/scandic-web/components/Blocks/DynamicContent/Stays/Upcoming/EmptyUpcomingStays/index.tsx index a0f2697a0..b49278fa1 100644 --- a/apps/scandic-web/components/Blocks/DynamicContent/Stays/Upcoming/EmptyUpcomingStays/index.tsx +++ b/apps/scandic-web/components/Blocks/DynamicContent/Stays/Upcoming/EmptyUpcomingStays/index.tsx @@ -65,7 +65,7 @@ export default async function EmptyUpcomingStays() { })}

- + {intl.formatMessage({ id: "stays.findDestinationOrHotel", defaultMessage: "Find hotel or destination", diff --git a/apps/scandic-web/components/Blocks/FullWidthCampaign/index.tsx b/apps/scandic-web/components/Blocks/FullWidthCampaign/index.tsx index 2088fece1..e3cc94bbd 100644 --- a/apps/scandic-web/components/Blocks/FullWidthCampaign/index.tsx +++ b/apps/scandic-web/components/Blocks/FullWidthCampaign/index.tsx @@ -52,8 +52,7 @@ export default function FullWidthCampaign({ target={primary_button.openInNewTab ? "_blank" : undefined} variant="Primary" color="Inverted" - size="Small" - typography="Body/Supporting text (caption)/smBold" + size="sm" className={styles.button} > {primary_button.title} @@ -64,10 +63,9 @@ export default function FullWidthCampaign({ href={secondary_button.href} target={secondary_button.openInNewTab ? "_blank" : undefined} variant="Secondary" - size="Small" + size="sm" color="Inverted" className={styles.button} - typography="Body/Supporting text (caption)/smBold" > {secondary_button.title} diff --git a/apps/scandic-web/components/Blocks/HotelListing/HotelListingItem/index.tsx b/apps/scandic-web/components/Blocks/HotelListing/HotelListingItem/index.tsx index 60335aea6..820e32276 100644 --- a/apps/scandic-web/components/Blocks/HotelListing/HotelListingItem/index.tsx +++ b/apps/scandic-web/components/Blocks/HotelListing/HotelListingItem/index.tsx @@ -93,7 +93,7 @@ export default async function HotelListingItem({ /> {primary_button.title} diff --git a/apps/scandic-web/components/CampaignBanner/index.tsx b/apps/scandic-web/components/CampaignBanner/index.tsx index 35fc5c72e..e1cc157ca 100644 --- a/apps/scandic-web/components/CampaignBanner/index.tsx +++ b/apps/scandic-web/components/CampaignBanner/index.tsx @@ -8,7 +8,6 @@ import { useMediaQuery } from "usehooks-ts" import { debounce } from "@scandic-hotels/common/utils/debounce" import { IconButton } from "@scandic-hotels/design-system/IconButton" -import { MaterialIcon } from "@scandic-hotels/design-system/Icons/MaterialIcon" import { trackClick } from "@scandic-hotels/tracking/base" import { trpc } from "@scandic-hotels/trpc/client" @@ -125,9 +124,8 @@ export default function CampaignBanner() { id: "campaignBanner.dismissBanner", defaultMessage: "Dismiss banner", })} - > - - + iconName="close" + />
) diff --git a/apps/scandic-web/components/Carousel/CarouselNavigation.tsx b/apps/scandic-web/components/Carousel/CarouselNavigation.tsx index 0aa181983..0fe9c22c3 100644 --- a/apps/scandic-web/components/Carousel/CarouselNavigation.tsx +++ b/apps/scandic-web/components/Carousel/CarouselNavigation.tsx @@ -4,7 +4,6 @@ import { cx } from "class-variance-authority" import { useIntl } from "react-intl" import { IconButton } from "@scandic-hotels/design-system/IconButton" -import { MaterialIcon } from "@scandic-hotels/design-system/Icons/MaterialIcon" import { useCarousel } from "./CarouselContext" @@ -28,9 +27,8 @@ export function CarouselPrevious({ className }: CarouselButtonProps) { id: "carousel.previousSlide", defaultMessage: "Previous slide", })} - > - - + iconName="arrow_back" + /> ) } @@ -51,9 +49,8 @@ export function CarouselNext({ className }: CarouselButtonProps) { id: "carousel.nextSlide", defaultMessage: "Next slide", })} - > - - + iconName="arrow_forward" + /> ) } diff --git a/apps/scandic-web/components/ContentType/CampaignPage/Hero/index.tsx b/apps/scandic-web/components/ContentType/CampaignPage/Hero/index.tsx index 9eab3d41e..0fe18b8f6 100644 --- a/apps/scandic-web/components/ContentType/CampaignPage/Hero/index.tsx +++ b/apps/scandic-web/components/ContentType/CampaignPage/Hero/index.tsx @@ -125,8 +125,7 @@ export default async function CampaignHero({ variant="Secondary" color={buttonColor} href={button.url} - typography="Body/Paragraph/mdBold" - size="Medium" + size="md" > {button.cta} diff --git a/apps/scandic-web/components/ContentType/CollectionPage/index.tsx b/apps/scandic-web/components/ContentType/CollectionPage/index.tsx index 7dd29a723..de722a9e7 100644 --- a/apps/scandic-web/components/ContentType/CollectionPage/index.tsx +++ b/apps/scandic-web/components/ContentType/CollectionPage/index.tsx @@ -63,7 +63,7 @@ export async function CollectionPage() { {header.top_primary_button?.url ? ( @@ -96,7 +96,7 @@ export async function CollectionPage() { {header.top_primary_button?.url ? ( {header.top_primary_button.title} diff --git a/apps/scandic-web/components/ContentType/ContentPage/index.tsx b/apps/scandic-web/components/ContentType/ContentPage/index.tsx index 1b79edfce..cd77cb925 100644 --- a/apps/scandic-web/components/ContentType/ContentPage/index.tsx +++ b/apps/scandic-web/components/ContentType/ContentPage/index.tsx @@ -62,7 +62,7 @@ export async function ContentPage() { {header.top_primary_button?.url ? ( {header.top_primary_button.title} diff --git a/apps/scandic-web/components/ContentType/DestinationPage/DestinationCityPage/CityMap/HotelListItem/index.tsx b/apps/scandic-web/components/ContentType/DestinationPage/DestinationCityPage/CityMap/HotelListItem/index.tsx index 7d29b50f8..85b330b6b 100644 --- a/apps/scandic-web/components/ContentType/DestinationPage/DestinationCityPage/CityMap/HotelListItem/index.tsx +++ b/apps/scandic-web/components/ContentType/DestinationPage/DestinationCityPage/CityMap/HotelListItem/index.tsx @@ -143,13 +143,7 @@ export default function HotelListItem({ hotel, url }: HotelListItemProps) { {url && (
- + {intl.formatMessage({ id: "destination.seeHotelDetails", defaultMessage: "See hotel details", diff --git a/apps/scandic-web/components/ContentType/DestinationPage/DestinationCityPage/CityMap/index.tsx b/apps/scandic-web/components/ContentType/DestinationPage/DestinationCityPage/CityMap/index.tsx index 1e7cc5a8c..a5c0a9b5f 100644 --- a/apps/scandic-web/components/ContentType/DestinationPage/DestinationCityPage/CityMap/index.tsx +++ b/apps/scandic-web/components/ContentType/DestinationPage/DestinationCityPage/CityMap/index.tsx @@ -60,12 +60,7 @@ export default function CityMap({ >
{fromCountryPage ? ( -
diff --git a/apps/scandic-web/components/ContentType/DestinationPage/Map/index.tsx b/apps/scandic-web/components/ContentType/DestinationPage/Map/index.tsx index e79e8b0ad..e79d38654 100644 --- a/apps/scandic-web/components/ContentType/DestinationPage/Map/index.tsx +++ b/apps/scandic-web/components/ContentType/DestinationPage/Map/index.tsx @@ -170,9 +170,8 @@ export default function Map({
{bookTableUrl ? (
- + {intl.formatMessage({ id: "restaurantBar.bookATable", defaultMessage: "Book a table", diff --git a/apps/scandic-web/components/ContentType/HotelSubpage/Sidebar/RestaurantSidebar.tsx b/apps/scandic-web/components/ContentType/HotelSubpage/Sidebar/RestaurantSidebar.tsx index eca77143d..137ad0387 100644 --- a/apps/scandic-web/components/ContentType/HotelSubpage/Sidebar/RestaurantSidebar.tsx +++ b/apps/scandic-web/components/ContentType/HotelSubpage/Sidebar/RestaurantSidebar.tsx @@ -47,12 +47,7 @@ export default async function RestaurantSidebar({ ) : null} {bookTableUrl && (
- + {intl.formatMessage({ id: "restaurantBar.bookATable", defaultMessage: "Book a table", diff --git a/apps/scandic-web/components/ContentType/PromoCampaignPage/ExpiredPromoCampaign/index.tsx b/apps/scandic-web/components/ContentType/PromoCampaignPage/ExpiredPromoCampaign/index.tsx index 8ae338004..c55d8e6c1 100644 --- a/apps/scandic-web/components/ContentType/PromoCampaignPage/ExpiredPromoCampaign/index.tsx +++ b/apps/scandic-web/components/ContentType/PromoCampaignPage/ExpiredPromoCampaign/index.tsx @@ -41,7 +41,7 @@ export default async function ExpiredPromoCampaign() {
- + {intl.formatMessage({ id: "promoCampaign.seeAllOffers", defaultMessage: "See all offers", diff --git a/apps/scandic-web/components/ContentType/PromoCampaignPage/Hero/ActivateOffer/index.tsx b/apps/scandic-web/components/ContentType/PromoCampaignPage/Hero/ActivateOffer/index.tsx index 07eeb9818..f1667536d 100644 --- a/apps/scandic-web/components/ContentType/PromoCampaignPage/Hero/ActivateOffer/index.tsx +++ b/apps/scandic-web/components/ContentType/PromoCampaignPage/Hero/ActivateOffer/index.tsx @@ -47,10 +47,9 @@ export default function ActivateOffer({ function ActivateButton() { return ( diff --git a/apps/scandic-web/components/DigitalTeamMemberCard/EmployeeBenefits/CallToActions/index.tsx b/apps/scandic-web/components/DigitalTeamMemberCard/EmployeeBenefits/CallToActions/index.tsx index 70953ad25..e3f1a78c3 100644 --- a/apps/scandic-web/components/DigitalTeamMemberCard/EmployeeBenefits/CallToActions/index.tsx +++ b/apps/scandic-web/components/DigitalTeamMemberCard/EmployeeBenefits/CallToActions/index.tsx @@ -33,7 +33,7 @@ export default async function EmployeeBenefitsCallToActions() { })}

- + {intl.formatMessage({ id: "dtmc.logInAndLinkEmployment", defaultMessage: "Log in and link employment", @@ -50,7 +50,7 @@ export default async function EmployeeBenefitsCallToActions() { })}

- + {intl.formatMessage({ id: "dtmc.signUpAndLinkEmployment", defaultMessage: "Sign up and link employment", @@ -65,12 +65,7 @@ export default async function EmployeeBenefitsCallToActions() { return (
- + {intl.formatMessage({ id: "dtmc.showTeamMemberCard", defaultMessage: "Show Team Member Card", @@ -86,7 +81,7 @@ export default async function EmployeeBenefitsCallToActions() { diff --git a/apps/scandic-web/components/Forms/Edit/Profile/index.tsx b/apps/scandic-web/components/Forms/Edit/Profile/index.tsx index b7dd4aa5f..ab6d60492 100644 --- a/apps/scandic-web/components/Forms/Edit/Profile/index.tsx +++ b/apps/scandic-web/components/Forms/Edit/Profile/index.tsx @@ -159,7 +159,7 @@ export default function Form({ user }: EditFormProps) { defaultMessage: "Discard unsaved changes?", })} trigger={ - diff --git a/apps/scandic-web/components/HotelReservation/MyStay/ReferenceCard/Actions/Upcoming/index.tsx b/apps/scandic-web/components/HotelReservation/MyStay/ReferenceCard/Actions/Upcoming/index.tsx index 84d9a010c..8a19a3767 100644 --- a/apps/scandic-web/components/HotelReservation/MyStay/ReferenceCard/Actions/Upcoming/index.tsx +++ b/apps/scandic-web/components/HotelReservation/MyStay/ReferenceCard/Actions/Upcoming/index.tsx @@ -20,10 +20,9 @@ export default function Upcoming() { {intl.formatMessage({ diff --git a/apps/scandic-web/components/HotelReservation/MyStay/ReferenceCard/GuaranteeInfo/GuaranteeInfoModal/index.tsx b/apps/scandic-web/components/HotelReservation/MyStay/ReferenceCard/GuaranteeInfo/GuaranteeInfoModal/index.tsx index f39bd49e3..c4b562a63 100644 --- a/apps/scandic-web/components/HotelReservation/MyStay/ReferenceCard/GuaranteeInfo/GuaranteeInfoModal/index.tsx +++ b/apps/scandic-web/components/HotelReservation/MyStay/ReferenceCard/GuaranteeInfo/GuaranteeInfoModal/index.tsx @@ -59,8 +59,7 @@ export function GuaranteeInfoModal() { className={styles.closeButton} variant="Secondary" color="Primary" - size="Medium" - typography="Body/Paragraph/mdBold" + size="md" onPress={() => setIsOpen(false)} > {intl.formatMessage({ diff --git a/apps/scandic-web/components/HotelReservation/MyStay/Rooms/MultiRoom/Room.tsx b/apps/scandic-web/components/HotelReservation/MyStay/Rooms/MultiRoom/Room.tsx index 096dfba66..92b30085f 100644 --- a/apps/scandic-web/components/HotelReservation/MyStay/Rooms/MultiRoom/Room.tsx +++ b/apps/scandic-web/components/HotelReservation/MyStay/Rooms/MultiRoom/Room.tsx @@ -268,13 +268,9 @@ export default function Room({ booking, roomNr, user }: RoomProps) { variant="Muted" emphasis className={styles.termsInfoIcon} - > - - + iconName="info" + size="md" + /> } >
diff --git a/apps/scandic-web/components/HotelReservation/MyStay/Rooms/SingleRoom/Details/Terms/Terms.tsx b/apps/scandic-web/components/HotelReservation/MyStay/Rooms/SingleRoom/Details/Terms/Terms.tsx index 59d5d327e..4c73e9aea 100644 --- a/apps/scandic-web/components/HotelReservation/MyStay/Rooms/SingleRoom/Details/Terms/Terms.tsx +++ b/apps/scandic-web/components/HotelReservation/MyStay/Rooms/SingleRoom/Details/Terms/Terms.tsx @@ -55,9 +55,8 @@ export default function Terms() { emphasis size="sm" className={styles.button} - > - - + iconName="info" + /> } >
diff --git a/apps/scandic-web/components/HotelReservation/MyStay/Rooms/SingleRoom/RoomDetailsSidePeek.tsx b/apps/scandic-web/components/HotelReservation/MyStay/Rooms/SingleRoom/RoomDetailsSidePeek.tsx index 9dd3c364f..8d019fd6c 100644 --- a/apps/scandic-web/components/HotelReservation/MyStay/Rooms/SingleRoom/RoomDetailsSidePeek.tsx +++ b/apps/scandic-web/components/HotelReservation/MyStay/Rooms/SingleRoom/RoomDetailsSidePeek.tsx @@ -34,7 +34,7 @@ export default function RoomDetailsSidePeek({ <>
diff --git a/apps/scandic-web/components/MyPages/CopyMembershipIdButton/index.tsx b/apps/scandic-web/components/MyPages/CopyMembershipIdButton/index.tsx index ec8fec0b6..9e7ee20a1 100644 --- a/apps/scandic-web/components/MyPages/CopyMembershipIdButton/index.tsx +++ b/apps/scandic-web/components/MyPages/CopyMembershipIdButton/index.tsx @@ -48,7 +48,7 @@ export default function CopyMembershipIdButton({ onClick={handleCopy} className={styles.copyButton} variant="Text" - size="Small" + size="sm" > diff --git a/apps/scandic-web/components/MyPages/LevelProgressCard/LevelProgressModal/index.tsx b/apps/scandic-web/components/MyPages/LevelProgressCard/LevelProgressModal/index.tsx index 767377f11..7f44adac2 100644 --- a/apps/scandic-web/components/MyPages/LevelProgressCard/LevelProgressModal/index.tsx +++ b/apps/scandic-web/components/MyPages/LevelProgressCard/LevelProgressModal/index.tsx @@ -4,7 +4,7 @@ import { useIntl } from "react-intl" import { dt } from "@scandic-hotels/common/dt" -import { IconButton } from "@scandic-hotels/design-system/IconButton" // client only +import { IconButton } from "@scandic-hotels/design-system/IconButton"; // client only import { MaterialIcon } from "@scandic-hotels/design-system/Icons/MaterialIcon" import Modal from "@scandic-hotels/design-system/Modal" import Link from "@scandic-hotels/design-system/OldDSLink" @@ -35,17 +35,11 @@ export default function LevelProgressModal({ - - + } >
diff --git a/apps/scandic-web/components/MyPages/Profile/index.tsx b/apps/scandic-web/components/MyPages/Profile/index.tsx index d99bd9e9a..44c99a320 100644 --- a/apps/scandic-web/components/MyPages/Profile/index.tsx +++ b/apps/scandic-web/components/MyPages/Profile/index.tsx @@ -140,12 +140,7 @@ export default async function Profile() { - + {intl.formatMessage({ id: "myPages.editProfile", defaultMessage: "Edit profile", diff --git a/apps/scandic-web/components/MyPages/ProfilingConsent/Banner/Button.tsx b/apps/scandic-web/components/MyPages/ProfilingConsent/Banner/Button.tsx index 36e54adb5..7766fb3be 100644 --- a/apps/scandic-web/components/MyPages/ProfilingConsent/Banner/Button.tsx +++ b/apps/scandic-web/components/MyPages/ProfilingConsent/Banner/Button.tsx @@ -18,9 +18,8 @@ export function BannerButton({ cta }: BannerButtonProps) { diff --git a/apps/scandic-web/components/MyPages/ProfilingConsent/Modal/index.tsx b/apps/scandic-web/components/MyPages/ProfilingConsent/Modal/index.tsx index 8da4c917d..d22e40007 100644 --- a/apps/scandic-web/components/MyPages/ProfilingConsent/Modal/index.tsx +++ b/apps/scandic-web/components/MyPages/ProfilingConsent/Modal/index.tsx @@ -13,9 +13,9 @@ import { trpc } from "@scandic-hotels/trpc/client" import { useUpdateProfilingConsent } from "@/hooks/useUpdateProfilingConsent" import { + setDismissed as persistDismissed, profilingConsentOpenEvent, readDismissed, - setDismissed as persistDismissed, } from "@/utils/profilingConsent" import { trackConsentAction } from "@/utils/tracking/profilingConsent" @@ -159,10 +159,10 @@ export default function ProfilingConsentModal({
diff --git a/apps/scandic-web/components/TempDesignSystem/ShowMoreButton/index.tsx b/apps/scandic-web/components/TempDesignSystem/ShowMoreButton/index.tsx index 413f2c92b..80d0f86d8 100644 --- a/apps/scandic-web/components/TempDesignSystem/ShowMoreButton/index.tsx +++ b/apps/scandic-web/components/TempDesignSystem/ShowMoreButton/index.tsx @@ -17,8 +17,7 @@ interface ShowMoreButtonProps extends ComponentProps { export default function ShowMoreButton({ variant = "Text", color = "Primary", - size = "Medium", - typography = "Body/Paragraph/mdBold", + size = "md", showLess, textShowMore, textShowLess, @@ -47,7 +46,6 @@ export default function ShowMoreButton({ color={color} size={size} onPress={loadMoreData} - typography={typography} {...props} > {showLess ? ( diff --git a/apps/scandic-web/components/TempDesignSystem/TeaserCard/Sidepeek/index.tsx b/apps/scandic-web/components/TempDesignSystem/TeaserCard/Sidepeek/index.tsx index 8abd226b0..c9acd54b7 100644 --- a/apps/scandic-web/components/TempDesignSystem/TeaserCard/Sidepeek/index.tsx +++ b/apps/scandic-web/components/TempDesignSystem/TeaserCard/Sidepeek/index.tsx @@ -27,8 +27,7 @@ export default function TeaserCardSidepeek({ onPress={() => setSidePeekIsOpen(true)} variant="Secondary" color="Primary" - size="Small" - typography="Body/Supporting text (caption)/smBold" + size="sm" > {button.call_to_action_text} @@ -54,8 +53,7 @@ export default function TeaserCardSidepeek({ @@ -66,8 +64,7 @@ export default function TeaserCardSidepeek({ diff --git a/apps/scandic-web/components/TempDesignSystem/TeaserCard/index.tsx b/apps/scandic-web/components/TempDesignSystem/TeaserCard/index.tsx index 090bb649b..c40a1b55d 100644 --- a/apps/scandic-web/components/TempDesignSystem/TeaserCard/index.tsx +++ b/apps/scandic-web/components/TempDesignSystem/TeaserCard/index.tsx @@ -57,8 +57,7 @@ export default function TeaserCard({ - - - +
void }) { const intl = useIntl() return ( - diff --git a/packages/booking-flow/lib/components/BookingConfirmation/Receipt/Room/index.tsx b/packages/booking-flow/lib/components/BookingConfirmation/Receipt/Room/index.tsx index 200b969f1..318756b0f 100644 --- a/packages/booking-flow/lib/components/BookingConfirmation/Receipt/Room/index.tsx +++ b/packages/booking-flow/lib/components/BookingConfirmation/Receipt/Room/index.tsx @@ -137,7 +137,6 @@ export function ReceiptRoom({
{isDirty && isBookingFlow ? intl.formatMessage({ @@ -210,9 +207,13 @@ export function BookingWidgetFormContentSkeleton() {
- - - +
@@ -221,10 +222,9 @@ export function BookingWidgetFormContentSkeleton() { @@ -231,8 +226,7 @@ export default function GuestsRoomsPickerDialog({ className={styles.hideOnMobile} variant="Tertiary" color="Primary" - size="Small" - typography="Body/Supporting text (caption)/smBold" + size="sm" > {doneLabel} diff --git a/packages/booking-flow/lib/components/EnterDetails/Details/RoomOne/JoinScandicFriendsCard/index.tsx b/packages/booking-flow/lib/components/EnterDetails/Details/RoomOne/JoinScandicFriendsCard/index.tsx index e3afbc22a..66fd7eeec 100644 --- a/packages/booking-flow/lib/components/EnterDetails/Details/RoomOne/JoinScandicFriendsCard/index.tsx +++ b/packages/booking-flow/lib/components/EnterDetails/Details/RoomOne/JoinScandicFriendsCard/index.tsx @@ -76,7 +76,7 @@ export function JoinScandicFriendsCard({ name = "join" }: Props) { setIsOpen(true)} @@ -59,8 +58,7 @@ export function GuaranteeInfo({ buttonClassName }: GuaranteeInfoProps) { className={styles.closeButton} variant="Secondary" color="Primary" - size="Medium" - typography="Body/Paragraph/mdBold" + size="md" onPress={() => setIsOpen(false)} > {intl.formatMessage({ diff --git a/packages/booking-flow/lib/components/EnterDetails/Payment/PaymentClient.tsx b/packages/booking-flow/lib/components/EnterDetails/Payment/PaymentClient.tsx index c10a0ff0c..1513e50f3 100644 --- a/packages/booking-flow/lib/components/EnterDetails/Payment/PaymentClient.tsx +++ b/packages/booking-flow/lib/components/EnterDetails/Payment/PaymentClient.tsx @@ -36,7 +36,6 @@ import useLang from "../../../hooks/useLang" import { useEnterDetailsStore } from "../../../stores/enter-details" import ConfirmBooking from "../Confirm" import PriceChangeDialog from "../PriceChangeDialog" -import { writeGlaToSessionStorage } from "./PaymentCallback/helpers" import BookingAlert from "./BookingAlert" import { GuaranteeInfo } from "./GuaranteeInfo" import { @@ -47,6 +46,7 @@ import { mustGuaranteeBooking, writePaymentInfoToSessionStorage, } from "./helpers" +import { writeGlaToSessionStorage } from "./PaymentCallback/helpers" import { type PaymentFormData, paymentSchema } from "./schema" import { getPaymentHeadingConfig } from "./utils" @@ -497,8 +497,7 @@ export default function PaymentClient({ type="submit" isDisabled={isSubmitting} isPending={isSubmitting} - size="Medium" - typography="Body/Paragraph/mdBold" + size="md" > {intl.formatMessage({ id: "enterDetails.completeBooking", diff --git a/packages/booking-flow/lib/components/EnterDetails/SelectedRoom/index.tsx b/packages/booking-flow/lib/components/EnterDetails/SelectedRoom/index.tsx index 66ab47153..6e643cba9 100644 --- a/packages/booking-flow/lib/components/EnterDetails/SelectedRoom/index.tsx +++ b/packages/booking-flow/lib/components/EnterDetails/SelectedRoom/index.tsx @@ -82,11 +82,10 @@ export default function SelectedRoom() { diff --git a/packages/booking-flow/lib/components/RoomDetailsSidePeek/index.tsx b/packages/booking-flow/lib/components/RoomDetailsSidePeek/index.tsx index 8d54f8a88..f990218ee 100644 --- a/packages/booking-flow/lib/components/RoomDetailsSidePeek/index.tsx +++ b/packages/booking-flow/lib/components/RoomDetailsSidePeek/index.tsx @@ -26,22 +26,17 @@ interface RoomDetailsSidePeekProps { const buttonPropsMap: Record< NonNullable, - Pick< - React.ComponentProps, - "variant" | "color" | "size" | "typography" - > + Pick, "variant" | "color" | "size"> > = { primary: { variant: "Text", color: "Primary", - size: "Medium", - typography: "Body/Paragraph/mdBold", + size: "md", }, secondary: { variant: "Text", color: "Inverted", - size: "Small", - typography: "Body/Supporting text (caption)/smBold", + size: "sm", }, } diff --git a/packages/booking-flow/lib/components/SelectHotel/Filters/FilterAndSortModal/index.tsx b/packages/booking-flow/lib/components/SelectHotel/Filters/FilterAndSortModal/index.tsx index ffad6d0e4..5223ab43e 100644 --- a/packages/booking-flow/lib/components/SelectHotel/Filters/FilterAndSortModal/index.tsx +++ b/packages/booking-flow/lib/components/SelectHotel/Filters/FilterAndSortModal/index.tsx @@ -135,7 +135,7 @@ export default function FilterAndSortModal({ return ( <> -

diff --git a/packages/booking-flow/lib/components/SelectRate/RoomsContainer/RateSummary/MobileSummary/Room/index.tsx b/packages/booking-flow/lib/components/SelectRate/RoomsContainer/RateSummary/MobileSummary/Room/index.tsx index b935c1492..eb9e2fbc9 100644 --- a/packages/booking-flow/lib/components/SelectRate/RoomsContainer/RateSummary/MobileSummary/Room/index.tsx +++ b/packages/booking-flow/lib/components/SelectRate/RoomsContainer/RateSummary/MobileSummary/Room/index.tsx @@ -159,7 +159,6 @@ export default function Room({ - )} {showPrimaryButton && !inMainArea && ( - )} {showSecondaryButton && ( diff --git a/packages/design-system/lib/components/FakeButton/index.tsx b/packages/design-system/lib/components/FakeButton/index.tsx index db9420452..2102c8050 100644 --- a/packages/design-system/lib/components/FakeButton/index.tsx +++ b/packages/design-system/lib/components/FakeButton/index.tsx @@ -4,6 +4,7 @@ import { variants } from './variants' import { cx, type VariantProps } from 'class-variance-authority' import type { HTMLAttributes } from 'react' +import { Typography } from '../Typography' interface FakeButtonProps extends @@ -16,7 +17,6 @@ export function FakeButton({ variant, color, size, - typography, fullWidth, children, className, @@ -28,19 +28,26 @@ export function FakeButton({ color, size, variant, - typography, fullWidth, isHovered, className, }) return ( - - {children} - + + {children} + + ) } diff --git a/packages/design-system/lib/components/Form/Compositions/ExampleForm.stories.tsx b/packages/design-system/lib/components/Form/Compositions/ExampleForm.stories.tsx index 1c98b02bc..41e7c7d22 100644 --- a/packages/design-system/lib/components/Form/Compositions/ExampleForm.stories.tsx +++ b/packages/design-system/lib/components/Form/Compositions/ExampleForm.stories.tsx @@ -1,14 +1,14 @@ +import { zodResolver } from '@hookform/resolvers/zod' import type { Meta, StoryObj } from '@storybook/nextjs-vite' -import { fn } from 'storybook/test' import { useEffect } from 'react' import { FormProvider, useForm } from 'react-hook-form' -import { zodResolver } from '@hookform/resolvers/zod' +import { fn } from 'storybook/test' import { z } from 'zod' -import { FormInput } from '../FormInput' import { Button } from '../../Button' -import { Typography } from '../../Typography' import { MaterialIcon } from '../../Icons/MaterialIcon' +import { Typography } from '../../Typography' +import { FormInput } from '../FormInput' const createExampleFormSchema = (prefix?: string) => { const getKey = (key: string) => (prefix ? `${prefix}_${key}` : key) @@ -127,7 +127,7 @@ function ExampleFormComponent({ registerOptions={{ required: true }} /> - @@ -292,7 +292,7 @@ function SignupFormComponent({ registerOptions={{ required: true }} /> - diff --git a/packages/design-system/lib/components/HotelCard/HotelCard.stories.tsx b/packages/design-system/lib/components/HotelCard/HotelCard.stories.tsx index f627b03a7..1ba782f95 100644 --- a/packages/design-system/lib/components/HotelCard/HotelCard.stories.tsx +++ b/packages/design-system/lib/components/HotelCard/HotelCard.stories.tsx @@ -76,11 +76,7 @@ export const Default: Story = { ], belowInfoSlot: ( - diff --git a/packages/design-system/lib/components/HotelCard/HotelDialogCard/StandaloneHotelCardDialog/index.tsx b/packages/design-system/lib/components/HotelCard/HotelDialogCard/StandaloneHotelCardDialog/index.tsx index 14556161d..bb14febc2 100644 --- a/packages/design-system/lib/components/HotelCard/HotelDialogCard/StandaloneHotelCardDialog/index.tsx +++ b/packages/design-system/lib/components/HotelCard/HotelDialogCard/StandaloneHotelCardDialog/index.tsx @@ -4,7 +4,6 @@ import { useState } from 'react' import { useIntl } from 'react-intl' import { IconButton } from '../../../IconButton' -import { MaterialIcon } from '../../../Icons/MaterialIcon' import { Typography } from '../../../Typography' import { HotelCardDialogImage } from '../../HotelCardDialogImage' @@ -84,9 +83,8 @@ export function StandaloneHotelCardDialog({ id: 'common.close', defaultMessage: 'Close', })} - > - - + iconName="close" + /> {intl.formatMessage({ diff --git a/packages/design-system/lib/components/HotelCard/index.tsx b/packages/design-system/lib/components/HotelCard/index.tsx index dcf12378d..cff7e5ebe 100644 --- a/packages/design-system/lib/components/HotelCard/index.tsx +++ b/packages/design-system/lib/components/HotelCard/index.tsx @@ -364,9 +364,8 @@ export const HotelCardComponent = memo( ) : null} {isDisabled diff --git a/packages/design-system/lib/components/HotelInfoCard/HotelInfoCard.stories.tsx b/packages/design-system/lib/components/HotelInfoCard/HotelInfoCard.stories.tsx index d4b24ea5c..50de51e9e 100644 --- a/packages/design-system/lib/components/HotelInfoCard/HotelInfoCard.stories.tsx +++ b/packages/design-system/lib/components/HotelInfoCard/HotelInfoCard.stories.tsx @@ -69,11 +69,7 @@ export const Default: Story = { mapping: { none: null, button: ( - ), diff --git a/packages/design-system/lib/components/IconButton/IconButton.stories.tsx b/packages/design-system/lib/components/IconButton/IconButton.stories.tsx index 743eb16df..cf40317d9 100644 --- a/packages/design-system/lib/components/IconButton/IconButton.stories.tsx +++ b/packages/design-system/lib/components/IconButton/IconButton.stories.tsx @@ -2,8 +2,8 @@ import type { Meta, StoryObj } from '@storybook/nextjs-vite' import { expect, fn } from 'storybook/test' -import { MaterialIcon, MaterialIconProps } from '../Icons/MaterialIcon' import { IconButton } from './IconButton' +import { iconButtonIconNames, IconButtonProps } from './types' import { config } from './variants' const meta: Meta = { @@ -12,13 +12,10 @@ const meta: Meta = { argTypes: { onPress: { table: { - disable: true, - }, - }, - children: { - table: { - disable: true, + type: { summary: 'function' }, + defaultValue: { summary: 'undefined' }, }, + description: 'Callback function to handle button press events.', }, variant: { control: 'select', @@ -58,43 +55,25 @@ const meta: Meta = { }, }, }, + iconName: { + control: 'select', + options: iconButtonIconNames, + table: { + type: { summary: iconButtonIconNames.join(' | ') }, + defaultValue: { summary: 'undefined' }, + }, + description: 'Name of the Material Icon to use as icon.', + }, + isDisabled: { + control: 'boolean', + table: { + type: { summary: 'boolean' }, + defaultValue: { summary: 'false' }, + }, + }, }, } -const buttonAndIconSizesMap = Object.keys(config.variants.size).map<{ - size: keyof typeof config.variants.size - iconSize: number -}>((key) => { - const typedKey = key as keyof typeof config.variants.size - switch (typedKey) { - case 'sm': - return { - size: typedKey, - iconSize: 16, - } - case 'md': - return { - size: typedKey, - iconSize: 20, - } - case 'lg': - return { - size: typedKey, - iconSize: 24, - } - case 'xl': - return { - size: typedKey, - iconSize: 28, - } - default: - return { - size: typedKey, - iconSize: 24, - } - } -}) - const globalStoryPropsInverted = { backgrounds: { value: 'scandicPrimaryDark' }, } @@ -104,11 +83,11 @@ type Story = StoryObj function renderAllSizesFn( args: Story['args'], - iconName: MaterialIconProps['icon'] = 'search' + iconName: IconButtonProps['iconName'] = 'search' ) { return (

- {buttonAndIconSizesMap.map(({ size, iconSize }) => ( + {Object.keys(config.variants.size).map((size) => (
- - - + {size}
))} @@ -135,7 +113,7 @@ function renderAllSizesFn( export const Default: Story = { args: { onPress: fn(), - children: , + iconName: 'search', }, play: async ({ canvas, userEvent, args }) => { await userEvent.click(canvas.getByRole('button')) @@ -283,6 +261,7 @@ export const Examples: Story = { ) }, } + export const Filled: Story = { args: { ...Default.args, @@ -319,9 +298,7 @@ export const FilledOnDarkBackground: Story = { export const FilledWithEmphasis: Story = { args: { ...Filled.args, - children: ( - - ), + iconName: 'arrow_forward', emphasis: true, }, play: async ({ canvas, userEvent, args }) => { @@ -344,9 +321,7 @@ export const FilledWithEmphasisDisabled: Story = { export const Outlined: Story = { args: { ...Default.args, - children: ( - - ), + iconName: 'arrow_forward', variant: 'Outlined', }, play: async ({ canvas, userEvent, args }) => { @@ -369,9 +344,7 @@ export const OutlinedDisabled: Story = { export const Elevated: Story = { args: { ...Default.args, - children: ( - - ), + iconName: 'arrow_forward', variant: 'Elevated', }, play: async ({ canvas, userEvent, args }) => { @@ -395,9 +368,7 @@ export const Faded: Story = { globals: globalStoryPropsInverted, args: { ...Default.args, - children: ( - - ), + iconName: 'arrow_forward', variant: 'Faded', }, play: async ({ canvas, userEvent, args }) => { @@ -422,9 +393,7 @@ export const Muted: Story = { globals: globalStoryPropsInverted, args: { ...Default.args, - children: ( - - ), + iconName: 'arrow_forward', variant: 'Muted', }, play: async ({ canvas, userEvent, args }) => { diff --git a/packages/design-system/lib/components/IconButton/IconButton.tsx b/packages/design-system/lib/components/IconButton/IconButton.tsx index 71156aada..e1edb2b2f 100644 --- a/packages/design-system/lib/components/IconButton/IconButton.tsx +++ b/packages/design-system/lib/components/IconButton/IconButton.tsx @@ -1,16 +1,14 @@ import { Button as ButtonRAC } from 'react-aria-components' -import { VariantProps } from 'class-variance-authority' -import { ComponentProps } from 'react' +import { MaterialIcon } from '../Icons/MaterialIcon' +import { IconButtonProps } from './types' import { variants } from './variants' -interface IconButtonProps - extends ComponentProps, VariantProps {} - export function IconButton({ variant, emphasis, size, + iconName, className, ...props }: IconButtonProps) { @@ -21,5 +19,27 @@ export function IconButton({ className, }) - return + return ( + + + + ) +} + +function getIconSize(size: IconButtonProps['size']) { + switch (size) { + case 'sm': + return 16 + case 'md': + return 20 + case 'xl': + return 28 + case 'lg': + default: + return 24 + } } diff --git a/packages/design-system/lib/components/IconButton/iconButton.module.css b/packages/design-system/lib/components/IconButton/iconButton.module.css index 64f97c1b3..30f31872f 100644 --- a/packages/design-system/lib/components/IconButton/iconButton.module.css +++ b/packages/design-system/lib/components/IconButton/iconButton.module.css @@ -73,7 +73,7 @@ &.emphasis { background-color: var(--Component-Button-Brand-Tertiary-Fill-Default); - color: var(--Component-Button-Brand-Tertiary-On-fill-Default); + color: inherit; &[data-disabled] { background-color: var(--Component-Button-Brand-Tertiary-Fill-Disabled); @@ -231,7 +231,7 @@ } &.emphasis { - color: var(--Component-Button-Muted-On-fill-Default); + color: inherit; &[data-disabled] { background-color: var(--Component-Button-Muted-Fill-Disabled-inverted); diff --git a/packages/design-system/lib/components/IconButton/types.ts b/packages/design-system/lib/components/IconButton/types.ts new file mode 100644 index 000000000..bdc2f60c9 --- /dev/null +++ b/packages/design-system/lib/components/IconButton/types.ts @@ -0,0 +1,39 @@ +import { Button as ButtonRAC } from 'react-aria-components' + +import type { VariantProps } from 'class-variance-authority' +import type { ComponentProps } from 'react' + +import type { SymbolCodepoints } from '../Icons/MaterialIcon/MaterialSymbol/types' +import type { variants } from './variants' + +export const iconButtonIconNames = [ + 'arrow_forward', + 'arrow_back', + 'remove', + 'close', + 'add', + 'search', + 'info_circle', + 'help_circle', + 'info', + 'delete', + 'visibility', + 'visibility_off', + 'keyboard_arrow_down', + 'keyboard_arrow_up', + 'cancel', + 'chevron_left', + 'chevron_right', +] as const + +export type IconButtonIconName = Extract< + SymbolCodepoints, + (typeof iconButtonIconNames)[number] +> + +export interface IconButtonProps + extends + Omit, 'children'>, + VariantProps { + iconName: IconButtonIconName +} diff --git a/packages/design-system/lib/components/InfoCard/InfoCard.tsx b/packages/design-system/lib/components/InfoCard/InfoCard.tsx index b5474cea1..37fc1c07d 100644 --- a/packages/design-system/lib/components/InfoCard/InfoCard.tsx +++ b/packages/design-system/lib/components/InfoCard/InfoCard.tsx @@ -71,9 +71,8 @@ export function InfoCard({
{primaryButton ? ( = { defaultValue: { summary: 'false' }, }, }, + // eslint-disable-next-line @typescript-eslint/no-explicit-any } as any, } @@ -147,6 +148,7 @@ export const Default: Story = { leftIconName: 'person', rightIconName: 'lock', showWarning: false, + // eslint-disable-next-line @typescript-eslint/no-explicit-any } as any, render: (args) => { // Extract custom Storybook args diff --git a/packages/design-system/lib/components/Input/Input.tsx b/packages/design-system/lib/components/Input/Input.tsx index 328d575e4..0af149e30 100644 --- a/packages/design-system/lib/components/Input/Input.tsx +++ b/packages/design-system/lib/components/Input/Input.tsx @@ -13,7 +13,6 @@ import { InputLabel } from '../InputLabel' import styles from './input.module.css' import { IconButton } from '../IconButton' -import { MaterialIcon } from '../Icons/MaterialIcon' import { Typography } from '../Typography' import type { InputProps } from './types' import { clearInput, useInputHasValue } from './utils' @@ -113,9 +112,8 @@ const InputComponent = forwardRef(function AriaInputWithLabelComponent( onPress={onClearContent} // eslint-disable-next-line formatjs/no-literal-string-in-jsx aria-label="Clear content" - > - - + iconName="cancel" + />
)} {rightIcon && !(showClearContentIcon && hasValue) && ( @@ -162,9 +160,8 @@ const InputComponent = forwardRef(function AriaInputWithLabelComponent( onPress={onClearContent} // eslint-disable-next-line formatjs/no-literal-string-in-jsx aria-label="Clear content" - > - - + iconName="cancel" + />
)} {rightIcon && !(showClearContentIcon && hasValue) && ( diff --git a/packages/design-system/lib/components/InputLabel/InputLabel.tsx b/packages/design-system/lib/components/InputLabel/InputLabel.tsx index 33eaa8041..ed9f4b3b4 100644 --- a/packages/design-system/lib/components/InputLabel/InputLabel.tsx +++ b/packages/design-system/lib/components/InputLabel/InputLabel.tsx @@ -22,6 +22,7 @@ export function InputLabel({ return ( {children} + {/* eslint-disable-next-line formatjs/no-literal-string-in-jsx */} {required && } ) diff --git a/packages/design-system/lib/components/Lightbox/FullView/index.tsx b/packages/design-system/lib/components/Lightbox/FullView/index.tsx index d98c053ff..310f66af2 100644 --- a/packages/design-system/lib/components/Lightbox/FullView/index.tsx +++ b/packages/design-system/lib/components/Lightbox/FullView/index.tsx @@ -7,7 +7,6 @@ import { useIntl } from 'react-intl' import Image from '../../Image' import { IconButton } from '../../IconButton' -import { MaterialIcon } from '../../Icons/MaterialIcon' import { Typography } from '../../Typography' import { LightboxImage } from '../index' @@ -94,9 +93,8 @@ export default function FullView({ id: 'common.close', defaultMessage: 'Close', })} - > - - + iconName="close" + />
@@ -141,16 +139,14 @@ export default function FullView({ variant="Muted" className={`${styles.navigationButton} ${styles.prev}`} onPress={handlePrev} - > - - + iconName="arrow_back" + /> - - + iconName="arrow_forward" + />
) } diff --git a/packages/design-system/lib/components/Lightbox/Gallery/index.tsx b/packages/design-system/lib/components/Lightbox/Gallery/index.tsx index 2d3049088..d065c6dea 100644 --- a/packages/design-system/lib/components/Lightbox/Gallery/index.tsx +++ b/packages/design-system/lib/components/Lightbox/Gallery/index.tsx @@ -5,12 +5,12 @@ import { Button as ButtonRAC } from 'react-aria-components' import { useIntl } from 'react-intl' import { IconButton } from '../../IconButton' -import { MaterialIcon } from '../../Icons/MaterialIcon' import { Typography } from '../../Typography' import Image from '../../Image' import { cx } from 'class-variance-authority' +import { useMediaQuery } from 'usehooks-ts' import { LightboxImage } from '..' import styles from './gallery.module.css' @@ -35,6 +35,7 @@ export default function Gallery({ const [animateLeft, setAnimateLeft] = useState(true) const mainImage = selectedImage || images[0] const mainImageIndex = images.findIndex((img) => img === mainImage) + const isMobile = useMediaQuery('(max-width: 767px)') function getThumbImages() { const thumbs = [] @@ -96,20 +97,8 @@ export default function Gallery({ id: 'common.close', defaultMessage: 'Close', })} - > - - - + iconName={isMobile ? 'chevron_left' : 'close'} + /> {/* Desktop Gallery */}
@@ -156,9 +145,8 @@ export default function Gallery({ id: 'lightbox.previousImage', defaultMessage: 'Previous image', })} - > - - + iconName="arrow_back" + /> - - + iconName="arrow_forward" + />
diff --git a/packages/design-system/lib/components/Loading/loading.module.css b/packages/design-system/lib/components/Loading/loading.module.css index 0cc388538..ee7152ec3 100644 --- a/packages/design-system/lib/components/Loading/loading.module.css +++ b/packages/design-system/lib/components/Loading/loading.module.css @@ -45,6 +45,10 @@ &.white circle { fill: var(--Icon-Inverted); } + + &.currentColor circle { + fill: currentColor; + } } @keyframes pulse { diff --git a/packages/design-system/lib/components/Loading/variants.ts b/packages/design-system/lib/components/Loading/variants.ts index 5bf33ea3e..13bc0f9ea 100644 --- a/packages/design-system/lib/components/Loading/variants.ts +++ b/packages/design-system/lib/components/Loading/variants.ts @@ -7,6 +7,7 @@ export const config = { type: { Dark: styles.dark, White: styles.white, + CurrentColor: styles.currentColor, }, }, defaultVariants: { diff --git a/packages/design-system/lib/components/Map/InteractiveMap/index.tsx b/packages/design-system/lib/components/Map/InteractiveMap/index.tsx index 94e9cbde0..ff1df5598 100644 --- a/packages/design-system/lib/components/Map/InteractiveMap/index.tsx +++ b/packages/design-system/lib/components/Map/InteractiveMap/index.tsx @@ -5,7 +5,6 @@ import { useEffect, useState } from 'react' import { useIntl } from 'react-intl' import { IconButton } from '../../IconButton' -import { MaterialIcon } from '../../Icons/MaterialIcon' import { HOTEL_PAGE, MAP_RESTRICTIONS } from '../mapConstants' @@ -150,9 +149,8 @@ export function InteractiveMap({ defaultMessage: 'Zoom out', })} isDisabled={isMinZoom} - > - - + iconName="remove" + /> - - + iconName="add" + />
diff --git a/packages/design-system/lib/components/Modal/index.tsx b/packages/design-system/lib/components/Modal/index.tsx index 75070d772..3c9387598 100644 --- a/packages/design-system/lib/components/Modal/index.tsx +++ b/packages/design-system/lib/components/Modal/index.tsx @@ -11,7 +11,6 @@ import { } from 'react-aria-components' import { useIntl } from 'react-intl' -import { MaterialIcon } from '../Icons/MaterialIcon' import { type AnimationState, @@ -126,13 +125,8 @@ function InnerModal({ })} variant="Muted" emphasis - > - - + iconName="close" + /> )} diff --git a/packages/design-system/lib/components/ParkingInformation/index.tsx b/packages/design-system/lib/components/ParkingInformation/index.tsx index 8679b9b30..4e6456aae 100644 --- a/packages/design-system/lib/components/ParkingInformation/index.tsx +++ b/packages/design-system/lib/components/ParkingInformation/index.tsx @@ -86,12 +86,7 @@ export default function ParkingInformation({ {parking.externalParkingUrl && showExternalParkingButton && ( - + {intl.formatMessage({ id: 'parkingInformation.bookParking', defaultMessage: 'Book parking', diff --git a/packages/design-system/lib/components/RateCard/Campaign/index.tsx b/packages/design-system/lib/components/RateCard/Campaign/index.tsx index 0d8be2768..c7d1bde35 100644 --- a/packages/design-system/lib/components/RateCard/Campaign/index.tsx +++ b/packages/design-system/lib/components/RateCard/Campaign/index.tsx @@ -87,9 +87,8 @@ export default function CampaignRateCard({ id: 'selectRate.rateCard.openReservationPolicy', defaultMessage: 'Open reservation policy', })} - > - - + iconName="info" + /> } > {rateTermDetails.map((termGroup) => ( diff --git a/packages/design-system/lib/components/RateCard/Code/index.tsx b/packages/design-system/lib/components/RateCard/Code/index.tsx index 7d1fdec7e..233dad1ce 100644 --- a/packages/design-system/lib/components/RateCard/Code/index.tsx +++ b/packages/design-system/lib/components/RateCard/Code/index.tsx @@ -77,9 +77,8 @@ export default function CodeRateCard({ id: 'selectRate.rateCard.openReservationPolicy', defaultMessage: 'Open reservation policy', })} - > - - + iconName="info" + /> } > {rateTermDetails.map((termGroup) => ( diff --git a/packages/design-system/lib/components/RateCard/Modal/index.tsx b/packages/design-system/lib/components/RateCard/Modal/index.tsx index 97a31bb5d..11c7c1cd4 100644 --- a/packages/design-system/lib/components/RateCard/Modal/index.tsx +++ b/packages/design-system/lib/components/RateCard/Modal/index.tsx @@ -19,7 +19,6 @@ import { fade, slideInOut } from './motionVariants' import { useIntl } from 'react-intl' import { IconButton } from '../../IconButton' -import { MaterialIcon } from '../../Icons/MaterialIcon' import { Typography } from '../../Typography' import styles from './modal.module.css' @@ -98,9 +97,8 @@ function InnerModal({ id: 'common.close', defaultMessage: 'Close', })} - > - - + iconName="close" + /> )} diff --git a/packages/design-system/lib/components/RateCard/NoRateAvailable/index.tsx b/packages/design-system/lib/components/RateCard/NoRateAvailable/index.tsx index 8eea43247..e7ff27beb 100644 --- a/packages/design-system/lib/components/RateCard/NoRateAvailable/index.tsx +++ b/packages/design-system/lib/components/RateCard/NoRateAvailable/index.tsx @@ -1,5 +1,4 @@ import { IconButton } from '../../IconButton' -import { MaterialIcon } from '../../Icons/MaterialIcon' import { Typography } from '../../Typography' import styles from '../rate-card.module.css' import { variants } from '../variants' @@ -34,9 +33,7 @@ export default function NoRateAvailableCard({

- - - + {/* eslint-disable-next-line formatjs/no-literal-string-in-jsx */} {`${rateTitle} / ${paymentTerm}`}

diff --git a/packages/design-system/lib/components/RateCard/Points/index.tsx b/packages/design-system/lib/components/RateCard/Points/index.tsx index 7bf36d582..43289cb2d 100644 --- a/packages/design-system/lib/components/RateCard/Points/index.tsx +++ b/packages/design-system/lib/components/RateCard/Points/index.tsx @@ -63,9 +63,8 @@ export default function PointsRateCard({ id: 'selectRate.rateCard.openReservationPolicy', defaultMessage: 'Open reservation policy', })} - > - - + iconName="info" + /> } > {rateTermDetails.map((termGroup) => ( diff --git a/packages/design-system/lib/components/RateCard/Regular/index.tsx b/packages/design-system/lib/components/RateCard/Regular/index.tsx index 7a7bd69d2..9c186ce2c 100644 --- a/packages/design-system/lib/components/RateCard/Regular/index.tsx +++ b/packages/design-system/lib/components/RateCard/Regular/index.tsx @@ -72,9 +72,8 @@ export default function RegularRateCard({ id: 'selectRate.rateCard.openReservationPolicy', defaultMessage: 'Open reservation policy', })} - > - - + iconName="info" + /> } > {rateTermDetails.map((termGroup) => ( diff --git a/packages/design-system/lib/components/SidePeek/SelfControlled.tsx b/packages/design-system/lib/components/SidePeek/SelfControlled.tsx index 101c4f0af..9c60917a5 100644 --- a/packages/design-system/lib/components/SidePeek/SelfControlled.tsx +++ b/packages/design-system/lib/components/SidePeek/SelfControlled.tsx @@ -7,7 +7,6 @@ import { useIntl } from 'react-intl' import usePopStateHandler from '@scandic-hotels/common/hooks/usePopStateHandler' import { IconButton } from '../IconButton' -import { MaterialIcon } from '../Icons/MaterialIcon' import { Typography } from '../Typography' import SidePeekSEO from './SidePeekSEO' @@ -72,13 +71,8 @@ export default function SidePeekSelfControlled({ id: 'common.close', defaultMessage: 'Close', })} - > - - + iconName="close" + />
{children}
diff --git a/packages/design-system/lib/components/SidePeek/index.tsx b/packages/design-system/lib/components/SidePeek/index.tsx index 70fc4715e..c7ec94582 100644 --- a/packages/design-system/lib/components/SidePeek/index.tsx +++ b/packages/design-system/lib/components/SidePeek/index.tsx @@ -3,7 +3,6 @@ import { useCallback, useContext, useRef } from 'react' import { Dialog, Modal, ModalOverlay } from 'react-aria-components' import { IconButton } from '../IconButton' -import { MaterialIcon } from '../Icons/MaterialIcon' import { Typography } from '../Typography' import { SidePeekContext } from './SidePeekContext' @@ -104,12 +103,8 @@ export default function SidePeek({ emphasis aria-label={closeLabel} onPress={onClose} - > - - + iconName="close" + />
{children}
diff --git a/packages/design-system/lib/components/Stepper/index.tsx b/packages/design-system/lib/components/Stepper/index.tsx index 72972df18..1592c4b7d 100644 --- a/packages/design-system/lib/components/Stepper/index.tsx +++ b/packages/design-system/lib/components/Stepper/index.tsx @@ -1,5 +1,4 @@ import { IconButton } from '../IconButton' -import { MaterialIcon } from '../Icons/MaterialIcon' import { Tooltip } from '../Tooltip' import { Typography } from '../Typography' @@ -29,9 +28,8 @@ export default function Stepper({ onPress={handleOnDecrease} variant="Elevated" isDisabled={disableDecrease} - > - - + iconName="remove" + />

{count}

@@ -49,9 +47,8 @@ export default function Stepper({ onPress={handleOnIncrease} variant="Elevated" isDisabled={disableIncrease} - > - - + iconName="add" + />
) diff --git a/packages/design-system/lib/components/Toasts/Toast.tsx b/packages/design-system/lib/components/Toasts/Toast.tsx index 0d8fab4bb..c07f91489 100644 --- a/packages/design-system/lib/components/Toasts/Toast.tsx +++ b/packages/design-system/lib/components/Toasts/Toast.tsx @@ -46,9 +46,8 @@ export function Toast({ children, message, onClose, variant }: ToastsProps) { })} variant="Muted" emphasis - > - - + iconName="close" + /> ) : null} )