<?php

return [
    // Kirby configuration settings
    'panel' => [
        'css' => 'build/panel.css',
        'install' => true,
        'language' => 'fr',
        'menu' => [
            'site' => [
                'current' => function (string $current): bool { // Override default menu entry highlighting
                    $links = [ // Links of all custom menu entries
                        'pages/media-library',
                    ];
                    $path  = Kirby\Cms\App::instance()->path();
                    return $current === 'site' && A::every($links, fn ($link) => Str::contains($path, $link) === false);
                },
            ],
            '-',
            'media-library' => [
                'icon' => 'images',
                'label' => [
                    'en' => 'Media library',
                    'fr' => 'Médiathèque',
                ],
                'link' => 'pages/media-library',
                'current' => function (string $current): bool { // Override default menu entry highlighting
                    $path = Kirby\Cms\App::instance()->path();
                    return Str::contains($path, 'pages/media-library'); // Link of current menu entry
                },
            ],
            'users',
            'system',
        ]
    ],
    // Sitemapper plugin options
    'kirbyzone.sitemapper' => [
        'intro' => false,
        'byLine' => 'Sitemap generated with <a href="https://github.com/kirbyzone/sitemapper" target="_blank">Sitemapper by Kirbyzone</a>.'
    ],
    // Thumbnails and srcsets presets
    'thumbs' => [
        'srcsets' => [
            'default' => [
                '640w' => ['width' => 640, 'quality' => 80],
                '1280w' => ['width' => 1280, 'quality' => 80],
                '1920w' => ['width' => 1920, 'quality' => 80],
                '2560w' => ['width' => 2560, 'quality' => 80],
                '3840w' => ['width' => 3840, 'quality' => 80]
            ]
        ]
    ]
];
