Fix SetHistory in SmartComponent

This commit is contained in:
Guillaume Tauzin 2022-10-17 17:36:00 +02:00
parent c693fc9a20
commit d40cd8cf8e

View file

@ -54,7 +54,6 @@ function SetHistory(root: Element | Document,
eventInitDict?: CustomEventInit): void { eventInitDict?: CustomEventInit): void {
const history: IHistoryState[] = eventInitDict?.detail.history; const history: IHistoryState[] = eventInitDict?.detail.history;
const historyCurrentStep: number | undefined = eventInitDict?.detail.historyCurrentStep; const historyCurrentStep: number | undefined = eventInitDict?.detail.historyCurrentStep;
ReviveHistoryAction(history);
setNewHistory(history, historyCurrentStep); setNewHistory(history, historyCurrentStep);
const customEvent = new CustomEvent<IEditorState>('setHistory', { detail: editorState }); const customEvent = new CustomEvent<IEditorState>('setHistory', { detail: editorState });
root.dispatchEvent(customEvent); root.dispatchEvent(customEvent);