From e4c5743852126dbda832517b331a22a2a1d32588 Mon Sep 17 00:00:00 2001 From: Pablo Vazquez Date: Sat, 30 Sep 2017 23:18:09 +0200 Subject: [PATCH] Comments: trigger comments-loaded event on comments load. Useful when apps want to know or do something with the comments, like Dillo to parse emojis for example. --- src/scripts/tutti/2_comments.js | 1 + 1 file changed, 1 insertion(+) diff --git a/src/scripts/tutti/2_comments.js b/src/scripts/tutti/2_comments.js index 5791e482..32af0761 100644 --- a/src/scripts/tutti/2_comments.js +++ b/src/scripts/tutti/2_comments.js @@ -147,6 +147,7 @@ function loadComments(commentsUrl) .done(function(dataHtml) { // Update the DOM injecting the generate HTML into the page commentsContainer.html(dataHtml); + $('body').trigger('pillar:comments-loaded'); }) .fail(function(xhr) { toastr.error('Could not load comments', xhr.responseText);