Is it possible to have the color of a widget change when the item changes? For example, I would like a door widget to change red when the door is open. I have it working when the door is open and the page is refreshed, but when the page is already open only the item status changes in the panel, not the color.
This is my current ng-style setting in my custom door widget.
A questions on top of that. I want to have a box in habpanel showing status of all windows. It would be nice to show box in green if all windows are closed and in red if one or more windows/dores are open. Has anyone done something similar and can help me with this?
Thanks.
Yes, this is the exact scenario I was working on. I created 2 custom widgets, 1 for single doors/windows, and 1 for groups of items. If door/window in the group is open, the color changes to red.
Attached are the widgets. Within the widget settings you can pick the open and closed colors, and icon. It assumes the standard icons, so if you type âwindowâ for the icon setting, it will use the icons window-open and window-closed depending on the state. I also have an icon size setting as I use the same widgets on a table and a phone, and for the phone I needed smaller image sizes.
@ David. Great. I thought of displaying al list of the items. But this is even better. THANKS! I now have to figure out, how to integrate. Hoepfully tonight I have some time when kids are in bed. I am just a beginner mirgrating from the Fibaro HC2.
Thanks to everyone in this forum for joining your experience. This realy helps much to move forward.
@ David: An additional question: can you also share your code for the two weather widges? The would cover my needs. For the beginning I started with a workaround. I integrated a small html file I have saved in a folder on my website. This contains the code that was provided form a weather website as html code for integrating in your website. Works, but does not look that nice⊠I started with getting an api-code from weahterunderground. For the beginning my plan was to work only with 2.0 bindings. But I think I will start with playing around with the âoldâ ones as well.
Sure here they are. They may not look great on a larger screen. I was specifically trying to shrink these down to fit on a phone, with the assumption that the phone is only 3 columns of widgets. With that in mind, you need to size the widgets to be 2 columns wide.
Great. Thanks for sharing. In my current old set up I have a fibaro wall-plug. its color is green when windows are closed and it turns red, when a window is open. The wall plug is next to the android tab close to the entrance door. Unfortunately it looks like there is no item for the wall plug to change its color. In the Fibaro-world there is a virtual device that can be imported. And than you can âpressâ via a line in lua-code different buttons to change the color. So I do not have to switch the tab on. I directly see red/green before I leave the house. Others are using a hue that covers this functionality.
Iâm not sure I fully understand, and know nothing about fibaro, but if there is a way to send a command to the switch to change the color, then you could likely have a rule created to send the command whenever there is a status change for the group of items.
I have successfully included my first Z-Wave device last weekend - a Fibaro Wall Plug. And it is working.
One of the available things is âColor when Onâ and another âColor when Offâ there are values from 0 to 8 possible.
Adding this in HabPanal as a slider is working excelent.
So I can integrate the functionality I am aiming for
Seems to work great. The garage one is the only one I have currently configured and working correctly. I have it tied to my MyQ binding, but would like to use this with the DSC Alarm binding instead. Still have more work to do.
but if I try something similar for the icon definition it does not. Iâve tried putting that in the same place as the background color, inside the widget-switch braces, and in the button2 definition to no avail.
First of all, thanks for creating this widget. The post is a bit older, but I only came across it recently and I have a question.
I installed the widgets in the HabPanel as well as created the group item. So far so good.
Values arrive when there is a change in the item(s) (for me ON and OFF) and are also correctly displayed in the group item (value change for me â ON: OFF).
But what somehow doesnât work is changing the color of the widget. However, the value does not change color. Likewise, the icon does not change from window closed to window open.
Is there still a rule missing or am I doing something wrong in principle?
In the widget code itself there is OPEN / CLOSE in relation to the âbackground-colorâ â Item.value == OPEN, does it have something to do with the fact that the states do not change? Is an OPEN / CLOSE expected and an ON / OFF received?