Commit Graph

1813 Commits (5.0.0)

Author SHA1 Message Date
openhab-bot b330c03838 Preparation for tag creation (Tag name: '5.0.0'). 2025-07-21 11:59:28 +00:00
Holger Friedrich a97bf3a586
[BasicUI] Add chart option interpolation (#3279)
Implement new option `interpolation` introduced in
openhab/openhab-core#4610.

Fixes #3277.

Signed-off-by: Holger Friedrich <mail@holger-friedrich.de>
2025-07-21 08:50:56 +02:00
openhab-bot 63b79784f7
New Crowdin updates (#3261) 2025-07-18 10:34:06 +02:00
Florian Hotze 05bb624775
Item details: Fix top-level semantics value breaks view (#3274)
Top-level semantic values like Point, Equipment, Location broke the
item-details view.

Regression from #3178.

Signed-off-by: Florian Hotze <dev@florianhotze.com>
2025-07-16 00:11:49 +02:00
Florian Hotze 74da899c8d
Item edit: Fix missing semantic config breaks view (#3271)
Regression from #3178.

Signed-off-by: Florian Hotze <dev@florianhotze.com>
2025-07-14 21:43:29 +02:00
Florian Hotze b850517c01
Semantic tags maintenance page: Change icon in menu entry (#3270)
To match the icon of the semantic model.

Signed-off-by: Florian Hotze <dev@florianhotze.com>
2025-07-14 20:05:56 +02:00
Florian Hotze 4604790fcf
Semantic tags maintenance: Fix tooltip icon hardly visible in light mode (#3269)
Signed-off-by: Florian Hotze <dev@florianhotze.com>
2025-07-14 20:02:05 +02:00
Florian Hotze 9f38099898
oh-slider docs: Fix note box not rendered properly (#3268)
Signed-off-by: Florian Hotze <dev@florianhotze.com>
2025-07-14 15:51:20 +02:00
Florian Hotze 7f4a8cd6df
Model cards: Fix missing or wrong labels (#3267)
Regression from #3178.
Fixes #3260.

Signed-off-by: Florian Hotze <dev@florianhotze.com>
2025-07-14 13:12:04 +02:00
Florian Hotze 1441a34571
Config description: Fix external links not opening correctly (#3266)
Fixes #3262.

Signed-off-by: Florian Hotze <dev@florianhotze.com>
2025-07-14 12:49:16 +02:00
jimtng 4f9ab3508e
Transformation Edit: Fix missing documentation link (#3264)
Documentation link for certain types isn't displayed because the lookup
was done using the wrong key.

Signed-off-by: Jimmy Tanagra <jcode@tanagra.id.au>
2025-07-14 12:48:47 +02:00
jimtng ea9cb8501b
Transformations List: Fix incorrect counter title (#3263)
Signed-off-by: Jimmy Tanagra <jcode@tanagra.id.au>
2025-07-14 12:45:34 +02:00
openhab-bot 59ac8e259f
New Crowdin updates (#3240) 2025-07-13 23:26:38 +02:00
Florian Hotze 89e1917836 Semantic tags maintenance page: Fix searchbar not sticky
Follow-up for #3165 & #3178.

Signed-off-by: Florian Hotze <dev@florianhotze.com>
2025-07-13 17:36:49 +02:00
Mark Herwege 46038c4bf4
Add treeview semantics picker (#3178)
Closes https://github.com/openhab/openhab-webui/issues/3211.

This PR changes the semantics picker to use a treeview.

This treeview is inherited from
https://github.com/openhab/openhab-webui/pull/3165 and enhanced.
It therefore also introduces some enhancements in the semantic treeview maintenance.

The semantics treeview presents a searchable treeview of the semantic
classes/properties, limited to what is relevant in the context. When
used as a picker, radio buttons are used for picking. It has filter and
expand capabilities, options to show the semantic name and synonyms and
tooltips showing the semantic descriptions if available.


---------

Also-by: Florian Hotze <dev@florianhotze.com>
Signed-off-by: Mark Herwege <mark.herwege@telenet.be>
2025-07-13 17:28:23 +02:00
Mark Herwege 4fc03ae45a
Add to model from Thing: Allow picking existing items and groups (#3200)
Resolves #433.

Adding to the model from thing channels has been enhanced in a few ways:

- Add Points to Model: now allows to pick an existing item already
linked to the channel. The item will get default semantic tags from the
channel defaults if it does not have semantic tags already.
- Add Equipment to Model: ability to pick an existing group for the
equipment. This group will get the default equipment semantic tag from
the thing if it does not have a semantic tag already. Groups tagged as
locations cannot be selected to guard model consistency. Adding points
in this case is enhanced just as above.

When doing this, I ran into some reactivity issues with oh-icon, where
switching icon and state at the same time caused update issues. This was
caused by conflicts in the 2 watchers updating the same properties. I
fixed that by grouping these 2 elements in 1 object with a single
watcher.

---------

Signed-off-by: Mark Herwege <mark.herwege@telenet.be>
2025-07-13 16:54:48 +02:00
Nadahar ac96f8b1b7
Regenerate rule templates: Follow up for #3197 (#3232)
Follow-up for #3197.

- Fixes issue with "overcrowded" rules-list selection toolbar on narrow screens.
- Adds ability to regenerate multiple rules at once from the rules-list selection.
- Adds ability to select all rules of a certain template by clicking on the template badge in the rules-list selection.
- Shows the script type in the top bar as subtitle for scripted rules (e.g. JS Scripting).

---------

Also-by: Florian Hotze <dev@florianhotze.com>
Signed-off-by: Ravi Nadahar <nadahar@rediffmail.com>
2025-07-13 16:33:57 +02:00
Mark Herwege 0020d52ba0
Add page to edit semantic tags tree (#3165)
This adds a page with a treeview of the existing semantic tags in the
development tools and allows adding (and editing) custom semantic tags.
With this, you can maintain custom tags from the UI (it was already
possible from `tags.yaml` files before). Moving around custom tags with
drag and drop is possible.

---------

Signed-off-by: Mark Herwege <mark.herwege@telenet.be>
2025-07-13 15:06:02 +02:00
Florian Hotze e4dade77de
oh-slider: Fix display state with decimal comma parsed to integer (#3257)
Fixes #1949.
This monkey patches parseFloat to also handle decimal comma and updates
oh-input to take advantage of that.

Signed-off-by: Florian Hotze <dev@florianhotze.com>
2025-07-11 11:48:48 +02:00
Florian Hotze 5b95355280
Upgrade Maven plugins (#3252)
This aligns Maven plugin versions with openhab-core.

Signed-off-by: Florian Hotze <dev@florianhotze.com>
2025-07-11 11:45:07 +02:00
Florian Hotze bd7eeafbba
Add Maven Wrapper & Use for CI builds (#3251)
This improves DX by adding the ability to use ./mvnw, so you aren't
required to manually install Maven anymore.
It also fixes (rare) issues with platform specific Maven builds (e.g.
https://github.com/codehaus-plexus/plexus-compiler/issues/394).

Also use Maven Wrapper in GitHub Actions CI, which eliminates the need
for the stCarols/setup-maven action.

Signed-off-by: Florian Hotze <dev@florianhotze.com>
2025-07-11 11:41:49 +02:00
Florian Hotze f04c91096e
oh-slider-item: Respect `ignoreDisplayState` config & Improve docs (#3256)
Closes https://github.com/openhab/openhab-webui/issues/1503.

https://github.com/openhab/openhab-webui/issues/1503 is caused by the
display state of the Item formatting the raw state different from the
slider.
With this change, it is possible to make the oh-slider-item ignore the
display state for the displayed state value.
oh-slider also ignores the display state if that value is set.

---------

Signed-off-by: Florian Hotze <dev@florianhotze.com>
2025-07-11 10:46:09 +02:00
Florian Hotze b001427104
oh-slider: Improve docs wrt to #1949 & Add logging (#3255)
Closes #1949.

Signed-off-by: Florian Hotze <dev@florianhotze.com>
2025-07-11 10:36:37 +02:00
openhab-bot 67f0b541b0
New Crowdin updates (#3236) 2025-07-06 20:54:10 +02:00
Florian Hotze e99fd1ea51
Use versioned branch for add-on & sidebar docs (#3254)
Closes #2945.

Load the markdown source files used by the add-on details and the
developer sidebar from the versioned git branch instead of always using
the latest docs. This is implemented by loading the docs src from the
website, were Netlify redirects are used to point each version to the
proper branch.

---------

Signed-off-by: Florian Hotze <dev@florianhotze.com>
2025-07-04 17:17:09 +02:00
Andrew Fiddian-Green 8a012d3107
Location card: Various improvements and fixes (#3245)
This does:

1. The collection methods can now not only include exact Property /
Equipment values but also (_**new**_) children of those values
(optionally). This allows display of not only Lightbulb and Lightstripe,
but also any LightSource or child thereof. And also of doors and windows
that support either OpenState (digital) or OpenLevel (analog) positions;
to name a couple.
2. Aligns the code in this PR with the
[documentation](https://github.com/openhab/openhab-docs/pull/2514) and
vice versa; taking into account
[#556](https://github.com/openhab/openhab-webui/issues/556) and
subsequent PRs related to that. This PR and #3239 added support for
Motion detectors under presence, other displays under screens.
3. Cleans up the collection of lighting points to prevent duplicate
entries in the location card; that may otherwise arise when (say) the
user connects a Switch, a Dimmer, and a Color item to the same light
channel.

Resolves
https://github.com/openhab/openhab-webui/pull/3239#issuecomment-3004118138

---------

Also-by: Mark Herwege <mark.herwege@telenet.be>
Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
2025-06-29 13:24:13 +02:00
Mark Herwege 9af58f62ba
Model treeview: Fixes for drag and drop (#3223)
This fixes 2 issues:

- When picking items from model, the already checked or selected items
would not appear if these are non-semantic. It would also return a bad
selection (selecting the already selected semantic item twice). This PR
fixes it by enabling showNonSemantic if any of the selected or checked
items are non-semantic and expanding the tree to show all selected or
checked items.
- Drag/drop sometimes fails when moving into a subtree of a sibling of a
node being moved, as the added and removed events where not generated,
but a moved event is created instead. This fix also interprets the moved
event. To make things more easily understood for the users when
dragging, the ghost element is now hidden, as it sometimes showed in
another place than where it would be dropped.
- Drag/drop performance on large models was sometimes very slugish. Some
performance improvements where made that should improve this.

---------

Signed-off-by: Mark Herwege <mark.herwege@telenet.be>
2025-06-29 13:01:27 +02:00
Mark Herwege 6669b7366f
Add semantic model warnings to health menu (#3202)
Refs https://github.com/openhab/openhab-core/pull/4827.

All of the semantics warning messages that are written in the log at
startup are made available in the REST API with
https://github.com/openhab/openhab-core/pull/4827.

---------

Signed-off-by: Mark Herwege <mark.herwege@telenet.be>
2025-06-29 12:52:53 +02:00
Florian Hotze 5de2702e5b
Item metadata: Use editable field of REST response (#3250)
Follow-up for #3249.
Depends on https://github.com/openhab/openhab-core/pull/4874.

This allows to add and edit editable metadata for uneditable Items, it
only blocks edition of uneditable metadata.
For the `widget` metaddata, it allow to try out changes if not editable,
but does not allow saving them.

---------

Signed-off-by: Florian Hotze <dev@florianhotze.com>
2025-06-29 12:46:42 +02:00
Florian Hotze 005e58dab1
Item metadata: Fix metadata from uneditable Items is editable (#3249)
When viewing an uneditable item, its metadata is shown as editable in
the UI. Use the editable property of the Item to decide whether its
metadata is editable. (Technically seen you can have managed metadata
for an unmanaged item, but this will cause confusing behaviour for the
user).

Signed-off-by: Florian Hotze <dev@florianhotze.com>
2025-06-27 01:02:53 +02:00
Florian Hotze b348311926
Allow float values for widget order (#3247)
Regression from #3138.
Reported on the community:
https://community.openhab.org/t/openhab-5-0-snapshot-discussion/161404/13?u=florian-h05

Signed-off-by: Florian Hotze <dev@florianhotze.com>
2025-06-26 23:28:47 +02:00
dependabot[bot] 37b67bcf0d
Bump pbkdf2 from 3.1.2 to 3.1.3 in /bundles/org.openhab.ui/web (#3243)
Bumps [pbkdf2](https://github.com/crypto-browserify/pbkdf2) from 3.1.2 to 3.1.3.

Signed-off-by: dependabot[bot] <support@github.com>
2025-06-26 23:26:49 +02:00
Dan Cunningham fe0ec14a97
[MainUI] Support linking switch items to dimmer channels (#3242)
Signed-off-by: Dan Cunningham <dan@digitaldan.com>
2025-06-26 23:22:16 +02:00
Andrew Fiddian-Green 93a7c05775
Fix tag badges (#3239)
Resolves #3238.

Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
2025-06-24 14:24:55 +02:00
Dan Cunningham 0646db2278
Fix Matter metadata configuration options for group members (#3241)
Signed-off-by: Dan Cunningham <dan@digitaldan.com>
2025-06-23 22:48:06 +02:00
jimtng 3ce849be3e
[BasicUI] Fix multiline buttons to optimize width when set to visible (#3237)
Regression from #2388
Fix #3233

Signed-off-by: Jimmy Tanagra <jcode@tanagra.id.au>
2025-06-22 08:52:53 +02:00
Timotheos Constambeys 204ca25097
oh-colorpicker: Fix sliders not initialized in widget (#3213)
Fixes #3208.

Signed-off-by: Timotheos Constambeys <timo0190@gmail.com>
2025-06-20 14:07:59 +02:00
Mark Herwege 7151fc618e
[Blockly] Fix blockly persistence code generation (#3234)
Reported here:
https://community.openhab.org/t/openhab-5-0-milestone-discussion/162686/108

A few persistence extension calls were expecting a RiemannType input,
which should not have been there.

Signed-off-by: Mark Herwege <mark.herwege@telenet.be>
2025-06-20 13:38:57 +02:00
dependabot[bot] 2d0b1853a1
Bump webpack-dev-server from 5.0.4 to 5.2.1 in /bundles/org.openhab.ui/web (#3214)
Bumps
[webpack-dev-server](https://github.com/webpack/webpack-dev-server) from
5.0.4 to 5.2.1.

Signed-off-by: dependabot[bot] <support@github.com>
2025-06-20 13:37:37 +02:00
Mark Herwege 0d52054c3c
Make Main UI log levels configurable (#3226)
As console logging consumes a considerable amount of time, even when
the browser console is closed (especially since logging objects requires
deep cloning them), implemented a UI wide log level.
The log level allows to only log to the console when the level is above a
set value. These levels mimic the OH server side log levels.

The log level for the browser can be set in an extra developer tools
screen entry, and are persisted in the browser store when set.
The default logging level is INFO (will include ERROR and WARN), thereby
disabling `console.log`, `console.debug` and `console.trace`.

The impact is UI wide.

---------

Also-by: Florian Hotze <dev@florianhotze.com>
Signed-off-by: Mark Herwege <mark.herwege@telenet.be>
2025-06-18 09:39:54 +02:00
openhab-bot b8cb689ea2
New Crowdin updates (#3206) 2025-06-17 15:21:14 +02:00
Holger Friedrich 70eb1e072a
Use Maven 3.9.10 for CI build (#3219)
See release announcement
https://lists.apache.org/thread/bh8hr89omrbw19ychrklyh3rompn1hj7

Signed-off-by: Holger Friedrich <mail@holger-friedrich.de>
2025-06-17 15:19:27 +02:00
stefan-hoehn ac2d89abdd
Add blockly "rule enable" block (#3209)
fixes #3096

Adds a new block to allow enabling/disabling rules.
Variables of type Boolean and String are supported. A String with "true"
or "enabled" will be converted to true, all other values will result
into false.

<img width="471" alt="image"
src="https://github.com/user-attachments/assets/30210a96-5adb-4b65-ad45-0e6a082fe486"
/>

I also added Boolean to typed variables as this was missing:

<img width="417" alt="image"
src="https://github.com/user-attachments/assets/30cf9ec1-46bd-45d8-95bc-6fb11ea99a16"
/>

I used "as" because I think this is the most intuitive way of describing
what the block does, in particular when you use "enabled". If anyone has
a better idea to make the block design better, then please provide
feedback. Using a dropdown with Note that "Enable/Disable" ruleUID would
be nicer but would not allow to use variables.

---------

Signed-off-by: Stefan Höhn <mail@stefanhoehn.com>
2025-06-15 20:05:12 +02:00
Nadahar 548d1c6d36
Regenerate rule templates (#3197)
This PR depends on https://github.com/openhab/openhab-core/pull/4718.

It does several things, but the major points are:
* It enables regeneration of rules based on rule templates from the UI.
Regeneration can be desirable if the rule template has been updated and
you want the rule(s) to reflect the change, or if you wish to change one
of the parameters, for example to make the rule work with a different
Item.
* It restores the display of read-only/unmanaged rules in the UI. It is
currently broken because all read-only rules are forwarded to the script
editor, effectively hiding the rule editor, unless you modify the URL
manually. This is very relevant for
https://github.com/openhab/openhab-core/pull/4633, whose rules will
otherwise be quite meaningless in the UI (they will still work, but you
won't be able to see what they do from the UI).
* It provides a third tab "Source" to the rule editor that shows the
"source script" used to create the rule, if the rule is supplied via a
JSR223 based scripting add-on, *if* the "source script" is embedded as
metadata with the rule. This is the current practice with most JSR223
based scripting add-on provided rules, and is the only situation where
showing read-only rules in the script editor makes any sense. The
"Source" tab is thus a replacement for removing the forwarding to the
script editor. Rules that have embedded "source scripts" will by default
open in the "Source" tab, so that the difference for these rules will be
minimal, while it also allows other read-only rules to work.

In addition to the above points, there are quite a few bug fixes that I
have come over while debugging/testing this.

There's a lot that could be said about the details here, but I know from
experience that if I attempt to describe everything, people won't read
it. So, I tried to make this description brief, and can instead
elaborate on any subjects on demand.

---------

Signed-off-by: Ravi Nadahar <nadahar@rediffmail.com>
Co-authored-by: Yannick Schaus <github@schaus.net>
2025-06-15 19:49:05 +02:00
lolodomo f1bc650743
[BasicUI] Reload the chart with higher dimensions when zooming (#3183)
When zooming, instead of just upscaling the previously loaded chart, a
new chart is built using available width as new chart width. Upscale is
kept and will be used in case the user defined a maximum width for
charts that is lower than the available width.

Closes #3139

Signed-off-by: Laurent Garnier <lg.hc@free.fr>
2025-06-14 13:55:46 +02:00
stefan-hoehn c12c18cdde
[blockly] Fix typed var not working for dictionary (#3210)
Fixes #3038.

Signed-off-by: Stefan Höhn <mail@stefanhoehn.com>
2025-06-06 19:02:15 +02:00
Holger Friedrich b76889373a
Add top dir marker for Maven 4 (#3203)
This suppresses the warning about missing top level directory marker
during build with Maven 4.
The approach to add `.mvn` dir is the option to do it which does not
impact our standard builds with Maven 3.

Signed-off-by: Holger Friedrich <mail@holger-friedrich.de>
2025-06-01 11:16:26 +02:00
Dan Cunningham 6c66733bd9
Add Matter metadata (#3129)
Refs https://github.com/openhab/openhab-addons/pull/18486

---------

Also-by: Florian Hotze <dev@florianhotze.com>
Signed-off-by: Dan Cunningham <dan@digitaldan.com>
2025-05-28 17:23:40 +02:00
Mark Herwege 60d7f8cf3f
Model editor: drag drop fixes (#3199)
This is a follow-up for #2970.

This applies 2 fixes:

1. Extra non-semantic tag was added with value equal to semantic class
when semantic item was moved.
2. On larger models, SortableJS and Vue DOM updates sometimes got out of
sync. This is solved by forcing SortableJS to use the fallback that does
not directly update the DOM.

Signed-off-by: Mark Herwege <mark.herwege@telenet.be>
2025-05-26 20:46:10 +02:00
openhab-bot 2e9c8c8e0c
New Crowdin updates (#3189) 2025-05-26 20:31:05 +02:00