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:
Neo.grid.Container (Macro Routing):
- Stripped down into a pure macro layout coordinator.
- Distributes columns parameters downwards but drops manual SubGrid instantiation from
createOrUpdateSubGrids().
Neo.grid.header.Wrapper (New Orchestrator):
- A dedicated wrapper (upgraded from a generic
BaseContainer) that is strictly responsible for managing headerStart, headerToolbar, and headerEnd.
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.
The Problem: The "God Object" Pattern
Currently,
Neo.grid.Containercarries the burden of manually instantiatingheaderStart,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 brittlethis.itemssynchronization.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:
Neo.grid.Container(Macro Routing):createOrUpdateSubGrids().Neo.grid.header.Wrapper(New Orchestrator):BaseContainer) that is strictly responsible for managingheaderStart,headerToolbar, andheaderEnd.Neo.grid.View(The State Master):syncBodies) ofbodyStart,body, andbodyEnd.Architectural Guarantee
This isolates all physical row logic perfectly beneath
grid.View, enabling it to safely host theSelectionModelin the future without triggering header layout thrashing.