summaryrefslogtreecommitdiffhomepage
path: root/modules/luci-base/htdocs
AgeCommit message (Collapse)Author
2024-11-27luci-base: make items of UIDynamicList drag-sortableRamon Van Gorkom
Signed-off-by: Ramon Van Gorkom <Ramon00c00@gmail.com>
2024-11-25luci-base: form: fix sort order bug triggered by integer typesPaul Donald
Signed-off-by: Paul Donald <newtwen+github@gmail.com>
2024-11-25luci-base: uci: fixed reorder bug where missed deletes caused off-by-onePaul Donald
Signed-off-by: Paul Donald <newtwen+github@gmail.com>
2024-11-24luci-base: add clone action for tablesPaul Donald
This augments CBITableSection, affecting types which extend it, i.e. CBIGridSection. Setting a table 'cloneable' property to true reveals a column of clone buttons who designate the current entry as a clone source. Clicking the clone button duplicates the data of that section_id into a new entry, while the new entry gets a new and unique SID. E.g. s = m.section(form.GridSection, 'foo', _('Bar')); ... s.cloneable = true; Clone and add actions differ: clone will not open a dialogue. That is a user exercise. One may set the put_next flag to false to put the new clone last, or true to put it next (after the clone source). This uses a new uci action which fulfills the behaviour: clone It is possible for the uci clone action to be used independently. See also: https://forum.openwrt.org/t/add-clone-button-to-luci-configurations-esp-in-firewall/196232 Signed-off-by: Paul Donald <newtwen+github@gmail.com>
2024-11-21luci-base: ui: extend addNotification to handle a user-provided timeoutPaul Donald
A millisecond value after which the notification will disappear automatically. If omitted, the notification will remain until it receives the click event. Existing calls are unaffected. Signed-off-by: Paul Donald <newtwen+github@gmail.com>
2024-11-07luci-base: fix documented pathPaul Donald
Signed-off-by: Paul Donald <newtwen+github@gmail.com>
2024-11-05luci-base: network; implement getIP6Prefixes()Paul Donald
Signed-off-by: Paul Donald <newtwen+github@gmail.com>
2024-10-24luci-base: actually use the packaged options for poll.add callsPaul Donald
Signed-off-by: Paul Donald <newtwen+github@gmail.com>
2024-10-23luci-base: implement RichListValue widget in formPaul Donald
Signed-off-by: Paul Donald <newtwen+github@gmail.com>
2024-10-23luci-base: show default forwarding target in general firewall settingsFlorian Eckert
Signed-off-by: Florian Eckert <fe@dev.tdt.de>
2024-10-23luci-base: add 'create' boolean to MultiValue form widgetPaul Donald
Enables creation of custom choices. example usage: o = s.taboption('thistab', form.MultiValue, 'myoption'); o.create = true; Form element now presents additional ' -- custom -- ' entry. Signed-off-by: Paul Donald <newtwen+github@gmail.com>
2024-10-22luci-base: allow terminal '.' in hostname checksPaul Donald
allowed in hostnames to represent the root of the DNS hierarchy Signed-off-by: Paul Donald <newtwen+github@gmail.com>
2024-10-17luci-base: space -> tabPaul Donald
Signed-off-by: Paul Donald <newtwen+github@gmail.com>
2024-10-16luci-base: Minor spell fixesPaul Donald
Signed-off-by: Paul Donald <newtwen+github@gmail.com>
2024-10-07luci-wireless: Add 11be supportRudy Andram
Tested with filogic banana rpi4 / QNAP qualcommax ipq8074 Signed-off-by: Rudy Andram <rmandrad@gmail.com> Tested-By: Daniel Pawlik <pawlik.dan@gmail.com>
2024-09-18luci-base: form.js: decode HTML entities in AbstractElement.stripTags()Mikael Magnusson
This commit fixes a problem with HTML entities which were visible in their encoded form in the mobile view. This happened for example when displaying a GridSection with a Value option containing "&nbsp;" in the title. Without this change only HTML entities in titles that also contains tags are decoded before they are stored in data-title attributes. Signed-off-by: Mikael Magnusson <mikma@users.sourceforge.net>
2024-09-14luci-base: refactor network devices enumerationLuca Barbato
And make sure to return an empty list if getDevices() returns null. It happens with batadv.
2024-07-19luci-base: revert replacing button tags with div tagsFlorian Eckert
Signed-off-by: Florian Eckert <fe@dev.tdt.de>
2024-07-19luci-base: fixing a regression that was add by the ne button-row css classFlorian Eckert
Signed-off-by: Florian Eckert <fe@dev.tdt.de>
2024-07-19luci-base: add missing btn css class to buttonFlorian Eckert
Signed-off-by: Florian Eckert <fe@dev.tdt.de>
2024-07-17Merge pull request #7153 from TDT-AG/pr/20240607-luci-baseFlorian Eckert
treewide: add new css class button-row
2024-07-09luci-base: replace css class right with css class button-rowFlorian Eckert
Signed-off-by: Florian Eckert <fe@dev.tdt.de>
2024-07-09luci-base: update connectivity change help text and button textFlorian Eckert
Signed-off-by: Florian Eckert <fe@dev.tdt.de>
2024-07-06luci-base: Correct how textarea's wrap worksJoseph Mory
Signed-off-by: Joseph Mory <morytyann@outlook.com>
2024-06-07luci-base: replace button tag with div tag in ui.jsFlorian Eckert
Signed-off-by: Florian Eckert <fe@dev.tdt.de>
2024-06-07luci-base: add missing css class cbi-button to ui.jsFlorian Eckert
Signed-off-by: Florian Eckert <fe@dev.tdt.de>
2024-06-07luci-base: move cancel button to the topFlorian Eckert
This change is required, so that the cancel button is the first and thus closes the modal when the 'ESC' button is pressed. Signed-off-by: Florian Eckert <fe@dev.tdt.de>
2024-06-07luci-base: remove flex style tagsFlorian Eckert
Signed-off-by: Florian Eckert <fe@dev.tdt.de>
2024-06-07luci-base: replace button tag with div tag in ui.jsFlorian Eckert
Signed-off-by: Florian Eckert <fe@dev.tdt.de>
2024-06-07luci-base: add missing css class cbi-button to ui.jsFlorian Eckert
Signed-off-by: Florian Eckert <fe@dev.tdt.de>
2024-06-07luci-base: move button one level up for Save & ApplyFlorian Eckert
This is a preparation commit so the buttons could get the new css class 'button-row' Signed-off-by: Florian Eckert <fe@dev.tdt.de>
2024-06-07luci-base: replace button tag with div tag in ui.jsFlorian Eckert
Signed-off-by: Florian Eckert <fe@dev.tdt.de>
2024-06-07luci-base: add missing css classes btn and cbi-button to ui.jsFlorian Eckert
Signed-off-by: Florian Eckert <fe@dev.tdt.de>
2024-06-07luci-base: add missing css class btn to form.jsFlorian Eckert
Signed-off-by: Florian Eckert <fe@dev.tdt.de>
2024-06-06luci-base: clarify apply-settings stringsPaul Donald
Signed-off-by: Paul Donald <newtwen+github@gmail.com>
2024-05-14luci-base: return ipv6 lease time from getExpiry()hitech95
This commit introduces a streamlined method for retrieving lease time information on IPv6 interfaces. While IPv4 interfaces typically have a single lease time (available in the interface data), IPv6 interfaces commonly feature multiple lease times due to factors like delegated prefixes or multiple /64 subnet. Users typically receive only one prefix delegation from their ISP, leading this PR to the retrieval of lease time from the first available prefix or IPv6 address. To enhance usability and provide users with a more comprehensive view of lease time information, however, alternative approaches should be discussed. Suggestions include returning an array of lease times or aggregating the various possible values using methods like min or max. These enhancements aim to improve the clarity the lease time management on IPv6 interfaces. Signed-off-by: hitech95 <nicveronese@gmail.com>
2024-04-09Merge pull request #6553 from stokito/luc-mod-system_filemanagerJo-Philipp Wich
Add File Manager / File Browser based on form.FileUpload
2024-04-09luci-base: ui.js FileUpload: option to enable Download buttonSergey Ponomarev
Allow downloading from a file browser. The Download button is located near to Delete. It's shown only for files: folders or /dev/ devices can't be downloaded. The downloading is made via fs.read_direct() which internally calls cgi-download. Signed-off-by: Sergey Ponomarev <stokito@gmail.com>
2024-03-29luci-base: drive-by fixesPaul Donald
Signed-off-by: Paul Donald <newtwen+github@gmail.com>
2024-03-17Revert "luci-base: force menu to regenerate after uci change"Hannu Nyman
This reverts commit 97ebdcbddb9cad76dc551086fcb887e55886a069. The commit seems to cause errors already before the login screen. Discussion in https://github.com/openwrt/luci/commit/97ebdcbddb9cad76dc551086fcb887e55886a069#commitcomment-139871175 Errors like: In error(), file [C] called from function [anonymous function] (/usr/lib/lua/luci/ucodebridge.lua:23) called from function ((tail call)) In [anonymous function](), file /usr/share/ucode/luci/runtime.uc, line 148, byte 45: called from function build_pagetree (/usr/share/ucode/luci/dispatcher.uc:382:73) called from function menu_json (/usr/share/ucode/luci/dispatcher.uc:439:26) called from function [anonymous function] (/usr/share/ucode/luci/dispatcher.uc:898:24) called from anonymous function (/www/cgi-bin/luci:39:13) ` return lcall.call(modname, method, ...args);` Near here ----------------------------------------^ Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
2024-03-17widgets: add a re-useable filtered logread viewKarl Palsson
Multiple apps introduced their own implementation of a syslog view, filtered for just their own application logs. Pull that out as a shared view. Some of these had _minor_ style differences, which has been "standardized" now. A full "widget" conversion would allow more end app tuning of that, but is not implemented. Signed-off-by: Karl Palsson <karlp@etactica.com> app-nextdns: fix Logs title Minor typo, introduced in 625abbf (convert simple controllers to menu.json) Signed-off-by: Karl Palsson <karlp@etactica.com> luci-base: implement shared log reader view Closes #5452 Signed-off-by: Paul Donald <newtwen@gmail.com>
2024-03-17luci-base: force menu to regenerate after uci changeJames Haggerty
Because the menu JSON can have 'depends' in them, uci changes should force the menu to regenerate. Closes #6423 Signed-off-by: James Haggerty <james.haggerty@morsemicro.com> Signed-off-by: Paul Donald <newtwen@gmail.com>
2024-03-17luci-base: ui.js: avoid polling in a tight loop on confirm/rollbackErik Karlsson
The call function was based on the legacy XHR interface and it has not been updated to comply with the new request interface which passes the duration as part of the response object rather than as a separate argument. This resulted in polling in a tight loop in certain cases since the duration was undefined. In addition there is no need to adjust apply_holdoff based on elapsed time as no significant amount of time has elapsed at this point. Signed-off-by: Erik Karlsson <erik.karlsson@genexis.eu>
2024-03-15luci-base: cbi.js: drop CustomEvent polyfillJo-Philipp Wich
All supported browsers natively support this functionality since quite a while already. Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2024-03-08luci-base: CBIFileUpload support file browser modeSergey Ponomarev
In the Browser mode the file tree dialog won't be closed when clicking on a file. The mode is used by a File Browser. Signed-off-by: Sergey Ponomarev <stokito@gmail.com>
2024-03-07luci-base: use correct regex for time validationDaniel Nilsson
Before this change, values further in time than 23:59:59 was allowed, such as 24:00:00 and 23:60:00. Leap seconds is accounted for so 60 is allowed in the seconds parameter. Signed-off-by: Daniel Nilsson <daniel.nilsson94@outlook.com>
2024-03-06luci-base: docs house-keepingPaul Donald
Signed-off-by: Paul Donald <newtwen@gmail.com>
2024-02-21luci-base: static.js: fix validation of netmask optionJo-Philipp Wich
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2024-02-21luci-base: ui.js: further keyboard navigation improvements for dropdownsJo-Philipp Wich
- Ensure that pressing escape within the custom choice input closes the dropdown list but not the parent modal dialog - Ensure that added custom choice elements are tabbable - Retain focus on dropdown when closing dropdown - Consistently focus input textarea when tabbing into custom choice item Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2024-02-21luci-base: validation.js: add iprange, iprange4 and iprange6 validatorsJo-Philipp Wich
Add datatype validators for IP address ranges which are required for certain firewall inputs. Signed-off-by: Jo-Philipp Wich <jo@mein.io>