X-Git-Url: http://source.bookstackapp.com/bookstack/blobdiff_plain/a1b1f8138aa9c439dc6cf375d8f843c93ceedbe3..09c6a3c2405742ea6003e9a8a30e7ad212ab6977:/resources/js/components/page-display.js diff --git a/resources/js/components/page-display.js b/resources/js/components/page-display.js index b4f1cca4f..f8377130c 100644 --- a/resources/js/components/page-display.js +++ b/resources/js/components/page-display.js @@ -22,7 +22,7 @@ class PageDisplay { if (sidebarPageNav) { DOM.onChildEvent(sidebarPageNav, 'a', 'click', (event, child) => { event.preventDefault(); - window.components['tri-layout'][0].showContent(); + window.$components.first('tri-layout').showContent(); const contentId = child.getAttribute('href').substr(1); this.goToText(contentId); window.history.pushState(null, null, '#' + contentId);