SEO-friendly id-based URLs, sitemap/robots, and homepage category banners

- Replace legacy DB-slug URLs with /products/{id}/{fa-slug},
  /products/category/{id}/{fa-slug}, and /blog/{id}/{fa-slug}, backed by
  the new by-id API endpoints and a Persian slugify helper
- Add /sitemap.xml (index) + /sitemap-main.xml + /sitemap-products.xml
  and /robots.txt pointing to it
- Register the three-banner-row slot in the static-image-slots catalog
- Replace the homepage category carousel with a 3-column linkable
  ThreeBanners section wired to that slot
- Remove the now-superseded root prompt files (moved into Ai data/)
This commit is contained in:
amirhosein.ashourloo
2026-08-24 08:43:53 +03:30
parent 08a729b3fc
commit 9965e567b8
24 changed files with 334 additions and 153 deletions
+5 -4
View File
@@ -15,6 +15,7 @@ import {
} from "./icons";
import { headerNavLinks } from "@/data/site";
import { CUSTOMER_PORTAL_URL } from "@/lib/config";
import { categoryHref } from "@/lib/slug";
import type { CategoryNode } from "@/lib/types";
const socialLinks = [
@@ -91,7 +92,7 @@ export default function Header({ categoryColumns }: { categoryColumns: CategoryN
{categoryColumns.map((col) => (
<div key={col.id} className="min-w-[180px]">
<Link
href={`/products?category=${col.slug}`}
href={categoryHref(col)}
className="block font-bold text-ink text-sm mb-2.5 hover:text-brand transition-colors"
>
{col.nameFa}
@@ -100,7 +101,7 @@ export default function Header({ categoryColumns }: { categoryColumns: CategoryN
{col.children.map((sub) => (
<li key={sub.id}>
<Link
href={`/products?category=${sub.slug}`}
href={categoryHref(sub)}
className="text-[13px] text-body hover:text-gold-dark transition-colors"
>
{sub.nameFa}
@@ -182,7 +183,7 @@ export default function Header({ categoryColumns }: { categoryColumns: CategoryN
{categoryColumns.map((col) => (
<div key={col.id}>
<Link
href={`/products?category=${col.slug}`}
href={categoryHref(col)}
className="block text-sm font-bold text-ink"
onClick={() => setMobileOpen(false)}
>
@@ -192,7 +193,7 @@ export default function Header({ categoryColumns }: { categoryColumns: CategoryN
{col.children.map((sub) => (
<li key={sub.id}>
<Link
href={`/products?category=${sub.slug}`}
href={categoryHref(sub)}
className="text-sm text-body"
onClick={() => setMobileOpen(false)}
>