mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-17 03:01:08 +01:00
started #1807
This commit is contained in:
@@ -10,6 +10,8 @@
|
|||||||
"chat.recent-chats": "Recent Chats",
|
"chat.recent-chats": "Recent Chats",
|
||||||
"chat.contacts": "Contacts",
|
"chat.contacts": "Contacts",
|
||||||
"chat.message-history": "Message History",
|
"chat.message-history": "Message History",
|
||||||
|
"chat.pop-out": "Pop out chat",
|
||||||
|
"chat.maximize": "Maximize",
|
||||||
|
|
||||||
"composer.user_said_in": "%1 said in %2:\n",
|
"composer.user_said_in": "%1 said in %2:\n",
|
||||||
"composer.user_said": "%1 said:\n",
|
"composer.user_said": "%1 said:\n",
|
||||||
|
|||||||
@@ -38,7 +38,8 @@ define('forum/chats', ['string', 'sounds'], function(S, sounds) {
|
|||||||
|
|
||||||
Chats.addEventListeners = function() {
|
Chats.addEventListeners = function() {
|
||||||
var inputEl = $('.chat-input'),
|
var inputEl = $('.chat-input'),
|
||||||
sendEl = $('.expanded-chat button[data-action="send"]');
|
sendEl = $('.expanded-chat button[data-action="send"]'),
|
||||||
|
popoutEl = $('[data-action="pop-out"]');
|
||||||
|
|
||||||
$('.chats-list').on('click', 'li', function(e) {
|
$('.chats-list').on('click', 'li', function(e) {
|
||||||
ajaxify.go('chats/' + utils.slugify($(this).attr('data-username')));
|
ajaxify.go('chats/' + utils.slugify($(this).attr('data-username')));
|
||||||
@@ -62,6 +63,11 @@ define('forum/chats', ['string', 'sounds'], function(S, sounds) {
|
|||||||
Chats.sendMessage(Chats.getRecipientUid(), inputEl);
|
Chats.sendMessage(Chats.getRecipientUid(), inputEl);
|
||||||
return false;
|
return false;
|
||||||
});
|
});
|
||||||
|
|
||||||
|
popoutEl.on('click', function() {
|
||||||
|
app.openChat($('.expanded-chat').attr('data-username'), Chats.getRecipientUid());
|
||||||
|
ajaxify.go('chats');
|
||||||
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
Chats.addGlobalEventListeners = function() {
|
Chats.addGlobalEventListeners = function() {
|
||||||
|
|||||||
Reference in New Issue
Block a user