Closed Jef012 closed 3 weeks ago
Hi @Jef012
Unfortunately, due to Android restrictions on foreground services (required for triggering alarms), each alarm must be associated with a notification.
Thanks for the clarification. Keeping the notification makes sense given the Android restrictions. However, would it be possible to reduce its priority so that it doesn’t draw too much attention? Also, could we ensure it doesn't navigate to or open the app when triggered?
What priority/importance would you like to give to your notification and why ?
You can try it yourself by modifying the code of the plugin (fork it or directly change it in your pub cache). It is set here: https://github.com/gdelataillade/alarm/blob/2cae6cfbe58c8b2fb3ef05fdc3e89444fbc4e04c/android/src/main/kotlin/com/gdelataillade/alarm/services/NotificationService.kt#L68
Add show notification parameter Add a 'show notification' parameter, which allows the user to show or hide the notification using a boolean value.