Commit Graph

9 Commits (b885158e07b403f8a6ba85a06469987bbd3c72a4)

Author SHA1 Message Date
Yannick Schaus 5bf98457f4
Add a Scene settings menu entry and editor (#1662)
Closes #1528.

The scene editor allows defining Item — command pairs that are applied when the scene is activated. While designing a scene, it is possible to sync the target state to the current Item state and test the target state command.

Technologically scenes are just rules without triggers, so they can be activated using the „Run Rule, Script, Scene …“ action.

Signed-off-by: Jan N. Klug <github@klug.nrw>
Signed-off-by: Yannick Schaus <github@schaus.net>
2023-02-16 22:25:26 +01:00
Yannick Schaus e2f06a2cd6
Add context parameter to rule action (#1582)
Signed-off-by: Yannick Schaus <github@schaus.net>
2022-12-15 19:29:09 +01:00
Florian Michel 1d7a3a9875
Add possibility to edit JSON variable keys in widgets (#1556)
Implements a possibility to work with nested JSON objects/arrays in widget variables. It allows to set the value of a custom key of the variable. The key can be nested in any depth to allow more complex scenarios. 

Adds a new action configuration `actionVariableKey` which allows to set the key of the object. The configuration syntax is like this:
```
actionVariableKey: name
actionVariableKey: user.name
actionVariableKey: user[0].address[1].street
actionVariableKey: [0]
actionVariableKey: [0].label
```

If you want to edit the key `user.name` but the key `user` is missing in the object, the parent hierarchy is automatically created. (Same applies if you want to add an value to an array but the array is not existing) This should make it easier for not so advanced users.

Signed-off-by: Florian Michel <florianmichel@hotmail.de>
Also-by: Yannick Schaus <github@schaus.net>
2022-12-11 12:35:11 +01:00
Florian Hotze e0b95d6764
[MainUI] Evaluate expressions in configuration Arrays & Update `actionPhotos` docs (#1519)
* [MainUI] Improve docs for the `actionPhotos` prop & Make Item start with uppercase

Signed-off-by: Florian Hotze <florianh_dev@icloud.com>

* [MainUI] Regenerate component docs

Signed-off-by: Florian Hotze <florianh_dev@icloud.com>

* [MainUI] widget-mixin:  Evaluate expressions in Arrays

This adds support for evaluating expressions in Arrays of the configuration of a component.

Signed-off-by: Florian Hotze <florianh_dev@icloud.com>

Signed-off-by: Florian Hotze <florianh_dev@icloud.com>
2022-10-09 02:40:07 +02:00
EngiNearEngiFar 9a8ff85c6a
Update oh-icon.md (#1493)
wrong link for f7 icons -> fixed
2022-09-24 21:43:04 +02:00
Yannick Schaus 01cee7bb29
oh-icon component improvements, Iconify icon support (#1149)
This allows the oh-icon to display both from more sources than the
OH icon servlet; bundled Framework7/Material icons can also be displayed
by this component (use `f7:` or `material:` prefixes).
Specifying no prefix will assume an OH icon for backward compatibility.

This also introduces Iconify (https://icon-sets.iconify.design) as an
icon source, allowing access to 100,000+ icons from various icon sets,
to display them in widgets like cards or floorplan markers.

The Iconify option requires Internet connectivity on the client to access
the external API but the underlying library will cache the icons in
local/session storage to limit the requests and speed up the rendering.

Update/fix documentation and plan marker default icon registration.

Signed-off-by: Yannick Schaus <github@schaus.net>
2021-08-30 00:58:46 +02:00
AndyXMB 184c6dab2f
Component docs (#900)
Signed-off-by: Andrew Black <andrewm.black@outlook.com>
Also-by: Yannick Schaus <github@schaus.net>
2021-03-01 15:42:17 +01:00
Yannick Schaus 5e7c092f55
Add frontmatter to component reference pages (#881)
Regenerate docs.

Signed-off-by: Yannick Schaus <github@schaus.net>
2021-02-05 19:22:23 +01:00
Yannick Schaus ba4d76fe9a
Add generated component reference (#864)
Add a Node.JS script to generate or update Markdown documentation from
the definitions of components. Generate an initial set of pages.

Signed-off-by: Yannick Schaus <github@schaus.net>
2021-02-05 15:16:35 +01:00