refactor: rename /releases route to /documentatie
Complete route rename from /releases to /documentatie to better reflect the continuous build-in-public nature of the project (not formal releases). Changes: - Renamed app/(marketing)/releases/ → app/(marketing)/documentatie/ - Renamed content/nl/releases/ → content/nl/documentatie/ - Updated all internal links from /releases to /documentatie - Updated middleware publicRoutes (/releases → /documentatie) - Updated navigation.json link - Updated build-timeline.tsx documentation link - Updated all component href attributes - Updated lib/mdx/releases.ts content directory path - Updated sidebar component paths and checks - Updated MDX documentation files with new routes Files changed: - app/(marketing)/documentatie/[category]/page.tsx (footer link) - app/(marketing)/documentatie/page.tsx (card links) - app/(marketing)/documentatie/components/release-sidebar.tsx (all links) - app/(marketing)/components/build-timeline.tsx (documentation link) - content/nl/navigation.json (header link) - content/nl/documentatie/*.mdx (internal references) - middleware.ts (publicRoutes) - lib/mdx/releases.ts (RELEASES_DIR path) This prevents future confusion between "releases" (versioned software releases) and "documentatie" (continuous build documentation). Old URL: /releases/[category] New URL: /documentatie/[category] The old /releases route now returns 404 as expected.
This commit is contained in:
@@ -242,7 +242,7 @@ export const BuildTimeline = ({ data }: BuildTimelineProps) => {
|
|||||||
|
|
||||||
{/* Link to detailed documentation */}
|
{/* Link to detailed documentation */}
|
||||||
<a
|
<a
|
||||||
href="/releases"
|
href="/documentatie"
|
||||||
className="inline-flex items-center gap-2 text-teal-600 hover:text-teal-700 font-medium text-sm transition-colors"
|
className="inline-flex items-center gap-2 text-teal-600 hover:text-teal-700 font-medium text-sm transition-colors"
|
||||||
>
|
>
|
||||||
<span>Bekijk uitgebreide documentatie</span>
|
<span>Bekijk uitgebreide documentatie</span>
|
||||||
|
|||||||
@@ -84,10 +84,10 @@ export default async function ReleasePage({ params }: ReleasePageProps) {
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
{/* Footer Navigation */}
|
{/* Footer Navigation */}
|
||||||
<footer className="mt-12 pt-8 border-t border-slate-200">
|
<footer className="mt-12 pt-8 border-slate-200">
|
||||||
<div className="flex justify-between items-center">
|
<div className="flex justify-between items-center">
|
||||||
<a
|
<a
|
||||||
href="/releases"
|
href="/documentatie"
|
||||||
className="text-teal-600 hover:text-teal-700 font-medium flex items-center gap-2"
|
className="text-teal-600 hover:text-teal-700 font-medium flex items-center gap-2"
|
||||||
>
|
>
|
||||||
<svg className="w-5 h-5" fill="none" stroke="currentColor" viewBox="0 0 24 24">
|
<svg className="w-5 h-5" fill="none" stroke="currentColor" viewBox="0 0 24 24">
|
||||||
@@ -11,7 +11,7 @@ import Link from 'next/link'
|
|||||||
import { usePathname } from 'next/navigation'
|
import { usePathname } from 'next/navigation'
|
||||||
import { ChevronRight, ChevronDown } from 'lucide-react'
|
import { ChevronRight, ChevronDown } from 'lucide-react'
|
||||||
import { useState } from 'react'
|
import { useState } from 'react'
|
||||||
import type { ReleaseNote, GroupMetadata, CategoryMetadata } from '@/lib/mdx/releases'
|
import type { ReleaseNote, GroupMetadata, CategoryMetadata } from '@/lib/mdx/documentatie'
|
||||||
|
|
||||||
interface ReleaseSidebarProps {
|
interface ReleaseSidebarProps {
|
||||||
releases: ReleaseNote[]
|
releases: ReleaseNote[]
|
||||||
@@ -46,7 +46,7 @@ export function ReleaseSidebar({ releases, metadata }: ReleaseSidebarProps) {
|
|||||||
}, {} as Record<string, ReleaseNote[]>)
|
}, {} as Record<string, ReleaseNote[]>)
|
||||||
|
|
||||||
// Check if we're on a specific release page
|
// Check if we're on a specific release page
|
||||||
const isReleaseDetail = pathname.startsWith('/releases/') && pathname !== '/releases'
|
const isReleaseDetail = pathname.startsWith('/documentatie/') && pathname !== '/documentatie'
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
@@ -54,9 +54,9 @@ export function ReleaseSidebar({ releases, metadata }: ReleaseSidebarProps) {
|
|||||||
<div className="lg:hidden bg-white border-b border-slate-200 sticky top-16 z-40">
|
<div className="lg:hidden bg-white border-b border-slate-200 sticky top-16 z-40">
|
||||||
<div className="flex gap-2 p-4 overflow-x-auto">
|
<div className="flex gap-2 p-4 overflow-x-auto">
|
||||||
<Link
|
<Link
|
||||||
href="/releases"
|
href="/documentatie"
|
||||||
className={`flex-shrink-0 px-4 py-2 rounded-lg text-sm font-medium transition-colors ${
|
className={`flex-shrink-0 px-4 py-2 rounded-lg text-sm font-medium transition-colors ${
|
||||||
pathname === '/releases'
|
pathname === '/documentatie'
|
||||||
? 'bg-teal-100 text-teal-700'
|
? 'bg-teal-100 text-teal-700'
|
||||||
: 'bg-slate-100 text-slate-600 hover:bg-slate-200'
|
: 'bg-slate-100 text-slate-600 hover:bg-slate-200'
|
||||||
}`}
|
}`}
|
||||||
@@ -66,9 +66,9 @@ export function ReleaseSidebar({ releases, metadata }: ReleaseSidebarProps) {
|
|||||||
{releases.map((release) => (
|
{releases.map((release) => (
|
||||||
<Link
|
<Link
|
||||||
key={release.slug}
|
key={release.slug}
|
||||||
href={`/releases/${release.slug}`}
|
href={`/documentatie/${release.slug}`}
|
||||||
className={`flex-shrink-0 px-4 py-2 rounded-lg text-sm font-medium transition-colors ${
|
className={`flex-shrink-0 px-4 py-2 rounded-lg text-sm font-medium transition-colors ${
|
||||||
pathname === `/releases/${release.slug}`
|
pathname === `/documentatie/${release.slug}`
|
||||||
? 'bg-teal-100 text-teal-700'
|
? 'bg-teal-100 text-teal-700'
|
||||||
: 'bg-slate-100 text-slate-600 hover:bg-slate-200'
|
: 'bg-slate-100 text-slate-600 hover:bg-slate-200'
|
||||||
}`}
|
}`}
|
||||||
@@ -89,9 +89,9 @@ export function ReleaseSidebar({ releases, metadata }: ReleaseSidebarProps) {
|
|||||||
<nav className="space-y-1">
|
<nav className="space-y-1">
|
||||||
{/* Overview link */}
|
{/* Overview link */}
|
||||||
<Link
|
<Link
|
||||||
href="/releases"
|
href="/documentatie"
|
||||||
className={`flex items-center justify-between px-3 py-2 rounded-lg text-sm font-medium transition-colors ${
|
className={`flex items-center justify-between px-3 py-2 rounded-lg text-sm font-medium transition-colors ${
|
||||||
pathname === '/releases' && !isReleaseDetail
|
pathname === '/documentatie' && !isReleaseDetail
|
||||||
? 'bg-teal-50 text-teal-700'
|
? 'bg-teal-50 text-teal-700'
|
||||||
: 'text-slate-700 hover:bg-slate-50'
|
: 'text-slate-700 hover:bg-slate-50'
|
||||||
}`}
|
}`}
|
||||||
@@ -125,12 +125,12 @@ export function ReleaseSidebar({ releases, metadata }: ReleaseSidebarProps) {
|
|||||||
{isExpanded && (
|
{isExpanded && (
|
||||||
<div className="space-y-1 ml-2">
|
<div className="space-y-1 ml-2">
|
||||||
{groupReleases.map((release) => {
|
{groupReleases.map((release) => {
|
||||||
const isActive = pathname === `/releases/${release.slug}`
|
const isActive = pathname === `/documentatie/${release.slug}`
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Link
|
<Link
|
||||||
key={release.slug}
|
key={release.slug}
|
||||||
href={`/releases/${release.slug}`}
|
href={`/documentatie/${release.slug}`}
|
||||||
className={`flex items-center justify-between px-3 py-2 rounded-lg text-sm font-medium transition-colors group ${
|
className={`flex items-center justify-between px-3 py-2 rounded-lg text-sm font-medium transition-colors group ${
|
||||||
isActive
|
isActive
|
||||||
? 'bg-teal-50 text-teal-700'
|
? 'bg-teal-50 text-teal-700'
|
||||||
@@ -98,7 +98,7 @@ export default async function ReleasesPage() {
|
|||||||
function ReleaseCard({ release }: { release: any }) {
|
function ReleaseCard({ release }: { release: any }) {
|
||||||
return (
|
return (
|
||||||
<Link
|
<Link
|
||||||
href={`/releases/${release.slug}`}
|
href={`/documentatie/${release.slug}`}
|
||||||
className="block bg-white rounded-lg border border-slate-200 p-6 hover:border-teal-300 hover:shadow-md transition-all"
|
className="block bg-white rounded-lg border border-slate-200 p-6 hover:border-teal-300 hover:shadow-md transition-all"
|
||||||
>
|
>
|
||||||
<div className="flex items-start justify-between gap-4">
|
<div className="flex items-start justify-between gap-4">
|
||||||
@@ -25,7 +25,7 @@ De authentication flow vormt de basis van het Mini-ECD systeem. Gebruikers kunne
|
|||||||
|
|
||||||
### Login Flow
|
### Login Flow
|
||||||
|
|
||||||

|

|
||||||
*Login formulier met email/password fields en demo account optie*
|
*Login formulier met email/password fields en demo account optie*
|
||||||
|
|
||||||
De login pagina biedt twee opties:
|
De login pagina biedt twee opties:
|
||||||
@@ -146,7 +146,7 @@ Styled components voor consistente formatting:
|
|||||||
|
|
||||||
```
|
```
|
||||||
# Code
|
# Code
|
||||||
app/(marketing)/releases/
|
app/(marketing)/documentatie/
|
||||||
├── layout.tsx # Sidebar wrapper
|
├── layout.tsx # Sidebar wrapper
|
||||||
├── page.tsx # Overview
|
├── page.tsx # Overview
|
||||||
├── [category]/
|
├── [category]/
|
||||||
@@ -156,7 +156,7 @@ app/(marketing)/releases/
|
|||||||
└── mdx-components.tsx
|
└── mdx-components.tsx
|
||||||
|
|
||||||
# Content
|
# Content
|
||||||
content/nl/releases/
|
content/nl/documentatie/
|
||||||
├── _index.json # Categories metadata
|
├── _index.json # Categories metadata
|
||||||
├── authentication.mdx
|
├── authentication.mdx
|
||||||
└── release-notes-system.mdx
|
└── release-notes-system.mdx
|
||||||
@@ -235,7 +235,7 @@ export async function generateStaticParams() {
|
|||||||
**Stap 1:** Kopieer template
|
**Stap 1:** Kopieer template
|
||||||
```bash
|
```bash
|
||||||
cp docs/templates/release-note-template.mdx \
|
cp docs/templates/release-note-template.mdx \
|
||||||
content/nl/releases/new-feature.mdx
|
content/nl/documentatie/new-feature.mdx
|
||||||
```
|
```
|
||||||
|
|
||||||
**Stap 2:** Vul frontmatter in
|
**Stap 2:** Vul frontmatter in
|
||||||
@@ -255,7 +255,7 @@ description: "Short description here"
|
|||||||
|
|
||||||
**Stap 4:** (Optioneel) Voeg screenshots toe
|
**Stap 4:** (Optioneel) Voeg screenshots toe
|
||||||
```bash
|
```bash
|
||||||
mkdir -p public/releases/new-feature/
|
mkdir -p public/documentatie/new-feature/
|
||||||
# Add images: screenshot-1.png, etc.
|
# Add images: screenshot-1.png, etc.
|
||||||
```
|
```
|
||||||
|
|
||||||
@@ -263,12 +263,12 @@ mkdir -p public/releases/new-feature/
|
|||||||
```bash
|
```bash
|
||||||
npm run build
|
npm run build
|
||||||
npm run dev
|
npm run dev
|
||||||
# Visit /releases/new-feature
|
# Visit /documentatie/new-feature
|
||||||
```
|
```
|
||||||
|
|
||||||
**Stap 6:** Commit en push
|
**Stap 6:** Commit en push
|
||||||
```bash
|
```bash
|
||||||
git add content/nl/releases/new-feature.mdx
|
git add content/nl/documentatie/new-feature.mdx
|
||||||
git commit -m "docs: add new-feature release note"
|
git commit -m "docs: add new-feature release note"
|
||||||
```
|
```
|
||||||
|
|
||||||
@@ -281,7 +281,7 @@ git commit -m "docs: add new-feature release note"
|
|||||||
Timeline component heeft nu link naar release notes:
|
Timeline component heeft nu link naar release notes:
|
||||||
|
|
||||||
```tsx
|
```tsx
|
||||||
<a href="/releases">
|
<a href="/documentatie">
|
||||||
Bekijk gedetailleerde release notes →
|
Bekijk gedetailleerde release notes →
|
||||||
</a>
|
</a>
|
||||||
```
|
```
|
||||||
@@ -293,7 +293,7 @@ Header navigatie heeft "Releases" link toegevoegd:
|
|||||||
```json
|
```json
|
||||||
{
|
{
|
||||||
"links": [
|
"links": [
|
||||||
{ "label": "Releases", "href": "/releases" },
|
{ "label": "Releases", "href": "/documentatie" },
|
||||||
{ "label": "Contact", "href": "/contact" },
|
{ "label": "Contact", "href": "/contact" },
|
||||||
{ "label": "Login", "href": "/login" }
|
{ "label": "Login", "href": "/login" }
|
||||||
]
|
]
|
||||||
@@ -25,8 +25,8 @@ Opgelost: Kritieke webpack module resolution error die optrad bij het laden van
|
|||||||
```
|
```
|
||||||
TypeError: Cannot read properties of undefined (reading 'call')
|
TypeError: Cannot read properties of undefined (reading 'call')
|
||||||
at eval (webpack-internal:///356:9:118)
|
at eval (webpack-internal:///356:9:118)
|
||||||
at 356 (.next/dev/static/chunks/app/(marketing)/releases/layout.js:28:1)
|
at 356 (.next/dev/static/chunks/app/(marketing)/documentatie/layout.js:28:1)
|
||||||
at ReleasesLayout (app/(marketing)/releases/layout.tsx:24:11)
|
at ReleasesLayout (app/(marketing)/documentatie/layout.tsx:24:11)
|
||||||
```
|
```
|
||||||
|
|
||||||
### What Was Happening
|
### What Was Happening
|
||||||
@@ -67,7 +67,7 @@ Maak een tussenlaag die de import isoleert en een default export gebruikt:
|
|||||||
|
|
||||||
**Bestanden structuur:**
|
**Bestanden structuur:**
|
||||||
```
|
```
|
||||||
app/(marketing)/releases/
|
app/(marketing)/documentatie/
|
||||||
├── layout.tsx # Server Component
|
├── layout.tsx # Server Component
|
||||||
├── components/
|
├── components/
|
||||||
│ ├── release-sidebar.tsx # Client Component (named export)
|
│ ├── release-sidebar.tsx # Client Component (named export)
|
||||||
@@ -79,7 +79,7 @@ app/(marketing)/releases/
|
|||||||
```tsx
|
```tsx
|
||||||
// release-sidebar-wrapper.tsx (NIEUW)
|
// release-sidebar-wrapper.tsx (NIEUW)
|
||||||
import { ReleaseSidebar } from './release-sidebar'
|
import { ReleaseSidebar } from './release-sidebar'
|
||||||
import type { ReleaseNote, GroupMetadata, CategoryMetadata } from '@/lib/mdx/releases'
|
import type { ReleaseNote, GroupMetadata, CategoryMetadata } from '@/lib/mdx/documentatie'
|
||||||
|
|
||||||
interface ReleaseSidebarWrapperProps {
|
interface ReleaseSidebarWrapperProps {
|
||||||
releases: ReleaseNote[]
|
releases: ReleaseNote[]
|
||||||
@@ -220,7 +220,7 @@ Dit is een **bekend probleem** in:
|
|||||||
|
|
||||||
## Testing Checklist
|
## Testing Checklist
|
||||||
|
|
||||||
- [x] `/releases` pagina laadt zonder errors
|
- [x] `/documentatie` pagina laadt zonder errors
|
||||||
- [x] Sidebar toont alle groups (Foundation, Features, Infrastructure, Bugs)
|
- [x] Sidebar toont alle groups (Foundation, Features, Infrastructure, Bugs)
|
||||||
- [x] Navigatie tussen release pages werkt
|
- [x] Navigatie tussen release pages werkt
|
||||||
- [x] Hard refresh werkt correct
|
- [x] Hard refresh werkt correct
|
||||||
@@ -233,11 +233,11 @@ Dit is een **bekend probleem** in:
|
|||||||
## Files Changed
|
## Files Changed
|
||||||
|
|
||||||
### Modified
|
### Modified
|
||||||
1. `app/(marketing)/releases/layout.tsx`
|
1. `app/(marketing)/documentatie/layout.tsx`
|
||||||
- Import via wrapper in plaats van direct
|
- Import via wrapper in plaats van direct
|
||||||
|
|
||||||
### Added
|
### Added
|
||||||
2. `app/(marketing)/releases/components/release-sidebar-wrapper.tsx`
|
2. `app/(marketing)/documentatie/components/release-sidebar-wrapper.tsx`
|
||||||
- Nieuwe wrapper component met default export
|
- Nieuwe wrapper component met default export
|
||||||
|
|
||||||
3. `docs/troubleshooting/webpack-module-resolution-error.md`
|
3. `docs/troubleshooting/webpack-module-resolution-error.md`
|
||||||
@@ -315,7 +315,7 @@ Dit is een **bekend probleem** in:
|
|||||||
|
|
||||||
**Internal Documentation:**
|
**Internal Documentation:**
|
||||||
- [Troubleshooting Guide](/docs/troubleshooting/webpack-module-resolution-error.md)
|
- [Troubleshooting Guide](/docs/troubleshooting/webpack-module-resolution-error.md)
|
||||||
- [Release Notes System Docs](/releases/release-notes-system)
|
- [Release Notes System Docs](/documentatie/release-notes-system)
|
||||||
|
|
||||||
**External Links:**
|
**External Links:**
|
||||||
- [Next.js Server Components](https://nextjs.org/docs/app/building-your-application/rendering/server-components)
|
- [Next.js Server Components](https://nextjs.org/docs/app/building-your-application/rendering/server-components)
|
||||||
@@ -3,7 +3,7 @@
|
|||||||
"links": [
|
"links": [
|
||||||
{
|
{
|
||||||
"label": "Documentatie",
|
"label": "Documentatie",
|
||||||
"href": "/releases"
|
"href": "/documentatie"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"label": "Contact",
|
"label": "Contact",
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ import fs from 'fs'
|
|||||||
import path from 'path'
|
import path from 'path'
|
||||||
import matter from 'gray-matter'
|
import matter from 'gray-matter'
|
||||||
|
|
||||||
const RELEASES_DIR = path.join(process.cwd(), 'content/nl/releases')
|
const RELEASES_DIR = path.join(process.cwd(), 'content/nl/documentatie')
|
||||||
|
|
||||||
export interface ReleaseFrontmatter {
|
export interface ReleaseFrontmatter {
|
||||||
title: string
|
title: string
|
||||||
|
|||||||
@@ -50,7 +50,7 @@ export async function middleware(request: NextRequest) {
|
|||||||
'/update-password',
|
'/update-password',
|
||||||
'/auth/callback',
|
'/auth/callback',
|
||||||
'/contact',
|
'/contact',
|
||||||
'/releases',
|
'/documentatie',
|
||||||
'/api/leads',
|
'/api/leads',
|
||||||
'/robots.txt',
|
'/robots.txt',
|
||||||
'/sitemap.xml',
|
'/sitemap.xml',
|
||||||
|
|||||||
Reference in New Issue
Block a user