Merged in chore/replace-deprecated-body (pull request #3300)
Replace deprecated <Body> with <Typography> * chore: replace deprecated body component * refactor: replace Body component with Typography across various components * merge Approved-by: Bianca Widstam Approved-by: Matilda Landström
This commit is contained in:
@@ -1,8 +1,8 @@
|
||||
import Body from "@scandic-hotels/design-system/Body"
|
||||
import { MaterialIcon } from "@scandic-hotels/design-system/Icons/MaterialIcon"
|
||||
import Image from "@scandic-hotels/design-system/Image"
|
||||
import Link from "@scandic-hotels/design-system/OldDSLink"
|
||||
import Title from "@scandic-hotels/design-system/Title"
|
||||
import { Typography } from "@scandic-hotels/design-system/Typography"
|
||||
|
||||
import { loyaltyCardVariants } from "./variants"
|
||||
|
||||
@@ -39,7 +39,14 @@ export default function LoyaltyCard({
|
||||
<Title as="h4" level="h3" textAlign="center">
|
||||
{heading}
|
||||
</Title>
|
||||
{bodyText ? <Body textAlign="center">{bodyText}</Body> : null}
|
||||
{!!bodyText && (
|
||||
<Typography
|
||||
variant="Body/Paragraph/mdRegular"
|
||||
className={styles.bodyText}
|
||||
>
|
||||
<p>{bodyText}</p>
|
||||
</Typography>
|
||||
)}
|
||||
<div className={styles.buttonContainer}>
|
||||
{link ? (
|
||||
<Link
|
||||
|
||||
@@ -36,3 +36,6 @@
|
||||
.icon {
|
||||
align-self: center;
|
||||
}
|
||||
.bodyText {
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user