Skip to content

Commit 67a175c

Browse files
authored
Merge pull request #1212 from hydephp/finalize-navigation-related-classes
Finalize navigation related code
2 parents a77e6b0 + 74e609c commit 67a175c

30 files changed

+892
-479
lines changed

config/hyde.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -327,7 +327,7 @@
327327
// To get started quickly, you can uncomment the defaults here.
328328
// See the documentation link above for more information.
329329
'custom' => [
330-
// NavItem::toLink('https://github.com/hydephp/hyde', 'GitHub', 200),
330+
// NavItem::forLink('https://github.com/hydephp/hyde', 'GitHub', 200),
331331
],
332332

333333
// How should pages in subdirectories be displayed in the menu?

docs/digging-deeper/customization.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -213,13 +213,13 @@ Note that since Blade pages do not support front matter, this will only work for
213213

214214
You can easily add custom navigation menu links similar how we add Authors. Simply add a `NavItem` model to the `navigation.custom` array.
215215

216-
When linking to an external site, you should use the `NavItem::toLink()` method facade. The first two arguments are the destination and label, both required. Third argument is the priority, which is optional.
216+
When linking to an external site, you should use the `NavItem::forLink()` method facade. The first two arguments are the destination and label, both required. Third argument is the priority, which is optional.
217217

218218
```php
219219
// filepath config/hyde.php
220220
'navigation' => [
221221
'custom' => [
222-
NavItem::toLink('https://github.com/hydephp/hyde', 'GitHub', 200),
222+
NavItem::forLink('https://github.com/hydephp/hyde', 'GitHub', 200),
223223
]
224224
]
225225
```

packages/framework/config/hyde.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -327,7 +327,7 @@
327327
// To get started quickly, you can uncomment the defaults here.
328328
// See the documentation link above for more information.
329329
'custom' => [
330-
// NavItem::toLink('https://github.com/hydephp/hyde', 'GitHub', 200),
330+
// NavItem::forLink('https://github.com/hydephp/hyde', 'GitHub', 200),
331331
],
332332

333333
// How should pages in subdirectories be displayed in the menu?

packages/framework/resources/views/components/docs/collapsible-grouped-sidebar-navigation.blade.php

Lines changed: 0 additions & 23 deletions
This file was deleted.

packages/framework/resources/views/components/docs/grouped-sidebar-item.blade.php

Lines changed: 0 additions & 18 deletions
This file was deleted.

packages/framework/resources/views/components/docs/grouped-sidebar-navigation.blade.php

Lines changed: 0 additions & 15 deletions
This file was deleted.
Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1 @@
1-
<div id="sidebar-backdrop" x-cloak="" x-show="sidebarOpen" x-transition @click="sidebarOpen = false"
2-
title="Click to close sidebar" class="w-screen h-screen fixed top-0 left-0 cursor-pointer z-10 bg-black/50">
3-
</div>
1+
<div id="sidebar-backdrop" x-cloak="" x-show="sidebarOpen" x-transition @click="sidebarOpen = false" title="Click to close sidebar" class="w-screen h-screen fixed top-0 left-0 cursor-pointer z-10 bg-black/50"></div>

packages/framework/resources/views/components/docs/sidebar-brand.blade.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<div id="sidebar-brand" class="flex items-center justify-between h-16 py-4 px-2">
22
<strong class="px-2">
3-
@if(DocumentationPage::home() !== null)
3+
@if(DocumentationPage::home())
44
<a href="{{ DocumentationPage::home() }}">
55
{{ config('docs.sidebar.header', 'Documentation') }}
66
</a>

packages/framework/resources/views/components/docs/sidebar-footer.blade.php renamed to packages/framework/resources/views/components/docs/sidebar-footer-text.blade.php

File renamed without changes.
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
<button class="sidebar-group-toggle opacity-50 group-hover:opacity-100">
2+
<svg class="sidebar-group-toggle-icon sidebar-group-toggle-icon-open" x-show="groupOpen" width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
3+
<path d="M8 12L12 8L4 8L8 12Z" fill="currentColor" />
4+
</svg>
5+
<svg class="sidebar-group-toggle-icon sidebar-group-toggle-icon-closed" x-show="! groupOpen" width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
6+
<path d="M12 8L8 12L8 4L12 8Z" fill="currentColor" />
7+
</svg>
8+
</button>

0 commit comments

Comments
 (0)