Skip to content

Commit e86715d

Browse files
committed
feat(download): add Sustainer CTA to hero section with translation support (#186)
feat(download): add Sustainer CTA to hero section with translation support (#186)
1 parent 531a15a commit e86715d

File tree

8 files changed

+61
-6
lines changed

8 files changed

+61
-6
lines changed

locales/de.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,9 @@
44
"download-temurin-for": "Temurin {defaultVersion} für {userOSName} {arch} herunterladen",
55
"download-temurin-short": "Temurin {defaultVersion} herunterladen",
66
"other-downloads": "Andere Downloads",
7-
"download-temurin-button": "Temurin® herunterladen"
7+
"download-temurin-button": "Temurin® herunterladen",
8+
"sustainer-cta-description": "Millionen vertrauen auf Eclipse Temurin. Ihre Unterstützung hält es am Laufen",
9+
"sustainer-cta-button": "In Eclipse Temurin reinvestieren"
810
},
911
"NotFoundPage": {
1012
"title": "Entschuldigung, wir konnten diese Seite nicht finden",

locales/en.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,9 @@
44
"download-temurin-for": "Download Temurin {defaultVersion} for {userOSName} {arch}",
55
"download-temurin-short": "Download Temurin {defaultVersion}",
66
"other-downloads": "Other Downloads",
7-
"download-temurin-button": "Download Temurin®"
7+
"download-temurin-button": "Download Temurin®",
8+
"sustainer-cta-description": "Millions Rely on Eclipse Temurin. Your Support Keeps It Going",
9+
"sustainer-cta-button": "Reinvest in Eclipse Temurin"
810
},
911
"NotFoundPage": {
1012
"title": "Sorry, we couldn't find this page",

locales/es.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,9 @@
44
"download-temurin-for": "Descargar Temurin {defaultVersion} para {userOSName} {arch}",
55
"download-temurin-short": "Descargar Temurin {defaultVersion}",
66
"other-downloads": "Otras descargas",
7-
"download-temurin-button": "Descargar Temurin®"
7+
"download-temurin-button": "Descargar Temurin®",
8+
"sustainer-cta-description": "Millones confían en Eclipse Temurin. Su apoyo lo mantiene funcionando",
9+
"sustainer-cta-button": "Reinvertir en Eclipse Temurin"
810
},
911
"NotFoundPage": {
1012
"title": "Lo sentimos, no pudimos encontrar esta página",

locales/fr.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,9 @@
44
"download-temurin-for": "Télécharger Temurin {defaultVersion} pour {userOSName} {arch}",
55
"download-temurin-short": "Télécharger Temurin {defaultVersion}",
66
"other-downloads": "Autres téléchargements",
7-
"download-temurin-button": "Télécharger Temurin®"
7+
"download-temurin-button": "Télécharger Temurin®",
8+
"sustainer-cta-description": "Des millions font confiance à Eclipse Temurin. Votre soutien le maintient en vie",
9+
"sustainer-cta-button": "Réinvestir dans Eclipse Temurin"
810
},
911
"NotFoundPage": {
1012
"title": "Désolé, nous n'avons pas pu trouver cette page",

locales/pt-BR.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,9 @@
44
"download-temurin-for": "Baixe o Temurin {defaultVersion} para {userOSName} {arch}",
55
"download-temurin-short": "Baixar Temurin {defaultVersion}",
66
"other-downloads": "Outros Downloads",
7-
"download-temurin-button": "Baixar Temurin®"
7+
"download-temurin-button": "Baixar Temurin®",
8+
"sustainer-cta-description": "Milhões confiam no Eclipse Temurin. Seu apoio o mantém funcionando",
9+
"sustainer-cta-button": "Reinvestir no Eclipse Temurin"
810
},
911
"NotFoundPage": {
1012
"title": "Desculpe, não conseguimos encontrar esta página",

locales/zh-CN.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,9 @@
44
"download-temurin-for": "下载适用于 {userOSName} {arch} 的 Temurin {defaultVersion}",
55
"download-temurin-short": "下载 Temurin {defaultVersion}",
66
"other-downloads": "其他下载",
7-
"download-temurin-button": "下载 Temurin®"
7+
"download-temurin-button": "下载 Temurin®",
8+
"sustainer-cta-description": "数百万用户信赖 Eclipse Temurin。您的支持让它持续发展",
9+
"sustainer-cta-button": "投资 Eclipse Temurin"
810
},
911
"NotFoundPage": {
1012
"title": "很抱歉,无法找到此页面",

src/app/[locale]/download/client.tsx

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,13 @@ import { useSearchParams, redirect } from "next/navigation"
44
import { capitalize } from "@/utils/capitalize"
55
import PageHeader from "@/components/Common/PageHeader"
66
import ImageText from "@/components/ImageText"
7+
import Cta from "@/components/Cta"
78
import Support from "@/components/WorkingGroup/Support"
9+
import Link from "next/link"
10+
import { useTranslations } from "next-intl"
811

912
export default function DownloadPageClient() {
13+
const t = useTranslations("HomePage")
1014
const searchParams = useSearchParams()
1115
const link = searchParams.get("link") || "";
1216
const vendor = searchParams.get("vendor") || "Adoptium";
@@ -63,11 +67,19 @@ export default function DownloadPageClient() {
6367
to start the download.
6468
</>
6569
)}
70+
71+
<Cta
72+
title="Millions Rely on Eclipse Temurin. Your Support Keeps It Going"
73+
description={t("sustainer-cta-description")}
74+
linkText={t("sustainer-cta-button")}
75+
link="https://adoptium.net/sustainers/"
76+
/>
6677
</>
6778
)}
6879
</>
6980
}
7081
/>
82+
7183
<ImageText
7284
title="What to do now?"
7385
description="You have successfully downloaded Temurin. For more details on usage and configuration, please take a look at our Installation Guide."

src/components/Cta/index.tsx

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
import React from "react";
2+
import Link from "next/link";
3+
4+
interface CtaProps {
5+
title: string;
6+
description: string;
7+
linkText: string;
8+
link: string;
9+
}
10+
11+
const Cta: React.FC<CtaProps> = ({ title, description, linkText, link }) => {
12+
return (
13+
<section className="py-16 max-w-[1048px] w-full mx-auto flex justify-center xl:px-0 px-6">
14+
<div className="lg:max-w-[560px] w-full mx-auto text-center">
15+
<p className="md:mt-6 my-10 text-grey text-base leading-6 font-normal mb-0">
16+
{description}
17+
</p>
18+
<Link href={link} className="inline-block">
19+
<button
20+
className="bg-transparent mt-10 border-2 border-pink-500/0 text-white text-base leading-6 font-normal w-[250px] h-[48px] rounded-2xl gradient-border transition-all duration-300 hover:border-pink-500/100 hover:text-pink"
21+
type="button"
22+
>
23+
{linkText}
24+
</button>
25+
</Link>
26+
</div>
27+
</section>
28+
);
29+
};
30+
31+
export default Cta;

0 commit comments

Comments
 (0)