WarUI

Reset to default and dirty detection

GRID-A21-F13P1beyond-baselinePlanned

Provides resetState() to return to the initial or default configuration, plus isStateDirty() and a dirty flag in change events that compare the current state with a baseline. The baseline can be the initial state or the most recently loaded saved view.

Planned. This page shows the specification from issue #201. The live example, source for every framework and the API reference replace it when the feature ships.

Live example

A grid with a toolbar containing a dirty indicator and a Reset button.

Expected behavior

Any modification lights the dirty indicator. Undoing that modification manually clears it again because comparison is canonical. Reset restores the baseline and clears the indicator.

Planned API surface

resetState({include})isStateDirty()setBaselineState(state)StateChangeEvent.isDirty

Acceptance criteria

  • isStateDirty uses canonical equality and ignores scroll by default. (pending)
  • resetState supports slice selection. (pending)
  • setBaselineState updates the reference point without changing the grid. (pending)
  • A dirty-to-clean transition emits a stateChange event with isDirty set to false. (pending)