mirror of
https://github.com/storytold/vectorcraft.git
synced 2026-10-24 09:46:59 -06:00
The History panel menu had no Clear History, and VectorCraft had no command that removes the undo and redo steps. In the reference app, Clear History in the History panel menu removes the states after the selected state, and it removes the states before it while their changes remain in the document. edit.clearHistory (Clear History) removes every step to undo and to redo in the active document and returns how many it removed. The document and the selection stay as they are, and clearing is not an undo step. Typing or a drag still in progress becomes a step first, as Undo makes it one, so its change stays in the document. The command is disabled when there is no step to clear, and it waits while an input method composes, as Undo does. The History panel menu has Clear History after Step Forward. It runs the command and is disabled when there is no step to clear. Docs: docs/mcp.md, docs/target-app-parity.md.