-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Expand file tree
/
Copy pathconfig.php
More file actions
23 lines (21 loc) · 868 Bytes
/
config.php
File metadata and controls
23 lines (21 loc) · 868 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
<?php
return [
'baseUrl' => '',
'production' => false,
'collections' => [],
'config' => json_decode(file_get_contents(__DIR__ . '/tailwind.json'), true),
'version' => json_decode(file_get_contents(__DIR__ . '/node_modules/tailwindcss/package.json'), true)['version'],
'colors' => ['red', 'orange', 'yellow', 'green', 'teal', 'blue', 'indigo', 'purple', 'pink'],
'active' => function ($page, $path) {
$pages = collect(array_wrap($page));
return $pages->contains(function ($page) use ($path) {
return str_contains($page->getPath(), $path);
});
},
'anyChildrenActive' => function ($page, $children) {
return $children->contains(function ($link) use ($page) {
return $page->getPath() == '/docs/'. $link;
});
},
'navigation' => require_once('navigation.php'),
];