Browse Source

Set selected class to global navigation

Signed-off-by: falkTX <falktx@falktx.com>
pull/19/head
falkTX 1 month ago
parent
commit
82437ee588
Signed by: falkTX <falktx@falktx.com> GPG Key ID: CDBAA37ABC74FBA0
3 changed files with 19 additions and 9 deletions
  1. +1
    -1
      News/themes/stardust/layouts/default.twig
  2. +1
    -1
      css/base.css
  3. +17
    -7
      includes/header.php

+ 1
- 1
News/themes/stardust/layouts/default.twig View File

@@ -32,7 +32,7 @@ ${ trigger.call("head") }
</a>
<a id="header-home" href="/">Home</a>
<ul id="global-navigation">
<li id="item-news"><a href="/News">News</a></li>
<li id="item-news" class="selected"><a href="/News">News</a></li>
<li id="item-soft" class="item-menu">
<a href="/Applications">Software &#9660;</a>
<div class="item-menu-children">


+ 1
- 1
css/base.css View File

@@ -261,7 +261,7 @@ form *[disabled="disabled"], form *[disabled=""], form *[disabled="true"]{backgr
.column_3{-moz-column-count:3;-moz-column-gap:20px;-webkit-column-count:3;-webkit-column-gap:20px;column-count:3;column-gap:20px;}
.column_4{-moz-column-count:4;-moz-column-gap:20px;-webkit-column-count:4;-webkit-column-gap:20px;column-count:4;column-gap:20px;}
#global-navigation{color:fuchsia !important;} /* TODO */
#global-navigation li.selected{background-color:#690;} /* TODO */
#global-navigation li.selected{background-image:none;background-color:#1a1b1a;}
/* TODO - global-navigation-menu */
.global-navigation-menu{background:#fff;border:1px solid #888;border-color:#DDDDDD #CCCCCC #BBBBBB;border-top:none;width:23em;padding:0;display:none;position:absolute;z-index:10;}
.global-navigation-menu, .global-navigation-menu li:last-child{border-bottom-left-radius:5px;border-bottom-right-radius:5px;-moz-border-radius-bottomleft:5px;-moz-border-radius-bottomright:5px;-webkit-border-bottom-left-radius:5px;-webkit-border-bottom-right-radius:5px;-khtml-border-bottom-left-radius:5px;-khtml-border-bottom-right-radius:5px;}


+ 17
- 7
includes/header.php View File

@@ -305,7 +305,7 @@ function isMobile() {
<a id="header-home" href="<?php echo $ROOT; ?>/">Home</a>
<ul id="global-navigation">
<li id="item-news"><a href="<?php echo $ROOT; ?>/News">News</a></li>
<li id="item-soft" class="item-menu">
<li id="item-soft" class="item-menu<?php if ($PAGE_SOURCE_1[0] == "/Applications" || $PAGE_SOURCE_1[0] == "/Plugins") { ?> selected<?php } ?>">
<?php if (isMobile()) { ?>
<span>Software &#9660;</span>
<?php } else { ?>
@@ -316,7 +316,7 @@ function isMobile() {
<p><a href="<?php echo $ROOT; ?>/Plugins"><img src="<?php echo $ROOT; ?>/images/ico_distrho.png" alt=""/> &nbsp; Plugins</a></p>
</div>
</li>
<li id="item-repos" class="item-menu">
<li id="item-repos" class="item-menu<?php if ($PAGE_SOURCE_1[0] == "/Repositories") { ?> selected<?php } ?>">
<?php if (isMobile()) { ?>
<span>Repositories &#9660;</span>
<?php } else { ?>
@@ -330,11 +330,21 @@ function isMobile() {
<p><a href="<?php echo $ROOT; ?>/Repositories:Extras">Extras</a></p>
</div>
</li>
<li id="item-board"><a href="<?php echo $ROOT; ?>/Board">Board</a></li>
<li id="item-development"><a href="<?php echo $ROOT; ?>/Development">Development</a></li>
<li id="item-documentation"><a href="<?php echo $ROOT; ?>/Documentation">Documentation</a></li>
<li id="item-downloads"><a href="<?php echo $ROOT; ?>/Downloads">Downloads</a></li>
<li id="item-donate"><a href="<?php echo $ROOT; ?>/Donations">Donations</a></li>
<li id="item-board" class="<?php if ($PAGE_SOURCE_1[0] == "/Board") { ?>selected<?php } ?>">
<a href="<?php echo $ROOT; ?>/Board">Board</a>
</li>
<li id="item-development" class="<?php if ($PAGE_SOURCE_1[0] == "/Development") { ?>selected<?php } ?>">
<a href="<?php echo $ROOT; ?>/Development">Development</a>
</li>
<li id="item-documentation" class="<?php if ($PAGE_SOURCE_1[0] == "/Documentation") { ?>selected<?php } ?>">
<a href="<?php echo $ROOT; ?>/Documentation">Documentation</a>
</li>
<li id="item-downloads" class="<?php if ($PAGE_SOURCE_1[0] == "/Downloads") { ?>selected<?php } ?>">
<a href="<?php echo $ROOT; ?>/Downloads">Downloads</a>
</li>
<li id="item-donate" class="<?php if ($PAGE_SOURCE_1[0] == "/Donations") { ?>selected<?php } ?>">
<a href="<?php echo $ROOT; ?>/Donations">Donations</a>
</li>
</ul>
</div>
</div>


Loading…
Cancel
Save