Completed
Push — master ( 1315ad...572de6 )
by Andreas
13s queued 11s
created

UndoMenuItemDispatcher.isAvailable   A

Complexity

Conditions 1

Size

Total Lines 3
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 2
dl 0
loc 3
rs 10
c 0
b 0
f 0
1
import { undo } from 'prosemirror-history';
2
import AbstractMenuItemDispatcher from './AbstractMenuItemDispatcher';
3
import { svgIcon } from '../MDI';
4
import MenuItem from '../MenuItem';
5
6
export default class UndoMenuItemDispatcher extends AbstractMenuItemDispatcher {
7
    // history should be available regardless of current schema
8
    static isAvailable() {
9
        return true;
10
    }
11
12
    static getMenuItem() {
13
        return new MenuItem({
14
            command: undo,
15
            icon: svgIcon('undo'),
16
            label: LANG.plugins.prosemirror['label:undo'],
0 ignored issues
show
Bug introduced by
The variable LANG seems to be never declared. If this is a global, consider adding a /** global: LANG */ comment.

This checks looks for references to variables that have not been declared. This is most likey a typographical error or a variable has been renamed.

To learn more about declaring variables in Javascript, see the MDN.

Loading history...
17
        });
18
    }
19
}
20