From 000dff3870c0adae1e0c5583efeb4bb43cd3898f Mon Sep 17 00:00:00 2001 From: Yuriy Bakhtin Date: Mon, 1 Jul 2024 10:46:33 +0300 Subject: [PATCH] Add a link to notification settings on top dropdown list (#7073) * Add a link to notification settings on top dropdown list * Update styles for notification dropdown list --- CHANGELOG.md | 1 + .../resources/js/humhub.notification.js | 8 +--- .../notification/widgets/views/overview.php | 29 ++++++++---- static/less/media.less | 5 ++- static/less/topbar.less | 44 ++++++++++--------- static/less/variables.less | 2 +- themes/HumHub/css/theme.css | 2 +- 7 files changed, 52 insertions(+), 39 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index f53555af23..42993485f2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,7 @@ HumHub Changelog 1.17.0 (TBA) ------------ - Enh #7070: Add GitHub action for PHP CS Fixer +- Enh #7073: Add a link to notification settings on top dropdown list 1.16.0 (June 19, 2024) diff --git a/protected/humhub/modules/notification/resources/js/humhub.notification.js b/protected/humhub/modules/notification/resources/js/humhub.notification.js index 517987b0e7..a2c4126466 100644 --- a/protected/humhub/modules/notification/resources/js/humhub.notification.js +++ b/protected/humhub/modules/notification/resources/js/humhub.notification.js @@ -174,20 +174,17 @@ humhub.module('notification', function (module, require, $) { return; } - $('#badge-notifications').hide(); - event.trigger('humhub:notification:updateCount', [$count]); if (!$count) { updateTitle(false); $('#badge-notifications').html('0'); - $('#mark-seen-link').hide(); + $('#badge-notifications, #mark-seen-link').hide(); $('#icon-notifications .fa').removeClass("animated swing"); } else { updateTitle($count); $('#badge-notifications').html($count); - $('#mark-seen-link').show(); - $('#badge-notifications').fadeIn('fast'); + $('#badge-notifications, #mark-seen-link').fadeIn('fast'); // Clone icon to retrigger animation var $icon = $('#icon-notifications .fa'); @@ -359,4 +356,3 @@ humhub.module('notification', function (module, require, $) { OverviewWidget: OverviewWidget }); }); - diff --git a/protected/humhub/modules/notification/widgets/views/overview.php b/protected/humhub/modules/notification/widgets/views/overview.php index f012cd5695..feebab2c7f 100755 --- a/protected/humhub/modules/notification/widgets/views/overview.php +++ b/protected/humhub/modules/notification/widgets/views/overview.php @@ -1,5 +1,7 @@