Merged in refactor/small-cleanup (pull request #3252)
fix: some cleanup * fix: some cleanup Approved-by: Emma Zettervall
This commit is contained in:
@@ -48,6 +48,7 @@
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: var(--Space-x2);
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.footer {
|
||||
|
||||
@@ -6,11 +6,10 @@ import {
|
||||
ModalOverlay,
|
||||
} from "react-aria-components"
|
||||
|
||||
import Body from "@scandic-hotels/design-system/Body"
|
||||
import { Button } from "@scandic-hotels/design-system/Button"
|
||||
import ButtonLink from "@scandic-hotels/design-system/ButtonLink"
|
||||
import { LoadingSpinner } from "@scandic-hotels/design-system/LoadingSpinner"
|
||||
import { OldDSButton as Button } from "@scandic-hotels/design-system/OldDSButton"
|
||||
import Link from "@scandic-hotels/design-system/OldDSLink"
|
||||
import Subtitle from "@scandic-hotels/design-system/Subtitle"
|
||||
import { Typography } from "@scandic-hotels/design-system/Typography"
|
||||
|
||||
import styles from "./dialog.module.css"
|
||||
|
||||
@@ -35,40 +34,42 @@ export default function Dialog({
|
||||
{({ close }) => (
|
||||
<section className={styles.modal}>
|
||||
<header className={styles.header}>
|
||||
<Subtitle textAlign="center">{titleText}</Subtitle>
|
||||
<Body textAlign="center">{bodyText}</Body>
|
||||
<Typography variant="Title/Subtitle/md">
|
||||
<p>{titleText}</p>
|
||||
</Typography>
|
||||
<Typography>
|
||||
<p>{bodyText}</p>
|
||||
</Typography>
|
||||
</header>
|
||||
{proceedIsPending ? (
|
||||
<LoadingSpinner />
|
||||
) : (
|
||||
<footer className={styles.footer}>
|
||||
<Button
|
||||
intent="secondary"
|
||||
variant="Secondary"
|
||||
onPress={close}
|
||||
size="medium"
|
||||
theme="base"
|
||||
size="Medium"
|
||||
color="Primary"
|
||||
>
|
||||
{cancelButtonText}
|
||||
</Button>
|
||||
{proceedHref ? (
|
||||
<Button
|
||||
asChild
|
||||
intent="primary"
|
||||
size="medium"
|
||||
theme="base"
|
||||
<ButtonLink
|
||||
variant="Primary"
|
||||
color="Primary"
|
||||
size="Medium"
|
||||
href={proceedHref}
|
||||
>
|
||||
<Link color="none" href={proceedHref}>
|
||||
{proceedText}
|
||||
</Link>
|
||||
</Button>
|
||||
{proceedText}
|
||||
</ButtonLink>
|
||||
) : (
|
||||
<Button
|
||||
intent="primary"
|
||||
variant="Primary"
|
||||
color="Primary"
|
||||
onPress={() => {
|
||||
proceedOnClick(close)
|
||||
}}
|
||||
size="medium"
|
||||
theme="base"
|
||||
size="Medium"
|
||||
>
|
||||
{proceedText}
|
||||
</Button>
|
||||
|
||||
@@ -41,7 +41,9 @@ import { trackLinkClick } from "@/utils/tracking/profilingConsent"
|
||||
|
||||
import styles from "./form.module.css"
|
||||
|
||||
import type { SignUpFormProps } from "@/types/components/form/signupForm"
|
||||
interface SignUpFormProps {
|
||||
title: string
|
||||
}
|
||||
|
||||
export default function SignupForm({ title }: SignUpFormProps) {
|
||||
const intl = useIntl()
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
import { useIntl } from "react-intl"
|
||||
|
||||
import { MaterialIcon } from "@scandic-hotels/design-system/Icons/MaterialIcon"
|
||||
import Link from "@scandic-hotels/design-system/OldDSLink"
|
||||
import { TextLink } from "@scandic-hotels/design-system/TextLink"
|
||||
import { Typography } from "@scandic-hotels/design-system/Typography"
|
||||
|
||||
import styles from "./changeNameDisclaimer.module.css"
|
||||
@@ -25,28 +25,24 @@ export default function ChangeNameDisclaimer() {
|
||||
{
|
||||
phone([str]) {
|
||||
return (
|
||||
<Typography variant="Body/Supporting text (caption)/smBold">
|
||||
<Link
|
||||
href={`tel:${str.replaceAll(" ", "")}`}
|
||||
textDecoration="underline"
|
||||
size="none"
|
||||
>
|
||||
{str}
|
||||
</Link>
|
||||
</Typography>
|
||||
<TextLink
|
||||
href={`tel:${str.replaceAll(" ", "")}`}
|
||||
typography="Body/Supporting text (caption)/smBold"
|
||||
isInline
|
||||
>
|
||||
{str}
|
||||
</TextLink>
|
||||
)
|
||||
},
|
||||
email(str) {
|
||||
return (
|
||||
<Typography variant="Body/Supporting text (caption)/smBold">
|
||||
<Link
|
||||
href={`mailto:${str}`}
|
||||
textDecoration="underline"
|
||||
size="none"
|
||||
>
|
||||
{str}
|
||||
</Link>
|
||||
</Typography>
|
||||
<TextLink
|
||||
href={`mailto:${str}`}
|
||||
typography="Body/Supporting text (caption)/smBold"
|
||||
isInline
|
||||
>
|
||||
{str}
|
||||
</TextLink>
|
||||
)
|
||||
},
|
||||
}
|
||||
|
||||
@@ -1,3 +0,0 @@
|
||||
export type SignUpFormProps = {
|
||||
title: string
|
||||
}
|
||||
Reference in New Issue
Block a user