feat(notifications): build per-user notification system (email, webhook, in-app)
Co-authored-by: christianlouis <361235+christianlouis@users.noreply.github.com>
This commit is contained in:
@@ -71,6 +71,9 @@ def _send_email_notification(target_config: dict[str, Any], title: str, message:
|
||||
smtp_password, smtp_use_tls, recipient_email
|
||||
title: Email subject
|
||||
message: Email body text
|
||||
|
||||
Returns:
|
||||
True if the email was sent successfully, False otherwise.
|
||||
"""
|
||||
try:
|
||||
smtp_host = target_config.get("smtp_host", "")
|
||||
@@ -113,6 +116,9 @@ def _send_webhook_notification(target_config: dict[str, Any], event_type: str, t
|
||||
event_type: The event type string
|
||||
title: Notification title
|
||||
message: Notification body
|
||||
|
||||
Returns:
|
||||
True if the webhook was delivered successfully, False otherwise.
|
||||
"""
|
||||
try:
|
||||
url = target_config.get("url", "")
|
||||
|
||||
@@ -204,8 +204,7 @@
|
||||
<i class="fas fa-bell" aria-hidden="true"></i>
|
||||
<span id="notificationBadge"
|
||||
class="hidden absolute -top-1 -right-1 h-4 w-4 rounded-full bg-red-500 text-white text-xs flex items-center justify-center font-bold"
|
||||
aria-live="polite"
|
||||
aria-label="unread notifications count"></span>
|
||||
aria-live="polite"></span>
|
||||
</a>
|
||||
|
||||
<!-- Dark mode toggle -->
|
||||
|
||||
Reference in New Issue
Block a user