Use Meshkee {id}/{fa-slug} detail URLs for products and blogs.
Resolve pages via by-id APIs, slugify Farsi titles for public paths, and redirect legacy slug-only URLs to the canonical form. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
co-authored by
Cursor
parent
24b5649abd
commit
0cb9aa57e2
@@ -3,9 +3,10 @@ import { ArrowUpLeft } from "lucide-react";
|
||||
import { Placeholder } from "@/components/Placeholder";
|
||||
import { faDigits, formatPrice } from "@/lib/format";
|
||||
import type { Product } from "@/lib/data";
|
||||
import { productHref } from "@/lib/store";
|
||||
|
||||
export function ProductCard({ product }: { product: Product }) {
|
||||
const href = product.href ?? `/products/${encodeURIComponent(product.id)}`;
|
||||
const href = product.href ?? productHref(product.id, product.title);
|
||||
|
||||
return (
|
||||
<article className="group flex h-full flex-col rounded-2xl border border-line bg-white p-3">
|
||||
|
||||
Reference in New Issue
Block a user