Fix dot-notation rule in es5
[MAILPOET-1143]
This commit is contained in:
@@ -42,7 +42,6 @@
|
|||||||
"no-extra-bind": 0,
|
"no-extra-bind": 0,
|
||||||
"brace-style": 0,
|
"brace-style": 0,
|
||||||
"space-infix-ops": 0,
|
"space-infix-ops": 0,
|
||||||
"dot-notation": 0,
|
|
||||||
"prefer-template": 0,
|
"prefer-template": 0,
|
||||||
"func-names": 0
|
"func-names": 0
|
||||||
}
|
}
|
||||||
|
@@ -146,7 +146,7 @@ define('date',
|
|||||||
|
|
||||||
if (!format || format.length <= 0) return format;
|
if (!format || format.length <= 0) return format;
|
||||||
|
|
||||||
replacements = formatMappings['date'];
|
replacements = formatMappings.date;
|
||||||
convertedFormat = [];
|
convertedFormat = [];
|
||||||
escapeToken = false;
|
escapeToken = false;
|
||||||
|
|
||||||
|
@@ -365,17 +365,17 @@ WysijaForm = {
|
|||||||
};
|
};
|
||||||
// body
|
// body
|
||||||
WysijaForm.getBlocks().each(function (b) {
|
WysijaForm.getBlocks().each(function (b) {
|
||||||
var blockData = (typeof (b.block['save']) === 'function') ? b.block.save() : null;
|
var blockData = (typeof (b.block.save) === 'function') ? b.block.save() : null;
|
||||||
|
|
||||||
if (blockData !== null) {
|
if (blockData !== null) {
|
||||||
// set block position
|
// set block position
|
||||||
blockData['position'] = position;
|
blockData.position = position;
|
||||||
|
|
||||||
// increment position
|
// increment position
|
||||||
position++;
|
position++;
|
||||||
|
|
||||||
// add block data to body
|
// add block data to body
|
||||||
data['body'].push(blockData);
|
data.body.push(blockData);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
@@ -480,7 +480,7 @@ WysijaForm = {
|
|||||||
WysijaForm.getBlocks().each(function (container) {
|
WysijaForm.getBlocks().each(function (container) {
|
||||||
container.setPosition(index++);
|
container.setPosition(index++);
|
||||||
// remove z-index value to avoid issues when resizing images
|
// remove z-index value to avoid issues when resizing images
|
||||||
if (container['block'] !== undefined) {
|
if (container.block !== undefined) {
|
||||||
container.block.element.setStyle({
|
container.block.element.setStyle({
|
||||||
zIndex: ''
|
zIndex: ''
|
||||||
});
|
});
|
||||||
@@ -774,7 +774,7 @@ WysijaForm.Block = window.Class.create({
|
|||||||
this.block.makeBlockDroppable();
|
this.block.makeBlockDroppable();
|
||||||
|
|
||||||
// setup events
|
// setup events
|
||||||
if (this.block['setup'] !== undefined) {
|
if (this.block.setup !== undefined) {
|
||||||
this.block.setup();
|
this.block.setup();
|
||||||
}
|
}
|
||||||
return this;
|
return this;
|
||||||
@@ -783,13 +783,13 @@ WysijaForm.Block = window.Class.create({
|
|||||||
this.element.writeAttribute('wysija_position', position);
|
this.element.writeAttribute('wysija_position', position);
|
||||||
},
|
},
|
||||||
hideControls: function () {
|
hideControls: function () {
|
||||||
if (this['getControls']) {
|
if (this.getControls) {
|
||||||
this.element.removeClassName('hover');
|
this.element.removeClassName('hover');
|
||||||
this.getControls().hide();
|
this.getControls().hide();
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
showControls: function () {
|
showControls: function () {
|
||||||
if (this['getControls']) {
|
if (this.getControls) {
|
||||||
this.element.addClassName('hover');
|
this.element.addClassName('hover');
|
||||||
try {
|
try {
|
||||||
this.getControls().show();
|
this.getControls().show();
|
||||||
|
@@ -254,7 +254,7 @@ define('modal', ['mailpoet', 'jquery'],
|
|||||||
|
|
||||||
// add sub panel wrapper
|
// add sub panel wrapper
|
||||||
jQuery('#mailpoet_' + this.options.type)
|
jQuery('#mailpoet_' + this.options.type)
|
||||||
.append(this.templates['subpanel']);
|
.append(this.templates.subpanel);
|
||||||
|
|
||||||
// add sub panel content
|
// add sub panel content
|
||||||
jQuery('.mailpoet_' + this.options.type + '_body').last()
|
jQuery('.mailpoet_' + this.options.type + '_body').last()
|
||||||
|
@@ -72,7 +72,7 @@ function (
|
|||||||
if (
|
if (
|
||||||
window.frameElement !== null
|
window.frameElement !== null
|
||||||
&& MailPoet !== undefined
|
&& MailPoet !== undefined
|
||||||
&& MailPoet['Iframe']
|
&& MailPoet.Iframe
|
||||||
) {
|
) {
|
||||||
MailPoet.Iframe.autoSize(window.frameElement);
|
MailPoet.Iframe.autoSize(window.frameElement);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user