fix: imagesLoaded integration for handleBack in world.js

This commit is contained in:
Julian Lam
2026-03-13 12:09:25 -04:00
parent f1d3114541
commit 38a1da4609

View File

@@ -3,10 +3,10 @@
define('forum/world', [
'forum/infinitescroll', 'search', 'sort', 'hooks',
'alerts', 'api', 'bootbox', 'helpers', 'forum/category/tools',
'translator', 'quickreply', 'handleBack',
'translator', 'quickreply', 'handleBack', 'imagesloaded',
], function (infinitescroll, search, sort, hooks,
alerts, api, bootbox, helpers, categoryTools,
translator, quickreply, handleBack) {
translator, quickreply, handleBack, imagesLoaded) {
const World = {};
World.init = function () {
@@ -52,11 +52,13 @@ define('forum/world', [
app.parseAndTranslate(ajaxify.data.template.name, 'posts', payload, function (html) {
const listEl = document.getElementById('world-feed');
$(listEl).append(html);
html.find('.timeago').timeago();
handleImages();
handleShowMoreButtons();
callback();
handleBackCb();
imagesLoaded(listEl, () => {
html.find('.timeago').timeago();
handleImages();
handleShowMoreButtons();
callback();
handleBackCb();
});
});
});
}, { container: '#world-feed' });