File size: 549 Bytes
97420cf
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
import keyMirror from 'keymirror';

const Formats = keyMirror({
    BITMAP: null,
    VECTOR: null,
    // Format changes which should not trigger conversions, for instance undo
    BITMAP_SKIP_CONVERT: null,
    VECTOR_SKIP_CONVERT: null
});

const isVector = function (format) {
    return format === Formats.VECTOR || format === Formats.VECTOR_SKIP_CONVERT;
};

const isBitmap = function (format) {
    return format === Formats.BITMAP || format === Formats.BITMAP_SKIP_CONVERT;
};

export {
    Formats as default,
    isVector,
    isBitmap
};