fix: match footer to design documents with typography and colors

This commit is contained in:
Christian Andolf
2025-05-27 13:12:01 +02:00
parent 32cc0cbe88
commit ade0279c8d
7 changed files with 100 additions and 138 deletions

View File

@@ -1,10 +1,11 @@
import { Typography } from "@scandic-hotels/design-system/Typography"
import { getFooter } from "@/lib/trpc/memoizedRequests"
import Image from "@/components/Image"
import LanguageSwitcher from "@/components/LanguageSwitcher"
import SkeletonShimmer from "@/components/SkeletonShimmer"
import Link from "@/components/TempDesignSystem/Link"
import Footnote from "@/components/TempDesignSystem/Text/Footnote"
import { getIntl } from "@/i18n"
import { getLang } from "@/i18n/serverContext"
@@ -20,7 +21,7 @@ export default async function FooterDetails() {
const currentYear = new Date().getFullYear()
return (
<section className={styles.details}>
<div className={styles.details}>
<div className={styles.topContainer}>
<Link href={`/${lang}`}>
<Image
@@ -37,8 +38,8 @@ export default async function FooterDetails() {
</nav>
</div>
<div className={styles.bottomContainer}>
<div className={styles.copyrightContainer}>
<Footnote type="label" textTransform="uppercase">
<Typography variant="Tag/sm">
<p>
{intl.formatMessage(
{
defaultMessage:
@@ -46,35 +47,27 @@ export default async function FooterDetails() {
},
{ currentYear }
)}
</Footnote>
</div>
</p>
</Typography>
<div className={styles.navigationContainer}>
<nav className={styles.navigation}>
{footer?.tertiaryLinks.map(
(link) =>
link.url && (
<Footnote
asChild
type="label"
textTransform="uppercase"
key={link.title}
>
<Link
className={styles.link}
color="peach50"
href={link.url}
target="_blank"
>
{link.title}
</Link>
</Footnote>
)
)}
{footer?.tertiaryLinks.map((link) => (
<Typography key={link.title} variant="Tag/sm">
<Link
className={styles.link}
color="peach50"
href={link.url}
target="_blank"
>
{link.title}
</Link>
</Typography>
))}
</nav>
<LanguageSwitcher type="footer" />
</div>
</div>
</section>
</div>
)
}
@@ -99,8 +92,8 @@ export async function FooterDetailsSkeleton() {
</nav>
</div>
<div className={styles.bottomContainer}>
<div className={styles.copyrightContainer}>
<Footnote type="label" textTransform="uppercase">
<Typography variant="Tag/sm">
<p>
{intl.formatMessage(
{
defaultMessage:
@@ -108,8 +101,8 @@ export async function FooterDetailsSkeleton() {
},
{ currentYear }
)}
</Footnote>
</div>
</p>
</Typography>
<div className={styles.navigationContainer}>
<nav className={styles.navigation}>
<SkeletonShimmer width="40ch" height="20px" contrast="dark" />