world-game/site/config/menu.php
isUnknown 44af8a9b4e add privacy page as standalone SPA view outside slide navigation
- New Kirby template/blueprint/JSON for privacy page (confidentialite slug)
- Standalone page state in slides store + router handling for non-nav pages
- Privacy.svelte view with background image, text blocks, footer
- Centralize vertical lines in App.svelte as fixed elements with per-slide visibility
- Footer privacy link language-aware (FR/EN)
- Portfolio mockup fix: read from default language for consistent EN display
- menu.php: add privacy page to Kirby panel navigation

refs #44

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-30 18:43:35 +02:00

38 lines
1.4 KiB
PHP

<?php
/**
* Helper : génère un item de menu avec détection automatique du lien actif.
*/
function menuItem(string $id, string $label, string $icon, string $link): array
{
return [
'label' => $label,
'icon' => $icon,
'link' => $link,
'current' => function () use ($link): bool {
return Str::contains(Kirby\Cms\App::instance()->path(), $link);
},
];
}
return [
'site' => [
'label' => 'Données partagées',
'icon' => 'cog',
'current' => function (): bool {
return Str::contains(Kirby\Cms\App::instance()->path(), '/site');
},
],
'-',
'home' => menuItem('home', 'Accueil', 'home', 'pages/home'),
'expertise' => menuItem('expertise', 'Expertise','wand', 'pages/expertise'),
'portfolio' => menuItem('portfolio', 'Portfolio','images', 'pages/portfolio'),
'jouer' => menuItem('jouer', 'Jouer', 'play', 'pages/jouer'),
'a-propos' => menuItem('a-propos', 'À propos', 'users', 'pages/a-propos'),
'blog' => menuItem('blog', 'Blog', 'text', 'pages/blog'),
'white-papers' => menuItem('livres-blancs', 'Livres blancs', 'book', 'pages/livres-blancs'),
'confidentialite' => menuItem('confidentialite', 'Confidentialité', 'lock', 'pages/confidentialite'),
'-',
'users',
'system',
];