rewind_disable() stops undo and redo for a session
completely. It destroys each observer that rewind_enable()
made. It also clears the buttons and the rail in the browser. Use
rewind_pause() and rewind_resume() to stop
capture for a short time. Use rewind_disable() to stop it
for the rest of the session.rewind no longer captures fileInput(). Its
value points to a temporary file on the server. Shiny deletes that file
at the next upload. An old snapshot would thus point to a file that does
not exist.rewind_pause() before the first
reactive flush stopped capture for the rest of the session. A later
rewind_resume() did not start it again. This occurred, for
example, with a call to rewind_pause() immediately after
rewind_enable(), before any input changed.rewind_buttons(undo_label = NULL, redo_label = NULL)
now sets aria-label on the buttons. A button with an icon
and no text thus has a correct accessible name.rewind_enable() inside a moduleServer()
now has tests. The documents said “untested” before.First release.
rewind_enable() captures the session inputs into an
undo and redo history. It groups the changes by time. One movement of a
slider is thus one step, and not forty steps.rewind_track() adds the reactiveValues on
the server to the history.rewind_step() puts several changes into one entry with
a label.rewind_buttons() and rewind_ui() give
ready-made undo and redo controls, and a scrubbable history rail.Ctrl/Cmd +
Z, Ctrl/Cmd + Shift
+ Z, and Ctrl + Y. They do
nothing while the user types in a text field.update*Input() table. Inputs from other packages thus
operate with no extra code.