* Add dagger module for daos
* Update classes in common to inject daos
* Update app view models to use inject
* Use inject with widgets
* Update app activities and fragments to use inject
* Clean up imports
* Make TileExtensions use coroutines
- Instead of silently failing, inform the user that a sensor cannot be enabled due to missing permissions and provide a link to change the setting. If possible, name the specific permission that is required.
* Sync sensor enabled state from app to core
- Change sensor 'registered' to indicate not registered, registered as disabled or registered as enabled
- When a sensor is disabled, set it's status as such on core 2022.6 servers
- In the sensor registration, use the basic sensor details in case there is no info in the database that can be used
* Clean up version check
- Now that there is a standard function to get the version, re-use it
* Improve which sensors are synced to core
- Update database migration to reset registration state on db upgrade to make sure the information is correct for all sensors
- Only sync sensors that are actually available on the device
- Fix registering all sensors on core <2022.6 on app/core version change
- Fix unnecessary sensor updates due to location sensors which are never registered always triggering update on core >=2022.6
* Sync sensor enabled state from core to app
- After pushing app enabled changes to core, if on core 2022.6 check if the enabled state for any of the sensors is different from what is registered in the app and try to update the sensors. This is done by reading the entire config, because otherwise we wouldn't know about sensors that have been enabled and the app already updates all sensors at the same time so no need for tracking individual updates in the sensor update response.
- Restore getting config using webhooks, because only the webhook config contains information about entity enabled state
- Add support for opening a specific sensor's settings page, used for the notification when trying to enable a sensor that requires granting (additional) permissions
* Update Media Player Widget Preview
* Add support for multiple media players. optionally show media source label
* fix crop of media player widget preview image. avoid unnecessary api call's when finding active media player. add db migrations. add text color to media source label. set default value of showsource to false.
* remove placeholder source for source icon to fix widget preview
- Use unique tags to allow identifying which function receives an error
- Actually use the onReceivedSslError callback error
- Also show SSL errors in the external auth callback
* Provide Compose preview for Play Store listing screens
* Update previews for onboarding
- Set theme correctly and show system UI
- Add variant for dark mode
* Update Wear OS listing image
* Remove specific icon, we can use domain default
* Improve time zone sensor string
- Update string to reflect if the time zone is using summer/daylight savings time or not
- Use the user's language settings instead of always using English
* Keep using English for sensor state
- Catch any exceptions thrown during app registration (after webview login) instead of crashing. There should only be a few errors possible here that are not encountered in the webview.
- Set dialog theme to fix background on API <31
- Set the width of the LazyColumn, which provides the scrollable container for this screen, to the full width of the screen to also allow scrolling the screen when touching on the right of narrow buttons
- The touch target for the refresh button is really small and there aren't any other conflicting actions, so allow tapping anywhere to refresh the content
* Check if device supports BLE transmitter
* Always send a state instead of blank string
* Add attribute if transmitter is supported instead of sensor availability
* Add transparent widgets
- Add options to the service, entity and template widgets to have a transparent background
- Register configuration change intent filter for widgets in order to be able to respond to day/night changes (no longer fully automatic due to setting color with int)
* Support Material You dynamic color in widgets
- In widgets that support theming (day/night or transparent), add an option to use Material You dynamic colors
- Dynamic colors is now the default widget style for new widgets on devices that support them
* Tweak dynamic color theming
- Update dynamic color values to better match other themed widgets such as those from Google
- Remove configuration changed intent receiver for widgets because it is no longer required to get colors
* Add dynamic color theming to media player widget
- Make the media player widget themeable and add an option to use dynamic colors (transparent doesn't make sense for this layout)
* Fix camera widget background if data cannot be loaded
* Add text size option to template widgets
- Added an option to set the text size to template widgets to better align with other widget options
* Additional Android 12 widget updates
- When using the dynamic color theme, also use the new Android 12 widget corner radius
- Update placeholder values in widgets to match images, and refer to dynamic color XML to provide a better preview on Android 12. Reset values when providing template to match existing behaviour when no widget is found in the database.
- Update entity state and template widget target size to 2x1 to match preview image
- Make sure media player album art doesn't extend past corner radius if possible
* Change theme selection to dropdown, text color alignment
- Change theme selection to use a dropdown menu (Spinner) instead of right-aligned radio buttons on multiple lines
- Change text color selection to left-align radio buttons
* Notification sensors: convert extra bundle arrays to lists
- If the notification extras contain any arrays, convert them to lists because when stringified, this will create a human readable text like "[Message 1, Message 2]" instead of something like "[Ljava.lang.String;@5d099f62"
* Convert BaseBundle arrays to lists as well
- Include array types that are in the superclass BaseBundle as well when converting values to a list
- Moved to another function to limit duplicated code
* Map bundles within a notification's bundle as well
- Also map any bundles we find inside a bundle, or if there is an array of bundles, to make this information readable as well
* Breaking change: send sensor list attributes as list to server
- Send a sensor attribute that is managed by the app as a list, to the server as a list as well instead of a stringified version of a list.
* Fallback to string for lists that include separator
- To prevent issues where we can't distinguish the list items separator from a value that includes the separator, don't try to convert a value to a list if that is the case but instead use string
* Improve string fallback for lists that include separator
- Instead of only falling back when a list includes a String with the separator, just use toString() to also support other objects which might include ", " when stringified, such as nested lists
* Store list data as JSON
- To remove any confusion when sending individual list items, store data as JSON to escape characters if necessary
- Map Any data in a list that is not any of the specific types to string, for consistency with the same types when not in a list and to prevent JSON serialization issues
* Ensure current mode is also supported for climate entities
* Don't crash when creating control fails
- Handle failures while creating a control gracefully: skip controls when showing all available controls, and show an error tile similar to network errors for existing controls
- Fix the Wear OS settings activity (seemingly) endlessly loading if there are no connected devices, by showing a proper error message for this situation
- Set title for Toolbar
- Show a chip suggesting the user to add the SSID of the currently connected network, if not already added to the list of home SSIDs, in the home SSID dialog
- Change icon for listed SSIDs in home SSID dialog to DKGRAY by default, and only show currently connected SSID icon in accent color
- Add missing contentDescription for ImageButtons
- Use correct tint namespace
- Update deprecated code