Skip to content

Commit 4fdff2d

Browse files
committed
match styles with legal banner
1 parent 1e64e5f commit 4fdff2d

File tree

1 file changed

+9
-14
lines changed

1 file changed

+9
-14
lines changed

src/components/TranslationBanner.tsx

Lines changed: 9 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,11 @@
11
import { useEffect, useState } from "react"
2-
import Link from "next/link"
32
import { useRouter } from "next/router"
43
import { useTranslation } from "next-i18next"
54
import { MdClose } from "react-icons/md"
65

76
import type { Lang } from "@/lib/types"
87

9-
import { Button } from "@/components/ui/buttons/Button"
8+
import { Button, ButtonLink } from "@/components/ui/buttons/Button"
109
import { Flex } from "@/components/ui/flex"
1110

1211
import { cn } from "@/lib/utils/cn"
@@ -45,17 +44,15 @@ const TranslationBanner = ({
4544
return (
4645
<aside
4746
className={cn(
48-
"fixed bottom-0 end-0 z-popover md:bottom-8 md:end-8",
47+
"fixed bottom-0 end-0 z-popover rounded bg-background-highlight md:bottom-8 md:end-8",
4948
isOpen ? "block" : "hidden"
5049
)}
5150
dir={dir}
5251
>
53-
<div className="bg-infoBanner relative max-h-full max-w-full p-4 text-neutral-900 shadow-md md:max-w-[600px] md:rounded-sm">
54-
<Flex className="m-4 mt-10 flex-col sm:mt-4">
55-
<Flex className="mb-4 flex-col-reverse items-start sm:flex-row sm:items-center">
56-
<h3 className="my-0 text-2xl font-bold leading-none">
57-
{t(headerTextId)}
58-
</h3>
52+
<div className="relative max-h-full max-w-full p-4 shadow-md md:max-w-[600px]">
53+
<Flex className="m-4 mt-10 flex-col gap-4 sm:mt-4">
54+
<Flex className="flex-col-reverse items-start sm:flex-row sm:items-center">
55+
<h3 className="leading-none md:text-2xl">{t(headerTextId)}</h3>
5956
<Emoji
6057
text=":globe_showing_asia_australia:"
6158
className="mb-4 ms-2 text-2xl sm:mb-auto"
@@ -64,11 +61,9 @@ const TranslationBanner = ({
6461
<p>{t(bodyTextId)}</p>
6562
<Flex className="flex-col items-start sm:flex-row sm:items-center">
6663
<div>
67-
<Button asChild variant="link">
68-
<Link href="/contributing/translation-program/">
69-
{t("translation-banner-button-translate-page")}
70-
</Link>
71-
</Button>
64+
<ButtonLink href="/contributing/translation-program/">
65+
{t("translation-banner-button-translate-page")}
66+
</ButtonLink>
7267
</div>
7368
{/* Todo: Reimplement once fixed */}
7469
{/* Issue: https://github.com/ethereum/ethereum-org-website/issues/12292 */}

0 commit comments

Comments
 (0)