diff options
Diffstat (limited to 'template/en/custom/global/common-links.html.tmpl')
-rw-r--r-- | template/en/custom/global/common-links.html.tmpl | 153 |
1 files changed, 153 insertions, 0 deletions
diff --git a/template/en/custom/global/common-links.html.tmpl b/template/en/custom/global/common-links.html.tmpl new file mode 100644 index 000000000..3f09d0496 --- /dev/null +++ b/template/en/custom/global/common-links.html.tmpl @@ -0,0 +1,153 @@ +[%# This Source Code Form is subject to the terms of the Mozilla Public + # License, v. 2.0. If a copy of the MPL was not distributed with this + # file, You can obtain one at http://mozilla.org/MPL/2.0/. + # + # This Source Code Form is "Incompatible With Secondary Licenses", as + # defined by the Mozilla Public License, v. 2.0. + #%] + +[% DEFAULT qs_suffix = "" %] +[% USE Bugzilla %] + +<nav class="tyrian-navbar" role="navigation"> +<div class="container"> + <div class="row"> + <div class="navbar-header"> + <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-main-collapse"> + <span class="sr-only">Toggle navigation</span> + <span class="icon-bar"></span> + <span class="icon-bar"></span> + <span class="icon-bar"></span> + </button> + </div> + <div class="collapse navbar-collapse navbar-main-collapse"> + <ul class="nav navbar-nav"> + + <!-- TODO Can we use the Gentoo logo instead? --> + <li><a href="./">Home</a></li> + + + + <li><a href="enter_bug.cgi?format=guided">New</a></li> + <li><a href="enter_bug.cgi">[Ex]</a></li> + <li><a href="describecomponents.cgi">Browse</a></li> + <li><a href="query.cgi">Search</a></li> + + [% IF user.login %] + <li><a href="page.cgi?id=mydashboard.html">Dashboard</a></li> + [% END %] + + + + + <li class="dropdown"> + <a class="dropdown-toggle" data-toggle="dropdown" role="button" aria-expanded="false"><i class="fa fa-angle-double-right" aria-hidden="true"></i></a> + <ul class="dropdown-menu" role="menu"> + <li><a href="report.cgi" style="color:#262626">Reports</a></li> + <li><a href="https://wiki.gentoo.org/wiki/Foundation:Privacy_Policy" style="color:#262626">Privacy Policy</a></li> + [% PROCESS link_to_documentation %] + </ul> + </li> + + </ul> + + <ul class="nav navbar-nav navbar-right hidden-xs"> + + + [% IF Param('shutdownhtml') || Bugzilla.has_flags %] + [% IF user.id %] + <li><a href="request.cgi?requester=[% user.login FILTER uri %]&requestee= + [% user.login FILTER uri %]&do_union=1&group=type&action=queue"><i class="fa fa-bell" aria-hidden="true"></i></a></li> + + + + [%-# Work around FF bug: keep this on one line %]</li> + [% ELSE %] + <li><a href="request.cgi"><i class="fa fa-bell" aria-hidden="true"></i></a>[%-# Work around FF bug: keep this on one line %]</li> + [% END %] + [% END %] + + + [% Hook.process('action-links') %] + + + <li class="dropdown"> + <a href="/wiki/Gentoo_Wiki:Menu-Documentation" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-expanded="false"> <span class="fa fa-user" aria-label="Personal tools"></span> [% IF sudoer %] [%+ sudoer.login FILTER html %] (<b>impersonating [%+ user.login FILTER html %]</b> <a href="relogin.cgi?action=end-sudo">end session</a>) [% ELSE %] [%+ user.login FILTER html %] [% END %] <span class="caret"></span></a> + <ul class="dropdown-menu" role="menu"> + + [% IF user.login %] + <li><a href="userprefs.cgi" style="color:#262626">Preferences</a></li> + + [% IF user.can_administer %] + <li><a href="admin.cgi" style="color:#262626">Administration</a></li> + [% END %] + + <li> + [% IF user.authorizer.can_logout %] + <a href="index.cgi?logout=1" style="color:#262626">Log out</a> + [% ELSE %] + Logged in as + [% END %] + [%-# Work around FF bug: keep this on one line %]</li> + [% ELSE %] + + [% IF Param('createemailregexp') + && user.authorizer.user_can_create_account %] + <li id="new_account_container[% qs_suffix FILTER html %]"> + <a href="createaccount.cgi" style="color:#262626">New Account</a> + </li> + [% END %] + + [%# Only display one login form when we're on a LOGIN_REQUIRED page. That + # way, we're guaranteed that the user will use the form that has + # hidden_fields in it (the center form) instead of this one. Also, it's + # less confusing to have one form (as opposed to three) when you're + # required to log in. + #%] + [% IF user.authorizer.can_login && !Bugzilla.page_requires_login %] + [% PROCESS "account/auth/login-small.html.tmpl" %] + [% END %] + [% END %] + </ul> + </li> + </ul> + + <form action="buglist.cgi" class="navbar-form navbar-right" method="get" + onsubmit="if (this.quicksearch.value == '') + { alert('Please enter one or more search terms first.'); + return false; } return true;"> + + <input type="hidden" id="no_redirect[% qs_suffix FILTER html %]" name="no_redirect" value="0"> + <script type="text/javascript"> + if (history && history.replaceState) { + var no_redirect = document.getElementById("no_redirect[% qs_suffix FILTER js %]"); + no_redirect.value = 1; + } + </script> + <div class="input-group" style="margin-top:2px;"> + <span class="input-group-addon" style="background:#61597b;color:#FFF;border:0px;" id="basic-addon1"><i class="fa fa-search" aria-hidden="true"></i></span> + <input class="form-control" style="height:30px;border:0px;background:#61597b;color:#FFF;padding-left:0px;box-shadow: none;" type="text" id="quicksearch[% qs_suffix FILTER html %]" name="quicksearch" + title="Quick Search" placeholder="Search Bugs" value="[% quicksearch FILTER html %]"> + </div> + <button class="btn btn-default hidden" type="submit" value="Search" + id="find[% qs_suffix FILTER html %]">Search</button> + + [%-# Work around FF bug: keep this on one line %]</form> + + </div> + </div> +</div> +</nav> + + + + + [% Hook.process("link-row") %] +[% BLOCK link_to_documentation %] + [% IF doc_section %] + <li role="separator" class="divider"></li> + <li> + <a href="[% docs_urlbase _ doc_section FILTER html %]" style="color:#262626" target="_blank">Help</a> + </li> + [% END %] +[% END %] |