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>
follow-up fix for 0be4ad51a0
It seems to have been this way for a while, for zone selections
involving the 'any' ('*') choice. firewall forwards.js has no
'this.allowany;' property on the widgets, so the any choice is absent,
leading to a traceback, caused by the 'src' widget, even though
this code block operates on the 'dst' value. Certain combinations of
'src' and 'dst' also triggered tracebacks.
This might not be the correct behaviour for this widget, but it does
prevent tracebacks caused by null values.
Signed-off-by: Paul Donald <newtwen+github@gmail.com>
Tunnel devices which are up, show as down, since they don't have access
to any device status. The 'device' being enumerated is e.g.
'wireguard_wg0', a configuration for a tunnel interface, whose parent
is an 'ethernet' type.
That's a bug for another day. So they shall get parent device status.
Signed-off-by: Paul Donald <newtwen+github@gmail.com>
removes a075566dbb (and subsequent fixes)
enforcing a datatype on this widget generates the following error when
multiple zones are selected:
Expecting: valid UCI identifier
(the error triggered for uciname). At its simplest: multiple selections
are no longer just a uciname, but multiple thereof.
Signed-off-by: Paul Donald <newtwen+github@gmail.com>
Refactor various sort operations throughout luci-base to use the new
L.naturalCompare() comparator function.
This primarily ensures that embedded numbers are sorted numerically and
not in a lexicographical way.
It also simplifies some code as a side effect.
Ref: #5899
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
Support the "loopback" interface by "widgets.NetworkSelect".
Enable the "loopback" option to include this interface.
Can be used to configure interface binding for services.
Signed-off-by: Vladislav Grigoryev <vg.aetera@gmail.com>
- Set src/dest defaults only in initial section create state, otherwise it
is impossible to specify output rules
- Get rid of dest_remote/dest_local widget switching and implement change
logic directly in tools.widgets.CBIZoneSelect
- Remove leftover debug code
Ref: https://github.com/openwrt/luci/issues/2889
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
Add a tools.widgets library which bundles a number of useful, higher
level CBI widgets like firewall zone list or network interface dropdowns
Signed-off-by: Jo-Philipp Wich <jo@mein.io>