Jelajahi Sumber

add "minus top-of-table-contents height"

kaoritokashiki 5 tahun lalu
induk
melakukan
87a6f7f6a2
1 mengubah file dengan 2 tambahan dan 2 penghapusan
  1. 2 2
      src/client/js/components/TableOfContents.jsx

+ 2 - 2
src/client/js/components/TableOfContents.jsx

@@ -26,8 +26,8 @@ const TableOfContents = (props) => {
     const containerElem = document.querySelector('#revision-toc');
     const containerTop = containerElem.getBoundingClientRect().top;
 
-    // window height - revisionToc top - .system-version - .grw-fab-container height
-    return window.innerHeight - containerTop - 20 - 155;
+    // window height - revisionToc top - .system-version - .grw-fab-container height - top-of-table-contents height
+    return window.innerHeight - containerTop - 20 - 155 - 26;
   }, []);
 
   const { tocHtml } = pageContainer.state;