LearnNewsExamplesConnect
Frontmatter
assigneesneo-gemini-maryam
createdAtApr 10, 2026, 8:19 PM
updatedAtNov 7, 2026, 12:36 AM
githubUrlhttps://github.com/neomjs/neo/issues/9872
authortobiu
commentsCount6
parentIssue9486
subIssues
12757 grid.View owns body-scroll orchestration (syncBodies relocation from Container)
12800 Grid Multi-Body: dedicated grid.header.Wrapper orchestrator
subIssuesCompleted2
subIssuesTotal2
contentTrust
projected
quarantined0
signals[]
blockedBy[]
blocking[]
closedAtNov 7, 2026, 12:36 AM

Grid Multi-Body: 3-Tier Component Orchestration and Architecture Refactoring

Closed v13.4.0/archive-v13-4-0-chunk-2 enhancementaigrid
tobiu
tobiu commented on Apr 10, 2026, 8:19 PM

The Problem: The "God Object" Pattern

Currently, Neo.grid.Container carries the burden of manually instantiating headerStart, bodyStart, and related split components. It forcibly injects them into the view hierarchy and manages low-level column iteration parameters. This violates the Single Responsibility Principle, creates immense VDOM diff penalties across unrelated domains (especially for Selection Models), and creates brittle this.items synchronization.

The Solution: The 3-Tier Orchestration Architecture

To support the Multi-Body split cleanly and prepare the foundation for centralized Selection Models (unblocking #9492), the instantiation logic must be pushed downwards:

  1. Neo.grid.Container (Macro Routing):

    • Stripped down into a pure macro layout coordinator.
    • Distributes columns parameters downwards but drops manual SubGrid instantiation from createOrUpdateSubGrids().
  2. Neo.grid.header.Wrapper (New Orchestrator):

    • A dedicated wrapper (upgraded from a generic BaseContainer) that is strictly responsible for managing headerStart, headerToolbar, and headerEnd.
  3. Neo.grid.View (The State Master):

    • Transitioned into the master body orchestrator.
    • Strictly responsible for the creation, lifecycle, and row-synchronization (syncBodies) of bodyStart, body, and bodyEnd.

Architectural Guarantee

This isolates all physical row logic perfectly beneath grid.View, enabling it to safely host the SelectionModel in the future without triggering header layout thrashing.

tobiu added the enhancement label on Apr 10, 2026, 8:19 PM
tobiu added the ai label on Apr 10, 2026, 8:19 PM
tobiu added the grid label on Apr 10, 2026, 8:19 PM
tobiu added parent issue #9486 on Apr 10, 2026, 8:19 PM
tobiu cross-referenced by #9868 on Apr 10, 2026, 8:19 PM
tobiu referenced in commit f69b56a - "refactor(grid): grid.View-owned single SelectionModel, eliminate per-body model construction (#12784) on Jun 9, 2026, 3:26 AM
tobiu referenced in commit d04bc04 - "refactor(grid): extract dedicated header.Wrapper orchestrator (#12800) (#12801) on Jun 9, 2026, 10:31 AM
tobiu removed the not-code-ready label on Jul 6, 2026, 3:21 PM
tobiu removed the needs-design label on Jul 6, 2026, 3:22 PM
tobiu referenced in commit d1056ea - "feat(grid): move locked body lifecycle orchestration into grid.View (#9872) (#20499) on Nov 7, 2026, 12:36 AM
tobiu closed this issue on Nov 7, 2026, 12:36 AM