Feature Request: TOC Jump on selecting inner scrollable elements.
### Problem
When using the Zotero Connector to save a ChatGPT page, the generated Table of Contents (TOC) becomes non-functional for navigation. Selecting TOC entries does not scroll or jump to the corresponding headers. This appears to be due to the TOC trying to scroll the main window rather than the actual scrollable container holding the content (e.g., inner `
` with `overflow: auto`).
This is frustrating when reviewing or citing content from saved sessions, as navigation becomes tedious without functional header jumps.
---
### Solution
Allow TOC interactions (e.g., clicking TOC links) to trigger scrolling within the correct scrollable container, not just `window.scrollTo`. The TOC should detect or allow configuring the target container if the document body is not the main scrollable area.
Or enable anchor‐link or scroll-to-element functionality for TOC entries within inner scrollable containers.
* Detect header IDs in the saved HTML.
* Wire each TOC entry to `element.scrollIntoView()` (or equivalent) so that clicking jumps to the right section.
---
### Alternatives
* Manually scroll through content, which is inefficient.
* Use browser DevTools to locate the desired element.
* Inject custom JavaScript into the saved page to manually patch the scroll behavior.
* Automatically expand the saved page in a single scrollable document (i.e. flatten inner scrollables).
* Provide “open in browser” links for each TOC entry instead of in-page jumps.
---
### Additional
* This affects any saved page with nested scrollable regions (e.g. ChatGPT’s code blocks or sidebar TOC).
* Screenshot: TOC panel on the right, clicking “### Sample Header” does nothing.
https://s3.amazonaws.com/zotero.org/images/forums/u13445381/5jdmk904a690rkavl9uf.png
This is frustrating when reviewing or citing content from saved sessions, as navigation becomes tedious without functional header jumps.
---
### Solution
Allow TOC interactions (e.g., clicking TOC links) to trigger scrolling within the correct scrollable container, not just `window.scrollTo`. The TOC should detect or allow configuring the target container if the document body is not the main scrollable area.
Or enable anchor‐link or scroll-to-element functionality for TOC entries within inner scrollable containers.
* Detect header IDs in the saved HTML.
* Wire each TOC entry to `element.scrollIntoView()` (or equivalent) so that clicking jumps to the right section.
---
### Alternatives
* Manually scroll through content, which is inefficient.
* Use browser DevTools to locate the desired element.
* Inject custom JavaScript into the saved page to manually patch the scroll behavior.
* Automatically expand the saved page in a single scrollable document (i.e. flatten inner scrollables).
* Provide “open in browser” links for each TOC entry instead of in-page jumps.
---
### Additional
* This affects any saved page with nested scrollable regions (e.g. ChatGPT’s code blocks or sidebar TOC).
* Screenshot: TOC panel on the right, clicking “### Sample Header” does nothing.
https://s3.amazonaws.com/zotero.org/images/forums/u13445381/5jdmk904a690rkavl9uf.png
-
AbeJellinekThanks, we'll look into this.
-
AbeJellinek@morisono: This is actually already fixed in the beta, and the fix will be included in an upcoming release.