Problem
Full view (#321) is a transient grafana-grid render mode held on the viewer
session, never persisted. Every two-resource workspace write rebuilds the
route from committed truth (rebuildRouteFromCommitted → app.renderDashboard()),
which constructs a fresh viewer session at the persisted style — so the user is
silently dropped back to Grid Tiles.
Two actions do this today:
Ordinary layout commands (widen, corner-drag resize, reorder) go through the
optimistic command queue instead and preserve Full view correctly; there is
already a test asserting that for reorder
(tests/unit/dashboard.test.ts, "reorder (drag) still dispatches move-tile and
persists while Full view is active").
Repro
- Open a Dashboard in Edit mode, pick Full view (G+F).
- Duplicate or remove any panel.
- The style picker reads Grid Tiles again.
Expected
A transient render mode should survive a rebuild caused by the user's own edit —
it is a view preference, not document state.
Notes
Asserted as-is rather than wished away, in
tests/unit/dashboard.test.ts → "remove still commits and persists while Full
view is active", which documents the current behaviour and will fail loudly when
it is fixed.
Same family as the other known cost of a two-resource write: the rebuild re-runs
every tile's query, so deleting one panel refetches the whole page. Worth
considering together — both would be addressed by making a queriesChanged
rebuild incremental, or by carrying the transient render mode across it.
Problem
Full view (#321) is a transient grafana-grid render mode held on the viewer
session, never persisted. Every two-resource workspace write rebuilds the
route from committed truth (
rebuildRouteFromCommitted→app.renderDashboard()),which constructs a fresh viewer session at the persisted style — so the user is
silently dropped back to Grid Tiles.
Two actions do this today:
write rather than a layout command.
Ordinary layout commands (widen, corner-drag resize, reorder) go through the
optimistic command queue instead and preserve Full view correctly; there is
already a test asserting that for reorder
(
tests/unit/dashboard.test.ts, "reorder (drag) still dispatches move-tile andpersists while Full view is active").
Repro
Expected
A transient render mode should survive a rebuild caused by the user's own edit —
it is a view preference, not document state.
Notes
Asserted as-is rather than wished away, in
tests/unit/dashboard.test.ts→ "remove still commits and persists while Fullview is active", which documents the current behaviour and will fail loudly when
it is fixed.
Same family as the other known cost of a two-resource write: the rebuild re-runs
every tile's query, so deleting one panel refetches the whole page. Worth
considering together — both would be addressed by making a
queriesChangedrebuild incremental, or by carrying the transient render mode across it.