diff options
author | Thedro Neely <thedroneely@gmail.com> | 2021-04-30 03:51:13 -0400 |
---|---|---|
committer | Thedro Neely <thedroneely@gmail.com> | 2021-04-30 15:31:01 -0400 |
commit | 9d39a7ba3de79e27029bb5c9c2d72e114d8fa795 (patch) | |
tree | 226696a3c635e5f91b1ca97edff49b7f34663f58 /app/views/partials | |
parent | fbd112c924190b1f622c59ff480f0cd2a2433249 (diff) | |
download | thedroneely.com-9d39a7ba3de79e27029bb5c9c2d72e114d8fa795.tar.gz thedroneely.com-9d39a7ba3de79e27029bb5c9c2d72e114d8fa795.tar.bz2 thedroneely.com-9d39a7ba3de79e27029bb5c9c2d72e114d8fa795.zip |
app/views/partials/navigator: Unify
Diffstat (limited to 'app/views/partials')
-rw-r--r-- | app/views/partials/navigator.links.php | 19 | ||||
-rw-r--r-- | app/views/partials/navigator.php | 126 |
2 files changed, 44 insertions, 101 deletions
diff --git a/app/views/partials/navigator.links.php b/app/views/partials/navigator.links.php deleted file mode 100644 index b207446..0000000 --- a/app/views/partials/navigator.links.php +++ /dev/null @@ -1,19 +0,0 @@ -<a href="/" class="<?php echo $check = $navigation->isActiveHome() ? 'navbar__active' : ''; ?> navbar-item navbar__item"> - Home -</a> - -<a href="/posts/" class="<?php echo $check = $navigation->isActive('posts') ? 'navbar__active' : ''; ?> navbar-item navbar__item"> - Posts -</a> - -<a href="/projects/" class="<?php echo $check = $navigation->isActive('projects') ? 'navbar__active' : ''; ?> navbar-item navbar__item"> - Projects -</a> - -<a href="/about/" class="<?php echo $check = $navigation->isActive('about') ? 'navbar__active' : ''; ?> navbar-item navbar__item"> - Profile -</a> - -<a href="/contact/" class="<?php echo $check = $navigation->isActive('contact') ? 'navbar__active' : ''; ?> navbar-item navbar__item"> - Contact -</a> diff --git a/app/views/partials/navigator.php b/app/views/partials/navigator.php index 4c5b765..67cf609 100644 --- a/app/views/partials/navigator.php +++ b/app/views/partials/navigator.php @@ -1,97 +1,59 @@ +<nav id="navbar" class="navbar is-fixed-top" aria-label="main navigation"> + <div class="container"> + <div class="navbar-menu"> + <div class="columns is-centered"> + + <div class="navbar__left column"> + <a title="Go to Website Repository" + href="/git/" + class="navbar-item item__box button is-inline-flex"> + <?php echo icon('git-commit'); ?> + <span>Repo</span> + </a> - <nav id="navbar" class="navbar is-fixed-top" aria-label="main navigation"> - - <div class="container"> - - <div class="navbar-brand navbar-mobile"> - - <a href="/" class="navbar-item navbar__icon - <?php echo $check = $navigation->isActiveHome() ? 'navbar__active' : ''; ?>"> - <div class="has-text-centered"> - <?php echo icon('user'); ?> - <p class="is-size-7 navbar__icon__align">Home</p> - </div> - </a> - - <a href="/posts/" class="navbar-item navbar__icon - <?php echo $check = $navigation->isActive('posts') ? 'navbar__active' : ''; ?>"> - <div class="has-text-centered"> - <?php echo icon('book-open'); ?> - <p class="is-size-7 navbar__icon__align">Posts</p> - </div> - </a> - - <a href="/projects/" class="navbar-item navbar__icon - <?php echo $check = $navigation->isActive('projects') ? 'navbar__active' : ''; ?>"> - <div class="has-text-centered"> - <?php echo icon('briefcase'); ?> - <p class="is-size-7 navbar__icon__align">Projects</p> - </div> - </a> + <?php + $formClass = 'is-inline'; + $buttonClass ='navbar-item button item__box'; + require views('components', 'theme.toggle'); + ?> + </div> - <a href="/contact/" class="navbar-item navbar__icon - <?php echo $check = $navigation->isActive('contact') ? 'navbar__active' : ''; ?>"> - <div class="has-text-centered"> - <?php echo icon('mail'); ?> - <p class="is-size-7 navbar__icon__align">Contact</p> - </div> - </a> + <div class="navbar__middle column is-7"> + <?php + $route = '/'; $label = 'Home'; $icon = 'home'; require views('components', 'navigator.link'); + $route = '/posts/'; $label = 'Posts'; $icon = 'feather'; require views('components', 'navigator.link'); + $route = '/projects/'; $label = 'Projects'; $icon = 'package'; require views('components', 'navigator.link'); + $route = '/about/'; $label = 'Profile'; $icon = 'file-text'; require views('components', 'navigator.link'); + $route = '/contact/'; $label = 'Contact'; $icon = 'mail'; require views('components', 'navigator.link'); + ?> - <div class="navbar-burger navbar-item navbar__icon has-text-dark has-tap-transparent"> + <div class="navbar-item navbar__icon has-text-dark has-tap-transparent"> <?php + $links = true; $id = 'mobile-compact'; $type = 'is-menu is-right'; - $icon = icon('menu'); + $icon = icon('arrow-down-circle'); $label = <<<insert - <span class="is-block has-text-centered"> - $icon - <span class="is-block is-size-7 navbar__icon__align">Menu</span> - </span> + <span class="is-block has-text-centered"> + $icon + <span class="is-block navbar__icon__label">More</span> + </span> insert; - $links = true; - require views('components', 'context-menu'); + require views('components', 'context.menu'); ?> + </div> </div> - </div> - - - <div class="navbar-menu"> - - <div class="columns is-centered has-margin-bottom-none"> - - <div class="navbar__left column"> - <a title="Go to Website Repository" - href="/git/" - class="navbar-item item__box button is-inline-flex"> - <?php echo icon('git-commit'); ?> - <span>Repo</span> - </a> - - <?php - $formClass = 'is-inline'; - $buttonClass ='navbar-item button item__box is-inline-flex'; - require views('components', 'theme-toggle'); - ?> - - </div> - - <div class="navbar__middle column is-7"> - <?php require views('partials', 'navigator.links'); ?> - </div> - - <div class="navbar__right column"> - <a title="Coffee" - href ="https://ko-fi.com/thedroneely" - class="navbar-item item__box button is-inline-flex has-margin-right-none"> - <?php echo icon('coffee'); ?> - <span>Coffee</span> - </a> - </div> - + <div class="navbar__right column"> + <a title="Coffee" + href ="https://ko-fi.com/thedroneely" + class="navbar-item item__box button is-inline-flex has-margin-left-none"> + <?php echo icon('coffee'); ?> + <span>Coffee</span> + </a> </div> </div> - </div> - </nav> + </div> +</nav> |