27 lines
515 B
JavaScript
27 lines
515 B
JavaScript
const getBlendMode = (function () {
|
|
var blendModeEnums = {
|
|
0: 'source-over',
|
|
1: 'multiply',
|
|
2: 'screen',
|
|
3: 'overlay',
|
|
4: 'darken',
|
|
5: 'lighten',
|
|
6: 'color-dodge',
|
|
7: 'color-burn',
|
|
8: 'hard-light',
|
|
9: 'soft-light',
|
|
10: 'difference',
|
|
11: 'exclusion',
|
|
12: 'hue',
|
|
13: 'saturation',
|
|
14: 'color',
|
|
15: 'luminosity',
|
|
};
|
|
|
|
return function (mode) {
|
|
return blendModeEnums[mode] || '';
|
|
};
|
|
}());
|
|
|
|
export default getBlendMode;
|