Merged in chore/SW-3381-move-loginbutton-to-ds- (pull request #2752)

chore(SW-3381) Moved LoginButton to design system

* chore(SW-3381) Moved LoginButton to design system


Approved-by: Anton Gunnarsson
This commit is contained in:
Hrishikesh Vaipurkar
2025-09-03 09:11:28 +00:00
parent ca408bbbb5
commit 260a544c99
23 changed files with 165 additions and 118 deletions

View File

@@ -6,14 +6,16 @@ import { formatPrice } from "@scandic-hotels/common/utils/numberFormatting"
import Footnote from "@scandic-hotels/design-system/Footnote"
import Checkbox from "@scandic-hotels/design-system/Form/Checkbox"
import Link from "@scandic-hotels/design-system/Link"
import { LoginButton } from "@scandic-hotels/design-system/LoginButton"
import { OldDSButton as Button } from "@scandic-hotels/design-system/OldDSButton"
import { Typography } from "@scandic-hotels/design-system/Typography"
import { membershipTermsAndConditions } from "@/constants/webHrefs"
import LoginButton from "@/components/LoginButton"
import { useRoomContext } from "@/contexts/Details/Room"
import useLang from "@/hooks/useLang"
import { useLazyPathname } from "@/hooks/useLazyPathname"
import { trackLoginClick } from "@/utils/tracking"
import styles from "./joinScandicFriendsCard.module.css"
@@ -24,6 +26,7 @@ export default function JoinScandicFriendsCard({
}: JoinScandicFriendsCardProps) {
const lang = useLang()
const intl = useIntl()
const loginPathname = useLazyPathname()
const {
room,
actions: { updateJoin },
@@ -74,7 +77,11 @@ export default function JoinScandicFriendsCard({
<LoginButton
className={styles.login}
color="white"
position="enter details"
lang={lang}
onClick={() => {
trackLoginClick("enter details")
}}
pathName={loginPathname}
trackingId="join-scandic-friends-enter-details"
>
{intl.formatMessage({