From 74b07284f6c6269ca1170156f1864257815e13c5 Mon Sep 17 00:00:00 2001 From: zahravaziri Date: Mon, 2 Jun 2025 15:25:14 +0330 Subject: [PATCH] create com button --- src/app/globals.css | 1 + src/app/layout.tsx | 2 -- src/app/page.tsx | 2 +- src/components/layout/header/index.tsx | 30 ++++++++++------- src/components/layout/navbar/index.tsx | 43 ++++++++++++++---------- src/components/uikit/button/index.tsx | 45 ++++++++++---------------- src/locales/en.ts | 16 ++++++++- src/locales/fa.ts | 10 ++++++ 8 files changed, 88 insertions(+), 61 deletions(-) diff --git a/src/app/globals.css b/src/app/globals.css index a5c9464..e13e04f 100644 --- a/src/app/globals.css +++ b/src/app/globals.css @@ -58,6 +58,7 @@ font-family: 'Manrope'; } + :root { --primary: #FA003F; --secondary: #A78BFA; diff --git a/src/app/layout.tsx b/src/app/layout.tsx index a697ecd..762fe42 100644 --- a/src/app/layout.tsx +++ b/src/app/layout.tsx @@ -1,5 +1,3 @@ -'use client' -import type { Metadata } from 'next'; import './globals.css'; import { cookies } from 'next/headers'; diff --git a/src/app/page.tsx b/src/app/page.tsx index 5a4ec34..70bf7d3 100644 --- a/src/app/page.tsx +++ b/src/app/page.tsx @@ -18,7 +18,7 @@ export default async function Home() { const data = await getData(); return ( -
+
{t('pages_home_title') as string} diff --git a/src/components/layout/header/index.tsx b/src/components/layout/header/index.tsx index d681f37..5d78152 100644 --- a/src/components/layout/header/index.tsx +++ b/src/components/layout/header/index.tsx @@ -1,11 +1,12 @@ import images from '@/assets/images/images'; import Navbar from '../navbar'; import Button from '@/components/uikit/button'; +import { t } from '@/locales/translates'; export default function Header() { return (
@@ -13,28 +14,33 @@ export default function Header() {

- Excellence innovating{' '} + {t('com_home_banner_title') as string}

- industry for today{' '} + {t('com_home_banner_title_bold') as string}

-

- At the heart of our operations is a commitment to delivering - superior products through cutting-
edge technology and innovative - processes. -

- +

+

+ +
diff --git a/src/components/layout/navbar/index.tsx b/src/components/layout/navbar/index.tsx index aa06b2b..207efea 100644 --- a/src/components/layout/navbar/index.tsx +++ b/src/components/layout/navbar/index.tsx @@ -1,6 +1,7 @@ 'use client'; import images from '@/assets/images/images'; +import { t } from '@/locales/translates'; import Image from 'next/image'; import Link from 'next/link'; import { usePathname } from 'next/navigation'; @@ -11,13 +12,12 @@ export default function Navbar() { const pathname = usePathname(); const links = [ - { href: '/', label: 'Home' }, - { href: '/services', label: 'About US' }, - { href: '/blog', label: 'Products' }, - { href: '/contact', label: 'Blog' }, - { href: '/contact', label: 'Project' }, - { href: '/contact', label: 'Contact Us' }, - + { href: '/', label: t('pages_home_title') as string }, + { href: '/about', label: t('pages_about_title') as string }, + { href: '/blog', label: t('pages_contact_title') as string }, + { href: '/contact', label: t('pages_contact_title') as string }, + { href: '/product', label: t('pages_product_title') as string }, + { href: '/project', label: t('pages_project_title') as string }, ]; const linkClass = (href: string) => @@ -26,27 +26,32 @@ export default function Navbar() { return (