Whether a newer snapshot is available
Whether an older snapshot is available
The active snapshot, undefined while the history is empty
Every recorded step, oldest first
Position of the active step in entries, -1 while empty
Drop all snapshots
Move to an arbitrary step and return its snapshot, or undefined where there is no such step or it is the active one already.
position in entries
Append a snapshot after the active one, discarding any redoable entries.
the state to record
Optionallabel: string
what the user did, for a history list
Move forward one snapshot and return it, or undefined at the newest entry
Move back one snapshot and return it, or undefined at the oldest entry
SPDX-FileCopyrightText: 2026 Nextcloud GmbH and Nextcloud contributors SPDX-License-Identifier: AGPL-3.0-or-later