LearnNewsExamplesServices
Frontmatter
id8591
titleCentralize TreeList expand and scroll logic to fix deep linking
stateClosed
labels
enhancementai
assigneestobiu
createdAtJan 13, 2026, 12:01 PM
updatedAtJan 13, 2026, 12:22 PM
githubUrlhttps://github.com/neomjs/neo/issues/8591
authortobiu
commentsCount1
parentIssuenull
subIssues[]
subIssuesCompleted0
subIssuesTotal0
blockedBy[]
blocking[]
closedAtJan 13, 2026, 12:21 PM

Centralize TreeList expand and scroll logic to fix deep linking

Closed v11.21.0 enhancementai
tobiu
tobiu commented on Jan 13, 2026, 12:01 PM

Problem: A recent optimization in Neo.tree.List (removing DOM for collapsed folders) broke the "deep linking" scroll behavior in the Portal app. Controllers currently implement inconsistent and brittle workarounds (manual timeouts or polling waitForDomRect) to handle expanding parents and scrolling to the newly mounted item.

Solution:

  1. Implement a robust expandAndScrollToItem(itemId) method in Neo.tree.List that handles the expansion, waits for the DOM node to be mounted (using waitForDomRect), and then scrolls it into view.
  2. Refactor MainContainerController for Blog, Release, and Tickets in the Portal app to use this new method, ensuring consistency and reliability.

Files to Modify:

  • src/tree/List.mjs
  • apps/portal/view/news/blog/MainContainerController.mjs
  • apps/portal/view/news/release/MainContainerController.mjs
  • apps/portal/view/news/tickets/MainContainerController.mjs
tobiu added the enhancement label on Jan 13, 2026, 12:01 PM
tobiu added the ai label on Jan 13, 2026, 12:01 PM
tobiu referenced in commit 745fd9c - "feat: Centralize TreeList expand and scroll logic to fix deep linking (#8591)" on Jan 13, 2026, 12:21 PM
tobiu assigned to @tobiu on Jan 13, 2026, 12:21 PM
tobiu closed this issue on Jan 13, 2026, 12:21 PM
tobiu
tobiu Jan 13, 2026, 12:22 PM

Input from Gemini 3 Pro:

✦ Implemented Neo.tree.List.expandAndScrollToItem(itemId) to centralize the logic for deep linking. Refactored Portal.view.news.blog.MainContainerController, Portal.view.news.release.MainContainerController, and Portal.view.news.tickets.MainContainerController to use this new method.

Changes pushed to dev.

Follow-up issues identified regarding horizontal scrolling and header styling will be tracked in a separate ticket.