2020-07-21 13:20:51 +00:00
|
|
|
import {ActionSummary} from 'app/common/ActionSummary';
|
|
|
|
|
2021-09-29 13:57:55 +00:00
|
|
|
/**
|
|
|
|
* This is the action representation the client works with, for the purposes of undos/redos.
|
|
|
|
*/
|
|
|
|
export interface MinimalActionGroup {
|
2020-07-21 13:20:51 +00:00
|
|
|
actionNum: number;
|
|
|
|
actionHash: string;
|
|
|
|
fromSelf: boolean;
|
|
|
|
linkId: number;
|
|
|
|
otherId: number;
|
|
|
|
rowIdHint: number; // If non-zero, this is a rowId that would be a good place to put
|
|
|
|
// the cursor after an undo.
|
|
|
|
isUndo: boolean; // True if the first user action is ApplyUndoActions.
|
2021-09-29 13:57:55 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* This is the action representation the client works with, for the purposes of document
|
|
|
|
* history and undos/redos.
|
|
|
|
*/
|
|
|
|
export interface ActionGroup extends MinimalActionGroup {
|
|
|
|
desc?: string;
|
|
|
|
actionSummary: ActionSummary;
|
|
|
|
time: number;
|
|
|
|
user: string;
|
|
|
|
primaryAction: string; // The name of the first user action in the ActionGroup.
|
2020-07-21 13:20:51 +00:00
|
|
|
internal: boolean; // True if it is inappropriate to log/undo the action.
|
|
|
|
}
|