android icon indicating copy to clipboard operation
android copied to clipboard

Allow for backup and transfer of widgets between client devices and connected server.

Open mattlward opened this issue 3 years ago • 5 comments

Is your feature request related to a problem? Please describe.

Kind of... I manage the Companion app installs on my families phones. On my S10+ this is a full screen of widgets and others in the house less, but different in some cases.

Describe the solution you'd like

I would love to see the widgets from each device either backed up to the server that the devices connect to or I would like to be able to share widgets between devices on the same server. To me, it would make the most sense to automatically store new or changed widgets on the server at time of creation or modification with the ability to edit them on the server via the normal browser connection. Then from a client running Companion download or push the widget to the client device.

Describe alternatives you've considered, if any

Additional context

mattlward avatar Sep 02 '22 23:09 mattlward

with the ability to edit them on the server via the normal browser connection

Would you expect a graphical interface with a preview? Or more like YAML code you can edit? Either way this isn't trivial, as far as I'm aware something like this isn't something currently supported by HA core.

push the widget to the client device

Android doesn't allow apps to add widgets to the home screen by itself, this always has to be done by you/the launcher. The app can only update widgets that were already added.

jpelgrom avatar Sep 03 '22 19:09 jpelgrom

I think if the widgets were backed up to maybe /config/widgets or some other similar folder where average users and admin users could read and and write the files would be great.

As far as editing them, from my standpoint a yaml style editor would be fine. But, I am sure that the long term route would be something like the automation editor. I am not sure that a preview for a code action would be needed. By default there is no preview on the android device, one must "update widget" to test it.

For starters... just being able to push and pull widgets to and from the server would be amazing... at that point, I would not really even care if I could edit them.

mattlward avatar Sep 04 '22 03:09 mattlward

Followed your link... this is exactly why I would like to be able to back them up. Having to remember the config for each and every one of these is a pain. image

mattlward avatar Sep 06 '22 22:09 mattlward

The minimum would be backup.... Came here because I was going to open a request for it and found this request. Esp. with the template widget one could have spend a serious amount of time to get it right. Loosing it would be painful. The App allows already to see the widget content in the settings. Having a button "backup" to transmit the content to the HA server and just being able to restore the widget from there would be of great help and give some peace of mind.

In the next steps a restore function could be created by allowing people to add a new widget (manually through the android starter), but selecting a new type "existing widget". This will ask for the name of one of the backuped widgets and copy the content over, basically restoring it.

Finally, I agree totally with @mattlward that managing different widgets on different devices shared among different family members could be a nightmare. It would be nice if one has a local place in the server to manage all those, make changes and push them to the desired devices. However, I can see that this requires much more work to get it in.

torwag avatar Jun 10 '23 17:06 torwag