Last active
November 27, 2017 18:37
-
-
Save domagude/0dee5290bc70cc6f084cd7825fa5a03c to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// on the add-user-to-contacts link click | |
// remove the link and notify, that the request has been sent | |
$(document).on('click', | |
'.add-user-to-contacts, .add-user-to-contacts-notif', | |
function(e) { | |
var conversation_window = $(this).parents('.conversation-window,\ | |
.conversation'); | |
conversation_window | |
.find('.add-user-to-contacts') | |
.replaceWith('<div class="contact-request-sent"\ | |
style="display: block;">\ | |
<div>\ | |
<i class="fa fa-question"\ | |
aria-hidden="true"\ | |
title="Contact request sent">\ | |
</i>\ | |
</div>\ | |
</div>'); | |
conversation_window.find('.add-user-to-contacts-message').remove(); | |
conversation_window | |
.find('.messages_list ul') | |
.append('<div class="add-user-to-contacts-message">\ | |
Contact request sent\ | |
</div>'); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment