diff options
author | Luke "Jared" Bennett <lbennett@gitlab.com> | 2017-09-14 15:30:00 +0100 |
---|---|---|
committer | Luke "Jared" Bennett <lbennett@gitlab.com> | 2017-09-28 13:29:32 +0100 |
commit | 94749a45b792c18c6dbf4a59e30c145d1aa825d9 (patch) | |
tree | 5bac11f70efc757e940b1ae59f2351ae38e08dcd /app/assets/javascripts | |
parent | 9cd87f6fa9be629018f11420ed7e70d9ac4e5804 (diff) | |
download | gitlab-ce-94749a45b792c18c6dbf4a59e30c145d1aa825d9.tar.gz |
Trigger load of lazy images when opening sidebar, or clicking 'more participants'
Diffstat (limited to 'app/assets/javascripts')
-rw-r--r-- | app/assets/javascripts/issuable_context.js | 5 | ||||
-rw-r--r-- | app/assets/javascripts/right_sidebar.js | 4 |
2 files changed, 7 insertions, 2 deletions
diff --git a/app/assets/javascripts/issuable_context.js b/app/assets/javascripts/issuable_context.js index 70c364e51fe..0a8bab6ee66 100644 --- a/app/assets/javascripts/issuable_context.js +++ b/app/assets/javascripts/issuable_context.js @@ -70,7 +70,10 @@ const PARTICIPANTS_ROW_COUNT = 7; } else { $(this).text(originalText); } - return $(".js-participants-hidden").toggle(); + + $(".js-participants-hidden").toggle(); + + gl.lazyLoader.loadCheck(); }; return IssuableContext; diff --git a/app/assets/javascripts/right_sidebar.js b/app/assets/javascripts/right_sidebar.js index a4eae135403..c06b8b6efe6 100644 --- a/app/assets/javascripts/right_sidebar.js +++ b/app/assets/javascripts/right_sidebar.js @@ -45,8 +45,10 @@ import Cookies from 'js-cookie'; $('.page-with-sidebar').removeClass('right-sidebar-collapsed').addClass('right-sidebar-expanded'); } if (!triggered) { - return Cookies.set("collapsed_gutter", $('.right-sidebar').hasClass('right-sidebar-collapsed')); + Cookies.set("collapsed_gutter", $('.right-sidebar').hasClass('right-sidebar-collapsed')); } + console.log('loadCheck') + gl.lazyLoader.loadCheck(); }); return $(document).off('click', '.js-issuable-todo').on('click', '.js-issuable-todo', this.toggleTodo); }; |