jodit 4.10.3 → 4.11.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +28 -0
- package/es2015/jodit.css +1 -1
- package/es2015/jodit.fat.min.js +15 -15
- package/es2015/jodit.js +359 -62
- package/es2015/jodit.min.js +7 -7
- package/es2015/plugins/debug/debug.css +1 -1
- package/es2015/plugins/debug/debug.js +1 -1
- package/es2015/plugins/debug/debug.min.js +1 -1
- package/es2015/plugins/speech-recognize/speech-recognize.css +1 -1
- package/es2015/plugins/speech-recognize/speech-recognize.js +1 -1
- package/es2015/plugins/speech-recognize/speech-recognize.min.js +1 -1
- package/es2018/jodit.fat.min.js +6 -6
- package/es2018/jodit.min.js +15 -15
- package/es2018/plugins/debug/debug.min.js +1 -1
- package/es2018/plugins/speech-recognize/speech-recognize.min.js +1 -1
- package/es2021/jodit.css +1 -1
- package/es2021/jodit.fat.min.js +8 -8
- package/es2021/jodit.js +358 -62
- package/es2021/jodit.min.js +9 -9
- package/es2021/plugins/debug/debug.css +1 -1
- package/es2021/plugins/debug/debug.js +1 -1
- package/es2021/plugins/debug/debug.min.js +1 -1
- package/es2021/plugins/speech-recognize/speech-recognize.css +1 -1
- package/es2021/plugins/speech-recognize/speech-recognize.js +1 -1
- package/es2021/plugins/speech-recognize/speech-recognize.min.js +1 -1
- package/es2021.en/jodit.css +1 -1
- package/es2021.en/jodit.fat.min.js +50 -50
- package/es2021.en/jodit.js +358 -62
- package/es2021.en/jodit.min.js +25 -25
- package/es2021.en/plugins/debug/debug.css +1 -1
- package/es2021.en/plugins/debug/debug.js +1 -1
- package/es2021.en/plugins/debug/debug.min.js +1 -1
- package/es2021.en/plugins/speech-recognize/speech-recognize.css +1 -1
- package/es2021.en/plugins/speech-recognize/speech-recognize.js +1 -1
- package/es2021.en/plugins/speech-recognize/speech-recognize.min.js +1 -1
- package/es5/jodit.css +2 -2
- package/es5/jodit.fat.min.js +2 -2
- package/es5/jodit.js +416 -62
- package/es5/jodit.min.css +2 -2
- package/es5/jodit.min.js +2 -2
- package/es5/plugins/debug/debug.css +1 -1
- package/es5/plugins/debug/debug.js +1 -1
- package/es5/plugins/debug/debug.min.js +1 -1
- package/es5/plugins/speech-recognize/speech-recognize.css +1 -1
- package/es5/plugins/speech-recognize/speech-recognize.js +1 -1
- package/es5/plugins/speech-recognize/speech-recognize.min.js +1 -1
- package/es5/polyfills.fat.min.js +1 -1
- package/es5/polyfills.js +1 -1
- package/es5/polyfills.min.js +1 -1
- package/esm/config.d.ts +85 -0
- package/esm/core/constants.js +1 -1
- package/esm/core/dom/dom.d.ts +1 -0
- package/esm/core/helpers/html/safe-html.d.ts +3 -2
- package/esm/core/helpers/html/safe-html.js +42 -3
- package/esm/plugins/clean-html/clean-html.js +4 -0
- package/esm/plugins/clean-html/config.d.ts +85 -0
- package/esm/plugins/clean-html/config.js +7 -1
- package/esm/plugins/clean-html/helpers/visitor/filters/convert-unsafe-embeds.d.ts +14 -0
- package/esm/plugins/clean-html/helpers/visitor/filters/convert-unsafe-embeds.js +37 -0
- package/esm/plugins/clean-html/helpers/visitor/filters/index.d.ts +4 -0
- package/esm/plugins/clean-html/helpers/visitor/filters/index.js +4 -0
- package/esm/plugins/clean-html/helpers/visitor/filters/safe-links-target.d.ts +14 -0
- package/esm/plugins/clean-html/helpers/visitor/filters/safe-links-target.js +38 -0
- package/esm/plugins/clean-html/helpers/visitor/filters/sandbox-iframes-in-content.d.ts +14 -0
- package/esm/plugins/clean-html/helpers/visitor/filters/sandbox-iframes-in-content.js +24 -0
- package/esm/plugins/clean-html/helpers/visitor/filters/sanitize-attributes.js +10 -5
- package/esm/plugins/clean-html/helpers/visitor/filters/sanitize-styles.d.ts +14 -0
- package/esm/plugins/clean-html/helpers/visitor/filters/sanitize-styles.js +70 -0
- package/esm/plugins/drag-and-drop/drag-and-drop.js +1 -1
- package/esm/plugins/enter/helpers/insert-paragraph.js +2 -1
- package/esm/plugins/file/file.js +3 -2
- package/esm/plugins/iframe/iframe.js +8 -6
- package/esm/plugins/image/image.js +3 -2
- package/esm/plugins/image-properties/writers/link.js +6 -0
- package/esm/plugins/link/link.js +15 -3
- package/esm/plugins/resizer/resizer.js +2 -2
- package/esm/plugins/source/editor/engines/area.js +3 -7
- package/package.json +1 -1
- package/types/config.d.ts +85 -0
- package/types/core/dom/dom.d.ts +1 -0
- package/types/core/helpers/html/safe-html.d.ts +3 -2
- package/types/plugins/clean-html/config.d.ts +85 -0
- package/types/plugins/clean-html/helpers/visitor/filters/convert-unsafe-embeds.d.ts +14 -0
- package/types/plugins/clean-html/helpers/visitor/filters/index.d.ts +4 -0
- package/types/plugins/clean-html/helpers/visitor/filters/safe-links-target.d.ts +14 -0
- package/types/plugins/clean-html/helpers/visitor/filters/sandbox-iframes-in-content.d.ts +14 -0
- package/types/plugins/clean-html/helpers/visitor/filters/sanitize-styles.d.ts +14 -0
package/es5/jodit.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* jodit - Jodit is an awesome and useful wysiwyg editor with filebrowser
|
|
3
3
|
* Author: Chupurnov <chupurnov@gmail.com> (https://xdsoft.net/jodit/)
|
|
4
|
-
* Version: v4.
|
|
4
|
+
* Version: v4.11.3
|
|
5
5
|
* Url: https://xdsoft.net/jodit/
|
|
6
6
|
* License(s): MIT
|
|
7
7
|
*/
|
|
@@ -2022,7 +2022,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
2022
2022
|
* @packageDocumentation
|
|
2023
2023
|
* @module constants
|
|
2024
2024
|
*/
|
|
2025
|
-
var APP_VERSION = "4.
|
|
2025
|
+
var APP_VERSION = "4.11.3";
|
|
2026
2026
|
// prettier-ignore
|
|
2027
2027
|
var ES = "es5";
|
|
2028
2028
|
var IS_ES_MODERN = false;
|
|
@@ -6882,21 +6882,77 @@ function normalizeCSS(s) {
|
|
|
6882
6882
|
/**
|
|
6883
6883
|
* Removes dangerous constructs from HTML
|
|
6884
6884
|
*/ function safeHTML(box, options) {
|
|
6885
|
+
var _options_removeEventAttributes;
|
|
6885
6886
|
if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isElement(box) && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isFragment(box)) {
|
|
6886
6887
|
return;
|
|
6887
6888
|
}
|
|
6888
|
-
|
|
6889
|
-
|
|
6889
|
+
var removeEvents = (_options_removeEventAttributes = options.removeEventAttributes) !== null && _options_removeEventAttributes !== void 0 ? _options_removeEventAttributes : options.removeOnError;
|
|
6890
|
+
if (removeEvents) {
|
|
6891
|
+
removeAllEventAttributes(box);
|
|
6892
|
+
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__.$$)('*', box).forEach(function(elm) {
|
|
6893
|
+
return removeAllEventAttributes(elm);
|
|
6894
|
+
});
|
|
6895
|
+
} else if (options.removeOnError) {
|
|
6896
|
+
sanitizeHTMLElement(box, options);
|
|
6890
6897
|
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__.$$)('[onerror]', box).forEach(function(elm) {
|
|
6891
6898
|
return sanitizeHTMLElement(elm, options);
|
|
6892
6899
|
});
|
|
6893
6900
|
}
|
|
6894
6901
|
if (options.safeJavaScriptLink) {
|
|
6895
|
-
sanitizeHTMLElement(box);
|
|
6902
|
+
sanitizeHTMLElement(box, options);
|
|
6896
6903
|
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__.$$)('a[href^="javascript"]', box).forEach(function(elm) {
|
|
6897
6904
|
return sanitizeHTMLElement(elm, options);
|
|
6898
6905
|
});
|
|
6899
6906
|
}
|
|
6907
|
+
if (options.safeLinksTarget) {
|
|
6908
|
+
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__.$$)('a[target="_blank"]', box).forEach(function(elm) {
|
|
6909
|
+
var rel = elm.getAttribute('rel') || '';
|
|
6910
|
+
var parts = rel.split(/\s+/).filter(Boolean);
|
|
6911
|
+
if (!parts.includes('noopener')) {
|
|
6912
|
+
parts.push('noopener');
|
|
6913
|
+
}
|
|
6914
|
+
if (!parts.includes('noreferrer')) {
|
|
6915
|
+
parts.push('noreferrer');
|
|
6916
|
+
}
|
|
6917
|
+
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__.attr)(elm, 'rel', parts.join(' '));
|
|
6918
|
+
});
|
|
6919
|
+
}
|
|
6920
|
+
}
|
|
6921
|
+
/**
|
|
6922
|
+
* Remove all on* event handler attributes from an element
|
|
6923
|
+
*/ function removeAllEventAttributes(elm) {
|
|
6924
|
+
if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isElement(elm)) {
|
|
6925
|
+
return false;
|
|
6926
|
+
}
|
|
6927
|
+
var effected = false;
|
|
6928
|
+
var toRemove = [];
|
|
6929
|
+
for(var i = 0; i < elm.attributes.length; i++){
|
|
6930
|
+
if (elm.attributes[i].name.toLowerCase().startsWith('on')) {
|
|
6931
|
+
toRemove.push(elm.attributes[i].name);
|
|
6932
|
+
}
|
|
6933
|
+
}
|
|
6934
|
+
var _iteratorNormalCompletion = true, _didIteratorError = false, _iteratorError = undefined;
|
|
6935
|
+
try {
|
|
6936
|
+
for(var _iterator = toRemove[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true){
|
|
6937
|
+
var name = _step.value;
|
|
6938
|
+
elm.removeAttribute(name);
|
|
6939
|
+
effected = true;
|
|
6940
|
+
}
|
|
6941
|
+
} catch (err) {
|
|
6942
|
+
_didIteratorError = true;
|
|
6943
|
+
_iteratorError = err;
|
|
6944
|
+
} finally{
|
|
6945
|
+
try {
|
|
6946
|
+
if (!_iteratorNormalCompletion && _iterator.return != null) {
|
|
6947
|
+
_iterator.return();
|
|
6948
|
+
}
|
|
6949
|
+
} finally{
|
|
6950
|
+
if (_didIteratorError) {
|
|
6951
|
+
throw _iteratorError;
|
|
6952
|
+
}
|
|
6953
|
+
}
|
|
6954
|
+
}
|
|
6955
|
+
return effected;
|
|
6900
6956
|
}
|
|
6901
6957
|
function sanitizeHTMLElement(elm) {
|
|
6902
6958
|
var _ref = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {
|
|
@@ -32105,6 +32161,10 @@ jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_10__.Icon.set('class-span', (_class_
|
|
|
32105
32161
|
{
|
|
32106
32162
|
key: "onSafeHTML",
|
|
32107
32163
|
value: function onSafeHTML(sandBox) {
|
|
32164
|
+
var sanitizer = this.j.o.cleanHTML.sanitizer;
|
|
32165
|
+
if (sanitizer) {
|
|
32166
|
+
sandBox.innerHTML = sanitizer(sandBox.innerHTML);
|
|
32167
|
+
}
|
|
32108
32168
|
(0,jodit_core_helpers_html_safe_html__WEBPACK_IMPORTED_MODULE_12__.safeHTML)(sandBox, this.j.o.cleanHTML);
|
|
32109
32169
|
}
|
|
32110
32170
|
},
|
|
@@ -32170,10 +32230,19 @@ jodit_config__WEBPACK_IMPORTED_MODULE_1__.Config.prototype.cleanHTML = {
|
|
|
32170
32230
|
b: 'strong'
|
|
32171
32231
|
},
|
|
32172
32232
|
allowTags: false,
|
|
32173
|
-
denyTags: 'script',
|
|
32233
|
+
denyTags: 'script,iframe,object,embed',
|
|
32174
32234
|
useIframeSandbox: false,
|
|
32175
32235
|
removeOnError: true,
|
|
32236
|
+
removeEventAttributes: true,
|
|
32176
32237
|
safeJavaScriptLink: true,
|
|
32238
|
+
safeLinksTarget: true,
|
|
32239
|
+
allowedStyles: false,
|
|
32240
|
+
sanitizer: false,
|
|
32241
|
+
sandboxIframesInContent: true,
|
|
32242
|
+
convertUnsafeEmbeds: [
|
|
32243
|
+
'object',
|
|
32244
|
+
'embed'
|
|
32245
|
+
],
|
|
32177
32246
|
disableCleanFilter: null
|
|
32178
32247
|
};
|
|
32179
32248
|
jodit_config__WEBPACK_IMPORTED_MODULE_1__.Config.prototype.controls.eraser = {
|
|
@@ -32437,6 +32506,56 @@ jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_0__.Icon.set('eraser', (_eraser_svg_
|
|
|
32437
32506
|
}
|
|
32438
32507
|
|
|
32439
32508
|
|
|
32509
|
+
/***/ }),
|
|
32510
|
+
|
|
32511
|
+
/***/ 85085:
|
|
32512
|
+
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
32513
|
+
|
|
32514
|
+
"use strict";
|
|
32515
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
32516
|
+
/* harmony export */ convertUnsafeEmbeds: function() { return /* binding */ convertUnsafeEmbeds; }
|
|
32517
|
+
/* harmony export */ });
|
|
32518
|
+
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211);
|
|
32519
|
+
/* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(7909);
|
|
32520
|
+
/*!
|
|
32521
|
+
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
32522
|
+
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
32523
|
+
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net
|
|
32524
|
+
*/ /**
|
|
32525
|
+
* @module plugins/clean-html
|
|
32526
|
+
*/
|
|
32527
|
+
|
|
32528
|
+
/**
|
|
32529
|
+
* Convert `<object>` and `<embed>` elements to safer `<iframe>` elements.
|
|
32530
|
+
* @private
|
|
32531
|
+
*/ function convertUnsafeEmbeds(jodit, nodeElm, hadEffect) {
|
|
32532
|
+
var opt = jodit.o.cleanHTML.convertUnsafeEmbeds;
|
|
32533
|
+
if (!opt || !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isElement(nodeElm)) {
|
|
32534
|
+
return hadEffect;
|
|
32535
|
+
}
|
|
32536
|
+
var tag = nodeElm.nodeName.toLowerCase();
|
|
32537
|
+
if (!opt.includes(tag)) {
|
|
32538
|
+
return hadEffect;
|
|
32539
|
+
}
|
|
32540
|
+
var elm = nodeElm;
|
|
32541
|
+
var src = (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(elm, 'data') || (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(elm, 'src') || (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(elm, 'movie') || '';
|
|
32542
|
+
if (!src) {
|
|
32543
|
+
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(elm);
|
|
32544
|
+
return true;
|
|
32545
|
+
}
|
|
32546
|
+
var iframe = jodit.createInside.element('iframe');
|
|
32547
|
+
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(iframe, {
|
|
32548
|
+
src: src,
|
|
32549
|
+
sandbox: '',
|
|
32550
|
+
frameborder: '0',
|
|
32551
|
+
width: (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(elm, 'width'),
|
|
32552
|
+
height: (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(elm, 'height')
|
|
32553
|
+
});
|
|
32554
|
+
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.replace(elm, iframe, undefined, false, true);
|
|
32555
|
+
return true;
|
|
32556
|
+
}
|
|
32557
|
+
|
|
32558
|
+
|
|
32440
32559
|
/***/ }),
|
|
32441
32560
|
|
|
32442
32561
|
/***/ 39188:
|
|
@@ -32484,20 +32603,28 @@ var TABLE_CONTAINER_TAGS = new Set([
|
|
|
32484
32603
|
__webpack_require__.r(__webpack_exports__);
|
|
32485
32604
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
32486
32605
|
/* harmony export */ allowAttributes: function() { return /* reexport safe */ _allow_attributes__WEBPACK_IMPORTED_MODULE_0__.allowAttributes; },
|
|
32487
|
-
/* harmony export */
|
|
32488
|
-
/* harmony export */
|
|
32489
|
-
/* harmony export */
|
|
32490
|
-
/* harmony export */
|
|
32491
|
-
/* harmony export */
|
|
32492
|
-
/* harmony export */
|
|
32606
|
+
/* harmony export */ convertUnsafeEmbeds: function() { return /* reexport safe */ _convert_unsafe_embeds__WEBPACK_IMPORTED_MODULE_1__.convertUnsafeEmbeds; },
|
|
32607
|
+
/* harmony export */ fillEmptyParagraph: function() { return /* reexport safe */ _fill_empty_paragraph__WEBPACK_IMPORTED_MODULE_2__.fillEmptyParagraph; },
|
|
32608
|
+
/* harmony export */ removeEmptyTextNode: function() { return /* reexport safe */ _remove_empty_text_node__WEBPACK_IMPORTED_MODULE_3__.removeEmptyTextNode; },
|
|
32609
|
+
/* harmony export */ removeInvTextNodes: function() { return /* reexport safe */ _remove_inv_text_nodes__WEBPACK_IMPORTED_MODULE_4__.removeInvTextNodes; },
|
|
32610
|
+
/* harmony export */ replaceOldTags: function() { return /* reexport safe */ _replace_old_tags__WEBPACK_IMPORTED_MODULE_5__.replaceOldTags; },
|
|
32611
|
+
/* harmony export */ safeLinksTarget: function() { return /* reexport safe */ _safe_links_target__WEBPACK_IMPORTED_MODULE_6__.safeLinksTarget; },
|
|
32612
|
+
/* harmony export */ sandboxIframesInContent: function() { return /* reexport safe */ _sandbox_iframes_in_content__WEBPACK_IMPORTED_MODULE_7__.sandboxIframesInContent; },
|
|
32613
|
+
/* harmony export */ sanitizeAttributes: function() { return /* reexport safe */ _sanitize_attributes__WEBPACK_IMPORTED_MODULE_8__.sanitizeAttributes; },
|
|
32614
|
+
/* harmony export */ sanitizeStyles: function() { return /* reexport safe */ _sanitize_styles__WEBPACK_IMPORTED_MODULE_9__.sanitizeStyles; },
|
|
32615
|
+
/* harmony export */ tryRemoveNode: function() { return /* reexport safe */ _try_remove_node__WEBPACK_IMPORTED_MODULE_10__.tryRemoveNode; }
|
|
32493
32616
|
/* harmony export */ });
|
|
32494
32617
|
/* harmony import */ var _allow_attributes__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(95559);
|
|
32495
|
-
/* harmony import */ var
|
|
32496
|
-
/* harmony import */ var
|
|
32497
|
-
/* harmony import */ var
|
|
32498
|
-
/* harmony import */ var
|
|
32499
|
-
/* harmony import */ var
|
|
32500
|
-
/* harmony import */ var
|
|
32618
|
+
/* harmony import */ var _convert_unsafe_embeds__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(85085);
|
|
32619
|
+
/* harmony import */ var _fill_empty_paragraph__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(39188);
|
|
32620
|
+
/* harmony import */ var _remove_empty_text_node__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(94561);
|
|
32621
|
+
/* harmony import */ var _remove_inv_text_nodes__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(53514);
|
|
32622
|
+
/* harmony import */ var _replace_old_tags__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(35104);
|
|
32623
|
+
/* harmony import */ var _safe_links_target__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(77041);
|
|
32624
|
+
/* harmony import */ var _sandbox_iframes_in_content__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(66647);
|
|
32625
|
+
/* harmony import */ var _sanitize_attributes__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(65015);
|
|
32626
|
+
/* harmony import */ var _sanitize_styles__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(60220);
|
|
32627
|
+
/* harmony import */ var _try_remove_node__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(27611);
|
|
32501
32628
|
/*!
|
|
32502
32629
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
32503
32630
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
@@ -32515,6 +32642,10 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
32515
32642
|
|
|
32516
32643
|
|
|
32517
32644
|
|
|
32645
|
+
|
|
32646
|
+
|
|
32647
|
+
|
|
32648
|
+
|
|
32518
32649
|
/***/ }),
|
|
32519
32650
|
|
|
32520
32651
|
/***/ 94561:
|
|
@@ -32631,6 +32762,90 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
32631
32762
|
}
|
|
32632
32763
|
|
|
32633
32764
|
|
|
32765
|
+
/***/ }),
|
|
32766
|
+
|
|
32767
|
+
/***/ 77041:
|
|
32768
|
+
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
32769
|
+
|
|
32770
|
+
"use strict";
|
|
32771
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
32772
|
+
/* harmony export */ safeLinksTarget: function() { return /* binding */ safeLinksTarget; }
|
|
32773
|
+
/* harmony export */ });
|
|
32774
|
+
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211);
|
|
32775
|
+
/* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(7909);
|
|
32776
|
+
/*!
|
|
32777
|
+
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
32778
|
+
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
32779
|
+
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net
|
|
32780
|
+
*/ /**
|
|
32781
|
+
* @module plugins/clean-html
|
|
32782
|
+
*/
|
|
32783
|
+
|
|
32784
|
+
/**
|
|
32785
|
+
* Automatically add `rel="noopener noreferrer"` to links with `target="_blank"`
|
|
32786
|
+
* @private
|
|
32787
|
+
*/ function safeLinksTarget(jodit, nodeElm, hadEffect) {
|
|
32788
|
+
if (!jodit.o.cleanHTML.safeLinksTarget || !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isElement(nodeElm) || nodeElm.nodeName !== 'A') {
|
|
32789
|
+
return hadEffect;
|
|
32790
|
+
}
|
|
32791
|
+
var elm = nodeElm;
|
|
32792
|
+
if ((0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(elm, 'target') !== '_blank') {
|
|
32793
|
+
return hadEffect;
|
|
32794
|
+
}
|
|
32795
|
+
var rel = (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(elm, 'rel') || '';
|
|
32796
|
+
var parts = rel.split(/\s+/).filter(Boolean);
|
|
32797
|
+
var changed = false;
|
|
32798
|
+
if (!parts.includes('noopener')) {
|
|
32799
|
+
parts.push('noopener');
|
|
32800
|
+
changed = true;
|
|
32801
|
+
}
|
|
32802
|
+
if (!parts.includes('noreferrer')) {
|
|
32803
|
+
parts.push('noreferrer');
|
|
32804
|
+
changed = true;
|
|
32805
|
+
}
|
|
32806
|
+
if (changed) {
|
|
32807
|
+
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(elm, 'rel', parts.join(' '));
|
|
32808
|
+
return true;
|
|
32809
|
+
}
|
|
32810
|
+
return hadEffect;
|
|
32811
|
+
}
|
|
32812
|
+
|
|
32813
|
+
|
|
32814
|
+
/***/ }),
|
|
32815
|
+
|
|
32816
|
+
/***/ 66647:
|
|
32817
|
+
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
32818
|
+
|
|
32819
|
+
"use strict";
|
|
32820
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
32821
|
+
/* harmony export */ sandboxIframesInContent: function() { return /* binding */ sandboxIframesInContent; }
|
|
32822
|
+
/* harmony export */ });
|
|
32823
|
+
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211);
|
|
32824
|
+
/* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(7909);
|
|
32825
|
+
/*!
|
|
32826
|
+
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
32827
|
+
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
32828
|
+
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net
|
|
32829
|
+
*/ /**
|
|
32830
|
+
* @module plugins/clean-html
|
|
32831
|
+
*/
|
|
32832
|
+
|
|
32833
|
+
/**
|
|
32834
|
+
* Add `sandbox=""` attribute to all `<iframe>` elements in the editor content
|
|
32835
|
+
* @private
|
|
32836
|
+
*/ function sandboxIframesInContent(jodit, nodeElm, hadEffect) {
|
|
32837
|
+
if (!jodit.o.cleanHTML.sandboxIframesInContent || !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isElement(nodeElm) || nodeElm.nodeName !== 'IFRAME') {
|
|
32838
|
+
return hadEffect;
|
|
32839
|
+
}
|
|
32840
|
+
var elm = nodeElm;
|
|
32841
|
+
if (!elm.hasAttribute('sandbox')) {
|
|
32842
|
+
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(elm, 'sandbox', '');
|
|
32843
|
+
return true;
|
|
32844
|
+
}
|
|
32845
|
+
return hadEffect;
|
|
32846
|
+
}
|
|
32847
|
+
|
|
32848
|
+
|
|
32634
32849
|
/***/ }),
|
|
32635
32850
|
|
|
32636
32851
|
/***/ 65015:
|
|
@@ -32653,9 +32868,15 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
32653
32868
|
/**
|
|
32654
32869
|
* @private
|
|
32655
32870
|
*/ function sanitizeAttributes(jodit, nodeElm, hadEffect) {
|
|
32656
|
-
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isElement(nodeElm)
|
|
32657
|
-
|
|
32658
|
-
|
|
32871
|
+
if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isElement(nodeElm)) {
|
|
32872
|
+
return hadEffect;
|
|
32873
|
+
}
|
|
32874
|
+
var opts = jodit.options.cleanHTML;
|
|
32875
|
+
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__.sanitizeHTMLElement)(nodeElm, {
|
|
32876
|
+
safeJavaScriptLink: opts.safeJavaScriptLink,
|
|
32877
|
+
removeOnError: opts.removeOnError,
|
|
32878
|
+
removeEventAttributes: opts.removeEventAttributes,
|
|
32879
|
+
safeLinksTarget: opts.safeLinksTarget
|
|
32659
32880
|
})) {
|
|
32660
32881
|
return true;
|
|
32661
32882
|
}
|
|
@@ -32663,6 +32884,120 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
32663
32884
|
}
|
|
32664
32885
|
|
|
32665
32886
|
|
|
32887
|
+
/***/ }),
|
|
32888
|
+
|
|
32889
|
+
/***/ 60220:
|
|
32890
|
+
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
32891
|
+
|
|
32892
|
+
"use strict";
|
|
32893
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
32894
|
+
/* harmony export */ sanitizeStyles: function() { return /* binding */ sanitizeStyles; }
|
|
32895
|
+
/* harmony export */ });
|
|
32896
|
+
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211);
|
|
32897
|
+
/* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(7909);
|
|
32898
|
+
/*!
|
|
32899
|
+
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
32900
|
+
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
32901
|
+
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net
|
|
32902
|
+
*/ /**
|
|
32903
|
+
* @module plugins/clean-html
|
|
32904
|
+
*/
|
|
32905
|
+
|
|
32906
|
+
/**
|
|
32907
|
+
* Filter CSS properties in style attributes based on allowedStyles whitelist
|
|
32908
|
+
* @private
|
|
32909
|
+
*/ function sanitizeStyles(jodit, nodeElm, hadEffect) {
|
|
32910
|
+
var allowedStyles = jodit.o.cleanHTML.allowedStyles;
|
|
32911
|
+
if (!allowedStyles || !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isElement(nodeElm)) {
|
|
32912
|
+
return hadEffect;
|
|
32913
|
+
}
|
|
32914
|
+
var elm = nodeElm;
|
|
32915
|
+
var style = (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(elm, 'style');
|
|
32916
|
+
if (!style) {
|
|
32917
|
+
return hadEffect;
|
|
32918
|
+
}
|
|
32919
|
+
var tagName = nodeElm.nodeName.toLowerCase();
|
|
32920
|
+
var allowed = getAllowedPropsForTag(tagName, allowedStyles);
|
|
32921
|
+
if (!allowed) {
|
|
32922
|
+
return hadEffect;
|
|
32923
|
+
}
|
|
32924
|
+
var filtered = filterStyleProperties(style, allowed);
|
|
32925
|
+
if (filtered !== style) {
|
|
32926
|
+
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(elm, 'style', filtered || null);
|
|
32927
|
+
return true;
|
|
32928
|
+
}
|
|
32929
|
+
return hadEffect;
|
|
32930
|
+
}
|
|
32931
|
+
function getAllowedPropsForTag(tagName, allowedStyles) {
|
|
32932
|
+
var tagSpecific = allowedStyles[tagName];
|
|
32933
|
+
var global = allowedStyles['*'];
|
|
32934
|
+
if (!tagSpecific && !global) {
|
|
32935
|
+
return null;
|
|
32936
|
+
}
|
|
32937
|
+
var set = new Set();
|
|
32938
|
+
if (global) {
|
|
32939
|
+
var _iteratorNormalCompletion = true, _didIteratorError = false, _iteratorError = undefined;
|
|
32940
|
+
try {
|
|
32941
|
+
for(var _iterator = global[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true){
|
|
32942
|
+
var prop = _step.value;
|
|
32943
|
+
set.add(prop.toLowerCase());
|
|
32944
|
+
}
|
|
32945
|
+
} catch (err) {
|
|
32946
|
+
_didIteratorError = true;
|
|
32947
|
+
_iteratorError = err;
|
|
32948
|
+
} finally{
|
|
32949
|
+
try {
|
|
32950
|
+
if (!_iteratorNormalCompletion && _iterator.return != null) {
|
|
32951
|
+
_iterator.return();
|
|
32952
|
+
}
|
|
32953
|
+
} finally{
|
|
32954
|
+
if (_didIteratorError) {
|
|
32955
|
+
throw _iteratorError;
|
|
32956
|
+
}
|
|
32957
|
+
}
|
|
32958
|
+
}
|
|
32959
|
+
}
|
|
32960
|
+
if (tagSpecific) {
|
|
32961
|
+
var _iteratorNormalCompletion1 = true, _didIteratorError1 = false, _iteratorError1 = undefined;
|
|
32962
|
+
try {
|
|
32963
|
+
for(var _iterator1 = tagSpecific[Symbol.iterator](), _step1; !(_iteratorNormalCompletion1 = (_step1 = _iterator1.next()).done); _iteratorNormalCompletion1 = true){
|
|
32964
|
+
var prop1 = _step1.value;
|
|
32965
|
+
set.add(prop1.toLowerCase());
|
|
32966
|
+
}
|
|
32967
|
+
} catch (err) {
|
|
32968
|
+
_didIteratorError1 = true;
|
|
32969
|
+
_iteratorError1 = err;
|
|
32970
|
+
} finally{
|
|
32971
|
+
try {
|
|
32972
|
+
if (!_iteratorNormalCompletion1 && _iterator1.return != null) {
|
|
32973
|
+
_iterator1.return();
|
|
32974
|
+
}
|
|
32975
|
+
} finally{
|
|
32976
|
+
if (_didIteratorError1) {
|
|
32977
|
+
throw _iteratorError1;
|
|
32978
|
+
}
|
|
32979
|
+
}
|
|
32980
|
+
}
|
|
32981
|
+
}
|
|
32982
|
+
return set;
|
|
32983
|
+
}
|
|
32984
|
+
function filterStyleProperties(style, allowed) {
|
|
32985
|
+
return style.split(';').map(function(s) {
|
|
32986
|
+
return s.trim();
|
|
32987
|
+
}).filter(function(s) {
|
|
32988
|
+
if (!s) {
|
|
32989
|
+
return false;
|
|
32990
|
+
}
|
|
32991
|
+
var colonIdx = s.indexOf(':');
|
|
32992
|
+
if (colonIdx === -1) {
|
|
32993
|
+
return false;
|
|
32994
|
+
}
|
|
32995
|
+
var prop = s.substring(0, colonIdx).trim().toLowerCase();
|
|
32996
|
+
return allowed.has(prop);
|
|
32997
|
+
}).join('; ').replace(/;\s*$/, '');
|
|
32998
|
+
}
|
|
32999
|
+
|
|
33000
|
+
|
|
32666
33001
|
/***/ }),
|
|
32667
33002
|
|
|
32668
33003
|
/***/ 27611:
|
|
@@ -34304,7 +34639,7 @@ jodit_core_global__WEBPACK_IMPORTED_MODULE_9__.pluginSystem.add('dragAndDropElem
|
|
|
34304
34639
|
'src'
|
|
34305
34640
|
], 2), tagName = _ref[0], field = _ref[1];
|
|
34306
34641
|
fragment = this.j.createInside.element(tagName);
|
|
34307
|
-
|
|
34642
|
+
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_12__.attr)(fragment, field, (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_12__.attr)(this.draggable, 'data-src') || (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_12__.attr)(this.draggable, 'src') || '');
|
|
34308
34643
|
if (tagName === 'a') {
|
|
34309
34644
|
fragment.textContent = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_12__.attr)(fragment, field) || '';
|
|
34310
34645
|
}
|
|
@@ -35000,7 +35335,8 @@ function brBefore(start) {
|
|
|
35000
35335
|
/* harmony export */ insertParagraph: function() { return /* binding */ insertParagraph; }
|
|
35001
35336
|
/* harmony export */ });
|
|
35002
35337
|
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211);
|
|
35003
|
-
/* harmony import */ var
|
|
35338
|
+
/* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(7909);
|
|
35339
|
+
/* harmony import */ var jodit_core_helpers_utils_scroll_into_view__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(60898);
|
|
35004
35340
|
/*!
|
|
35005
35341
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
35006
35342
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
@@ -35009,6 +35345,7 @@ function brBefore(start) {
|
|
|
35009
35345
|
* @module plugins/enter
|
|
35010
35346
|
*/
|
|
35011
35347
|
|
|
35348
|
+
|
|
35012
35349
|
/**
|
|
35013
35350
|
* Insert default paragraph
|
|
35014
35351
|
* @private
|
|
@@ -35018,11 +35355,11 @@ function brBefore(start) {
|
|
|
35018
35355
|
p.appendChild(br);
|
|
35019
35356
|
}
|
|
35020
35357
|
if (style && style.cssText) {
|
|
35021
|
-
|
|
35358
|
+
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(p, 'style', style.cssText);
|
|
35022
35359
|
}
|
|
35023
35360
|
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.after(fake, p);
|
|
35024
35361
|
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.before(isBR ? p : br, fake);
|
|
35025
|
-
(0,
|
|
35362
|
+
(0,jodit_core_helpers_utils_scroll_into_view__WEBPACK_IMPORTED_MODULE_2__.scrollIntoViewIfNeeded)(p, editor.editor, editor.ed);
|
|
35026
35363
|
return p;
|
|
35027
35364
|
}
|
|
35028
35365
|
|
|
@@ -35212,8 +35549,9 @@ function brBefore(start) {
|
|
|
35212
35549
|
/* unused harmony export file */
|
|
35213
35550
|
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211);
|
|
35214
35551
|
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(28077);
|
|
35215
|
-
/* harmony import */ var
|
|
35216
|
-
/* harmony import */ var
|
|
35552
|
+
/* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(7909);
|
|
35553
|
+
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5266);
|
|
35554
|
+
/* harmony import */ var jodit_modules_widget__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(15753);
|
|
35217
35555
|
/*!
|
|
35218
35556
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
35219
35557
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
@@ -35226,7 +35564,8 @@ function brBefore(start) {
|
|
|
35226
35564
|
|
|
35227
35565
|
|
|
35228
35566
|
|
|
35229
|
-
|
|
35567
|
+
|
|
35568
|
+
jodit_config__WEBPACK_IMPORTED_MODULE_3__.Config.prototype.controls.file = {
|
|
35230
35569
|
popup: function popup(editor, current, close) {
|
|
35231
35570
|
var insert = function insert(url) {
|
|
35232
35571
|
var title = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : '';
|
|
@@ -35236,7 +35575,7 @@ jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.controls.file = {
|
|
|
35236
35575
|
if (current && (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(current, 'a') || jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(current, 'a', editor.editor))) {
|
|
35237
35576
|
sourceAnchor = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(current, 'a') ? current : jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(current, 'a', editor.editor);
|
|
35238
35577
|
}
|
|
35239
|
-
return (0,
|
|
35578
|
+
return (0,jodit_modules_widget__WEBPACK_IMPORTED_MODULE_4__.FileSelectorWidget)(editor, {
|
|
35240
35579
|
filebrowser: function filebrowser(data) {
|
|
35241
35580
|
data.files && data.files.forEach(function(file) {
|
|
35242
35581
|
return insert(data.baseurl + file);
|
|
@@ -35246,8 +35585,8 @@ jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.controls.file = {
|
|
|
35246
35585
|
upload: true,
|
|
35247
35586
|
url: function url(url, text) {
|
|
35248
35587
|
if (sourceAnchor) {
|
|
35249
|
-
|
|
35250
|
-
|
|
35588
|
+
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_2__.attr)(sourceAnchor, 'href', url);
|
|
35589
|
+
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_2__.attr)(sourceAnchor, 'title', text);
|
|
35251
35590
|
} else {
|
|
35252
35591
|
insert(url, text);
|
|
35253
35592
|
}
|
|
@@ -36158,8 +36497,8 @@ jodit_config__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.iframeSandbox = null;
|
|
|
36158
36497
|
if (opt.iframeCSSLinks) {
|
|
36159
36498
|
opt.iframeCSSLinks.forEach(function(href) {
|
|
36160
36499
|
var link = doc.createElement('link');
|
|
36161
|
-
|
|
36162
|
-
|
|
36500
|
+
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_2__.attr)(link, 'rel', 'stylesheet');
|
|
36501
|
+
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_2__.attr)(link, 'href', href);
|
|
36163
36502
|
doc.head && doc.head.appendChild(link);
|
|
36164
36503
|
});
|
|
36165
36504
|
}
|
|
@@ -36176,11 +36515,13 @@ jodit_config__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.iframeSandbox = null;
|
|
|
36176
36515
|
_$iframe.style.display = 'block';
|
|
36177
36516
|
_$iframe.src = 'about:blank';
|
|
36178
36517
|
_$iframe.className = 'jodit-wysiwyg_iframe';
|
|
36179
|
-
_$iframe
|
|
36180
|
-
|
|
36181
|
-
|
|
36518
|
+
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_2__.attr)(_$iframe, {
|
|
36519
|
+
allowtransparency: 'true',
|
|
36520
|
+
tabindex: opt.tabIndex.toString(),
|
|
36521
|
+
frameborder: '0'
|
|
36522
|
+
});
|
|
36182
36523
|
if (opt.iframeSandbox != null) {
|
|
36183
|
-
_$iframe
|
|
36524
|
+
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_2__.attr)(_$iframe, 'sandbox', opt.iframeSandbox);
|
|
36184
36525
|
}
|
|
36185
36526
|
editor.workplace.appendChild(_$iframe);
|
|
36186
36527
|
editor.iframe = _$iframe;
|
|
@@ -38294,6 +38635,12 @@ UIImagePositionTab = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_6__.__
|
|
|
38294
38635
|
}
|
|
38295
38636
|
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(link, 'href', imageLink);
|
|
38296
38637
|
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(link, 'target', imageLinkOpenInNewTab ? '_blank' : null);
|
|
38638
|
+
if (!imageLinkOpenInNewTab) {
|
|
38639
|
+
var relParts = ((0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(link, 'rel') || '').split(/\s+/).filter(function(p) {
|
|
38640
|
+
return p && p !== 'noopener' && p !== 'noreferrer';
|
|
38641
|
+
});
|
|
38642
|
+
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(link, 'rel', relParts.length ? relParts.join(' ') : null);
|
|
38643
|
+
}
|
|
38297
38644
|
} else {
|
|
38298
38645
|
if (link && link.parentNode) {
|
|
38299
38646
|
link.parentNode.replaceChild(image, link);
|
|
@@ -38405,11 +38752,12 @@ UIImagePositionTab = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_6__.__
|
|
|
38405
38752
|
/* harmony import */ var jodit_core_dom__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(27795);
|
|
38406
38753
|
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(28077);
|
|
38407
38754
|
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(65946);
|
|
38408
|
-
/* harmony import */ var
|
|
38409
|
-
/* harmony import */ var
|
|
38410
|
-
/* harmony import */ var
|
|
38411
|
-
/* harmony import */ var
|
|
38412
|
-
/* harmony import */ var
|
|
38755
|
+
/* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(7909);
|
|
38756
|
+
/* harmony import */ var jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(29434);
|
|
38757
|
+
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(5266);
|
|
38758
|
+
/* harmony import */ var jodit_modules_widget__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(15753);
|
|
38759
|
+
/* harmony import */ var _image_svg__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(64831);
|
|
38760
|
+
/* harmony import */ var _image_svg__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(_image_svg__WEBPACK_IMPORTED_MODULE_9__);
|
|
38413
38761
|
/*!
|
|
38414
38762
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
38415
38763
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
@@ -38427,15 +38775,16 @@ UIImagePositionTab = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_6__.__
|
|
|
38427
38775
|
|
|
38428
38776
|
|
|
38429
38777
|
|
|
38430
|
-
|
|
38431
|
-
|
|
38778
|
+
|
|
38779
|
+
jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_6__.Icon.set('image', (_image_svg__WEBPACK_IMPORTED_MODULE_9___default()));
|
|
38780
|
+
jodit_config__WEBPACK_IMPORTED_MODULE_7__.Config.prototype.controls.image = {
|
|
38432
38781
|
popup: function popup(editor, current, close) {
|
|
38433
38782
|
var sourceImage = null;
|
|
38434
38783
|
if (current && !jodit_core_dom__WEBPACK_IMPORTED_MODULE_2__.Dom.isText(current) && jodit_core_dom__WEBPACK_IMPORTED_MODULE_2__.Dom.isHTMLElement(current) && (jodit_core_dom__WEBPACK_IMPORTED_MODULE_2__.Dom.isTag(current, 'img') || (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.$$)('img', current).length)) {
|
|
38435
38784
|
sourceImage = jodit_core_dom__WEBPACK_IMPORTED_MODULE_2__.Dom.isTag(current, 'img') ? current : (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.$$)('img', current)[0];
|
|
38436
38785
|
}
|
|
38437
38786
|
editor.s.save();
|
|
38438
|
-
return (0,
|
|
38787
|
+
return (0,jodit_modules_widget__WEBPACK_IMPORTED_MODULE_8__.FileSelectorWidget)(editor, {
|
|
38439
38788
|
filebrowser: function filebrowser(data) {
|
|
38440
38789
|
editor.s.restore();
|
|
38441
38790
|
data.files && data.files.forEach(function(file) {
|
|
@@ -38455,8 +38804,8 @@ jodit_config__WEBPACK_IMPORTED_MODULE_6__.Config.prototype.controls.image = {
|
|
|
38455
38804
|
url = '//' + url;
|
|
38456
38805
|
}
|
|
38457
38806
|
_$image = sourceImage || editor.createInside.element('img');
|
|
38458
|
-
_$image
|
|
38459
|
-
_$image
|
|
38807
|
+
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_5__.attr)(_$image, 'src', url);
|
|
38808
|
+
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_5__.attr)(_$image, 'alt', text);
|
|
38460
38809
|
if (!!sourceImage) return [
|
|
38461
38810
|
3,
|
|
38462
38811
|
2
|
|
@@ -40731,7 +41080,7 @@ jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.controls.link = {
|
|
|
40731
41080
|
}
|
|
40732
41081
|
if (jodit.s.isCollapsed()) {
|
|
40733
41082
|
var a = jodit.createInside.element('a');
|
|
40734
|
-
|
|
41083
|
+
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_10__.attr)(a, 'href', html);
|
|
40735
41084
|
a.textContent = html;
|
|
40736
41085
|
jodit.e.fire('applyLink', jodit, a, null);
|
|
40737
41086
|
return a;
|
|
@@ -40796,7 +41145,7 @@ jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.controls.link = {
|
|
|
40796
41145
|
target_checkbox.checked = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_10__.attr)(_$link, 'target') === '_blank';
|
|
40797
41146
|
}
|
|
40798
41147
|
if (noFollowCheckbox && nofollow_checkbox) {
|
|
40799
|
-
nofollow_checkbox.checked = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_10__.attr)(_$link, 'rel')
|
|
41148
|
+
nofollow_checkbox.checked = ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_10__.attr)(_$link, 'rel') || '').split(/\s+/).includes('nofollow');
|
|
40800
41149
|
}
|
|
40801
41150
|
insert.textContent = i18n('Update');
|
|
40802
41151
|
} else {
|
|
@@ -40864,7 +41213,14 @@ jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.controls.link = {
|
|
|
40864
41213
|
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_10__.attr)(a, 'target', target_checkbox.checked ? '_blank' : null);
|
|
40865
41214
|
}
|
|
40866
41215
|
if (noFollowCheckbox && nofollow_checkbox) {
|
|
40867
|
-
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_10__.attr)(a, 'rel'
|
|
41216
|
+
var relParts = ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_10__.attr)(a, 'rel') || '').split(/\s+/).filter(Boolean);
|
|
41217
|
+
var hasNofollow = relParts.includes('nofollow');
|
|
41218
|
+
if (nofollow_checkbox.checked && !hasNofollow) {
|
|
41219
|
+
relParts.push('nofollow');
|
|
41220
|
+
} else if (!nofollow_checkbox.checked && hasNofollow) {
|
|
41221
|
+
relParts.splice(relParts.indexOf('nofollow'), 1);
|
|
41222
|
+
}
|
|
41223
|
+
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_10__.attr)(a, 'rel', relParts.length ? relParts.join(' ') : null);
|
|
40868
41224
|
}
|
|
40869
41225
|
jodit.e.fire('applyLink', jodit, a, form);
|
|
40870
41226
|
});
|
|
@@ -44038,8 +44394,8 @@ var keyBInd = '__jodit-resizer_binded';
|
|
|
44038
44394
|
this.j.e.off(element, 'mousedown.select touchstart.select').on(element, 'mousedown.select touchstart.select', function() {
|
|
44039
44395
|
_this.j.s.select(element);
|
|
44040
44396
|
}).off(element, 'changesize').on(element, 'changesize', function() {
|
|
44041
|
-
|
|
44042
|
-
|
|
44397
|
+
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_11__.attr)(iframe, 'width', element.offsetWidth + 'px');
|
|
44398
|
+
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_11__.attr)(iframe, 'height', element.offsetHeight + 'px');
|
|
44043
44399
|
});
|
|
44044
44400
|
}
|
|
44045
44401
|
this.j.e.on(element, 'dragstart', this.hide);
|
|
@@ -46663,8 +47019,9 @@ var AceEditor = /*#__PURE__*/ function(SourceEditor) {
|
|
|
46663
47019
|
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(25045);
|
|
46664
47020
|
/* harmony import */ var _swc_helpers_inherits__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(34918);
|
|
46665
47021
|
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(23211);
|
|
46666
|
-
/* harmony import */ var
|
|
46667
|
-
/* harmony import */ var
|
|
47022
|
+
/* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(7909);
|
|
47023
|
+
/* harmony import */ var jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(80991);
|
|
47024
|
+
/* harmony import */ var jodit_plugins_source_editor_sourceEditor__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(94193);
|
|
46668
47025
|
/*!
|
|
46669
47026
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
46670
47027
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
@@ -46679,6 +47036,7 @@ var AceEditor = /*#__PURE__*/ function(SourceEditor) {
|
|
|
46679
47036
|
|
|
46680
47037
|
|
|
46681
47038
|
|
|
47039
|
+
|
|
46682
47040
|
var TextAreaEditor = /*#__PURE__*/ function(SourceEditor) {
|
|
46683
47041
|
"use strict";
|
|
46684
47042
|
(0,_swc_helpers_inherits__WEBPACK_IMPORTED_MODULE_4__._)(TextAreaEditor, SourceEditor);
|
|
@@ -46702,7 +47060,7 @@ var TextAreaEditor = /*#__PURE__*/ function(SourceEditor) {
|
|
|
46702
47060
|
});
|
|
46703
47061
|
this.container.appendChild(this.instance);
|
|
46704
47062
|
editor.e.on(this.instance, 'mousedown keydown touchstart input', editor.async.debounce(this.toWYSIWYG, editor.defaultTimeout)).on('setMinHeight.source', function(minHeightD) {
|
|
46705
|
-
(0,
|
|
47063
|
+
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_7__.css)(_this.instance, 'minHeight', minHeightD);
|
|
46706
47064
|
}).on(this.instance, 'change keydown mousedown touchstart input', this.autosize).on('afterSetMode.source', this.autosize).on(this.instance, 'mousedown focus', function(e) {
|
|
46707
47065
|
editor.e.fire(e.type, e);
|
|
46708
47066
|
});
|
|
@@ -46780,17 +47138,13 @@ var TextAreaEditor = /*#__PURE__*/ function(SourceEditor) {
|
|
|
46780
47138
|
{
|
|
46781
47139
|
key: "setPlaceHolder",
|
|
46782
47140
|
value: function setPlaceHolder(title) {
|
|
46783
|
-
this.instance
|
|
47141
|
+
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_6__.attr)(this.instance, 'placeholder', title);
|
|
46784
47142
|
}
|
|
46785
47143
|
},
|
|
46786
47144
|
{
|
|
46787
47145
|
key: "setReadOnly",
|
|
46788
47146
|
value: function setReadOnly(isReadOnly) {
|
|
46789
|
-
|
|
46790
|
-
this.instance.setAttribute('readonly', 'true');
|
|
46791
|
-
} else {
|
|
46792
|
-
this.instance.removeAttribute('readonly');
|
|
46793
|
-
}
|
|
47147
|
+
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_6__.attr)(this.instance, 'readonly', isReadOnly ? 'true' : null);
|
|
46794
47148
|
}
|
|
46795
47149
|
},
|
|
46796
47150
|
{
|
|
@@ -46819,7 +47173,7 @@ var TextAreaEditor = /*#__PURE__*/ function(SourceEditor) {
|
|
|
46819
47173
|
}
|
|
46820
47174
|
]);
|
|
46821
47175
|
return TextAreaEditor;
|
|
46822
|
-
}(
|
|
47176
|
+
}(jodit_plugins_source_editor_sourceEditor__WEBPACK_IMPORTED_MODULE_8__.SourceEditor);
|
|
46823
47177
|
|
|
46824
47178
|
|
|
46825
47179
|
/***/ }),
|