Minor change

This commit is contained in:
Kamran Ahmed
2018-03-10 01:53:07 +01:00
parent a63a502b63
commit 438fea8645
2 changed files with 9 additions and 3 deletions
+1 -1
View File
@@ -3,7 +3,7 @@ export const OVERLAY_PADDING = 10;
export const OVERLAY_ANIMATE = true;
export const OVERLAY_ZINDEX = '999999999';
export const ESC_KEYCODE = 27;
export const ESC_KEY_CODE = 27;
export const ID_POPOVER = 'sholo-popover-item';
export const ID_OVERLAY = 'sholo-canvas-overlay';
+8 -2
View File
@@ -2,7 +2,13 @@ import Overlay from './overlay';
import Element from './element';
import './polyfill';
import Popover from './popover';
import { CLASS_CLOSE_BTN, CLASS_NEXT_STEP_BTN, CLASS_PREV_STEP_BTN, ESC_KEYCODE, ID_POPOVER } from './constants';
import {
CLASS_CLOSE_BTN,
CLASS_NEXT_STEP_BTN,
CLASS_PREV_STEP_BTN,
ESC_KEY_CODE,
ID_POPOVER,
} from './constants';
/**
* Plugin class that drives the plugin
@@ -153,7 +159,7 @@ export default class Sholo {
* @param event
*/
onKeyUp(event) {
if (event.keyCode === ESC_KEYCODE) {
if (event.keyCode === ESC_KEY_CODE) {
this.overlay.clear();
}
}