162 Commits

Author SHA1 Message Date
Self-Hosting-Group
d16ffa3113 luci-theme: add missing menu name to page <title>
Signed-off-by: Self-Hosting-Group <selfhostinggroup-git+openwrt@shost.ing>
2025-12-03 21:47:13 +01:00
Eamon Xiong
53548203fd luci-theme-material: use arrow function
Replaced L.bind with an arrow function for simpler syntax and clearer `this` binding.

Signed-off-by: Eamon Xiong <eamonxiong@gmail.com>
2025-11-17 23:41:07 +08:00
Paul Donald
6e263428bd luci-mod-status: partial revert of styling changes
follow-up to 788e47034b

Some of the CSS changes have knock-on effects and change behaviour in
other display areas, especially when the CSS is minified.

Simplified to change between label flavours on hide/show status.

Signed-off-by: Paul Donald <newtwen+github@gmail.com>
2025-10-21 16:25:47 +02:00
Christian Marangi
788e47034b luci-mod-status: add support to show/hide index cards
Add support to show/hide index cards. A card's state is saved using the
browser localstorage and its state is restored on page reload/relogin.

Rework the pool function to check and skip loading of hidden cards.

Rework themes to address new button position.

Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
[ changed tabs in CSS ]
Signed-off-by: Paul Donald <newtwen+github@gmail.com>
2025-10-02 15:11:51 +02:00
Dávid Benko
65c1075b86 themes: scale down icons for network interfaces
Many LuCI icons doubled in size during migration to vector graphics
in commit ae5d91da90 (16px to 32px).

Sizing of their instances is mostly controlled by CSS, but there's
an exception - network interface boxes of "Interfaces" page in LuCI.
Current CSS doesn't specify any particular size requirements to follow,
so the icons just scale with the images served, thus effectively
doubling in width and height compared to state before the vectorization
commit. Such a big icons look odd and take up too much space, especially
for bridge interfaces with many ports.

Instead of reverting to the original 16×16px, this commit proposes
compromise of 24×24px as most of other icons within LuCI became a bit
bigger as well.

Signed-off-by: Dávid Benko <davidbenko@davidbenko.dev>
2025-09-29 17:25:45 +02:00
Paul Donald
755061bc9e themes: remove overflow-y property; it inhibits readonly view scrolling
Closes #7947

Signed-off-by: Paul Donald <newtwen+github@gmail.com>
2025-09-19 01:45:03 +02:00
Paul Donald
ae5d91da90 treewide: vectorise iconography
Clear, crisp, resolution independent vector graphics replace the trusty
microscopic PNG. Some minor CSS changes were needed to constrain images
in some locations to make sure they don't consume too much space.

Iconography taken from Mate desktop theme with minor adjustments:

https://github.com/mate-desktop/mate-icon-theme/

Signed-off-by: Paul Donald <newtwen+github@gmail.com>
2025-06-12 18:55:53 +02:00
Paul Donald
f1fefe958c luci-theme-*: layout improvements
material menu bar on the left is now 'above' main content

Signed-off-by: Paul Donald <newtwen+github@gmail.com>
2025-06-08 22:59:15 +02:00
Paul Donald
76fa3036a2 luci-theme-*: wrap span tags, fixes badge text
The nowrap can be a bit obnoxious when available layout space is
limited. Wrap.

Signed-off-by: Paul Donald <newtwen+github@gmail.com>
2025-06-08 22:56:40 +02:00
Paul Donald
9180f2a762 luci-theme-*: ES6 refactor
Signed-off-by: Paul Donald <newtwen+github@gmail.com>
2025-04-23 14:21:40 +02:00
Paul Donald
9157254059 luci-theme: fix some dynamic layout issues
Implement a dynamic menu item width to allow item unwrapped and visible:
'min-width: max-content;' or 'max-width: max-content;'

Remove IE hacks and fix a console error for -webkit-scrollbar-thumb

Signed-off-by: Paul Donald <newtwen+github@gmail.com>
2025-04-23 14:03:57 +02:00
Jyn
50677f9de5 luci-theme-material: zone-forwards wrap
Signed-off-by: Jyn <pvp4eek@gmail.com>
2025-04-14 15:19:35 +02:00
Florian Eckert
046a121087 treewide: set css tag flex-wrap to wrap buttons in modal view
In CSS, the flex-wrap property is used in a flex container to control
how flex items are laid out when there is not enough space in a single
line.

If a modal is displayed on small screens, the buttons are not wrapped. They
remain on one line. This breaks the layout and does not look good.

Signed-off-by: Florian Eckert <fe@dev.tdt.de>
2025-03-06 11:21:32 -06:00
Florian Eckert
47d26bcb62 luci-theme-material: update cascade.css to use first-of-type instead of last/first-child
first-child:
Selects an element that is the first child of its parent. The element must
be the very first child of its parent, regardless of its type.

first-of-type:
Selects the first element of its type among its siblings. The element must
be the first of its type (e.g., <p>, <div>, etc.) within its parent, but it
does *not* have to be the first child.

Makes the CSS usage more robust if the layout changes and new html elements
are added.

Signed-off-by: Florian Eckert <fe@dev.tdt.de>
2025-03-06 11:21:32 -06:00
Christian Korber
4c692b88df themes/luci-theme-material: change dropdown text to black
This commit enforces black text in dropdown[open] to highlight it
against white background.

Signed-off-by: Christian Korber <ck@dev.tdt.de>
2025-03-03 20:42:57 -06:00
Christian Korber
29df6ff70f luci-base: change Save Button textcolor to white
Upstream color is defined as #808080, so for better distinction the
color is changed to var(--white-color).

Signed-off-by: Christian Korber <ck@dev.tdt.de>
2025-03-03 20:42:57 -06:00
Paul Donald
779ca14125 css: remove unsupported properties
neither Safari nor Firefox recognize them, and they generate a parse
error.

Signed-off-by: Paul Donald <newtwen+github@gmail.com>
2024-12-22 16:23:35 +00:00
Paul Donald
0459c378b7 themes: update package-manager style to match page name
opkg is no longer available as the generic name for package-manager

Signed-off-by: Paul Donald <newtwen+github@gmail.com>
2024-12-15 20:29:36 +01:00
Ramon Van Gorkom
80f18df48f luci-base: make items of UIDynamicList drag-sortable
Signed-off-by: Ramon Van Gorkom <Ramon00c00@gmail.com>
2024-11-27 21:43:16 +01:00
Mustafa Can Elmacı
ae8bbb814f treewide: HTML Cleanup
* HTML Cleanup: Meta tags.
* Converted charset to shorthand.
* Removed meta tags with `Content-Script-Type` attribute. (Invalid in HTML5 spec.)

* HTML Cleanup: CSS tags.
* Removed `type` attribute with CSS files from link tags. (HTML5 spec recommends omitting it.)
* Removed `type` attribute from style tags. (Deprecated in HTML5 spec.)
https://html.spec.whatwg.org/#attr-link-type
https://developer.mozilla.org/en-US/docs/Web/HTML/Element/style

* HTML Cleanup: Convert from XHTML to HTML5
* Removed XML declaration.
* Removed XML namespace.
* Changed doctype to HTML5.

* HTML Cleanup: CDATA tags.
* CDATA sections should not be used within HTML they are considered as comments and not displayed.
https://developer.mozilla.org/en-US/docs/Web/API/CDATASection

* HTML Cleanup: Script tags.
* Removed `language` attribute from script tags. (No longer valid in HTML5)
* Removed `type` attribute with JavaScript MIME type from script tags. (HTML5 spec recommends omitting it.)
https://html.spec.whatwg.org/multipage/scripting.html#attr-script-type
https://mimesniff.spec.whatwg.org/#javascript-mime-type

Signed-off-by: Mustafa Can Elmacı <mustafacan@elmaci.net>
2024-11-22 22:39:46 +01:00
Florian Eckert
5119fa2f79 luci-theme-material: add css class button-row
Signed-off-by: Florian Eckert <fe@dev.tdt.de>
2024-07-09 16:19:51 +02:00
Florian Eckert
a277e63975 luci-theme-material: do not show the message 'no password' on the login page
This note is also not displayed in the theme luci-theme-boostrap. Also, for
security reasons, we should not explicitly point this out on the login page,
that no password is set.

Signed-off-by: Florian Eckert <fe@dev.tdt.de>
2024-04-25 10:34:31 +02:00
Florian Eckert
41c18218f3 Merge pull request #7008 from dannil/material-color-variables
luci-theme-material: add back removed color variables
2024-03-25 07:56:39 +01:00
Daniel Nilsson
4adc4a6568 luci-theme-material: make luci-app-commands command box align with Bootstrap theme
The current implementation made the commands from the app luci-app-commands absolutely positioned which resulted in hiding elements which was underneath it, ie. the buttons. This implementation removes the absolutely positioned behavior making the buttons visible again and as an upside aligns it with how the Bootstrap theme handles commands.

Signed-off-by: Daniel Nilsson <daniel.nilsson94@outlook.com>
2024-03-23 01:53:43 +01:00
Daniel Nilsson
eeddf40ac9 luci-theme-material: add back removed color variables
Partially reverts 2bdabf14c3 by adding back the deleted color variables as the custom.css was used by users to override the theme with their own colors. To maintain backwards compatibility with users we should not remove/rename these as it will result in colors being applied incorrectly.

Signed-off-by: Daniel Nilsson <daniel.nilsson94@outlook.com>
2024-03-22 12:28:29 +01:00
Florian Eckert
504d934150 luci-theme-material: add missing license information
Signed-off-by: Florian Eckert <fe@dev.tdt.de>
2024-03-19 13:36:33 +01:00
Fengyu Wu
98a6ba28de luci-themes: add luci-base to depends
Signed-off-by: Fengyu Wu <saldry@proton.me>
2024-03-02 17:57:01 +01:00
Fengyu Wu
45d2becacb luci-theme-material: open footer link in new tab
Also set Referrer Policy

Signed-off-by: Fengyu Wu <saldry@proton.me>
2024-03-02 17:57:01 +01:00
Daniel Nilsson
3acc8bc373 luci-theme-material: improve theming system colors and contrasts
This changed spawned from trying to make certain text colors readable (such as white text on white background in many dialogs) introduced by commit 4ee2bc6 (ref: #5841) which made obvious the need to improve the color and contrast situation in the theme.

Alot of colors were duplicated in cascade.css and made for a hard time to align colors across different elements. This commit tries to rectify that by introducing variables for all commonly used colors.

* All base colors (white, blue, red, green, blue, yellow, etc) has been consolidated and moved to common variables
* Introduced more specific selectors for info levels to avoid colors bleeding over to other elements
* Removed duplicated properties which were overriden at the next row

Signed-off-by: Daniel Nilsson <daniel.nilsson94@outlook.com>
2024-03-02 17:56:28 +01:00
Florian Eckert
0b24d1f465 luci-theme-material: add missing css for dsl_status_table
Insert a space between the name and the current value, as with other themes.

Signed-off-by: Florian Eckert <fe@dev.tdt.de>
2024-02-28 15:28:40 +01:00
Jo-Philipp Wich
01e5510888 luci-theme-material: add dropdown option hover styles
Subsequent commits will drop the JS based mouse following focus behavior,
so add appropriate replacement CSS hover styles.

Ref: #6903
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2024-02-19 00:04:16 +01:00
Sergey Ponomarev
b572c35ca8 luci-theme-material: Use a new OpenWrt logo
The new OpenWrt logo.svg is copied from luci-theme-openwrt-2020.
The logo.png was copied too but resized from 180px 3.9Kb down to 48px 2.3Kb.
This is enough when used as icon for app pinned to desktop.

Signed-off-by: Sergey Ponomarev <stokito@gmail.com>
2023-12-12 20:24:12 +02:00
Florian Eckert
f464199be1 luci-theme-material: add again no password set hint
This was accidentally deleted with commit:
bec2c7e2b5

Signed-off-by: Florian Eckert <fe@dev.tdt.de>
2023-03-29 10:34:20 +02:00
Florian Eckert
21b40652d9 luci-theme-: add postrm script
Remove uci theme config section on uninstall.

Signed-off-by: Florian Eckert <fe@dev.tdt.de>
2023-01-09 13:07:42 +01:00
Jo-Philipp Wich
bd4bf6ac9b luci-theme-material: fix location of template files
Fixes: #6060
Fixes: e496014760 ("luci-theme-material: convert Lua templates to ucode")
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2022-10-27 11:14:52 +02:00
Jo-Philipp Wich
e496014760 luci-theme-material: convert Lua templates to ucode
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2022-10-25 01:03:37 +02:00
INAGAKI Hiroshi
2a55839363 luci-theme-material: fix typo in recovery mode message
Fix the message from "Sytem" to "System" and merge with the existing
message on the other themes.

Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
2022-07-27 11:21:54 +09:00
y04
ec8bdab76c luci-theme-material: optimized image filesize
Optimized PNG filesize from 6280 to 3939 bytes. Visually looks the same, technically the image is 99.9% identical.

Signed-off-by: Alexander Semukhin <semukhin@mail.com>
2022-06-25 01:43:23 +02:00
Quentin Baker
4ee2bc644a luci-theme-material: CSS Fix for previous update
Commit b0f13ef Changed the color of a CSS element from a bright blue to
a dark blue. This resulted in a modal with difficult-to-read text (black
text on dark blue).

This commit sets the modal text-color to #000, in line with style
guidelines.

Signed-off-by: Quentin Baker <opensource@quentb.com>
2022-06-17 00:02:09 -04:00
Quentin Baker
b0f13efa9c luci-theme-material: Update brand logo/colors
I have updated the brand.png logo to the 2020 version, and I have
made a small adjustment to the CSS to reflect its slightly larger
vertical height.

I also have made small tweaks to the system theme colors to use
the brand colors as recommended on page 5 of the logo usage
guidelines document avalible at
openwrt/branding/blob/master/openwrt-styleguide.pdf

Signed-off-by: Quentin Baker <opensource@quentb.com>
2022-06-05 21:46:27 -04:00
Miguel Angel Mulero Martinez
1cd615787a luci-material-theme: replace margin by gap in ifacebadge
Material is a "flex" theme. Better to use "gap" in place of "margin" to
add some space between elements inside "flex" elements.

This fixes the problem specially when there are text elements inside the
"flex" and don't hurt when there are images.

Signed-off-by: Miguel Angel Mulero Martinez <migmul@gmail.com>
2022-05-04 10:53:35 +02:00
Jo-Philipp Wich
a000cf9c01 Merge pull request #5794 from McGiverGim/material_align_button_text_center
luci-material-theme: align text buttons center
2022-05-02 10:37:15 +02:00
Miguel Angel Mulero Martinez
56aeaa8ac8 luci-material-theme: fix localizated left menu
The latest fix to fix the logout worked, but it was not applied to all
the resolutions, and I have observed the same problem exists for the
dasboard optional component.
Looking at the code, it seems only the components without submenu, have the
data-title element, so this fix modifies the style for all of them, not
relying on the position or text content.

Signed-off-by: Miguel Angel Mulero Martinez <migmul@gmail.com>
2022-05-02 09:47:36 +02:00
Miguel Angel Mulero Martinez
9e73a04adb luci-material-theme: align text buttons center
The text inside the buttons is aligned to the top. This change mades
it aligned to the center.

Signed-off-by: Miguel Angel Mulero Martinez <migmul@gmail.com>
2022-05-01 09:23:04 +02:00
Jo-Philipp Wich
0a8bf7583e Merge pull request #5791 from McGiverGim/fix_td_align
luci-material-theme: align td text width 33%
2022-04-30 15:35:06 +02:00
Jo-Philipp Wich
0a49bbe87f Merge pull request #5792 from McGiverGim/controlgroup_flex
luci-material-theme: make control-group flex
2022-04-30 15:34:41 +02:00
Miguel Angel Mulero Martinez
17ddeb7b57 luci-material-theme: make control-group flex
The control-group div does not flex. The buttons overflow the screen.

This change mades them flex.

Signed-off-by: Miguel Angel Mulero Martinez <migmul@gmail.com>
2022-04-30 10:37:08 +02:00
Miguel Angel Mulero Martinez
3333fd6695 luci-material-theme: align td text width 33%
The CSS applies a different padding for td elements with 33% width. This
misaligns the text from this td to the others td.

This change modifies the CSS to apply the same padding to all of the
sibling td.

Signed-off-by: Miguel Angel Mulero Martinez <migmul@gmail.com>
2022-04-30 09:57:02 +02:00
Miguel Angel Mulero Martinez
f8e52aa85d luci-material-theme: adjust data-title for logout
The data-title attribute style depends on the content in the css rule.
When translated to other language, the css rule fails.
This change uses the position and not the content to apply the style.

Signed-off-by: Miguel Angel Mulero Martinez <migmul@gmail.com>
2022-04-30 09:15:40 +02:00
Miguel Angel Mulero Martinez
d452dee8ce Revert "luci-material-theme: reduce size of logout icon"
This reverts commit 3758ab9479.

The solution is not good. It breaks in some way the English UI to fix
localizated UI.

It will be fixed again in other commit.

Signed-off-by: Miguel Angel Mulero Martinez <migmul@gmail.com>
2022-04-30 09:13:32 +02:00