feat: Revert homepage changes, fix Persian slug 404, and make various article and about us adjustments

- Removed the newly added city-focused section from the homepage.
- Fixed 404 error for Persian slugs in specialties and blog pages by implementing a decode helper.
- Removed the "مخصوص شهر" label from article headers.
- Linked article tags to their respective filter pages.
- Adjusted related content images to prevent distortion.
- Added a section in the "About Us" page for physician registration guidance.
- Updated the logo in the "About Us" header to the correct version.
- Added tests for the new functionality and ensured existing tests are updated accordingly.
This commit is contained in:
hamed
2026-08-08 21:06:48 +03:30
parent e8a073cae6
commit 9cfbd2e002
18 changed files with 704 additions and 145 deletions
+5 -2
View File
@@ -10,6 +10,7 @@ import { buildSpecialtyFaq, buildSpecialtyIntro } from "@/lib/specialtyContent";
import { isCategorySpecialty } from "@/lib/specialtyIndexing";
import { safeJsonLd } from "@/lib/sanitize";
import { fetchReq } from "@/lib/req";
import { decodeRouteParam } from "@/lib/routeParams";
import { isNextRedirectError } from "@/lib/maintenance";
const API_URL = process.env.NEXT_PUBLIC_API_URL;
@@ -42,7 +43,8 @@ const getDoctors = cache(async (specialtyId, cityId) => {
});
export async function generateMetadata({ params }) {
const { slug } = await params;
const { slug: rawSlug } = await params;
const slug = decodeRouteParam(rawSlug);
const specialty = findSpecialty(slug);
if (!specialty) notFound();
@@ -73,7 +75,8 @@ export async function generateMetadata({ params }) {
}
async function SpecialtyDetail({ params }) {
const { slug } = await params;
const { slug: rawSlug } = await params;
const slug = decodeRouteParam(rawSlug);
const specialty = findSpecialty(slug);
if (!specialty) notFound();