({
mode,
checkpoints,
}: {
readonly mode: string;
readonly checkpoints: Checkpoints;
})
| 660 | }; |
| 661 | |
| 662 | const CheckpointInfo = ({ |
| 663 | mode, |
| 664 | checkpoints, |
| 665 | }: { |
| 666 | readonly mode: string; |
| 667 | readonly checkpoints: Checkpoints; |
| 668 | }) => { |
| 669 | const undoInformation = useUndoInformation(checkpoints); |
| 670 | const redoInformation = useRedoInformation(checkpoints); |
| 671 | return (() => { |
| 672 | const button = document.createElement('button'); |
| 673 | const [available, action, checkpointId, label] = |
| 674 | mode == 'undoInformation' ? undoInformation : redoInformation; |
| 675 | button.addEventListener('click', action); |
| 676 | return [JSON.stringify([available, checkpointId ?? null, label]), button]; |
| 677 | }) as unknown as JSXElement; |
| 678 | }; |
| 679 | |
| 680 | const State = ({ |
| 681 | mode, |
nothing calls this directly
no test coverage detected
searching dependent graphs…