Skip to content

Node.js based forum software built for the modern web

updated notif page code to work with new mobile-only dropdown for marking notifications read

Julian Lamc7fbaf1a53ec
diff --git a/package.json b/package.json
index b0e089cfa3..03ba509085 100644
--- a/package.json
+++ b/package.json
@@ -45,8 +45,8 @@
"nodebb-plugin-soundpack-default": "~0.1.1",
"nodebb-plugin-spam-be-gone": "^0.4.0",
"nodebb-theme-lavender": "^1.0.28",
- "nodebb-theme-vanilla": "^1.0.108",
- "nodebb-theme-persona": "^0.1.23",
+ "nodebb-theme-vanilla": "^1.0.120",
+ "nodebb-theme-persona": "^0.1.39",
"nodebb-widget-essentials": "^1.0.0",
"nodebb-rewards-essentials": "^0.0.1",
"npm": "^2.1.4",
diff --git a/public/src/client/notifications.js b/public/src/client/notifications.js
index 4e7244f83f..f380707f86 100644
--- a/public/src/client/notifications.js
+++ b/public/src/client/notifications.js
@@ -2,7 +2,7 @@
/* globals define, socket, app */
-define('forum/notifications', function() {
+define('forum/notifications', ['components'], function(components) {
var Notifications = {};
Notifications.init = function() {
@@ -18,15 +18,14 @@ define('forum/notifications', function() {
$('.timeago').timeago();
- $('.notifications .delete').on('click', function() {
+ components.get('notifications/mark_all').on('click', function() {
socket.emit('notifications.markAllRead', function(err) {
if (err) {
return app.alertError(err.message);
}
- $('.notifications .delete').addClass('hidden');
- $('.notifications .alert-info').removeClass('hidden');
- listEl.empty();
+ console.log('here!@');
+ components.get('notifications/item').removeClass('unread');
});
});
};