diff options
Diffstat (limited to 'themes/luci-theme-material')
-rw-r--r--[-rwxr-xr-x] | themes/luci-theme-material/htdocs/luci-static/material/cascade.css (renamed from themes/luci-theme-material/htdocs/luci-static/material/css/style.css) | 48 | ||||
-rw-r--r-- | themes/luci-theme-material/htdocs/luci-static/material/custom.css | 9 | ||||
-rw-r--r-- | themes/luci-theme-material/luasrc/view/themes/material/header.htm | 30 |
3 files changed, 55 insertions, 32 deletions
diff --git a/themes/luci-theme-material/htdocs/luci-static/material/css/style.css b/themes/luci-theme-material/htdocs/luci-static/material/cascade.css index 01fef2110a..fa0316343b 100755..100644 --- a/themes/luci-theme-material/htdocs/luci-static/material/css/style.css +++ b/themes/luci-theme-material/htdocs/luci-static/material/cascade.css @@ -19,15 +19,20 @@ */ /* + * Include custom css + */ +@import url("custom.css"); + +/* * Font generate by Icomoon<icomoon.io> */ @font-face { font-family: 'icomoon'; - src: url('../fonts/font.eot'); - src: url('../fonts/font.eot') format('embedded-opentype'), - url('../fonts/font.ttf') format('truetype'), - url('../fonts/font.woff') format('woff'), - url('../fonts/font.svg') format('svg'); + src: url('fonts/font.eot'); + src: url('fonts/font.eot') format('embedded-opentype'), + url('fonts/font.ttf') format('truetype'), + url('fonts/font.woff') format('woff'), + url('fonts/font.svg') format('svg'); font-weight: normal; font-style: normal; } @@ -255,7 +260,7 @@ footer > a { width: calc(0% + 15rem); height: 100%; height: calc(100% - 4rem); - background-color: white; + background-color: var(--menu-bg-color, #FFFFFF); overflow-x: auto; position: fixed; } @@ -281,18 +286,18 @@ footer > a { } header { - background: #0099CC; - color: white; + background: var(--header-bg, #0099CC); + color: var(--header-color, #FFFFFF); } -header > .container { +header > .fill > .container { margin-top: 0.5rem; padding: 0.5rem 1rem 0 1rem; } -header > .container > .brand { +header > .fill > .container > .brand { font-size: 1.4rem; - color: white; + color: var(--header-color, #FFFFFF); text-decoration: none; cursor: default; vertical-align: text-bottom; @@ -374,7 +379,7 @@ header > .container > .brand { } .main > .main-left > .nav > li a { - color: #404040; + color: var(--menu-color, #404040); display: block; } @@ -406,7 +411,7 @@ header > .container > .brand { .main > .main-left > .nav > li:hover, .main > .main-left > .nav > .slide > .menu:hover { - background: #D4D4D4; + background: var(--submenu-bg-hover, #D4D4D4) } .main > .main-left > .nav > .slide:hover { @@ -418,7 +423,7 @@ header > .container > .brand { } .main > .main-left > .nav > .slide > .slide-menu > .active { - background-color: #0099CC; + background-color: var(--submenu-bg-hover-active, #0099CC); } .main > .main-left > .nav > .slide > .slide-menu > li > a { @@ -431,7 +436,7 @@ header > .container > .brand { } .main > .main-left > .nav > .slide > .slide-menu > li:hover { - background: #D4D4D4; + background: var(--submenu-bg-hover, #D4D4D4) } .main > .main-left > .nav > .slide > .slide-menu > .active:hover { @@ -1226,7 +1231,7 @@ td > .ifacebadge, min-height: 14rem; padding: 0.8rem; font-size: 0.8rem; - font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; + font-family: monospace; color: black; } @@ -1732,6 +1737,17 @@ body.lang_pl.node-main-login .cbi-value-title { width: 12rem; } +/* applyreboot fix */ + +#applyreboot-container { + margin: 2rem; +} + +#applyreboot-section { + margin: 2rem; + line-height: 300%; +} + @media screen and (max-width: 1600px) { .main-left { width: calc(0% + 13rem); diff --git a/themes/luci-theme-material/htdocs/luci-static/material/custom.css b/themes/luci-theme-material/htdocs/luci-static/material/custom.css new file mode 100644 index 0000000000..b32eb2af1b --- /dev/null +++ b/themes/luci-theme-material/htdocs/luci-static/material/custom.css @@ -0,0 +1,9 @@ + +:root { + --header-bg: #0099CC; + --header-color: #FFFFFF; + --menu-bg-color: #FFFFFF; + --menu-color: #404040; + --submenu-bg-hover: #D4D4D4; + --submenu-bg-hover-active: #0099CC; +} diff --git a/themes/luci-theme-material/luasrc/view/themes/material/header.htm b/themes/luci-theme-material/luasrc/view/themes/material/header.htm index f97db25751..c070b1a617 100644 --- a/themes/luci-theme-material/luasrc/view/themes/material/header.htm +++ b/themes/luci-theme-material/luasrc/view/themes/material/header.htm @@ -160,13 +160,9 @@ -- calculate the number of unsaved changes if tree.nodes[category] and tree.nodes[category].ucidata then local ucichanges = 0 - + local i, j for i, j in pairs(require("luci.model.uci").cursor():changes()) do - for k, l in pairs(j) do - for m, n in pairs(l) do - ucichanges = ucichanges + 1; - end - end + ucichanges = ucichanges + #j end if ucichanges > 0 then @@ -203,7 +199,7 @@ <link rel="icon" href="<%=media%>/logo.png" sizes="144x144"> <link rel="apple-touch-icon-precomposed" href="<%=media%>/logo.png" sizes="144x144"> - <link rel="stylesheet" href="<%=media%>/css/style.css"> + <link rel="stylesheet" href="<%=media%>/cascade.css"> <link rel="shortcut icon" href="<%=media%>/favicon.ico"> <% if node and node.css then %> <link rel="stylesheet" href="<%=resource%>/<%=node.css%>"> @@ -216,15 +212,17 @@ </head> <body class="lang_<%=luci.i18n.context.lang%> <%- if node then %><%= striptags( node.title ) %><%- end %> <% if luci.dispatcher.context.authsession then %>logged-in<% end %>"> <header> - <div class="container"> - <span class="showSide"></span> - <a class="brand" href="#"><%=boardinfo.hostname or "?"%></a> - <div class="pull-right"> - <% render_changes() %> - <span id="xhr_poll_status" style="display:none" onclick="XHR.running() ? XHR.halt() : XHR.run()"> - <span class="label success" id="xhr_poll_status_on"><span class="mobile-hide"><%:Auto Refresh%></span> <%:on%></span> - <span class="label" id="xhr_poll_status_off" style="display:none"><span class="mobile-hide"><%:Auto Refresh%></span> <%:off%></span> - </span> + <div class="fill"> + <div class="container"> + <span class="showSide"></span> + <a class="brand" href="#"><%=boardinfo.hostname or "?"%></a> + <div class="pull-right"> + <% render_changes() %> + <span id="xhr_poll_status" style="display:none" onclick="XHR.running() ? XHR.halt() : XHR.run()"> + <span class="label success" id="xhr_poll_status_on"><span class="mobile-hide"><%:Auto Refresh%></span> <%:on%></span> + <span class="label" id="xhr_poll_status_off" style="display:none"><span class="mobile-hide"><%:Auto Refresh%></span> <%:off%></span> + </span> + </div> </div> </div> </header> |