Update theme argon
|
@ -8,18 +8,9 @@ include $(TOPDIR)/rules.mk
|
||||||
|
|
||||||
LUCI_TITLE:=Argon Theme
|
LUCI_TITLE:=Argon Theme
|
||||||
LUCI_DEPENDS:=
|
LUCI_DEPENDS:=
|
||||||
PKG_VERSION:=2.2.4
|
PKG_VERSION:=2.2.6
|
||||||
PKG_RELEASE:=20200821
|
PKG_RELEASE:=20210215
|
||||||
|
|
||||||
include $(TOPDIR)/feeds/luci/luci.mk
|
include $(TOPDIR)/feeds/luci/luci.mk
|
||||||
|
|
||||||
define Package/luci-theme-argon/postinst
|
# call BuildPackage - OpenWrt buildroot signature
|
||||||
#!/bin/sh
|
|
||||||
sed -i ":a;$!N;s/tmpl.render.*sysauth_template.*return/local scope = { duser = default_user, fuser = user }\nlocal ok, res = luci.util.copcall\(luci.template.render_string, [[<% include\(\"themes\/\" .. theme .. \"\/sysauth\"\) %>]], scope\)\nif ok then\nreturn res\nend\nreturn luci.template.render\(\"sysauth\", scope\)/;ba" /usr/lib/lua/luci/dispatcher.lua
|
|
||||||
[ -f /usr/lib/lua/luci/view/themes/argon/out_header_login.htm ] && mv -f /usr/lib/lua/luci/view/themes/argon/out_header_login.htm /usr/lib/lua/luci/view/header_login.htm
|
|
||||||
rm -Rf /var/luci-modulecache
|
|
||||||
rm -Rf /var/luci-indexcache
|
|
||||||
exit 0
|
|
||||||
endef
|
|
||||||
|
|
||||||
# call BuildPackage - OpenWrt buildroot signature
|
|
||||||
|
|
|
@ -1,36 +1,58 @@
|
||||||
# luci-theme-argon ([中文](/README_ZH.md))
|
<div align="center">
|
||||||
|
<img src="https://raw.githubusercontent.com/jerrykuku/staff/master/argon_title2.png" >
|
||||||
|
<h1 align="center">
|
||||||
|
A new LuCI theme for OpenWrt
|
||||||
|
</h1>
|
||||||
|
<h3 align="center">
|
||||||
|
Argon is a clean HTML5 theme for LuCI. Users may<br>setup their own favorite logins, including beautiful<br>pics and customized mp4 videos.<br><br>
|
||||||
|
</h3>
|
||||||
|
|
||||||
[1]: https://img.shields.io/badge/license-MIT-brightgreen.svg
|
<a href="/LICENSE">
|
||||||
[2]: /LICENSE
|
<img src="https://img.shields.io/badge/license-MIT-brightgreen.svg" alt="">
|
||||||
[3]: https://img.shields.io/badge/PRs-welcome-brightgreen.svg
|
</a>
|
||||||
[4]: https://github.com/jerrykuku/luci-theme-argon/pulls
|
|
||||||
[5]: https://img.shields.io/badge/Issues-welcome-brightgreen.svg
|
|
||||||
[6]: https://github.com/jerrykuku/luci-theme-argon/issues/new
|
|
||||||
[7]: https://img.shields.io/badge/release-v2.2.4-blue.svg?
|
|
||||||
[8]: https://github.com/jerrykuku/luci-theme-argon/releases
|
|
||||||
[9]: https://img.shields.io/github/downloads/jerrykuku/luci-theme-argon/total
|
|
||||||
[10]: https://img.shields.io/badge/Contact-telegram-blue
|
|
||||||
[11]: https://t.me/jerryk6
|
|
||||||
[![license][1]][2]
|
|
||||||
[![PRs Welcome][3]][4]
|
|
||||||
[![Issue Welcome][5]][6]
|
|
||||||
[![Release Version][7]][8]
|
|
||||||
[![Release Count][9]][8]
|
|
||||||
[![Contact Me][10]][11]
|
|
||||||
|
|
||||||

|
<a href="https://github.com/jerrykuku/luci-theme-argon/pulls">
|
||||||

|
<img src="https://img.shields.io/badge/PRs-welcome-brightgreen.svg" alt="">
|
||||||
|
</a>
|
||||||
|
|
||||||
|
<a href="https://github.com/jerrykuku/luci-theme-argon/issues/new">
|
||||||
|
<img src="https://img.shields.io/badge/Issues-welcome-brightgreen.svg">
|
||||||
|
</a>
|
||||||
|
|
||||||
|
<a href="https://github.com/jerrykuku/luci-theme-argon/releases">
|
||||||
|
<img src="https://img.shields.io/badge/release-v2.2.5-blue.svg?">
|
||||||
|
</a>
|
||||||
|
|
||||||
|
<a href="https://github.com/jerrykuku/luci-theme-argon/releases">
|
||||||
|
<img src="https://img.shields.io/github/downloads/jerrykuku/luci-theme-argon/total">
|
||||||
|
</a>
|
||||||
|
|
||||||
|
<a href="https://t.me/jerryk6">
|
||||||
|
<img src="https://img.shields.io/badge/Contact-telegram-blue">
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
<br>
|
||||||
|
<div align="center">
|
||||||
|
<img src="https://raw.githubusercontent.com/jerrykuku/staff/master/argon2.gif">
|
||||||
|
</div>
|
||||||
|
|
||||||
A new Luci theme for LEDE/OpenWRT
|
<br>English | [简体中文](README_ZH.md)
|
||||||
Argon is a clean HTML5 theme for LuCI. It is based on luci-theme-material and Argon Template
|
|
||||||
|
|
||||||
## Notice
|
## Notice
|
||||||
|
It is strongly recommended to use the Chrome browser. Some new css3 features are used in the theme, and currently only Chrome has the best compatibility.
|
||||||
|
The mainline version of IE series currently has bugs to be resolved.
|
||||||
|
FireFox does not enable the backdrop-filter by default, see here for the opening method: https://developer.mozilla.org/zh-CN/docs/Web/CSS/backdrop-filter
|
||||||
|
|
||||||
v2.x.x Adapt to official mainline snapshot.
|
v2.x.x Adapt to official mainline snapshot.
|
||||||
You can checkout branch 18.06 for OpenWRT 18.06 or lean 19.07.
|
You can checkout branch 18.06 for OpenWRT 18.06 or lean 19.07.
|
||||||
|
|
||||||
## Update log 2020.08.21 v2.2.4
|
## Update Log 2020.09.13 v2.2.5
|
||||||
|
|
||||||
|
- 【v2.2.5】New config app for argon theme. You can set the blur and transparency of the login page of argon theme, and manage the background pictures and videos.[Chrome is recommended] [Download](https://github.com/jerrykuku/luci-app-argon-config/releases/download/v0.8-beta/luci-app-argon-config_0.8-beta_all.ipk)
|
||||||
|
- 【v2.2.5】Automatically set as the default theme when compiling.
|
||||||
|
- 【v2.2.5】Modify the file structure to adapt to luci-app-argon-config. The old method of turning on dark mode is no longer applicable, please use it with luci-app-argon-config.
|
||||||
|
- 【v2.2.5】Adapt to Koolshare lede 2.3.6。
|
||||||
|
- 【v2.2.5】Fix some Bug。
|
||||||
- 【v2.2.4】Fix the problem that the login background cannot be displayed on some phones.
|
- 【v2.2.4】Fix the problem that the login background cannot be displayed on some phones.
|
||||||
- 【v2.2.4】Remove the dependency of luasocket.
|
- 【v2.2.4】Remove the dependency of luasocket.
|
||||||
- 【v2.2.3】Fix Firmware flash page display error in dark mode.
|
- 【v2.2.3】Fix Firmware flash page display error in dark mode.
|
||||||
|
@ -78,16 +100,19 @@ make -j1 V=s
|
||||||
### For Lean openwrt 18.06 LuCI
|
### For Lean openwrt 18.06 LuCI
|
||||||
|
|
||||||
```
|
```
|
||||||
wget --no-check-certificate https://github.com/jerrykuku/luci-theme-argon/releases/download/v1.6.9/luci-theme-argon_1.6.9-20200821_all.ipk
|
wget --no-check-certificate https://github.com/jerrykuku/luci-theme-argon/releases/download/v1.7.0/luci-theme-argon_1.7.0-20200909_all.ipk
|
||||||
opkg install luci-theme-argon*.ipk
|
opkg install luci-theme-argon*.ipk
|
||||||
```
|
```
|
||||||
|
|
||||||
### For openwrt official 19.07 Snapshots LuCI master
|
### For openwrt official 19.07 Snapshots LuCI master
|
||||||
|
|
||||||
```
|
```
|
||||||
wget --no-check-certificate https://github.com/jerrykuku/luci-theme-argon/releases/download/v2.2.4/luci-theme-argon_2.2.4-20200821_all.ipk
|
opkg install luci-compat
|
||||||
|
wget --no-check-certificate https://github.com/jerrykuku/luci-theme-argon/releases/download/v2.2.5/luci-theme-argon_2.2.5-20200914_all.ipk
|
||||||
opkg install luci-theme-argon*.ipk
|
opkg install luci-theme-argon*.ipk
|
||||||
```
|
```
|
||||||
|

|
||||||
|

|
||||||
|
|
||||||
## Thanks to
|
## Thanks to
|
||||||
|
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
[4]: https://github.com/jerrykuku/luci-theme-argon/pulls
|
[4]: https://github.com/jerrykuku/luci-theme-argon/pulls
|
||||||
[5]: https://img.shields.io/badge/Issues-welcome-brightgreen.svg
|
[5]: https://img.shields.io/badge/Issues-welcome-brightgreen.svg
|
||||||
[6]: https://github.com/jerrykuku/luci-theme-argon/issues/new
|
[6]: https://github.com/jerrykuku/luci-theme-argon/issues/new
|
||||||
[7]: https://img.shields.io/badge/release-v2.2.4-blue.svg?
|
[7]: https://img.shields.io/badge/release-v2.2.5-blue.svg?
|
||||||
[8]: https://github.com/jerrykuku/luci-theme-argon/releases
|
[8]: https://github.com/jerrykuku/luci-theme-argon/releases
|
||||||
[9]: https://img.shields.io/github/downloads/jerrykuku/luci-theme-argon/total
|
[9]: https://img.shields.io/github/downloads/jerrykuku/luci-theme-argon/total
|
||||||
[10]: https://img.shields.io/badge/Contact-telegram-blue
|
[10]: https://img.shields.io/badge/Contact-telegram-blue
|
||||||
|
@ -23,14 +23,21 @@
|
||||||
全新的 Openwrt 主题,基于luci-theme-material 和 开源免费的 Argon 模板进行移植。
|
全新的 Openwrt 主题,基于luci-theme-material 和 开源免费的 Argon 模板进行移植。
|
||||||
|
|
||||||
## 注意
|
## 注意
|
||||||
|
强烈建议使用Chrome 浏览器。主题中使用了一些新的css3特性,目前只有Chrome有最佳的兼容性。
|
||||||
|
主线版本 IE 系列目前还有Bug有待解决。
|
||||||
|
FireFox 默认不开启backdrop-filter,开启方法见这里:https://developer.mozilla.org/zh-CN/docs/Web/CSS/backdrop-filter
|
||||||
当前master版本基于官方 OpenWrt 19.07.1 稳定版固件进行移植适配。
|
当前master版本基于官方 OpenWrt 19.07.1 稳定版固件进行移植适配。
|
||||||
v2.x.x 适配主线快照版本。
|
v2.x.x 适配主线快照版本。
|
||||||
v1.x.x 适配18.06 和 Lean Openwrt [如果你是lean代码 请选择这个版本]
|
v1.x.x 适配18.06 和 Lean Openwrt [如果你是lean代码 请选择这个版本]
|
||||||
|
|
||||||
|
|
||||||
## 更新日志 2020.08.21 v2.2.4
|
## 更新日志 2020.09.13 v2.2.5
|
||||||
|
|
||||||
|
- 【v2.2.5】全新的设置app.你可以设置argon 主题的登录页面的模糊和透明度,并管理背景图片与视频。[建议使用 Chrome][点击下载](https://github.com/jerrykuku/luci-app-argon-config/releases/download/v0.8-beta/luci-app-argon-config_0.8-beta_all.ipk)
|
||||||
|
- 【v2.2.5】当编译固件时,将自动设置为默认主题。
|
||||||
|
- 【v2.2.5】修改文件结构,以适应luci-app-argon-config,旧的开启暗色模式方法将不再适用,请搭配luci-app-argon-config使用。
|
||||||
|
- 【v2.2.5】适配Koolshare lede 2.3.6。
|
||||||
|
- 【v2.2.5】修复了一些Bug。
|
||||||
- 【v2.2.4】修复了在某些手机下图片背景第一次加载不能显示的问题。
|
- 【v2.2.4】修复了在某些手机下图片背景第一次加载不能显示的问题。
|
||||||
- 【v2.2.4】取消 luasocket 的依赖,无需再担心依赖问题。
|
- 【v2.2.4】取消 luasocket 的依赖,无需再担心依赖问题。
|
||||||
- 【v2.2.3】修正了在暗色模式下,固件刷写弹窗内的显示错误。
|
- 【v2.2.3】修正了在暗色模式下,固件刷写弹窗内的显示错误。
|
||||||
|
@ -78,14 +85,14 @@ make -j1 V=s
|
||||||
### Lean源码
|
### Lean源码
|
||||||
|
|
||||||
```
|
```
|
||||||
wget --no-check-certificate https://github.com/jerrykuku/luci-theme-argon/releases/download/v1.6.9/luci-theme-argon_1.6.9-20200821_all.ipk
|
wget --no-check-certificate https://github.com/jerrykuku/luci-theme-argon/releases/download/v1.7.0/luci-theme-argon_1.7.0-20200909_all.ipk
|
||||||
opkg install luci-theme-argon*.ipk
|
opkg install luci-theme-argon*.ipk
|
||||||
```
|
```
|
||||||
|
|
||||||
### For openwrt official 19.07 Snapshots LuCI master
|
### For openwrt official 19.07 Snapshots LuCI master
|
||||||
|
|
||||||
```
|
```
|
||||||
wget --no-check-certificate https://github.com/jerrykuku/luci-theme-argon/releases/download/v2.2.4/luci-theme-argon_2.2.4-20200821_all.ipk
|
wget --no-check-certificate https://github.com/jerrykuku/luci-theme-argon/releases/download/v2.2.5/luci-theme-argon_2.2.5-20200914_all.ipk
|
||||||
opkg install luci-theme-argon*.ipk
|
opkg install luci-theme-argon*.ipk
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
BIN
luci-theme-argon/Screenshots/screenshot_pc.jpg
Normal file
After Width: | Height: | Size: 658 KiB |
BIN
luci-theme-argon/Screenshots/screenshot_phone.jpg
Normal file
After Width: | Height: | Size: 456 KiB |
|
@ -1,2 +1,2 @@
|
||||||
Drop background here!
|
Drop background here!
|
||||||
accept jpg png gif and mp4
|
accept jpg png gif and mp4
|
||||||
|
|
|
@ -24,7 +24,7 @@
|
||||||
* Login background
|
* Login background
|
||||||
* https://unsplash.com/
|
* https://unsplash.com/
|
||||||
*
|
*
|
||||||
* Licensed to the public under the Apache License 2.0
|
* Licensed to the public under the Apache License 2.0
|
||||||
*/
|
*/
|
||||||
body {
|
body {
|
||||||
background: #1e1e1e;
|
background: #1e1e1e;
|
||||||
|
@ -50,11 +50,12 @@ body {
|
||||||
box-shadow: none;
|
box-shadow: none;
|
||||||
}
|
}
|
||||||
.login-page .login-container .login-form .form-login .cbi-button-apply {
|
.login-page .login-container .login-form .form-login .cbi-button-apply {
|
||||||
background-image: linear-gradient(-135deg, #6c61ab 0%, #594ca9 100%);
|
background-color: #483d8b !important;
|
||||||
|
background-color: var(--dark-primary) !important;
|
||||||
}
|
}
|
||||||
.login-page .login-container .login-form .form-login .cbi-button-apply:hover,
|
.login-page .login-container .login-form .form-login .cbi-button-apply:hover,
|
||||||
.login-page .login-container .login-form .form-login .cbi-button-apply:focus {
|
.login-page .login-container .login-form .form-login .cbi-button-apply:focus {
|
||||||
background-image: linear-gradient(-135deg, #554c8a 0%, #483d8b 100%);
|
opacity: 0.9;
|
||||||
}
|
}
|
||||||
header::after {
|
header::after {
|
||||||
background-color: #1e1e1e !important;
|
background-color: #1e1e1e !important;
|
||||||
|
@ -79,7 +80,8 @@ header::after {
|
||||||
background: none !important;
|
background: none !important;
|
||||||
}
|
}
|
||||||
.main .main-left .nav .slide .menu.active {
|
.main .main-left .nav .slide .menu.active {
|
||||||
background-color: darkslateblue !important;
|
background-color: #483d8b !important;
|
||||||
|
background-color: var(--dark-primary) !important;
|
||||||
color: #cccccc !important;
|
color: #cccccc !important;
|
||||||
}
|
}
|
||||||
.main .main-left .nav .slide .menu.active a::after {
|
.main .main-left .nav .slide .menu.active a::after {
|
||||||
|
@ -89,7 +91,8 @@ header::after {
|
||||||
color: #cccccc !important;
|
color: #cccccc !important;
|
||||||
}
|
}
|
||||||
.main .main-left .nav li a:hover {
|
.main .main-left .nav li a:hover {
|
||||||
background-color: darkslateblue !important;
|
background-color: #483d8b !important;
|
||||||
|
background-color: var(--dark-primary) !important;
|
||||||
color: #cccccc !important;
|
color: #cccccc !important;
|
||||||
}
|
}
|
||||||
.main .main-left::-webkit-scrollbar-thumb {
|
.main .main-left::-webkit-scrollbar-thumb {
|
||||||
|
@ -113,7 +116,8 @@ h3 {
|
||||||
a:-webkit-any-link {
|
a:-webkit-any-link {
|
||||||
color: -webkit-link;
|
color: -webkit-link;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
color: darkslateblue;
|
color: #483d8b;
|
||||||
|
color: var(--dark-primary);
|
||||||
}
|
}
|
||||||
input:-webkit-autofill {
|
input:-webkit-autofill {
|
||||||
background-color: #3c3c3c !important;
|
background-color: #3c3c3c !important;
|
||||||
|
@ -122,8 +126,10 @@ input:-webkit-autofill {
|
||||||
.cbi-button-apply,
|
.cbi-button-apply,
|
||||||
.cbi-button-edit {
|
.cbi-button-edit {
|
||||||
color: #fff !important;
|
color: #fff !important;
|
||||||
background-color: darkslateblue !important;
|
background-color: #483d8b !important;
|
||||||
border-color: darkslateblue !important;
|
background-color: var(--dark-primary) !important;
|
||||||
|
border-color: #483d8b !important;
|
||||||
|
border-color: var(--dark-primary) !important;
|
||||||
}
|
}
|
||||||
.cbi-section em {
|
.cbi-section em {
|
||||||
color: #ccc;
|
color: #ccc;
|
||||||
|
@ -235,7 +241,8 @@ h4 {
|
||||||
}
|
}
|
||||||
.cbi-button {
|
.cbi-button {
|
||||||
color: #ccc !important;
|
color: #ccc !important;
|
||||||
background-color: darkslateblue;
|
background-color: #483d8b;
|
||||||
|
background-color: var(--dark-primary);
|
||||||
}
|
}
|
||||||
.cbi-section-node {
|
.cbi-section-node {
|
||||||
background: none;
|
background: none;
|
||||||
|
@ -271,7 +278,8 @@ div > .table > .tbody > .tr:nth-of-type(2n) {
|
||||||
}
|
}
|
||||||
.tabs > li[class~="active"],
|
.tabs > li[class~="active"],
|
||||||
.tabs > li:hover {
|
.tabs > li:hover {
|
||||||
border-bottom: 0.18751rem solid darkslateblue;
|
border-bottom: 0.18751rem solid #483d8b;
|
||||||
|
border-bottom: 0.18751rem solid var(--dark-primary);
|
||||||
color: #ccc;
|
color: #ccc;
|
||||||
background-color: #181819;
|
background-color: #181819;
|
||||||
}
|
}
|
||||||
|
@ -311,7 +319,8 @@ input {
|
||||||
}
|
}
|
||||||
select:not([multiple="multiple"]):focus,
|
select:not([multiple="multiple"]):focus,
|
||||||
input:focus {
|
input:focus {
|
||||||
border-color: darkslateblue !important;
|
border-color: #483d8b !important;
|
||||||
|
border-color: var(--dark-primary) !important;
|
||||||
outline: 0;
|
outline: 0;
|
||||||
}
|
}
|
||||||
select {
|
select {
|
||||||
|
@ -392,7 +401,8 @@ td.cbi-value-field var {
|
||||||
box-shadow: 0 0 5px 0 rgba(0, 0, 0, 0.35);
|
box-shadow: 0 0 5px 0 rgba(0, 0, 0, 0.35);
|
||||||
}
|
}
|
||||||
.node-services-vssr .cbi-section-table-row.fast {
|
.node-services-vssr .cbi-section-table-row.fast {
|
||||||
background: darkslateblue !important;
|
background: #483d8b !important;
|
||||||
|
background: var(--dark-primary) !important;
|
||||||
color: #fff;
|
color: #fff;
|
||||||
}
|
}
|
||||||
.node-services-vssr .ssr-button {
|
.node-services-vssr .ssr-button {
|
||||||
|
@ -406,7 +416,8 @@ td.cbi-value-field var {
|
||||||
background-color: darkolivegreen !important;
|
background-color: darkolivegreen !important;
|
||||||
}
|
}
|
||||||
.notice {
|
.notice {
|
||||||
background-color: darkslateblue !important;
|
background-color: #483d8b !important;
|
||||||
|
background-color: var(--dark-primary) !important;
|
||||||
}
|
}
|
||||||
.cbi-input-find,
|
.cbi-input-find,
|
||||||
.cbi-input-save,
|
.cbi-input-save,
|
||||||
|
@ -431,7 +442,8 @@ td.cbi-value-field var {
|
||||||
.cbi-button-apply.important,
|
.cbi-button-apply.important,
|
||||||
.cbi-button-reload.important,
|
.cbi-button-reload.important,
|
||||||
.cbi-button-action.important {
|
.cbi-button-action.important {
|
||||||
border: 1px darkslateblue solid !important;
|
border: 1px #483d8b solid !important;
|
||||||
|
border: 1px var(--dark-primary) solid !important;
|
||||||
}
|
}
|
||||||
.btn[value="Dismiss"],
|
.btn[value="Dismiss"],
|
||||||
.cbi-button[value="Terminate"],
|
.cbi-button[value="Terminate"],
|
||||||
|
@ -442,8 +454,8 @@ td.cbi-value-field var {
|
||||||
.cbi-button-neutral[value="Disable"] {
|
.cbi-button-neutral[value="Disable"] {
|
||||||
font-weight: normal;
|
font-weight: normal;
|
||||||
color: #fff;
|
color: #fff;
|
||||||
border: thin solid darkorange!important;
|
border: thin solid darkorange !important;
|
||||||
background-color: darkorange!important;
|
background-color: darkorange !important;
|
||||||
}
|
}
|
||||||
fieldset[id^="cbi-apply-"] {
|
fieldset[id^="cbi-apply-"] {
|
||||||
background-color: #333333;
|
background-color: #333333;
|
||||||
|
@ -477,7 +489,8 @@ header .fill .status span[data-style="active"] {
|
||||||
}
|
}
|
||||||
td > .ifacebadge,
|
td > .ifacebadge,
|
||||||
.td > .ifacebadge {
|
.td > .ifacebadge {
|
||||||
background-color: darkslateblue;
|
background-color: #483d8b;
|
||||||
|
background-color: var(--dark-primary);
|
||||||
border: 0;
|
border: 0;
|
||||||
}
|
}
|
||||||
.btn.danger,
|
.btn.danger,
|
||||||
|
@ -529,7 +542,8 @@ div[style="width:100%;height:300px;border:1px solid #000;background:#fff"] {
|
||||||
background-color: darkorange !important;
|
background-color: darkorange !important;
|
||||||
}
|
}
|
||||||
.cbi-value input[type="password"] + .cbi-button-neutral {
|
.cbi-value input[type="password"] + .cbi-button-neutral {
|
||||||
background-color: darkslateblue !important;
|
background-color: #483d8b !important;
|
||||||
|
background-color: var(--dark-primary) !important;
|
||||||
}
|
}
|
||||||
.btn,
|
.btn,
|
||||||
button,
|
button,
|
||||||
|
@ -558,7 +572,8 @@ input,
|
||||||
color: #adb5bd !important;
|
color: #adb5bd !important;
|
||||||
}
|
}
|
||||||
.cbi-dropdown[open] {
|
.cbi-dropdown[open] {
|
||||||
border-color: darkslateblue !important;
|
border-color: #483d8b !important;
|
||||||
|
border-color: var(--dark-primary) !important;
|
||||||
}
|
}
|
||||||
.cbi-dropdown[open] > ul.dropdown {
|
.cbi-dropdown[open] > ul.dropdown {
|
||||||
background: #252526 !important;
|
background: #252526 !important;
|
||||||
|
@ -571,11 +586,13 @@ input,
|
||||||
border-bottom: 1px solid #3c3c3c !important;
|
border-bottom: 1px solid #3c3c3c !important;
|
||||||
}
|
}
|
||||||
.cbi-dropdown[open] > ul.dropdown > li[selected] {
|
.cbi-dropdown[open] > ul.dropdown > li[selected] {
|
||||||
background-color: darkslateblue !important;
|
background-color: #483d8b !important;
|
||||||
|
background-color: var(--dark-primary) !important;
|
||||||
border-bottom: 1px solid #3c3c3c !important;
|
border-bottom: 1px solid #3c3c3c !important;
|
||||||
}
|
}
|
||||||
.cbi-dropdown[open] > ul.dropdown > li.focus {
|
.cbi-dropdown[open] > ul.dropdown > li.focus {
|
||||||
background: darkslateblue;
|
background: #483d8b;
|
||||||
|
background: var(--dark-primary);
|
||||||
outline: none;
|
outline: none;
|
||||||
}
|
}
|
||||||
.ifacebadge {
|
.ifacebadge {
|
||||||
|
@ -594,7 +611,8 @@ input,
|
||||||
.cbi-button[value="Upload"],
|
.cbi-button[value="Upload"],
|
||||||
.cbi-button[value$="Apply"],
|
.cbi-button[value$="Apply"],
|
||||||
.cbi-button[onclick="addKey(event)"] {
|
.cbi-button[onclick="addKey(event)"] {
|
||||||
background: darkslateblue !important;
|
background: #483d8b !important;
|
||||||
|
background: var(--dark-primary) !important;
|
||||||
}
|
}
|
||||||
.btn.primary,
|
.btn.primary,
|
||||||
.cbi-page-actions .cbi-button-save,
|
.cbi-page-actions .cbi-button-save,
|
||||||
|
@ -607,7 +625,8 @@ input,
|
||||||
.cbi-button[value="Scan"],
|
.cbi-button[value="Scan"],
|
||||||
.cbi-button[value^="Back"],
|
.cbi-button[value^="Back"],
|
||||||
.cbi-button-neutral[onclick="handleConfig(event)"] {
|
.cbi-button-neutral[onclick="handleConfig(event)"] {
|
||||||
background: darkslateblue;
|
background: #483d8b;
|
||||||
|
background: var(--dark-primary);
|
||||||
}
|
}
|
||||||
[data-page="admin-system-opkg"] h2 {
|
[data-page="admin-system-opkg"] h2 {
|
||||||
color: #ccc !important;
|
color: #ccc !important;
|
||||||
|
|
|
@ -24,7 +24,7 @@
|
||||||
* Login background
|
* Login background
|
||||||
* https://unsplash.com/
|
* https://unsplash.com/
|
||||||
*
|
*
|
||||||
* Licensed to the public under the Apache License 2.0
|
* Licensed to the public under the Apache License 2.0
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
@ -183,4 +183,4 @@
|
||||||
|
|
||||||
.icon-app:before {
|
.icon-app:before {
|
||||||
content: "\e915";
|
content: "\e915";
|
||||||
}
|
}
|
||||||
|
|
BIN
luci-theme-argon/htdocs/luci-static/argon/favicon.ico
Normal file
After Width: | Height: | Size: 15 KiB |
Before Width: | Height: | Size: 535 B |
BIN
luci-theme-argon/htdocs/luci-static/argon/icon/favicon-16x16.png
Normal file
After Width: | Height: | Size: 1,019 B |
BIN
luci-theme-argon/htdocs/luci-static/argon/icon/favicon-32x32.png
Normal file
After Width: | Height: | Size: 1.7 KiB |
BIN
luci-theme-argon/htdocs/luci-static/argon/icon/favicon-96x96.png
Normal file
After Width: | Height: | Size: 3.6 KiB |
Before Width: | Height: | Size: 535 B |
3
luci-theme-argon/htdocs/luci-static/argon/js/polyfill.min.js
vendored
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
/* Disable minification (remove `.min` from URL path) for more info */
|
||||||
|
|
||||||
|
(function(undefined) {}).call('object' === typeof window && window || 'object' === typeof self && self || 'object' === typeof global && global || {});
|
|
@ -7,7 +7,7 @@
|
||||||
* Have a bug? Please create an issue here on GitHub!
|
* Have a bug? Please create an issue here on GitHub!
|
||||||
* https://github.com/jerrykuku/luci-theme-argon/issues
|
* https://github.com/jerrykuku/luci-theme-argon/issues
|
||||||
*
|
*
|
||||||
* luci-theme-material:
|
* luci-theme-material:
|
||||||
* Copyright 2015 Lutty Yang <lutty@wcan.in>
|
* Copyright 2015 Lutty Yang <lutty@wcan.in>
|
||||||
* https://github.com/LuttyYang/luci-theme-material/
|
* https://github.com/LuttyYang/luci-theme-material/
|
||||||
*
|
*
|
||||||
|
@ -89,6 +89,11 @@ document.addEventListener('luci-loaded', function(ev) {
|
||||||
$(".main > .main-left > .nav > .slide > .menu").click(function () {
|
$(".main > .main-left > .nav > .slide > .menu").click(function () {
|
||||||
var ul = $(this).next(".slide-menu");
|
var ul = $(this).next(".slide-menu");
|
||||||
var menu = $(this);
|
var menu = $(this);
|
||||||
|
$(".main > .main-left > .nav > .slide > .menu").each(function () {
|
||||||
|
var ulNode = $(this);
|
||||||
|
ulNode.removeClass("active");
|
||||||
|
ulNode.next(".slide-menu").stop(true).slideUp("fast")
|
||||||
|
});
|
||||||
if (!ul.is(":visible")) {
|
if (!ul.is(":visible")) {
|
||||||
menu.addClass("active");
|
menu.addClass("active");
|
||||||
ul.addClass("active");
|
ul.addClass("active");
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
// compress: false , sourceMap: false
|
||||||
/**
|
/**
|
||||||
* Argon is a clean HTML5 theme for LuCI. It is based on luci-theme-material and Argon Template
|
* Argon is a clean HTML5 theme for LuCI. It is based on luci-theme-material and Argon Template
|
||||||
*
|
*
|
||||||
|
@ -24,7 +25,7 @@
|
||||||
* Login background
|
* Login background
|
||||||
* https://unsplash.com/
|
* https://unsplash.com/
|
||||||
*
|
*
|
||||||
* Licensed to the public under the Apache License 2.0
|
* Licensed to the public under the Apache License 2.0
|
||||||
*/
|
*/
|
||||||
|
|
||||||
body {
|
body {
|
||||||
|
@ -61,11 +62,12 @@ body {
|
||||||
}
|
}
|
||||||
|
|
||||||
.cbi-button-apply {
|
.cbi-button-apply {
|
||||||
background-image: linear-gradient(-135deg, #6c61ab 0%, #594ca9 100%);
|
background-color: #483d8b !important;
|
||||||
|
background-color: var(--dark-primary) !important;
|
||||||
|
|
||||||
&:hover,
|
&:hover,
|
||||||
&:focus {
|
&:focus {
|
||||||
background-image: linear-gradient(-135deg, rgb(85, 76, 138) 0%, rgb(72, 61, 139) 100%);
|
opacity: 0.9;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -113,7 +115,8 @@ header::after {
|
||||||
}
|
}
|
||||||
|
|
||||||
.menu.active {
|
.menu.active {
|
||||||
background-color: darkslateblue !important;
|
background-color: #483d8b !important;
|
||||||
|
background-color: var(--dark-primary) !important;
|
||||||
color: #cccccc !important;
|
color: #cccccc !important;
|
||||||
|
|
||||||
a::after {
|
a::after {
|
||||||
|
@ -128,7 +131,8 @@ header::after {
|
||||||
}
|
}
|
||||||
|
|
||||||
a:hover {
|
a:hover {
|
||||||
background-color: darkslateblue !important;
|
background-color: #483d8b !important;
|
||||||
|
background-color: var(--dark-primary) !important;
|
||||||
color: #cccccc !important;
|
color: #cccccc !important;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -163,7 +167,8 @@ h3 {
|
||||||
a:-webkit-any-link {
|
a:-webkit-any-link {
|
||||||
color: -webkit-link;
|
color: -webkit-link;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
color: darkslateblue;
|
color: #483d8b;
|
||||||
|
color: var(--dark-primary);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -175,8 +180,10 @@ input:-webkit-autofill {
|
||||||
.cbi-button-apply,
|
.cbi-button-apply,
|
||||||
.cbi-button-edit {
|
.cbi-button-edit {
|
||||||
color: #fff !important;
|
color: #fff !important;
|
||||||
background-color: darkslateblue !important;
|
background-color: #483d8b !important;
|
||||||
border-color: darkslateblue !important;
|
background-color: var(--dark-primary) !important;
|
||||||
|
border-color: #483d8b !important;
|
||||||
|
border-color: var(--dark-primary) !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -316,7 +323,8 @@ h4 {
|
||||||
|
|
||||||
.cbi-button {
|
.cbi-button {
|
||||||
color: #ccc !important;
|
color: #ccc !important;
|
||||||
background-color: darkslateblue;
|
background-color: #483d8b;
|
||||||
|
background-color: var(--dark-primary);
|
||||||
}
|
}
|
||||||
|
|
||||||
.cbi-section-node {
|
.cbi-section-node {
|
||||||
|
@ -361,7 +369,8 @@ div>.table>.tbody>.tr:nth-of-type(2n) {
|
||||||
|
|
||||||
.tabs>li[class~="active"],
|
.tabs>li[class~="active"],
|
||||||
.tabs>li:hover {
|
.tabs>li:hover {
|
||||||
border-bottom: 0.18751rem solid darkslateblue;
|
border-bottom: 0.18751rem solid #483d8b;
|
||||||
|
border-bottom: 0.18751rem solid var(--dark-primary);
|
||||||
color: #ccc;
|
color: #ccc;
|
||||||
background-color: #181819;
|
background-color: #181819;
|
||||||
}
|
}
|
||||||
|
@ -410,7 +419,8 @@ input {
|
||||||
|
|
||||||
select:not([multiple="multiple"]):focus,
|
select:not([multiple="multiple"]):focus,
|
||||||
input:focus {
|
input:focus {
|
||||||
border-color: darkslateblue !important;
|
border-color: #483d8b !important;
|
||||||
|
border-color: var(--dark-primary) !important;
|
||||||
outline: 0;
|
outline: 0;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -515,7 +525,8 @@ td.cbi-value-field var {
|
||||||
}
|
}
|
||||||
|
|
||||||
.node-services-vssr .cbi-section-table-row.fast {
|
.node-services-vssr .cbi-section-table-row.fast {
|
||||||
background: darkslateblue !important;
|
background: #483d8b !important;
|
||||||
|
background: var(--dark-primary) !important;
|
||||||
color: #fff;
|
color: #fff;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -535,7 +546,8 @@ td.cbi-value-field var {
|
||||||
}
|
}
|
||||||
|
|
||||||
.notice {
|
.notice {
|
||||||
background-color: darkslateblue !important;
|
background-color: #483d8b !important;
|
||||||
|
background-color: var(--dark-primary) !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
.cbi-input-find,
|
.cbi-input-find,
|
||||||
|
@ -563,7 +575,8 @@ td.cbi-value-field var {
|
||||||
.cbi-button-apply.important,
|
.cbi-button-apply.important,
|
||||||
.cbi-button-reload.important,
|
.cbi-button-reload.important,
|
||||||
.cbi-button-action.important {
|
.cbi-button-action.important {
|
||||||
border: 1px darkslateblue solid !important;
|
border: 1px #483d8b solid !important;
|
||||||
|
border: 1px var(--dark-primary) solid !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
.btn[value="Dismiss"],
|
.btn[value="Dismiss"],
|
||||||
|
@ -575,8 +588,8 @@ td.cbi-value-field var {
|
||||||
.cbi-button-neutral[value="Disable"] {
|
.cbi-button-neutral[value="Disable"] {
|
||||||
font-weight: normal;
|
font-weight: normal;
|
||||||
color: #fff;
|
color: #fff;
|
||||||
border: thin solid darkorange!important;
|
border: thin solid darkorange !important;
|
||||||
background-color: darkorange!important;
|
background-color: darkorange !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
fieldset[id^="cbi-apply-"] {
|
fieldset[id^="cbi-apply-"] {
|
||||||
|
@ -619,7 +632,8 @@ header .fill .status span[data-style="active"] {
|
||||||
td>.ifacebadge,
|
td>.ifacebadge,
|
||||||
.td>.ifacebadge {
|
.td>.ifacebadge {
|
||||||
|
|
||||||
background-color: darkslateblue;
|
background-color: #483d8b;
|
||||||
|
background-color: var(--dark-primary);
|
||||||
border: 0;
|
border: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -684,7 +698,8 @@ div[style="width:100%;height:300px;border:1px solid #000;background:#fff"] {
|
||||||
}
|
}
|
||||||
|
|
||||||
.cbi-value input[type="password"]+.cbi-button-neutral {
|
.cbi-value input[type="password"]+.cbi-button-neutral {
|
||||||
background-color: darkslateblue !important;
|
background-color: #483d8b !important;
|
||||||
|
background-color: var(--dark-primary) !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
.btn,
|
.btn,
|
||||||
|
@ -722,7 +737,8 @@ input,
|
||||||
}
|
}
|
||||||
|
|
||||||
.cbi-dropdown[open] {
|
.cbi-dropdown[open] {
|
||||||
border-color: darkslateblue !important;
|
border-color: #483d8b !important;
|
||||||
|
border-color: var(--dark-primary) !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
.cbi-dropdown[open]>ul.dropdown {
|
.cbi-dropdown[open]>ul.dropdown {
|
||||||
|
@ -740,12 +756,14 @@ input,
|
||||||
}
|
}
|
||||||
|
|
||||||
.cbi-dropdown[open]>ul.dropdown>li[selected] {
|
.cbi-dropdown[open]>ul.dropdown>li[selected] {
|
||||||
background-color: darkslateblue !important;
|
background-color: #483d8b !important;
|
||||||
|
background-color: var(--dark-primary) !important;
|
||||||
border-bottom: 1px solid #3c3c3c !important;
|
border-bottom: 1px solid #3c3c3c !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
.cbi-dropdown[open]>ul.dropdown>li.focus {
|
.cbi-dropdown[open]>ul.dropdown>li.focus {
|
||||||
background: darkslateblue;
|
background: #483d8b;
|
||||||
|
background: var(--dark-primary);
|
||||||
outline: none;
|
outline: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -767,7 +785,8 @@ input,
|
||||||
.cbi-button[value="Upload"],
|
.cbi-button[value="Upload"],
|
||||||
.cbi-button[value$="Apply"],
|
.cbi-button[value$="Apply"],
|
||||||
.cbi-button[onclick="addKey(event)"] {
|
.cbi-button[onclick="addKey(event)"] {
|
||||||
background: darkslateblue !important;
|
background: #483d8b !important;
|
||||||
|
background: var(--dark-primary) !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
.btn.primary,
|
.btn.primary,
|
||||||
|
@ -781,7 +800,8 @@ input,
|
||||||
.cbi-button[value="Scan"],
|
.cbi-button[value="Scan"],
|
||||||
.cbi-button[value^="Back"],
|
.cbi-button[value^="Back"],
|
||||||
.cbi-button-neutral[onclick="handleConfig(event)"] {
|
.cbi-button-neutral[onclick="handleConfig(event)"] {
|
||||||
background: darkslateblue;
|
background: #483d8b;
|
||||||
|
background: var(--dark-primary);
|
||||||
}
|
}
|
||||||
|
|
||||||
[data-page="admin-system-opkg"] h2 {
|
[data-page="admin-system-opkg"] h2 {
|
||||||
|
@ -805,4 +825,4 @@ input,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -7,13 +7,13 @@
|
||||||
Have a bug? Please create an issue here on GitHub!
|
Have a bug? Please create an issue here on GitHub!
|
||||||
https://github.com/jerrykuku/luci-theme-argon/issues
|
https://github.com/jerrykuku/luci-theme-argon/issues
|
||||||
|
|
||||||
luci-theme-material:
|
luci-theme-material:
|
||||||
Copyright 2015 Lutty Yang <lutty@wcan.in>
|
Copyright 2015 Lutty Yang <lutty@wcan.in>
|
||||||
|
|
||||||
Agron Theme
|
|
||||||
https://demos.creative-tim.com/argon-dashboard/index.html
|
|
||||||
|
|
||||||
Licensed to the public under the Apache License 2.0
|
Agron Theme
|
||||||
|
https://demos.creative-tim.com/argon-dashboard/index.html
|
||||||
|
|
||||||
|
Licensed to the public under the Apache License 2.0
|
||||||
-%>
|
-%>
|
||||||
|
|
||||||
<% local ver = require "luci.version" %>
|
<% local ver = require "luci.version" %>
|
||||||
|
@ -43,4 +43,4 @@
|
||||||
</script>
|
</script>
|
||||||
<script src="<%=media%>/js/script.js"></script>
|
<script src="<%=media%>/js/script.js"></script>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|
46
luci-theme-argon/luasrc/view/themes/argon/footer_login.htm
Normal file
|
@ -0,0 +1,46 @@
|
||||||
|
<%#
|
||||||
|
Argon is a clean HTML5 theme for LuCI. It is based on luci-theme-material Argon Template
|
||||||
|
|
||||||
|
luci-theme-argon
|
||||||
|
Copyright 2020 Jerrykuku <jerrykuku@qq.com>
|
||||||
|
|
||||||
|
Have a bug? Please create an issue here on GitHub!
|
||||||
|
https://github.com/jerrykuku/luci-theme-argon/issues
|
||||||
|
|
||||||
|
luci-theme-material:
|
||||||
|
Copyright 2015 Lutty Yang <lutty@wcan.in>
|
||||||
|
|
||||||
|
Agron Theme
|
||||||
|
https://demos.creative-tim.com/argon-dashboard/index.html
|
||||||
|
|
||||||
|
Licensed to the public under the Apache License 2.0
|
||||||
|
-%>
|
||||||
|
|
||||||
|
<% local ver = require "luci.version" %>
|
||||||
|
</div>
|
||||||
|
<footer class="mobile-hide">
|
||||||
|
<div>
|
||||||
|
<a class="luci-link" href="https://github.com/openwrt/luci">Powered by <%= ver.luciname %> (<%= ver.luciversion %>)</a> /
|
||||||
|
<a href="https://github.com/jerrykuku/luci-theme-argon">ArgonTheme <%# vPKG_VERSION %></a> /
|
||||||
|
<%= ver.distversion %>
|
||||||
|
<ul class="breadcrumb pull-right" id="modemenu" style="display:none"></ul>
|
||||||
|
</div>
|
||||||
|
</footer>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<script>
|
||||||
|
// thanks for Jo-Philipp Wich <jow@openwrt.org>
|
||||||
|
var luciLocation = <%= luci.http.write_json(luci.dispatcher.context.path) %>;
|
||||||
|
var winHeight = $(window).height();
|
||||||
|
$(window).resize(function () {
|
||||||
|
var winWidth = $(window).width()
|
||||||
|
if(winWidth < 600){
|
||||||
|
var newHeight = $(this).height();
|
||||||
|
var keyboradHeight = newHeight - winHeight;
|
||||||
|
$(".ftc").css("bottom", keyboradHeight + 30);
|
||||||
|
}
|
||||||
|
})
|
||||||
|
</script>
|
||||||
|
<script src="<%=media%>/js/script.js"></script>
|
||||||
|
</body>
|
||||||
|
</html>
|
|
@ -5,19 +5,19 @@
|
||||||
Copyright 2020 Jerrykuku <jerrykuku@qq.com>
|
Copyright 2020 Jerrykuku <jerrykuku@qq.com>
|
||||||
|
|
||||||
Have a bug? Please create an issue here on GitHub!
|
Have a bug? Please create an issue here on GitHub!
|
||||||
https://github.com/jerrykuku/luci-theme-argon/issues
|
https://github.com/jerrykuku/luci-theme-argon/issues
|
||||||
|
|
||||||
luci-theme-material:
|
luci-theme-material:
|
||||||
Copyright 2015 Lutty Yang <lutty@wcan.in>
|
Copyright 2015 Lutty Yang <lutty@wcan.in>
|
||||||
|
|
||||||
Agron Theme
|
Argon Theme
|
||||||
https://demos.creative-tim.com/argon-dashboard/index.html
|
https://demos.creative-tim.com/argon-dashboard/index.html
|
||||||
|
|
||||||
Licensed to the public under the Apache License 2.0
|
Licensed to the public under the Apache License 2.0
|
||||||
-%>
|
-%>
|
||||||
|
|
||||||
<%
|
<%
|
||||||
local sys = require "luci.sys"
|
local sys = require "luci.sys"
|
||||||
local util = require "luci.util"
|
local util = require "luci.util"
|
||||||
local http = require "luci.http"
|
local http = require "luci.http"
|
||||||
local disp = require "luci.dispatcher"
|
local disp = require "luci.dispatcher"
|
||||||
|
@ -25,42 +25,87 @@
|
||||||
local boardinfo = util.ubus("system", "board")
|
local boardinfo = util.ubus("system", "board")
|
||||||
|
|
||||||
local node = disp.context.dispatched
|
local node = disp.context.dispatched
|
||||||
|
|
||||||
local fs = require "nixio.fs"
|
local fs = require "nixio.fs"
|
||||||
local nutil = require "nixio.util"
|
local nutil = require "nixio.util"
|
||||||
|
local uci = require 'luci.model.uci'.cursor()
|
||||||
|
|
||||||
-- send as HTML5
|
-- send as HTML5
|
||||||
http.prepare_content("text/html")
|
http.prepare_content("text/html")
|
||||||
math.randomseed(os.time())
|
|
||||||
|
math.randomseed(os.time())
|
||||||
|
|
||||||
|
-- Custom settings
|
||||||
|
local mode = 'normal'
|
||||||
|
local dark_css = fs.readfile('/www/luci-static/argon/css/dark.css')
|
||||||
|
local bar_color = '#5e72e4'
|
||||||
|
local primary, dark_primary, blur_radius, blur_radius_dark, blur_opacity
|
||||||
|
if fs.access('/etc/config/argon') then
|
||||||
|
primary = uci:get_first('argon', 'global', 'primary')
|
||||||
|
dark_primary = uci:get_first('argon', 'global', 'dark_primary')
|
||||||
|
blur_radius = uci:get_first('argon', 'global', 'blur')
|
||||||
|
blur_radius_dark = uci:get_first('argon', 'global', 'blur_dark')
|
||||||
|
blur_opacity = uci:get_first('argon', 'global', 'transparency')
|
||||||
|
blur_opacity_dark = uci:get_first('argon', 'global', 'transparency_dark')
|
||||||
|
mode = uci:get_first('argon', 'global', 'mode')
|
||||||
|
bar_color = mode == 'dark' and dark_primary or primary
|
||||||
|
end
|
||||||
|
|
||||||
|
-- Brand name
|
||||||
|
local brand_name = boardinfo.hostname or "?"
|
||||||
-%>
|
-%>
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="<%=luci.i18n.context.lang%>">
|
<html lang="<%=luci.i18n.context.lang%>">
|
||||||
|
|
||||||
<head>
|
<head>
|
||||||
<meta charset="utf-8">
|
<meta charset="utf-8">
|
||||||
<title>
|
<title>
|
||||||
<%=striptags( (boardinfo.hostname or "?") .. ( (node and node.title) and ' - ' .. translate(node.title) or '')) %>
|
<%=striptags( (boardinfo.hostname or "?") .. ( (node and node.title) and ' - ' .. translate(node.title) or '')) %>
|
||||||
- LuCI</title>
|
- LuCI</title>
|
||||||
<meta content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0" name="viewport" />
|
<meta content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0" name="viewport" />
|
||||||
<meta name="format-detection" content="telephone=no, email=no" />
|
<meta name="format-detection" content="telephone=no, email=no" />
|
||||||
<meta name="apple-mobile-web-app-capable" content="yes">
|
<meta name="apple-mobile-web-app-capable" content="yes">
|
||||||
<meta name="mobile-web-app-capable" content="yes">
|
<meta name="mobile-web-app-capable" content="yes">
|
||||||
<meta name="x5-fullscreen" content="true">
|
<meta name="x5-fullscreen" content="true">
|
||||||
<meta name="full-screen" content="yes">
|
<meta name="full-screen" content="yes">
|
||||||
<meta name="x5-page-mode" content="app">
|
<meta name="x5-page-mode" content="app">
|
||||||
<meta name="browsermode" content="application">
|
<meta name="browsermode" content="application">
|
||||||
<meta name="msapplication-tap-highlight" content="no">
|
<meta name="msapplication-tap-highlight" content="no">
|
||||||
<meta name="msapplication-TileColor" content="#5e72e4">
|
<meta name="msapplication-TileColor" content="<%=bar_color%>">
|
||||||
<meta name="application-name" content="<%=striptags( (boardinfo.hostname or "?") ) %> - LuCI">
|
<meta name="application-name" content="<%=striptags( (boardinfo.hostname or "?") ) %> - LuCI">
|
||||||
<meta name="apple-mobile-web-app-title" content="<%=striptags( (boardinfo.hostname or "?") ) %> - LuCI">
|
<meta name="apple-mobile-web-app-title" content="<%=striptags( (boardinfo.hostname or "?") ) %> - LuCI">
|
||||||
<link rel="shortcut icon" type="image/png" href="<%=media%>/icon/favicon.png">
|
<link rel="apple-touch-icon" sizes="60x60" href="<%=media%>/icon/apple-icon-60x60.png">
|
||||||
<link rel="manifest" href="<%=media%>/icon/manifest.json">
|
<link rel="apple-touch-icon" sizes="72x72" href="<%=media%>/icon/apple-icon-72x72.png">
|
||||||
<meta name="msapplication-TileColor" content="#5e72e4">
|
<link rel="apple-touch-icon" sizes="144x144" href="<%=media%>/icon/apple-icon-144x144.png">
|
||||||
<meta name="theme-color" content="#5e72e4">
|
<link rel="icon" type="image/png" sizes="192x192" href="<%=media%>/icon/android-icon-192x192.png">
|
||||||
<link rel="stylesheet" href="<%=media%>/css/cascade.css?v=<%=math.random(1,100000)%>">
|
<link rel="icon" type="image/png" sizes="32x32" href="<%=media%>/icon/favicon-32x32.png">
|
||||||
<% if nixio.fs.access("/etc/dark") then %>
|
<link rel="icon" type="image/png" sizes="96x96" href="<%=media%>/icon/favicon-96x96.png">
|
||||||
<link rel="stylesheet" href="<%=media%>/css/dark.css?v=<%=math.random(1,100000)%>">
|
<link rel="icon" type="image/png" sizes="16x16" href="<%=media%>/icon/favicon-16x16.png">
|
||||||
<% end -%>
|
<link rel="manifest" href="<%=media%>/icon/manifest.json">
|
||||||
|
<meta name="msapplication-TileColor" content="<%=bar_color%>">
|
||||||
|
<meta name="msapplication-TileImage" content="<%=media%>/icon/ms-icon-144x144.png">
|
||||||
|
<meta name="theme-color" content="<%=bar_color%>">
|
||||||
|
<link rel="stylesheet" href="<%=media%>/css/cascade.css?v=<%=math.random(1,100000)%>">
|
||||||
|
<style title="text/css">
|
||||||
|
<% if mode == 'normal' then %>
|
||||||
|
@media (prefers-color-scheme: dark) {
|
||||||
|
<%=dark_css%>
|
||||||
|
}
|
||||||
|
<% elseif mode == 'dark' then %>
|
||||||
|
<%=dark_css%>
|
||||||
|
<% end -%>
|
||||||
|
<% if fs.access('/etc/config/argon') then %>
|
||||||
|
:root {
|
||||||
|
--primary: <%=primary%>;
|
||||||
|
--dark-primary: <%=dark_primary%>;
|
||||||
|
--blur-radius:<%=blur_radius%>px;
|
||||||
|
--blur-opacity:<%=blur_opacity%>;
|
||||||
|
--blur-radius-dark:<%=blur_radius_dark%>px;
|
||||||
|
--blur-opacity-dark:<%=blur_opacity_dark%>;
|
||||||
|
}
|
||||||
|
<% end -%>
|
||||||
|
</style>
|
||||||
|
<link rel="shortcut icon" href="<%=media%>/favicon.ico">
|
||||||
<% if node and node.css then %>
|
<% if node and node.css then %>
|
||||||
<link rel="stylesheet" href="<%=resource%>/<%=node.css%>">
|
<link rel="stylesheet" href="<%=resource%>/<%=node.css%>">
|
||||||
<% end -%>
|
<% end -%>
|
||||||
|
@ -69,136 +114,110 @@
|
||||||
<%=css %>
|
<%=css %>
|
||||||
</style>
|
</style>
|
||||||
<% end -%>
|
<% end -%>
|
||||||
<script src="<%=url('admin/translations', luci.i18n.context.lang)%><%# ?v=PKG_VERSION %>"></script>
|
<script src="<%=media%>/js/polyfill.min.js"></script>
|
||||||
<script src="<%=resource%>/cbi.js<%# ?v=PKG_VERSION %>"></script>
|
<script src="<%=url('admin/translations', luci.i18n.context.lang)%>?v=2.2.4"></script>
|
||||||
<script src="<%=resource%>/luci.js<%# ?v=PKG_VERSION %>"></script>
|
<script src="<%=resource%>/cbi.js?v=2.2.4"></script>
|
||||||
<script src="<%=media%>/js/jquery.min.js<%# ?v=PKG_VERSION %>"></script>
|
<script src="<%=resource%>/luci.js?v=2.2.4"></script>
|
||||||
<script type="text/javascript">//<![CDATA[
|
<script src="<%=media%>/js/jquery.min.js?v=2.2.4"></script>
|
||||||
(function () {
|
<script type="text/javascript">//<![CDATA[
|
||||||
|
function EF() { return L.dom.create.apply(L.dom, arguments) }
|
||||||
|
(function() {
|
||||||
function get_children(node) {
|
function get_children(node) {
|
||||||
var children = [];
|
var children = [];
|
||||||
|
|
||||||
for (var k in node.children) {
|
for (var k in node.children) {
|
||||||
if (!node.children.hasOwnProperty(k))
|
if (!node.children.hasOwnProperty(k))
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
if (!node.children[k].satisfied)
|
if (!node.children[k].satisfied)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
if (!node.children[k].hasOwnProperty('title'))
|
if (!node.children[k].hasOwnProperty('title'))
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
children.push(Object.assign(node.children[k], { name: k }));
|
children.push(Object.assign(node.children[k], { name: k }));
|
||||||
}
|
}
|
||||||
|
return children.sort(function(a, b) {
|
||||||
return children.sort(function (a, b) {
|
|
||||||
return ((a.order || 1000) - (b.order || 1000));
|
return ((a.order || 1000) - (b.order || 1000));
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
function render_mainmenu(tree, url, level) {
|
function render_mainmenu(tree, url, level) {
|
||||||
var l = (level || 0) + 1,
|
var l = (level || 0) + 1,
|
||||||
ul = E('ul', { 'class': level ? 'slide-menu' : 'nav' }),
|
ul = EF('ul', { 'class': level ? 'slide-menu' : 'nav' }),
|
||||||
children = get_children(tree);
|
children = get_children(tree);
|
||||||
if (children.length == 0 || l > 2)
|
if (children.length == 0 || l > 2)
|
||||||
return E([]);
|
return EF([]);
|
||||||
|
|
||||||
for (var i = 0; i < children.length; i++) {
|
for (var i = 0; i < children.length; i++) {
|
||||||
var submenu = render_mainmenu(children[i], url + '/' + children[i].name, l),
|
var submenu = render_mainmenu(children[i], url + '/' + children[i].name, l),
|
||||||
hasChildren = submenu.children.length;
|
hasChildren = submenu.children.length;
|
||||||
isLogout = (children[i].name == 'logout');
|
ul.appendChild(EF('li', { 'class': hasChildren ? 'slide' : null }, [
|
||||||
ul.appendChild(E('li', { 'class': hasChildren ? 'slide' : isLogout ? 'lg' : null }, [
|
EF('a', {
|
||||||
E('a', {
|
|
||||||
'href': hasChildren ? '#' : L.url(url, children[i].name),
|
'href': hasChildren ? '#' : L.url(url, children[i].name),
|
||||||
'class': hasChildren ? 'menu' : isLogout ? "logout" : null,
|
'class': hasChildren ? 'menu' : null,
|
||||||
'data-title': children[i].title.replace(" ", "_"),
|
'data-title': hasChildren ? children[i].title.replace(" ", "_") : children[i].title.replace(" ", "_"),
|
||||||
}, [_(children[i].title)]),
|
}, [ _(children[i].title) ]),
|
||||||
submenu
|
submenu
|
||||||
]));
|
]));
|
||||||
}
|
}
|
||||||
|
|
||||||
if (l == 1) {
|
if (l == 1) {
|
||||||
var container = document.querySelector('#mainmenu');
|
var container = document.querySelector('#mainmenu');
|
||||||
|
|
||||||
container.appendChild(ul);
|
container.appendChild(ul);
|
||||||
container.style.display = '';
|
container.style.display = '';
|
||||||
}
|
}
|
||||||
|
|
||||||
return ul;
|
return ul;
|
||||||
}
|
}
|
||||||
|
|
||||||
function render_modemenu(tree) {
|
function render_modemenu(tree) {
|
||||||
var ul = document.querySelector('#modemenu'),
|
var ul = document.querySelector('#modemenu'),
|
||||||
children = get_children(tree);
|
children = get_children(tree);
|
||||||
|
|
||||||
for (var i = 0; i < children.length; i++) {
|
for (var i = 0; i < children.length; i++) {
|
||||||
var isActive = (L.env.requestpath.length ? children[i].name == L.env.requestpath[0] : i == 0);
|
var isActive = (L.env.requestpath.length ? children[i].name == L.env.requestpath[0] : i == 0);
|
||||||
|
ul.appendChild(EF('li', {}, [
|
||||||
ul.appendChild(E('li', {}, [
|
EF('a', {
|
||||||
E('a', {
|
|
||||||
'href': L.url(children[i].name),
|
'href': L.url(children[i].name),
|
||||||
'class': isActive ? 'active' : null
|
'class': isActive ? 'active' : null
|
||||||
}, [_(children[i].title)])
|
}, [ _(children[i].title) ])
|
||||||
]));
|
]));
|
||||||
|
|
||||||
if (isActive)
|
if (isActive)
|
||||||
render_mainmenu(children[i], children[i].name);
|
render_mainmenu(children[i], children[i].name);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (ul.children.length > 1)
|
if (ul.children.length > 1)
|
||||||
ul.style.display = '';
|
ul.style.display = '';
|
||||||
}
|
}
|
||||||
|
|
||||||
function render_tabmenu(tree, url, level) {
|
function render_tabmenu(tree, url, level) {
|
||||||
var container = document.querySelector('#tabmenu'),
|
var container = document.querySelector('#tabmenu'),
|
||||||
l = (level || 0) + 1,
|
l = (level || 0) + 1,
|
||||||
ul = E('ul', { 'class': 'tabs' }),
|
ul = EF('ul', { 'class': 'tabs' }),
|
||||||
children = get_children(tree),
|
children = get_children(tree),
|
||||||
activeNode = null;
|
activeNode = null;
|
||||||
|
|
||||||
if (children.length == 0)
|
if (children.length == 0)
|
||||||
return E([]);
|
return EF([]);
|
||||||
|
|
||||||
for (var i = 0; i < children.length; i++) {
|
for (var i = 0; i < children.length; i++) {
|
||||||
var isActive = (L.env.dispatchpath[l + 2] == children[i].name),
|
var isActive = (L.env.dispatchpath[l + 2] == children[i].name),
|
||||||
activeClass = isActive ? ' active' : '',
|
activeClass = isActive ? ' active' : '',
|
||||||
className = 'tabmenu-item-%s %s'.format(children[i].name, activeClass);
|
className = 'tabmenu-item-%s %s'.format(children[i].name, activeClass);
|
||||||
|
ul.appendChild(EF('li', { 'class': className }, [
|
||||||
ul.appendChild(E('li', { 'class': className }, [
|
EF('a', { 'href': L.url(url, children[i].name) }, [ _(children[i].title) ] )
|
||||||
E('a', { 'href': L.url(url, children[i].name) }, [_(children[i].title)])
|
|
||||||
]));
|
]));
|
||||||
|
|
||||||
if (isActive)
|
if (isActive)
|
||||||
activeNode = children[i];
|
activeNode = children[i];
|
||||||
}
|
}
|
||||||
|
|
||||||
container.appendChild(ul);
|
container.appendChild(ul);
|
||||||
container.style.display = '';
|
container.style.display = '';
|
||||||
|
|
||||||
if (activeNode)
|
if (activeNode)
|
||||||
container.appendChild(render_tabmenu(activeNode, url + '/' + activeNode.name, l));
|
container.appendChild(render_tabmenu(activeNode, url + '/' + activeNode.name, l));
|
||||||
|
|
||||||
return ul;
|
return ul;
|
||||||
}
|
}
|
||||||
|
document.addEventListener('luci-loaded', function(ev) {
|
||||||
document.addEventListener('luci-loaded', function (ev) {
|
var tree = <%= luci.http.write_json(luci.dispatcher.menu_json() or {}) %>,
|
||||||
var tree = <%= luci.http.write_json(luci.dispatcher.menu_json() or { }) %>,
|
node = tree,
|
||||||
node = tree,
|
url = '';
|
||||||
url = '';
|
render_modemenu(tree);
|
||||||
|
if (L.env.dispatchpath.length >= 3) {
|
||||||
render_modemenu(tree);
|
for (var i = 0; i < 3 && node; i++) {
|
||||||
|
node = node.children[L.env.dispatchpath[i]];
|
||||||
if (L.env.dispatchpath.length >= 3) {
|
url = url + (url ? '/' : '') + L.env.dispatchpath[i];
|
||||||
for (var i = 0; i < 3 && node; i++) {
|
}
|
||||||
node = node.children[L.env.dispatchpath[i]];
|
if (node)
|
||||||
url = url + (url ? '/' : '') + L.env.dispatchpath[i];
|
render_tabmenu(node, url);
|
||||||
}
|
}
|
||||||
|
});
|
||||||
if (node)
|
})();
|
||||||
render_tabmenu(node, url);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}) ();
|
|
||||||
//]]></script>
|
//]]></script>
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
|
@ -209,7 +228,7 @@
|
||||||
<div class="main">
|
<div class="main">
|
||||||
<div class="main-left" id="mainmenu" style="display:none">
|
<div class="main-left" id="mainmenu" style="display:none">
|
||||||
<div class="sidenav-header d-flex align-items-center">
|
<div class="sidenav-header d-flex align-items-center">
|
||||||
<a class="brand" href="#"><%=boardinfo.hostname or "?"%></a>
|
<a class="brand" href="#"><%=brand_name%></a>
|
||||||
<div class="ml-auto">
|
<div class="ml-auto">
|
||||||
<!-- Sidenav toggler -->
|
<!-- Sidenav toggler -->
|
||||||
<div class="sidenav-toggler d-none d-xl-block active" data-action="sidenav-unpin"
|
<div class="sidenav-toggler d-none d-xl-block active" data-action="sidenav-unpin"
|
||||||
|
@ -228,7 +247,7 @@
|
||||||
<div class="fill">
|
<div class="fill">
|
||||||
<div class="container">
|
<div class="container">
|
||||||
<a class="showSide"></a>
|
<a class="showSide"></a>
|
||||||
<a class="brand" href="#"><%=boardinfo.hostname or "?"%> ™</a>
|
<a class="brand" href="#"><%=brand_name%></a>
|
||||||
<div class="status" id="indicators">
|
<div class="status" id="indicators">
|
||||||
<span id="xhr_poll_status" style="display:none" onclick="XHR.running() ? XHR.halt() : XHR.run()">
|
<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 success" id="xhr_poll_status_on"><span class="mobile-hide"><%:Auto Refresh%></span> <%:on%></span>
|
||||||
|
@ -244,7 +263,7 @@
|
||||||
<%- if luci.sys.process.info("uid") == 0 and luci.sys.user.getuser("root") and not luci.sys.user.getpasswd("root") then -%>
|
<%- if luci.sys.process.info("uid") == 0 and luci.sys.user.getuser("root") and not luci.sys.user.getpasswd("root") then -%>
|
||||||
<div class="alert-message error">
|
<div class="alert-message error">
|
||||||
<h4><%:No password set!%></h4>
|
<h4><%:No password set!%></h4>
|
||||||
<p><%:There is no password set on this router. Please configure a root password to protect the web interface and enable SSH.%>
|
<p><%:There is no password set on this router. Please configure a root password to protect the web interface.%>
|
||||||
</p>
|
</p>
|
||||||
<% if disp.lookup("admin/system/admin") then %>
|
<% if disp.lookup("admin/system/admin") then %>
|
||||||
<div class="right"><a class="btn"
|
<div class="right"><a class="btn"
|
||||||
|
|
|
@ -1,36 +1,55 @@
|
||||||
<%#
|
<%#
|
||||||
edge is a clean HTML5 theme for LuCI. It is based on luci-theme-material edge Template
|
Argon is a clean HTML5 theme for LuCI. It is based on luci-theme-material Argon Template
|
||||||
|
|
||||||
luci-theme-edge
|
luci-theme-argon
|
||||||
Copyright 2020 Jerrykuku <jerrykuku@qq.com>
|
Copyright 2020 Jerrykuku <jerrykuku@qq.com>
|
||||||
|
|
||||||
Have a bug? Please create an issue here on GitHub!
|
Have a bug? Please create an issue here on GitHub!
|
||||||
https://github.com/jerrykuku/luci-theme-edge/issues
|
https://github.com/jerrykuku/luci-theme-argon/issues
|
||||||
|
|
||||||
luci-theme-material:
|
luci-theme-material:
|
||||||
Copyright 2015 Lutty Yang <lutty@wcan.in>
|
Copyright 2015 Lutty Yang <lutty@wcan.in>
|
||||||
|
|
||||||
Agron Theme
|
Argon Theme
|
||||||
https://demos.creative-tim.com/edge-dashboard/index.html
|
https://demos.creative-tim.com/argon-dashboard/index.html
|
||||||
|
|
||||||
Licensed to the public under the Apache License 2.0
|
Licensed to the public under the Apache License 2.0
|
||||||
-%>
|
-%>
|
||||||
|
|
||||||
<%
|
<%
|
||||||
local sys = require "luci.sys"
|
local sys = require "luci.sys"
|
||||||
local util = require "luci.util"
|
local util = require "luci.util"
|
||||||
local http = require "luci.http"
|
local http = require "luci.http"
|
||||||
local disp = require "luci.dispatcher"
|
local disp = require "luci.dispatcher"
|
||||||
|
|
||||||
local boardinfo = util.ubus("system", "board")
|
local boardinfo = util.ubus("system", "board")
|
||||||
|
|
||||||
local node = disp.context.dispatched
|
local node = disp.context.dispatched
|
||||||
local fs = require "nixio.fs"
|
|
||||||
|
local fs = require "nixio.fs"
|
||||||
local nutil = require "nixio.util"
|
local nutil = require "nixio.util"
|
||||||
|
local uci = require 'luci.model.uci'.cursor()
|
||||||
|
|
||||||
-- send as HTML5
|
-- send as HTML5
|
||||||
http.prepare_content("text/html")
|
http.prepare_content("text/html")
|
||||||
|
|
||||||
math.randomseed(tonumber(tostring(os.time()):reverse():sub(1, 9)))
|
math.randomseed(tonumber(tostring(os.time()):reverse():sub(1, 9)))
|
||||||
|
|
||||||
|
-- Custom settings
|
||||||
|
local mode = 'normal'
|
||||||
|
local dark_css = fs.readfile('/www/luci-static/argon/css/dark.css')
|
||||||
|
local bar_color = '#5e72e4'
|
||||||
|
local primary, dark_primary, blur_radius, blur_radius_dark, blur_opacity
|
||||||
|
if fs.access('/etc/config/argon') then
|
||||||
|
primary = uci:get_first('argon', 'global', 'primary')
|
||||||
|
dark_primary = uci:get_first('argon', 'global', 'dark_primary')
|
||||||
|
blur_radius = uci:get_first('argon', 'global', 'blur')
|
||||||
|
blur_radius_dark = uci:get_first('argon', 'global', 'blur_dark')
|
||||||
|
blur_opacity = uci:get_first('argon', 'global', 'transparency')
|
||||||
|
blur_opacity_dark = uci:get_first('argon', 'global', 'transparency_dark')
|
||||||
|
mode = uci:get_first('argon', 'global', 'mode')
|
||||||
|
bar_color = mode == 'dark' and dark_primary or primary
|
||||||
|
end
|
||||||
-%>
|
-%>
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="<%=luci.i18n.context.lang%>">
|
<html lang="<%=luci.i18n.context.lang%>">
|
||||||
|
@ -49,17 +68,41 @@
|
||||||
<meta name="x5-page-mode" content="app">
|
<meta name="x5-page-mode" content="app">
|
||||||
<meta name="browsermode" content="application">
|
<meta name="browsermode" content="application">
|
||||||
<meta name="msapplication-tap-highlight" content="no">
|
<meta name="msapplication-tap-highlight" content="no">
|
||||||
<meta name="msapplication-TileColor" content="#5e72e4">
|
<meta name="msapplication-TileColor" content="<%=bar_color%>">
|
||||||
<meta name="application-name" content="<%=striptags( (boardinfo.hostname or "?") ) %> - LuCI">
|
<meta name="application-name" content="<%=striptags( (boardinfo.hostname or "?") ) %> - LuCI">
|
||||||
<meta name="apple-mobile-web-app-title" content="<%=striptags( (boardinfo.hostname or "?") ) %> - LuCI">
|
<meta name="apple-mobile-web-app-title" content="<%=striptags( (boardinfo.hostname or "?") ) %> - LuCI">
|
||||||
<link rel="shortcut icon" type="image/png" href="<%=media%>/icon/favicon.png">
|
<link rel="apple-touch-icon" sizes="60x60" href="<%=media%>/icon/apple-icon-60x60.png">
|
||||||
|
<link rel="apple-touch-icon" sizes="72x72" href="<%=media%>/icon/apple-icon-72x72.png">
|
||||||
|
<link rel="apple-touch-icon" sizes="144x144" href="<%=media%>/icon/apple-icon-144x144.png">
|
||||||
|
<link rel="icon" type="image/png" sizes="192x192" href="<%=media%>/icon/android-icon-192x192.png">
|
||||||
|
<link rel="icon" type="image/png" sizes="32x32" href="<%=media%>/icon/favicon-32x32.png">
|
||||||
|
<link rel="icon" type="image/png" sizes="96x96" href="<%=media%>/icon/favicon-96x96.png">
|
||||||
|
<link rel="icon" type="image/png" sizes="16x16" href="<%=media%>/icon/favicon-16x16.png">
|
||||||
<link rel="manifest" href="<%=media%>/icon/manifest.json">
|
<link rel="manifest" href="<%=media%>/icon/manifest.json">
|
||||||
<meta name="msapplication-TileColor" content="#5e72e4">
|
<meta name="msapplication-TileColor" content="<%=bar_color%>">
|
||||||
<meta name="theme-color" content="#5e72e4">
|
<meta name="msapplication-TileImage" content="<%=media%>/icon/ms-icon-144x144.png">
|
||||||
|
<meta name="theme-color" content="<%=bar_color%>">
|
||||||
<link rel="stylesheet" href="<%=media%>/css/cascade.css?v=<%=math.random(1,100000)%>">
|
<link rel="stylesheet" href="<%=media%>/css/cascade.css?v=<%=math.random(1,100000)%>">
|
||||||
<% if nixio.fs.access("/etc/dark") then %>
|
<style title="text/css">
|
||||||
<link rel="stylesheet" href="<%=media%>/css/dark.css?v=<%=math.random(1,100000)%>">
|
<% if mode == 'normal' then %>
|
||||||
<% end -%>
|
@media (prefers-color-scheme: dark) {
|
||||||
|
<%=dark_css%>
|
||||||
|
}
|
||||||
|
<% elseif mode == 'dark' then %>
|
||||||
|
<%=dark_css%>
|
||||||
|
<% end -%>
|
||||||
|
<% if fs.access('/etc/config/argon') then %>
|
||||||
|
:root {
|
||||||
|
--primary: <%=primary%>;
|
||||||
|
--dark-primary: <%=dark_primary%>;
|
||||||
|
--blur-radius:<%=blur_radius%>px;
|
||||||
|
--blur-opacity:<%=blur_opacity%>;
|
||||||
|
--blur-radius-dark:<%=blur_radius_dark%>px;
|
||||||
|
--blur-opacity-dark:<%=blur_opacity_dark%>;
|
||||||
|
}
|
||||||
|
<% end -%>
|
||||||
|
</style>
|
||||||
|
<link rel="shortcut icon" href="<%=media%>/favicon.ico">
|
||||||
<% if node and node.css then %>
|
<% if node and node.css then %>
|
||||||
<link rel="stylesheet" href="<%=resource%>/<%=node.css%>">
|
<link rel="stylesheet" href="<%=resource%>/<%=node.css%>">
|
||||||
<% end -%>
|
<% end -%>
|
||||||
|
@ -72,10 +115,9 @@
|
||||||
<script src="<%=resource%>/cbi.js<%# ?v=PKG_VERSION %>"></script>
|
<script src="<%=resource%>/cbi.js<%# ?v=PKG_VERSION %>"></script>
|
||||||
<script src="<%=resource%>/xhr.js<%# ?v=PKG_VERSION %>"></script>
|
<script src="<%=resource%>/xhr.js<%# ?v=PKG_VERSION %>"></script>
|
||||||
<script src="<%=media%>/js/jquery.min.js<%# ?v=PKG_VERSION %>"></script>
|
<script src="<%=media%>/js/jquery.min.js<%# ?v=PKG_VERSION %>"></script>
|
||||||
|
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
<body
|
<body
|
||||||
class="lang_<%=luci.i18n.context.lang%> <% if node then %><%= striptags( node.title ) %><% end %> <% if luci.dispatcher.context.authsession then %>logged-in<% end %>"
|
class="lang_<%=luci.i18n.context.lang%> <% if node then %><%= striptags( node.title ) %><% end %> <% if luci.dispatcher.context.authsession then %>logged-in<% end %>"
|
||||||
data-page="<%= table.concat(disp.context.requestpath, "-") %>">
|
data-page="<%= table.concat(disp.context.requestpath, "-") %>">
|
||||||
|
|
|
@ -0,0 +1,27 @@
|
||||||
|
<%#
|
||||||
|
Copyright 2008 Steven Barth <steven@midlink.org>
|
||||||
|
Copyright 2008-2019 Jo-Philipp Wich <jo@mein.io>
|
||||||
|
Licensed to the public under the Apache License 2.0.
|
||||||
|
-%>
|
||||||
|
|
||||||
|
<%
|
||||||
|
local is_rollback_pending, rollback_time_remaining, rollback_session, rollback_token = luci.model.uci:rollback_pending()
|
||||||
|
|
||||||
|
if is_rollback_pending or trigger_apply or trigger_revert then
|
||||||
|
%>
|
||||||
|
<script type="text/javascript">
|
||||||
|
document.addEventListener("luci-loaded", function() {
|
||||||
|
<% if trigger_apply then -%>
|
||||||
|
L.ui.changes.apply(true);
|
||||||
|
<%- elseif trigger_revert then -%>
|
||||||
|
L.ui.changes.revert();
|
||||||
|
<%- else -%>
|
||||||
|
L.ui.changes.confirm(true, Date.now() + <%=rollback_time_remaining%> * 1000, <%=luci.http.write_json(rollback_token)%>);
|
||||||
|
<%- end %>
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
<%
|
||||||
|
end
|
||||||
|
|
||||||
|
include("themes/" .. theme .. "/footer_login")
|
||||||
|
%>
|
|
@ -13,8 +13,8 @@
|
||||||
local applyconf = luci.config and luci.config.apply
|
local applyconf = luci.config and luci.config.apply
|
||||||
%>
|
%>
|
||||||
|
|
||||||
<script type="text/javascript" src="<%=resource%>/promis.min.js?v=git-20.186.82389-282dbf8"></script>
|
<script type="text/javascript" src="<%=resource%>/promis.min.js"></script>
|
||||||
<script type="text/javascript" src="<%=resource%>/luci.js?v=git-20.186.82389-282dbf8"></script>
|
<script type="text/javascript" src="<%=resource%>/luci.js"></script>
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
L = new LuCI(<%= luci.http.write_json({
|
L = new LuCI(<%= luci.http.write_json({
|
||||||
token = token,
|
token = token,
|
||||||
|
@ -29,7 +29,7 @@
|
||||||
ubuspath = luci.config.main.ubuspath or '/ubus/',
|
ubuspath = luci.config.main.ubuspath or '/ubus/',
|
||||||
sessionid = luci.dispatcher.context.authsession,
|
sessionid = luci.dispatcher.context.authsession,
|
||||||
nodespec = luci.dispatcher.context.dispatched,
|
nodespec = luci.dispatcher.context.dispatched,
|
||||||
apply_rollback = math.max(applyconf and applyconf.rollback or 30, 30),
|
apply_rollback = math.max(applyconf and applyconf.rollback or 90, 90),
|
||||||
apply_holdoff = math.max(applyconf and applyconf.holdoff or 4, 1),
|
apply_holdoff = math.max(applyconf and applyconf.holdoff or 4, 1),
|
||||||
apply_timeout = math.max(applyconf and applyconf.timeout or 5, 1),
|
apply_timeout = math.max(applyconf and applyconf.timeout or 5, 1),
|
||||||
apply_display = math.max(applyconf and applyconf.display or 1.5, 1),
|
apply_display = math.max(applyconf and applyconf.display or 1.5, 1),
|
||||||
|
|
|
@ -14,18 +14,18 @@
|
||||||
|
|
||||||
MUI:
|
MUI:
|
||||||
https://github.com/muicss/mui
|
https://github.com/muicss/mui
|
||||||
|
|
||||||
Agron Theme
|
Argon Theme
|
||||||
https://demos.creative-tim.com/argon-dashboard/index.html
|
https://demos.creative-tim.com/argon-dashboard/index.html
|
||||||
|
|
||||||
Licensed to the public under the Apache License 2.0
|
Licensed to the public under the Apache License 2.0
|
||||||
-%>
|
-%>
|
||||||
|
|
||||||
<%+header_login%>
|
<%+themes/argon/out_header_login%>
|
||||||
<%
|
<%
|
||||||
local util = require "luci.util"
|
local util = require "luci.util"
|
||||||
local boardinfo = util.ubus("system", "board")
|
local boardinfo = util.ubus("system", "board")
|
||||||
local fs = require "nixio.fs"
|
local fs = require "nixio.fs"
|
||||||
local nutil = require "nixio.util"
|
local nutil = require "nixio.util"
|
||||||
|
|
||||||
function glob(...)
|
function glob(...)
|
||||||
|
@ -60,7 +60,7 @@
|
||||||
end
|
end
|
||||||
|
|
||||||
if bgcount > 0 then
|
if bgcount > 0 then
|
||||||
currentBg = bgs[math.random(1,bgcount)]
|
currentBg = bgs[math.random(1,bgcount)]
|
||||||
end
|
end
|
||||||
%>
|
%>
|
||||||
<div class="login-page">
|
<div class="login-page">
|
||||||
|
@ -82,25 +82,23 @@
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
</script>
|
</script>
|
||||||
<% else %>
|
<% else
|
||||||
<div class="main-bg" id="main-bg"
|
local bg_url = media .. "/img/bg1.jpg"
|
||||||
<%
|
local bing = "123"
|
||||||
if (bgcount == 0 ) then
|
if (bgcount == 0 ) then
|
||||||
local http = require "luci.sys"
|
local sys = require "luci.sys"
|
||||||
local json = require "luci.jsonc"
|
local json = require "luci.jsonc"
|
||||||
local bg_url = media .. "/img/bg1.jpg"
|
local remote_bg_url="http://www.bing.com/HPImageArchive.aspx?format=js&idx=0&n=1&mkt=en-US"
|
||||||
local bing = http.httpget("http://www.bing.com/HPImageArchive.aspx?format=js&idx=0&n=1&mkt=en-US")
|
--bing = sys.httpget(remote_bg_url)
|
||||||
|
bing = sys.exec("wget --timeout=0.5 -qO- '%s'" %remote_bg_url)
|
||||||
if (bing and bing ~= '') then
|
if (bing and bing ~= '') then
|
||||||
local bingjson = json.parse(bing)
|
bg_url = "https://www.bing.com" .. json.parse(bing).images[1].url
|
||||||
bg_url = "https://www.bing.com" .. bingjson.images[1].url
|
|
||||||
end
|
end
|
||||||
|
elseif (bgcount > 0 and currentBg["type"] ~= "mp4") then
|
||||||
|
bg_url = currentBg.url
|
||||||
|
end
|
||||||
%>
|
%>
|
||||||
style="background-image:url(<%=bg_url%>)"
|
<div class="main-bg" id="main-bg" style="background-image:url(<%=bg_url%>)"></div>
|
||||||
<% elseif (bgcount > 0 and currentBg["type"] ~= "mp4") then %>
|
|
||||||
style="background-image:url(<%=currentBg.url%>)"
|
|
||||||
<% end %>
|
|
||||||
></div>
|
|
||||||
|
|
||||||
<% end %>
|
<% end %>
|
||||||
<div class="login-container">
|
<div class="login-container">
|
||||||
<div class="login-form">
|
<div class="login-form">
|
||||||
|
@ -156,4 +154,4 @@
|
||||||
}
|
}
|
||||||
//]]></script>
|
//]]></script>
|
||||||
<% end %>
|
<% end %>
|
||||||
<%+footer%>
|
<%+themes/argon/out_footer_login%>
|
||||||
|
|
|
@ -1,9 +1,12 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
uci batch <<-EOF
|
|
||||||
set luci.themes.Argon=/luci-static/argon
|
if [ "$PKG_UPGRADE" != 1 ]; then
|
||||||
commit luci
|
uci get luci.themes.Argon >/dev/null 2>&1 || \
|
||||||
EOF
|
uci batch <<-EOF
|
||||||
[ -f /usr/lib/lua/luci/view/themes/argon/out_header_login.htm ] && mv -f /usr/lib/lua/luci/view/themes/argon/out_header_login.htm /usr/lib/lua/luci/view/header_login.htm
|
set luci.themes.Argon=/luci-static/argon
|
||||||
rm -Rf /var/luci-modulecache
|
set luci.main.mediaurlbase=/luci-static/argon
|
||||||
rm -Rf /var/luci-indexcache
|
commit luci
|
||||||
|
EOF
|
||||||
|
fi
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
|
|