added seeder for legacy apge and added the legacy page

This commit is contained in:
teledrisi
2026-10-05 17:32:06 +02:00
parent a5c531be00
commit 98fae066bc
30 changed files with 1488 additions and 181 deletions
+5 -4
View File
@@ -5,7 +5,7 @@
/ -> 302 to /en or /ar (Accept-Language)
/:lang -> home
/:lang/<section> -> one of the ten top-level sections
/:lang/<section> -> one of the eleven top-level sections
/:lang/<section>/<slug> -> one entry of a CMS-backed section
/:lang/events-calendar/<slug>.ics -> that event as an RFC 5545 file
anything else -> 404
@@ -43,7 +43,7 @@
ROUTE IDS
---------
"root" | "routes/locale-redirect" | "locale" | "routes/not-found", one per
section named after its key: "home", "about", "whatWeDo", "activities",
section named after its key: "home", "about", "legacy", "whatWeDo", "activities",
"events", "applications", "news", "contact", "resources", "knowledgeHub" -
and one per detail route, the section key plus "Detail" ("newsDetail",
"eventsDetail", ...), plus "eventsIcs". So `useRouteLoaderData("locale")`
@@ -76,6 +76,7 @@ import { ROUTE_SLUGS, type RouteSlugKey } from "./lib/route-slugs";
const SECTION_MODULES = {
home: "routes/home.tsx",
about: "routes/about.tsx",
legacy: "routes/legacy.tsx",
whatWeDo: "routes/what-we-do.tsx",
activities: "routes/activities-and-initiatives.tsx",
events: "routes/events-calendar.tsx",
@@ -89,7 +90,7 @@ const SECTION_MODULES = {
/**
* Section -> the module that renders ONE entry of it, at
* `<section slug>/:slug`. Only the six CMS-backed sections have one; "about",
* "what-we-do", "contact" and the home page are single pages with nothing to
* "legacy", "what-we-do", "contact" and the home page are single pages with nothing to
* drill into.
*/
const DETAIL_MODULES = {
@@ -117,7 +118,7 @@ const RESOURCE_ROUTES = [
const detailKeys = Object.keys(DETAIL_MODULES) as (keyof typeof DETAIL_MODULES)[];
/**
* Every page under ":lang": the ten sections, then the six detail routes, then
* Every page under ":lang": the eleven sections, then the six detail routes, then
* the .ics resource route. Flat on purpose - see "LISTING AND DETAIL ARE
* SIBLINGS" above.
*/