Skip to content

A platform for community discussion. Free, open, simple.

DEV: Add additional arg to appEvents triggered on notification click (#25317)

Mark VanLandingham07a0c6c637a0
diff --git a/app/assets/javascripts/discourse/app/lib/user-menu/notification-item.js b/app/assets/javascripts/discourse/app/lib/user-menu/notification-item.js
index 99ca27d3bc9..48eaa03520f 100644
--- a/app/assets/javascripts/discourse/app/lib/user-menu/notification-item.js
+++ b/app/assets/javascripts/discourse/app/lib/user-menu/notification-item.js
@@ -82,7 +82,10 @@ export default class UserMenuNotificationItem extends UserMenuBaseItem {
onClick() {
this.renderDirector.onClick?.();
- this.appEvents.trigger("user-menu:notification-click", this.notification);
+ this.appEvents.trigger("user-menu:notification-click", {
+ notification: this.notification,
+ href: this.linkHref,
+ });
if (!this.notification.read) {
this.notification.set("read", true);