fix(map): enrich and render minorLocations alongside defaultLocations on dynamic slug pages to establish 100% map parity with referenzen overview
All checks were successful
Build & Deploy / 🔍 Prepare (push) Successful in 19s
Build & Deploy / 🧪 QA (push) Successful in 1m6s
Build & Deploy / 🏗️ Build (push) Successful in 2m37s
Build & Deploy / 🚀 Deploy (push) Successful in 25s
Build & Deploy / 🧪 Post-Deploy Verification (push) Has been skipped
Build & Deploy / 🔔 Notify (push) Successful in 1s
All checks were successful
Build & Deploy / 🔍 Prepare (push) Successful in 19s
Build & Deploy / 🧪 QA (push) Successful in 1m6s
Build & Deploy / 🏗️ Build (push) Successful in 2m37s
Build & Deploy / 🚀 Deploy (push) Successful in 25s
Build & Deploy / 🧪 Post-Deploy Verification (push) Has been skipped
Build & Deploy / 🔔 Notify (push) Successful in 1s
This commit is contained in:
@@ -9,7 +9,7 @@ import { SITE_URL } from '@/lib/schema';
|
|||||||
import TrackedLink from '@/components/analytics/TrackedLink';
|
import TrackedLink from '@/components/analytics/TrackedLink';
|
||||||
import { getButtonClasses, ButtonOverlay } from '@/components/ui/Button';
|
import { getButtonClasses, ButtonOverlay } from '@/components/ui/Button';
|
||||||
import { getAllReferences } from '@/lib/references';
|
import { getAllReferences } from '@/lib/references';
|
||||||
import { defaultLocations } from '@/lib/map-data';
|
import { defaultLocations, minorLocations } from '@/lib/map-data';
|
||||||
|
|
||||||
// Import components used in MDX
|
// Import components used in MDX
|
||||||
import { HeroVideo as HomeHero } from '@/components/blocks/HeroVideo';
|
import { HeroVideo as HomeHero } from '@/components/blocks/HeroVideo';
|
||||||
@@ -153,7 +153,8 @@ export default async function Page(props: { params: Promise<{ locale: string; sl
|
|||||||
|
|
||||||
// Fetch references to enrich the map if it's used
|
// Fetch references to enrich the map if it's used
|
||||||
const references = await getAllReferences(locale);
|
const references = await getAllReferences(locale);
|
||||||
const enrichedLocations = defaultLocations.map(loc => {
|
const allLocations = [...defaultLocations, ...minorLocations];
|
||||||
|
const enrichedLocations = allLocations.map(loc => {
|
||||||
if (loc.type === 'project') {
|
if (loc.type === 'project') {
|
||||||
const ref = references.find(r => r.slug === loc.id);
|
const ref = references.find(r => r.slug === loc.id);
|
||||||
if (ref) {
|
if (ref) {
|
||||||
|
|||||||
Reference in New Issue
Block a user