Skip to content

Commit b3fd720

Browse files
committed
AC-12726::[2.4.8-beta1] TinyMCE 5 migration to TinyMCE 7
1 parent 16ad098 commit b3fd720

File tree

3 files changed

+12
-8
lines changed

3 files changed

+12
-8
lines changed

dev/tests/integration/_files/Magento/TestModuleWysiwygConfig/view/adminhtml/web/wysiwyg/tinymceTestAdapter.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
* See COPYING.txt for license details.
44
*/
55

6-
/* global popups, tinyMceEditors, MediabrowserUtility, Base64 */
76
/* eslint-disable strict */
87
define([
98
'mage/adminhtml/wysiwyg/tiny_mce/tinymceAdapter'

lib/web/mage/adminhtml/wysiwyg/tiny_mce/plugins/magentovariable/editor_plugin.js

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,8 @@ define([
1313
'mage/adminhtml/tools'
1414
], function (configDirectiveGenerator, customDirectiveGenerator, wysiwyg, jQuery) {
1515
return function (config) {
16-
var magentovariable = function(editor, url) {
16+
var self = null;
17+
var magentovariable = function (editor) {
1718
this.widget = {
1819
/**
1920
* Encode variables in content
@@ -53,8 +54,8 @@ define([
5354
magentoVariables = JSON.parse(config.placeholders);
5455

5556
if (magentoVariables[match[1]] && magentoVariables[match[1]]['variable_type'] === 'custom') {
56-
imageHtml = '<span id="%id" class="magento-variable magento-custom-var magento-placeholder ' +
57-
'mceNonEditable">%s</span>';
57+
imageHtml = '<span id="%id" class="magento-variable magento-custom-var ' +
58+
'magento-placeholder mceNonEditable">%s</span>';
5859
imageHtml = imageHtml.replace('%s', magentoVariables[match[1]]['variable_name']);
5960
} else {
6061
imageHtml = '<span id="%id" class="' +
@@ -123,7 +124,8 @@ define([
123124
}
124125
};
125126

126-
var self = this.widget;
127+
self = this.widget;
128+
127129
this.activePlaceholder = null;
128130

129131
/**

lib/web/mage/adminhtml/wysiwyg/tiny_mce/plugins/magentowidget/editor_plugin.js

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,8 @@ define([
1111
'mage/adminhtml/wysiwyg/widget'
1212
], function (wysiwyg, varienGlobalEvents) {
1313
return function (config) {
14-
var magentowidget = function(editor, url) {
14+
var self = null;
15+
var magentowidget = function (editor) {
1516
this.widget = {
1617
/**
1718
* @param {Object} placeholder - Contains the selected node
@@ -54,7 +55,8 @@ define([
5455
} else {
5556
imageSrc = config['error_image_url'];
5657
imageHtml += '<span ' +
57-
'class="magento-placeholder magento-placeholder-error magento-widget mceNonEditable" ' +
58+
'class="magento-placeholder magento-placeholder-error magento-widget ' +
59+
'mceNonEditable" ' +
5860
'contenteditable="false">';
5961
}
6062

@@ -153,7 +155,8 @@ define([
153155
}
154156
};
155157

156-
var self = this.widget;
158+
self = this.widget;
159+
157160
this.activePlaceholder = null;
158161

159162
editor.addCommand('mceMagentowidget', function (img) {

0 commit comments

Comments
 (0)