mirror of
https://github.com/BookStackApp/BookStack.git
synced 2025-11-03 02:13:16 +03:00
Fixed firefox tri-layout grid issue and added tablet sticky sidebar
- Fixed issue with original left-sidebar content being placed halfway down the page. - Added sticky sidebar to mid-size tablet layout, only for original left sidebar items. Fixes #1434.
This commit is contained in:
@@ -23,8 +23,11 @@ class PageDisplay {
|
||||
const sidebarPageNav = document.querySelector('.sidebar-page-nav');
|
||||
if (sidebarPageNav) {
|
||||
DOM.onChildEvent(sidebarPageNav, 'a', 'click', (event, child) => {
|
||||
event.preventDefault();
|
||||
window.components['tri-layout'][0].showContent();
|
||||
this.goToText(child.getAttribute('href').substr(1));
|
||||
const contentId = child.getAttribute('href').substr(1);
|
||||
this.goToText(contentId);
|
||||
window.history.pushState(null, null, '#' + contentId);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user