element-hq / element-hq/element-web

RFC: Cross-platform in-app toasts with avatars & privacy controls (Windows/Linux/macOS)

Open
#31,054 0 comments 0 reactions 0 assignees View on GitHub
A-Avatar A-Toast T-Enhancement T-Feature X-Needs-Product
Dominant language
TypeScript
Stars
13.5k
Forks
2.8k
PR merge metrics
PR metrics pending

Description

### Your use case

#### What would you like to do?
Have Element Web provide **in-app toast notifications** (small overlay inside the app), with:
- room/DM avatar (or branded fallback),
- granular privacy toggles: "Show sender info" and "Show message preview",
- consistent click-through to focus Element and open the room/thread,
- identical behavior across Windows / Linux (GNOME/KDE) / macOS.

#### Why would you like to do it?
System notifications behave differently per OS/DE (avatar support, grouping, click-through/focus).
Users also want predictable **privacy** (be able to hide sender/preview everywhere) and a modern,
compact UI that matches Element's look & feel.

#### How would you like to achieve it?
- **Element Web (this repo):**
- Add an in-app toast UI component (overlay) + event bus.
- Add device-level settings:
- *Use in-app toasts (instead of system)*,
- *Show sender info (like avatar) in desktop notifications*,
- *Show message preview* (enabled only if sender info is on).
- Privacy policy: when sender/preview are off, show brand title and a generic message ("You have a new message").
- **Element Desktop (Electron):**
- Wire click-through (toast -> focus app -> navigate to room/thread).
- Windows: ensure correct App identity (AUMID) and app icon/name when system toasts are used; in-app toasts are the primary path.
- **Cross-platform goals:**
- Parity for focus behavior and dismissal,
- Stacking/positioning (1–3 concurrent toasts), auto-dismiss, a11y (ARIA live + keyboard).

![Image](https://github.com/user-attachments/assets/8d602ce2-a13b-4be7-a97a-86789b6920c0)
Image
Image
Image
Image

### Have you considered any alternatives?

- Keep system notifications only: inconsistent UX/privacy across OSes; limited avatar support.
- Fully native per-OS implementations: higher maintenance cost; the proposed in-app approach is simpler and consistent for a first step.

### Additional context

**Related**
- element-hq/element-desktop#2575

**Work in progress branches**
- [ogyrec-o/element-web@feat/notifications/in-app-toasts-crossplatform](https://github.com/ogyrec-o/element-web/tree/feat/notifications/in-app-toasts-crossplatform)
- [ogyrec-o/element-desktop@feat/notifications/in-app-toasts-crossplatform](https://github.com/ogyrec-o/element-desktop/tree/feat/notifications/in-app-toasts-crossplatform)

**Acceptance criteria (initial)**
- [ ] In-app toasts render with room/DM avatar or branded fallback
- [ ] Device settings: use in-app toasts, show sender info, show preview (depends on sender)
- [ ] Privacy respected: when off, no sender avatar/name and generic message text
- [ ] Click-through: toast -> focus Element -> open room/thread
- [ ] Basic stacking (1-3), auto-dismiss, a11y (ARIA live, keyboard)
- [ ] Windows base tested; Linux and macOS parity to follow

I'm happy to iterate with maintainers' feedback.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.