1
0
mirror of https://github.com/yacy/yacy_search_server.git synced 2025-07-14 07:56:08 -04:00

added option to change the navbar-default, i.e. usable for dark skins

This commit is contained in:
Michael Peter Christen
2014-11-26 18:01:35 +01:00
parent 041b605cfe
commit c0f9f6ac66
3 changed files with 4 additions and 1 deletions
defaults
htroot/env/templates
source/net/yacy/http/servlets

@ -1270,4 +1270,5 @@ crawler.userAgent.clienttimeout = 10000
decoration.audio = false
decoration.grafics.linkstructure = true
decoration.hostanalysis = false
decoration.simpleheadernavbar = navbar-default

@ -1,5 +1,5 @@
<!-- top navigation -->
<div class="navbar navbar-default navbar-fixed-top" role="navigation">
<div class="navbar #[simpleheadernavbar]# navbar-fixed-top" role="navigation">
<div class="container-fluid">
<div class="navbar-header">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">

@ -903,6 +903,8 @@ public class YaCyDefaultServlet extends HttpServlet {
templatePatterns.putHTML("newpeer_peerhash", myPeer.hash);
boolean authorized = sb.adminAuthenticated(legacyRequestHeader) >= 2;
templatePatterns.put("authorized", authorized ? 1 : 0);
templatePatterns.put("simpleheadernavbar", sb.getConfig("decoration.simpleheadernavbar", "navbar-default"));
// add navigation keys to enable or disable menu items
templatePatterns.put("navigation-p2p", sb.getConfigBool(SwitchboardConstants.DHT_ENABLED, true) || !sb.isRobinsonMode() ? 1 : 0);