mirror of
https://github.com/tauri-apps/plugins-workspace.git
synced 2026-10-10 22:38:44 +02:00
* feat(notification): report actions on desktop A click on a notification (tap) or on one of the actions of its action type now reaches the JavaScript onAction listeners on desktop, and the new Rust Notification::on_action on every platform. On Linux and the BSDs the click comes from the notification server's ActionInvoked signal; on Windows and macOS from notify-rust's wait_for_response, which needs notify-rust 4.18. register_action_types, remove_active (Linux and the BSDs) and the listener commands are implemented for desktop, so they no longer fail with "command not found". The api example sends a notification with two actions and shows the action it hears. Closes #2150, closes #1903. * fix(notification): complete desktop action API * cleanup --------- Co-authored-by: Haex <hexxx@ok.de> Co-authored-by: Lucas Nogueira <lucas@tauri.app>
589 B
589 B
notification, notification-js
| notification | notification-js |
|---|---|
| minor:feat | minor:feat |
Report actions on desktop: a click on a notification (tap) or on one of the actions of its action type reaches onAction and the new Rust Notification::on_action, which also works on mobile. registerActionTypes, removeActive (Linux and the BSDs) and the listener commands no longer fail with "command not found" on desktop.
The onAction callback is now typed with the new ActionPerformed interface, which is what every platform sends, instead of Options. Callbacks annotated with Options must be updated.