fix lint errors

This commit is contained in:
vitalets 2013-06-23 17:16:15 +04:00
parent 46d77f50bb
commit 89cccbb860
7 changed files with 216 additions and 211 deletions

@ -222,16 +222,21 @@
//see http://stackoverflow.com/questions/7264899/detect-css-transitions-using-javascript-and-without-modernizr
supportsTransitions: function () {
var b = document.body || document.documentElement;
var s = b.style;
var p = 'transition';
if(typeof s[p] == 'string') {return true; }
var b = document.body || document.documentElement,
s = b.style,
p = 'transition',
v = ['Moz', 'Webkit', 'Khtml', 'O', 'ms'];
if(typeof s[p] === 'string') {
return true;
}
// Tests for vendor specific prop
v = ['Moz', 'Webkit', 'Khtml', 'O', 'ms'],
p = p.charAt(0).toUpperCase() + p.substr(1);
for(var i=0; i<v.length; i++) {
if(typeof s[v[i] + p] == 'string') { return true; }
if(typeof s[v[i] + p] === 'string') {
return true;
}
}
return false;
}

@ -89,7 +89,7 @@ Makes editable any HTML element on the page. Applied as jQuery method.
//if display is function it's far more convinient to have autotext = always to render correctly on init
//see https://github.com/vitalets/x-editable-yii/issues/34
if(typeof this.options.display === 'function') {
this.options.autotext = 'always'
this.options.autotext = 'always';
}
//check conditions for autotext: