Commit Graph

1397 Commits

Author SHA1 Message Date
dependabot[bot]
9aece78bce
Bump hilt from 2.50 to 2.51 (#4234)
* Bump hilt from 2.50 to 2.51

Bumps `hilt` from 2.50 to 2.51.

Updates `com.google.dagger:hilt-android-compiler` from 2.50 to 2.51
- [Release notes](https://github.com/google/dagger/releases)
- [Changelog](https://github.com/google/dagger/blob/master/CHANGELOG.md)
- [Commits](https://github.com/google/dagger/compare/dagger-2.50...dagger-2.51)

Updates `com.google.dagger:hilt-android` from 2.50 to 2.51
- [Release notes](https://github.com/google/dagger/releases)
- [Changelog](https://github.com/google/dagger/blob/master/CHANGELOG.md)
- [Commits](https://github.com/google/dagger/compare/dagger-2.50...dagger-2.51)

Updates `com.google.dagger.hilt.android` from 2.50 to 2.51
- [Release notes](https://github.com/google/dagger/releases)
- [Changelog](https://github.com/google/dagger/blob/master/CHANGELOG.md)
- [Commits](https://github.com/google/dagger/compare/dagger-2.50...dagger-2.51)

---
updated-dependencies:
- dependency-name: com.google.dagger:hilt-android-compiler
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: com.google.dagger:hilt-android
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: com.google.dagger.hilt.android
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* Remove protected from ServerManager inject

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Joris Pelgröm <joris.pelgrom@gmail.com>
2024-02-29 17:27:05 -05:00
Joris Pelgröm
835b50f0e3
Update Assist dialog state when transitioning locked<>unlocked (#4235)
- Update the dialog flags for showing the Assist dialog when locked to prevent unintentional resuming in another locked state and clear contents when resumed intentionally (assistant intent action)
2024-02-29 17:26:07 -05:00
dependabot[bot]
48ac7037c2
Bump com.github.Dimezis:BlurView from version-1.6.6 to version-2.0.4 (#4220)
* Bump com.github.Dimezis:BlurView from version-1.6.6 to version-2.0.4

Bumps com.github.Dimezis:BlurView from version-1.6.6 to version-2.0.4.

---
updated-dependencies:
- dependency-name: com.github.Dimezis:BlurView
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>

* Fix build: use convenience method which sets algorithm, remove functions matching defaults

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Joris Pelgröm <joris.pelgrom@gmail.com>
2024-02-24 19:37:26 +00:00
Daniel Shokouhi
2e30f270ee
Update change log week of 2/23 (#4222) 2024-02-24 09:55:51 -08:00
Daniel Shokouhi
b3b61ae5bf
Add command screen off to write permissions method (#4223) 2024-02-24 12:28:51 -05:00
StopMotionCuber
45e0ca9caa
Add ability for ClimateControl Card to cycle through entity states (#4142)
* Add ability for ClimateControl Card to cycle through entity states

* Fix ktlint issue

* Set `currentMode` after sending request for cycling through modes

* Display thermostat always as "on"

* Use "toggle" string from widget_tap_action_toggle

* Use hashMap to save states of entities as we're in a singleton

* Include support for colliding entityIds when using multi server within ClimateControl

* Add comment why ToggleRangeTemplate is always set to checked
2024-02-22 17:06:43 -05:00
dependabot[bot]
15b1518a44
Bump org.jlleitschuh.gradle.ktlint from 11.6.1 to 12.1.0 (#4125)
* Bump org.jlleitschuh.gradle.ktlint from 11.6.1 to 12.1.0

Bumps org.jlleitschuh.gradle.ktlint from 11.6.1 to 12.1.0.

---
updated-dependencies:
- dependency-name: org.jlleitschuh.gradle.ktlint
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* Add .editorconfig

* ktlintFormat

* Fix comment in a 'value_argument_list' is only allowed when placed on a separate line

* Restore AssistShortcutView

* Fix comment in a 'value_argument_list' is only allowed when placed on a separate line

* Fix no comment expected at this location

* Fix property name should start with a lowercase letter and use camel case

* Fix parameter comments

* Fix comment in a 'value_argument_list' is only allowed when placed on a separate line, again

* Fix property name should use the screaming snake case notation when the value can not be changed

* Fix final comment in argument list

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Joris Pelgröm <joris.pelgrom@gmail.com>
2024-02-06 21:02:39 -05:00
Daniel Shokouhi
075bc50a07
Update change log week of 2/2/24 (#4186) 2024-02-02 17:18:25 -08:00
Joris Pelgröm
98f3d7abd2
Add option to update camera & template tile when 'in view' (#4185)
* Add option to update camera & template tile 'on view'

 - Use the tile enter callback to request an update to the tile once it enters the view. Considering that this callback exists it's probably safe to assume an update that is requested in this callback won't be throttled (at least it appears to work during testing).
 - Minor edit to the refresh interval picker to ensure strings that are more than one line look a bit nicer.

* on view -> in view
2024-02-02 16:44:22 -05:00
Joris Pelgröm
f95b482e53
Replace deprecated MdcTheme with 'normal' theme matching XML theme (#4182)
- MdcTheme appears to have been deprecated in the latest release. Replace it with our own theme everywhere it is used. Thankfully, because the modifications for the HA (XML) theme are very minor compared to a default Material theme there's not a lot to define/duplicate.
2024-02-02 15:30:41 -05:00
Jorden
1786a7d3e6
Fix button widget on Samsung devices (#4181)
Fix button widget
2024-02-02 15:27:03 -05:00
Márton Maráz
c185b871fd
Make volume sensors update instantly by subscribing to a broadcast (#4162)
* Make volume sensors update instantly by subscribing to a broadcast

* Change skippableActions to a 1-to-many map and the list of all volume sensors to the corresponding Intent action key
2024-02-02 15:25:55 -05:00
Daniel Shokouhi
44807af50f
Update change log week of 1/26 (#4163) 2024-01-27 10:17:02 -08:00
Joris Pelgröm
97d312bdd6
Androidx dependency updates late Jan 2024 (#4165)
- Update Wear Assist alignment to keep same appearance of an inline chevron to change the assistant
2024-01-27 17:58:40 +00:00
Joris Pelgröm
c6ddca8fdc
Support image entity in camera widget (now renamed picture widget) (#4159)
- Allow selecting image entities in the camera widget
 - Rename camera widget to picture widget to better reflect camera + image entity support
2024-01-25 17:02:51 -05:00
Joris Pelgröm
d9e65f8e5d
Remove Thread credential sync from start of Matter commissioning flow (#4150)
- After discussion with Thread dev, remove Thread credential syncing from the start of the Matter commissioning flow. There are 2 major reasons for this:
   * it significantly slows down the flow while only being useful some of the time
   * the results have limited usefulness because the API limits how much Home Assistant can influence the device data
  The alternative for the user is to use the manual 'import credentials' button in the frontend (matching iOS), or access the sync option in the app settings > troubleshooting menu.
2024-01-24 13:06:48 -05:00
Iván Cea Fontenla
b0f1aa2906
Integrate car sensors with automotive, and added permissions (#4122)
* Integrate car sensors with automotive, and added permissions

* Set context in every call

* Fixed CarSensorManager format

* Enable car sensors only on correct flavors

* Fixed format

* Renamed context to latestContext and added parenthesis to expression
2024-01-24 10:57:27 -05:00
Sebastian Lövdahl
5d52735e36
Support multiple Template tiles on Wear OS (#3783)
* Support multiple Template tiles on Wear OS

* Add `TemplateTileConfig` data class

* Fix migration

* `Pair` -> `TemplateTileConfig` fixes

* Fix `getAllTemplateTiles` implementation

* Initial work on companion <-> wearable device communication

* More work on phone <-> wear device communication

* Save updated template in phone app

* Get the template to render using the right method

* Fix CI complaints

* Work on Wear UI for multiple template tiles

* Update wear manifest

* Wear migration and navigation fixes

* Fix Template tile IDs in mobile app

* Make adding a new Template tile on Wear device work

* Small cleanups and TODO fixes

* Try to fix template config refresh in settings

* Fix after rebase

* Adopt blocking approach for reacting to tile events, inspired by #3974

* Use `OpenTileSettingsActivity` for template tile

* Adopt Material 3 and other UI-related changes

* Show help text in phone app if no template tiles have been added yet

* Reference the view model variable inside the function

By having the view model variable outside the block, the updated template tile
might not be propagated to the template settings view.

* Reload template tiles when opening the template tiles from settings

* Replace null key with -1 for old template tile

* Lint complaints fixes

* remove TODO

* Store error

* Scrollable list of template tiles

* Move "Configure template tile" to header

* Replace with methods with copy

* Show template as secondary text

* Fix scrolling

* Update app/src/full/java/io/homeassistant/companion/android/settings/wear/views/SettingsWearTemplateTileList.kt

Co-authored-by: Joris Pelgröm <jpelgrom@users.noreply.github.com>

* Remove unused field

* Move padding to "no tiles" text

* Add deep link

---------

Co-authored-by: Joris Pelgröm <jpelgrom@users.noreply.github.com>
2024-01-24 10:56:39 -05:00
Daniel Shokouhi
b3b74fae0e
Update change log week of 1/12 (#4133)
* Update change log week of 1/12

* Update matter and thread change
2024-01-12 12:07:53 -08:00
Joris Pelgröm
a5efe6a9ab
Support for Thread "import credentials" from frontend (#4128)
* Support for Thread "import credentials" frontend action

 - Add support for the frontend action to import Thread credentials, or better said export Thread credentials from the device. This is essentially a very basic sync.

* Rename/reorder reused Matter code

 - Change names and order of reused Matter code for Thread importing to prevent potential confusion

* Update minimal implementation
2024-01-12 09:20:57 -05:00
Daniel Shokouhi
b4c4c7a458
Update change log week of 1/5 (#4117)
* Update change log week of 1/5

* Add note about Matter
2024-01-05 18:07:24 -08:00
Joris Pelgröm
f1fcabb0c9
Send IP address of Matter device for on network commissioning (#4069)
* [WIP] Send IP of device during commissioning

* Add version check for IP address in commission_on_network

* Update minimal
2024-01-04 14:29:19 -05:00
Joris Pelgröm
1162a82c48
Suppress system Matter device discovery bottom sheet (#4062)
- Prevents the system's Matter device discovery bottom sheet from showing up while the Home Assistant app is opened.
2023-12-20 12:26:04 -05:00
Joris Pelgröm
7cc545bfac
Fix button widget authentication dismissed due to non-foreground window (#4066)
- Fixes the button widget authentication dialog automatically being dismissed when triggered on Android 14 QPR1+, because the window was not in the foreground. It looks like the framework check for this was bugged before QPR1, and the Home Assistant app was showing the authentication dialog before the window (which is transparent) was in the foreground.
2023-12-20 12:25:06 -05:00
Daniel Shokouhi
1fa6ec463e
Update change log week of 12/15 (#4058) 2023-12-15 10:13:35 -08:00
Joris Pelgröm
62414e4cd5
Migrate BuildConfig to Gradle Build Files (#4049)
- Addresses the following warning: The option setting 'android.defaults.buildfeatures.buildconfig=true' is deprecated. Each module uses the BuildConfig class so it's added everywhere.
2023-12-15 12:46:48 -05:00
Steffen Klee
e0731c9c79
Add Wear OS TLS client certificate authentication (TLS CCA) support (#3924)
* Add Wear OS TLS client certificate authentication (TLS CCA) support

Wear OS does not currently allow the user to install certificates to the
system-wide KeyChain for TLS CCA support. This commit adds support for
using certificates from the app-specific Android KeyStore with UI for
setting up a certificate during the Wear OS onboarding process.
The manual step in the onboarding process is required since we cannot
transmit certificates of the Android KeyChain because they are not
extractable.

In particular, this commit adds the following changes:
* KeyStoreImpl as an additional KeyChainRepository interface
  implementation for loading and storing keys to the application's
  KeyStore. TLSHelper uses KeyStoreImpl as a fallback key manager.
* UI for selecting a certificate file with GET_CONTENT intent during
  Wear OS onboarding in OnboardingActivity if it is detected that the
  Home Assistant may require TLS CCA. The UI includes a password check
  for the PKCS12 container.
* During onboarding the app sends the raw PKCS12 data to Wear OS
  together with the container password. The connection is assumed to be
  encrypted and trusted so that no additional encryption is necessary.

* Move PKCS12 password check to lifecycle scope

* Remove redundant try-catch when loading PKCS12

* Simplify MobileAppIntegrationView layout code
2023-12-13 15:19:54 -05:00
Joris Pelgröm
df902803ab
Check controls while locked setting when using panel (#4047)
- When using the device controls panel instead of individual/native controls on Android 14, also check the setting for using controls while the device is locked and if so block the panel (as the frontend doesn't have a read only mode).
2023-12-13 14:47:55 -05:00
Paul Biester
5d779a27aa
Fix target temperature step attribute name error (#4039)
Fix wrong attribute name for the target temperature step. Correct one is target_temp_step (which is returned by the API) instead of target_temperature_step
2023-12-13 14:46:36 -05:00
Joseph Abbey
6b56bc579a
mobile_app_notification_cleared for wearos (#4035)
* mobile_app_notification_cleared for wearos

* Fix imports

* Remove database id extra

* Fix whitespace

* Reformatted imports and added the receiver to the manifest

* Move `handleDeleteIntent` to common
2023-12-13 14:45:46 -05:00
Daniel Shokouhi
4aaec08127
Update change log week of 11/24 (#4029)
* Update change log week of 11/24

* Mention new default value for BLE transmitter
2023-11-25 10:04:24 -08:00
Daniel Shokouhi
1aa56166c7
Catch potential play services errors (#4019) 2023-11-22 13:12:47 -05:00
Ruben van Dijk
f5886dce1a
Added a sensor to detect if the hotspot is enabled. (#4012)
* Added a sensor to detect if the hotspot is enabled.

* Validate if we aren't running a watch before showing hotspot sensor.

* Fixed code style issues with the linter.

* Fix instant update for hotspot-sensor.

* Update hotspot icon to access-point instead of wifi.
2023-11-22 12:54:06 -05:00
Daniel Shokouhi
a75d1da1d7
Update change log week of 11/11 (#4011) 2023-11-11 22:37:29 -05:00
Daniel Shokouhi
dfc30d5357
Update change log week of 11/3 (#3996) 2023-11-04 15:05:31 -07:00
Joris Pelgröm
ac7ba33ae7
Show server name in "Unable to connect to Home Assistant" dialog (#3995)
- Shows the server name instead of a generic "Home Assistant" to prevent confusion when the app cannot connect in the WebViewActivity, when using multiserver.
2023-11-04 14:59:15 -04:00
Daniel Shokouhi
15574f7531
Update change log week of 10/27 (#3978) 2023-10-28 09:44:52 -07:00
Daniel Shokouhi
51b30fc19f
Update change log week of 10/20 (#3963) 2023-10-20 16:03:49 -07:00
Joris Pelgröm
607833d4c7
Update launcher icon, Play Store feature graphic (#3960)
* Update launcher icon, Play Store feature graphic

 - Update launcher icon to better match other Android app launcher icon sizes
 - Update Play Store feature graphic to new version

* Cannot deduplicate this launcher icon on Wear

* ktlint
2023-10-20 17:47:26 -04:00
Joris Pelgröm
cda25479d6
Add clear_notification support to Wear OS (#3956)
- Move the clear_notification command to common extensions and add support in the Wear OS app
2023-10-20 17:45:48 -04:00
Daniel Shokouhi
6118933e4e
Update change log week of 10/13 (#3939) 2023-10-14 08:33:42 -04:00
Joris Pelgröm
4486a42400
Add Harman template host to car service allowlist (#3937) 2023-10-14 08:33:21 -04:00
dmiales
eba9295644
Bugfix/crash web view (#3787)
* bugfix/crashWebView reload webview after crash

* bugfix/crashWebView reload webview after crash

* bugfix/crashWebView reload webview after crash

* bugfix/crashWebView reload webview after crash

* bugfix/crashWebView reload webview after crash

* bugfix/crashWebView reload webview after crash

* bugfix/crashWebView reload webview after crash

* bugfix/crashWebView reload webview after crash

* bugfix/crashWebView codereview
2023-10-12 20:52:16 -04:00
Joris Pelgröm
dbbf7473ac
Prevent notification attachments failing due to spaces ( ) in url (#3930) 2023-10-12 20:50:32 -04:00
Daniel Shokouhi
fb739596fc
Change log week of 10/6 (#3922) 2023-10-06 12:57:06 -04:00
Márton Maráz
2641422e50
Add NFC state sensor (#3905)
* Add first draft for NFC sensor

* Rename NfcSensorManager.nfcSensor to nfcStateSensor

* Move NfcSensorManager to the common module

* Add BroadcastReceiver subscription to NfcAdapter.ACTION_ADAPTER_STATE_CHANGED in both the app and wear modules

* Remove TODO comments

* Change updateType to INTENT

* Convert simple methods to expression body

* Change mdi:nfc to mdi:nfc-variant

* Fix docs URL

* Reword NFC sensor manager according to the PR suggestions
2023-10-05 09:57:33 -04:00
Daniel Shokouhi
b290d568ef
Update change log week of 9/29 (#3901)
* Update change log week of 9/29

* Move up icon change

* Update all version numbers
2023-09-29 22:51:46 -04:00
Joris Pelgröm
4a4cc31b97
Update icon (#3888)
* Update icon

 - Replace old icon with the new icon
 - Update app primary color to new blue tint
 - Deduplicate resources

* Update feature graphic

* Decouple app icon color from main color
2023-09-28 17:38:48 -04:00
Joris Pelgröm
b0ad11d04f
Add troubleshooting tool: location history (#3886)
* Add location history (location, trigger, result)

 - Initial setup saving data, no UI, cleanup or preferences yet

* On/off setting, limit history size and basic UI

 - Add a on/off setting for location history (default on)
 - Limit the history size to 48 hours, any older entries will be deleted during regular sensor updates
 - Add a basic UI for location history based on paging considering the possible data size with multiserver/high accuracy. The list looks good and shows status at a glance, detail view still needs work.

* Finish expanded UI

 - Make the expanded UI nicer and show relevant data, buttons for opening the location in a maps app and sharing log data
 - Add empty states for location history

* Filter by state, improve list speed

 - Add option to filter by state
 - Simplify Room configuration and sort by indexed ID to improve list loading speed

* Remove duplicate source

* Fix minimal

* Split sent into sent and failed to send
2023-09-28 17:37:37 -04:00
Daniel Shokouhi
847b8f4a42
Update change log week of 9/22 (#3885) 2023-09-23 10:59:13 -04:00