diff --git a/src/app/about/page.tsx b/src/app/about/page.tsx index ae37ce5..b94b0c3 100644 --- a/src/app/about/page.tsx +++ b/src/app/about/page.tsx @@ -1,14 +1,18 @@ +import type { Metadata } from "next"; import Image from "next/image"; import { Footer } from "@/components/Footer"; import { Header } from "@/components/Header"; import { PageHero } from "@/components/PageShared"; import { aboutPage } from "@/data/company"; +import { pageMetadata } from "@/lib/seo"; -export const metadata = { - title: "درباره ما | رسام تجارت هواران", +export const metadata: Metadata = pageMetadata({ + title: "درباره ما", description: "درباره شرکت رسام تجارت هواران؛ طراحی، تامین و تولید تجهیزات تهویه مطبوع و سیستم‌های مدیریت دود", -}; + path: "/about", + image: aboutPage.image, +}); export default function AboutUsPage() { return ( diff --git a/src/app/articles/[slug]/page.tsx b/src/app/articles/[slug]/page.tsx index f621f1b..d7294eb 100644 --- a/src/app/articles/[slug]/page.tsx +++ b/src/app/articles/[slug]/page.tsx @@ -18,11 +18,37 @@ export async function generateMetadata({ params }: PageProps) { const { slug } = await params; const { item } = await getBlog(slug); if (!item) { - return { title: "مقاله | رسام تجارت هواران" }; + return { + title: "مقاله", + robots: { index: false, follow: true }, + }; } + + const description = item.excerpt || item.title; + const image = item.image || "/images/brand/logo.png"; + return { - title: `${item.title} | رسام تجارت هواران`, - description: item.excerpt || item.title, + title: item.title, + description, + alternates: { + canonical: `/articles/${item.slug}`, + }, + openGraph: { + type: "article", + locale: "fa_IR", + url: `/articles/${item.slug}`, + siteName: "رسام تجارت هواران", + title: item.title, + description, + images: [{ url: image, alt: item.title }], + publishedTime: item.date || undefined, + }, + twitter: { + card: "summary_large_image", + title: item.title, + description, + images: [image], + }, }; } diff --git a/src/app/articles/page.tsx b/src/app/articles/page.tsx index 607a82c..6dea410 100644 --- a/src/app/articles/page.tsx +++ b/src/app/articles/page.tsx @@ -4,11 +4,14 @@ import { PageHero } from "@/components/PageShared"; import { ArticlesGrid } from "@/components/ArticlesGrid"; import { Pagination } from "@/components/Pagination"; import { DEFAULT_LIST_PAGE_SIZE, listBlogs } from "@/lib/meshkee"; +import type { Metadata } from "next"; +import { pageMetadata } from "@/lib/seo"; -export const metadata = { - title: "مقالات | رسام تجارت هواران", +export const metadata: Metadata = pageMetadata({ + title: "مقالات", description: "مقالات و دانشنامه تخصصی شرکت رسام تجارت هواران", -}; + path: "/articles", +}); type PageProps = { searchParams: Promise<{ page?: string }>; diff --git a/src/app/catalog/page.tsx b/src/app/catalog/page.tsx index c76cd5e..e611b59 100644 --- a/src/app/catalog/page.tsx +++ b/src/app/catalog/page.tsx @@ -3,12 +3,15 @@ import { Footer } from "@/components/Footer"; import { Header } from "@/components/Header"; import { PageHero } from "@/components/PageShared"; import { catalogPage } from "@/data/company"; +import type { Metadata } from "next"; +import { pageMetadata } from "@/lib/seo"; -export const metadata = { - title: "کاتالوگ | رسام تجارت هواران", +export const metadata: Metadata = pageMetadata({ + title: "کاتالوگ", description: "دانلود کاتالوگ عمومی شرکت رسام تجارت هواران؛ محصولات و فعالیت‌ها", -}; + path: "/catalog", +}); export default function CatalogPage() { return ( diff --git a/src/app/contact/page.tsx b/src/app/contact/page.tsx index 3fda5d2..a87fa4d 100644 --- a/src/app/contact/page.tsx +++ b/src/app/contact/page.tsx @@ -1,10 +1,13 @@ import type { Metadata } from "next"; import { ContactUsView } from "@/components/ContactUsView"; +import { pageMetadata } from "@/lib/seo"; -export const metadata: Metadata = { - title: "تماس باما | هواران", - description: "تماس با رسام تجارت هواران؛ آدرس، تلفن، ایمیل و فرم پیام", -}; +export const metadata: Metadata = pageMetadata({ + title: "تماس با ما", + description: + "تماس با رسام تجارت هواران؛ آدرس دفتر و کارخانه، تلفن، ایمیل و فرم پیام", + path: "/contact", +}); export default function ContactUsPage() { return ; diff --git a/src/app/documents/page.tsx b/src/app/documents/page.tsx index 671012d..e5cf12b 100644 --- a/src/app/documents/page.tsx +++ b/src/app/documents/page.tsx @@ -3,12 +3,14 @@ import { Footer } from "@/components/Footer"; import { Header } from "@/components/Header"; import { PageHero } from "@/components/PageShared"; import { documentsCerts, documentsSatisfaction } from "@/data/documents"; +import type { Metadata } from "next"; +import { pageMetadata } from "@/lib/seo"; -export const metadata = { - title: "مدارک | رسام تجارت هواران", - description: - "گواهینامه‌ها و رضایتمندی‌های مشتریان رسام تجارت هواران", -}; +export const metadata: Metadata = pageMetadata({ + title: "مدارک", + description: "گواهینامه‌ها و رضایتمندی‌های مشتریان رسام تجارت هواران", + path: "/documents", +}); export default function DocumentsPage() { return ( diff --git a/src/app/globals.css b/src/app/globals.css index 00a5aef..74b423a 100644 --- a/src/app/globals.css +++ b/src/app/globals.css @@ -165,6 +165,86 @@ img { box-shadow: 0 0 10px rgba(0, 0, 0, 0.05); } +.meshkee-credit { + position: relative; +} + +.meshkee-credit__frame { + position: absolute; + inset: 0; + pointer-events: none; +} + +.meshkee-credit__line { + position: absolute; + background: #c8c8c8; + transition: transform 0.28s cubic-bezier(0.22, 1, 0.36, 1); +} + +/* Draw clockwise starting from the left edge */ +.meshkee-credit__line--l { + top: 0; + left: 0; + width: 1px; + height: 100%; + transform: scaleY(0); + transform-origin: top; + transition-delay: 0s; +} + +.meshkee-credit__line--b { + bottom: 0; + left: 0; + width: 100%; + height: 1px; + transform: scaleX(0); + transform-origin: left; + transition-delay: 0.14s; +} + +.meshkee-credit__line--r { + top: 0; + right: 0; + width: 1px; + height: 100%; + transform: scaleY(0); + transform-origin: bottom; + transition-delay: 0.28s; +} + +.meshkee-credit__line--t { + top: 0; + left: 0; + width: 100%; + height: 1px; + transform: scaleX(0); + transform-origin: right; + transition-delay: 0.42s; +} + +.meshkee-credit:hover .meshkee-credit__line--l, +.meshkee-credit:hover .meshkee-credit__line--r { + transform: scaleY(1); +} + +.meshkee-credit:hover .meshkee-credit__line--t, +.meshkee-credit:hover .meshkee-credit__line--b { + transform: scaleX(1); +} + +.meshkee-credit:not(:hover) .meshkee-credit__line--l { + transition-delay: 0.42s; +} +.meshkee-credit:not(:hover) .meshkee-credit__line--b { + transition-delay: 0.28s; +} +.meshkee-credit:not(:hover) .meshkee-credit__line--r { + transition-delay: 0.14s; +} +.meshkee-credit:not(:hover) .meshkee-credit__line--t { + transition-delay: 0s; +} + .round-box { border-radius: 8px; overflow: hidden; diff --git a/src/app/ims-policy/page.tsx b/src/app/ims-policy/page.tsx index 9905f89..1fbe6f4 100644 --- a/src/app/ims-policy/page.tsx +++ b/src/app/ims-policy/page.tsx @@ -2,12 +2,15 @@ import { Footer } from "@/components/Footer"; import { Header } from "@/components/Header"; import { PageHero } from "@/components/PageShared"; import { imsPolicy } from "@/data/company"; +import type { Metadata } from "next"; +import { pageMetadata } from "@/lib/seo"; -export const metadata = { - title: "خط مشی سیستم مدیریت یکپارچه | رسام تجارت هواران", +export const metadata: Metadata = pageMetadata({ + title: "خط مشی سیستم مدیریت یکپارچه", description: "خط مشی سیستم مدیریت یکپارچه (IMS) شرکت رسام تجارت هواران بر اساس استانداردهای ISO 9001، ISO 14001 و ISO 45001", -}; + path: "/ims-policy", +}); export default function ImsPolicyPage() { return ( diff --git a/src/app/layout.tsx b/src/app/layout.tsx index 929d52c..c843943 100644 --- a/src/app/layout.tsx +++ b/src/app/layout.tsx @@ -1,14 +1,84 @@ -import type { Metadata } from "next"; +import type { Metadata, Viewport } from "next"; import { LatinDigitsEnhancer } from "@/components/LatinDigits"; +import { + DEFAULT_DESCRIPTION, + DEFAULT_OG_IMAGE, + SITE_KEYWORDS, + SITE_NAME, + SITE_NAME_EN, + SITE_URL, + organizationJsonLd, + websiteJsonLd, +} from "@/lib/seo"; import "./globals.css"; export const metadata: Metadata = { - title: "صفحه اصلی | رسام تجارت هواران", - description: - "شرکت رسام تجارت هواران در حوزه طراحی و تولید تجهیزاتی نظیر چیلر، فن، هواساز، فن کویل و غیره و همچنین توان و تجربه در امور بازرگانی اعضای مجموعه خود آماده همکاری و ارائه خدمات در این زمینه است.", - icons: { - icon: "/favicon.png", + metadataBase: new URL(SITE_URL), + title: { + default: `${SITE_NAME} | طراحی و تولید تجهیزات تهویه مطبوع`, + template: `%s | ${SITE_NAME}`, }, + description: DEFAULT_DESCRIPTION, + applicationName: SITE_NAME, + authors: [{ name: SITE_NAME, url: SITE_URL }], + creator: SITE_NAME, + publisher: SITE_NAME, + keywords: SITE_KEYWORDS, + category: "business", + icons: { + icon: [ + { url: "/favicon.ico", sizes: "any" }, + { url: "/favicon.png", type: "image/png", sizes: "512x512" }, + { url: "/images/brand/logo.png", type: "image/png" }, + ], + apple: [{ url: "/favicon.png", type: "image/png", sizes: "512x512" }], + shortcut: ["/favicon.ico"], + }, + openGraph: { + type: "website", + locale: "fa_IR", + url: SITE_URL, + siteName: SITE_NAME, + title: `${SITE_NAME} | ${SITE_NAME_EN}`, + description: DEFAULT_DESCRIPTION, + images: [ + { + url: DEFAULT_OG_IMAGE, + alt: SITE_NAME, + }, + ], + }, + twitter: { + card: "summary_large_image", + title: `${SITE_NAME} | ${SITE_NAME_EN}`, + description: DEFAULT_DESCRIPTION, + images: [DEFAULT_OG_IMAGE], + }, + robots: { + index: true, + follow: true, + googleBot: { + index: true, + follow: true, + "max-image-preview": "large", + "max-snippet": -1, + "max-video-preview": -1, + }, + }, + alternates: { + canonical: "/", + }, + formatDetection: { + telephone: true, + email: true, + address: true, + }, +}; + +export const viewport: Viewport = { + width: "device-width", + initialScale: 1, + themeColor: "#002776", }; export default function RootLayout({ @@ -16,9 +86,15 @@ export default function RootLayout({ }: Readonly<{ children: React.ReactNode; }>) { + const jsonLd = [organizationJsonLd(), websiteJsonLd()]; + return ( +