Improve coming soon page
This commit is contained in:
@@ -1,13 +1,15 @@
|
|||||||
import type { Metadata } from "next";
|
import type { Metadata } from "next";
|
||||||
import { unstable_noStore as noStore } from "next/cache";
|
import { unstable_noStore as noStore } from "next/cache";
|
||||||
import { Sparkles } from "lucide-react";
|
import Link from "next/link";
|
||||||
|
import { ArrowLeft, ArrowRight, Mail, Sparkles } from "lucide-react";
|
||||||
import { getLocale, getTranslations } from "next-intl/server";
|
import { getLocale, getTranslations } from "next-intl/server";
|
||||||
|
|
||||||
import { FloatingPreferences } from "@/components/layout/floating-preferences";
|
import { FloatingPreferences } from "@/components/layout/floating-preferences";
|
||||||
import { HeroContentMotion, HeroMotionItem, HeroShell, HeroTitle } from "@/components/layout/site-hero";
|
import { HeroContentMotion, HeroMotionItem, HeroShell, HeroTitle } from "@/components/layout/site-hero";
|
||||||
|
import { Button } from "@/components/ui/button";
|
||||||
import { getSiteSettings } from "@/lib/app-config";
|
import { getSiteSettings } from "@/lib/app-config";
|
||||||
import { buildLocalizedMetadata } from "@/lib/metadata";
|
import { buildLocalizedMetadata } from "@/lib/metadata";
|
||||||
import { resolveLocale } from "@/lib/locale";
|
import { getLocalizedPath, resolveLocale } from "@/lib/locale";
|
||||||
|
|
||||||
type ComingSoonPageProps = {
|
type ComingSoonPageProps = {
|
||||||
params: Promise<{
|
params: Promise<{
|
||||||
@@ -43,6 +45,7 @@ export default async function ComingSoonPage({
|
|||||||
const localeKey = resolveLocale(await getLocale().catch(() => siteSettings.defaultLocale), siteSettings.defaultLocale);
|
const localeKey = resolveLocale(await getLocale().catch(() => siteSettings.defaultLocale), siteSettings.defaultLocale);
|
||||||
const t = await getTranslations({ locale: localeKey, namespace: "comingSoon" });
|
const t = await getTranslations({ locale: localeKey, namespace: "comingSoon" });
|
||||||
const isArabic = localeKey === "ar";
|
const isArabic = localeKey === "ar";
|
||||||
|
const DirectionIcon = isArabic ? ArrowLeft : ArrowRight;
|
||||||
const lines = [
|
const lines = [
|
||||||
{
|
{
|
||||||
text: t("titleLineOne"),
|
text: t("titleLineOne"),
|
||||||
@@ -75,7 +78,7 @@ export default async function ComingSoonPage({
|
|||||||
</p>
|
</p>
|
||||||
</HeroMotionItem>
|
</HeroMotionItem>
|
||||||
|
|
||||||
<HeroTitle locale={localeKey} lines={lines} className="mx-auto mt-8" />
|
<HeroTitle locale={localeKey} lines={lines} className="mx-auto mt-8 tracking-normal" />
|
||||||
|
|
||||||
<HeroMotionItem>
|
<HeroMotionItem>
|
||||||
<p className="mx-auto mt-8 max-w-[34rem] text-sm leading-7 text-foreground/68 sm:text-base">
|
<p className="mx-auto mt-8 max-w-[34rem] text-sm leading-7 text-foreground/68 sm:text-base">
|
||||||
@@ -83,10 +86,19 @@ export default async function ComingSoonPage({
|
|||||||
</p>
|
</p>
|
||||||
</HeroMotionItem>
|
</HeroMotionItem>
|
||||||
|
|
||||||
<HeroMotionItem>
|
<HeroMotionItem className="mt-8 flex flex-col items-center justify-center gap-3 sm:flex-row">
|
||||||
<p className="mx-auto mt-4 max-w-[32rem] text-sm leading-6 text-foreground/54 sm:text-base">
|
<Button asChild size="lg" className="w-full sm:w-auto">
|
||||||
{t("note")}
|
<Link href={getLocalizedPath(localeKey, "/contact", siteSettings.defaultLocale)}>
|
||||||
</p>
|
<Mail className="h-4 w-4" />
|
||||||
|
{t("primaryCta")}
|
||||||
|
</Link>
|
||||||
|
</Button>
|
||||||
|
<Button asChild variant="outline" size="lg" className="w-full sm:w-auto">
|
||||||
|
<Link href={getLocalizedPath(localeKey, "/", siteSettings.defaultLocale)}>
|
||||||
|
{t("secondaryCta")}
|
||||||
|
<DirectionIcon className="h-4 w-4" />
|
||||||
|
</Link>
|
||||||
|
</Button>
|
||||||
</HeroMotionItem>
|
</HeroMotionItem>
|
||||||
</div>
|
</div>
|
||||||
</HeroContentMotion>
|
</HeroContentMotion>
|
||||||
|
|||||||
+7
-8
@@ -29,14 +29,13 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"comingSoon": {
|
"comingSoon": {
|
||||||
"badge": "قريباً",
|
"badge": "تحديث مهني",
|
||||||
"kicker": "شيء جديد عم يتشكّل",
|
"kicker": "الموقع قيد إعادة البناء",
|
||||||
"titleLineOne": "نسخة",
|
"titleLineOne": "الموقع",
|
||||||
"titleLineTwo": "أقوى",
|
"titleLineTwo": "قيد التطوير",
|
||||||
"titleLineThree": "بالطريق.",
|
"titleLineThree": "وسيعود قريباً",
|
||||||
"description": "عم بشتغل على نسخة جديدة — هوية أقوى، شغل أوضح، وتجربة مبنية من الأساس.",
|
"description": "أعيد بناء الموقع ليعرض الخدمات، الأعمال المختارة، وطريقة التعاون بشكل مباشر ومنظم.",
|
||||||
"note": "",
|
"primaryCta": "ابدأ مشروعاً",
|
||||||
"primaryCta": "تواصل معي",
|
|
||||||
"secondaryCta": "العودة للرئيسية"
|
"secondaryCta": "العودة للرئيسية"
|
||||||
},
|
},
|
||||||
"homepage": {
|
"homepage": {
|
||||||
|
|||||||
+7
-8
@@ -29,14 +29,13 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"comingSoon": {
|
"comingSoon": {
|
||||||
"badge": "Demnächst",
|
"badge": "Professionelles Update",
|
||||||
"kicker": "Etwas Neues nimmt Form an",
|
"kicker": "Die Website wird neu aufgebaut",
|
||||||
"titleLineOne": "Eine stärkere",
|
"titleLineOne": "Website",
|
||||||
"titleLineTwo": "Version",
|
"titleLineTwo": "in Bearbeitung",
|
||||||
"titleLineThree": "kommt.",
|
"titleLineThree": "bald wieder online",
|
||||||
"description": "Die nächste Iteration dieser Seite entsteht mit Bedacht — schärfere Arbeiten, eine klarere Identität und ein Auftritt, der wirklich zeigt, was ich tue.",
|
"description": "Ich baue die Website neu auf, damit Leistungen, ausgewählte Arbeiten und Zusammenarbeit klarer, direkter und ohne Wiederholungen sichtbar werden.",
|
||||||
"note": "",
|
"primaryCta": "Projekt starten",
|
||||||
"primaryCta": "Schreib mir",
|
|
||||||
"secondaryCta": "Zur Startseite"
|
"secondaryCta": "Zur Startseite"
|
||||||
},
|
},
|
||||||
"homepage": {
|
"homepage": {
|
||||||
|
|||||||
+7
-8
@@ -29,14 +29,13 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"comingSoon": {
|
"comingSoon": {
|
||||||
"badge": "Coming Soon",
|
"badge": "Professional update",
|
||||||
"kicker": "Something new is taking shape",
|
"kicker": "The site is being rebuilt",
|
||||||
"titleLineOne": "A stronger",
|
"titleLineOne": "Website",
|
||||||
"titleLineTwo": "version",
|
"titleLineTwo": "under development",
|
||||||
"titleLineThree": "is coming.",
|
"titleLineThree": "returning soon",
|
||||||
"description": "The next iteration of this site is being built with intention — sharper work, a clearer identity, and an experience that actually reflects what I do.",
|
"description": "I am rebuilding the site to present services, selected work, and collaboration details with sharper structure and less noise.",
|
||||||
"note": "",
|
"primaryCta": "Start a project",
|
||||||
"primaryCta": "Get in touch",
|
|
||||||
"secondaryCta": "Back to homepage"
|
"secondaryCta": "Back to homepage"
|
||||||
},
|
},
|
||||||
"homepage": {
|
"homepage": {
|
||||||
|
|||||||
Reference in New Issue
Block a user