From: Jo-Philipp Wich
Date: Fri, 3 Apr 2020 11:28:38 +0000 (+0200)
Subject: docs: update js api docs
X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=0c3152c88d108a39b6f235300dd56fac81748aa6;p=oweals%2Fluci.git
docs: update js api docs
Signed-off-by: Jo-Philipp Wich
---
diff --git a/docs/jsapi/LuCI.baseclass.html b/docs/jsapi/LuCI.baseclass.html
index 01e84ba58..f35e51267 100644
--- a/docs/jsapi/LuCI.baseclass.html
+++ b/docs/jsapi/LuCI.baseclass.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -2942,7 +2944,7 @@ and the values extracted from the args
array beginning with
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.dom.html b/docs/jsapi/LuCI.dom.html
index c050ca0be..1de264bce 100644
--- a/docs/jsapi/LuCI.dom.html
+++ b/docs/jsapi/LuCI.dom.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -4500,7 +4502,7 @@ ignored, else not.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.fs.html b/docs/jsapi/LuCI.fs.html
index 0fa989c8f..b0bac3f81 100644
--- a/docs/jsapi/LuCI.fs.html
+++ b/docs/jsapi/LuCI.fs.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -4087,7 +4089,7 @@ the failure reason.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.headers.html b/docs/jsapi/LuCI.headers.html
index 4a03cef57..dfbd235b9 100644
--- a/docs/jsapi/LuCI.headers.html
+++ b/docs/jsapi/LuCI.headers.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -2115,7 +2117,7 @@ Note: Header-Names are case-insensitive.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.html b/docs/jsapi/LuCI.html
index d7cf33ced..8734be585 100644
--- a/docs/jsapi/LuCI.html
+++ b/docs/jsapi/LuCI.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -6043,7 +6045,7 @@ else null
.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.network.Device.html b/docs/jsapi/LuCI.network.Device.html
index bef9b0849..9d989c277 100644
--- a/docs/jsapi/LuCI.network.Device.html
+++ b/docs/jsapi/LuCI.network.Device.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -4060,7 +4062,7 @@ when it is down or absent.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.network.Hosts.html b/docs/jsapi/LuCI.network.Hosts.html
index 16d52ba34..87bbce6f3 100644
--- a/docs/jsapi/LuCI.network.Hosts.html
+++ b/docs/jsapi/LuCI.network.Hosts.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -3041,7 +3043,7 @@ is used as hint.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.network.Protocol.html b/docs/jsapi/LuCI.network.Protocol.html
index 80db046f8..2dca6061d 100644
--- a/docs/jsapi/LuCI.network.Protocol.html
+++ b/docs/jsapi/LuCI.network.Protocol.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -6124,7 +6126,7 @@ configuration.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.network.WifiDevice.html b/docs/jsapi/LuCI.network.WifiDevice.html
index ab2b904c3..78ef70356 100644
--- a/docs/jsapi/LuCI.network.WifiDevice.html
+++ b/docs/jsapi/LuCI.network.WifiDevice.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -3407,7 +3409,7 @@ configuration.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.network.WifiNetwork.html b/docs/jsapi/LuCI.network.WifiNetwork.html
index 3942a108a..35a5423e2 100644
--- a/docs/jsapi/LuCI.network.WifiNetwork.html
+++ b/docs/jsapi/LuCI.network.WifiNetwork.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -5900,7 +5902,7 @@ configuration.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.network.html b/docs/jsapi/LuCI.network.html
index 60b16624c..62ea32a90 100644
--- a/docs/jsapi/LuCI.network.html
+++ b/docs/jsapi/LuCI.network.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -7755,7 +7757,7 @@ conjunction with quality
to calculate a quality percentage.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.poll.html b/docs/jsapi/LuCI.poll.html
index 26a588a68..b999a9ae2 100644
--- a/docs/jsapi/LuCI.poll.html
+++ b/docs/jsapi/LuCI.poll.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -2498,7 +2500,7 @@ run to begin with.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.request.html b/docs/jsapi/LuCI.request.html
index a505568cb..7424fea0d 100644
--- a/docs/jsapi/LuCI.request.html
+++ b/docs/jsapi/LuCI.request.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -3433,7 +3435,7 @@ instances as sole argument during the HTTP request transfer.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.request.poll.html b/docs/jsapi/LuCI.request.poll.html
index b1c040599..961348962 100644
--- a/docs/jsapi/LuCI.request.poll.html
+++ b/docs/jsapi/LuCI.request.poll.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -2617,7 +2619,7 @@ else null
.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.response.html b/docs/jsapi/LuCI.response.html
index a6f76a997..50b4c116d 100644
--- a/docs/jsapi/LuCI.response.html
+++ b/docs/jsapi/LuCI.response.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -2575,7 +2577,7 @@ using String()
and treated as response text.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.rpc.html b/docs/jsapi/LuCI.rpc.html
index 372aa5212..c24bde480 100644
--- a/docs/jsapi/LuCI.rpc.html
+++ b/docs/jsapi/LuCI.rpc.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -3845,7 +3847,7 @@ to the expect
and filter
declarations.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.uci.html b/docs/jsapi/LuCI.uci.html
index 7a7b97f3d..2efef59e0 100644
--- a/docs/jsapi/LuCI.uci.html
+++ b/docs/jsapi/LuCI.uci.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -5393,7 +5395,7 @@ associated name as arguments.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.ui.AbstractElement.html b/docs/jsapi/LuCI.ui.AbstractElement.html
index c4f575c86..779f9ae4e 100644
--- a/docs/jsapi/LuCI.ui.AbstractElement.html
+++ b/docs/jsapi/LuCI.ui.AbstractElement.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -3084,7 +3086,7 @@ converted to a string and treated as validation error message.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.ui.Checkbox.html b/docs/jsapi/LuCI.ui.Checkbox.html
index 2554607b9..6779e51ab 100644
--- a/docs/jsapi/LuCI.ui.Checkbox.html
+++ b/docs/jsapi/LuCI.ui.Checkbox.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -3231,7 +3233,7 @@ it is required for HTML based form submissions.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.ui.ComboButton.html b/docs/jsapi/LuCI.ui.ComboButton.html
index 35a048160..77ed40907 100644
--- a/docs/jsapi/LuCI.ui.ComboButton.html
+++ b/docs/jsapi/LuCI.ui.ComboButton.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -3261,7 +3263,7 @@ choice value as second argument.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.ui.Combobox.html b/docs/jsapi/LuCI.ui.Combobox.html
index b8486ac64..73699cb4c 100644
--- a/docs/jsapi/LuCI.ui.Combobox.html
+++ b/docs/jsapi/LuCI.ui.Combobox.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -3164,7 +3166,7 @@ forcibly set to true
.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.ui.Dropdown.html b/docs/jsapi/LuCI.ui.Dropdown.html
index 65aa154d0..920bc3d47 100644
--- a/docs/jsapi/LuCI.ui.Dropdown.html
+++ b/docs/jsapi/LuCI.ui.Dropdown.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -3962,7 +3964,7 @@ expression. Only applicable when create
is true
.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.ui.DynamicList.html b/docs/jsapi/LuCI.ui.DynamicList.html
index 22e728105..e6c6d7bee 100644
--- a/docs/jsapi/LuCI.ui.DynamicList.html
+++ b/docs/jsapi/LuCI.ui.DynamicList.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -3339,7 +3341,7 @@ it to remain unselected.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.ui.FileUpload.html b/docs/jsapi/LuCI.ui.FileUpload.html
index 4fd54fb77..e5b50a8aa 100644
--- a/docs/jsapi/LuCI.ui.FileUpload.html
+++ b/docs/jsapi/LuCI.ui.FileUpload.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -3188,7 +3190,7 @@ ACL setup for the current session.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.ui.Hiddenfield.html b/docs/jsapi/LuCI.ui.Hiddenfield.html
index 4f62217d1..ede76a977 100644
--- a/docs/jsapi/LuCI.ui.Hiddenfield.html
+++ b/docs/jsapi/LuCI.ui.Hiddenfield.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -2942,7 +2944,7 @@ trigger validation runs, e.g. when programmatically altering values.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.ui.Select.html b/docs/jsapi/LuCI.ui.Select.html
index f3c3df35d..ed5fa6a57 100644
--- a/docs/jsapi/LuCI.ui.Select.html
+++ b/docs/jsapi/LuCI.ui.Select.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -3291,7 +3293,7 @@ selected yet. Only applicable to the select
widget type.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.ui.Textarea.html b/docs/jsapi/LuCI.ui.Textarea.html
index 24e8e7266..8f6562083 100644
--- a/docs/jsapi/LuCI.ui.Textarea.html
+++ b/docs/jsapi/LuCI.ui.Textarea.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -3240,7 +3242,7 @@ contents.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.ui.Textfield.html b/docs/jsapi/LuCI.ui.Textfield.html
index 38ec37d4e..0c10a90a7 100644
--- a/docs/jsapi/LuCI.ui.Textfield.html
+++ b/docs/jsapi/LuCI.ui.Textfield.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -3168,7 +3170,7 @@ corresponding <input>
element is empty.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.ui.changes.html b/docs/jsapi/LuCI.ui.changes.html
index cb4ce752d..543e5ba12 100644
--- a/docs/jsapi/LuCI.ui.changes.html
+++ b/docs/jsapi/LuCI.ui.changes.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -2352,7 +2354,7 @@ is removed.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.ui.html b/docs/jsapi/LuCI.ui.html
index 855151253..0d2768f8f 100644
--- a/docs/jsapi/LuCI.ui.html
+++ b/docs/jsapi/LuCI.ui.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -2974,6 +2976,158 @@ handler as-is without the need to bind it first.
+
+
+
+
+
+
+
+
+ instantiateView(path) {Promise.<LuCI.view >}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
Load specified view class path and set it up.
+
Transforms the given view path into a class name, requires it
+using LuCI.require()
and asserts that the
+resulting class instance is a descendant of
+LuCI.view
.
+
By instantiating the view class, its corresponding contents are
+rendered and included into the view area. Any runtime errors are
+catched and rendered using LuCI.error()
.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Name
+
+
+ Type
+
+
+
+ Description
+
+
+
+
+
+
+
+
+ path
+
+
+
+
+
+string
+
+
+
+
+
+
+
+
+
+ The view path to render.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Returns:
+
+
+
+
+
+
+
+ Type
+ Description
+
+
+
+
+
+
+
+
+ Promise.<LuCI.view >
+
+
+
+ Returns a promise resolving to the loaded view instance.
+
+
+
+
+
+
+
+
@@ -4290,7 +4444,7 @@ cancelled by the user.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.ui.tabs.html b/docs/jsapi/LuCI.ui.tabs.html
index 16d23dcfe..1678180fb 100644
--- a/docs/jsapi/LuCI.ui.tabs.html
+++ b/docs/jsapi/LuCI.ui.tabs.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -2099,7 +2101,7 @@ DOM node.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.view.html b/docs/jsapi/LuCI.view.html
index 456beee2a..ede26a161 100644
--- a/docs/jsapi/LuCI.view.html
+++ b/docs/jsapi/LuCI.view.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -2703,7 +2705,7 @@ to a Node
value.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/LuCI.xhr.html b/docs/jsapi/LuCI.xhr.html
index 474867c28..b7801c9d7 100644
--- a/docs/jsapi/LuCI.xhr.html
+++ b/docs/jsapi/LuCI.xhr.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -2667,7 +2669,7 @@ when invoked.
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/fs.js.html b/docs/jsapi/fs.js.html
index 3839d60fb..2dd663338 100644
--- a/docs/jsapi/fs.js.html
+++ b/docs/jsapi/fs.js.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -2141,7 +2143,7 @@ return FileSystem;
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/index.html b/docs/jsapi/index.html
index 127e4e59e..720d3f61b 100644
--- a/docs/jsapi/index.html
+++ b/docs/jsapi/index.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -1728,7 +1730,7 @@
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/luci.js.html b/docs/jsapi/luci.js.html
index 7455146df..3cf97d537 100644
--- a/docs/jsapi/luci.js.html
+++ b/docs/jsapi/luci.js.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -2039,7 +2041,7 @@
* response objects using the `response.headers` property.
*/
var Headers = Class.extend(/** @lends LuCI.headers.prototype */ {
- __name__: 'LuCI.Headers',
+ __name__: 'LuCI.headers',
__init__: function(xhr) {
var hdrs = this.headers = {};
xhr.getAllResponseHeaders().split(/\r\n/).forEach(function(line) {
@@ -2092,7 +2094,7 @@
* The `Response` class is an internal utility class representing HTTP responses.
*/
var Response = Class.extend({
- __name__: 'LuCI.Response',
+ __name__: 'LuCI.response',
__init__: function(xhr, url, duration, headers, content) {
/**
* Describes whether the response is successful (status codes `200..299`) or not
@@ -2914,7 +2916,7 @@
* external JavaScript, use `L.require("dom").then(...)`.
*/
var DOM = Class.singleton(/* @lends LuCI.dom.prototype */ {
- __name__: 'LuCI.DOM',
+ __name__: 'LuCI.dom',
/**
* Tests whether the given argument is a valid DOM `Node`.
@@ -3535,7 +3537,7 @@
* set of methods to inherit from.
*/
var View = Class.extend(/* @lends LuCI.view.prototype */ {
- __name__: 'LuCI.View',
+ __name__: 'LuCI.view',
__init__: function() {
var vp = document.getElementById('view');
@@ -4924,7 +4926,7 @@
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/network.js.html b/docs/jsapi/network.js.html
index 51277d671..58f3fd874 100644
--- a/docs/jsapi/network.js.html
+++ b/docs/jsapi/network.js.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -5838,7 +5840,7 @@ return Network;
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/rpc.js.html b/docs/jsapi/rpc.js.html
index 48e5a95e9..044536986 100644
--- a/docs/jsapi/rpc.js.html
+++ b/docs/jsapi/rpc.js.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -2191,7 +2193,7 @@ return baseclass.extend(/** @lends LuCI.rpc.prototype */ {
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/uci.js.html b/docs/jsapi/uci.js.html
index fe3fd48b9..f85b82b7c 100644
--- a/docs/jsapi/uci.js.html
+++ b/docs/jsapi/uci.js.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -2656,7 +2658,7 @@ return baseclass.extend(/** @lends LuCI.uci.prototype */ {
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)
diff --git a/docs/jsapi/ui.js.html b/docs/jsapi/ui.js.html
index 015a955a2..f0f5bbda1 100644
--- a/docs/jsapi/ui.js.html
+++ b/docs/jsapi/ui.js.html
@@ -1048,6 +1048,8 @@
hideModal
+ instantiateView
+
itemlist
pingDevice
@@ -5970,6 +5972,38 @@ var UI = baseclass.extend(/** @lends LuCI.ui.prototype */ {
}, this.varargs(arguments, 2, ctx));
},
+ /**
+ * Load specified view class path and set it up.
+ *
+ * Transforms the given view path into a class name, requires it
+ * using [LuCI.require()]{@link LuCI#require} and asserts that the
+ * resulting class instance is a descendant of
+ * [LuCI.view]{@link LuCI.view}.
+ *
+ * By instantiating the view class, its corresponding contents are
+ * rendered and included into the view area. Any runtime errors are
+ * catched and rendered using [LuCI.error()]{@link LuCI#error}.
+ *
+ * @param {string} path
+ * The view path to render.
+ *
+ * @returns {Promise<LuCI.view>}
+ * Returns a promise resolving to the loaded view instance.
+ */
+ instantiateView: function(path) {
+ var className = 'view.%s'.format(path.replace(/\//g, '.'));
+
+ return L.require(className).then(function(view) {
+ if (!(view instanceof View))
+ throw new TypeError('Loaded class %s is not a descendant of View'.format(className));
+
+ return view;
+ }).catch(function(err) {
+ dom.content(document.querySelector('#view'), null);
+ L.error(err);
+ });
+ },
+
AbstractElement: UIElement,
/* Widgets */
@@ -5998,7 +6032,7 @@ return UI;
- Documentation generated by JSDoc 3.6.3 on Thu Apr 02 2020 21:30:57 GMT+0200 (Central European Summer Time)
+ Documentation generated by JSDoc 3.6.3 on Fri Apr 03 2020 13:28:08 GMT+0200 (Central European Summer Time)