ES5 object-curly-spacing
This commit is contained in:
@ -48,7 +48,6 @@
|
|||||||
"one-var": 0,
|
"one-var": 0,
|
||||||
"camelcase": 0,
|
"camelcase": 0,
|
||||||
"padded-blocks": 0,
|
"padded-blocks": 0,
|
||||||
"object-curly-spacing": 0,
|
|
||||||
"strict": 0,
|
"strict": 0,
|
||||||
"vars-on-top": 0,
|
"vars-on-top": 0,
|
||||||
"no-var": 0,
|
"no-var": 0,
|
||||||
|
@ -109,7 +109,7 @@ define('mp2migrator', ['mailpoet', 'jquery'], function (mp, jQuery) {
|
|||||||
response.errors.map(function (error) {
|
response.errors.map(function (error) {
|
||||||
return error.message;
|
return error.message;
|
||||||
}),
|
}),
|
||||||
{scroll: true}
|
{ scroll: true }
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
@ -140,7 +140,7 @@ define('mp2migrator', ['mailpoet', 'jquery'], function (mp, jQuery) {
|
|||||||
response.errors.map(function (error) {
|
response.errors.map(function (error) {
|
||||||
return error.message;
|
return error.message;
|
||||||
}),
|
}),
|
||||||
{scroll: true}
|
{ scroll: true }
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
@ -163,7 +163,7 @@ define('mp2migrator', ['mailpoet', 'jquery'], function (mp, jQuery) {
|
|||||||
response.errors.map(function (error) {
|
response.errors.map(function (error) {
|
||||||
return error.message;
|
return error.message;
|
||||||
}),
|
}),
|
||||||
{scroll: true}
|
{ scroll: true }
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
@ -181,7 +181,7 @@ define('mp2migrator', ['mailpoet', 'jquery'], function (mp, jQuery) {
|
|||||||
* Actions to run when the DOM is ready
|
* Actions to run when the DOM is ready
|
||||||
*/
|
*/
|
||||||
jQuery(function () {
|
jQuery(function () {
|
||||||
jQuery('#progressbar').progressbar({value: 0});
|
jQuery('#progressbar').progressbar({ value: 0 });
|
||||||
|
|
||||||
// Import button
|
// Import button
|
||||||
jQuery('#import').click(function () {
|
jQuery('#import').click(function () {
|
||||||
|
@ -201,9 +201,9 @@ define([
|
|||||||
orientation: 'vertical'
|
orientation: 'vertical'
|
||||||
});
|
});
|
||||||
tempCollection.get('blocks').add(droppableModel);
|
tempCollection.get('blocks').add(droppableModel);
|
||||||
viewCollection.add(tempCollection, {at: index});
|
viewCollection.add(tempCollection, { at: index });
|
||||||
} else {
|
} else {
|
||||||
viewCollection.add(droppableModel, {at: index});
|
viewCollection.add(droppableModel, { at: index });
|
||||||
}
|
}
|
||||||
|
|
||||||
droppedView = that.getChildren().findByModel(droppableModel);
|
droppedView = that.getChildren().findByModel(droppableModel);
|
||||||
@ -247,7 +247,7 @@ define([
|
|||||||
tempCollection.get('blocks').add(droppableModel);
|
tempCollection.get('blocks').add(droppableModel);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
viewCollection.add(tempCollection, {at: dropPosition.index});
|
viewCollection.add(tempCollection, { at: dropPosition.index });
|
||||||
|
|
||||||
// Call post add actions
|
// Call post add actions
|
||||||
droppedView = that.getChildren().findByModel(tempCollection).children.findByModel(droppableModel);
|
droppedView = that.getChildren().findByModel(tempCollection).children.findByModel(droppableModel);
|
||||||
|
@ -116,7 +116,7 @@ define([
|
|||||||
this.on('refreshPosts', this.updatePosts, this);
|
this.on('refreshPosts', this.updatePosts, this);
|
||||||
},
|
},
|
||||||
updatePosts: function (posts) {
|
updatePosts: function (posts) {
|
||||||
this.get('_container.blocks').reset(posts, {parse: true});
|
this.get('_container.blocks').reset(posts, { parse: true });
|
||||||
},
|
},
|
||||||
/**
|
/**
|
||||||
* Batch more changes during a specific time, instead of fetching
|
* Batch more changes during a specific time, instead of fetching
|
||||||
@ -131,7 +131,7 @@ define([
|
|||||||
className: 'mailpoet_block mailpoet_automated_latest_content_block mailpoet_droppable_block',
|
className: 'mailpoet_block mailpoet_automated_latest_content_block mailpoet_droppable_block',
|
||||||
initialize: function () {
|
initialize: function () {
|
||||||
function replaceButtonStylesHandler(data) {
|
function replaceButtonStylesHandler(data) {
|
||||||
this.model.set({readMoreButton: data});
|
this.model.set({ readMoreButton: data });
|
||||||
}
|
}
|
||||||
App.getChannel().on('replaceAllButtonStyles', replaceButtonStylesHandler.bind(this));
|
App.getChannel().on('replaceAllButtonStyles', replaceButtonStylesHandler.bind(this));
|
||||||
},
|
},
|
||||||
|
@ -144,7 +144,7 @@ define([
|
|||||||
}.bind(this));
|
}.bind(this));
|
||||||
},
|
},
|
||||||
duplicateBlock: function () {
|
duplicateBlock: function () {
|
||||||
this.model.collection.add(this.model.toJSON(), {at: this.model.collection.findIndex(this.model)});
|
this.model.collection.add(this.model.toJSON(), { at: this.model.collection.findIndex(this.model) });
|
||||||
},
|
},
|
||||||
transitionIn: function () {
|
transitionIn: function () {
|
||||||
return this._transition('slideDown', 'fadeIn', 'easeOut');
|
return this._transition('slideDown', 'fadeIn', 'easeOut');
|
||||||
|
@ -28,7 +28,7 @@ define([
|
|||||||
return _.map(response, function (block) {
|
return _.map(response, function (block) {
|
||||||
var Type = App.getBlockTypeModel(block.type);
|
var Type = App.getBlockTypeModel(block.type);
|
||||||
// TODO: If type has no registered model, use a backup one
|
// TODO: If type has no registered model, use a backup one
|
||||||
return new Type(block, {parse: true});
|
return new Type(block, { parse: true });
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -152,7 +152,7 @@ define([
|
|||||||
}
|
}
|
||||||
|
|
||||||
CommunicationComponent.getTransformedPosts(data).done(function (posts) {
|
CommunicationComponent.getTransformedPosts(data).done(function (posts) {
|
||||||
that.get('_transformedPosts').get('blocks').reset(posts, {parse: true});
|
that.get('_transformedPosts').get('blocks').reset(posts, { parse: true });
|
||||||
}).fail(function () {
|
}).fail(function () {
|
||||||
MailPoet.Notice.error(MailPoet.I18n.t('failedToFetchRenderedPosts'));
|
MailPoet.Notice.error(MailPoet.I18n.t('failedToFetchRenderedPosts'));
|
||||||
});
|
});
|
||||||
|
@ -93,7 +93,7 @@ define([
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
App._contentContainer = new (App.getBlockTypeModel('container'))(content, {parse: true});
|
App._contentContainer = new (App.getBlockTypeModel('container'))(content, { parse: true });
|
||||||
App._contentContainerView = new (App.getBlockTypeView('container'))({
|
App._contentContainerView = new (App.getBlockTypeView('container'))({
|
||||||
model: App._contentContainer,
|
model: App._contentContainer,
|
||||||
renderOptions: { depth: 0 }
|
renderOptions: { depth: 0 }
|
||||||
|
@ -14,7 +14,7 @@ define('num',
|
|||||||
return (Math.round(num * factor) / factor)
|
return (Math.round(num * factor) / factor)
|
||||||
.toLocaleString(
|
.toLocaleString(
|
||||||
undefined,
|
undefined,
|
||||||
{minimumFractionDigits: precision, maximumFractionDigits: precision}
|
{ minimumFractionDigits: precision, maximumFractionDigits: precision }
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -10,7 +10,7 @@ define(
|
|||||||
if (confirm(MailPoet.I18n.t('reinstallConfirmation'))) {
|
if (confirm(MailPoet.I18n.t('reinstallConfirmation'))) {
|
||||||
MailPoet.trackEvent(
|
MailPoet.trackEvent(
|
||||||
'User has reinstalled MailPoet via Settings',
|
'User has reinstalled MailPoet via Settings',
|
||||||
{'MailPoet Free version': window.mailpoet_version}
|
{ 'MailPoet Free version': window.mailpoet_version }
|
||||||
);
|
);
|
||||||
|
|
||||||
MailPoet.Modal.loading(true);
|
MailPoet.Modal.loading(true);
|
||||||
@ -28,7 +28,7 @@ define(
|
|||||||
response.errors.map(function (error) {
|
response.errors.map(function (error) {
|
||||||
return error.message;
|
return error.message;
|
||||||
}),
|
}),
|
||||||
{scroll: true}
|
{ scroll: true }
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -35,7 +35,7 @@ define(
|
|||||||
step3: 'step3'
|
step3: 'step3'
|
||||||
},
|
},
|
||||||
home: function () {
|
home: function () {
|
||||||
this.navigate('step1', {trigger: true});
|
this.navigate('step1', { trigger: true });
|
||||||
}
|
}
|
||||||
}));
|
}));
|
||||||
|
|
||||||
@ -242,7 +242,7 @@ define(
|
|||||||
source: 'MailChimp',
|
source: 'MailChimp',
|
||||||
'MailPoet Free version': window.mailpoet_version
|
'MailPoet Free version': window.mailpoet_version
|
||||||
});
|
});
|
||||||
router.navigate('step2', {trigger: true});
|
router.navigate('step2', { trigger: true });
|
||||||
}).fail(function (response) {
|
}).fail(function (response) {
|
||||||
if (response.errors.length > 0) {
|
if (response.errors.length > 0) {
|
||||||
MailPoet.Notice.error(
|
MailPoet.Notice.error(
|
||||||
@ -423,7 +423,7 @@ define(
|
|||||||
source: isFile ? 'file upload' : 'pasted data',
|
source: isFile ? 'file upload' : 'pasted data',
|
||||||
'MailPoet Free version': window.mailpoet_version
|
'MailPoet Free version': window.mailpoet_version
|
||||||
});
|
});
|
||||||
router.navigate('step2', {trigger: true});
|
router.navigate('step2', { trigger: true });
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
MailPoet.Modal.loading(false);
|
MailPoet.Modal.loading(false);
|
||||||
@ -439,7 +439,7 @@ define(
|
|||||||
|
|
||||||
router.on('route:step2', function () {
|
router.on('route:step2', function () {
|
||||||
if (typeof (window.importData.step1) === 'undefined') {
|
if (typeof (window.importData.step1) === 'undefined') {
|
||||||
router.navigate('step1', {trigger: true});
|
router.navigate('step1', { trigger: true });
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
// define reusable variables
|
// define reusable variables
|
||||||
@ -678,7 +678,7 @@ define(
|
|||||||
&& displayedColumnsIds.indexOf(columnId) === -1)
|
&& displayedColumnsIds.indexOf(columnId) === -1)
|
||||||
? columnId
|
? columnId
|
||||||
: 'ignore';
|
: 'ignore';
|
||||||
displayedColumns[i] = {column_id: columnId};
|
displayedColumns[i] = { column_id: columnId };
|
||||||
displayedColumnsIds.push(columnId);
|
displayedColumnsIds.push(columnId);
|
||||||
}
|
}
|
||||||
return options.fn(displayedColumns);
|
return options.fn(displayedColumns);
|
||||||
@ -1057,7 +1057,7 @@ define(
|
|||||||
});
|
});
|
||||||
window.importData.step2 = importResults;
|
window.importData.step2 = importResults;
|
||||||
enableSegmentSelection(window.mailpoetSegments);
|
enableSegmentSelection(window.mailpoetSegments);
|
||||||
router.navigate('step3', {trigger: true});
|
router.navigate('step3', { trigger: true });
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
@ -1068,7 +1068,7 @@ define(
|
|||||||
|
|
||||||
router.on('route:step3', function () {
|
router.on('route:step3', function () {
|
||||||
if (typeof (window.importData.step2) === 'undefined') {
|
if (typeof (window.importData.step2) === 'undefined') {
|
||||||
router.navigate('step2', {trigger: true});
|
router.navigate('step2', { trigger: true });
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1111,7 +1111,7 @@ define(
|
|||||||
|
|
||||||
jQuery('a.mailpoet_import_again').off().click(function () {
|
jQuery('a.mailpoet_import_again').off().click(function () {
|
||||||
jQuery('#subscribers_data_import_results').hide();
|
jQuery('#subscribers_data_import_results').hide();
|
||||||
router.navigate('step1', {trigger: true});
|
router.navigate('step1', { trigger: true });
|
||||||
});
|
});
|
||||||
|
|
||||||
jQuery('a.mailpoet_view_subscribers').off().click(function () {
|
jQuery('a.mailpoet_view_subscribers').off().click(function () {
|
||||||
|
Reference in New Issue
Block a user