In the case of undo, this is implemented using drawInteraction.removeLastPoint().
https://openlayers.org/en/latest/examples/draw-features.html
But I don't know how to implement redo.
The redo function should be available when drawing interaction is active.
Should I use "setGeometry"?