Native notifications: default vs important #86

Open
opened 2026-05-15 07:15:43 +00:00 by guettli · 2 comments
guettli commented 2026-05-15 07:15:43 +00:00 (Migrated from codeberg.org)

I want some mails to pop up immediately.

By default mails should not popup.

Create a plan how this could be configured by the user.

Focus on user convenience. Implementation is not important now.


Labels:

  • State/InProgress — Set this when you start working on an issue
  • State/Question — Set this when you hit a blocker or need clarification
I want some mails to pop up immediately. By default mails should not popup. Create a plan how this could be configured by the user. Focus on user convenience. Implementation is not important now. --- Labels: - **State/InProgress** — Set this when you start working on an issue - **State/Question** — Set this when you hit a blocker or need clarification
guettlibot commented 2026-05-15 08:52:13 +00:00 (Migrated from codeberg.org)

Plan comment test

Plan comment test
guettlibot commented 2026-05-15 08:52:27 +00:00 (Migrated from codeberg.org)

Plan: Configurable notification level per account

User-facing design

Each account gets a Notifications setting in the Edit Account screen with three choices:

Level Behaviour
Off No notification (for noise/monitored mailboxes)
Silent (default) Notification in shade, no pop-up, no sound
Important Heads-up pop-up with sound

The setting is per-account, so one account can be silent while another pops up immediately.

Data model

Add an AccountNotificationLevel enum (off, silent, important) to the Account class. Default = silent.

No DB migration needed: the field lives in the existing secure-storage JSON blob; a missing key defaults to silent.

Android notification channels

Two channels created once at app startup:

  • new_mail_silentImportance.defaultImportance, no forced sound
  • new_mail_importantImportance.high, Priority.high, default sound

showNewMailNotification receives the account-level setting, picks the right channel, or returns early for off.

UI

EditAccountScreen gets a Notifications section (a SegmentedButton with Off / Silent / Important). No extra screen or navigation needed.

Future scope (out of this issue)

  • iOS/macOS: same enum, different DarwinNotificationDetails wiring
  • Per-mailbox granularity (INBOX important, Promotions silent)
  • Auto-upgrade based on email Importance:/X-Priority: headers
## Plan: Configurable notification level per account ### User-facing design Each account gets a **Notifications** setting in the Edit Account screen with three choices: | Level | Behaviour | |---|---| | **Off** | No notification (for noise/monitored mailboxes) | | **Silent** *(default)* | Notification in shade, no pop-up, no sound | | **Important** | Heads-up pop-up with sound | The setting is per-account, so one account can be silent while another pops up immediately. ### Data model Add an `AccountNotificationLevel` enum (`off`, `silent`, `important`) to the `Account` class. Default = `silent`. No DB migration needed: the field lives in the existing secure-storage JSON blob; a missing key defaults to `silent`. ### Android notification channels Two channels created once at app startup: - `new_mail_silent` — `Importance.defaultImportance`, no forced sound - `new_mail_important` — `Importance.high`, `Priority.high`, default sound `showNewMailNotification` receives the account-level setting, picks the right channel, or returns early for `off`. ### UI `EditAccountScreen` gets a **Notifications** section (a `SegmentedButton` with Off / Silent / Important). No extra screen or navigation needed. ### Future scope (out of this issue) - iOS/macOS: same enum, different `DarwinNotificationDetails` wiring - Per-mailbox granularity (INBOX important, Promotions silent) - Auto-upgrade based on email `Importance:`/`X-Priority:` headers
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: guettli/sharedinbox#86