diff --git a/src/containers/editable-popover.js b/src/containers/editable-popover.js index c2f7fcc..e369b6f 100644 --- a/src/containers/editable-popover.js +++ b/src/containers/editable-popover.js @@ -26,6 +26,7 @@ /** * move popover to new position. This function mainly copied from bootstrap-popover. */ + /*jshint laxcomma: true*/ setPosition: function () { (function() { @@ -37,7 +38,7 @@ , placement , tp; - placement = typeof this.options.placement == 'function' ? + placement = typeof this.options.placement === 'function' ? this.options.placement.call(this, $tip[0], this.$element[0]) : this.options.placement; @@ -58,16 +59,16 @@ switch (inside ? placement.split(' ')[1] : placement) { case 'bottom': tp = {top: pos.top + pos.height, left: pos.left + pos.width / 2 - actualWidth / 2}; - break + break; case 'top': tp = {top: pos.top - actualHeight, left: pos.left + pos.width / 2 - actualWidth / 2}; - break + break; case 'left': tp = {top: pos.top + pos.height / 2 - actualHeight / 2, left: pos.left - actualWidth}; - break + break; case 'right': tp = {top: pos.top + pos.height / 2 - actualHeight / 2, left: pos.left + pos.width}; - break + break; } $tip @@ -76,7 +77,7 @@ .addClass('in'); }).call(this.container()); - + /*jshint laxcomma: false*/ } }); diff --git a/src/element/editable-element.js b/src/element/editable-element.js index 2d6ad36..b6784fd 100644 --- a/src/element/editable-element.js +++ b/src/element/editable-element.js @@ -132,7 +132,7 @@ Makes editable any HTML element on the page. Applied as jQuery method. disable: function() { this.options.disabled = true; this.hide(); - this.$element.addClass('editable-disabled') + this.$element.addClass('editable-disabled'); this.handleEmpty(); //do not stop focus on this element this.$element.attr('tabindex', -1);