-
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #474 from hydephp/breaking-namespace-changes
Breaking move of navigation related namespaces hydephp/develop@f2f8c0d
- Loading branch information
github-actions
committed
Sep 8, 2022
1 parent
ebea713
commit 616dc6d
Showing
11 changed files
with
56 additions
and
52 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,44 +1,46 @@ | ||
@php | ||
$navigation = \Hyde\Framework\Models\NavigationMenu::create(); | ||
$navigation = \Hyde\Framework\Models\Navigation\NavigationMenu::create(); | ||
@endphp | ||
|
||
<nav aria-label="Main navigation" id="main-navigation" | ||
class="flex flex-wrap items-center justify-between p-4 shadow-lg sm:shadow-xl md:shadow-none dark:bg-gray-800"> | ||
<div class="flex flex-grow items-center flex-shrink-0 text-gray-700 dark:text-gray-200"> | ||
@include('hyde::components.navigation.navigation-brand') | ||
class="flex flex-wrap items-center justify-between p-4 shadow-lg sm:shadow-xl md:shadow-none dark:bg-gray-800"> | ||
<div class="flex flex-grow items-center flex-shrink-0 text-gray-700 dark:text-gray-200"> | ||
@include('hyde::components.navigation.navigation-brand') | ||
|
||
<div class="ml-auto"> | ||
<x-hyde::navigation.theme-toggle-button /> | ||
</div> | ||
</div> | ||
<div class="ml-auto"> | ||
<x-hyde::navigation.theme-toggle-button/> | ||
</div> | ||
</div> | ||
|
||
<div class="block md:hidden"> | ||
<button id="navigation-toggle-button" @click="navigationOpen = ! navigationOpen" class="flex items-center px-3 py-1 hover:text-gray-700 dark:text-gray-200" | ||
aria-label="Toggle navigation menu"> | ||
<svg x-show="! navigationOpen" title="Open Navigation Menu" class="dark:fill-gray-200" style="display: block;" | ||
id="open-main-navigation-menu-icon" xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" | ||
width="24"><title>Open Menu</title> | ||
<path d="M0 0h24v24H0z" fill="none"/> | ||
<path d="M3 18h18v-2H3v2zm0-5h18v-2H3v2zm0-7v2h18V6H3z"/> | ||
</svg> | ||
<svg x-show="navigationOpen" title="Close Navigation Menu" class="dark:fill-gray-200" style="display: none;" | ||
id="close-main-navigation-menu-icon" xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" | ||
width="24"><title>Close Menu</title> | ||
<path d="M0 0h24v24H0z" fill="none"></path> | ||
<path d="M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"></path> | ||
</svg> | ||
</button> | ||
</div> | ||
<div class="block md:hidden"> | ||
<button id="navigation-toggle-button" @click="navigationOpen = ! navigationOpen" | ||
class="flex items-center px-3 py-1 hover:text-gray-700 dark:text-gray-200" | ||
aria-label="Toggle navigation menu"> | ||
<svg x-show="! navigationOpen" title="Open Navigation Menu" class="dark:fill-gray-200" | ||
style="display: block;" | ||
id="open-main-navigation-menu-icon" xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" | ||
width="24"><title>Open Menu</title> | ||
<path d="M0 0h24v24H0z" fill="none"/> | ||
<path d="M3 18h18v-2H3v2zm0-5h18v-2H3v2zm0-7v2h18V6H3z"/> | ||
</svg> | ||
<svg x-show="navigationOpen" title="Close Navigation Menu" class="dark:fill-gray-200" style="display: none;" | ||
id="close-main-navigation-menu-icon" xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" | ||
width="24"><title>Close Menu</title> | ||
<path d="M0 0h24v24H0z" fill="none"></path> | ||
<path d="M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"></path> | ||
</svg> | ||
</button> | ||
</div> | ||
|
||
<div id="main-navigation-links" | ||
class="w-full x-uncloak-md md:flex flex-grow md:flex-grow-0 md:items-center md:w-auto px-6 -mx-4 border-t mt-3 pt-3 md:border-none md:mt-0 md:py-0 border-gray-200 dark:border-gray-700" | ||
:class="navigationOpen ? '' : 'hidden'" x-cloak> | ||
<ul aria-label="Navigation links" class="md:flex-grow md:flex justify-end"> | ||
@foreach ($navigation->items as $item) | ||
<li class="md:mx-2"> | ||
@include('hyde::components.navigation.navigation-link') | ||
</li> | ||
@endforeach | ||
</ul> | ||
</div> | ||
<div id="main-navigation-links" | ||
class="w-full x-uncloak-md md:flex flex-grow md:flex-grow-0 md:items-center md:w-auto px-6 -mx-4 border-t mt-3 pt-3 md:border-none md:mt-0 md:py-0 border-gray-200 dark:border-gray-700" | ||
:class="navigationOpen ? '' : 'hidden'" x-cloak> | ||
<ul aria-label="Navigation links" class="md:flex-grow md:flex justify-end"> | ||
@foreach ($navigation->items as $item) | ||
<li class="md:mx-2"> | ||
@include('hyde::components.navigation.navigation-link') | ||
</li> | ||
@endforeach | ||
</ul> | ||
</div> | ||
</nav> |
3 changes: 2 additions & 1 deletion
3
src/Models/DocumentationSidebar.php → ...odels/Navigation/DocumentationSidebar.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 2 additions & 1 deletion
3
src/Models/NavigationMenu.php → src/Models/Navigation/NavigationMenu.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters