feat(SW-187): Fixed LanguageSwitcher for footer

This commit is contained in:
Pontus Dreij
2024-09-05 14:30:33 +02:00
parent 05ee4d1717
commit 6d55ee7595
13 changed files with 136 additions and 54 deletions

View File

@@ -65,5 +65,6 @@
border-bottom: 0;
padding-bottom: 0;
margin-bottom: 0;
gap: var(--Spacing-x4);
}
}

View File

@@ -6,8 +6,6 @@ import Footnote from "@/components/TempDesignSystem/Text/Footnote"
import { getIntl } from "@/i18n"
import { getLang } from "@/i18n/serverContext"
import { footer } from "../mockedData"
import styles from "./details.module.css"
import type { FooterDetailsProps } from "@/types/components/footer/navigation"
@@ -22,11 +20,12 @@ function SocialIcon({ iconName }: SocialIconsProps) {
export default async function FooterDetails({
socialMedia,
tertiaryLinks,
languageUrls,
}: FooterDetailsProps) {
const lang = getLang()
const { formatMessage } = await getIntl()
const currentYear = new Date().getFullYear()
const { languageSwitcher } = footer
return (
<section className={styles.details}>
<div className={styles.topContainer}>
@@ -85,7 +84,9 @@ export default async function FooterDetails({
)
)}
</nav>
<LanguageSwitcher type="desktopFooter" urls={languageSwitcher.urls} />
{languageUrls && (
<LanguageSwitcher type="footer" urls={languageUrls} />
)}
</div>
</div>
</section>