From d7c58306164f88457d0078d0f22f20697075be39 Mon Sep 17 00:00:00 2001 From: Pierre Date: Sat, 3 Mar 2018 13:52:25 +0100 Subject: [PATCH] Added no unread conversations message --- .../css/components/conversations/unreadDropdown.css | 9 +++++++++ .../js/components/conversations/unreadDropdown.js | 13 +++++++++++++ system/config/dev.config.php | 1 + 3 files changed, 23 insertions(+) create mode 100644 assets/css/components/conversations/unreadDropdown.css diff --git a/assets/css/components/conversations/unreadDropdown.css b/assets/css/components/conversations/unreadDropdown.css new file mode 100644 index 00000000..1bf1e7f7 --- /dev/null +++ b/assets/css/components/conversations/unreadDropdown.css @@ -0,0 +1,9 @@ +/** + * Unread conversations dropdown stylesheet + * + * @author Pierre HUBERT + */ + +.no-unread-conversation-msg { + padding: 20px; +} \ No newline at end of file diff --git a/assets/js/components/conversations/unreadDropdown.js b/assets/js/components/conversations/unreadDropdown.js index bcfe0147..3971fd34 100644 --- a/assets/js/components/conversations/unreadDropdown.js +++ b/assets/js/components/conversations/unreadDropdown.js @@ -234,5 +234,18 @@ ComunicWeb.components.conversations.unreadDropdown = { } } + //Display a specific message if there is not any new conversation + if(conversations.length == 0){ + + //Display a message in the target + createElem2({ + appendTo: target, + type: "p", + class: "no-unread-conversation-msg", + innerHTML: "You do not have any unread messages in the conversations you are following..." + }); + + } + }, } \ No newline at end of file diff --git a/system/config/dev.config.php b/system/config/dev.config.php index 2798017e..7aac1138 100644 --- a/system/config/dev.config.php +++ b/system/config/dev.config.php @@ -127,6 +127,7 @@ class Dev { "css/components/conversations/manager.css", "css/components/conversations/windows.css", "css/components/conversations/list.css", + "css/components/conversations/unreadDropdown.css", //User selector stylesheet "css/components/userSelect/userSelect.css",