Skip to content

fix(notification): support arbitrary notification actions and wrap them dynamically#3052

Open
the-daonm wants to merge 4 commits into
noctalia-dev:mainfrom
the-daonm:main
Open

fix(notification): support arbitrary notification actions and wrap them dynamically#3052
the-daonm wants to merge 4 commits into
noctalia-dev:mainfrom
the-daonm:main

Conversation

@the-daonm

@the-daonm the-daonm commented Jun 17, 2026

Copy link
Copy Markdown
Contributor

Summary

This PR fixes the issue where noctalia silently dropped notification actions beyond the first two in both the toast notification and the notification center/history tab. The hardcoded limits of 2 action buttons have been removed. Additionally, action buttons are now dynamically wrapped onto multiple horizontal rows when their cumulative widths exceed the card's available width limit. Within each wrapped row, buttons are configured with flexGrow = 1.0f to stretch and share the horizontal space evenly, matching modern UI standards.

Motivation

This solves the problem where clients (such as notify-send) supplying more than two actions are unable to display them to the user, rendering critical notification controls unreachable.

Type of Change

  • Bug fix
  • New feature
  • Breaking change
  • Refactoring
  • Build / packaging

Related Issue

Closes #2934

Testing

just build, just test, just run work

Manual Coverage

  • Tested on Niri
  • Tested on Hyprland
  • Tested on Sway
  • Tested on another compositor:
  • Tested with different bar positions and density settings
  • Tested at different interface scaling values
  • Tested with multiple monitors

Screenshots / Videos

image image image

Checklist

  • This PR is ready for review, or it is marked as Draft.
  • I read and followed the relevant guidance in CONTRIBUTING.md.
  • I ran just format with clang-format v22+ installed, or this PR has no code changes.
  • I ran the relevant build or test commands, or explained why they were not run.
  • I self-reviewed the changes.
  • I checked for new warnings or errors.
  • I will update end-user documentation after merge, or this PR does not change user-facing configuration or behavior.
  • I added or updated assets/translations/en.json, or this PR adds no new user-facing strings.
  • I did not edit non-English translation files unless this PR is explicitly for translation tooling, an import/export sync, or a maintainer-requested locale change.
  • I used the existing canonical names for config keys, IPC names, paths, and identifiers.

Additional Notes

@the-daonm

the-daonm commented Jun 18, 2026

Copy link
Copy Markdown
Contributor Author

I also fix the bug causing the lint failure

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] Notification action buttons capped at 2 (toast + center) — make configurable or show overflow

1 participant