EnxDev opened a new pull request, #42865: URL: https://github.com/apache/superset/pull/42865
### SUMMARY This PR expands Dashboard v2 from an assistant-first canvas into a complete editing workspace. Human edits and assistant-driven changes use the same dashboard provider, so both paths update the same in-memory dashboard tree. The editing UI adds: - A dashboard header with an editable title, author metadata, publication state, and clearly disabled actions that are not supported by the prototype yet. - A resizable and collapsible editor panel with Building blocks, Properties, and Outline tabs. - A searchable, registry-backed block palette. Blocks can be added by clicking or dragged into the root or a nested canvas. - A block inspector for editing content, generated property forms, raw JSON properties, placement, sizing, and deletion. - JSON validation with Apply, Revert, and Copy actions. - Dashboard-level properties built from the existing dashboard properties sections. - A navigable outline that reflects nested dashboard structure, selects blocks, and scrolls them into view. - Consistent block chrome with readable titles, selection states, a single card frame, and direct removal controls. This PR also adds three container layout modes: - `grid`: the existing compact, collision-aware layout and the default for layouts without an explicit mode. - `free`: allows blocks to overlap and provides controls for moving blocks to the front or back. - `flex`: supports row or column flow, wrapping, alignment, justification, proportional sizing, and drag-to-reorder. **NB**: Dashboard v2 also registers browser-owned client tools that are provisional, may be amended, for reading and editing the dashboard tree. These tools let the assistant validate data bindings and add, update, move, resize, or remove blocks through the same APIs used by the editing UI. Dashboard state remains in memory for this prototype. Save, History, Refresh, and other persistence-dependent actions remain disabled, I'll update those. ### BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF <img width="2316" height="1237" alt="Screenshot 2026-08-06 230058" src="https://github.com/user-attachments/assets/a43cd788-40f3-45c4-8fa9-0d6d95dd1883" /> <img width="2319" height="1246" alt="Screenshot 2026-08-06 230158" src="https://github.com/user-attachments/assets/8b70c9f3-802b-400a-aa5f-fb57a1ff1502" /> <img width="2318" height="1241" alt="Screenshot 2026-08-06 230218" src="https://github.com/user-attachments/assets/d9314cb7-9782-46f5-a636-8b49554d2868" /> <img width="2321" height="1241" alt="Screenshot 2026-08-06 230304" src="https://github.com/user-attachments/assets/e1243f01-428a-44b1-9fd0-c2ab6427edbb" /> <img width="2318" height="1241" alt="Screenshot 2026-08-06 230325" src="https://github.com/user-attachments/assets/c4951f06-6cd8-407d-bdbb-50cca5c52aa5" /> <img width="2320" height="1241" alt="Screenshot 2026-08-06 230356" src="https://github.com/user-attachments/assets/b98f6437-b5e3-4560-a633-7af986f1debc" /> ### TESTING INSTRUCTIONS Automated tests: ```bash cd superset-frontend npm test -- \ src/pages/DashboardBuilderV2 \ src/core/dashboard \ src/core/chat ``` Manual verification: 1. Open /dashboard/v2/new/. 2. Edit the dashboard title and verify it is reflected in dashboard properties. 3. Search and collapse sections in the Building blocks palette. 4. Add blocks by clicking palette items and by dragging them onto the root and nested canvases. 5. Select blocks from both the canvas and Outline and verify the Properties tab shows the selected block. 6. Edit Markdown content and block properties using both the generated form and JSON editor. 7. Verify invalid JSON cannot be applied, and test Apply, Revert, and Copy. 8. Resize, collapse, and reopen the editor panel. Verify its resize handle also works with the keyboard. 9. Select the dashboard root and switch between grid, free, and flex layouts. 10. In free mode, overlap blocks and test Bring to front and Send to back. 11. In flex mode, test direction, wrapping, alignment, justification, and drag-to-reorder. 12. Delete blocks from both the canvas header and the Properties panel. 13. If a compatible chat extension is available, ask the assistant to add or update a block and verify the editor updates immediately. ### ADDITIONAL INFORMATION <!--- Check any relevant boxes with "x" --> <!--- HINT: Include "Fixes #nnn" if you are fixing an existing issue --> - [ ] Has associated issue: - [ ] Required feature flags: - [ ] Changes UI - [ ] Includes DB Migration (follow approval process in [SIP-59](https://github.com/apache/superset/issues/13351)) - [ ] Migration is atomic, supports rollback & is backwards-compatible - [ ] Confirm DB migration upgrade and downgrade tested - [ ] Runtime estimates and downtime expectations provided - [ ] Introduces new feature or API - [ ] Removes existing feature or API -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
