style(SW-762): update styling for headings
This commit is contained in:
@@ -51,7 +51,7 @@ async function LevelCard({ level }: LevelCardProps) {
|
|||||||
</BiroScript>
|
</BiroScript>
|
||||||
<MembershipLevelIcon level={level.level_id} color="red" />
|
<MembershipLevelIcon level={level.level_id} color="red" />
|
||||||
</header>
|
</header>
|
||||||
<Title textAlign="center" level="h5">
|
<Title textAlign="center" level="h4">
|
||||||
{pointsString}
|
{pointsString}
|
||||||
{level.required_nights ? (
|
{level.required_nights ? (
|
||||||
<span className={styles.redText}>
|
<span className={styles.redText}>
|
||||||
|
|||||||
@@ -70,7 +70,7 @@ function RewardTableHeader({ name, description }: RewardTableHeaderProps) {
|
|||||||
<details className={styles.details}>
|
<details className={styles.details}>
|
||||||
<summary className={styles.summary}>
|
<summary className={styles.summary}>
|
||||||
<hgroup className={styles.rewardHeader}>
|
<hgroup className={styles.rewardHeader}>
|
||||||
<Title as="h5" level="h2" textTransform={"regular"}>
|
<Title as="h4" level="h2" textTransform={"regular"}>
|
||||||
{name}
|
{name}
|
||||||
</Title>
|
</Title>
|
||||||
<span className={styles.chevron}>
|
<span className={styles.chevron}>
|
||||||
|
|||||||
@@ -19,7 +19,7 @@ export default function RewardCard({
|
|||||||
<details className={styles.details}>
|
<details className={styles.details}>
|
||||||
<summary className={styles.summary}>
|
<summary className={styles.summary}>
|
||||||
<hgroup className={styles.rewardCardHeader}>
|
<hgroup className={styles.rewardCardHeader}>
|
||||||
<Title as="h5" level="h2" textTransform={"regular"}>
|
<Title as="h4" level="h2" textTransform={"regular"}>
|
||||||
{title}
|
{title}
|
||||||
</Title>
|
</Title>
|
||||||
<span className={styles.chevron}>
|
<span className={styles.chevron}>
|
||||||
|
|||||||
@@ -56,7 +56,7 @@ export default async function NextLevelRewardsBlock({
|
|||||||
{ level: nextLevelRewards.level?.name }
|
{ level: nextLevelRewards.level?.name }
|
||||||
)}
|
)}
|
||||||
</Body>
|
</Body>
|
||||||
<Title level="h4" as="h5" color="pale" textAlign="center">
|
<Title level="h4" as="h4" color="pale" textAlign="center">
|
||||||
{reward.label}
|
{reward.label}
|
||||||
</Title>
|
</Title>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ export default async function EmptyPreviousStaysBlock() {
|
|||||||
const { formatMessage } = await getIntl()
|
const { formatMessage } = await getIntl()
|
||||||
return (
|
return (
|
||||||
<section className={styles.container}>
|
<section className={styles.container}>
|
||||||
<Title as="h5" level="h3" color="red" textAlign="center">
|
<Title as="h4" level="h3" color="red" textAlign="center">
|
||||||
{formatMessage({
|
{formatMessage({
|
||||||
id: "You have no previous stays.",
|
id: "You have no previous stays.",
|
||||||
})}
|
})}
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ export default async function EmptyUpcomingStaysBlock() {
|
|||||||
return (
|
return (
|
||||||
<section className={styles.container}>
|
<section className={styles.container}>
|
||||||
<div className={styles.titleContainer}>
|
<div className={styles.titleContainer}>
|
||||||
<Title as="h5" level="h3" color="red" className={styles.title}>
|
<Title as="h4" level="h3" color="red" className={styles.title}>
|
||||||
{formatMessage({ id: "You have no upcoming stays." })}
|
{formatMessage({ id: "You have no upcoming stays." })}
|
||||||
<span className={styles.burgundyTitle}>
|
<span className={styles.burgundyTitle}>
|
||||||
{formatMessage({ id: "Where should you go next?" })}
|
{formatMessage({ id: "Where should you go next?" })}
|
||||||
|
|||||||
@@ -47,7 +47,7 @@ export default function StayCard({ stay }: StayCardProps) {
|
|||||||
height={240}
|
height={240}
|
||||||
/>
|
/>
|
||||||
<footer className={styles.footer}>
|
<footer className={styles.footer}>
|
||||||
<Title as="h5" className={styles.hotel} level="h3">
|
<Title as="h4" className={styles.hotel} level="h3">
|
||||||
{hotelInformation.hotelName}
|
{hotelInformation.hotelName}
|
||||||
</Title>
|
</Title>
|
||||||
<div className={styles.date}>
|
<div className={styles.date}>
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ export default async function EmptyUpcomingStaysBlock() {
|
|||||||
return (
|
return (
|
||||||
<section className={styles.container}>
|
<section className={styles.container}>
|
||||||
<div className={styles.titleContainer}>
|
<div className={styles.titleContainer}>
|
||||||
<Title as="h5" level="h3" color="red" className={styles.title}>
|
<Title as="h4" level="h3" color="red" className={styles.title}>
|
||||||
{formatMessage({ id: "You have no upcoming stays." })}
|
{formatMessage({ id: "You have no upcoming stays." })}
|
||||||
<span className={styles.burgundyTitle}>
|
<span className={styles.burgundyTitle}>
|
||||||
{formatMessage({ id: "Where should you go next?" })}
|
{formatMessage({ id: "Where should you go next?" })}
|
||||||
|
|||||||
@@ -34,7 +34,7 @@ export default function MyPagesMobileDropdown({
|
|||||||
<nav
|
<nav
|
||||||
className={`${styles.navigationMenu} ${isMyPagesMobileMenuOpen ? styles.navigationMenuIsOpen : ""}`}
|
className={`${styles.navigationMenu} ${isMyPagesMobileMenuOpen ? styles.navigationMenuIsOpen : ""}`}
|
||||||
>
|
>
|
||||||
<Title className={styles.heading} textTransform="capitalize" level="h5">
|
<Title className={styles.heading} textTransform="capitalize" level="h4">
|
||||||
{navigation.title}
|
{navigation.title}
|
||||||
</Title>
|
</Title>
|
||||||
{navigation.menuItems.map((menuItem, idx) => (
|
{navigation.menuItems.map((menuItem, idx) => (
|
||||||
|
|||||||
@@ -198,7 +198,7 @@ export const renderOptions: RenderOptions = {
|
|||||||
) => {
|
) => {
|
||||||
const props = extractPossibleAttributes(node.attrs)
|
const props = extractPossibleAttributes(node.attrs)
|
||||||
return (
|
return (
|
||||||
<Title key={node.uid} {...props} level="h5">
|
<Title key={node.uid} {...props} level="h4">
|
||||||
{next(node.children, embeds, fullRenderOptions)}
|
{next(node.children, embeds, fullRenderOptions)}
|
||||||
</Title>
|
</Title>
|
||||||
)
|
)
|
||||||
|
|||||||
@@ -20,7 +20,7 @@ export default function SelectionCard({
|
|||||||
return (
|
return (
|
||||||
<div className={styles.card}>
|
<div className={styles.card}>
|
||||||
<div>
|
<div>
|
||||||
<Title className={styles.name} as="h5" level="h3">
|
<Title className={styles.name} as="h4" level="h3">
|
||||||
{title}
|
{title}
|
||||||
</Title>
|
</Title>
|
||||||
<div className={styles.nameInfo}>i</div>
|
<div className={styles.nameInfo}>i</div>
|
||||||
|
|||||||
@@ -221,7 +221,7 @@ export const renderOptions: RenderOptions = {
|
|||||||
) => {
|
) => {
|
||||||
const props = extractPossibleAttributes(node.attrs)
|
const props = extractPossibleAttributes(node.attrs)
|
||||||
return (
|
return (
|
||||||
<Title key={node.uid} {...props} level="h5">
|
<Title key={node.uid} {...props} level="h4">
|
||||||
{next(node.children, embeds, fullRenderOptions)}
|
{next(node.children, embeds, fullRenderOptions)}
|
||||||
</Title>
|
</Title>
|
||||||
)
|
)
|
||||||
|
|||||||
@@ -35,7 +35,7 @@ export default function LoyaltyCard({
|
|||||||
focalPoint={image.focalPoint}
|
focalPoint={image.focalPoint}
|
||||||
/>
|
/>
|
||||||
) : null}
|
) : null}
|
||||||
<Title as="h5" level="h3" textAlign="center">
|
<Title as="h4" level="h3" textAlign="center">
|
||||||
{heading}
|
{heading}
|
||||||
</Title>
|
</Title>
|
||||||
{bodyText ? <Body textAlign="center">{bodyText}</Body> : null}
|
{bodyText ? <Body textAlign="center">{bodyText}</Body> : null}
|
||||||
|
|||||||
@@ -4,7 +4,9 @@
|
|||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
}
|
}
|
||||||
|
|
||||||
.h1 {
|
/* Temporarily remove h1 styling until design tokens är updated */
|
||||||
|
|
||||||
|
/* .h1 {
|
||||||
font-family: var(--typography-Title-1-fontFamily);
|
font-family: var(--typography-Title-1-fontFamily);
|
||||||
font-size: clamp(
|
font-size: clamp(
|
||||||
var(--typography-Title-1-Mobile-fontSize),
|
var(--typography-Title-1-Mobile-fontSize),
|
||||||
@@ -14,9 +16,9 @@
|
|||||||
letter-spacing: var(--typography-Title-1-letterSpacing);
|
letter-spacing: var(--typography-Title-1-letterSpacing);
|
||||||
line-height: var(--typography-Title-1-lineHeight);
|
line-height: var(--typography-Title-1-lineHeight);
|
||||||
text-decoration: var(--typography-Title-1-textDecoration);
|
text-decoration: var(--typography-Title-1-textDecoration);
|
||||||
}
|
} */
|
||||||
|
|
||||||
.h2 {
|
.h1 {
|
||||||
font-family: var(--typography-Title-2-fontFamily);
|
font-family: var(--typography-Title-2-fontFamily);
|
||||||
font-size: clamp(
|
font-size: clamp(
|
||||||
var(--typography-Title-2-Mobile-fontSize),
|
var(--typography-Title-2-Mobile-fontSize),
|
||||||
@@ -28,7 +30,7 @@
|
|||||||
text-decoration: var(--typography-Title-2-textDecoration);
|
text-decoration: var(--typography-Title-2-textDecoration);
|
||||||
}
|
}
|
||||||
|
|
||||||
.h3 {
|
.h2 {
|
||||||
font-family: var(--typography-Title-3-fontFamily);
|
font-family: var(--typography-Title-3-fontFamily);
|
||||||
font-size: clamp(
|
font-size: clamp(
|
||||||
var(--typography-Title-3-Mobile-fontSize),
|
var(--typography-Title-3-Mobile-fontSize),
|
||||||
@@ -40,7 +42,7 @@
|
|||||||
text-decoration: var(--typography-Title-3-textDecoration);
|
text-decoration: var(--typography-Title-3-textDecoration);
|
||||||
}
|
}
|
||||||
|
|
||||||
.h4 {
|
.h3 {
|
||||||
font-family: var(--typography-Title-4-fontFamily);
|
font-family: var(--typography-Title-4-fontFamily);
|
||||||
font-size: clamp(
|
font-size: clamp(
|
||||||
var(--typography-Title-4-Mobile-fontSize),
|
var(--typography-Title-4-Mobile-fontSize),
|
||||||
@@ -52,7 +54,7 @@
|
|||||||
text-decoration: var(--typography-Title-4-textDecoration);
|
text-decoration: var(--typography-Title-4-textDecoration);
|
||||||
}
|
}
|
||||||
|
|
||||||
.h5 {
|
.h4 {
|
||||||
font-family: var(--typography-Title-5-fontFamily);
|
font-family: var(--typography-Title-5-fontFamily);
|
||||||
font-size: clamp(
|
font-size: clamp(
|
||||||
var(--typography-Title-5-Mobile-fontSize),
|
var(--typography-Title-5-Mobile-fontSize),
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ import { headingVariants } from "./variants"
|
|||||||
|
|
||||||
import type { VariantProps } from "class-variance-authority"
|
import type { VariantProps } from "class-variance-authority"
|
||||||
|
|
||||||
type HeadingLevel = "h1" | "h2" | "h3" | "h4" | "h5"
|
type HeadingLevel = "h1" | "h2" | "h3" | "h4"
|
||||||
|
|
||||||
export interface HeadingProps
|
export interface HeadingProps
|
||||||
extends Omit<React.HTMLAttributes<HTMLHeadingElement>, "color">,
|
extends Omit<React.HTMLAttributes<HTMLHeadingElement>, "color">,
|
||||||
|
|||||||
@@ -26,7 +26,6 @@ const config = {
|
|||||||
h2: styles.h2,
|
h2: styles.h2,
|
||||||
h3: styles.h3,
|
h3: styles.h3,
|
||||||
h4: styles.h4,
|
h4: styles.h4,
|
||||||
h5: styles.h5,
|
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
defaultVariants: {
|
defaultVariants: {
|
||||||
|
|||||||
Reference in New Issue
Block a user