-
-
Notifications
You must be signed in to change notification settings - Fork 202
Fix Grid Header Drag Proxy for Row Component Architecture #8975
Copy link
Copy link
Closed
Labels
Description
The current implementation of createDragProxy in src/draggable/grid/header/toolbar/SortZone.mjs is broken due to recent refactoring of the Grid component (specifically, the introduction of Neo.grid.Row).
Current Issues:
- Styling Loss: The drag proxy no longer retains the correct grid styling (e.g., even/odd row colors) because the proxy structure doesn't match the new row-based DOM structure.
- Height Calculation: The proxy height calculation might be incorrect or missing the necessary context.
- Data Retrieval: While cell content retrieval partly works for simple columns, it needs to be robustly adapted to fetch data from the new
Rowcomponents.
Goal:
- Update
createDragProxyto correctly reconstruct the visual representation of the dragged column. - Ensure the proxy includes the full grid height and proper styling (mimicking the grid body).
- Adapt the logic to iterate over
Neo.grid.Rowinstances to extract cell VDOM. - Verify that component-based columns are handled gracefully (or at least don't crash, even if fully cloning them is complex).
Implementation Details:
- Iterate over
grid.body.items(the Row components) instead ofbody.getVdomRoot().cn. - Extract the specific cell VDOM matching the dragged column index from each Row.
- Reconstruct the VDOM for the proxy to include
neo-grid-rowclasses and styles to maintain visual fidelity during the drag operation.
Reactions are currently unavailable