Resolves#3303.
This PR adds various filters to:
- Things List:
- Filter by Kind: editable, non-editable
- Filter by Thing Status
- Items List:
- Filter by Kind: editable, non-editable
- Filter by Item Type
- Rules List:
- Filter by Kind: editable, non-editable, marketplace, template-based
- Filter by Tag (existing filter)
A common component `list-filter` is added to display and perform the
bookkeeping of the filter selections.
The internal structure of the lists is defined with this general idea,
which is uniform across the three lists involved in this PR:
- Raw items (things, rules, items)
- filteredItems (with the filters applied)
- listedItems (what is being displayed by the list)
---------
Also-by: Florian Hotze <dev@florianhotze.com>
Signed-off-by: Jimmy Tanagra <jcode@tanagra.id.au>
Fixes https://github.com/openhab/openhab-webui/discussions/3381#discussioncomment-14839964.
A default HTML input type will be used based on the openHAB item type.
The user can still override by typing in a different type.
Further changes:
- placeholder of field in the item-metadata-widget will be the default
type value (based on item type) to make clear default value is being
used
---------
Signed-off-by: Jeff James <jeff@james-online.com>
For composition API usage in the future, mixins need to be converted to
composables or other module imports.
This refactors the variable-mixin to be function imports from a module.
As the mixin only included methods, this was straightforward, requiring
no code changes to the functions.
---------
Signed-off-by: Jeff James <jeff@james-online.com>
The deleted text was just copied from
bundles/org.openhab.ui.classic/src/main/java/org/openhab/ui/classic/internal/render/ColorpickerRenderer.java
At commit 30dfe0d9ee
bundles/org.openhab.ui.classic/src/main/resources/snippets/colorpicker.html
has required jquery.minicolors, and
bundles/org.openhab.ui.basic/src/main/resources/snippets/colorpicker.html
has not required it.
So the deleted text was never correct.
This adds a few enhancements to the video widget:
- 2-way audio support for WebRTC streams
- Option to start video muted
- Support for Image and String items for the poster image
---------
Signed-off-by: Dan Cunningham <dan@digitaldan.com>
Fixes#3408.
oh-state-series for fixed duration periods (State series not working in
non-dynamic modes (i.e. day, month, ...) did not work. To calculate the
min / max values for the time axis, a callback function is used where
echarts provides the min/max values of the dataset. Since echarts does
not kow about the x value in custom series dataset, the provided min/max
values are NaN. To correct, we now check for isNaN and return the bounds
for the chart itself.
Also, some minor adjustments in the dataset parameters and clipping is
now done by echarts by setting series.clip=true.
Signed-off-by: Jeff James <jeff@james-online.com>
Persistence was never implemented for the search box for
transformations. This was part of the TODO-V3.1 updates required.
Signed-off-by: Jeff James <jeff@james-online.com>
Fixes https://github.com/openhab/openhab-webui/discussions/3381#discussioncomment-14806528.
- Moved import vue-draggable-resizable.css and component to <script setup> to eliminate need to dynamically import
- Updated vue-draggable-resizable to 3.0.0
- Fixed lint error in chart-mixin with Duration import
---------
Signed-off-by: Jeff James <jeff@james-online.com>
The way the "pin" icons are currently displayed:
When an item is pinned, the pin icon is shown as red with slash. This
makes me wonder: is this item currently pinned or not?
So instead of the icon showing what will happen when it's clicked, show
the current state (is it currently pinned or unpinned). Clicking it will
toggle it.
Furthermore, when it's unpinned, show it as gray color, and when it's
pinned, show it as blue, indicating that "yes it's pinned".
-----
Signed-off-by: Jimmy Tanagra <jcode@tanagra.id.au>
This adds support for selecting markers for time and aggregate series on
chart pages.
It also adds a current time marker that allows to mark the current time
in a chart.
---------
Signed-off-by: Florian Hotze <dev@florianhotze.com>
Modifies the future parameter to allow configuring the proportion of the
period extending into the future.
Backwards compatibility with the old boolean parameter is kept.
---------
Signed-off-by: Florian Hotze <dev@florianhotze.com>
Fixes#3188
The root of the problem is that the underlying time library does not
support to set the nanoseconds only. Nanoseconds also contain the millis
and the micros. As a result, for example changing only microseconds
requires to merge the new microseconds between the millis and the actual
nano seconds. The has now been fixed in the copy-of method that allows
to overwrite them individually.
As a side effect or natural consequence, _nanoTotal_ was introduced to
retrieve the >whole< nanoseconds including millis an micros, whereas
_nano_ only retrieves the actual nanoseconds.
**Important side note or warning:**
When retrieving the current datetime with _now_ there is a precision
limitation within javascript that will only return a time with precision
milliseconds! This means that micros and nanos are always set to zero.
This is not an openHAB limitation but one that relates to javascript
only.
Signed-off-by: Stefan Höhn <mail@stefanhoehn.com>
Depends on: https://github.com/openhab/openhab-addons/pull/19443
The event object/attributes in script actions and conditions is now the
same as in JSRule and Rule Builder.
Backwards compatibility will be retained for some time, though it is
advised to adjust, which is done in this PR according to:
51f164dc9f/src/rules/rules.js (L471)
Additionally **a new return block** was added to the "Run & Process" category with return parameter.
1) The block without a return parameter is a nice improvement to easily
leave a script without using non-elegant if/else statements. Bei adding
the return statement the script is immediately ended. In this case the
return parameter is not important.
2) By adding a return parameter (in particular true or false) this can be used for script conditions
---------
Signed-off-by: Stefan Höhn <mail@stefanhoehn.com>
Related to ##3350.
This should minimize the amount of changed files and lines at least a
bit.
---------
Signed-off-by: Florian Hotze <dev@florianhotze.com>