| 1 |
/*! |
| 2 |
* jodit - Jodit is an awesome and useful wysiwyg editor with filebrowser |
| 3 |
* Author: Chupurnov <[email protected]> (https://xdsoft.net/jodit/) |
| 4 |
* Version: v4.9.14 |
| 5 |
* Url: https://xdsoft.net/jodit/ |
| 6 |
* License(s): MIT |
| 7 |
*/ |
| 8 |
|
| 9 |
(function webpackUniversalModuleDefinition(root, factory) { |
| 10 |
if(typeof exports === 'object' && typeof module === 'object') |
| 11 |
module.exports = factory(require("{}")); |
| 12 |
else if(typeof define === 'function' && define.amd) |
| 13 |
define(["{}"], factory); |
| 14 |
else { |
| 15 |
var a = typeof exports === 'object' ? factory(require("{}")) : factory(root["{}"]); |
| 16 |
for(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i]; |
| 17 |
} |
| 18 |
})(self, function(__WEBPACK_EXTERNAL_MODULE__41324__) { |
| 19 |
return /******/ (function() { // webpackBootstrap |
| 20 |
/******/ var __webpack_modules__ = ({ |
| 21 |
|
| 22 |
/***/ 421: |
| 23 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 24 |
|
| 25 |
"use strict"; |
| 26 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 27 |
/* harmony export */ getClassName: function() { return /* binding */ getClassName; }, |
| 28 |
/* harmony export */ keepNames: function() { return /* binding */ keepNames; } |
| 29 |
/* harmony export */ }); |
| 30 |
/* harmony import */ var jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(91565); |
| 31 |
/*! |
| 32 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 33 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 34 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 35 |
*/ /** |
| 36 |
* @module helpers/utils |
| 37 |
*/ |
| 38 |
const keepNames = new Map(); |
| 39 |
const getClassName = (obj)=>{ |
| 40 |
var _obj_constructor; |
| 41 |
if ((0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_0__.isFunction)(obj.className)) { |
| 42 |
return obj.className(); |
| 43 |
} |
| 44 |
const constructor = ((_obj_constructor = obj.constructor) === null || _obj_constructor === void 0 ? void 0 : _obj_constructor.originalConstructor) || obj.constructor; |
| 45 |
if (keepNames.has(constructor)) { |
| 46 |
return keepNames.get(constructor); |
| 47 |
} |
| 48 |
if (constructor.name) { |
| 49 |
return constructor.name; |
| 50 |
} |
| 51 |
const regex = new RegExp(/^\s*function\s*(\S*)\s*\(/); |
| 52 |
const res = constructor.toString().match(regex); |
| 53 |
return res ? res[1] : ''; |
| 54 |
}; |
| 55 |
|
| 56 |
|
| 57 |
/***/ }), |
| 58 |
|
| 59 |
/***/ 442: |
| 60 |
/***/ (function(module) { |
| 61 |
|
| 62 |
/*! |
| 63 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 64 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 65 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 66 |
*/ module.exports = { |
| 67 |
symbols: 'Símbolo' |
| 68 |
}; |
| 69 |
|
| 70 |
|
| 71 |
/***/ }), |
| 72 |
|
| 73 |
/***/ 466: |
| 74 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 75 |
|
| 76 |
"use strict"; |
| 77 |
/* harmony import */ var _img__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(75711); |
| 78 |
/*! |
| 79 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 80 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 81 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 82 |
*/ /** |
| 83 |
* @module plugins/inline-popup |
| 84 |
*/ |
| 85 |
/* harmony default export */ __webpack_exports__["default"] = ([ |
| 86 |
{ |
| 87 |
name: 'bin', |
| 88 |
tooltip: 'Delete', |
| 89 |
exec: (editor, image)=>{ |
| 90 |
image && editor.s.removeNode(image); |
| 91 |
} |
| 92 |
}, |
| 93 |
_img__WEBPACK_IMPORTED_MODULE_0__.align |
| 94 |
]); |
| 95 |
|
| 96 |
|
| 97 |
/***/ }), |
| 98 |
|
| 99 |
/***/ 670: |
| 100 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 101 |
|
| 102 |
"use strict"; |
| 103 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 104 |
/* harmony export */ openImagePopup: function() { return /* binding */ openImagePopup; } |
| 105 |
/* harmony export */ }); |
| 106 |
/* harmony import */ var _swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(49376); |
| 107 |
/* harmony import */ var jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(17312); |
| 108 |
/* harmony import */ var jodit_core_helpers_size_position__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(23599); |
| 109 |
/* harmony import */ var jodit_core_ui_popup_popup__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(51116); |
| 110 |
/* harmony import */ var jodit_modules_widget_file_selector_file_selector__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(18762); |
| 111 |
/*! |
| 112 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 113 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 114 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 115 |
*/ /** |
| 116 |
* @module plugins/image-properties |
| 117 |
*/ |
| 118 |
|
| 119 |
|
| 120 |
|
| 121 |
|
| 122 |
/** @private */ function openImagePopup(j, dialog, state, button) { |
| 123 |
const popup = new jodit_core_ui_popup_popup__WEBPACK_IMPORTED_MODULE_3__.Popup(dialog); |
| 124 |
const closePopup = ()=>{ |
| 125 |
popup.close(); |
| 126 |
popup.destruct(); |
| 127 |
}; |
| 128 |
popup.setContent((0,jodit_modules_widget_file_selector_file_selector__WEBPACK_IMPORTED_MODULE_4__.FileSelectorWidget)(j, { |
| 129 |
upload: (data)=>{ |
| 130 |
if (data.files && data.files.length) { |
| 131 |
state.values.imageSrc = data.baseurl + data.files[0]; |
| 132 |
} |
| 133 |
closePopup(); |
| 134 |
}, |
| 135 |
filebrowser: (data)=>(0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 136 |
if (data && (0,jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_1__.isArray)(data.files) && data.files.length) { |
| 137 |
state.values.imageSrc = data.files[0]; |
| 138 |
closePopup(); |
| 139 |
} |
| 140 |
})() |
| 141 |
}, state.image, closePopup)).open(()=>(0,jodit_core_helpers_size_position__WEBPACK_IMPORTED_MODULE_2__.position)(button)); |
| 142 |
} |
| 143 |
|
| 144 |
|
| 145 |
/***/ }), |
| 146 |
|
| 147 |
/***/ 928: |
| 148 |
/***/ (function(module) { |
| 149 |
|
| 150 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M621 1280h595v-595zm-45-45l595-595h-595v595zm1152 77v192q0 14-9 23t-23 9h-224v224q0 14-9 23t-23 9h-192q-14 0-23-9t-9-23v-224h-864q-14 0-23-9t-9-23v-864h-224q-14 0-23-9t-9-23v-192q0-14 9-23t23-9h224v-224q0-14 9-23t23-9h192q14 0 23 9t9 23v224h851l246-247q10-9 23-9t23 9q9 10 9 23t-9 23l-247 246v851h224q14 0 23 9t9 23z\"/> </svg>" |
| 151 |
|
| 152 |
/***/ }), |
| 153 |
|
| 154 |
/***/ 1080: |
| 155 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 156 |
|
| 157 |
"use strict"; |
| 158 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 159 |
/* harmony export */ LazyWalker: function() { return /* binding */ LazyWalker; } |
| 160 |
/* harmony export */ }); |
| 161 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 162 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 163 |
/* harmony import */ var jodit_core_decorators_autobind_autobind__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(49574); |
| 164 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(23211); |
| 165 |
/* harmony import */ var jodit_core_event_emitter_eventify__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(60216); |
| 166 |
/*! |
| 167 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 168 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 169 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 170 |
*/ /** |
| 171 |
* @module dom |
| 172 |
*/ |
| 173 |
|
| 174 |
|
| 175 |
|
| 176 |
|
| 177 |
class LazyWalker extends jodit_core_event_emitter_eventify__WEBPACK_IMPORTED_MODULE_4__.Eventify { |
| 178 |
setWork(root) { |
| 179 |
if (this.isWorked) { |
| 180 |
this.break(); |
| 181 |
} |
| 182 |
this.workNodes = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.eachGen(root, !this.options.reverse); |
| 183 |
this.isFinished = false; |
| 184 |
this._requestStarting(); |
| 185 |
return this; |
| 186 |
} |
| 187 |
_requestStarting() { |
| 188 |
this.__schedulerController = new AbortController(); |
| 189 |
this.async.schedulerPostTask(this.__workPerform, { |
| 190 |
delay: this.options.timeout, |
| 191 |
signal: this.__schedulerController.signal |
| 192 |
}).catch(()=>null); |
| 193 |
} |
| 194 |
break(reason) { |
| 195 |
if (this.isWorked) { |
| 196 |
this.stop(); |
| 197 |
this.emit('break', reason); |
| 198 |
} |
| 199 |
} |
| 200 |
end() { |
| 201 |
if (this.isWorked) { |
| 202 |
this.stop(); |
| 203 |
this.emit('end', this.hadAffect); |
| 204 |
this.hadAffect = false; |
| 205 |
} |
| 206 |
} |
| 207 |
stop() { |
| 208 |
this.isWorked = false; |
| 209 |
this.isFinished = true; |
| 210 |
this.workNodes = null; |
| 211 |
this.async.cancelIdleCallback(this.idleId); |
| 212 |
} |
| 213 |
destruct() { |
| 214 |
super.destruct(); |
| 215 |
this.stop(); |
| 216 |
} |
| 217 |
__workPerform() { |
| 218 |
if (this.workNodes) { |
| 219 |
var _this_options_timeoutChunkSize; |
| 220 |
this.isWorked = true; |
| 221 |
let count = 0; |
| 222 |
const chunkSize = (_this_options_timeoutChunkSize = this.options.timeoutChunkSize) !== null && _this_options_timeoutChunkSize !== void 0 ? _this_options_timeoutChunkSize : 50; |
| 223 |
while(!this.isFinished && count <= chunkSize){ |
| 224 |
const item = this.workNodes.next(); |
| 225 |
count += 1; |
| 226 |
if (this.visitNode(item.value)) { |
| 227 |
this.hadAffect = true; |
| 228 |
} |
| 229 |
if (item.done) { |
| 230 |
this.end(); |
| 231 |
return; |
| 232 |
} |
| 233 |
} |
| 234 |
} else { |
| 235 |
this.end(); |
| 236 |
} |
| 237 |
if (!this.isFinished) { |
| 238 |
this._requestStarting(); |
| 239 |
} |
| 240 |
} |
| 241 |
visitNode(nodeElm) { |
| 242 |
var _this_emit; |
| 243 |
if (!nodeElm || this.options.whatToShow !== undefined && nodeElm.nodeType !== this.options.whatToShow) { |
| 244 |
return false; |
| 245 |
} |
| 246 |
return (_this_emit = this.emit('visit', nodeElm)) !== null && _this_emit !== void 0 ? _this_emit : false; |
| 247 |
} |
| 248 |
constructor(async, options = {}){ |
| 249 |
super(), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "async", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "options", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "workNodes", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "hadAffect", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "isWorked", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "isFinished", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "idleId", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__schedulerController", void 0), this.async = async, this.options = options, this.workNodes = null, this.hadAffect = false, this.isWorked = false, this.isFinished = false, this.idleId = 0, this.__schedulerController = null; |
| 250 |
} |
| 251 |
} |
| 252 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 253 |
jodit_core_decorators_autobind_autobind__WEBPACK_IMPORTED_MODULE_2__.autobind |
| 254 |
], LazyWalker.prototype, "__workPerform", null); |
| 255 |
|
| 256 |
|
| 257 |
/***/ }), |
| 258 |
|
| 259 |
/***/ 1277: |
| 260 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 261 |
|
| 262 |
"use strict"; |
| 263 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 264 |
/* harmony export */ cleanFromWord: function() { return /* binding */ cleanFromWord; } |
| 265 |
/* harmony export */ }); |
| 266 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 267 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(23211); |
| 268 |
/* harmony import */ var jodit_core_helpers_array_to_array__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(88475); |
| 269 |
/* harmony import */ var jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(4040); |
| 270 |
/*! |
| 271 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 272 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 273 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 274 |
*/ /** |
| 275 |
* @module helpers/html |
| 276 |
*/ |
| 277 |
|
| 278 |
|
| 279 |
|
| 280 |
/** |
| 281 |
* The method automatically cleans up content from Microsoft Word and other HTML sources to ensure clean, compliant |
| 282 |
* content that matches the look and feel of the site. |
| 283 |
*/ function cleanFromWord(html) { |
| 284 |
if (html.indexOf('<html ') !== -1) { |
| 285 |
html = html.substring(html.indexOf('<html '), html.length); |
| 286 |
html = html.substring(0, html.lastIndexOf('</html>') + '</html>'.length); |
| 287 |
} |
| 288 |
let convertedString = ''; |
| 289 |
try { |
| 290 |
const div = jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.globalDocument.createElement('div'); |
| 291 |
div.innerHTML = html; |
| 292 |
const marks = []; |
| 293 |
if (div.firstChild) { |
| 294 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.each(div, (node)=>{ |
| 295 |
if (!node) { |
| 296 |
return; |
| 297 |
} |
| 298 |
switch(node.nodeType){ |
| 299 |
case Node.ELEMENT_NODE: |
| 300 |
switch(node.nodeName){ |
| 301 |
case 'STYLE': |
| 302 |
case 'LINK': |
| 303 |
case 'META': |
| 304 |
marks.push(node); |
| 305 |
break; |
| 306 |
case 'W:SDT': |
| 307 |
case 'W:SDTPR': |
| 308 |
case 'FONT': |
| 309 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.unwrap(node); |
| 310 |
break; |
| 311 |
default: |
| 312 |
(0,jodit_core_helpers_array_to_array__WEBPACK_IMPORTED_MODULE_2__.toArray)(node.attributes).forEach((attr)=>{ |
| 313 |
if ([ |
| 314 |
'src', |
| 315 |
'href', |
| 316 |
'rel', |
| 317 |
'content' |
| 318 |
].indexOf(attr.name.toLowerCase()) === -1) { |
| 319 |
node.removeAttribute(attr.name); |
| 320 |
} |
| 321 |
}); |
| 322 |
} |
| 323 |
break; |
| 324 |
case Node.TEXT_NODE: |
| 325 |
break; |
| 326 |
default: |
| 327 |
marks.push(node); |
| 328 |
} |
| 329 |
}); |
| 330 |
} |
| 331 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.safeRemove.apply(null, marks); |
| 332 |
convertedString = div.innerHTML; |
| 333 |
} catch (e) {} |
| 334 |
if (convertedString) { |
| 335 |
html = convertedString; |
| 336 |
} |
| 337 |
html = html.split(/(\n)/).filter(jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_3__.trim).join('\n'); |
| 338 |
return html.replace(/<(\/)?(html|colgroup|col|o:p)[^>]*>/g, '').replace(/<!--[^>]*>/g, ''); |
| 339 |
} |
| 340 |
|
| 341 |
|
| 342 |
/***/ }), |
| 343 |
|
| 344 |
/***/ 1305: |
| 345 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 346 |
|
| 347 |
"use strict"; |
| 348 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 349 |
/* harmony export */ deleteFile: function() { return /* binding */ deleteFile; } |
| 350 |
/* harmony export */ }); |
| 351 |
/*! |
| 352 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 353 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 354 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 355 |
*/ /** |
| 356 |
* @module modules/file-browser |
| 357 |
*/ /** |
| 358 |
* Removes a file from the server |
| 359 |
* @private |
| 360 |
*/ function deleteFile(fb, name, source) { |
| 361 |
return fb.dataProvider.fileRemove(fb.state.currentPath, name, source).then((message)=>{ |
| 362 |
fb.status(message || fb.i18n('File "%s" was deleted', name), true); |
| 363 |
}).catch(fb.status); |
| 364 |
} |
| 365 |
|
| 366 |
|
| 367 |
/***/ }), |
| 368 |
|
| 369 |
/***/ 1488: |
| 370 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 371 |
|
| 372 |
"use strict"; |
| 373 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 374 |
/* harmony export */ loadItems: function() { return /* binding */ loadItems; } |
| 375 |
/* harmony export */ }); |
| 376 |
/*! |
| 377 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 378 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 379 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 380 |
*/ /** |
| 381 |
* @module modules/file-browser |
| 382 |
*/ /** |
| 383 |
* Loads a list of files and adds them to the state |
| 384 |
* @private |
| 385 |
*/ function loadItems(fb) { |
| 386 |
fb.files.setMod('active', true); |
| 387 |
fb.files.setMod('loading', true); |
| 388 |
return fb.dataProvider.items(fb.state.currentPath, fb.state.currentSource, { |
| 389 |
sortBy: fb.state.sortBy, |
| 390 |
onlyImages: fb.state.onlyImages, |
| 391 |
filterWord: fb.state.filterWord |
| 392 |
}).then((resp)=>{ |
| 393 |
if (resp) { |
| 394 |
fb.state.elements = resp; |
| 395 |
fb.state.activeElements = []; |
| 396 |
} |
| 397 |
}).catch(fb.status).finally(()=>fb.files.setMod('loading', false)); |
| 398 |
} |
| 399 |
|
| 400 |
|
| 401 |
/***/ }), |
| 402 |
|
| 403 |
/***/ 1496: |
| 404 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 405 |
|
| 406 |
"use strict"; |
| 407 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 408 |
/* harmony export */ EventEmitter: function() { return /* reexport safe */ _event_emitter__WEBPACK_IMPORTED_MODULE_0__.EventEmitter; }, |
| 409 |
/* harmony export */ EventHandlersStore: function() { return /* reexport safe */ _store__WEBPACK_IMPORTED_MODULE_3__.EventHandlersStore; }, |
| 410 |
/* harmony export */ Eventify: function() { return /* reexport safe */ _eventify__WEBPACK_IMPORTED_MODULE_1__.Eventify; }, |
| 411 |
/* harmony export */ defaultNameSpace: function() { return /* reexport safe */ _store__WEBPACK_IMPORTED_MODULE_3__.defaultNameSpace; }, |
| 412 |
/* harmony export */ observable: function() { return /* reexport safe */ _observable__WEBPACK_IMPORTED_MODULE_2__.observable; } |
| 413 |
/* harmony export */ }); |
| 414 |
/* harmony import */ var _event_emitter__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(93747); |
| 415 |
/* harmony import */ var _eventify__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(60216); |
| 416 |
/* harmony import */ var _observable__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(70535); |
| 417 |
/* harmony import */ var _store__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(18869); |
| 418 |
/*! |
| 419 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 420 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 421 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 422 |
*/ /** |
| 423 |
* @module event-emitter |
| 424 |
*/ |
| 425 |
|
| 426 |
|
| 427 |
|
| 428 |
|
| 429 |
|
| 430 |
/***/ }), |
| 431 |
|
| 432 |
/***/ 2222: |
| 433 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 434 |
|
| 435 |
"use strict"; |
| 436 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 437 |
/* harmony export */ ViewWithToolbar: function() { return /* binding */ ViewWithToolbar; } |
| 438 |
/* harmony export */ }); |
| 439 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 440 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 441 |
/* harmony import */ var jodit_core_component_statuses__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(69364); |
| 442 |
/* harmony import */ var jodit_core_decorators_autobind_autobind__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(49574); |
| 443 |
/* harmony import */ var jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(68616); |
| 444 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(23211); |
| 445 |
/* harmony import */ var jodit_core_helpers_array__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(45664); |
| 446 |
/* harmony import */ var jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(85932); |
| 447 |
/* harmony import */ var jodit_core_helpers_utils_selector__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(28723); |
| 448 |
/* harmony import */ var jodit_core_ui__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(4099); |
| 449 |
/* harmony import */ var jodit_core_ui_helpers_buttons__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(2496); |
| 450 |
/* harmony import */ var jodit_core_view_view__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(35099); |
| 451 |
/* harmony import */ var jodit_modules_toolbar_factory__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(4274); |
| 452 |
/*! |
| 453 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 454 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 455 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 456 |
*/ /** |
| 457 |
* @module view |
| 458 |
*/ |
| 459 |
|
| 460 |
|
| 461 |
|
| 462 |
|
| 463 |
|
| 464 |
|
| 465 |
|
| 466 |
|
| 467 |
|
| 468 |
|
| 469 |
|
| 470 |
|
| 471 |
|
| 472 |
class ViewWithToolbar extends jodit_core_view_view__WEBPACK_IMPORTED_MODULE_11__.View { |
| 473 |
/** |
| 474 |
* Container for toolbar |
| 475 |
*/ get toolbarContainer() { |
| 476 |
if (!this.o.fullsize && ((0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_7__.isString)(this.o.toolbar) || jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_5__.Dom.isHTMLElement(this.o.toolbar))) { |
| 477 |
return (0,jodit_core_helpers_utils_selector__WEBPACK_IMPORTED_MODULE_8__.resolveElement)(this.o.toolbar, this.o.shadowRoot || this.od); |
| 478 |
} |
| 479 |
this.o.toolbar && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_5__.Dom.appendChildFirst(this.container, this.__defaultToolbarContainer); |
| 480 |
return this.__defaultToolbarContainer; |
| 481 |
} |
| 482 |
/** |
| 483 |
* Change panel container |
| 484 |
*/ setPanel(element) { |
| 485 |
this.o.toolbar = element; |
| 486 |
this.buildToolbar(); |
| 487 |
} |
| 488 |
/** |
| 489 |
* Helper for appended toolbar in its place |
| 490 |
*/ buildToolbar() { |
| 491 |
var _this_toolbar; |
| 492 |
if (!this.o.toolbar) { |
| 493 |
return; |
| 494 |
} |
| 495 |
const buttons = this.o.buttons ? (0,jodit_core_helpers_array__WEBPACK_IMPORTED_MODULE_6__.splitArray)(this.o.buttons) : []; |
| 496 |
(_this_toolbar = this.toolbar) === null || _this_toolbar === void 0 ? void 0 : _this_toolbar.setRemoveButtons(this.o.removeButtons).build(buttons.concat(this.o.extraButtons || [])).appendTo(this.toolbarContainer); |
| 497 |
} |
| 498 |
getRegisteredButtonGroups() { |
| 499 |
return this.groupToButtons; |
| 500 |
} |
| 501 |
/** |
| 502 |
* Register button for a group |
| 503 |
*/ registerButton(btn) { |
| 504 |
var _btn_group; |
| 505 |
this.registeredButtons.add(btn); |
| 506 |
const group = (_btn_group = btn.group) !== null && _btn_group !== void 0 ? _btn_group : 'other'; |
| 507 |
if (!this.groupToButtons[group]) { |
| 508 |
this.groupToButtons[group] = []; |
| 509 |
} |
| 510 |
if (btn.position != null) { |
| 511 |
this.groupToButtons[group][btn.position] = btn.name; |
| 512 |
} else { |
| 513 |
this.groupToButtons[group].push(btn.name); |
| 514 |
} |
| 515 |
return this; |
| 516 |
} |
| 517 |
/** |
| 518 |
* Remove button from a group |
| 519 |
*/ unregisterButton(btn) { |
| 520 |
var _btn_group; |
| 521 |
this.registeredButtons.delete(btn); |
| 522 |
const groupName = (_btn_group = btn.group) !== null && _btn_group !== void 0 ? _btn_group : 'other', group = this.groupToButtons[groupName]; |
| 523 |
if (group) { |
| 524 |
const index = group.indexOf(btn.name); |
| 525 |
if (index !== -1) { |
| 526 |
group.splice(index, 1); |
| 527 |
} |
| 528 |
if (group.length === 0) { |
| 529 |
delete this.groupToButtons[groupName]; |
| 530 |
} |
| 531 |
} |
| 532 |
return this; |
| 533 |
} |
| 534 |
/** |
| 535 |
* Prepare toolbar items and append buttons in groups |
| 536 |
*/ beforeToolbarBuild(items) { |
| 537 |
if (Object.keys(this.groupToButtons).length) { |
| 538 |
return items.map((item)=>{ |
| 539 |
if ((0,jodit_core_ui_helpers_buttons__WEBPACK_IMPORTED_MODULE_10__.isButtonGroup)(item) && item.group && this.groupToButtons[item.group]) { |
| 540 |
return { |
| 541 |
group: item.group, |
| 542 |
buttons: [ |
| 543 |
...item.buttons, |
| 544 |
...this.groupToButtons[item.group] |
| 545 |
] |
| 546 |
}; |
| 547 |
} |
| 548 |
return item; |
| 549 |
}); |
| 550 |
} |
| 551 |
} |
| 552 |
destruct() { |
| 553 |
if (this.isDestructed) { |
| 554 |
return; |
| 555 |
} |
| 556 |
this.setStatus(jodit_core_component_statuses__WEBPACK_IMPORTED_MODULE_2__.STATUSES.beforeDestruct); |
| 557 |
this.e.off('beforeToolbarBuild', this.beforeToolbarBuild); |
| 558 |
this.__tooltip.destruct(); |
| 559 |
this.toolbar.destruct(); |
| 560 |
// @ts-ignore After destruct, we are not responsible for anything |
| 561 |
this.toolbar = undefined; |
| 562 |
super.destruct(); |
| 563 |
} |
| 564 |
/** @override **/ constructor(options, isJodit = false){ |
| 565 |
super(options, isJodit), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "toolbar", (0,jodit_modules_toolbar_factory__WEBPACK_IMPORTED_MODULE_12__.makeCollection)(this)), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__defaultToolbarContainer", this.c.div('jodit-toolbar__box')), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "registeredButtons", new Set()), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "groupToButtons", {}), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "isJodit", false), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__tooltip", new jodit_core_ui__WEBPACK_IMPORTED_MODULE_9__.UITooltip(this)); |
| 566 |
this.isJodit = isJodit; |
| 567 |
this.e.on('beforeToolbarBuild', this.beforeToolbarBuild); |
| 568 |
} |
| 569 |
} |
| 570 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 571 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_4__.watch)(':rebuildToolbar') |
| 572 |
], ViewWithToolbar.prototype, "buildToolbar", null); |
| 573 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 574 |
jodit_core_decorators_autobind_autobind__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 575 |
], ViewWithToolbar.prototype, "beforeToolbarBuild", null); |
| 576 |
|
| 577 |
|
| 578 |
/***/ }), |
| 579 |
|
| 580 |
/***/ 2409: |
| 581 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 582 |
|
| 583 |
"use strict"; |
| 584 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 585 |
/* harmony export */ checkRemoveEmptyParent: function() { return /* binding */ checkRemoveEmptyParent; } |
| 586 |
/* harmony export */ }); |
| 587 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 588 |
/* harmony import */ var jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(27795); |
| 589 |
/* harmony import */ var _check_join_two_lists__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(80951); |
| 590 |
/*! |
| 591 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 592 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 593 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 594 |
*/ /** |
| 595 |
* @module plugins/backspace |
| 596 |
*/ |
| 597 |
|
| 598 |
|
| 599 |
/** |
| 600 |
* Check if the current empty item can be removed |
| 601 |
* |
| 602 |
* @example |
| 603 |
* ```html |
| 604 |
* <p>first stop</p><p>|<br></p> |
| 605 |
* ``` |
| 606 |
* result |
| 607 |
* ```html |
| 608 |
* <p>first stop|</p> |
| 609 |
* ``` |
| 610 |
* |
| 611 |
* @private |
| 612 |
*/ function checkRemoveEmptyParent(jodit, fakeNode, backspace) { |
| 613 |
let found = false; |
| 614 |
const { setCursorBefore, setCursorIn } = jodit.s; |
| 615 |
let prn = jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.closest(fakeNode, jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isElement, jodit.editor); |
| 616 |
if (!prn || !jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isEmpty(prn)) { |
| 617 |
return false; |
| 618 |
} |
| 619 |
const neighbor = jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.findNotEmptyNeighbor(fakeNode, backspace, jodit.editor); |
| 620 |
do { |
| 621 |
if (prn && jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isEmpty(prn) && !jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isCell(prn)) { |
| 622 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.after(prn, fakeNode); |
| 623 |
const tmp = jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.closest(prn, (n)=>jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isElement(n) && n !== prn, jodit.editor); |
| 624 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.safeRemove(prn); |
| 625 |
found = true; |
| 626 |
prn = tmp; |
| 627 |
} else { |
| 628 |
break; |
| 629 |
} |
| 630 |
}while (prn) |
| 631 |
if (found && (0,_check_join_two_lists__WEBPACK_IMPORTED_MODULE_2__.checkJoinTwoLists)(jodit, fakeNode, backspace)) { |
| 632 |
return true; |
| 633 |
} |
| 634 |
if (neighbor && !jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isText(neighbor) && !jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isTag(neighbor, jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INSEPARABLE_TAGS)) { |
| 635 |
setCursorIn(neighbor, !backspace); |
| 636 |
} else { |
| 637 |
setCursorBefore(fakeNode); |
| 638 |
} |
| 639 |
return found; |
| 640 |
} |
| 641 |
|
| 642 |
|
| 643 |
/***/ }), |
| 644 |
|
| 645 |
/***/ 2496: |
| 646 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 647 |
|
| 648 |
"use strict"; |
| 649 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 650 |
/* harmony export */ flatButtonsSet: function() { return /* binding */ flatButtonsSet; }, |
| 651 |
/* harmony export */ isButtonGroup: function() { return /* binding */ isButtonGroup; } |
| 652 |
/* harmony export */ }); |
| 653 |
/* harmony import */ var jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(17312); |
| 654 |
/*! |
| 655 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 656 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 657 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 658 |
*/ /** |
| 659 |
* @module ui |
| 660 |
*/ |
| 661 |
/** |
| 662 |
* @private |
| 663 |
*/ const isButtonGroup = (item)=>{ |
| 664 |
return (0,jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_0__.isArray)(item.buttons); |
| 665 |
}; |
| 666 |
/** |
| 667 |
* @private |
| 668 |
*/ function flatButtonsSet(buttons, jodit) { |
| 669 |
const groups = jodit.getRegisteredButtonGroups(); |
| 670 |
return new Set(buttons.reduce((acc, item)=>{ |
| 671 |
if (isButtonGroup(item)) { |
| 672 |
var _groups_item_group; |
| 673 |
acc = acc.concat([ |
| 674 |
...item.buttons, |
| 675 |
...(_groups_item_group = groups[item.group]) !== null && _groups_item_group !== void 0 ? _groups_item_group : [] |
| 676 |
]); |
| 677 |
} else { |
| 678 |
acc.push(item); |
| 679 |
} |
| 680 |
return acc; |
| 681 |
}, [])); |
| 682 |
} |
| 683 |
|
| 684 |
|
| 685 |
/***/ }), |
| 686 |
|
| 687 |
/***/ 2602: |
| 688 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 689 |
|
| 690 |
"use strict"; |
| 691 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 692 |
/* harmony export */ UICheckbox: function() { return /* reexport safe */ _checkbox_checkbox__WEBPACK_IMPORTED_MODULE_1__.UICheckbox; }, |
| 693 |
/* harmony export */ UIFileInput: function() { return /* reexport safe */ _file_file__WEBPACK_IMPORTED_MODULE_2__.UIFileInput; }, |
| 694 |
/* harmony export */ UIInput: function() { return /* reexport safe */ _input_input__WEBPACK_IMPORTED_MODULE_3__.UIInput; }, |
| 695 |
/* harmony export */ UISelect: function() { return /* reexport safe */ _select_select__WEBPACK_IMPORTED_MODULE_4__.UISelect; }, |
| 696 |
/* harmony export */ UITextArea: function() { return /* reexport safe */ _area_area__WEBPACK_IMPORTED_MODULE_0__.UITextArea; } |
| 697 |
/* harmony export */ }); |
| 698 |
/* harmony import */ var _area_area__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(87329); |
| 699 |
/* harmony import */ var _checkbox_checkbox__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(24641); |
| 700 |
/* harmony import */ var _file_file__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(75587); |
| 701 |
/* harmony import */ var _input_input__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(65273); |
| 702 |
/* harmony import */ var _select_select__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(49999); |
| 703 |
/*! |
| 704 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 705 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 706 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 707 |
*/ /** |
| 708 |
* @module ui/form |
| 709 |
*/ |
| 710 |
|
| 711 |
|
| 712 |
|
| 713 |
|
| 714 |
|
| 715 |
|
| 716 |
/***/ }), |
| 717 |
|
| 718 |
/***/ 2756: |
| 719 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 720 |
|
| 721 |
"use strict"; |
| 722 |
/* unused harmony export selectCells */ |
| 723 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 724 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 725 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(81937); |
| 726 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(84839); |
| 727 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(23211); |
| 728 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(28077); |
| 729 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(65946); |
| 730 |
/* harmony import */ var jodit_core_plugin__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(91206); |
| 731 |
/* harmony import */ var jodit_modules_table_table__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(98803); |
| 732 |
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(69070); |
| 733 |
/*! |
| 734 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 735 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 736 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 737 |
*/ /** |
| 738 |
* [[include:plugins/select-cells/README.md]] |
| 739 |
* @packageDocumentation |
| 740 |
* @module plugins/select-cells |
| 741 |
*/ |
| 742 |
|
| 743 |
|
| 744 |
|
| 745 |
|
| 746 |
|
| 747 |
|
| 748 |
|
| 749 |
|
| 750 |
|
| 751 |
const key = 'table_processor_observer'; |
| 752 |
const MOUSE_MOVE_LABEL = 'onMoveTableSelectCell'; |
| 753 |
class selectCells extends jodit_core_plugin__WEBPACK_IMPORTED_MODULE_7__.Plugin { |
| 754 |
/** |
| 755 |
* Shortcut for Jodit.modules.Table |
| 756 |
*/ get __tableModule() { |
| 757 |
return this.j.getInstance(jodit_modules_table_table__WEBPACK_IMPORTED_MODULE_8__.Table, this.j.o); |
| 758 |
} |
| 759 |
afterInit(jodit) { |
| 760 |
if (!jodit.o.tableAllowCellSelection) { |
| 761 |
return; |
| 762 |
} |
| 763 |
jodit.e.on('keydown.select-cells', (event)=>{ |
| 764 |
if (event.key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.KEY_TAB) { |
| 765 |
this.unselectCells(); |
| 766 |
} |
| 767 |
}).on('beforeCommand.select-cells', this.onExecCommand).on('afterCommand.select-cells', this.onAfterCommand)// see `plugins/select.ts` |
| 768 |
.on([ |
| 769 |
'clickEditor', |
| 770 |
'mousedownTd', |
| 771 |
'mousedownTh', |
| 772 |
'touchstartTd', |
| 773 |
'touchstartTh' |
| 774 |
].map((e)=>e + '.select-cells').join(' '), this.onStartSelection)// For `clickEditor` correct working. Because `mousedown` on first cell |
| 775 |
// and mouseup on another cell call `click` only for `TR` element. |
| 776 |
.on('clickTr clickTbody', ()=>{ |
| 777 |
const cellsCount = this.__tableModule.getAllSelectedCells().length; |
| 778 |
if (cellsCount) { |
| 779 |
if (cellsCount > 1) { |
| 780 |
var _this_j_s_sel; |
| 781 |
(_this_j_s_sel = this.j.s.sel) === null || _this_j_s_sel === void 0 ? void 0 : _this_j_s_sel.removeAllRanges(); |
| 782 |
} |
| 783 |
return false; |
| 784 |
} |
| 785 |
}); |
| 786 |
} |
| 787 |
/** |
| 788 |
* Mouse click inside the table |
| 789 |
*/ onStartSelection(cell) { |
| 790 |
if (this.j.o.readonly) { |
| 791 |
return; |
| 792 |
} |
| 793 |
this.unselectCells(); |
| 794 |
if (cell === this.j.editor) { |
| 795 |
return; |
| 796 |
} |
| 797 |
const table = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.closest(cell, 'table', this.j.editor); |
| 798 |
if (!cell || !table) { |
| 799 |
return; |
| 800 |
} |
| 801 |
if (!cell.firstChild) { |
| 802 |
cell.appendChild(this.j.createInside.element('br')); |
| 803 |
} |
| 804 |
this.__isSelectionMode = true; |
| 805 |
this.__selectedCell = cell; |
| 806 |
this.__tableModule.addSelection(cell); |
| 807 |
this.j.e.on(table, 'mousemove.select-cells touchmove.select-cells', // Don't use decorator because need clear label on mouseup |
| 808 |
this.j.async.throttle(this.__onMove.bind(this, table), { |
| 809 |
label: MOUSE_MOVE_LABEL, |
| 810 |
timeout: this.j.defaultTimeout / 2 |
| 811 |
})).on(table, 'mouseup.select-cells touchend.select-cells', this.__onStopSelection.bind(this, table)); |
| 812 |
return false; |
| 813 |
} |
| 814 |
onOutsideClick() { |
| 815 |
this.__selectedCell = null; |
| 816 |
this.__onRemoveSelection(); |
| 817 |
} |
| 818 |
onChange() { |
| 819 |
if (!this.j.isLocked && !this.__isSelectionMode) { |
| 820 |
this.__onRemoveSelection(); |
| 821 |
} |
| 822 |
} |
| 823 |
/** |
| 824 |
* Mouse move inside the table |
| 825 |
*/ __onMove(table, e) { |
| 826 |
if (this.j.o.readonly && !this.j.isLocked) { |
| 827 |
return; |
| 828 |
} |
| 829 |
if (this.j.isLockedNotBy(key)) { |
| 830 |
return; |
| 831 |
} |
| 832 |
const node = this.j.ed.elementFromPoint(e.clientX, e.clientY); |
| 833 |
if (!node) { |
| 834 |
return; |
| 835 |
} |
| 836 |
const cell = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.closest(node, [ |
| 837 |
'td', |
| 838 |
'th' |
| 839 |
], table); |
| 840 |
if (!cell || !this.__selectedCell) { |
| 841 |
return; |
| 842 |
} |
| 843 |
if (cell !== this.__selectedCell) { |
| 844 |
this.j.lock(key); |
| 845 |
} |
| 846 |
this.unselectCells(); |
| 847 |
const bound = this.__tableModule.getSelectedBound(table, [ |
| 848 |
cell, |
| 849 |
this.__selectedCell |
| 850 |
]), box = this.__tableModule.formalMatrix(table); |
| 851 |
for(let i = bound[0][0]; i <= bound[1][0]; i += 1){ |
| 852 |
for(let j = bound[0][1]; j <= bound[1][1]; j += 1){ |
| 853 |
this.__tableModule.addSelection(box[i][j]); |
| 854 |
} |
| 855 |
} |
| 856 |
const cellsCount = this.__tableModule.getAllSelectedCells().length; |
| 857 |
if (cellsCount > 1) { |
| 858 |
var _this_j_s_sel; |
| 859 |
(_this_j_s_sel = this.j.s.sel) === null || _this_j_s_sel === void 0 ? void 0 : _this_j_s_sel.removeAllRanges(); |
| 860 |
} |
| 861 |
this.j.e.fire('hidePopup'); |
| 862 |
e.stopPropagation(); |
| 863 |
// Hack for FireFox for force redraw selection |
| 864 |
(()=>{ |
| 865 |
const n = this.j.createInside.fromHTML('<div style="color:rgba(0,0,0,0.01);width:0;height:0"> </div>'); |
| 866 |
cell.appendChild(n); |
| 867 |
this.j.async.setTimeout(()=>{ |
| 868 |
var _n_parentNode; |
| 869 |
(_n_parentNode = n.parentNode) === null || _n_parentNode === void 0 ? void 0 : _n_parentNode.removeChild(n); |
| 870 |
}, this.j.defaultTimeout / 5); |
| 871 |
})(); |
| 872 |
} |
| 873 |
/** |
| 874 |
* On click in outside - remove selection |
| 875 |
*/ __onRemoveSelection(e) { |
| 876 |
var _e_buffer; |
| 877 |
if (!(e === null || e === void 0 ? void 0 : (_e_buffer = e.buffer) === null || _e_buffer === void 0 ? void 0 : _e_buffer.actionTrigger) && !this.__selectedCell && this.__tableModule.getAllSelectedCells().length) { |
| 878 |
this.j.unlock(); |
| 879 |
this.unselectCells(); |
| 880 |
this.j.e.fire('hidePopup', 'cells'); |
| 881 |
return; |
| 882 |
} |
| 883 |
this.__isSelectionMode = false; |
| 884 |
this.__selectedCell = null; |
| 885 |
} |
| 886 |
/** |
| 887 |
* Stop a selection process |
| 888 |
*/ __onStopSelection(table, e) { |
| 889 |
if (!this.__selectedCell) { |
| 890 |
return; |
| 891 |
} |
| 892 |
this.__isSelectionMode = false; |
| 893 |
this.j.unlock(); |
| 894 |
const node = this.j.ed.elementFromPoint(e.clientX, e.clientY); |
| 895 |
if (!node) { |
| 896 |
return; |
| 897 |
} |
| 898 |
const cell = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.closest(node, [ |
| 899 |
'td', |
| 900 |
'th' |
| 901 |
], table); |
| 902 |
if (!cell) { |
| 903 |
return; |
| 904 |
} |
| 905 |
const ownTable = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.closest(cell, 'table', table); |
| 906 |
if (ownTable && ownTable !== table) { |
| 907 |
return; // Nested tables |
| 908 |
} |
| 909 |
const bound = this.__tableModule.getSelectedBound(table, [ |
| 910 |
cell, |
| 911 |
this.__selectedCell |
| 912 |
]), box = this.__tableModule.formalMatrix(table); |
| 913 |
const max = box[bound[1][0]][bound[1][1]], min = box[bound[0][0]][bound[0][1]]; |
| 914 |
this.j.e.fire('showPopup', table, ()=>{ |
| 915 |
const minOffset = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.position)(min, this.j), maxOffset = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.position)(max, this.j); |
| 916 |
return { |
| 917 |
left: minOffset.left, |
| 918 |
top: minOffset.top, |
| 919 |
width: maxOffset.left - minOffset.left + maxOffset.width, |
| 920 |
height: maxOffset.top - minOffset.top + maxOffset.height |
| 921 |
}; |
| 922 |
}, 'cells'); |
| 923 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.$$)('table', this.j.editor).forEach((table)=>{ |
| 924 |
this.j.e.off(table, 'mousemove.select-cells touchmove.select-cells mouseup.select-cells touchend.select-cells'); |
| 925 |
}); |
| 926 |
this.j.async.clearTimeout(MOUSE_MOVE_LABEL); |
| 927 |
} |
| 928 |
/** |
| 929 |
* Remove selection for all cells |
| 930 |
*/ unselectCells(currentCell) { |
| 931 |
const module = this.__tableModule; |
| 932 |
const cells = module.getAllSelectedCells(); |
| 933 |
if (cells.length) { |
| 934 |
cells.forEach((cell)=>{ |
| 935 |
if (!currentCell || currentCell !== cell) { |
| 936 |
module.removeSelection(cell); |
| 937 |
} |
| 938 |
}); |
| 939 |
} |
| 940 |
} |
| 941 |
/** |
| 942 |
* Execute custom commands for table |
| 943 |
*/ onExecCommand(command) { |
| 944 |
if (/table(splitv|splitg|merge|empty|bin|binrow|bincolumn|addcolumn|addrow)/.test(command)) { |
| 945 |
command = command.replace('table', ''); |
| 946 |
const cells = this.__tableModule.getAllSelectedCells(); |
| 947 |
if (cells.length) { |
| 948 |
const [cell] = cells; |
| 949 |
if (!cell) { |
| 950 |
return; |
| 951 |
} |
| 952 |
const table = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.closest(cell, 'table', this.j.editor); |
| 953 |
if (!table) { |
| 954 |
return; |
| 955 |
} |
| 956 |
switch(command){ |
| 957 |
case 'splitv': |
| 958 |
this.__tableModule.splitVertical(table); |
| 959 |
break; |
| 960 |
case 'splitg': |
| 961 |
this.__tableModule.splitHorizontal(table); |
| 962 |
break; |
| 963 |
case 'merge': |
| 964 |
this.__tableModule.mergeSelected(table); |
| 965 |
break; |
| 966 |
case 'empty': |
| 967 |
cells.forEach((td)=>jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.detach(td)); |
| 968 |
break; |
| 969 |
case 'bin': |
| 970 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeRemove(table); |
| 971 |
break; |
| 972 |
case 'binrow': |
| 973 |
new Set(cells.map((td)=>td.parentNode)).forEach((row)=>{ |
| 974 |
this.__tableModule.removeRow(table, row.rowIndex); |
| 975 |
}); |
| 976 |
break; |
| 977 |
case 'bincolumn': |
| 978 |
{ |
| 979 |
const columnsSet = new Set(), columns = cells.reduce((acc, td)=>{ |
| 980 |
if (!columnsSet.has(td.cellIndex)) { |
| 981 |
acc.push(td); |
| 982 |
columnsSet.add(td.cellIndex); |
| 983 |
} |
| 984 |
return acc; |
| 985 |
}, []); |
| 986 |
columns.forEach((td)=>{ |
| 987 |
this.__tableModule.removeColumn(table, td.cellIndex); |
| 988 |
}); |
| 989 |
} |
| 990 |
break; |
| 991 |
case 'addcolumnafter': |
| 992 |
case 'addcolumnbefore': |
| 993 |
this.__tableModule.appendColumn(table, cell, command === 'addcolumnafter'); |
| 994 |
break; |
| 995 |
case 'addrowafter': |
| 996 |
case 'addrowbefore': |
| 997 |
this.__tableModule.appendRow(table, cell.parentNode, command === 'addrowafter'); |
| 998 |
break; |
| 999 |
} |
| 1000 |
} |
| 1001 |
return false; |
| 1002 |
} |
| 1003 |
} |
| 1004 |
/** |
| 1005 |
* Add some align after native command |
| 1006 |
*/ onAfterCommand(command) { |
| 1007 |
if (/^justify/.test(command)) { |
| 1008 |
this.__tableModule.getAllSelectedCells().forEach((elm)=>(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.alignElement)(command, elm)); |
| 1009 |
} |
| 1010 |
} |
| 1011 |
/** @override */ beforeDestruct(jodit) { |
| 1012 |
this.__onRemoveSelection(); |
| 1013 |
jodit.e.off('.select-cells'); |
| 1014 |
} |
| 1015 |
constructor(...args){ |
| 1016 |
super(...args), /** |
| 1017 |
* First selected cell |
| 1018 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__selectedCell", null), /** |
| 1019 |
* User is selecting cells now |
| 1020 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__isSelectionMode", false); |
| 1021 |
} |
| 1022 |
} |
| 1023 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(selectCells, "requires", [ |
| 1024 |
'select' |
| 1025 |
]); |
| 1026 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 1027 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 1028 |
], selectCells.prototype, "onStartSelection", null); |
| 1029 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 1030 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.watch)(':outsideClick') |
| 1031 |
], selectCells.prototype, "onOutsideClick", null); |
| 1032 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 1033 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.watch)(':change') |
| 1034 |
], selectCells.prototype, "onChange", null); |
| 1035 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 1036 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 1037 |
], selectCells.prototype, "__onRemoveSelection", null); |
| 1038 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 1039 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 1040 |
], selectCells.prototype, "__onStopSelection", null); |
| 1041 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 1042 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 1043 |
], selectCells.prototype, "onExecCommand", null); |
| 1044 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 1045 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 1046 |
], selectCells.prototype, "onAfterCommand", null); |
| 1047 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_5__.pluginSystem.add('selectCells', selectCells); |
| 1048 |
|
| 1049 |
|
| 1050 |
/***/ }), |
| 1051 |
|
| 1052 |
/***/ 2923: |
| 1053 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 1054 |
|
| 1055 |
"use strict"; |
| 1056 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 1057 |
/* harmony export */ onTabInsideLi: function() { return /* reexport safe */ _on_tab_inside_li__WEBPACK_IMPORTED_MODULE_0__.onTabInsideLi; } |
| 1058 |
/* harmony export */ }); |
| 1059 |
/* harmony import */ var _on_tab_inside_li__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(8837); |
| 1060 |
/*! |
| 1061 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 1062 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 1063 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 1064 |
*/ /** |
| 1065 |
* @module plugins/tab |
| 1066 |
*/ |
| 1067 |
|
| 1068 |
|
| 1069 |
/***/ }), |
| 1070 |
|
| 1071 |
/***/ 2952: |
| 1072 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 1073 |
|
| 1074 |
"use strict"; |
| 1075 |
/* unused harmony export hr */ |
| 1076 |
/* harmony import */ var jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(27795); |
| 1077 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(28077); |
| 1078 |
/* harmony import */ var jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(29434); |
| 1079 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5266); |
| 1080 |
/* harmony import */ var _hr_svg__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(89097); |
| 1081 |
/* harmony import */ var _hr_svg__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_hr_svg__WEBPACK_IMPORTED_MODULE_4__); |
| 1082 |
/*! |
| 1083 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 1084 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 1085 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 1086 |
*/ /** |
| 1087 |
* [[include:plugins/hr/README.md]] |
| 1088 |
* @packageDocumentation |
| 1089 |
* @module plugins/hr |
| 1090 |
*/ |
| 1091 |
|
| 1092 |
|
| 1093 |
|
| 1094 |
|
| 1095 |
jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_2__.Icon.set('hr', (_hr_svg__WEBPACK_IMPORTED_MODULE_4___default())); |
| 1096 |
jodit_config__WEBPACK_IMPORTED_MODULE_3__.Config.prototype.controls.hr = { |
| 1097 |
command: 'insertHorizontalRule', |
| 1098 |
tags: [ |
| 1099 |
'hr' |
| 1100 |
], |
| 1101 |
tooltip: 'Insert Horizontal Line' |
| 1102 |
}; |
| 1103 |
function hr(editor) { |
| 1104 |
editor.registerButton({ |
| 1105 |
name: 'hr', |
| 1106 |
group: 'insert' |
| 1107 |
}); |
| 1108 |
editor.registerCommand('insertHorizontalRule', ()=>{ |
| 1109 |
const elm = editor.createInside.element('hr'); |
| 1110 |
editor.s.insertNode(elm, false, false); |
| 1111 |
const block = jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(elm.parentElement, jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isBlock, editor.editor); |
| 1112 |
if (block && jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isEmpty(block) && block !== editor.editor) { |
| 1113 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.after(block, elm); |
| 1114 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(block); |
| 1115 |
} |
| 1116 |
let p = jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.next(elm, jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isBlock, editor.editor, false); |
| 1117 |
if (!p) { |
| 1118 |
p = editor.createInside.element(editor.o.enter); |
| 1119 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.after(elm, p); |
| 1120 |
} |
| 1121 |
editor.s.setCursorIn(p); |
| 1122 |
return false; |
| 1123 |
}); |
| 1124 |
} |
| 1125 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_1__.pluginSystem.add('hr', hr); |
| 1126 |
|
| 1127 |
|
| 1128 |
/***/ }), |
| 1129 |
|
| 1130 |
/***/ 3050: |
| 1131 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 1132 |
|
| 1133 |
"use strict"; |
| 1134 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 1135 |
/* harmony export */ loadExtras: function() { return /* binding */ loadExtras; }, |
| 1136 |
/* harmony export */ loadStyle: function() { return /* binding */ loadStyle; } |
| 1137 |
/* harmony export */ }); |
| 1138 |
/* harmony import */ var _swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(49376); |
| 1139 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(81937); |
| 1140 |
/* harmony import */ var jodit_core_helpers_string_kebab_case__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(74264); |
| 1141 |
/* harmony import */ var jodit_core_helpers_utils_append_script__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(47760); |
| 1142 |
/* harmony import */ var jodit_core_plugin_helpers_utils__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(86189); |
| 1143 |
/*! |
| 1144 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 1145 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 1146 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 1147 |
*/ /** |
| 1148 |
* @module plugin |
| 1149 |
*/ |
| 1150 |
|
| 1151 |
|
| 1152 |
|
| 1153 |
|
| 1154 |
const styles = new Set(); |
| 1155 |
/** |
| 1156 |
* @private |
| 1157 |
*/ function loadStyle(jodit, pluginName) { |
| 1158 |
return (0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 1159 |
const url = getFullUrl(jodit, pluginName, false); |
| 1160 |
if (styles.has(url)) { |
| 1161 |
return; |
| 1162 |
} |
| 1163 |
styles.add(url); |
| 1164 |
return (0,jodit_core_helpers_utils_append_script__WEBPACK_IMPORTED_MODULE_3__.appendStyleAsync)(jodit, url); |
| 1165 |
})(); |
| 1166 |
} |
| 1167 |
/** |
| 1168 |
* Call full url to the script or style file |
| 1169 |
* @private |
| 1170 |
*/ function getFullUrl(jodit, name, js) { |
| 1171 |
name = (0,jodit_core_helpers_string_kebab_case__WEBPACK_IMPORTED_MODULE_2__.kebabCase)(name); |
| 1172 |
const min = jodit.minified ? '.min' : ''; |
| 1173 |
return jodit.basePath + 'plugins/' + name + '/' + name + min + '.' + (js ? 'js' : 'css'); |
| 1174 |
} |
| 1175 |
/** |
| 1176 |
* @private |
| 1177 |
*/ function loadExtras(items, jodit, extraList, callback) { |
| 1178 |
try { |
| 1179 |
const needLoadExtras = extraList.filter((extra)=>!items.has((0,jodit_core_plugin_helpers_utils__WEBPACK_IMPORTED_MODULE_4__.normalizeName)(extra.name))); |
| 1180 |
if (needLoadExtras.length) { |
| 1181 |
load(jodit, needLoadExtras, callback); |
| 1182 |
} |
| 1183 |
} catch (e) { |
| 1184 |
if (!jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.IS_PROD) { |
| 1185 |
throw e; |
| 1186 |
} |
| 1187 |
} |
| 1188 |
} |
| 1189 |
/** |
| 1190 |
* Download plugins |
| 1191 |
* @private |
| 1192 |
*/ function load(jodit, pluginList, callback) { |
| 1193 |
pluginList.map((extra)=>{ |
| 1194 |
const url = extra.url || getFullUrl(jodit, extra.name, true); |
| 1195 |
return (0,jodit_core_helpers_utils_append_script__WEBPACK_IMPORTED_MODULE_3__.appendScriptAsync)(jodit, url).then(callback).catch(()=>null); |
| 1196 |
}); |
| 1197 |
} |
| 1198 |
|
| 1199 |
|
| 1200 |
/***/ }), |
| 1201 |
|
| 1202 |
/***/ 3213: |
| 1203 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 1204 |
|
| 1205 |
"use strict"; |
| 1206 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 1207 |
/* harmony export */ isSet: function() { return /* binding */ isSet; } |
| 1208 |
/* harmony export */ }); |
| 1209 |
/* harmony import */ var _is_function__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(91565); |
| 1210 |
/*! |
| 1211 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 1212 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 1213 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 1214 |
*/ /** |
| 1215 |
* @module helpers/checker |
| 1216 |
*/ |
| 1217 |
/** |
| 1218 |
* Check if element is set |
| 1219 |
*/ function isSet(elm) { |
| 1220 |
return Boolean(elm) && (0,_is_function__WEBPACK_IMPORTED_MODULE_0__.isFunction)(elm.has) && (0,_is_function__WEBPACK_IMPORTED_MODULE_0__.isFunction)(elm.add) && (0,_is_function__WEBPACK_IMPORTED_MODULE_0__.isFunction)(elm.delete); |
| 1221 |
} |
| 1222 |
|
| 1223 |
|
| 1224 |
/***/ }), |
| 1225 |
|
| 1226 |
/***/ 3244: |
| 1227 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 1228 |
|
| 1229 |
"use strict"; |
| 1230 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 1231 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(65946); |
| 1232 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5266); |
| 1233 |
/* harmony import */ var jodit_modules_toolbar_collection_collection__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(42573); |
| 1234 |
/* harmony import */ var jodit_modules_toolbar_factory__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(4274); |
| 1235 |
/*! |
| 1236 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 1237 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 1238 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 1239 |
*/ /** |
| 1240 |
* @module plugins/mobile |
| 1241 |
*/ |
| 1242 |
|
| 1243 |
|
| 1244 |
|
| 1245 |
|
| 1246 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.mobileTapTimeout = 300; |
| 1247 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.toolbarAdaptive = true; |
| 1248 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.buttonsMD = [ |
| 1249 |
{ |
| 1250 |
group: 'font-style', |
| 1251 |
buttons: [] |
| 1252 |
}, |
| 1253 |
{ |
| 1254 |
group: 'list', |
| 1255 |
buttons: [] |
| 1256 |
}, |
| 1257 |
{ |
| 1258 |
group: 'font', |
| 1259 |
buttons: [] |
| 1260 |
}, |
| 1261 |
'---', |
| 1262 |
{ |
| 1263 |
group: 'media', |
| 1264 |
buttons: [] |
| 1265 |
}, |
| 1266 |
'\n', |
| 1267 |
{ |
| 1268 |
group: 'state', |
| 1269 |
buttons: [] |
| 1270 |
}, |
| 1271 |
{ |
| 1272 |
group: 'insert', |
| 1273 |
buttons: [] |
| 1274 |
}, |
| 1275 |
{ |
| 1276 |
group: 'indent', |
| 1277 |
buttons: [] |
| 1278 |
}, |
| 1279 |
{ |
| 1280 |
group: 'color', |
| 1281 |
buttons: [] |
| 1282 |
}, |
| 1283 |
'---', |
| 1284 |
{ |
| 1285 |
group: 'history', |
| 1286 |
buttons: [] |
| 1287 |
}, |
| 1288 |
{ |
| 1289 |
group: 'other', |
| 1290 |
buttons: [] |
| 1291 |
}, |
| 1292 |
'|', |
| 1293 |
'dots' |
| 1294 |
]; |
| 1295 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.buttonsSM = [ |
| 1296 |
{ |
| 1297 |
group: 'font-style', |
| 1298 |
buttons: [] |
| 1299 |
}, |
| 1300 |
{ |
| 1301 |
group: 'list', |
| 1302 |
buttons: [] |
| 1303 |
}, |
| 1304 |
'---', |
| 1305 |
{ |
| 1306 |
group: 'font', |
| 1307 |
buttons: [] |
| 1308 |
}, |
| 1309 |
'\n', |
| 1310 |
{ |
| 1311 |
group: 'state', |
| 1312 |
buttons: [] |
| 1313 |
}, |
| 1314 |
{ |
| 1315 |
group: 'indent', |
| 1316 |
buttons: [] |
| 1317 |
}, |
| 1318 |
{ |
| 1319 |
group: 'color', |
| 1320 |
buttons: [] |
| 1321 |
}, |
| 1322 |
'---', |
| 1323 |
{ |
| 1324 |
group: 'history', |
| 1325 |
buttons: [] |
| 1326 |
}, |
| 1327 |
'|', |
| 1328 |
'dots' |
| 1329 |
]; |
| 1330 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.buttonsXS = [ |
| 1331 |
{ |
| 1332 |
group: 'font-style', |
| 1333 |
buttons: [] |
| 1334 |
}, |
| 1335 |
{ |
| 1336 |
group: 'list', |
| 1337 |
buttons: [] |
| 1338 |
}, |
| 1339 |
'---', |
| 1340 |
{ |
| 1341 |
group: 'font', |
| 1342 |
buttons: [] |
| 1343 |
}, |
| 1344 |
{ |
| 1345 |
group: 'color', |
| 1346 |
buttons: [] |
| 1347 |
}, |
| 1348 |
'---', |
| 1349 |
'dots' |
| 1350 |
]; |
| 1351 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.controls.dots = { |
| 1352 |
mode: jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.MODE_SOURCE + jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.MODE_WYSIWYG, |
| 1353 |
popup: (editor, current, close, button)=>{ |
| 1354 |
let store = button.control.data; |
| 1355 |
if (store === undefined) { |
| 1356 |
store = { |
| 1357 |
toolbar: (0,jodit_modules_toolbar_factory__WEBPACK_IMPORTED_MODULE_4__.makeCollection)(editor), |
| 1358 |
rebuild: ()=>{ |
| 1359 |
if (button) { |
| 1360 |
const buttons = editor.e.fire('getDiffButtons.mobile', button.closest(jodit_modules_toolbar_collection_collection__WEBPACK_IMPORTED_MODULE_3__.ToolbarCollection)); |
| 1361 |
if (buttons && store) { |
| 1362 |
var _editor_toolbar_firstButton, _editor_toolbar; |
| 1363 |
store.toolbar.build((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__.splitArray)(buttons)); |
| 1364 |
const w = ((_editor_toolbar = editor.toolbar) === null || _editor_toolbar === void 0 ? void 0 : (_editor_toolbar_firstButton = _editor_toolbar.firstButton) === null || _editor_toolbar_firstButton === void 0 ? void 0 : _editor_toolbar_firstButton.container.offsetWidth) || 36; |
| 1365 |
store.toolbar.container.style.width = (w + 4) * 3 + 'px'; |
| 1366 |
} |
| 1367 |
} |
| 1368 |
} |
| 1369 |
}; |
| 1370 |
button.control.data = store; |
| 1371 |
} |
| 1372 |
store.rebuild(); |
| 1373 |
return store.toolbar; |
| 1374 |
}, |
| 1375 |
tooltip: 'Show all' |
| 1376 |
}; |
| 1377 |
|
| 1378 |
|
| 1379 |
/***/ }), |
| 1380 |
|
| 1381 |
/***/ 3268: |
| 1382 |
/***/ (function(module) { |
| 1383 |
|
| 1384 |
module.exports["default"] = ["Begin met typen..","Over Jodit","Jodit Editor","Jodit gebruikershandleiding","bevat gedetailleerde informatie voor gebruik.","Voor informatie over de licentie, ga naar onze website:","Volledige versie kopen","Copyright © XDSoft.net - Chupurnov Valeriy. Alle rechten voorbehouden.","Anker","Open in nieuwe tab","Editor in volledig scherm openen","Opmaak verwijderen","Vulkleur of tekstkleur aanpassen","Opnieuw","Ongedaan maken","Vet","Cursief","Geordende list invoegen","Ongeordende lijst invoegen","Centreren","Uitlijnen op volledige breedte","Links uitlijnen","Rechts uitlijnen","Horizontale lijn invoegen","Afbeelding invoegen","Bestand invoegen","Youtube/Vimeo video invoegen","Link toevoegen","Tekstgrootte","Lettertype","Format blok invoegen","Normaal","Koptekst 1","Koptekst 2","Koptekst 3","Koptekst 4","Citaat","Code","Invoegen","Tabel invoegen","Inspringing verkleinen","Inspringing vergroten","Symbool selecteren","Symbool invoegen","Opmaak kopieren","Modus veranderen","Marges","Boven","Rechts","Onder","Links","CSS styles","CSS classes","Uitlijning","Rechts","Gecentreerd","Links","--Leeg--","Src","Titel","Alternatieve tekst","Link","Link in nieuwe tab openen","Afbeelding","Bestand","Geavanceerd","Afbeeldingseigenschappen","Annuleren","OK","Bestandsbrowser","Fout bij het laden van de lijst","Fout bij het laden van de mappenlijst","Weet je het zeker?","Geef de map een naam","Map aanmaken","Type naam","Sleep hier een afbeelding naartoe","Sleep hier een bestand naartoe","of klik","Alternatieve tekst","Uploaden","Bladeren","Achtergrond","Tekst","Boven","Midden","Onder","Kolom invoegen (voor)","Kolom invoegen (na)","Rij invoegen (boven)","Rij invoegen (onder)","Tabel verwijderen","Rij verwijderen","Kolom verwijderen","Cel leegmaken","Tekens: %d","Woorden: %d","Doorstrepen","Onderstrepen","Superscript","Subscript","Selectie knippen","Selecteer alles","Enter","Zoek naar","Vervangen door","Vervangen","Plakken","Kies content om te plakken","Broncode","vet","cursief","kwast","link","ongedaan maken","opnieuw","tabel","afbeelding","gum","paragraaf","lettergrootte","video","lettertype","over","afdrukken","onderstreept","doorgestreept","inspringen","minder inspringen","volledige grootte","kleiner maken","horizontale lijn","lijst","genummerde lijst","knip","alles selecteren","Embed code","Link openen","Link aanpassen","Niet volgen","link verwijderen","Updaten","Om te bewerken","Recensie"," URL","Bewerken","Horizontaal uitlijnen","Filteren","Sorteren op wijzigingsdatum","Sorteren op naam","Sorteren op grootte","Map toevoegen","Herstellen","Opslaan","Opslaan als ...","Grootte aanpassen","Bijknippen","Breedte","Hoogte","Verhouding behouden","Ja","Nee","Verwijderen","Selecteren","Selecteer: %s","Verticaal uitlijnen","Splitsen","Samenvoegen","Kolom toevoegen","Rij toevoegen","Licentie: %s","Verwijderen","Verticaal splitsen","Horizontaal splitsen","Rand","Deze code lijkt op HTML. Als HTML behouden?","Invoegen als HTML","Origineel behouden","Als tekst invoegen","Als onopgemaakte tekst invoegen","Je kunt alleen je eigen afbeeldingen aanpassen. Deze afbeelding downloaden?","De afbeelding is succesvol geüploadet!","Palette","Er zijn geen bestanden in deze map.","Hernoemen","Voer een nieuwe naam in","Voorvertoning","Download","Plakken van klembord","Uw browser ondersteunt geen directe toegang tot het klembord.","Selectie kopiëren","kopiëren","Border radius","Toon alle","Toepassen","Vul dit veld in","Voer een webadres in","Standaard","Cirkel","Punt","Kwadraat","Zoeken","Vorige Zoeken","Volgende Zoeken","De geplakte tekst is afkomstig van een Microsoft Word/Excel document. Wil je de opmaak behouden of opschonen?","Word-tekst gedetecteerd","Opschonen","Voeg de klassenaam in","Druk op Alt voor aangepaste grootte",null,null,null,"Alles"] |
| 1385 |
|
| 1386 |
/***/ }), |
| 1387 |
|
| 1388 |
/***/ 3294: |
| 1389 |
/***/ (function(module) { |
| 1390 |
|
| 1391 |
/*! |
| 1392 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 1393 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 1394 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 1395 |
*/ module.exports = { |
| 1396 |
symbols: 'symbol' |
| 1397 |
}; |
| 1398 |
|
| 1399 |
|
| 1400 |
/***/ }), |
| 1401 |
|
| 1402 |
/***/ 3347: |
| 1403 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 1404 |
|
| 1405 |
"use strict"; |
| 1406 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 1407 |
/* harmony export */ stringify: function() { return /* binding */ stringify; } |
| 1408 |
/* harmony export */ }); |
| 1409 |
/*! |
| 1410 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 1411 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 1412 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 1413 |
*/ /** |
| 1414 |
* @module helpers/string |
| 1415 |
*/ /** |
| 1416 |
* Safe stringify circular object |
| 1417 |
*/ function stringify(value, options = {}) { |
| 1418 |
if (typeof value !== 'object') { |
| 1419 |
return String(value); |
| 1420 |
} |
| 1421 |
const excludeKeys = new Set(options.excludeKeys); |
| 1422 |
const map = new WeakMap(); |
| 1423 |
const r = (k, v)=>{ |
| 1424 |
if (excludeKeys.has(k)) { |
| 1425 |
return; |
| 1426 |
} |
| 1427 |
if (typeof v === 'object' && v != null) { |
| 1428 |
if (map.get(v)) { |
| 1429 |
return '[refObject]'; |
| 1430 |
} |
| 1431 |
map.set(v, true); |
| 1432 |
} |
| 1433 |
return v; |
| 1434 |
}; |
| 1435 |
return JSON.stringify(value, r, options.prettify); |
| 1436 |
} |
| 1437 |
|
| 1438 |
|
| 1439 |
/***/ }), |
| 1440 |
|
| 1441 |
/***/ 3513: |
| 1442 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 1443 |
|
| 1444 |
"use strict"; |
| 1445 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 1446 |
/* harmony export */ isWindow: function() { return /* binding */ isWindow; } |
| 1447 |
/* harmony export */ }); |
| 1448 |
/*! |
| 1449 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 1450 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 1451 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 1452 |
*/ /** |
| 1453 |
* @module helpers/checker |
| 1454 |
*/ function isWindow(obj) { |
| 1455 |
return obj != null && obj === obj.window; |
| 1456 |
} |
| 1457 |
|
| 1458 |
|
| 1459 |
/***/ }), |
| 1460 |
|
| 1461 |
/***/ 3678: |
| 1462 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 1463 |
|
| 1464 |
"use strict"; |
| 1465 |
/* unused harmony export enter */ |
| 1466 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(31635); |
| 1467 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(81937); |
| 1468 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(84839); |
| 1469 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(23211); |
| 1470 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(28077); |
| 1471 |
/* harmony import */ var jodit_core_helpers_checker_is_boolean__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(22289); |
| 1472 |
/* harmony import */ var jodit_core_plugin_plugin__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(18855); |
| 1473 |
/* harmony import */ var _helpers__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(10918); |
| 1474 |
/*! |
| 1475 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 1476 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 1477 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 1478 |
*/ /** |
| 1479 |
* [[include:plugins/enter/README.md]] |
| 1480 |
* @packageDocumentation |
| 1481 |
* @module plugins/enter |
| 1482 |
*/ |
| 1483 |
|
| 1484 |
|
| 1485 |
|
| 1486 |
|
| 1487 |
|
| 1488 |
|
| 1489 |
|
| 1490 |
|
| 1491 |
/** |
| 1492 |
* One of most important core plugins. It is responsible for all the browsers to have the same effect when the Enter |
| 1493 |
* button is pressed. By default, it should insert the <p> |
| 1494 |
*/ class enter extends jodit_core_plugin_plugin__WEBPACK_IMPORTED_MODULE_6__.Plugin { |
| 1495 |
/** @override */ afterInit(editor) { |
| 1496 |
// use 'enter' option if no set |
| 1497 |
const defaultTag = editor.o.enter.toLowerCase(); |
| 1498 |
const brMode = defaultTag === jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.BR.toLowerCase(); |
| 1499 |
if (!editor.o.enterBlock) { |
| 1500 |
editor.o.enterBlock = brMode ? jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.PARAGRAPH : defaultTag; |
| 1501 |
} |
| 1502 |
editor.registerCommand('enter', (command, value, event = {})=>this.onEnter(event)); |
| 1503 |
} |
| 1504 |
onEnterKeyDown(event) { |
| 1505 |
if (event.key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.KEY_ENTER) { |
| 1506 |
const editor = this.j; |
| 1507 |
const beforeEnter = editor.e.fire('beforeEnter', event); |
| 1508 |
if (beforeEnter !== undefined) { |
| 1509 |
return beforeEnter; |
| 1510 |
} |
| 1511 |
if (!editor.s.isCollapsed()) { |
| 1512 |
editor.execCommand('Delete'); |
| 1513 |
} |
| 1514 |
editor.s.focus(); |
| 1515 |
this.onEnter(event); |
| 1516 |
editor.e.fire('afterEnter', event); |
| 1517 |
editor.synchronizeValues(); // fire change |
| 1518 |
return false; |
| 1519 |
} |
| 1520 |
} |
| 1521 |
onEnter(event) { |
| 1522 |
const { jodit } = this; |
| 1523 |
const fake = jodit.createInside.fake(); |
| 1524 |
try { |
| 1525 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.safeInsertNode(jodit.s.range, fake); |
| 1526 |
(0,_helpers__WEBPACK_IMPORTED_MODULE_7__.moveCursorOutFromSpecialTags)(jodit, fake, [ |
| 1527 |
'a' |
| 1528 |
]); |
| 1529 |
let block = (0,_helpers__WEBPACK_IMPORTED_MODULE_7__.getBlockWrapper)(fake, jodit); |
| 1530 |
const isLi = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.isLeaf(block); |
| 1531 |
// if use <br> defaultTag for break line or when was entered SHIFt key or in <td> or <th> or <blockquote> |
| 1532 |
if ((!isLi || (event === null || event === void 0 ? void 0 : event.shiftKey)) && (0,_helpers__WEBPACK_IMPORTED_MODULE_7__.checkBR)(fake, jodit, event === null || event === void 0 ? void 0 : event.shiftKey)) { |
| 1533 |
return false; |
| 1534 |
} |
| 1535 |
// wrap no wrapped element |
| 1536 |
if (!block && !(0,_helpers__WEBPACK_IMPORTED_MODULE_7__.hasPreviousBlock)(fake, jodit)) { |
| 1537 |
block = (0,_helpers__WEBPACK_IMPORTED_MODULE_7__.wrapText)(fake, jodit); |
| 1538 |
} |
| 1539 |
if (!block) { |
| 1540 |
(0,_helpers__WEBPACK_IMPORTED_MODULE_7__.insertParagraph)(fake, jodit, isLi ? 'li' : jodit.o.enter); |
| 1541 |
return false; |
| 1542 |
} |
| 1543 |
if (!(0,_helpers__WEBPACK_IMPORTED_MODULE_7__.checkUnsplittableBox)(fake, jodit, block)) { |
| 1544 |
return false; |
| 1545 |
} |
| 1546 |
if (isLi && this.__isEmptyListLeaf(block)) { |
| 1547 |
(0,_helpers__WEBPACK_IMPORTED_MODULE_7__.processEmptyLILeaf)(fake, jodit, block); |
| 1548 |
return false; |
| 1549 |
} |
| 1550 |
(0,_helpers__WEBPACK_IMPORTED_MODULE_7__.splitFragment)(fake, jodit, block); |
| 1551 |
} finally{ |
| 1552 |
fake.isConnected && jodit.s.setCursorBefore(fake); |
| 1553 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.safeRemove(fake); |
| 1554 |
} |
| 1555 |
} |
| 1556 |
__isEmptyListLeaf(li) { |
| 1557 |
const result = this.j.e.fire('enterIsEmptyListLeaf', li); |
| 1558 |
return (0,jodit_core_helpers_checker_is_boolean__WEBPACK_IMPORTED_MODULE_5__.isBoolean)(result) ? result : jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.isEmpty(li); |
| 1559 |
} |
| 1560 |
/** @override */ beforeDestruct(editor) { |
| 1561 |
editor.e.off('keydown.enter'); |
| 1562 |
} |
| 1563 |
} |
| 1564 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_0__.__decorate)([ |
| 1565 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.watch)(':keydown.enter') |
| 1566 |
], enter.prototype, "onEnterKeyDown", null); |
| 1567 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_4__.pluginSystem.add('enter', enter); |
| 1568 |
|
| 1569 |
|
| 1570 |
/***/ }), |
| 1571 |
|
| 1572 |
/***/ 3787: |
| 1573 |
/***/ (function(module) { |
| 1574 |
|
| 1575 |
/*! |
| 1576 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 1577 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 1578 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 1579 |
*/ module.exports = { |
| 1580 |
'copy-format': 'Kopírovat formát' |
| 1581 |
}; |
| 1582 |
|
| 1583 |
|
| 1584 |
/***/ }), |
| 1585 |
|
| 1586 |
/***/ 3843: |
| 1587 |
/***/ (function(module) { |
| 1588 |
|
| 1589 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 16 16\"> <path stroke-width=\"0\" d=\"M16 9v-6h-3v-1c0-0.55-0.45-1-1-1h-11c-0.55 0-1 0.45-1 1v3c0 0.55 0.45 1 1 1h11c0.55 0 1-0.45 1-1v-1h2v4h-9v2h-0.5c-0.276 0-0.5 0.224-0.5 0.5v5c0 0.276 0.224 0.5 0.5 0.5h2c0.276 0 0.5-0.224 0.5-0.5v-5c0-0.276-0.224-0.5-0.5-0.5h-0.5v-1h9zM12 3h-11v-1h11v1z\"/> </svg>" |
| 1590 |
|
| 1591 |
/***/ }), |
| 1592 |
|
| 1593 |
/***/ 3856: |
| 1594 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 1595 |
|
| 1596 |
"use strict"; |
| 1597 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 1598 |
/* harmony export */ convertMediaUrlToVideoEmbed: function() { return /* binding */ convertMediaUrlToVideoEmbed; } |
| 1599 |
/* harmony export */ }); |
| 1600 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 1601 |
/* harmony import */ var jodit_core_helpers_checker_is_url__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(91764); |
| 1602 |
/* harmony import */ var _parse_query__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(36310); |
| 1603 |
/*! |
| 1604 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 1605 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 1606 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 1607 |
*/ /** |
| 1608 |
* @module helpers/utils |
| 1609 |
*/ |
| 1610 |
|
| 1611 |
|
| 1612 |
/** |
| 1613 |
* Javascript url pattern converter replace youtube/vimeo url in embed code. |
| 1614 |
*/ const convertMediaUrlToVideoEmbed = (url, { width = 400, height = 345 } = {})=>{ |
| 1615 |
if (!(0,jodit_core_helpers_checker_is_url__WEBPACK_IMPORTED_MODULE_1__.isURL)(url)) { |
| 1616 |
return url; |
| 1617 |
} |
| 1618 |
const parser = jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.globalDocument.createElement('a'); |
| 1619 |
const pattern1 = /(?:http?s?:\/\/)?(?:www\.)?(?:vimeo\.com)\/?(.+)/g; |
| 1620 |
parser.href = url; |
| 1621 |
if (!width) { |
| 1622 |
width = 400; |
| 1623 |
} |
| 1624 |
if (!height) { |
| 1625 |
height = 345; |
| 1626 |
} |
| 1627 |
const protocol = parser.protocol || ''; |
| 1628 |
switch(parser.hostname){ |
| 1629 |
case 'www.vimeo.com': |
| 1630 |
case 'vimeo.com': |
| 1631 |
return pattern1.test(url) ? url.replace(pattern1, '<iframe width="' + width + '" height="' + height + '" src="' + protocol + '//player.vimeo.com/video/$1" frameborder="0" allowfullscreen></iframe>') : url; |
| 1632 |
case 'youtube.com': |
| 1633 |
case 'www.youtube.com': |
| 1634 |
case 'youtu.be': |
| 1635 |
case 'www.youtu.be': |
| 1636 |
{ |
| 1637 |
const query = parser.search ? (0,_parse_query__WEBPACK_IMPORTED_MODULE_2__.parseQuery)(parser.search) : { |
| 1638 |
v: parser.pathname.substring(1) |
| 1639 |
}; |
| 1640 |
if (/^embed\/.*/.test(query.v)) { |
| 1641 |
query.v = query.v.substring(6); |
| 1642 |
} |
| 1643 |
return query.v ? '<iframe width="' + width + '" height="' + height + '" src="' + protocol + '//www.youtube.com/embed/' + query.v + '" frameborder="0" allowfullscreen></iframe>' : url; |
| 1644 |
} |
| 1645 |
} |
| 1646 |
return url; |
| 1647 |
}; |
| 1648 |
|
| 1649 |
|
| 1650 |
/***/ }), |
| 1651 |
|
| 1652 |
/***/ 4040: |
| 1653 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 1654 |
|
| 1655 |
"use strict"; |
| 1656 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 1657 |
/* harmony export */ trim: function() { return /* binding */ trim; }, |
| 1658 |
/* harmony export */ trimChars: function() { return /* binding */ trimChars; }, |
| 1659 |
/* harmony export */ trimInv: function() { return /* binding */ trimInv; } |
| 1660 |
/* harmony export */ }); |
| 1661 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 1662 |
/*! |
| 1663 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 1664 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 1665 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 1666 |
*/ /** |
| 1667 |
* @module helpers/string |
| 1668 |
*/ |
| 1669 |
/** |
| 1670 |
* It clears the line of all auxiliary invisible characters , from the spaces and line breaks , tabs |
| 1671 |
* from the beginning and end of the line |
| 1672 |
*/ function trim(value) { |
| 1673 |
return value.replace((0,jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.SPACE_REG_EXP_END)(), '').replace((0,jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.SPACE_REG_EXP_START)(), ''); |
| 1674 |
} |
| 1675 |
function trimChars(value, chars) { |
| 1676 |
return value.replace(RegExp(`[${chars}]+$`), '').replace(RegExp(`^[${chars}]+`), ''); |
| 1677 |
} |
| 1678 |
/** |
| 1679 |
* Trim only invisible chars |
| 1680 |
*/ function trimInv(value) { |
| 1681 |
return value.replace((0,jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE_REG_EXP_END)(), '').replace((0,jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE_REG_EXP_START)(), ''); |
| 1682 |
} |
| 1683 |
|
| 1684 |
|
| 1685 |
/***/ }), |
| 1686 |
|
| 1687 |
/***/ 4099: |
| 1688 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 1689 |
|
| 1690 |
"use strict"; |
| 1691 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 1692 |
/* harmony export */ Button: function() { return /* reexport safe */ _button__WEBPACK_IMPORTED_MODULE_0__.Button; }, |
| 1693 |
/* harmony export */ Icon: function() { return /* reexport safe */ _icon__WEBPACK_IMPORTED_MODULE_4__.Icon; }, |
| 1694 |
/* harmony export */ Popup: function() { return /* reexport safe */ _popup__WEBPACK_IMPORTED_MODULE_5__.Popup; }, |
| 1695 |
/* harmony export */ ProgressBar: function() { return /* reexport safe */ _progress_bar_progress_bar__WEBPACK_IMPORTED_MODULE_6__.ProgressBar; }, |
| 1696 |
/* harmony export */ UIBlock: function() { return /* reexport safe */ _form__WEBPACK_IMPORTED_MODULE_2__.UIBlock; }, |
| 1697 |
/* harmony export */ UIButton: function() { return /* reexport safe */ _button__WEBPACK_IMPORTED_MODULE_0__.UIButton; }, |
| 1698 |
/* harmony export */ UIButtonGroup: function() { return /* reexport safe */ _button__WEBPACK_IMPORTED_MODULE_0__.UIButtonGroup; }, |
| 1699 |
/* harmony export */ UIButtonState: function() { return /* reexport safe */ _button__WEBPACK_IMPORTED_MODULE_0__.UIButtonState; }, |
| 1700 |
/* harmony export */ UICheckbox: function() { return /* reexport safe */ _form__WEBPACK_IMPORTED_MODULE_2__.UICheckbox; }, |
| 1701 |
/* harmony export */ UIElement: function() { return /* reexport safe */ _element__WEBPACK_IMPORTED_MODULE_1__.UIElement; }, |
| 1702 |
/* harmony export */ UIFileInput: function() { return /* reexport safe */ _form__WEBPACK_IMPORTED_MODULE_2__.UIFileInput; }, |
| 1703 |
/* harmony export */ UIForm: function() { return /* reexport safe */ _form__WEBPACK_IMPORTED_MODULE_2__.UIForm; }, |
| 1704 |
/* harmony export */ UIGroup: function() { return /* reexport safe */ _group__WEBPACK_IMPORTED_MODULE_3__.UIGroup; }, |
| 1705 |
/* harmony export */ UIInput: function() { return /* reexport safe */ _form__WEBPACK_IMPORTED_MODULE_2__.UIInput; }, |
| 1706 |
/* harmony export */ UIList: function() { return /* reexport safe */ _group__WEBPACK_IMPORTED_MODULE_3__.UIList; }, |
| 1707 |
/* harmony export */ UISelect: function() { return /* reexport safe */ _form__WEBPACK_IMPORTED_MODULE_2__.UISelect; }, |
| 1708 |
/* harmony export */ UISeparator: function() { return /* reexport safe */ _group__WEBPACK_IMPORTED_MODULE_3__.UISeparator; }, |
| 1709 |
/* harmony export */ UISpacer: function() { return /* reexport safe */ _group__WEBPACK_IMPORTED_MODULE_3__.UISpacer; }, |
| 1710 |
/* harmony export */ UITextArea: function() { return /* reexport safe */ _form__WEBPACK_IMPORTED_MODULE_2__.UITextArea; }, |
| 1711 |
/* harmony export */ UITooltip: function() { return /* reexport safe */ _button__WEBPACK_IMPORTED_MODULE_0__.UITooltip; } |
| 1712 |
/* harmony export */ }); |
| 1713 |
/* harmony import */ var _button__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(59400); |
| 1714 |
/* harmony import */ var _element__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(96007); |
| 1715 |
/* harmony import */ var _form__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5658); |
| 1716 |
/* harmony import */ var _group__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(64847); |
| 1717 |
/* harmony import */ var _icon__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(29434); |
| 1718 |
/* harmony import */ var _popup__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(56490); |
| 1719 |
/* harmony import */ var _progress_bar_progress_bar__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(34396); |
| 1720 |
/*! |
| 1721 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 1722 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 1723 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 1724 |
*/ /** |
| 1725 |
* [[include:core/ui/README.md]] |
| 1726 |
* @packageDocumentation |
| 1727 |
* @module ui |
| 1728 |
*/ |
| 1729 |
|
| 1730 |
|
| 1731 |
|
| 1732 |
|
| 1733 |
|
| 1734 |
|
| 1735 |
|
| 1736 |
|
| 1737 |
/***/ }), |
| 1738 |
|
| 1739 |
/***/ 4274: |
| 1740 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 1741 |
|
| 1742 |
"use strict"; |
| 1743 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 1744 |
/* harmony export */ makeButton: function() { return /* binding */ makeButton; }, |
| 1745 |
/* harmony export */ makeCollection: function() { return /* binding */ makeCollection; }, |
| 1746 |
/* harmony export */ makeSelect: function() { return /* binding */ makeSelect; } |
| 1747 |
/* harmony export */ }); |
| 1748 |
/* harmony import */ var jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(91672); |
| 1749 |
/* harmony import */ var jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(91565); |
| 1750 |
/* harmony import */ var jodit_core_helpers_checker_is_jodit_object__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(24497); |
| 1751 |
/*! |
| 1752 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 1753 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 1754 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 1755 |
*/ /** |
| 1756 |
* [[include:modules/toolbar/README.md]] |
| 1757 |
* @packageDocumentation |
| 1758 |
* @module modules/toolbar |
| 1759 |
*/ |
| 1760 |
|
| 1761 |
|
| 1762 |
/** |
| 1763 |
* Collection factory |
| 1764 |
*/ function makeCollection(jodit, parentElement) { |
| 1765 |
const ToolbarCollection = (0,jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_0__.getComponentClass)('ToolbarCollection'); |
| 1766 |
const ToolbarEditorCollection = (0,jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_0__.getComponentClass)('ToolbarEditorCollection'); |
| 1767 |
const collection = (0,jodit_core_helpers_checker_is_jodit_object__WEBPACK_IMPORTED_MODULE_2__.isJoditObject)(jodit) ? new ToolbarEditorCollection(jodit) : new ToolbarCollection(jodit); |
| 1768 |
if (jodit.o.textIcons) { |
| 1769 |
collection.container.classList.add('jodit_text_icons'); |
| 1770 |
} |
| 1771 |
if (parentElement) { |
| 1772 |
collection.parentElement = parentElement; |
| 1773 |
} |
| 1774 |
if (jodit.o.toolbarButtonSize) { |
| 1775 |
collection.buttonSize = jodit.o.toolbarButtonSize; |
| 1776 |
} |
| 1777 |
return collection; |
| 1778 |
} |
| 1779 |
/** |
| 1780 |
* Button factory |
| 1781 |
*/ function makeButton(jodit, control, target = null) { |
| 1782 |
if ((0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_1__.isFunction)(control.getContent)) { |
| 1783 |
const ToolbarContent = (0,jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_0__.getComponentClass)('ToolbarContent'); |
| 1784 |
return new ToolbarContent(jodit, control, target); |
| 1785 |
} |
| 1786 |
const ToolbarButton = (0,jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_0__.getComponentClass)('ToolbarButton'); |
| 1787 |
const button = new ToolbarButton(jodit, control, target); |
| 1788 |
button.state.tabIndex = jodit.o.allowTabNavigation ? 0 : -1; |
| 1789 |
return button; |
| 1790 |
} |
| 1791 |
function makeSelect(view, control, target = null) { |
| 1792 |
const ToolbarSelect = (0,jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_0__.getComponentClass)('ToolbarSelect'); |
| 1793 |
return new ToolbarSelect(view, control, target); |
| 1794 |
} |
| 1795 |
|
| 1796 |
|
| 1797 |
/***/ }), |
| 1798 |
|
| 1799 |
/***/ 4561: |
| 1800 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 1801 |
|
| 1802 |
"use strict"; |
| 1803 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 1804 |
/* harmony export */ UIBlock: function() { return /* binding */ UIBlock; } |
| 1805 |
/* harmony export */ }); |
| 1806 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 1807 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 1808 |
/* harmony import */ var jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(91672); |
| 1809 |
/* harmony import */ var jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(93640); |
| 1810 |
/* harmony import */ var jodit_core_ui_group_group__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(63468); |
| 1811 |
/*! |
| 1812 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 1813 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 1814 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 1815 |
*/ /** |
| 1816 |
* @module ui/form |
| 1817 |
*/ |
| 1818 |
|
| 1819 |
|
| 1820 |
|
| 1821 |
|
| 1822 |
|
| 1823 |
class UIBlock extends jodit_core_ui_group_group__WEBPACK_IMPORTED_MODULE_4__.UIGroup { |
| 1824 |
/** @override */ className() { |
| 1825 |
return 'UIBlock'; |
| 1826 |
} |
| 1827 |
constructor(jodit, elements, options = { |
| 1828 |
align: 'left' |
| 1829 |
}){ |
| 1830 |
super(jodit, elements), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "options", void 0), this.options = options; |
| 1831 |
this.setMod('align', this.options.align || 'left'); |
| 1832 |
this.setMod('width', this.options.width || ''); |
| 1833 |
this.options.mod && this.setMod(this.options.mod, true); |
| 1834 |
this.options.className && this.container.classList.add(this.options.className); |
| 1835 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_3__.attr)(this.container, 'data-ref', options.ref); |
| 1836 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_3__.attr)(this.container, 'ref', options.ref); |
| 1837 |
} |
| 1838 |
} |
| 1839 |
UIBlock = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 1840 |
jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_2__.component |
| 1841 |
], UIBlock); |
| 1842 |
|
| 1843 |
|
| 1844 |
/***/ }), |
| 1845 |
|
| 1846 |
/***/ 5266: |
| 1847 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 1848 |
|
| 1849 |
"use strict"; |
| 1850 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 1851 |
/* harmony export */ Config: function() { return /* binding */ Config; } |
| 1852 |
/* harmony export */ }); |
| 1853 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 1854 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(81937); |
| 1855 |
|
| 1856 |
/*! |
| 1857 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 1858 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 1859 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 1860 |
*/ /** |
| 1861 |
* Editor options. These can be configured upon the creation of the editor. |
| 1862 |
* ```javascript |
| 1863 |
* const editor = Jodit.make('#editor', { |
| 1864 |
* toolbar: true, |
| 1865 |
* buttons: ['bold', 'italic', 'underline'] |
| 1866 |
* // other options |
| 1867 |
* // ... |
| 1868 |
* }); |
| 1869 |
* ``` |
| 1870 |
* @packageDocumentation |
| 1871 |
* @module config |
| 1872 |
*/ |
| 1873 |
|
| 1874 |
let ConfigPrototype = {}; |
| 1875 |
/** |
| 1876 |
* Default Editor's Configuration. |
| 1877 |
* |
| 1878 |
* This class holds all default option values for the Jodit editor. |
| 1879 |
* It uses a **private constructor** and a **lazy singleton** pattern — the single instance |
| 1880 |
* is created on the first access to {@link Config.defaultOptions} (also available as `Jodit.defaultOptions`). |
| 1881 |
* |
| 1882 |
* ## How options are resolved |
| 1883 |
* |
| 1884 |
* When you create an editor with `Jodit.make('#editor', userOptions)`, the library |
| 1885 |
* calls {@link ConfigProto}(userOptions, Config.defaultOptions). `ConfigProto` does |
| 1886 |
* **not** deep-clone the defaults. Instead it creates a new object whose JavaScript |
| 1887 |
* prototype is `Config.defaultOptions`: |
| 1888 |
* |
| 1889 |
* ``` |
| 1890 |
* userOptions ──[[Prototype]]──► Config.defaultOptions |
| 1891 |
* ``` |
| 1892 |
* |
| 1893 |
* Any key present in `userOptions` shadows the default; |
| 1894 |
* any key **not** present falls through to `Config.defaultOptions` via the prototype chain. |
| 1895 |
* Nested plain objects are recursively prototyped in the same way, so partial overrides |
| 1896 |
* of nested options work automatically: |
| 1897 |
* |
| 1898 |
* ```js |
| 1899 |
* // Only override `dialogWidth`; all other `image.*` defaults are still available |
| 1900 |
* Jodit.make('#editor', { |
| 1901 |
* image: { dialogWidth: 500 } |
| 1902 |
* }); |
| 1903 |
* ``` |
| 1904 |
* |
| 1905 |
* ## How plugins extend the config |
| 1906 |
* |
| 1907 |
* Each plugin adds its own defaults by assigning to `Config.prototype` and augmenting |
| 1908 |
* the TypeScript type with `declare module`: |
| 1909 |
* |
| 1910 |
* ```ts |
| 1911 |
* // 1. Type augmentation (compile-time) |
| 1912 |
* declare module 'jodit/config' { |
| 1913 |
* interface Config { |
| 1914 |
* toolbarSticky: boolean; |
| 1915 |
* } |
| 1916 |
* } |
| 1917 |
* |
| 1918 |
* // 2. Runtime default |
| 1919 |
* Config.prototype.toolbarSticky = true; |
| 1920 |
* ``` |
| 1921 |
* |
| 1922 |
* Because the constructor runs `Object.assign(this, ConfigPrototype)` (where |
| 1923 |
* `ConfigPrototype` is captured as `Config.prototype` after the class definition), |
| 1924 |
* all prototype-level values — including those added by plugins — are materialized |
| 1925 |
* as own properties on the singleton. This means `Config.defaultOptions` always |
| 1926 |
* contains every registered option as an own, enumerable property. |
| 1927 |
* |
| 1928 |
* ## Changing global defaults |
| 1929 |
* |
| 1930 |
* You can modify `Jodit.defaultOptions` **before** creating editors to change |
| 1931 |
* defaults globally: |
| 1932 |
* |
| 1933 |
* ```js |
| 1934 |
* Jodit.defaultOptions.language = 'de'; |
| 1935 |
* Jodit.defaultOptions.theme = 'dark'; |
| 1936 |
* |
| 1937 |
* // Both editors inherit the new defaults |
| 1938 |
* Jodit.make('#editor1'); |
| 1939 |
* Jodit.make('#editor2'); |
| 1940 |
* ``` |
| 1941 |
* |
| 1942 |
* ## `Jodit.atom` — preventing deep merge |
| 1943 |
* |
| 1944 |
* By default, `ConfigProto` deep-merges nested plain objects and arrays. |
| 1945 |
* Wrap a value with `Jodit.atom(value)` to make it **atomic** — it will completely |
| 1946 |
* replace the default instead of being merged: |
| 1947 |
* |
| 1948 |
* ```js |
| 1949 |
* Jodit.make('#editor', { |
| 1950 |
* controls: { |
| 1951 |
* fontsize: { |
| 1952 |
* // Replace the entire list rather than merging with the default one |
| 1953 |
* list: Jodit.atom([8, 9, 10]) |
| 1954 |
* } |
| 1955 |
* } |
| 1956 |
* }); |
| 1957 |
* ``` |
| 1958 |
* |
| 1959 |
* `Jodit.atom` calls {@link markAsAtomic}, which sets a non-enumerable |
| 1960 |
* `isAtom` flag on the object. `ConfigProto` checks this flag and skips |
| 1961 |
* recursive merging when it is present. Note: top-level arrays (depth 0) |
| 1962 |
* are always treated as atomic — they replace rather than merge. |
| 1963 |
* |
| 1964 |
* @see {@link ConfigProto} for the full merge algorithm |
| 1965 |
* @see {@link markAsAtomic} / {@link isAtom} for the atom marker implementation |
| 1966 |
*/ class Config { |
| 1967 |
static get defaultOptions() { |
| 1968 |
if (!Config.__defaultOptions) { |
| 1969 |
Config.__defaultOptions = new Config(); |
| 1970 |
} |
| 1971 |
return Config.__defaultOptions; |
| 1972 |
} |
| 1973 |
constructor(){ |
| 1974 |
/** |
| 1975 |
* When enabled, the editor caches the results of expensive computations (e.g. toolbar rebuilds) |
| 1976 |
* to improve performance. Disable for debugging or when options change frequently at runtime. |
| 1977 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "cache", true); |
| 1978 |
/** |
| 1979 |
* Timeout of all asynchronous methods |
| 1980 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "defaultTimeout", 100); |
| 1981 |
/** |
| 1982 |
* Prefix used for CSS class names and local-storage keys to avoid collisions |
| 1983 |
* when multiple editor instances or applications share the same page. |
| 1984 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "namespace", ''); |
| 1985 |
/** |
| 1986 |
* Editor loads completely without plugins. Useful when debugging your own plugin. |
| 1987 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "safeMode", false); |
| 1988 |
/** |
| 1989 |
* Editor's width |
| 1990 |
* |
| 1991 |
* ```javascript |
| 1992 |
* Jodit.make('.editor', { |
| 1993 |
* width: '100%', |
| 1994 |
* }) |
| 1995 |
* ``` |
| 1996 |
* ```javascript |
| 1997 |
* Jodit.make('.editor', { |
| 1998 |
* width: 600, // equivalent for '600px' |
| 1999 |
* }) |
| 2000 |
* ``` |
| 2001 |
* ```javascript |
| 2002 |
* Jodit.make('.editor', { |
| 2003 |
* width: 'auto', // autosize |
| 2004 |
* }) |
| 2005 |
* ``` |
| 2006 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "width", 'auto'); |
| 2007 |
/** |
| 2008 |
* Editor's height |
| 2009 |
* |
| 2010 |
* ```javascript |
| 2011 |
* Jodit.make('.editor', { |
| 2012 |
* height: '100%', |
| 2013 |
* }) |
| 2014 |
* ``` |
| 2015 |
* ```javascript |
| 2016 |
* Jodit.make('.editor', { |
| 2017 |
* height: 600, // equivalent for '600px' |
| 2018 |
* }) |
| 2019 |
* ``` |
| 2020 |
* ```javascript |
| 2021 |
* Jodit.make('.editor', { |
| 2022 |
* height: 'auto', // default - autosize |
| 2023 |
* }) |
| 2024 |
* ``` |
| 2025 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "height", 'auto'); |
| 2026 |
/** |
| 2027 |
* List of plugins that will be initialized in safe mode. |
| 2028 |
* |
| 2029 |
* ```js |
| 2030 |
* Jodit.make('#editor', { |
| 2031 |
* safeMode: true, |
| 2032 |
* safePluginsList: ['about'], |
| 2033 |
* extraPlugins: ['yourPluginDev'] |
| 2034 |
* }); |
| 2035 |
* ``` |
| 2036 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "safePluginsList", [ |
| 2037 |
'about', |
| 2038 |
'enter', |
| 2039 |
'backspace', |
| 2040 |
'size', |
| 2041 |
'bold', |
| 2042 |
'hotkeys' |
| 2043 |
]); |
| 2044 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "commandToHotkeys", void 0); |
| 2045 |
/** |
| 2046 |
* Reserved for the paid version of the editor |
| 2047 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "license", ''); |
| 2048 |
/** |
| 2049 |
* The name of the preset that will be used to initialize the editor. |
| 2050 |
* The list of available presets can be found here Jodit.defaultOptions.presets |
| 2051 |
* ```javascript |
| 2052 |
* Jodit.make('.editor', { |
| 2053 |
* preset: 'inline' |
| 2054 |
* }); |
| 2055 |
* ``` |
| 2056 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "preset", 'custom'); |
| 2057 |
/** |
| 2058 |
* Dictionary of named configuration presets. Each key is a preset name and the value |
| 2059 |
* is a partial options object that will be merged into the editor config when |
| 2060 |
* {@link Config.preset} matches the key. |
| 2061 |
* |
| 2062 |
* ```javascript |
| 2063 |
* // Use a built-in preset |
| 2064 |
* Jodit.make('#editor', { |
| 2065 |
* preset: 'inline' |
| 2066 |
* }); |
| 2067 |
* ``` |
| 2068 |
* |
| 2069 |
* ```javascript |
| 2070 |
* // Define and use a custom preset |
| 2071 |
* Jodit.defaultOptions.presets.myCompact = { |
| 2072 |
* toolbarButtonSize: 'small', |
| 2073 |
* showCharsCounter: false, |
| 2074 |
* showWordsCounter: false, |
| 2075 |
* showXPathInStatusbar: false |
| 2076 |
* }; |
| 2077 |
* |
| 2078 |
* Jodit.make('#editor', { |
| 2079 |
* preset: 'myCompact' |
| 2080 |
* }); |
| 2081 |
* ``` |
| 2082 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "presets", { |
| 2083 |
inline: { |
| 2084 |
inline: true, |
| 2085 |
toolbar: false, |
| 2086 |
toolbarInline: true, |
| 2087 |
toolbarInlineForSelection: true, |
| 2088 |
showXPathInStatusbar: false, |
| 2089 |
showCharsCounter: false, |
| 2090 |
showWordsCounter: false, |
| 2091 |
showPlaceholder: false |
| 2092 |
} |
| 2093 |
}); |
| 2094 |
/** |
| 2095 |
* The Document object the editor operates within. Defaults to the current `document`. |
| 2096 |
* Override when the editor is created inside an iframe or a different browsing context. |
| 2097 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "ownerDocument", jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.globalDocument); |
| 2098 |
/** |
| 2099 |
* Allows you to specify the window in which the editor will be created. Default - window |
| 2100 |
* This is necessary if you are creating the editor inside an iframe but the code is running in the parent window |
| 2101 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "ownerWindow", jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.globalWindow); |
| 2102 |
/** |
| 2103 |
* Shadow root if Jodit was created in it |
| 2104 |
* |
| 2105 |
* ```html |
| 2106 |
* <div id="editor"></div> |
| 2107 |
* ``` |
| 2108 |
* |
| 2109 |
* ```js |
| 2110 |
* const app = document.getElementById('editor'); |
| 2111 |
* app.attachShadow({ mode: 'open' }); |
| 2112 |
* const root = app.shadowRoot; |
| 2113 |
* |
| 2114 |
* root.innerHTML = ` |
| 2115 |
* <link rel="stylesheet" href="./build/jodit.css"/> |
| 2116 |
* <h1>Jodit example in Shadow DOM</h1> |
| 2117 |
* <div id="edit"></div> |
| 2118 |
* `; |
| 2119 |
* |
| 2120 |
* const editor = Jodit.make(root.getElementById('edit'), { |
| 2121 |
* globalFullSize: false, |
| 2122 |
* shadowRoot: root |
| 2123 |
* }); |
| 2124 |
* editor.value = '<p>start</p>'; |
| 2125 |
* ``` |
| 2126 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "shadowRoot", null); |
| 2127 |
/** |
| 2128 |
* Base CSS `z-index` for the editor UI (toolbar, popups, dialogs). |
| 2129 |
* Set to a higher value when other page elements overlap the editor. |
| 2130 |
* `0` means no explicit z-index is applied. |
| 2131 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "zIndex", 0); |
| 2132 |
/** |
| 2133 |
* Change the read-only state of the editor |
| 2134 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "readonly", false); |
| 2135 |
/** |
| 2136 |
* Change the disabled state of the editor |
| 2137 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "disabled", false); |
| 2138 |
/** |
| 2139 |
* In readOnly mode, some buttons can still be useful, for example, the button to view source code or print |
| 2140 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "activeButtonsInReadOnly", [ |
| 2141 |
'source', |
| 2142 |
'fullsize', |
| 2143 |
'print', |
| 2144 |
'about', |
| 2145 |
'dots', |
| 2146 |
'selectall' |
| 2147 |
]); |
| 2148 |
/** |
| 2149 |
* When the editor is in read-only mode, some commands can still be executed: |
| 2150 |
* ```javascript |
| 2151 |
* const editor = Jodit.make('.editor', { |
| 2152 |
* allowCommandsInReadOnly: ['selectall', 'preview', 'print'] |
| 2153 |
* readonly: true |
| 2154 |
* }); |
| 2155 |
* editor.execCommand('selectall');// will be selected all content |
| 2156 |
* editor.execCommand('delete');// but content will not be deleted |
| 2157 |
* ``` |
| 2158 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "allowCommandsInReadOnly", [ |
| 2159 |
'selectall', |
| 2160 |
'preview', |
| 2161 |
'print' |
| 2162 |
]); |
| 2163 |
/** |
| 2164 |
* Size of icons in the toolbar (can be "small", "middle", "large") |
| 2165 |
* |
| 2166 |
* ```javascript |
| 2167 |
* const editor = Jodit.make(".dark_editor", { |
| 2168 |
* toolbarButtonSize: "small" |
| 2169 |
* }); |
| 2170 |
* ``` |
| 2171 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "toolbarButtonSize", 'middle'); |
| 2172 |
/** |
| 2173 |
* Allow navigation in the toolbar of the editor by Tab key |
| 2174 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "allowTabNavigation", false); |
| 2175 |
/** |
| 2176 |
* When enabled, the editor renders without its own container chrome (toolbar, borders, statusbar). |
| 2177 |
* The editable area becomes the element itself. Typically combined with |
| 2178 |
* `toolbarInline: true` so a floating toolbar appears on selection. |
| 2179 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "inline", false); |
| 2180 |
/** |
| 2181 |
* Theme (can be "dark") |
| 2182 |
* |
| 2183 |
* ```javascript |
| 2184 |
* const editor = Jodit.make(".dark_editor", { |
| 2185 |
* theme: "dark" |
| 2186 |
* }); |
| 2187 |
* ``` |
| 2188 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "theme", 'default'); |
| 2189 |
/** |
| 2190 |
* if set true, then the current mode is saved in a cookie, and is restored after a reload of the page |
| 2191 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "saveModeInStorage", false); |
| 2192 |
/** |
| 2193 |
* Class name that can be appended to the editable area |
| 2194 |
* |
| 2195 |
* @see {@link Config.iframeCSSLinks} |
| 2196 |
* @see {@link Config.iframeStyle} |
| 2197 |
* |
| 2198 |
* ```javascript |
| 2199 |
* Jodit.make('#editor', { |
| 2200 |
* editorClassName: 'some_my_class' |
| 2201 |
* }); |
| 2202 |
* ``` |
| 2203 |
* ```html |
| 2204 |
* <style> |
| 2205 |
* .some_my_class p{ |
| 2206 |
* line-height: 16px; |
| 2207 |
* } |
| 2208 |
* </style> |
| 2209 |
* ``` |
| 2210 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "editorClassName", false); |
| 2211 |
/** |
| 2212 |
* Class name that can be appended to the main editor container |
| 2213 |
* |
| 2214 |
* ```javascript |
| 2215 |
* const jodit = Jodit.make('#editor', { |
| 2216 |
* className: 'some_my_class' |
| 2217 |
* }); |
| 2218 |
* |
| 2219 |
* console.log(jodit.container.classList.contains('some_my_class')); // true |
| 2220 |
* ``` |
| 2221 |
* ```html |
| 2222 |
* <style> |
| 2223 |
* .some_my_class { |
| 2224 |
* max-width: 600px; |
| 2225 |
* margin: 0 auto; |
| 2226 |
* } |
| 2227 |
* </style> |
| 2228 |
* ``` |
| 2229 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "className", false); |
| 2230 |
/** |
| 2231 |
* The internal styles of the editable area. They are intended to change |
| 2232 |
* not the appearance of the editor, but to change the appearance of the content. |
| 2233 |
* |
| 2234 |
* ```javascript |
| 2235 |
* Jodit.make('#editor', { |
| 2236 |
* style: { |
| 2237 |
* font: '12px Arial', |
| 2238 |
* color: '#0c0c0c' |
| 2239 |
* } |
| 2240 |
* }); |
| 2241 |
* ``` |
| 2242 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "style", false); |
| 2243 |
/** |
| 2244 |
* Inline CSS styles applied to the outer editor container element. |
| 2245 |
* Use this to style the editor wrapper (borders, background, etc.) without affecting content. |
| 2246 |
* |
| 2247 |
* ```javascript |
| 2248 |
* Jodit.make('#editor', { |
| 2249 |
* containerStyle: { |
| 2250 |
* border: '1px solid #ccc', |
| 2251 |
* background: '#f9f9f9' |
| 2252 |
* } |
| 2253 |
* }); |
| 2254 |
* ``` |
| 2255 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "containerStyle", false); |
| 2256 |
/** |
| 2257 |
* Dictionary of variable values in css, a complete list can be found here |
| 2258 |
* https://github.com/xdan/jodit/blob/main/src/styles/variables.less#L25 |
| 2259 |
* |
| 2260 |
* ```js |
| 2261 |
* const editor = Jodit.make('#editor', { |
| 2262 |
* styleValues: { |
| 2263 |
* 'color-text': 'red', |
| 2264 |
* colorBorder: 'black', |
| 2265 |
* 'color-panel': 'blue' |
| 2266 |
* } |
| 2267 |
* }); |
| 2268 |
* ``` |
| 2269 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "styleValues", {}); |
| 2270 |
/** |
| 2271 |
* When enabled, the editor dispatches a native `change` event on the original |
| 2272 |
* `<textarea>` element whenever the content changes, so standard DOM listeners work. |
| 2273 |
* |
| 2274 |
* ```javascript |
| 2275 |
* const editor = Jodit.make('#editor'); |
| 2276 |
* document.getElementById('editor').addEventListener('change', function () { |
| 2277 |
* console.log(this.value); |
| 2278 |
* }) |
| 2279 |
* ``` |
| 2280 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "triggerChangeEvent", true); |
| 2281 |
/** |
| 2282 |
* The writing direction of the language which is used to create editor content. Allowed values are: '' |
| 2283 |
* (an empty string) – Indicates that content direction will be the same as either the editor UI direction or |
| 2284 |
* the page element direction. 'ltr' – Indicates a Left-To-Right text direction (like in English). |
| 2285 |
* 'rtl' – Indicates a Right-To-Left text direction (like in Arabic). |
| 2286 |
* |
| 2287 |
* ```javascript |
| 2288 |
* Jodit.make('.editor', { |
| 2289 |
* direction: 'rtl' |
| 2290 |
* }) |
| 2291 |
* ``` |
| 2292 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "direction", ''); |
| 2293 |
/** |
| 2294 |
* Language by default. if `auto` language set by document.documentElement.lang || |
| 2295 |
* (navigator.language && navigator.language.substr(0, 2)) || |
| 2296 |
* (navigator.browserLanguage && navigator.browserLanguage.substr(0, 2)) || 'en' |
| 2297 |
* |
| 2298 |
* ```html |
| 2299 |
* <!-- include in you page lang file --> |
| 2300 |
* <script src="jodit/lang/de.js"></script> |
| 2301 |
* <script> |
| 2302 |
* var editor = Jodit.make('.editor', { |
| 2303 |
* language: 'de' |
| 2304 |
* }); |
| 2305 |
* </script> |
| 2306 |
* ``` |
| 2307 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "language", 'auto'); |
| 2308 |
/** |
| 2309 |
* if true all Lang.i18n(key) return `{key}` |
| 2310 |
* |
| 2311 |
* ```html |
| 2312 |
* <script> |
| 2313 |
* var editor = Jodit.make('.editor', { |
| 2314 |
* debugLanguage: true |
| 2315 |
* }); |
| 2316 |
* |
| 2317 |
* console.log(editor.i18n("Test")); // {Test} |
| 2318 |
* </script> |
| 2319 |
* ``` |
| 2320 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "debugLanguage", false); |
| 2321 |
/** |
| 2322 |
* Collection of language pack data `{en: {'Type something': 'Type something', ...}}` |
| 2323 |
* |
| 2324 |
* ```javascript |
| 2325 |
* const editor = Jodit.make('#editor', { |
| 2326 |
* language: 'ru', |
| 2327 |
* i18n: { |
| 2328 |
* ru: { |
| 2329 |
* 'Type something': 'Начните что-либо вводить' |
| 2330 |
* } |
| 2331 |
* } |
| 2332 |
* }); |
| 2333 |
* console.log(editor.i18n('Type something')) //Начните что-либо вводить |
| 2334 |
* ``` |
| 2335 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "i18n", false); |
| 2336 |
/** |
| 2337 |
* The tabindex global attribute is an integer indicating if the element can take |
| 2338 |
* input focus (is focusable), if it should participate to sequential keyboard navigation, |
| 2339 |
* and if so, at what position. It can take several values |
| 2340 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "tabIndex", -1); |
| 2341 |
/** |
| 2342 |
* Boolean, whether the toolbar should be shown. |
| 2343 |
* Alternatively, a valid css-selector-string to use an element as toolbar container. |
| 2344 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "toolbar", true); |
| 2345 |
/** |
| 2346 |
* Boolean, whether the statusbar should be shown. |
| 2347 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "statusbar", true); |
| 2348 |
/** |
| 2349 |
* Show tooltip after mouse enter on the button |
| 2350 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "showTooltip", true); |
| 2351 |
/** |
| 2352 |
* Delay before show tooltip |
| 2353 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "showTooltipDelay", 200); |
| 2354 |
/** |
| 2355 |
* Instead of creating a custom tooltip, use the browser's native title tooltips |
| 2356 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "useNativeTooltip", false); |
| 2357 |
/** |
| 2358 |
* How pasted content is inserted into the editor by default. |
| 2359 |
* Possible values: `insert_as_html`, `insert_as_text`, `insert_only_text`, `insert_clear_html`. |
| 2360 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "defaultActionOnPaste", jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.INSERT_AS_HTML); |
| 2361 |
// TODO |
| 2362 |
// autosave: false, // false or url |
| 2363 |
// autosaveCallback: false, // function |
| 2364 |
// interval: 60, // seconds |
| 2365 |
// TODO |
| 2366 |
/** |
| 2367 |
* Element that will be created when you press Enter |
| 2368 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "enter", jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.PARAGRAPH); |
| 2369 |
/** |
| 2370 |
* When this option is enabled, the editor's content will be placed in an iframe and isolated from the rest of the page. |
| 2371 |
* |
| 2372 |
* ```javascript |
| 2373 |
* Jodit.make('#editor', { |
| 2374 |
* iframe: true, |
| 2375 |
* iframeStyle: 'html{margin: 0px;}body{padding:10px;background:transparent;color:#000;position:relative;z-index:2;\ |
| 2376 |
* user-select:auto;margin:0px;overflow:hidden;}body:after{content:"";clear:both;display:block}'; |
| 2377 |
* }); |
| 2378 |
* ``` |
| 2379 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "iframe", false); |
| 2380 |
/** |
| 2381 |
* Allow editing the entire HTML document(html, head) |
| 2382 |
* \> Works together with the iframe option. |
| 2383 |
* |
| 2384 |
* ```js |
| 2385 |
* const editor = Jodit.make('#editor', { |
| 2386 |
* iframe: true, |
| 2387 |
* editHTMLDocumentMode: true |
| 2388 |
* }); |
| 2389 |
* editor.value = '<!DOCTYPE html><html lang="en" style="overflow-y:hidden">' + |
| 2390 |
* '<head><title>Jodit Editor</title></head>' + |
| 2391 |
* '<body spellcheck="false"><p>Some text</p><p> a </p></body>' + |
| 2392 |
* '</html>'; |
| 2393 |
* ``` |
| 2394 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "editHTMLDocumentMode", false); |
| 2395 |
/** |
| 2396 |
* Use when you need to insert new block element |
| 2397 |
* use enter option if not set |
| 2398 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "enterBlock", this.enter !== 'br' ? this.enter : jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.PARAGRAPH); |
| 2399 |
/** |
| 2400 |
* Jodit.MODE_WYSIWYG The HTML editor allows you to write like MSWord, |
| 2401 |
* Jodit.MODE_SOURCE syntax highlighting source editor |
| 2402 |
* |
| 2403 |
* ```javascript |
| 2404 |
* var editor = Jodit.make('#editor', { |
| 2405 |
* defaultMode: Jodit.MODE_SPLIT |
| 2406 |
* }); |
| 2407 |
* console.log(editor.getRealMode()) |
| 2408 |
* ``` |
| 2409 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "defaultMode", jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.MODE_WYSIWYG); |
| 2410 |
/** |
| 2411 |
* When enabled, the editor displays both the WYSIWYG view and the source-code view side by side. |
| 2412 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "useSplitMode", false); |
| 2413 |
/** |
| 2414 |
* The colors in HEX representation to select a color for the background and for the text in colorpicker |
| 2415 |
* |
| 2416 |
* ```javascript |
| 2417 |
* Jodit.make('#editor', { |
| 2418 |
* colors: ['#ff0000', '#00ff00', '#0000ff'] |
| 2419 |
* }) |
| 2420 |
* ``` |
| 2421 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "colors", { |
| 2422 |
greyscale: [ |
| 2423 |
'#000000', |
| 2424 |
'#434343', |
| 2425 |
'#666666', |
| 2426 |
'#999999', |
| 2427 |
'#B7B7B7', |
| 2428 |
'#CCCCCC', |
| 2429 |
'#D9D9D9', |
| 2430 |
'#EFEFEF', |
| 2431 |
'#F3F3F3', |
| 2432 |
'#FFFFFF' |
| 2433 |
], |
| 2434 |
palette: [ |
| 2435 |
'#980000', |
| 2436 |
'#FF0000', |
| 2437 |
'#FF9900', |
| 2438 |
'#FFFF00', |
| 2439 |
'#00F0F0', |
| 2440 |
'#00FFFF', |
| 2441 |
'#4A86E8', |
| 2442 |
'#0000FF', |
| 2443 |
'#9900FF', |
| 2444 |
'#FF00FF' |
| 2445 |
], |
| 2446 |
full: [ |
| 2447 |
'#E6B8AF', |
| 2448 |
'#F4CCCC', |
| 2449 |
'#FCE5CD', |
| 2450 |
'#FFF2CC', |
| 2451 |
'#D9EAD3', |
| 2452 |
'#D0E0E3', |
| 2453 |
'#C9DAF8', |
| 2454 |
'#CFE2F3', |
| 2455 |
'#D9D2E9', |
| 2456 |
'#EAD1DC', |
| 2457 |
'#DD7E6B', |
| 2458 |
'#EA9999', |
| 2459 |
'#F9CB9C', |
| 2460 |
'#FFE599', |
| 2461 |
'#B6D7A8', |
| 2462 |
'#A2C4C9', |
| 2463 |
'#A4C2F4', |
| 2464 |
'#9FC5E8', |
| 2465 |
'#B4A7D6', |
| 2466 |
'#D5A6BD', |
| 2467 |
'#CC4125', |
| 2468 |
'#E06666', |
| 2469 |
'#F6B26B', |
| 2470 |
'#FFD966', |
| 2471 |
'#93C47D', |
| 2472 |
'#76A5AF', |
| 2473 |
'#6D9EEB', |
| 2474 |
'#6FA8DC', |
| 2475 |
'#8E7CC3', |
| 2476 |
'#C27BA0', |
| 2477 |
'#A61C00', |
| 2478 |
'#CC0000', |
| 2479 |
'#E69138', |
| 2480 |
'#F1C232', |
| 2481 |
'#6AA84F', |
| 2482 |
'#45818E', |
| 2483 |
'#3C78D8', |
| 2484 |
'#3D85C6', |
| 2485 |
'#674EA7', |
| 2486 |
'#A64D79', |
| 2487 |
'#85200C', |
| 2488 |
'#990000', |
| 2489 |
'#B45F06', |
| 2490 |
'#BF9000', |
| 2491 |
'#38761D', |
| 2492 |
'#134F5C', |
| 2493 |
'#1155CC', |
| 2494 |
'#0B5394', |
| 2495 |
'#351C75', |
| 2496 |
'#733554', |
| 2497 |
'#5B0F00', |
| 2498 |
'#660000', |
| 2499 |
'#783F04', |
| 2500 |
'#7F6000', |
| 2501 |
'#274E13', |
| 2502 |
'#0C343D', |
| 2503 |
'#1C4587', |
| 2504 |
'#073763', |
| 2505 |
'#20124D', |
| 2506 |
'#4C1130' |
| 2507 |
] |
| 2508 |
}); |
| 2509 |
/** |
| 2510 |
* The default tab color picker |
| 2511 |
* |
| 2512 |
* ```javascript |
| 2513 |
* Jodit.make('#editor2', { |
| 2514 |
* colorPickerDefaultTab: 'color' |
| 2515 |
* }) |
| 2516 |
* ``` |
| 2517 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "colorPickerDefaultTab", 'background'); |
| 2518 |
/** |
| 2519 |
* Default width (in pixels) applied to images inserted into the editor |
| 2520 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "imageDefaultWidth", 300); |
| 2521 |
/** |
| 2522 |
* Do not display these buttons that are on the list |
| 2523 |
* |
| 2524 |
* ```javascript |
| 2525 |
* Jodit.make('#editor2', { |
| 2526 |
* removeButtons: ['hr', 'source'] |
| 2527 |
* }); |
| 2528 |
* ``` |
| 2529 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "removeButtons", []); |
| 2530 |
/** |
| 2531 |
* Do not init these plugins |
| 2532 |
* |
| 2533 |
* ```typescript |
| 2534 |
* var editor = Jodit.make('.editor', { |
| 2535 |
* disablePlugins: 'table,iframe' |
| 2536 |
* }); |
| 2537 |
* //or |
| 2538 |
* var editor = Jodit.make('.editor', { |
| 2539 |
* disablePlugins: ['table', 'iframe'] |
| 2540 |
* }); |
| 2541 |
* ``` |
| 2542 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "disablePlugins", []); |
| 2543 |
/** |
| 2544 |
* Init and download extra plugins |
| 2545 |
* |
| 2546 |
* ```typescript |
| 2547 |
* var editor = Jodit.make('.editor', { |
| 2548 |
* extraPlugins: ['emoji'] |
| 2549 |
* }); |
| 2550 |
* ``` |
| 2551 |
* It will try load %SCRIPT_PATH%/plugins/emoji/emoji.js and after load will try init it |
| 2552 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "extraPlugins", []); |
| 2553 |
/** |
| 2554 |
* Base path for download extra plugins |
| 2555 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "basePath", void 0); |
| 2556 |
/** |
| 2557 |
* Additional buttons appended to the {@link Config.buttons} list |
| 2558 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "extraButtons", []); |
| 2559 |
/** |
| 2560 |
* By default, you can only install an icon from the Jodit suite. |
| 2561 |
* You can add your icon to the set using the `Jodit.modules.Icon.set (name, svg Code)` method. |
| 2562 |
* But for a declarative declaration, you can use this option. |
| 2563 |
* |
| 2564 |
* ```js |
| 2565 |
* Jodit.modules.Icon.set('someIcon', '<svg><path.../></svg>'); |
| 2566 |
* const editor = Jodit.make({ |
| 2567 |
* extraButtons: [{ |
| 2568 |
* name: 'someButton', |
| 2569 |
* icon: 'someIcon' |
| 2570 |
* }] |
| 2571 |
* }); |
| 2572 |
* ``` |
| 2573 |
* |
| 2574 |
* ```js |
| 2575 |
* const editor = Jodit.make({ |
| 2576 |
* extraIcons: { |
| 2577 |
* someIcon: '<svg><path.../></svg>' |
| 2578 |
* }, |
| 2579 |
* extraButtons: [{ |
| 2580 |
* name: 'someButton', |
| 2581 |
* icon: 'someIcon' |
| 2582 |
* }] |
| 2583 |
* }); |
| 2584 |
* ``` |
| 2585 |
* |
| 2586 |
* ```js |
| 2587 |
* const editor = Jodit.make({ |
| 2588 |
* extraButtons: [{ |
| 2589 |
* name: 'someButton', |
| 2590 |
* icon: '<svg><path.../></svg>' |
| 2591 |
* }] |
| 2592 |
* }); |
| 2593 |
* ``` |
| 2594 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "extraIcons", {}); |
| 2595 |
/** |
| 2596 |
* Default attributes for created inside editor elements |
| 2597 |
* |
| 2598 |
* ```js |
| 2599 |
* const editor2 = Jodit.make('#editor', { |
| 2600 |
* createAttributes: { |
| 2601 |
* div: { |
| 2602 |
* class: 'test' |
| 2603 |
* }, |
| 2604 |
* ul: function (ul) { |
| 2605 |
* ul.classList.add('ui-test'); |
| 2606 |
* } |
| 2607 |
* } |
| 2608 |
* }); |
| 2609 |
* |
| 2610 |
* const div2 = editor2.createInside.div(); |
| 2611 |
* expect(div2.className).equals('test'); |
| 2612 |
* |
| 2613 |
* const ul = editor2.createInside.element('ul'); |
| 2614 |
* expect(ul.className).equals('ui-test'); |
| 2615 |
* ``` |
| 2616 |
* Or JSX in React |
| 2617 |
* |
| 2618 |
* ```jsx |
| 2619 |
* import React, {useState, useRef} from 'react'; |
| 2620 |
* import JoditEditor from "jodit-react"; |
| 2621 |
* |
| 2622 |
* const config = { |
| 2623 |
* createAttributes: { |
| 2624 |
* div: { |
| 2625 |
* class: 'align-center' |
| 2626 |
* } |
| 2627 |
* } |
| 2628 |
* }; |
| 2629 |
* |
| 2630 |
* <JoditEditor config={config}/> |
| 2631 |
* ``` |
| 2632 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "createAttributes", { |
| 2633 |
table: { |
| 2634 |
style: 'border-collapse:collapse;width: 100%;' |
| 2635 |
} |
| 2636 |
}); |
| 2637 |
/** |
| 2638 |
* The width of the editor, accepted as the biggest. Used to the responsive version of the editor |
| 2639 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "sizeLG", 900); |
| 2640 |
/** |
| 2641 |
* The width of the editor, accepted as the medium. Used to the responsive version of the editor |
| 2642 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "sizeMD", 700); |
| 2643 |
/** |
| 2644 |
* The width of the editor, accepted as the small. Used to the responsive version of the editor |
| 2645 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "sizeSM", 400); |
| 2646 |
/** |
| 2647 |
* The list of buttons that appear in the editor's toolbar on large places (≥ options.sizeLG). |
| 2648 |
* Note - this is not the width of the device, the width of the editor |
| 2649 |
* |
| 2650 |
* ```javascript |
| 2651 |
* Jodit.make('#editor', { |
| 2652 |
* buttons: ['bold', 'italic', 'source'], |
| 2653 |
* buttonsMD: ['bold', 'italic'], |
| 2654 |
* buttonsXS: ['bold', 'fullsize'], |
| 2655 |
* }); |
| 2656 |
* ``` |
| 2657 |
* |
| 2658 |
* ```javascript |
| 2659 |
* Jodit.make('#editor2', { |
| 2660 |
* buttons: [{ |
| 2661 |
* name: 'empty', |
| 2662 |
* icon: 'source', |
| 2663 |
* exec: function (editor) { |
| 2664 |
* const dialog = new Jodit.modules.Dialog({}), |
| 2665 |
* text = editor.c.element('textarea'); |
| 2666 |
* |
| 2667 |
* dialog.setHeader('Source code'); |
| 2668 |
* dialog.setContent(text); |
| 2669 |
* dialog.setSize(400, 300); |
| 2670 |
* |
| 2671 |
* Jodit.modules.Helpers.css(elm, { |
| 2672 |
* width: '100%', |
| 2673 |
* height: '100%' |
| 2674 |
* }) |
| 2675 |
|
| 2676 |
* dialog.open(); |
| 2677 |
* } |
| 2678 |
* }] |
| 2679 |
* }); |
| 2680 |
* ``` |
| 2681 |
* |
| 2682 |
* ```javascript |
| 2683 |
* Jodit.make('#editor2', { |
| 2684 |
* buttons: Jodit.defaultOptions.buttons.concat([{ |
| 2685 |
* name: 'listsss', |
| 2686 |
* iconURL: 'stuf/dummy.png', |
| 2687 |
* list: { |
| 2688 |
* h1: 'insert Header 1', |
| 2689 |
* h2: 'insert Header 2', |
| 2690 |
* clear: 'Empty editor', |
| 2691 |
* }, |
| 2692 |
* exec: ({originalEvent, control, btn}) => { |
| 2693 |
* var key = control.args[0], |
| 2694 |
* value = control.args[1]; |
| 2695 |
* if (key === 'clear') { |
| 2696 |
* this.val(''); |
| 2697 |
* return; |
| 2698 |
* } |
| 2699 |
* this.s.insertNode(this.c.element(key, '')); |
| 2700 |
* this.message.info('Was inserted ' + value); |
| 2701 |
* }, |
| 2702 |
* template: function (key, value) { |
| 2703 |
* return '<div>' + value + '</div>'; |
| 2704 |
* } |
| 2705 |
* }); |
| 2706 |
* ``` |
| 2707 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "buttons", [ |
| 2708 |
{ |
| 2709 |
group: 'font-style', |
| 2710 |
buttons: [] |
| 2711 |
}, |
| 2712 |
{ |
| 2713 |
group: 'list', |
| 2714 |
buttons: [] |
| 2715 |
}, |
| 2716 |
{ |
| 2717 |
group: 'font', |
| 2718 |
buttons: [] |
| 2719 |
}, |
| 2720 |
'---', |
| 2721 |
{ |
| 2722 |
group: 'script', |
| 2723 |
buttons: [] |
| 2724 |
}, |
| 2725 |
{ |
| 2726 |
group: 'media', |
| 2727 |
buttons: [] |
| 2728 |
}, |
| 2729 |
'\n', |
| 2730 |
{ |
| 2731 |
group: 'state', |
| 2732 |
buttons: [] |
| 2733 |
}, |
| 2734 |
{ |
| 2735 |
group: 'clipboard', |
| 2736 |
buttons: [] |
| 2737 |
}, |
| 2738 |
{ |
| 2739 |
group: 'insert', |
| 2740 |
buttons: [] |
| 2741 |
}, |
| 2742 |
{ |
| 2743 |
group: 'indent', |
| 2744 |
buttons: [] |
| 2745 |
}, |
| 2746 |
{ |
| 2747 |
group: 'color', |
| 2748 |
buttons: [] |
| 2749 |
}, |
| 2750 |
{ |
| 2751 |
group: 'form', |
| 2752 |
buttons: [] |
| 2753 |
}, |
| 2754 |
'---', |
| 2755 |
{ |
| 2756 |
group: 'history', |
| 2757 |
buttons: [] |
| 2758 |
}, |
| 2759 |
{ |
| 2760 |
group: 'search', |
| 2761 |
buttons: [] |
| 2762 |
}, |
| 2763 |
{ |
| 2764 |
group: 'source', |
| 2765 |
buttons: [] |
| 2766 |
}, |
| 2767 |
{ |
| 2768 |
group: 'other', |
| 2769 |
buttons: [] |
| 2770 |
}, |
| 2771 |
{ |
| 2772 |
group: 'info', |
| 2773 |
buttons: [] |
| 2774 |
} |
| 2775 |
]); |
| 2776 |
/** |
| 2777 |
* Map of toolbar button names to their control definitions (icon, tooltip, exec handler, etc.). |
| 2778 |
* Plugins extend this object with their own button definitions via `Config.prototype.controls`. |
| 2779 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "controls", void 0); |
| 2780 |
/** |
| 2781 |
* Some events are called when the editor is initialized, for example, the `afterInit` event. |
| 2782 |
* So this code won't work: |
| 2783 |
* ```javascript |
| 2784 |
* const editor = Jodit.make('#editor'); |
| 2785 |
* editor.events.on('afterInit', () => console.log('afterInit')); |
| 2786 |
* ``` |
| 2787 |
* You need to do this: |
| 2788 |
* ```javascript |
| 2789 |
* Jodit.make('#editor', { |
| 2790 |
* events: { |
| 2791 |
* afterInit: () => console.log('afterInit') |
| 2792 |
* } |
| 2793 |
* }); |
| 2794 |
* ``` |
| 2795 |
* The option can use any Jodit events, for example: |
| 2796 |
* ```javascript |
| 2797 |
* const editor = Jodit.make('#editor', { |
| 2798 |
* events: { |
| 2799 |
* hello: (name) => console.log('Hello', name) |
| 2800 |
* } |
| 2801 |
* }); |
| 2802 |
* editor.e.fire('hello', 'Mike'); |
| 2803 |
* ``` |
| 2804 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "events", {}); |
| 2805 |
/** |
| 2806 |
* Buttons in toolbar without SVG - only texts |
| 2807 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "textIcons", false); |
| 2808 |
/** |
| 2809 |
* Element for dialog container |
| 2810 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "popupRoot", null); |
| 2811 |
/** |
| 2812 |
* shows a INPUT[type=color] to open the browser color picker, on the right bottom of widget color picker |
| 2813 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "showBrowserColorPicker", true); |
| 2814 |
Object.assign(this, ConfigPrototype); |
| 2815 |
} |
| 2816 |
} |
| 2817 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(Config, "__defaultOptions", void 0); |
| 2818 |
ConfigPrototype = Config.prototype; |
| 2819 |
Config.prototype.controls = {}; |
| 2820 |
|
| 2821 |
|
| 2822 |
|
| 2823 |
/***/ }), |
| 2824 |
|
| 2825 |
/***/ 5650: |
| 2826 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 2827 |
|
| 2828 |
"use strict"; |
| 2829 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 2830 |
/* harmony export */ getHash: function() { return /* binding */ getHash; } |
| 2831 |
/* harmony export */ }); |
| 2832 |
/* harmony import */ var jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(85932); |
| 2833 |
/* harmony import */ var jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(4040); |
| 2834 |
/*! |
| 2835 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 2836 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 2837 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 2838 |
*/ /** |
| 2839 |
* @module plugins/clean-html |
| 2840 |
*/ |
| 2841 |
|
| 2842 |
/** |
| 2843 |
* @private |
| 2844 |
*/ function getHash(tags) { |
| 2845 |
const attributesReg = /([^[]*)\[([^\]]+)]/; |
| 2846 |
const separator = /[\s]*,[\s]*/, attrReg = /^(.*)[\s]*=[\s]*(.*)$/; |
| 2847 |
const tagsHash = {}; |
| 2848 |
if ((0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_0__.isString)(tags)) { |
| 2849 |
tags.split(separator).map((elm)=>{ |
| 2850 |
elm = (0,jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_1__.trim)(elm); |
| 2851 |
const attr = attributesReg.exec(elm), allowAttributes = {}, attributeMap = (attrName)=>{ |
| 2852 |
attrName = (0,jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_1__.trim)(attrName); |
| 2853 |
const val = attrReg.exec(attrName); |
| 2854 |
if (val) { |
| 2855 |
allowAttributes[val[1]] = val[2]; |
| 2856 |
} else { |
| 2857 |
allowAttributes[attrName] = true; |
| 2858 |
} |
| 2859 |
}; |
| 2860 |
if (attr) { |
| 2861 |
const attr2 = attr[2].split(separator); |
| 2862 |
if (attr[1]) { |
| 2863 |
attr2.forEach(attributeMap); |
| 2864 |
tagsHash[attr[1].toUpperCase()] = allowAttributes; |
| 2865 |
} |
| 2866 |
} else { |
| 2867 |
tagsHash[elm.toUpperCase()] = true; |
| 2868 |
} |
| 2869 |
}); |
| 2870 |
return tagsHash; |
| 2871 |
} |
| 2872 |
if (tags) { |
| 2873 |
Object.keys(tags).forEach((tagName)=>{ |
| 2874 |
tagsHash[tagName.toUpperCase()] = tags[tagName]; |
| 2875 |
}); |
| 2876 |
return tagsHash; |
| 2877 |
} |
| 2878 |
return false; |
| 2879 |
} |
| 2880 |
|
| 2881 |
|
| 2882 |
/***/ }), |
| 2883 |
|
| 2884 |
/***/ 5658: |
| 2885 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 2886 |
|
| 2887 |
"use strict"; |
| 2888 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 2889 |
/* harmony export */ UIBlock: function() { return /* reexport safe */ _block_block__WEBPACK_IMPORTED_MODULE_0__.UIBlock; }, |
| 2890 |
/* harmony export */ UICheckbox: function() { return /* reexport safe */ _inputs__WEBPACK_IMPORTED_MODULE_2__.UICheckbox; }, |
| 2891 |
/* harmony export */ UIFileInput: function() { return /* reexport safe */ _inputs__WEBPACK_IMPORTED_MODULE_2__.UIFileInput; }, |
| 2892 |
/* harmony export */ UIForm: function() { return /* reexport safe */ _form__WEBPACK_IMPORTED_MODULE_1__.UIForm; }, |
| 2893 |
/* harmony export */ UIInput: function() { return /* reexport safe */ _inputs__WEBPACK_IMPORTED_MODULE_2__.UIInput; }, |
| 2894 |
/* harmony export */ UISelect: function() { return /* reexport safe */ _inputs__WEBPACK_IMPORTED_MODULE_2__.UISelect; }, |
| 2895 |
/* harmony export */ UITextArea: function() { return /* reexport safe */ _inputs__WEBPACK_IMPORTED_MODULE_2__.UITextArea; } |
| 2896 |
/* harmony export */ }); |
| 2897 |
/* harmony import */ var _block_block__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(4561); |
| 2898 |
/* harmony import */ var _form__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(98838); |
| 2899 |
/* harmony import */ var _inputs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2602); |
| 2900 |
/*! |
| 2901 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 2902 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 2903 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 2904 |
*/ /** |
| 2905 |
* @module ui/form |
| 2906 |
*/ |
| 2907 |
|
| 2908 |
|
| 2909 |
|
| 2910 |
|
| 2911 |
/***/ }), |
| 2912 |
|
| 2913 |
/***/ 5771: |
| 2914 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 2915 |
|
| 2916 |
"use strict"; |
| 2917 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 2918 |
/* harmony export */ checkRemoveEmptyNeighbor: function() { return /* binding */ checkRemoveEmptyNeighbor; } |
| 2919 |
/* harmony export */ }); |
| 2920 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 2921 |
/*! |
| 2922 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 2923 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 2924 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 2925 |
*/ /** |
| 2926 |
* @module plugins/backspace |
| 2927 |
*/ |
| 2928 |
/** |
| 2929 |
* Check if it is possible to remove an empty adjacent element. |
| 2930 |
* |
| 2931 |
* @example |
| 2932 |
* ```html |
| 2933 |
* <p><br></p><p>|second stop</p> |
| 2934 |
* ``` |
| 2935 |
* result |
| 2936 |
* ```html |
| 2937 |
* <p>|second stop</p> |
| 2938 |
* ``` |
| 2939 |
* @private |
| 2940 |
*/ function checkRemoveEmptyNeighbor(jodit, fakeNode, backspace) { |
| 2941 |
const parent = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(fakeNode, jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isElement, jodit.editor); |
| 2942 |
if (!parent) { |
| 2943 |
return false; |
| 2944 |
} |
| 2945 |
const neighbor = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.findNotEmptySibling(parent, backspace); |
| 2946 |
if (neighbor && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isEmpty(neighbor)) { |
| 2947 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(neighbor); |
| 2948 |
jodit.s.setCursorBefore(fakeNode); |
| 2949 |
return true; |
| 2950 |
} |
| 2951 |
return false; |
| 2952 |
} |
| 2953 |
|
| 2954 |
|
| 2955 |
/***/ }), |
| 2956 |
|
| 2957 |
/***/ 5772: |
| 2958 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 2959 |
|
| 2960 |
"use strict"; |
| 2961 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 2962 |
/* harmony export */ ToolbarContent: function() { return /* binding */ ToolbarContent; } |
| 2963 |
/* harmony export */ }); |
| 2964 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 2965 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 2966 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(84839); |
| 2967 |
/* harmony import */ var jodit_core_dom__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(27795); |
| 2968 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(65946); |
| 2969 |
/* harmony import */ var jodit_core_ui_button__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(59400); |
| 2970 |
/*! |
| 2971 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 2972 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 2973 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 2974 |
*/ /** |
| 2975 |
* @module modules/toolbar/button |
| 2976 |
*/ |
| 2977 |
|
| 2978 |
|
| 2979 |
|
| 2980 |
|
| 2981 |
|
| 2982 |
|
| 2983 |
class ToolbarContent extends jodit_core_ui_button__WEBPACK_IMPORTED_MODULE_5__.UIButton { |
| 2984 |
/** @override */ className() { |
| 2985 |
return 'ToolbarContent'; |
| 2986 |
} |
| 2987 |
/** @override */ update() { |
| 2988 |
const content = this.control.getContent(this.j, this); |
| 2989 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.isString)(content) || content.parentNode !== this.container) { |
| 2990 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.detach(this.container); |
| 2991 |
this.container.appendChild((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.isString)(content) ? this.j.create.fromHTML(content) : content); |
| 2992 |
} |
| 2993 |
super.update(); |
| 2994 |
} |
| 2995 |
/** @override */ createContainer() { |
| 2996 |
return this.j.c.span(this.componentName); |
| 2997 |
} |
| 2998 |
constructor(jodit, control, target = null){ |
| 2999 |
super(jodit), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "control", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "target", void 0), this.control = control, this.target = target; |
| 3000 |
this.container.classList.add(`${this.componentName}_${this.clearName(control.name)}`); |
| 3001 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.attr)(this.container, 'role', 'content'); |
| 3002 |
} |
| 3003 |
} |
| 3004 |
ToolbarContent = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 3005 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.component |
| 3006 |
], ToolbarContent); |
| 3007 |
|
| 3008 |
|
| 3009 |
/***/ }), |
| 3010 |
|
| 3011 |
/***/ 6209: |
| 3012 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 3013 |
|
| 3014 |
"use strict"; |
| 3015 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 3016 |
/* harmony export */ ToolbarEditorCollection: function() { return /* binding */ ToolbarEditorCollection; } |
| 3017 |
/* harmony export */ }); |
| 3018 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 3019 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 3020 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(81937); |
| 3021 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(84839); |
| 3022 |
/* harmony import */ var jodit_core_dom__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(27795); |
| 3023 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(65946); |
| 3024 |
/* harmony import */ var _collection__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(42573); |
| 3025 |
/*! |
| 3026 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 3027 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 3028 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 3029 |
*/ /** |
| 3030 |
* @module modules/toolbar/collection |
| 3031 |
*/ |
| 3032 |
|
| 3033 |
|
| 3034 |
|
| 3035 |
|
| 3036 |
|
| 3037 |
|
| 3038 |
class ToolbarEditorCollection extends _collection__WEBPACK_IMPORTED_MODULE_6__.ToolbarCollection { |
| 3039 |
/** @override */ className() { |
| 3040 |
return 'ToolbarEditorCollection'; |
| 3041 |
} |
| 3042 |
/** @override */ shouldBeDisabled(button) { |
| 3043 |
const disabled = super.shouldBeDisabled(button); |
| 3044 |
if (disabled !== undefined) { |
| 3045 |
return disabled; |
| 3046 |
} |
| 3047 |
const mode = button.control.mode === undefined ? jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.MODE_WYSIWYG : button.control.mode; |
| 3048 |
return !(mode === jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.MODE_SPLIT || mode === this.j.getRealMode()); |
| 3049 |
} |
| 3050 |
/** @override */ shouldBeActive(button) { |
| 3051 |
const active = super.shouldBeActive(button); |
| 3052 |
if (active !== undefined) { |
| 3053 |
return active; |
| 3054 |
} |
| 3055 |
const element = this.j.selection ? this.j.s.current() : null; |
| 3056 |
if (!element) { |
| 3057 |
return false; |
| 3058 |
} |
| 3059 |
let elm; |
| 3060 |
if (button.control.tags) { |
| 3061 |
const tags = button.control.tags; |
| 3062 |
elm = element; |
| 3063 |
if (jodit_core_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.up(elm, (node)=>{ |
| 3064 |
if (node && tags.indexOf(node.nodeName.toLowerCase()) !== -1) { |
| 3065 |
return true; |
| 3066 |
} |
| 3067 |
}, this.j.editor)) { |
| 3068 |
return true; |
| 3069 |
} |
| 3070 |
} |
| 3071 |
// activate by supposed css |
| 3072 |
if (button.control.css) { |
| 3073 |
const css = button.control.css; |
| 3074 |
elm = element; |
| 3075 |
if (jodit_core_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.up(elm, (node)=>{ |
| 3076 |
if (node && !jodit_core_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isText(node) && !jodit_core_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isComment(node)) { |
| 3077 |
return this.checkActiveStatus(css, node); |
| 3078 |
} |
| 3079 |
}, this.j.editor)) { |
| 3080 |
return true; |
| 3081 |
} |
| 3082 |
} |
| 3083 |
return false; |
| 3084 |
} |
| 3085 |
/** @override */ getTarget(button) { |
| 3086 |
return button.target || this.j.s.current() || null; |
| 3087 |
} |
| 3088 |
/** |
| 3089 |
* Adds an invisible element to the container that can handle the |
| 3090 |
* situation when the editor is inside the <label> |
| 3091 |
* |
| 3092 |
* @see https://github.com/jodit/jodit-react/issues/138 |
| 3093 |
*/ prependInvisibleInput(container) { |
| 3094 |
const input = this.j.create.element('input', { |
| 3095 |
name: 'jodit-toolbar-focus-helper_' + this.j.id, |
| 3096 |
tabIndex: -1, |
| 3097 |
disabled: true, |
| 3098 |
style: 'width: 0; height:0; position: absolute; visibility: hidden;' |
| 3099 |
}); |
| 3100 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.appendChildFirst(container, input); |
| 3101 |
} |
| 3102 |
/** |
| 3103 |
* Show the inline toolbar inside WYSIWYG editor. |
| 3104 |
* @param bound - you can set the place for displaying the toolbar, |
| 3105 |
* or the place will be in the place of the cursor |
| 3106 |
*/ showInline(bound) { |
| 3107 |
this.jodit.e.fire('showInlineToolbar', bound); |
| 3108 |
} |
| 3109 |
hide() { |
| 3110 |
this.jodit.e.fire('hidePopup'); |
| 3111 |
super.hide(); |
| 3112 |
this.jodit.e.fire('toggleToolbar'); |
| 3113 |
} |
| 3114 |
show() { |
| 3115 |
super.show(); |
| 3116 |
this.jodit.e.fire('toggleToolbar'); |
| 3117 |
} |
| 3118 |
/** @override */ constructor(jodit){ |
| 3119 |
super(jodit), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "checkActiveStatus", (cssObject, node)=>{ |
| 3120 |
let matches = 0, total = 0; |
| 3121 |
Object.keys(cssObject).forEach((cssProperty)=>{ |
| 3122 |
const cssValue = cssObject[cssProperty]; |
| 3123 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.isFunction)(cssValue)) { |
| 3124 |
if (cssValue(this.j, (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.css)(node, cssProperty).toString())) { |
| 3125 |
matches += 1; |
| 3126 |
} |
| 3127 |
} else { |
| 3128 |
if (cssValue.indexOf((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.css)(node, cssProperty).toString()) !== -1) { |
| 3129 |
matches += 1; |
| 3130 |
} |
| 3131 |
} |
| 3132 |
total += 1; |
| 3133 |
}); |
| 3134 |
return total === matches; |
| 3135 |
}); |
| 3136 |
this.prependInvisibleInput(this.container); |
| 3137 |
} |
| 3138 |
} |
| 3139 |
ToolbarEditorCollection = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 3140 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.component |
| 3141 |
], ToolbarEditorCollection); |
| 3142 |
|
| 3143 |
|
| 3144 |
/***/ }), |
| 3145 |
|
| 3146 |
/***/ 6490: |
| 3147 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 3148 |
|
| 3149 |
"use strict"; |
| 3150 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 3151 |
/* harmony export */ required: function() { return /* binding */ required; } |
| 3152 |
/* harmony export */ }); |
| 3153 |
/* harmony import */ var jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(4040); |
| 3154 |
/*! |
| 3155 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 3156 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 3157 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 3158 |
*/ /** |
| 3159 |
* @module ui/form |
| 3160 |
*/ |
| 3161 |
/** |
| 3162 |
* Select is required |
| 3163 |
*/ const required = function(select) { |
| 3164 |
if (!(0,jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_0__.trim)(select.value).length) { |
| 3165 |
select.error = 'Please fill out this field'; |
| 3166 |
return false; |
| 3167 |
} |
| 3168 |
return true; |
| 3169 |
}; |
| 3170 |
|
| 3171 |
|
| 3172 |
/***/ }), |
| 3173 |
|
| 3174 |
/***/ 6609: |
| 3175 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 3176 |
|
| 3177 |
"use strict"; |
| 3178 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 3179 |
/* harmony export */ htmlspecialchars: function() { return /* binding */ htmlspecialchars; } |
| 3180 |
/* harmony export */ }); |
| 3181 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 3182 |
/*! |
| 3183 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 3184 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 3185 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 3186 |
*/ /** |
| 3187 |
* @module helpers/html |
| 3188 |
*/ |
| 3189 |
/** |
| 3190 |
* Convert special characters to HTML entities |
| 3191 |
*/ function htmlspecialchars(html) { |
| 3192 |
const tmp = jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.globalDocument.createElement('div'); |
| 3193 |
tmp.textContent = html; |
| 3194 |
return tmp.innerHTML; |
| 3195 |
} |
| 3196 |
|
| 3197 |
|
| 3198 |
/***/ }), |
| 3199 |
|
| 3200 |
/***/ 7018: |
| 3201 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 3202 |
|
| 3203 |
"use strict"; |
| 3204 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 3205 |
/* harmony export */ colorToHex: function() { return /* reexport safe */ _color_to_hex__WEBPACK_IMPORTED_MODULE_0__.colorToHex; } |
| 3206 |
/* harmony export */ }); |
| 3207 |
/* harmony import */ var _color_to_hex__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(93387); |
| 3208 |
/*! |
| 3209 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 3210 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 3211 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 3212 |
*/ /** |
| 3213 |
* @module helpers/color |
| 3214 |
*/ |
| 3215 |
|
| 3216 |
|
| 3217 |
/***/ }), |
| 3218 |
|
| 3219 |
/***/ 7433: |
| 3220 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 3221 |
|
| 3222 |
"use strict"; |
| 3223 |
/* harmony import */ var _swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(41411); |
| 3224 |
/* harmony import */ var _swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(15366); |
| 3225 |
/* harmony import */ var jodit_core_dom__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(27795); |
| 3226 |
/* harmony import */ var jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(4040); |
| 3227 |
/* harmony import */ var jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(80991); |
| 3228 |
/* harmony import */ var jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(29434); |
| 3229 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(5266); |
| 3230 |
/* harmony import */ var _icons_font_svg__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(48842); |
| 3231 |
/* harmony import */ var _icons_font_svg__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(_icons_font_svg__WEBPACK_IMPORTED_MODULE_7__); |
| 3232 |
/* harmony import */ var _icons_fontsize_svg__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(25501); |
| 3233 |
/* harmony import */ var _icons_fontsize_svg__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(_icons_fontsize_svg__WEBPACK_IMPORTED_MODULE_8__); |
| 3234 |
/*! |
| 3235 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 3236 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 3237 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 3238 |
*/ /** |
| 3239 |
* @module plugins/font |
| 3240 |
*/ |
| 3241 |
|
| 3242 |
|
| 3243 |
|
| 3244 |
|
| 3245 |
|
| 3246 |
|
| 3247 |
|
| 3248 |
|
| 3249 |
/** |
| 3250 |
* Default font-size points |
| 3251 |
*/ jodit_config__WEBPACK_IMPORTED_MODULE_6__.Config.prototype.defaultFontSizePoints = 'px'; |
| 3252 |
jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_5__.Icon.set('font', (_icons_font_svg__WEBPACK_IMPORTED_MODULE_7___default())).set('fontsize', (_icons_fontsize_svg__WEBPACK_IMPORTED_MODULE_8___default())); |
| 3253 |
jodit_config__WEBPACK_IMPORTED_MODULE_6__.Config.prototype.controls.fontsize = { |
| 3254 |
command: 'fontsize', |
| 3255 |
data: { |
| 3256 |
cssRule: 'font-size', |
| 3257 |
normalise: (v, editor)=>{ |
| 3258 |
if (/pt$/i.test(v) && editor.o.defaultFontSizePoints === 'pt') { |
| 3259 |
return v.replace(/pt$/i, ''); |
| 3260 |
} |
| 3261 |
return v; |
| 3262 |
} |
| 3263 |
}, |
| 3264 |
list: [ |
| 3265 |
8, |
| 3266 |
9, |
| 3267 |
10, |
| 3268 |
11, |
| 3269 |
12, |
| 3270 |
14, |
| 3271 |
16, |
| 3272 |
18, |
| 3273 |
24, |
| 3274 |
30, |
| 3275 |
32, |
| 3276 |
34, |
| 3277 |
36, |
| 3278 |
48, |
| 3279 |
60, |
| 3280 |
72, |
| 3281 |
96 |
| 3282 |
], |
| 3283 |
textTemplate: (editor, value)=>{ |
| 3284 |
return value + editor.o.defaultFontSizePoints; |
| 3285 |
}, |
| 3286 |
childTemplate: (editor, key, value)=>{ |
| 3287 |
return `${value}${editor.o.defaultFontSizePoints}`; |
| 3288 |
}, |
| 3289 |
tooltip: 'Font size', |
| 3290 |
value: (editor, button)=>{ |
| 3291 |
var _control_data; |
| 3292 |
const current = editor.s.current(); |
| 3293 |
if (!current) { |
| 3294 |
return; |
| 3295 |
} |
| 3296 |
const box = jodit_core_dom__WEBPACK_IMPORTED_MODULE_2__.Dom.closest(current, jodit_core_dom__WEBPACK_IMPORTED_MODULE_2__.Dom.isElement, editor.editor); |
| 3297 |
if (!box) { |
| 3298 |
return; |
| 3299 |
} |
| 3300 |
const control = button.control; |
| 3301 |
const cssKey = ((_control_data = control.data) === null || _control_data === void 0 ? void 0 : _control_data.cssRule) || 'font-size'; |
| 3302 |
const value = (0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_4__.css)(box, cssKey); |
| 3303 |
return value.toString(); |
| 3304 |
}, |
| 3305 |
isChildActive: (editor, button)=>{ |
| 3306 |
var _ref; |
| 3307 |
var _button_control_data; |
| 3308 |
const value = button.state.value; |
| 3309 |
const normalize = (_ref = (_button_control_data = button.control.data) === null || _button_control_data === void 0 ? void 0 : _button_control_data.normalize) !== null && _ref !== void 0 ? _ref : (v)=>v; |
| 3310 |
return Boolean(value && button.control.args && normalize(button.control.args[0].toString()) === normalize(value.toString())); |
| 3311 |
}, |
| 3312 |
isActive: (editor, button)=>{ |
| 3313 |
var _ref; |
| 3314 |
var _button_control_data; |
| 3315 |
const value = button.state.value; |
| 3316 |
if (!value) { |
| 3317 |
return false; |
| 3318 |
} |
| 3319 |
const normalize = (_ref = (_button_control_data = button.control.data) === null || _button_control_data === void 0 ? void 0 : _button_control_data.normalize) !== null && _ref !== void 0 ? _ref : (v)=>v; |
| 3320 |
let keySet = button.control.data.cacheListSet; |
| 3321 |
if (!keySet) { |
| 3322 |
const keys = Object.keys(button.control.list).map(normalize); |
| 3323 |
keySet = new Set(keys); |
| 3324 |
button.control.data.cacheListSet = keySet; |
| 3325 |
} |
| 3326 |
return keySet.has(normalize(value.toString())); |
| 3327 |
} |
| 3328 |
}; |
| 3329 |
jodit_config__WEBPACK_IMPORTED_MODULE_6__.Config.prototype.controls.font = (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_1__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__._)({}, jodit_config__WEBPACK_IMPORTED_MODULE_6__.Config.prototype.controls.fontsize), { |
| 3330 |
command: 'fontname', |
| 3331 |
textTemplate: (j, value)=>{ |
| 3332 |
const [first] = value.split(','); |
| 3333 |
return (0,jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_3__.trimChars)(first, '"\''); |
| 3334 |
}, |
| 3335 |
list: { |
| 3336 |
'': 'Default', |
| 3337 |
'Arial, Helvetica, sans-serif': 'Arial', |
| 3338 |
"'Courier New', Courier, monospace": 'Courier New', |
| 3339 |
'Georgia, Palatino, serif': 'Georgia', |
| 3340 |
"'Lucida Sans Unicode', 'Lucida Grande', sans-serif": 'Lucida Sans Unicode', |
| 3341 |
'Tahoma, Geneva, sans-serif': 'Tahoma', |
| 3342 |
"'Times New Roman', Times, serif": 'Times New Roman', |
| 3343 |
"'Trebuchet MS', Helvetica, sans-serif": 'Trebuchet MS', |
| 3344 |
'Helvetica, sans-serif': 'Helvetica', |
| 3345 |
'Impact, Charcoal, sans-serif': 'Impact', |
| 3346 |
'Verdana, Geneva, sans-serif': 'Verdana' |
| 3347 |
}, |
| 3348 |
childTemplate: (editor, key, value)=>{ |
| 3349 |
let isAvailable = false; |
| 3350 |
try { |
| 3351 |
isAvailable = key.indexOf('dings') === -1 && document.fonts.check(`16px ${key}`, value); |
| 3352 |
} catch (unused) {} |
| 3353 |
return `<span data-style="${key}" style="${isAvailable ? `font-family: ${key}!important;` : ''}">${value}</span>`; |
| 3354 |
}, |
| 3355 |
data: { |
| 3356 |
cssRule: 'font-family', |
| 3357 |
normalize: (v)=>{ |
| 3358 |
return v.toLowerCase().replace(/['"]+/g, '').replace(/[^a-z0-9-]+/g, ','); |
| 3359 |
} |
| 3360 |
}, |
| 3361 |
tooltip: 'Font family' |
| 3362 |
}); |
| 3363 |
|
| 3364 |
|
| 3365 |
/***/ }), |
| 3366 |
|
| 3367 |
/***/ 7470: |
| 3368 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 3369 |
|
| 3370 |
"use strict"; |
| 3371 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 3372 |
/* harmony export */ moveTheNodeAlongTheEdgeOutward: function() { return /* binding */ moveTheNodeAlongTheEdgeOutward; } |
| 3373 |
/* harmony export */ }); |
| 3374 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 3375 |
/*! |
| 3376 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 3377 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 3378 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 3379 |
*/ /** |
| 3380 |
* @module selection |
| 3381 |
*/ |
| 3382 |
/** |
| 3383 |
* Moves the fake node up until it encounters a non-empty sibling on the left(right) |
| 3384 |
* @private |
| 3385 |
*/ function moveTheNodeAlongTheEdgeOutward(node, start, root) { |
| 3386 |
let item = node; |
| 3387 |
while(item && item !== root){ |
| 3388 |
const sibling = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.findSibling(item, start); |
| 3389 |
if (sibling) { |
| 3390 |
return; |
| 3391 |
} |
| 3392 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isBlock(item.parentElement)) { |
| 3393 |
break; |
| 3394 |
} |
| 3395 |
item = item.parentElement; |
| 3396 |
if (item && item !== root) { |
| 3397 |
start ? jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.before(item, node) : jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.after(item, node); |
| 3398 |
} |
| 3399 |
} |
| 3400 |
return; |
| 3401 |
} |
| 3402 |
|
| 3403 |
|
| 3404 |
/***/ }), |
| 3405 |
|
| 3406 |
/***/ 7909: |
| 3407 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 3408 |
|
| 3409 |
"use strict"; |
| 3410 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 3411 |
/* harmony export */ attr: function() { return /* binding */ attr; } |
| 3412 |
/* harmony export */ }); |
| 3413 |
/* harmony import */ var jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(91565); |
| 3414 |
/* harmony import */ var jodit_core_helpers_checker_is_plain_object__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(62101); |
| 3415 |
/* harmony import */ var jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(85932); |
| 3416 |
/* harmony import */ var jodit_core_helpers_string_kebab_case__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(74264); |
| 3417 |
/* harmony import */ var _css__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(80991); |
| 3418 |
/*! |
| 3419 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 3420 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 3421 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 3422 |
*/ /** |
| 3423 |
* @module helpers/utils |
| 3424 |
*/ |
| 3425 |
|
| 3426 |
|
| 3427 |
|
| 3428 |
|
| 3429 |
/** |
| 3430 |
* Alias for `elm.getAttribute` but if set second argument `-{key}` |
| 3431 |
* it will also check `data-{key}` attribute |
| 3432 |
* if set `value` it is alias for setAttribute with the same logic |
| 3433 |
*/ function attr(elm, keyOrAttributes, value) { |
| 3434 |
if (!elm || !(0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_0__.isFunction)(elm.getAttribute)) { |
| 3435 |
return null; |
| 3436 |
} |
| 3437 |
if (!(0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_2__.isString)(keyOrAttributes)) { |
| 3438 |
Object.keys(keyOrAttributes).forEach((key)=>{ |
| 3439 |
const value = keyOrAttributes[key]; |
| 3440 |
if ((0,jodit_core_helpers_checker_is_plain_object__WEBPACK_IMPORTED_MODULE_1__.isPlainObject)(value) && key === 'style') { |
| 3441 |
(0,_css__WEBPACK_IMPORTED_MODULE_4__.css)(elm, value); |
| 3442 |
} else { |
| 3443 |
if (key === 'className') { |
| 3444 |
key = 'class'; |
| 3445 |
} |
| 3446 |
attr(elm, key, value); |
| 3447 |
} |
| 3448 |
}); |
| 3449 |
return null; |
| 3450 |
} |
| 3451 |
let key = (0,jodit_core_helpers_string_kebab_case__WEBPACK_IMPORTED_MODULE_3__.CamelCaseToKebabCase)(keyOrAttributes); |
| 3452 |
if (/^-/.test(key)) { |
| 3453 |
const res = attr(elm, `data${key}`); |
| 3454 |
if (res) { |
| 3455 |
return res; |
| 3456 |
} |
| 3457 |
key = key.substr(1); |
| 3458 |
} |
| 3459 |
if (value !== undefined) { |
| 3460 |
if (value == null) { |
| 3461 |
elm.hasAttribute(key) && elm.removeAttribute(key); |
| 3462 |
} else { |
| 3463 |
let replaceValue = value.toString(); |
| 3464 |
if (elm.nodeName === 'IMG' && (key === 'width' || key === 'height')) { |
| 3465 |
replaceValue = replaceValue.replace('px', ''); |
| 3466 |
} |
| 3467 |
elm.setAttribute(key, replaceValue); |
| 3468 |
return replaceValue; |
| 3469 |
} |
| 3470 |
} |
| 3471 |
return elm.getAttribute(key); |
| 3472 |
} |
| 3473 |
|
| 3474 |
|
| 3475 |
/***/ }), |
| 3476 |
|
| 3477 |
/***/ 7994: |
| 3478 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 3479 |
|
| 3480 |
"use strict"; |
| 3481 |
/* unused harmony export table */ |
| 3482 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(28077); |
| 3483 |
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(48290); |
| 3484 |
/*! |
| 3485 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 3486 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 3487 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 3488 |
*/ /** |
| 3489 |
* [[include:plugins/table/README.md]] |
| 3490 |
* @packageDocumentation |
| 3491 |
* @module plugins/table |
| 3492 |
*/ |
| 3493 |
|
| 3494 |
|
| 3495 |
function table(editor) { |
| 3496 |
editor.registerButton({ |
| 3497 |
name: 'table', |
| 3498 |
group: 'insert' |
| 3499 |
}); |
| 3500 |
} |
| 3501 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_0__.pluginSystem.add('table', table); |
| 3502 |
|
| 3503 |
|
| 3504 |
/***/ }), |
| 3505 |
|
| 3506 |
/***/ 8006: |
| 3507 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 3508 |
|
| 3509 |
"use strict"; |
| 3510 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 3511 |
/* harmony export */ AsyncStorage: function() { return /* binding */ AsyncStorage; } |
| 3512 |
/* harmony export */ }); |
| 3513 |
/* harmony import */ var _swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(49376); |
| 3514 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(25045); |
| 3515 |
/* harmony import */ var jodit_core_helpers_string_camel_case__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(57821); |
| 3516 |
/* harmony import */ var _engines_indexed_db_provider__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(91162); |
| 3517 |
/* harmony import */ var _engines_local_storage_provider__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(59807); |
| 3518 |
/* harmony import */ var _engines_memory_storage_provider__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(9505); |
| 3519 |
/* harmony import */ var _storage__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(24475); |
| 3520 |
/*! |
| 3521 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 3522 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 3523 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 3524 |
*/ /** |
| 3525 |
* @module storage |
| 3526 |
*/ |
| 3527 |
|
| 3528 |
|
| 3529 |
|
| 3530 |
|
| 3531 |
|
| 3532 |
|
| 3533 |
class AsyncStorage { |
| 3534 |
set(key, value) { |
| 3535 |
return (0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 3536 |
const provider = yield this.provider; |
| 3537 |
yield provider.set((0,jodit_core_helpers_string_camel_case__WEBPACK_IMPORTED_MODULE_2__.camelCase)(this.prefix + key), value); |
| 3538 |
return this; |
| 3539 |
}).call(this); |
| 3540 |
} |
| 3541 |
delete(key) { |
| 3542 |
return (0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 3543 |
const provider = yield this.provider; |
| 3544 |
yield provider.delete((0,jodit_core_helpers_string_camel_case__WEBPACK_IMPORTED_MODULE_2__.camelCase)(this.prefix + key)); |
| 3545 |
return this; |
| 3546 |
}).call(this); |
| 3547 |
} |
| 3548 |
get(key) { |
| 3549 |
return (0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 3550 |
const provider = yield this.provider; |
| 3551 |
return provider.get((0,jodit_core_helpers_string_camel_case__WEBPACK_IMPORTED_MODULE_2__.camelCase)(this.prefix + key)); |
| 3552 |
}).call(this); |
| 3553 |
} |
| 3554 |
exists(key) { |
| 3555 |
return (0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 3556 |
const provider = yield this.provider; |
| 3557 |
return provider.exists((0,jodit_core_helpers_string_camel_case__WEBPACK_IMPORTED_MODULE_2__.camelCase)(this.prefix + key)); |
| 3558 |
}).call(this); |
| 3559 |
} |
| 3560 |
clear() { |
| 3561 |
return (0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 3562 |
const provider = yield this.provider; |
| 3563 |
yield provider.clear(); |
| 3564 |
return this; |
| 3565 |
}).call(this); |
| 3566 |
} |
| 3567 |
close() { |
| 3568 |
return (0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 3569 |
const provider = yield this.provider; |
| 3570 |
if ('close' in provider && typeof provider.close === 'function') { |
| 3571 |
yield provider.close(); |
| 3572 |
} |
| 3573 |
}).call(this); |
| 3574 |
} |
| 3575 |
static makeStorage(persistentOrStrategy = false, suffix) { |
| 3576 |
let provider = undefined; |
| 3577 |
let storage = null; |
| 3578 |
if (persistentOrStrategy === 'localStorage' || persistentOrStrategy === 'sessionStorage') { |
| 3579 |
if ((0,_engines_local_storage_provider__WEBPACK_IMPORTED_MODULE_4__.canUsePersistentStorage)(persistentOrStrategy)) { |
| 3580 |
provider = new _engines_local_storage_provider__WEBPACK_IMPORTED_MODULE_4__.LocalStorageProvider(_storage__WEBPACK_IMPORTED_MODULE_6__.StorageKey + (suffix || ''), persistentOrStrategy); |
| 3581 |
} |
| 3582 |
} else if (persistentOrStrategy === 'indexedDB' || persistentOrStrategy === true) { |
| 3583 |
provider = (0,_engines_indexed_db_provider__WEBPACK_IMPORTED_MODULE_3__.canUseIndexedDB)().then((canUse)=>canUse ? new _engines_indexed_db_provider__WEBPACK_IMPORTED_MODULE_3__.IndexedDBProvider(_storage__WEBPACK_IMPORTED_MODULE_6__.StorageKey + (suffix || ''), 'keyValueStore') : new _engines_memory_storage_provider__WEBPACK_IMPORTED_MODULE_5__.MemoryStorageProvider()); |
| 3584 |
} |
| 3585 |
if (!provider) { |
| 3586 |
provider = new _engines_memory_storage_provider__WEBPACK_IMPORTED_MODULE_5__.MemoryStorageProvider(); |
| 3587 |
} |
| 3588 |
storage = new AsyncStorage(Promise.resolve(provider), suffix); |
| 3589 |
return storage; |
| 3590 |
} |
| 3591 |
constructor(provider, suffix){ |
| 3592 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(this, "provider", void 0); |
| 3593 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(this, "prefix", void 0); |
| 3594 |
this.provider = provider; |
| 3595 |
this.prefix = _storage__WEBPACK_IMPORTED_MODULE_6__.StorageKey; |
| 3596 |
if (suffix) { |
| 3597 |
this.prefix += suffix; |
| 3598 |
} |
| 3599 |
} |
| 3600 |
} |
| 3601 |
|
| 3602 |
|
| 3603 |
/***/ }), |
| 3604 |
|
| 3605 |
/***/ 8071: |
| 3606 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 3607 |
|
| 3608 |
"use strict"; |
| 3609 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 3610 |
/* harmony import */ var jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(65946); |
| 3611 |
/* harmony import */ var jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(29434); |
| 3612 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5266); |
| 3613 |
/* harmony import */ var jodit_modules_widget__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(15753); |
| 3614 |
/* harmony import */ var _brush_svg__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(45674); |
| 3615 |
/* harmony import */ var _brush_svg__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_brush_svg__WEBPACK_IMPORTED_MODULE_5__); |
| 3616 |
/*! |
| 3617 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 3618 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 3619 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 3620 |
*/ /** |
| 3621 |
* @module plugins/color |
| 3622 |
*/ |
| 3623 |
|
| 3624 |
|
| 3625 |
|
| 3626 |
|
| 3627 |
|
| 3628 |
jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_2__.Icon.set('brush', (_brush_svg__WEBPACK_IMPORTED_MODULE_5___default())); |
| 3629 |
jodit_config__WEBPACK_IMPORTED_MODULE_3__.Config.prototype.controls.brushCell = { |
| 3630 |
isVisible: (editor)=>{ |
| 3631 |
return !editor.o.disablePlugins.includes('color'); |
| 3632 |
}, |
| 3633 |
icon: 'brush', |
| 3634 |
popup: (editor, _, close)=>{ |
| 3635 |
if (!(0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.isJoditObject)(editor)) { |
| 3636 |
return; |
| 3637 |
} |
| 3638 |
const tableModule = editor.getInstance('Table', editor.o), selected = tableModule.getAllSelectedCells(); |
| 3639 |
if (!selected.length) { |
| 3640 |
return false; |
| 3641 |
} |
| 3642 |
const makeColorPicker = (key)=>(0,jodit_modules_widget__WEBPACK_IMPORTED_MODULE_4__.ColorPickerWidget)(editor, (value)=>{ |
| 3643 |
selected.forEach((cell)=>{ |
| 3644 |
(0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.css)(cell, key, value); |
| 3645 |
}); |
| 3646 |
editor.lock(); |
| 3647 |
editor.synchronizeValues(); |
| 3648 |
close(); |
| 3649 |
editor.unlock(); |
| 3650 |
}, (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.css)(selected[0], key)); |
| 3651 |
return (0,jodit_modules_widget__WEBPACK_IMPORTED_MODULE_4__.TabsWidget)(editor, [ |
| 3652 |
{ |
| 3653 |
name: 'Background', |
| 3654 |
content: makeColorPicker('background-color') |
| 3655 |
}, |
| 3656 |
{ |
| 3657 |
name: 'Text', |
| 3658 |
content: makeColorPicker('color') |
| 3659 |
}, |
| 3660 |
{ |
| 3661 |
name: 'Border', |
| 3662 |
content: makeColorPicker('border-color') |
| 3663 |
} |
| 3664 |
]); |
| 3665 |
}, |
| 3666 |
tooltip: 'Background' |
| 3667 |
}; |
| 3668 |
jodit_config__WEBPACK_IMPORTED_MODULE_3__.Config.prototype.controls.brush = { |
| 3669 |
isVisible: (editor)=>{ |
| 3670 |
return !editor.o.disablePlugins.includes('color'); |
| 3671 |
}, |
| 3672 |
update (editor, button) { |
| 3673 |
const color = (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.dataBind)(button, 'color'); |
| 3674 |
const update = (key, value)=>{ |
| 3675 |
if (value && value !== (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.css)(editor.editor, key).toString()) { |
| 3676 |
button.state.icon.fill = value; |
| 3677 |
return; |
| 3678 |
} |
| 3679 |
}; |
| 3680 |
if (color) { |
| 3681 |
const mode = (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.dataBind)(button, 'color'); |
| 3682 |
update(mode === 'color' ? mode : 'background-color', color); |
| 3683 |
return; |
| 3684 |
} |
| 3685 |
const current = editor.s.current(); |
| 3686 |
if (current && !button.state.disabled) { |
| 3687 |
const currentBpx = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(current, jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isElement, editor.editor) || editor.editor; |
| 3688 |
update('color', (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.css)(currentBpx, 'color').toString()); |
| 3689 |
update('background-color', (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.css)(currentBpx, 'background-color').toString()); |
| 3690 |
} |
| 3691 |
button.state.icon.fill = ''; |
| 3692 |
button.state.activated = false; |
| 3693 |
}, |
| 3694 |
popup: (editor, current, close, button)=>{ |
| 3695 |
let colorHEX = '', bg_color = '', tabs = [], currentElement = null; |
| 3696 |
if (current && current !== editor.editor && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isNode(current)) { |
| 3697 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isElement(current) && editor.s.isCollapsed() && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(current, new Set([ |
| 3698 |
'br', |
| 3699 |
'hr' |
| 3700 |
]))) { |
| 3701 |
currentElement = current; |
| 3702 |
} |
| 3703 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.up(current, (node)=>{ |
| 3704 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isHTMLElement(node)) { |
| 3705 |
const color = (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.css)(node, 'color', true), background = (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.css)(node, 'background-color', true); |
| 3706 |
if (color) { |
| 3707 |
colorHEX = color.toString(); |
| 3708 |
return true; |
| 3709 |
} |
| 3710 |
if (background) { |
| 3711 |
bg_color = background.toString(); |
| 3712 |
return true; |
| 3713 |
} |
| 3714 |
} |
| 3715 |
}, editor.editor); |
| 3716 |
} |
| 3717 |
const backgroundTag = (0,jodit_modules_widget__WEBPACK_IMPORTED_MODULE_4__.ColorPickerWidget)(editor, (value)=>{ |
| 3718 |
if (!currentElement) { |
| 3719 |
editor.execCommand('background', false, value); |
| 3720 |
} else { |
| 3721 |
currentElement.style.backgroundColor = value; |
| 3722 |
} |
| 3723 |
(0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.dataBind)(button, 'color', value); |
| 3724 |
(0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.dataBind)(button, 'color-mode', 'background'); |
| 3725 |
close(); |
| 3726 |
}, bg_color); |
| 3727 |
const colorTab = (0,jodit_modules_widget__WEBPACK_IMPORTED_MODULE_4__.ColorPickerWidget)(editor, (value)=>{ |
| 3728 |
if (!currentElement) { |
| 3729 |
editor.execCommand('forecolor', false, value); |
| 3730 |
} else { |
| 3731 |
currentElement.style.color = value; |
| 3732 |
} |
| 3733 |
(0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.dataBind)(button, 'color', value); |
| 3734 |
(0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.dataBind)(button, 'color-mode', 'color'); |
| 3735 |
close(); |
| 3736 |
}, colorHEX); |
| 3737 |
tabs = [ |
| 3738 |
{ |
| 3739 |
name: 'Background', |
| 3740 |
content: backgroundTag |
| 3741 |
}, |
| 3742 |
{ |
| 3743 |
name: 'Text', |
| 3744 |
content: colorTab |
| 3745 |
} |
| 3746 |
]; |
| 3747 |
if (editor.o.colorPickerDefaultTab !== 'background') { |
| 3748 |
tabs = tabs.reverse(); |
| 3749 |
} |
| 3750 |
return (0,jodit_modules_widget__WEBPACK_IMPORTED_MODULE_4__.TabsWidget)(editor, tabs, currentElement); |
| 3751 |
}, |
| 3752 |
exec (jodit, current, { button }) { |
| 3753 |
const mode = (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.dataBind)(button, 'color-mode'), color = (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.dataBind)(button, 'color'); |
| 3754 |
if (!mode) { |
| 3755 |
return false; |
| 3756 |
} |
| 3757 |
if (current && current !== jodit.editor && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isNode(current) && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isElement(current)) { |
| 3758 |
switch(mode){ |
| 3759 |
case 'color': |
| 3760 |
current.style.color = color; |
| 3761 |
break; |
| 3762 |
case 'background': |
| 3763 |
current.style.backgroundColor = color; |
| 3764 |
break; |
| 3765 |
} |
| 3766 |
} else { |
| 3767 |
jodit.execCommand(mode === 'background' ? mode : 'forecolor', false, color); |
| 3768 |
} |
| 3769 |
}, |
| 3770 |
tooltip: 'Fill color or set the text color' |
| 3771 |
}; |
| 3772 |
|
| 3773 |
|
| 3774 |
/***/ }), |
| 3775 |
|
| 3776 |
/***/ 8105: |
| 3777 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 3778 |
|
| 3779 |
"use strict"; |
| 3780 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 3781 |
/* harmony export */ AceEditor: function() { return /* reexport safe */ _ace__WEBPACK_IMPORTED_MODULE_0__.AceEditor; }, |
| 3782 |
/* harmony export */ TextAreaEditor: function() { return /* reexport safe */ _area__WEBPACK_IMPORTED_MODULE_1__.TextAreaEditor; } |
| 3783 |
/* harmony export */ }); |
| 3784 |
/* harmony import */ var _ace__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(94978); |
| 3785 |
/* harmony import */ var _area__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(45844); |
| 3786 |
/*! |
| 3787 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 3788 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 3789 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 3790 |
*/ /** |
| 3791 |
* @module plugins/source |
| 3792 |
*/ |
| 3793 |
// export * from "./custom"; // You can add here another source editor |
| 3794 |
|
| 3795 |
|
| 3796 |
/***/ }), |
| 3797 |
|
| 3798 |
/***/ 8136: |
| 3799 |
/***/ (function(module) { |
| 3800 |
|
| 3801 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M1792 1344v128q0 26-19 45t-45 19h-1664q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1664q26 0 45 19t19 45zm-384-384v128q0 26-19 45t-45 19h-1280q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1280q26 0 45 19t19 45zm256-384v128q0 26-19 45t-45 19h-1536q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1536q26 0 45 19t19 45zm-384-384v128q0 26-19 45t-45 19h-1152q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1152q26 0 45 19t19 45z\"/> </svg>" |
| 3802 |
|
| 3803 |
/***/ }), |
| 3804 |
|
| 3805 |
/***/ 8524: |
| 3806 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 3807 |
|
| 3808 |
"use strict"; |
| 3809 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 3810 |
/* harmony export */ checkUnsplittableBox: function() { return /* binding */ checkUnsplittableBox; } |
| 3811 |
/* harmony export */ }); |
| 3812 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 3813 |
/*! |
| 3814 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 3815 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 3816 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 3817 |
*/ /** |
| 3818 |
* @module plugins/enter |
| 3819 |
*/ |
| 3820 |
/** |
| 3821 |
* Inside quote/tables cell, etc. you can't split so just add br |
| 3822 |
* @private |
| 3823 |
*/ function checkUnsplittableBox(fake, jodit, currentBox) { |
| 3824 |
if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.canSplitBlock(currentBox)) { |
| 3825 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.before(fake, jodit.createInside.element('br')); |
| 3826 |
return false; |
| 3827 |
} |
| 3828 |
return true; |
| 3829 |
} |
| 3830 |
|
| 3831 |
|
| 3832 |
/***/ }), |
| 3833 |
|
| 3834 |
/***/ 8837: |
| 3835 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 3836 |
|
| 3837 |
"use strict"; |
| 3838 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 3839 |
/* harmony export */ onTabInsideLi: function() { return /* binding */ onTabInsideLi; } |
| 3840 |
/* harmony export */ }); |
| 3841 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 3842 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(28712); |
| 3843 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_1__); |
| 3844 |
/*! |
| 3845 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 3846 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 3847 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 3848 |
*/ /** |
| 3849 |
* @module plugins/tab |
| 3850 |
*/ |
| 3851 |
|
| 3852 |
/** |
| 3853 |
* Checks if the cursor is at the beginning of the LI element when tabbed. |
| 3854 |
* If so then add an internal list |
| 3855 |
* @private |
| 3856 |
*/ function onTabInsideLi(jodit, shift = false) { |
| 3857 |
if (!jodit.o.tab.tabInsideLiInsertNewList) { |
| 3858 |
return false; |
| 3859 |
} |
| 3860 |
const [fake, fake2] = fakeCursors(jodit); |
| 3861 |
try { |
| 3862 |
const li = getParentLeaf(jodit, fake, shift); |
| 3863 |
if (!li) { |
| 3864 |
return false; |
| 3865 |
} |
| 3866 |
if (!isSameLeftCursorPosition(li, jodit, fake)) { |
| 3867 |
return false; |
| 3868 |
} |
| 3869 |
const list = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(li, [ |
| 3870 |
'ol', |
| 3871 |
'ul' |
| 3872 |
], jodit.editor); |
| 3873 |
if (!list || shift && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(list, 'li', jodit.editor)) { |
| 3874 |
return false; |
| 3875 |
} |
| 3876 |
if (!shift) { |
| 3877 |
appendNestedList(jodit, list, li); |
| 3878 |
} else { |
| 3879 |
removeNestedList(jodit, list, li); |
| 3880 |
} |
| 3881 |
return true; |
| 3882 |
} finally{ |
| 3883 |
const range = jodit.s.createRange(); |
| 3884 |
range.setStartAfter(fake); |
| 3885 |
range.setEndBefore(fake2); |
| 3886 |
jodit.s.selectRange(range); |
| 3887 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(fake); |
| 3888 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(fake2); |
| 3889 |
} |
| 3890 |
// removed by dead control flow |
| 3891 |
|
| 3892 |
} |
| 3893 |
function fakeCursors(jodit) { |
| 3894 |
const fake = jodit.createInside.fake(); |
| 3895 |
const fake2 = jodit.createInside.fake(); |
| 3896 |
const r = jodit.s.range.cloneRange(); |
| 3897 |
r.collapse(true); |
| 3898 |
r.insertNode(fake); |
| 3899 |
const r2 = jodit.s.range.cloneRange(); |
| 3900 |
r2.collapse(false); |
| 3901 |
r2.insertNode(fake2); |
| 3902 |
return [ |
| 3903 |
fake, |
| 3904 |
fake2 |
| 3905 |
]; |
| 3906 |
} |
| 3907 |
function getParentLeaf(jodit, fake, shift) { |
| 3908 |
const li = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(fake, 'li', jodit.editor); |
| 3909 |
if (!li) { |
| 3910 |
return false; |
| 3911 |
} |
| 3912 |
if (!shift && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isLeaf(li.previousElementSibling)) { |
| 3913 |
return false; |
| 3914 |
} |
| 3915 |
if (shift && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(li, 'li', jodit.editor)) { |
| 3916 |
return false; |
| 3917 |
} |
| 3918 |
return li; |
| 3919 |
} |
| 3920 |
function isSameLeftCursorPosition(li, jodit, fake) { |
| 3921 |
const li2 = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(fake, 'li', jodit.editor); |
| 3922 |
return !(!li2 || li2 !== li && !li.contains(li2)); |
| 3923 |
} |
| 3924 |
function appendNestedList(jodit, list, li) { |
| 3925 |
const previousLi = li.previousElementSibling; |
| 3926 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_1__.assert)(previousLi, 'tab previousElementSibling is null'); |
| 3927 |
const lastElm = previousLi.lastElementChild; |
| 3928 |
const newList = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(lastElm, list.tagName) ? lastElm : jodit.createInside.element(list.tagName, Array.from(list.attributes).reduce((acc, attr)=>{ |
| 3929 |
acc[attr.name] = attr.value; |
| 3930 |
return acc; |
| 3931 |
}, {})); |
| 3932 |
newList.appendChild(li); |
| 3933 |
lastElm !== newList && previousLi.appendChild(newList); |
| 3934 |
} |
| 3935 |
function removeNestedList(jodit, list, li) { |
| 3936 |
const parentLi = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(list, 'li', jodit.editor); |
| 3937 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_1__.assert)(parentLi, 'tab parent li is null'); |
| 3938 |
const items = Array.from(list.children).filter((t)=>jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isLeaf(t)); |
| 3939 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.after(parentLi, li); |
| 3940 |
const index = items.indexOf(li); |
| 3941 |
if (index === 0 || items.length === 1) { |
| 3942 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(list); |
| 3943 |
} |
| 3944 |
if (index !== items.length - 1) { |
| 3945 |
const clone = list.cloneNode(); |
| 3946 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.append(li, clone); |
| 3947 |
for(let i = index + 1; i < items.length; i += 1){ |
| 3948 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.append(clone, items[i]); |
| 3949 |
} |
| 3950 |
} |
| 3951 |
} |
| 3952 |
|
| 3953 |
|
| 3954 |
/***/ }), |
| 3955 |
|
| 3956 |
/***/ 8838: |
| 3957 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 3958 |
|
| 3959 |
"use strict"; |
| 3960 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 3961 |
/* harmony export */ Command: function() { return /* binding */ Command; } |
| 3962 |
/* harmony export */ }); |
| 3963 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 3964 |
/*! |
| 3965 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 3966 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 3967 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 3968 |
*/ /** |
| 3969 |
* @module modules/history |
| 3970 |
*/ |
| 3971 |
class Command { |
| 3972 |
undo() { |
| 3973 |
this.history.snapshot.restore(this.oldValue); |
| 3974 |
} |
| 3975 |
redo() { |
| 3976 |
this.history.snapshot.restore(this.newValue); |
| 3977 |
} |
| 3978 |
constructor(oldValue, newValue, history, tick){ |
| 3979 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "oldValue", void 0); |
| 3980 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "newValue", void 0); |
| 3981 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "history", void 0); |
| 3982 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "tick", void 0); |
| 3983 |
this.oldValue = oldValue; |
| 3984 |
this.newValue = newValue; |
| 3985 |
this.history = history; |
| 3986 |
this.tick = tick; |
| 3987 |
} |
| 3988 |
} |
| 3989 |
|
| 3990 |
|
| 3991 |
/***/ }), |
| 3992 |
|
| 3993 |
/***/ 8908: |
| 3994 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 3995 |
|
| 3996 |
"use strict"; |
| 3997 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 3998 |
/* harmony export */ form: function() { return /* binding */ form; } |
| 3999 |
/* harmony export */ }); |
| 4000 |
/* harmony import */ var jodit_core_ui__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(4099); |
| 4001 |
/*! |
| 4002 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 4003 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 4004 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 4005 |
*/ /** |
| 4006 |
* @module modules/image-editor |
| 4007 |
*/ |
| 4008 |
const jie = 'jodit-image-editor'; |
| 4009 |
const gi = jodit_core_ui__WEBPACK_IMPORTED_MODULE_0__.Icon.get.bind(jodit_core_ui__WEBPACK_IMPORTED_MODULE_0__.Icon); |
| 4010 |
const act = (el, className = 'jodti-image-editor_active')=>el ? className : ''; |
| 4011 |
const form = (editor, o)=>{ |
| 4012 |
const i = editor.i18n.bind(editor); |
| 4013 |
const switcher = (label, ref, active = true)=>`<div class="jodit-form__group"> |
| 4014 |
<label class="jodit-switcher-wrapper"> |
| 4015 |
<span class='jodit-switcher'> |
| 4016 |
<input ${act(active, 'checked')} data-ref="${ref}" type="checkbox"/> |
| 4017 |
<span class="jodit-switcher__slider"></span> |
| 4018 |
</span> |
| 4019 |
<span>${i(label)}</span> |
| 4020 |
</label> |
| 4021 |
</div>`; |
| 4022 |
return editor.create.fromHTML(`<form class="${jie} jodit-properties"> |
| 4023 |
<div class="jodit-grid jodit-grid_xs-column"> |
| 4024 |
<div class="jodit_col-lg-3-4 jodit_col-sm-5-5"> |
| 4025 |
${o.resize ? `<div class="${jie}__area ${jie}__area_resize ${jie}_active"> |
| 4026 |
<div data-ref="resizeBox" class="${jie}__box"></div> |
| 4027 |
<div class="${jie}__resizer"> |
| 4028 |
<i class="jodit_bottomright"></i> |
| 4029 |
</div> |
| 4030 |
</div>` : ''} |
| 4031 |
${o.crop ? `<div class="${jie}__area ${jie}__area_crop ${act(!o.resize)}"> |
| 4032 |
<div data-ref="cropBox" class="${jie}__box"> |
| 4033 |
<div class="${jie}__croper"> |
| 4034 |
<i class="jodit_bottomright"></i> |
| 4035 |
<i class="${jie}__sizes"></i> |
| 4036 |
</div> |
| 4037 |
</div> |
| 4038 |
</div>` : ''} |
| 4039 |
</div> |
| 4040 |
<div class="jodit_col-lg-1-4 jodit_col-sm-5-5"> |
| 4041 |
${o.resize ? `<div data-area="resize" class="${jie}__slider ${jie}_active"> |
| 4042 |
<div class="${jie}__slider-title"> |
| 4043 |
${gi('resize')} |
| 4044 |
${i('Resize')} |
| 4045 |
</div> |
| 4046 |
<div class="${jie}__slider-content"> |
| 4047 |
<div class="jodit-form__group"> |
| 4048 |
<label> |
| 4049 |
${i('Width')} |
| 4050 |
</label> |
| 4051 |
<input type="number" data-ref="widthInput" class="jodit-input"/> |
| 4052 |
</div> |
| 4053 |
<div class="jodit-form__group"> |
| 4054 |
<label> |
| 4055 |
${i('Height')} |
| 4056 |
</label> |
| 4057 |
<input type="number" data-ref="heightInput" class="jodit-input"/> |
| 4058 |
</div> |
| 4059 |
${switcher('Keep Aspect Ratio', 'keepAspectRatioResize')} |
| 4060 |
</div> |
| 4061 |
</div>` : ''} |
| 4062 |
${o.crop ? `<div data-area="crop" class="${jie}__slider ${act(!o.resize)}'"> |
| 4063 |
<div class="${jie}__slider-title"> |
| 4064 |
${gi('crop')} |
| 4065 |
${i('Crop')} |
| 4066 |
</div> |
| 4067 |
<div class="${jie}__slider-content"> |
| 4068 |
${switcher('Keep Aspect Ratio', 'keepAspectRatioCrop')} |
| 4069 |
</div> |
| 4070 |
</div>` : ''} |
| 4071 |
</div> |
| 4072 |
</div> |
| 4073 |
</form>`); |
| 4074 |
}; |
| 4075 |
|
| 4076 |
|
| 4077 |
/***/ }), |
| 4078 |
|
| 4079 |
/***/ 9103: |
| 4080 |
/***/ (function(module) { |
| 4081 |
|
| 4082 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M553 1399l-50 50q-10 10-23 10t-23-10l-466-466q-10-10-10-23t10-23l466-466q10-10 23-10t23 10l50 50q10 10 10 23t-10 23l-393 393 393 393q10 10 10 23t-10 23zm591-1067l-373 1291q-4 13-15.5 19.5t-23.5 2.5l-62-17q-13-4-19.5-15.5t-2.5-24.5l373-1291q4-13 15.5-19.5t23.5-2.5l62 17q13 4 19.5 15.5t2.5 24.5zm657 651l-466 466q-10 10-23 10t-23-10l-50-50q-10-10-10-23t10-23l393-393-393-393q-10-10-10-23t10-23l50-50q10-10 23-10t23 10l466 466q10 10 10 23t-10 23z\"/> </svg>" |
| 4083 |
|
| 4084 |
/***/ }), |
| 4085 |
|
| 4086 |
/***/ 9505: |
| 4087 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 4088 |
|
| 4089 |
"use strict"; |
| 4090 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 4091 |
/* harmony export */ MemoryStorageProvider: function() { return /* binding */ MemoryStorageProvider; } |
| 4092 |
/* harmony export */ }); |
| 4093 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 4094 |
/*! |
| 4095 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 4096 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 4097 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 4098 |
*/ /** |
| 4099 |
* @module storage |
| 4100 |
*/ |
| 4101 |
class MemoryStorageProvider { |
| 4102 |
set(key, value) { |
| 4103 |
this.data.set(key, value); |
| 4104 |
return this; |
| 4105 |
} |
| 4106 |
delete(key) { |
| 4107 |
this.data.delete(key); |
| 4108 |
return this; |
| 4109 |
} |
| 4110 |
get(key) { |
| 4111 |
return this.data.get(key); |
| 4112 |
} |
| 4113 |
exists(key) { |
| 4114 |
return this.data.has(key); |
| 4115 |
} |
| 4116 |
clear() { |
| 4117 |
this.data.clear(); |
| 4118 |
return this; |
| 4119 |
} |
| 4120 |
constructor(){ |
| 4121 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "data", new Map()); |
| 4122 |
} |
| 4123 |
} |
| 4124 |
|
| 4125 |
|
| 4126 |
/***/ }), |
| 4127 |
|
| 4128 |
/***/ 9703: |
| 4129 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 4130 |
|
| 4131 |
"use strict"; |
| 4132 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 4133 |
/* harmony export */ hasSameStyle: function() { return /* binding */ hasSameStyle; }, |
| 4134 |
/* harmony export */ hasSameStyleKeys: function() { return /* binding */ hasSameStyleKeys; } |
| 4135 |
/* harmony export */ }); |
| 4136 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 4137 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(23211); |
| 4138 |
/* harmony import */ var jodit_core_helpers_checker_is_void__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(18303); |
| 4139 |
/* harmony import */ var jodit_core_helpers_normalize_normalize_css_value__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(19147); |
| 4140 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(28712); |
| 4141 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_4__); |
| 4142 |
/* harmony import */ var jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(80991); |
| 4143 |
/*! |
| 4144 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 4145 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 4146 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 4147 |
*/ |
| 4148 |
|
| 4149 |
|
| 4150 |
|
| 4151 |
|
| 4152 |
|
| 4153 |
/** |
| 4154 |
* Element has the same styles as in the commit |
| 4155 |
* @private |
| 4156 |
*/ function hasSameStyle(elm, rules) { |
| 4157 |
return Boolean(!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isTag(elm, 'font') && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isHTMLElement(elm) && Object.keys(rules).every((property)=>{ |
| 4158 |
const value = (0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_5__.css)(elm, property, true); |
| 4159 |
if (value === '' && (rules[property] === '' || rules[property] == null)) { |
| 4160 |
return true; |
| 4161 |
} |
| 4162 |
return !(0,jodit_core_helpers_checker_is_void__WEBPACK_IMPORTED_MODULE_2__.isVoid)(value) && value !== '' && !(0,jodit_core_helpers_checker_is_void__WEBPACK_IMPORTED_MODULE_2__.isVoid)(rules[property]) && (0,jodit_core_helpers_normalize_normalize_css_value__WEBPACK_IMPORTED_MODULE_3__.normalizeCssValue)(property, rules[property]).toString().toLowerCase() === value.toString().toLowerCase(); |
| 4163 |
})); |
| 4164 |
} |
| 4165 |
if (jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.globalDocument) { |
| 4166 |
const elm = jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.globalDocument.createElement('div'); |
| 4167 |
elm.style.color = 'red'; |
| 4168 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_4__.assert)(hasSameStyle(elm, { |
| 4169 |
color: 'red' |
| 4170 |
}), 'Style test'); |
| 4171 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_4__.assert)(hasSameStyle(elm, { |
| 4172 |
fontSize: null |
| 4173 |
}), 'Style test'); |
| 4174 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_4__.assert)(hasSameStyle(elm, { |
| 4175 |
fontSize: '' |
| 4176 |
}), 'Style test'); |
| 4177 |
} |
| 4178 |
/** |
| 4179 |
* Element has the similar styles keys |
| 4180 |
*/ function hasSameStyleKeys(elm, rules) { |
| 4181 |
return Boolean(!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isTag(elm, 'font') && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isHTMLElement(elm) && Object.keys(rules).every((property)=>{ |
| 4182 |
const value = (0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_5__.css)(elm, property, true); |
| 4183 |
return value !== ''; |
| 4184 |
})); |
| 4185 |
} |
| 4186 |
if (jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.globalDocument) { |
| 4187 |
const elm2 = jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.globalDocument.createElement('div'); |
| 4188 |
elm2.style.color = 'red'; |
| 4189 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_4__.assert)(hasSameStyleKeys(elm2, { |
| 4190 |
color: 'red' |
| 4191 |
}), 'Style test'); |
| 4192 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_4__.assert)(!hasSameStyleKeys(elm2, { |
| 4193 |
font: 'Arial', |
| 4194 |
color: 'red' |
| 4195 |
}), 'Style test'); |
| 4196 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_4__.assert)(!hasSameStyleKeys(elm2, { |
| 4197 |
border: '1px solid #ccc' |
| 4198 |
}), 'Style test'); |
| 4199 |
} |
| 4200 |
|
| 4201 |
|
| 4202 |
/***/ }), |
| 4203 |
|
| 4204 |
/***/ 10081: |
| 4205 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 4206 |
|
| 4207 |
"use strict"; |
| 4208 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 4209 |
/* harmony export */ UIMessages: function() { return /* binding */ UIMessages; } |
| 4210 |
/* harmony export */ }); |
| 4211 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 4212 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 4213 |
/* harmony import */ var jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(91672); |
| 4214 |
/* harmony import */ var jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(80991); |
| 4215 |
/* harmony import */ var jodit_core_ui_group_group__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(63468); |
| 4216 |
/* harmony import */ var jodit_modules_messages_message__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(61466); |
| 4217 |
/*! |
| 4218 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 4219 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 4220 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 4221 |
*/ /** |
| 4222 |
* [[include:modules/messages/README.md]] |
| 4223 |
* @packageDocumentation |
| 4224 |
* @module modules/messages |
| 4225 |
*/ |
| 4226 |
|
| 4227 |
|
| 4228 |
|
| 4229 |
|
| 4230 |
|
| 4231 |
|
| 4232 |
class UIMessages extends jodit_core_ui_group_group__WEBPACK_IMPORTED_MODULE_4__.UIGroup { |
| 4233 |
className() { |
| 4234 |
return 'UIMessages'; |
| 4235 |
} |
| 4236 |
/** |
| 4237 |
* Show popup info message in the lower right corner of the container |
| 4238 |
* ```js |
| 4239 |
* const jodit = Jodit.make('#editor'); |
| 4240 |
* jodit.info('Hello world', 3000); |
| 4241 |
* ``` |
| 4242 |
*/ info(text, timeout) { |
| 4243 |
this.__message(text, 'info', timeout); |
| 4244 |
} |
| 4245 |
/** |
| 4246 |
* Show popup success message in the lower right corner of the container |
| 4247 |
* ```js |
| 4248 |
* const jodit = Jodit.make('#editor'); |
| 4249 |
* jodit.success('Hello world', 3000); |
| 4250 |
* ``` |
| 4251 |
*/ success(text, timeout) { |
| 4252 |
this.__message(text, 'success', timeout); |
| 4253 |
} |
| 4254 |
/** |
| 4255 |
* Show popup error message in the lower right corner of the container |
| 4256 |
* ```js |
| 4257 |
* const jodit = Jodit.make('#editor'); |
| 4258 |
* jodit.error('Hello world', 3000); |
| 4259 |
* ``` |
| 4260 |
*/ error(text, timeout) { |
| 4261 |
this.__message(text, 'error', timeout); |
| 4262 |
} |
| 4263 |
/** |
| 4264 |
* Show popup message in the lower right corner of the container |
| 4265 |
* ```js |
| 4266 |
* const jodit = Jodit.make('#editor'); |
| 4267 |
* jodit.message('Hello world', 'info', 3000); |
| 4268 |
* ``` |
| 4269 |
*/ message(text, variant, timeout) { |
| 4270 |
this.__message(text, variant, timeout); |
| 4271 |
} |
| 4272 |
__message(text, variant = 'info', timeout) { |
| 4273 |
const key = text + ':' + variant; |
| 4274 |
if (this.__messages.has(key)) { |
| 4275 |
this.async.updateTimeout(key, timeout || this.options.defaultTimeout); |
| 4276 |
return; |
| 4277 |
} |
| 4278 |
if (!this.__box) { |
| 4279 |
throw new Error('Container is not defined: ' + key); |
| 4280 |
} |
| 4281 |
this.__box.appendChild(this.container); |
| 4282 |
const msg = new jodit_modules_messages_message__WEBPACK_IMPORTED_MODULE_5__.UIMessage(this.j, { |
| 4283 |
text, |
| 4284 |
variant |
| 4285 |
}); |
| 4286 |
this.append(msg); |
| 4287 |
this.__calcOffsets(); |
| 4288 |
this.__messages.add(key); |
| 4289 |
const remove = this.__getRemoveCallback(msg, key); |
| 4290 |
this.j.e.on(msg.container, 'pointerdown', remove); |
| 4291 |
this.async.setTimeout(remove, { |
| 4292 |
label: key, |
| 4293 |
timeout: timeout || this.options.defaultTimeout |
| 4294 |
}); |
| 4295 |
} |
| 4296 |
__getRemoveCallback(msg, key) { |
| 4297 |
const remove = (e)=>{ |
| 4298 |
e && e.preventDefault(); |
| 4299 |
if (msg.isInDestruct) { |
| 4300 |
return; |
| 4301 |
} |
| 4302 |
this.async.clearTimeout(key); |
| 4303 |
this.j.e.off(msg.container, 'pointerdown', remove); |
| 4304 |
this.__messages.delete(key); |
| 4305 |
msg.setMod('active', false); |
| 4306 |
this.async.setTimeout(()=>{ |
| 4307 |
this.remove(msg); |
| 4308 |
msg.destruct(); |
| 4309 |
this.__calcOffsets(); |
| 4310 |
}, 300); |
| 4311 |
}; |
| 4312 |
return remove; |
| 4313 |
} |
| 4314 |
__calcOffsets() { |
| 4315 |
let height = 5; |
| 4316 |
this.elements.forEach((elm)=>{ |
| 4317 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_3__.css)(elm.container, 'bottom', height + 'px'); |
| 4318 |
height += elm.container.offsetHeight + this.options.defaultOffset; |
| 4319 |
}); |
| 4320 |
} |
| 4321 |
constructor(jodit, __box, options = { |
| 4322 |
defaultTimeout: 3000, |
| 4323 |
defaultOffset: 5 |
| 4324 |
}){ |
| 4325 |
super(jodit), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__box", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "options", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__messages", void 0), this.__box = __box, this.options = options, this.__messages = new Set(); |
| 4326 |
} |
| 4327 |
} |
| 4328 |
UIMessages = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 4329 |
jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_2__.component |
| 4330 |
], UIMessages); |
| 4331 |
|
| 4332 |
|
| 4333 |
/***/ }), |
| 4334 |
|
| 4335 |
/***/ 10099: |
| 4336 |
/***/ (function(module) { |
| 4337 |
|
| 4338 |
/*! |
| 4339 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 4340 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 4341 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 4342 |
*/ module.exports = { |
| 4343 |
symbols: 'symbol' |
| 4344 |
}; |
| 4345 |
|
| 4346 |
|
| 4347 |
/***/ }), |
| 4348 |
|
| 4349 |
/***/ 10157: |
| 4350 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 4351 |
|
| 4352 |
"use strict"; |
| 4353 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 4354 |
/* harmony export */ checkUnwrapFirstListItem: function() { return /* binding */ checkUnwrapFirstListItem; } |
| 4355 |
/* harmony export */ }); |
| 4356 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 4357 |
/* harmony import */ var jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(93640); |
| 4358 |
/*! |
| 4359 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 4360 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 4361 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 4362 |
*/ /** |
| 4363 |
* @module plugins/backspace |
| 4364 |
*/ |
| 4365 |
|
| 4366 |
/** |
| 4367 |
* For the first item in a list on backspace, try to move his content in new P |
| 4368 |
* |
| 4369 |
* @example |
| 4370 |
* ```html |
| 4371 |
* <ul><li>|first</li><li>second</li></ul> |
| 4372 |
* ``` |
| 4373 |
* Result |
| 4374 |
* ```html |
| 4375 |
* <p>|first</p><ul><li>second</li></ul> |
| 4376 |
* ``` |
| 4377 |
* |
| 4378 |
* @private |
| 4379 |
*/ function checkUnwrapFirstListItem(jodit, fakeNode, backspace) { |
| 4380 |
var _li_parentElement; |
| 4381 |
const li = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(fakeNode, jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isElement, jodit.editor); |
| 4382 |
const { s } = jodit; |
| 4383 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isLeaf(li) && (li === null || li === void 0 ? void 0 : (_li_parentElement = li.parentElement) === null || _li_parentElement === void 0 ? void 0 : _li_parentElement[backspace ? 'firstElementChild' : 'lastElementChild']) === li && s.cursorInTheEdge(backspace, li)) { |
| 4384 |
const ul = li.parentElement; |
| 4385 |
const p = jodit.createInside.element(jodit.o.enterBlock); |
| 4386 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__.call)(backspace ? jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.before : jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.after, ul, p); |
| 4387 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.moveContent(li, p); |
| 4388 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(li); |
| 4389 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isEmpty(ul)) { |
| 4390 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(ul); |
| 4391 |
} |
| 4392 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__.call)(backspace ? s.setCursorBefore : s.setCursorAfter, fakeNode); |
| 4393 |
return true; |
| 4394 |
} |
| 4395 |
return false; |
| 4396 |
} |
| 4397 |
|
| 4398 |
|
| 4399 |
/***/ }), |
| 4400 |
|
| 4401 |
/***/ 10171: |
| 4402 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 4403 |
|
| 4404 |
"use strict"; |
| 4405 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 4406 |
/* harmony export */ getSuitChild: function() { return /* binding */ getSuitChild; } |
| 4407 |
/* harmony export */ }); |
| 4408 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 4409 |
/* harmony import */ var _is_normal_node__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(83653); |
| 4410 |
/* harmony import */ var _is_suit_element__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(73019); |
| 4411 |
/*! |
| 4412 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 4413 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 4414 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 4415 |
*/ |
| 4416 |
|
| 4417 |
|
| 4418 |
/** |
| 4419 |
* Checks if child elements are suitable for applying styles. |
| 4420 |
* An element is suitable for us only if it is the only significant child. |
| 4421 |
* If the child matches then returns it. |
| 4422 |
* @example |
| 4423 |
* `<font><strong>selected</strong></font>` |
| 4424 |
* @private |
| 4425 |
*/ function getSuitChild(style, font) { |
| 4426 |
let { firstChild: child } = font; |
| 4427 |
while(child && !(0,_is_normal_node__WEBPACK_IMPORTED_MODULE_1__.isNormalNode)(child)){ |
| 4428 |
child = child.nextSibling; |
| 4429 |
if (!child) { |
| 4430 |
return null; |
| 4431 |
} |
| 4432 |
} |
| 4433 |
if (child && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.next(child, _is_normal_node__WEBPACK_IMPORTED_MODULE_1__.isNormalNode, font) && (0,_is_suit_element__WEBPACK_IMPORTED_MODULE_2__.isSuitElement)(style, child, false)) { |
| 4434 |
return child; |
| 4435 |
} |
| 4436 |
return null; |
| 4437 |
} |
| 4438 |
|
| 4439 |
|
| 4440 |
/***/ }), |
| 4441 |
|
| 4442 |
/***/ 10685: |
| 4443 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 4444 |
|
| 4445 |
"use strict"; |
| 4446 |
/* harmony import */ var jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(29434); |
| 4447 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(5266); |
| 4448 |
/* harmony import */ var _enter_svg__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(86634); |
| 4449 |
/* harmony import */ var _enter_svg__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_enter_svg__WEBPACK_IMPORTED_MODULE_2__); |
| 4450 |
/*! |
| 4451 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 4452 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 4453 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 4454 |
*/ /** |
| 4455 |
* @module plugins/add-new-line |
| 4456 |
*/ |
| 4457 |
|
| 4458 |
|
| 4459 |
jodit_config__WEBPACK_IMPORTED_MODULE_1__.Config.prototype.addNewLine = true; |
| 4460 |
jodit_config__WEBPACK_IMPORTED_MODULE_1__.Config.prototype.addNewLineOnDBLClick = true; |
| 4461 |
jodit_config__WEBPACK_IMPORTED_MODULE_1__.Config.prototype.addNewLineTagsTriggers = [ |
| 4462 |
'table', |
| 4463 |
'iframe', |
| 4464 |
'img', |
| 4465 |
'hr', |
| 4466 |
'pre', |
| 4467 |
'jodit' |
| 4468 |
]; |
| 4469 |
jodit_config__WEBPACK_IMPORTED_MODULE_1__.Config.prototype.addNewLineDeltaShow = 20; |
| 4470 |
jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_0__.Icon.set('enter', (_enter_svg__WEBPACK_IMPORTED_MODULE_2___default())); |
| 4471 |
|
| 4472 |
|
| 4473 |
/***/ }), |
| 4474 |
|
| 4475 |
/***/ 10808: |
| 4476 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 4477 |
|
| 4478 |
"use strict"; |
| 4479 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 4480 |
/* harmony export */ normalSizeFromString: function() { return /* binding */ normalSizeFromString; }, |
| 4481 |
/* harmony export */ normalSizeToString: function() { return /* binding */ normalSizeToString; } |
| 4482 |
/* harmony export */ }); |
| 4483 |
/* harmony import */ var jodit_core_helpers_checker_is_number__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(72412); |
| 4484 |
/* harmony import */ var jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(4040); |
| 4485 |
/*! |
| 4486 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 4487 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 4488 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 4489 |
*/ /** |
| 4490 |
* @module plugins/image-properties |
| 4491 |
*/ |
| 4492 |
|
| 4493 |
/** @private */ const normalSizeFromString = (value)=>{ |
| 4494 |
return /^[-+]?[0-9.]+(px)?$/.test(value.toString()) ? parseFloat(value.toString()) : value; |
| 4495 |
}; |
| 4496 |
/** @private */ const normalSizeToString = (value)=>{ |
| 4497 |
if ((0,jodit_core_helpers_checker_is_number__WEBPACK_IMPORTED_MODULE_0__.isNumber)(value)) { |
| 4498 |
return value ? value + 'px' : value.toString(); |
| 4499 |
} |
| 4500 |
value = (0,jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_1__.trim)(value); |
| 4501 |
return /^[0-9]+$/.test(value) ? value + 'px' : value; |
| 4502 |
}; |
| 4503 |
|
| 4504 |
|
| 4505 |
/***/ }), |
| 4506 |
|
| 4507 |
/***/ 10918: |
| 4508 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 4509 |
|
| 4510 |
"use strict"; |
| 4511 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 4512 |
/* harmony export */ checkBR: function() { return /* reexport safe */ _check_br__WEBPACK_IMPORTED_MODULE_0__.checkBR; }, |
| 4513 |
/* harmony export */ checkUnsplittableBox: function() { return /* reexport safe */ _check_unsplittable_box__WEBPACK_IMPORTED_MODULE_1__.checkUnsplittableBox; }, |
| 4514 |
/* harmony export */ getBlockWrapper: function() { return /* reexport safe */ _get_block_wrapper__WEBPACK_IMPORTED_MODULE_2__.getBlockWrapper; }, |
| 4515 |
/* harmony export */ hasPreviousBlock: function() { return /* reexport safe */ _has_previous_block__WEBPACK_IMPORTED_MODULE_3__.hasPreviousBlock; }, |
| 4516 |
/* harmony export */ insertParagraph: function() { return /* reexport safe */ _insert_paragraph__WEBPACK_IMPORTED_MODULE_4__.insertParagraph; }, |
| 4517 |
/* harmony export */ moveCursorOutFromSpecialTags: function() { return /* reexport safe */ _move_cursor_out_from_specal_tags__WEBPACK_IMPORTED_MODULE_5__.moveCursorOutFromSpecialTags; }, |
| 4518 |
/* harmony export */ processEmptyLILeaf: function() { return /* reexport safe */ _process_empty_li_leaf__WEBPACK_IMPORTED_MODULE_6__.processEmptyLILeaf; }, |
| 4519 |
/* harmony export */ splitFragment: function() { return /* reexport safe */ _split_fragment__WEBPACK_IMPORTED_MODULE_7__.splitFragment; }, |
| 4520 |
/* harmony export */ wrapText: function() { return /* reexport safe */ _wrap_text__WEBPACK_IMPORTED_MODULE_8__.wrapText; } |
| 4521 |
/* harmony export */ }); |
| 4522 |
/* harmony import */ var _check_br__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(34287); |
| 4523 |
/* harmony import */ var _check_unsplittable_box__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(8524); |
| 4524 |
/* harmony import */ var _get_block_wrapper__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(83376); |
| 4525 |
/* harmony import */ var _has_previous_block__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(66862); |
| 4526 |
/* harmony import */ var _insert_paragraph__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(65710); |
| 4527 |
/* harmony import */ var _move_cursor_out_from_specal_tags__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(47919); |
| 4528 |
/* harmony import */ var _process_empty_li_leaf__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(34672); |
| 4529 |
/* harmony import */ var _split_fragment__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(46303); |
| 4530 |
/* harmony import */ var _wrap_text__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(52938); |
| 4531 |
/*! |
| 4532 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 4533 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 4534 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 4535 |
*/ /** |
| 4536 |
* @module plugins/enter |
| 4537 |
*/ |
| 4538 |
|
| 4539 |
|
| 4540 |
|
| 4541 |
|
| 4542 |
|
| 4543 |
|
| 4544 |
|
| 4545 |
|
| 4546 |
|
| 4547 |
|
| 4548 |
/***/ }), |
| 4549 |
|
| 4550 |
/***/ 11018: |
| 4551 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 4552 |
|
| 4553 |
"use strict"; |
| 4554 |
/* unused harmony export cleanHtml */ |
| 4555 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 4556 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 4557 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(84839); |
| 4558 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(23211); |
| 4559 |
/* harmony import */ var jodit_core_dom_lazy_walker__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(1080); |
| 4560 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(28077); |
| 4561 |
/* harmony import */ var jodit_core_helpers_html_safe_html__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(48155); |
| 4562 |
/* harmony import */ var jodit_core_plugin_plugin__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(18855); |
| 4563 |
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(11173); |
| 4564 |
/* harmony import */ var _helpers__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(54053); |
| 4565 |
/*! |
| 4566 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 4567 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 4568 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 4569 |
*/ /** |
| 4570 |
* [[include:plugins/clean-html/README.md]] |
| 4571 |
* @packageDocumentation |
| 4572 |
* @module plugins/clean-html |
| 4573 |
*/ |
| 4574 |
|
| 4575 |
|
| 4576 |
|
| 4577 |
|
| 4578 |
|
| 4579 |
|
| 4580 |
|
| 4581 |
|
| 4582 |
|
| 4583 |
/** |
| 4584 |
* Clean HTML after removeFormat and insertHorizontalRule command |
| 4585 |
*/ class cleanHtml extends jodit_core_plugin_plugin__WEBPACK_IMPORTED_MODULE_7__.Plugin { |
| 4586 |
/** @override */ afterInit(jodit) {} |
| 4587 |
get isEditMode() { |
| 4588 |
return !(this.j.isInDestruct || !this.j.isEditorMode() || this.j.getReadOnly()); |
| 4589 |
} |
| 4590 |
/** |
| 4591 |
* Clean HTML code on every change |
| 4592 |
*/ onChangeCleanHTML() { |
| 4593 |
if (!this.isEditMode) { |
| 4594 |
return; |
| 4595 |
} |
| 4596 |
const editor = this.j; |
| 4597 |
this.walker.setWork(editor.editor); |
| 4598 |
this.currentSelectionNode = editor.s.current(); |
| 4599 |
} |
| 4600 |
startWalker() { |
| 4601 |
const { jodit } = this; |
| 4602 |
const allow = (0,_helpers__WEBPACK_IMPORTED_MODULE_9__.getHash)(this.j.o.cleanHTML.allowTags); |
| 4603 |
const deny = (0,_helpers__WEBPACK_IMPORTED_MODULE_9__.getHash)(this.j.o.cleanHTML.denyTags); |
| 4604 |
this.walker.on('visit', (node)=>(0,_helpers__WEBPACK_IMPORTED_MODULE_9__.visitNodeWalker)(jodit, node, allow, deny, this.currentSelectionNode)).on('end', (affected)=>{ |
| 4605 |
this.j.e.fire(affected ? 'internalChange finishedCleanHTMLWorker' : 'finishedCleanHTMLWorker'); |
| 4606 |
}); |
| 4607 |
} |
| 4608 |
beforeCommand(command) { |
| 4609 |
if (command.toLowerCase() === 'removeformat') { |
| 4610 |
if (this.j.s.isCollapsed()) { |
| 4611 |
(0,_helpers__WEBPACK_IMPORTED_MODULE_9__.removeFormatForCollapsedSelection)(this.j); |
| 4612 |
} else { |
| 4613 |
(0,_helpers__WEBPACK_IMPORTED_MODULE_9__.removeFormatForSelection)(this.j); |
| 4614 |
} |
| 4615 |
return false; |
| 4616 |
} |
| 4617 |
} |
| 4618 |
/** |
| 4619 |
* Event handler when manually assigning a value to the HTML editor. |
| 4620 |
*/ onBeforeSetNativeEditorValue(data) { |
| 4621 |
const [sandBox, iframe] = this.j.o.cleanHTML.useIframeSandbox ? this.j.createInside.sandbox() : [ |
| 4622 |
this.j.createInside.div() |
| 4623 |
]; |
| 4624 |
sandBox.innerHTML = data.value; |
| 4625 |
this.onSafeHTML(sandBox); |
| 4626 |
data.value = sandBox.innerHTML; |
| 4627 |
(0,jodit_core_helpers_html_safe_html__WEBPACK_IMPORTED_MODULE_6__.safeHTML)(sandBox, { |
| 4628 |
safeJavaScriptLink: true, |
| 4629 |
removeOnError: true |
| 4630 |
}); |
| 4631 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.safeRemove(iframe); |
| 4632 |
return false; |
| 4633 |
} |
| 4634 |
onSafeHTML(sandBox) { |
| 4635 |
(0,jodit_core_helpers_html_safe_html__WEBPACK_IMPORTED_MODULE_6__.safeHTML)(sandBox, this.j.o.cleanHTML); |
| 4636 |
} |
| 4637 |
/** @override */ beforeDestruct() { |
| 4638 |
this.walker.destruct(); |
| 4639 |
} |
| 4640 |
constructor(...args){ |
| 4641 |
super(...args), /** @override */ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "buttons", [ |
| 4642 |
{ |
| 4643 |
name: 'eraser', |
| 4644 |
group: 'font-style' |
| 4645 |
} |
| 4646 |
]), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "currentSelectionNode", null), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "walker", new jodit_core_dom_lazy_walker__WEBPACK_IMPORTED_MODULE_4__.LazyWalker(this.j.async, { |
| 4647 |
timeout: this.j.o.cleanHTML.timeout |
| 4648 |
})); |
| 4649 |
} |
| 4650 |
} |
| 4651 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 4652 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.watch)([ |
| 4653 |
':change', |
| 4654 |
':afterSetMode', |
| 4655 |
':afterInit', |
| 4656 |
':mousedown', |
| 4657 |
':keydown' |
| 4658 |
]) |
| 4659 |
], cleanHtml.prototype, "onChangeCleanHTML", null); |
| 4660 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 4661 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.hook)('ready') |
| 4662 |
], cleanHtml.prototype, "startWalker", null); |
| 4663 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 4664 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.watch)(':beforeCommand') |
| 4665 |
], cleanHtml.prototype, "beforeCommand", null); |
| 4666 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 4667 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.watch)(':beforeSetNativeEditorValue') |
| 4668 |
], cleanHtml.prototype, "onBeforeSetNativeEditorValue", null); |
| 4669 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 4670 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.watch)(':safeHTML') |
| 4671 |
], cleanHtml.prototype, "onSafeHTML", null); |
| 4672 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_5__.pluginSystem.add('cleanHtml', cleanHtml); |
| 4673 |
|
| 4674 |
|
| 4675 |
/***/ }), |
| 4676 |
|
| 4677 |
/***/ 11080: |
| 4678 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 4679 |
|
| 4680 |
"use strict"; |
| 4681 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 4682 |
/* harmony export */ OptionsError: function() { return /* binding */ OptionsError; } |
| 4683 |
/* harmony export */ }); |
| 4684 |
/*! |
| 4685 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 4686 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 4687 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 4688 |
*/ /** |
| 4689 |
* @module helpers/utils |
| 4690 |
*/ class OptionsError extends TypeError { |
| 4691 |
constructor(m){ |
| 4692 |
super(m); |
| 4693 |
Object.setPrototypeOf(this, OptionsError.prototype); |
| 4694 |
} |
| 4695 |
} |
| 4696 |
|
| 4697 |
|
| 4698 |
/***/ }), |
| 4699 |
|
| 4700 |
/***/ 11173: |
| 4701 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 4702 |
|
| 4703 |
"use strict"; |
| 4704 |
/* harmony import */ var jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(29434); |
| 4705 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(5266); |
| 4706 |
/* harmony import */ var _eraser_svg__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(71948); |
| 4707 |
/* harmony import */ var _eraser_svg__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_eraser_svg__WEBPACK_IMPORTED_MODULE_2__); |
| 4708 |
/*! |
| 4709 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 4710 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 4711 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 4712 |
*/ /** |
| 4713 |
* @module plugins/clean-html |
| 4714 |
*/ |
| 4715 |
|
| 4716 |
|
| 4717 |
jodit_config__WEBPACK_IMPORTED_MODULE_1__.Config.prototype.cleanHTML = { |
| 4718 |
timeout: 300, |
| 4719 |
removeEmptyElements: true, |
| 4720 |
fillEmptyParagraph: true, |
| 4721 |
replaceNBSP: true, |
| 4722 |
replaceOldTags: { |
| 4723 |
i: 'em', |
| 4724 |
b: 'strong' |
| 4725 |
}, |
| 4726 |
allowTags: false, |
| 4727 |
denyTags: 'script', |
| 4728 |
useIframeSandbox: false, |
| 4729 |
removeOnError: true, |
| 4730 |
safeJavaScriptLink: true, |
| 4731 |
disableCleanFilter: null |
| 4732 |
}; |
| 4733 |
jodit_config__WEBPACK_IMPORTED_MODULE_1__.Config.prototype.controls.eraser = { |
| 4734 |
command: 'removeFormat', |
| 4735 |
tooltip: 'Clear Formatting' |
| 4736 |
}; |
| 4737 |
jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_0__.Icon.set('eraser', (_eraser_svg__WEBPACK_IMPORTED_MODULE_2___default())); |
| 4738 |
|
| 4739 |
|
| 4740 |
/***/ }), |
| 4741 |
|
| 4742 |
/***/ 11774: |
| 4743 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 4744 |
|
| 4745 |
"use strict"; |
| 4746 |
/* unused harmony export symbols */ |
| 4747 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 4748 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(81937); |
| 4749 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(23211); |
| 4750 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(28077); |
| 4751 |
/* harmony import */ var jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(93640); |
| 4752 |
/* harmony import */ var jodit_core_plugin_plugin__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(18855); |
| 4753 |
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(18993); |
| 4754 |
/* harmony import */ var _langs__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(91017); |
| 4755 |
/*! |
| 4756 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 4757 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 4758 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 4759 |
*/ /** |
| 4760 |
* [[include:plugins/symbols/README.md]] |
| 4761 |
* @packageDocumentation |
| 4762 |
* @module plugins/symbols |
| 4763 |
*/ |
| 4764 |
|
| 4765 |
|
| 4766 |
|
| 4767 |
|
| 4768 |
|
| 4769 |
|
| 4770 |
|
| 4771 |
|
| 4772 |
/** |
| 4773 |
* The plugin inserts characters that are not part of the standard keyboard. |
| 4774 |
*/ class symbols extends jodit_core_plugin_plugin__WEBPACK_IMPORTED_MODULE_5__.Plugin { |
| 4775 |
afterInit(jodit) { |
| 4776 |
jodit.e.on('generateSpecialCharactersTable.symbols', ()=>{ |
| 4777 |
const container = jodit.c.fromHTML(`<div class="jodit-symbols__container"> |
| 4778 |
<div class="jodit-symbols__container_table"> |
| 4779 |
<table class="jodit-symbols__table"><tbody></tbody></table> |
| 4780 |
</div> |
| 4781 |
<div class="jodit-symbols__container_preview"> |
| 4782 |
<div class="jodit-symbols__preview"></div> |
| 4783 |
</div> |
| 4784 |
</div>`); |
| 4785 |
const preview = container.querySelector('.jodit-symbols__preview'); |
| 4786 |
const table = container.querySelector('table'); |
| 4787 |
const body = table.tBodies[0]; |
| 4788 |
const chars = []; |
| 4789 |
for(let i = 0; i < jodit.o.specialCharacters.length;){ |
| 4790 |
const tr = jodit.c.element('tr'); |
| 4791 |
for(let j = 0; j < this.__countInRow && i < jodit.o.specialCharacters.length; j += 1, i += 1){ |
| 4792 |
const td = jodit.c.element('td'), a = jodit.c.fromHTML(`<a |
| 4793 |
data-index="${i}" |
| 4794 |
data-index-j="${j}" |
| 4795 |
role="option" |
| 4796 |
tabindex="-1" |
| 4797 |
>${jodit.o.specialCharacters[i]}</a>`); |
| 4798 |
chars.push(a); |
| 4799 |
td.appendChild(a); |
| 4800 |
tr.appendChild(td); |
| 4801 |
} |
| 4802 |
body.appendChild(tr); |
| 4803 |
} |
| 4804 |
const self = this; |
| 4805 |
jodit.e.on(chars, 'focus', function() { |
| 4806 |
preview.innerHTML = this.innerHTML; |
| 4807 |
}).on(chars, 'mousedown', function(e) { |
| 4808 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__.Dom.isTag(this, 'a')) { |
| 4809 |
jodit.s.focus(); |
| 4810 |
jodit.s.insertHTML(this.innerHTML); |
| 4811 |
if (!(e === null || e === void 0 ? void 0 : e.shiftKey)) { |
| 4812 |
jodit.e.fire(this, 'close_dialog'); |
| 4813 |
} |
| 4814 |
e && e.preventDefault(); |
| 4815 |
e && e.stopImmediatePropagation(); |
| 4816 |
} |
| 4817 |
}).on(chars, 'mouseenter', function() { |
| 4818 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__.Dom.isTag(this, 'a')) { |
| 4819 |
this.focus(); |
| 4820 |
} |
| 4821 |
}).on(chars, 'keydown', (e)=>{ |
| 4822 |
const target = e.target; |
| 4823 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__.Dom.isTag(target, 'a')) { |
| 4824 |
const index = parseInt((0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_4__.attr)(target, '-index') || '0', 10), jIndex = parseInt((0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_4__.attr)(target, 'data-index-j') || '0', 10); |
| 4825 |
let newIndex; |
| 4826 |
switch(e.key){ |
| 4827 |
case jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.KEY_UP: |
| 4828 |
case jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.KEY_DOWN: |
| 4829 |
newIndex = e.key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.KEY_UP ? index - self.__countInRow : index + self.__countInRow; |
| 4830 |
if (chars[newIndex] === undefined) { |
| 4831 |
newIndex = e.key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.KEY_UP ? Math.floor(chars.length / self.__countInRow) * self.__countInRow + jIndex : jIndex; |
| 4832 |
if (newIndex > chars.length - 1) { |
| 4833 |
newIndex -= self.__countInRow; |
| 4834 |
} |
| 4835 |
} |
| 4836 |
chars[newIndex] && chars[newIndex].focus(); |
| 4837 |
break; |
| 4838 |
case jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.KEY_RIGHT: |
| 4839 |
case jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.KEY_LEFT: |
| 4840 |
newIndex = e.key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.KEY_LEFT ? index - 1 : index + 1; |
| 4841 |
if (chars[newIndex] === undefined) { |
| 4842 |
newIndex = e.key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.KEY_LEFT ? chars.length - 1 : 0; |
| 4843 |
} |
| 4844 |
chars[newIndex] && chars[newIndex].focus(); |
| 4845 |
break; |
| 4846 |
case jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.KEY_ENTER: |
| 4847 |
jodit.e.fire(target, 'mousedown'); |
| 4848 |
e.stopImmediatePropagation(); |
| 4849 |
e.preventDefault(); |
| 4850 |
break; |
| 4851 |
} |
| 4852 |
} |
| 4853 |
}); |
| 4854 |
return container; |
| 4855 |
}); |
| 4856 |
} |
| 4857 |
/** @override */ beforeDestruct(jodit) { |
| 4858 |
jodit.e.off('generateSpecialCharactersTable.symbols'); |
| 4859 |
} |
| 4860 |
constructor(jodit){ |
| 4861 |
super(jodit), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "buttons", [ |
| 4862 |
{ |
| 4863 |
name: 'symbols', |
| 4864 |
group: 'insert' |
| 4865 |
} |
| 4866 |
]), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__countInRow", 17); |
| 4867 |
(0,jodit_core_global__WEBPACK_IMPORTED_MODULE_3__.extendLang)(_langs__WEBPACK_IMPORTED_MODULE_7__); |
| 4868 |
} |
| 4869 |
} |
| 4870 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_3__.pluginSystem.add('symbols', symbols); |
| 4871 |
|
| 4872 |
|
| 4873 |
/***/ }), |
| 4874 |
|
| 4875 |
/***/ 11917: |
| 4876 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 4877 |
|
| 4878 |
"use strict"; |
| 4879 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 4880 |
/* harmony export */ getKey: function() { return /* binding */ getKey; } |
| 4881 |
/* harmony export */ }); |
| 4882 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 4883 |
/*! |
| 4884 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 4885 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 4886 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 4887 |
*/ /** |
| 4888 |
* @module plugins/indent |
| 4889 |
*/ |
| 4890 |
/** |
| 4891 |
* Get style rule key for current direction |
| 4892 |
* @internal |
| 4893 |
*/ const getKey = (direction, box)=>`${jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isCell(box) ? 'padding' : 'margin'}${direction === 'rtl' ? 'Right' : 'Left'}`; |
| 4894 |
|
| 4895 |
|
| 4896 |
/***/ }), |
| 4897 |
|
| 4898 |
/***/ 11981: |
| 4899 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 4900 |
|
| 4901 |
"use strict"; |
| 4902 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 4903 |
/* harmony export */ ajaxInstances: function() { return /* reexport safe */ _send__WEBPACK_IMPORTED_MODULE_2__.ajaxInstances; }, |
| 4904 |
/* harmony export */ hasFiles: function() { return /* binding */ hasFiles; }, |
| 4905 |
/* harmony export */ hasItems: function() { return /* binding */ hasItems; }, |
| 4906 |
/* harmony export */ processOldBrowserDrag: function() { return /* reexport safe */ _process_old_browser_drag__WEBPACK_IMPORTED_MODULE_1__.processOldBrowserDrag; }, |
| 4907 |
/* harmony export */ send: function() { return /* reexport safe */ _send__WEBPACK_IMPORTED_MODULE_2__.send; }, |
| 4908 |
/* harmony export */ sendFiles: function() { return /* reexport safe */ _send_files__WEBPACK_IMPORTED_MODULE_3__.sendFiles; } |
| 4909 |
/* harmony export */ }); |
| 4910 |
/* harmony import */ var _build_data__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(89446); |
| 4911 |
/* harmony import */ var _process_old_browser_drag__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(95436); |
| 4912 |
/* harmony import */ var _send__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(77911); |
| 4913 |
/* harmony import */ var _send_files__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(46533); |
| 4914 |
/*! |
| 4915 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 4916 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 4917 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 4918 |
*/ /** |
| 4919 |
* @module modules/uploader |
| 4920 |
*/ |
| 4921 |
|
| 4922 |
|
| 4923 |
|
| 4924 |
|
| 4925 |
function hasFiles(data) { |
| 4926 |
return Boolean(data && data.files && data.files.length > 0); |
| 4927 |
} |
| 4928 |
function hasItems(data) { |
| 4929 |
return Boolean(data && data.items && data.items.length > 0); |
| 4930 |
} |
| 4931 |
|
| 4932 |
|
| 4933 |
/***/ }), |
| 4934 |
|
| 4935 |
/***/ 12443: |
| 4936 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 4937 |
|
| 4938 |
"use strict"; |
| 4939 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 4940 |
/* harmony export */ checkTableCell: function() { return /* binding */ checkTableCell; } |
| 4941 |
/* harmony export */ }); |
| 4942 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 4943 |
/*! |
| 4944 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 4945 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 4946 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 4947 |
*/ /** |
| 4948 |
* @module plugins/backspace |
| 4949 |
*/ |
| 4950 |
/** |
| 4951 |
* Inside the CELL table - nothing to do |
| 4952 |
* |
| 4953 |
* @example |
| 4954 |
* ```html |
| 4955 |
* <table><tr><td>|test</td></tr></table> |
| 4956 |
* ``` |
| 4957 |
* result |
| 4958 |
* ```html |
| 4959 |
* <table><tr><td>|test</td></tr></table> |
| 4960 |
* ``` |
| 4961 |
* |
| 4962 |
* @private |
| 4963 |
*/ function checkTableCell(jodit, fakeNode) { |
| 4964 |
const cell = fakeNode.parentElement; |
| 4965 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isCell(cell)) { |
| 4966 |
return true; |
| 4967 |
} |
| 4968 |
return false; |
| 4969 |
} |
| 4970 |
|
| 4971 |
|
| 4972 |
/***/ }), |
| 4973 |
|
| 4974 |
/***/ 13564: |
| 4975 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 4976 |
|
| 4977 |
"use strict"; |
| 4978 |
__webpack_require__.r(__webpack_exports__); |
| 4979 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 4980 |
/* harmony export */ angle_down: function() { return /* reexport default from dynamic */ _angle_down_svg__WEBPACK_IMPORTED_MODULE_0___default.a; }, |
| 4981 |
/* harmony export */ angle_left: function() { return /* reexport default from dynamic */ _angle_left_svg__WEBPACK_IMPORTED_MODULE_1___default.a; }, |
| 4982 |
/* harmony export */ angle_right: function() { return /* reexport default from dynamic */ _angle_right_svg__WEBPACK_IMPORTED_MODULE_2___default.a; }, |
| 4983 |
/* harmony export */ angle_up: function() { return /* reexport default from dynamic */ _angle_up_svg__WEBPACK_IMPORTED_MODULE_3___default.a; }, |
| 4984 |
/* harmony export */ bin: function() { return /* reexport default from dynamic */ _bin_svg__WEBPACK_IMPORTED_MODULE_4___default.a; }, |
| 4985 |
/* harmony export */ cancel: function() { return /* reexport default from dynamic */ _cancel_svg__WEBPACK_IMPORTED_MODULE_5___default.a; }, |
| 4986 |
/* harmony export */ center: function() { return /* reexport default from dynamic */ _center_svg__WEBPACK_IMPORTED_MODULE_6___default.a; }, |
| 4987 |
/* harmony export */ check: function() { return /* reexport default from dynamic */ _check_svg__WEBPACK_IMPORTED_MODULE_7___default.a; }, |
| 4988 |
/* harmony export */ chevron: function() { return /* reexport default from dynamic */ _chevron_svg__WEBPACK_IMPORTED_MODULE_8___default.a; }, |
| 4989 |
/* harmony export */ dots: function() { return /* reexport default from dynamic */ _dots_svg__WEBPACK_IMPORTED_MODULE_9___default.a; }, |
| 4990 |
/* harmony export */ eye: function() { return /* reexport default from dynamic */ _eye_svg__WEBPACK_IMPORTED_MODULE_10___default.a; }, |
| 4991 |
/* harmony export */ file: function() { return /* reexport default from dynamic */ _file_svg__WEBPACK_IMPORTED_MODULE_11___default.a; }, |
| 4992 |
/* harmony export */ folder: function() { return /* reexport default from dynamic */ _folder_svg__WEBPACK_IMPORTED_MODULE_12___default.a; }, |
| 4993 |
/* harmony export */ info_circle: function() { return /* reexport default from dynamic */ _info_circle_svg__WEBPACK_IMPORTED_MODULE_13___default.a; }, |
| 4994 |
/* harmony export */ left: function() { return /* reexport default from dynamic */ _left_svg__WEBPACK_IMPORTED_MODULE_14___default.a; }, |
| 4995 |
/* harmony export */ lock: function() { return /* reexport default from dynamic */ _lock_svg__WEBPACK_IMPORTED_MODULE_15___default.a; }, |
| 4996 |
/* harmony export */ ok: function() { return /* reexport default from dynamic */ _ok_svg__WEBPACK_IMPORTED_MODULE_16___default.a; }, |
| 4997 |
/* harmony export */ pencil: function() { return /* reexport default from dynamic */ _pencil_svg__WEBPACK_IMPORTED_MODULE_17___default.a; }, |
| 4998 |
/* harmony export */ plus: function() { return /* reexport default from dynamic */ _plus_svg__WEBPACK_IMPORTED_MODULE_18___default.a; }, |
| 4999 |
/* harmony export */ resize_handler: function() { return /* reexport default from dynamic */ _resize_handler_svg__WEBPACK_IMPORTED_MODULE_19___default.a; }, |
| 5000 |
/* harmony export */ right: function() { return /* reexport default from dynamic */ _right_svg__WEBPACK_IMPORTED_MODULE_20___default.a; }, |
| 5001 |
/* harmony export */ save: function() { return /* reexport default from dynamic */ _save_svg__WEBPACK_IMPORTED_MODULE_21___default.a; }, |
| 5002 |
/* harmony export */ settings: function() { return /* reexport default from dynamic */ _settings_svg__WEBPACK_IMPORTED_MODULE_22___default.a; }, |
| 5003 |
/* harmony export */ unlock: function() { return /* reexport default from dynamic */ _unlock_svg__WEBPACK_IMPORTED_MODULE_23___default.a; }, |
| 5004 |
/* harmony export */ update: function() { return /* reexport default from dynamic */ _update_svg__WEBPACK_IMPORTED_MODULE_24___default.a; }, |
| 5005 |
/* harmony export */ upload: function() { return /* reexport default from dynamic */ _upload_svg__WEBPACK_IMPORTED_MODULE_25___default.a; }, |
| 5006 |
/* harmony export */ valign: function() { return /* reexport default from dynamic */ _valign_svg__WEBPACK_IMPORTED_MODULE_26___default.a; } |
| 5007 |
/* harmony export */ }); |
| 5008 |
/* harmony import */ var _angle_down_svg__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(88497); |
| 5009 |
/* harmony import */ var _angle_down_svg__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_angle_down_svg__WEBPACK_IMPORTED_MODULE_0__); |
| 5010 |
/* harmony import */ var _angle_left_svg__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(91882); |
| 5011 |
/* harmony import */ var _angle_left_svg__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_angle_left_svg__WEBPACK_IMPORTED_MODULE_1__); |
| 5012 |
/* harmony import */ var _angle_right_svg__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(14305); |
| 5013 |
/* harmony import */ var _angle_right_svg__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_angle_right_svg__WEBPACK_IMPORTED_MODULE_2__); |
| 5014 |
/* harmony import */ var _angle_up_svg__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(58446); |
| 5015 |
/* harmony import */ var _angle_up_svg__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_angle_up_svg__WEBPACK_IMPORTED_MODULE_3__); |
| 5016 |
/* harmony import */ var _bin_svg__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(39858); |
| 5017 |
/* harmony import */ var _bin_svg__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_bin_svg__WEBPACK_IMPORTED_MODULE_4__); |
| 5018 |
/* harmony import */ var _cancel_svg__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(70881); |
| 5019 |
/* harmony import */ var _cancel_svg__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_cancel_svg__WEBPACK_IMPORTED_MODULE_5__); |
| 5020 |
/* harmony import */ var _center_svg__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(60636); |
| 5021 |
/* harmony import */ var _center_svg__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(_center_svg__WEBPACK_IMPORTED_MODULE_6__); |
| 5022 |
/* harmony import */ var _check_svg__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(32013); |
| 5023 |
/* harmony import */ var _check_svg__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(_check_svg__WEBPACK_IMPORTED_MODULE_7__); |
| 5024 |
/* harmony import */ var _chevron_svg__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(45512); |
| 5025 |
/* harmony import */ var _chevron_svg__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(_chevron_svg__WEBPACK_IMPORTED_MODULE_8__); |
| 5026 |
/* harmony import */ var _dots_svg__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(80347); |
| 5027 |
/* harmony import */ var _dots_svg__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(_dots_svg__WEBPACK_IMPORTED_MODULE_9__); |
| 5028 |
/* harmony import */ var _eye_svg__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(95134); |
| 5029 |
/* harmony import */ var _eye_svg__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(_eye_svg__WEBPACK_IMPORTED_MODULE_10__); |
| 5030 |
/* harmony import */ var _file_svg__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(70697); |
| 5031 |
/* harmony import */ var _file_svg__WEBPACK_IMPORTED_MODULE_11___default = /*#__PURE__*/__webpack_require__.n(_file_svg__WEBPACK_IMPORTED_MODULE_11__); |
| 5032 |
/* harmony import */ var _folder_svg__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(49983); |
| 5033 |
/* harmony import */ var _folder_svg__WEBPACK_IMPORTED_MODULE_12___default = /*#__PURE__*/__webpack_require__.n(_folder_svg__WEBPACK_IMPORTED_MODULE_12__); |
| 5034 |
/* harmony import */ var _info_circle_svg__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(98964); |
| 5035 |
/* harmony import */ var _info_circle_svg__WEBPACK_IMPORTED_MODULE_13___default = /*#__PURE__*/__webpack_require__.n(_info_circle_svg__WEBPACK_IMPORTED_MODULE_13__); |
| 5036 |
/* harmony import */ var _left_svg__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(8136); |
| 5037 |
/* harmony import */ var _left_svg__WEBPACK_IMPORTED_MODULE_14___default = /*#__PURE__*/__webpack_require__.n(_left_svg__WEBPACK_IMPORTED_MODULE_14__); |
| 5038 |
/* harmony import */ var _lock_svg__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(94806); |
| 5039 |
/* harmony import */ var _lock_svg__WEBPACK_IMPORTED_MODULE_15___default = /*#__PURE__*/__webpack_require__.n(_lock_svg__WEBPACK_IMPORTED_MODULE_15__); |
| 5040 |
/* harmony import */ var _ok_svg__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(31365); |
| 5041 |
/* harmony import */ var _ok_svg__WEBPACK_IMPORTED_MODULE_16___default = /*#__PURE__*/__webpack_require__.n(_ok_svg__WEBPACK_IMPORTED_MODULE_16__); |
| 5042 |
/* harmony import */ var _pencil_svg__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(44636); |
| 5043 |
/* harmony import */ var _pencil_svg__WEBPACK_IMPORTED_MODULE_17___default = /*#__PURE__*/__webpack_require__.n(_pencil_svg__WEBPACK_IMPORTED_MODULE_17__); |
| 5044 |
/* harmony import */ var _plus_svg__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(36327); |
| 5045 |
/* harmony import */ var _plus_svg__WEBPACK_IMPORTED_MODULE_18___default = /*#__PURE__*/__webpack_require__.n(_plus_svg__WEBPACK_IMPORTED_MODULE_18__); |
| 5046 |
/* harmony import */ var _resize_handler_svg__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(53328); |
| 5047 |
/* harmony import */ var _resize_handler_svg__WEBPACK_IMPORTED_MODULE_19___default = /*#__PURE__*/__webpack_require__.n(_resize_handler_svg__WEBPACK_IMPORTED_MODULE_19__); |
| 5048 |
/* harmony import */ var _right_svg__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(98711); |
| 5049 |
/* harmony import */ var _right_svg__WEBPACK_IMPORTED_MODULE_20___default = /*#__PURE__*/__webpack_require__.n(_right_svg__WEBPACK_IMPORTED_MODULE_20__); |
| 5050 |
/* harmony import */ var _save_svg__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(53808); |
| 5051 |
/* harmony import */ var _save_svg__WEBPACK_IMPORTED_MODULE_21___default = /*#__PURE__*/__webpack_require__.n(_save_svg__WEBPACK_IMPORTED_MODULE_21__); |
| 5052 |
/* harmony import */ var _settings_svg__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(20784); |
| 5053 |
/* harmony import */ var _settings_svg__WEBPACK_IMPORTED_MODULE_22___default = /*#__PURE__*/__webpack_require__.n(_settings_svg__WEBPACK_IMPORTED_MODULE_22__); |
| 5054 |
/* harmony import */ var _unlock_svg__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__(70999); |
| 5055 |
/* harmony import */ var _unlock_svg__WEBPACK_IMPORTED_MODULE_23___default = /*#__PURE__*/__webpack_require__.n(_unlock_svg__WEBPACK_IMPORTED_MODULE_23__); |
| 5056 |
/* harmony import */ var _update_svg__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__(45244); |
| 5057 |
/* harmony import */ var _update_svg__WEBPACK_IMPORTED_MODULE_24___default = /*#__PURE__*/__webpack_require__.n(_update_svg__WEBPACK_IMPORTED_MODULE_24__); |
| 5058 |
/* harmony import */ var _upload_svg__WEBPACK_IMPORTED_MODULE_25__ = __webpack_require__(99876); |
| 5059 |
/* harmony import */ var _upload_svg__WEBPACK_IMPORTED_MODULE_25___default = /*#__PURE__*/__webpack_require__.n(_upload_svg__WEBPACK_IMPORTED_MODULE_25__); |
| 5060 |
/* harmony import */ var _valign_svg__WEBPACK_IMPORTED_MODULE_26__ = __webpack_require__(14006); |
| 5061 |
/* harmony import */ var _valign_svg__WEBPACK_IMPORTED_MODULE_26___default = /*#__PURE__*/__webpack_require__.n(_valign_svg__WEBPACK_IMPORTED_MODULE_26__); |
| 5062 |
/*! |
| 5063 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 5064 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 5065 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 5066 |
*/ /** |
| 5067 |
* [[include:styles/icons/README.md]] |
| 5068 |
* @packageDocumentation |
| 5069 |
* @module icons |
| 5070 |
*/ |
| 5071 |
|
| 5072 |
|
| 5073 |
|
| 5074 |
|
| 5075 |
|
| 5076 |
|
| 5077 |
|
| 5078 |
|
| 5079 |
|
| 5080 |
|
| 5081 |
|
| 5082 |
|
| 5083 |
|
| 5084 |
|
| 5085 |
|
| 5086 |
|
| 5087 |
|
| 5088 |
|
| 5089 |
|
| 5090 |
|
| 5091 |
|
| 5092 |
|
| 5093 |
|
| 5094 |
|
| 5095 |
|
| 5096 |
|
| 5097 |
|
| 5098 |
|
| 5099 |
|
| 5100 |
/***/ }), |
| 5101 |
|
| 5102 |
/***/ 13810: |
| 5103 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 5104 |
|
| 5105 |
"use strict"; |
| 5106 |
/* unused harmony export source */ |
| 5107 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 5108 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 5109 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(81937); |
| 5110 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(84839); |
| 5111 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(23211); |
| 5112 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(28077); |
| 5113 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(65946); |
| 5114 |
/* harmony import */ var jodit_core_plugin__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(91206); |
| 5115 |
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(18929); |
| 5116 |
/* harmony import */ var _editor_factory__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(82495); |
| 5117 |
/*! |
| 5118 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 5119 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 5120 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 5121 |
*/ /** |
| 5122 |
* [[include:plugins/source/README.md]] |
| 5123 |
* @packageDocumentation |
| 5124 |
* @module plugins/source |
| 5125 |
*/ |
| 5126 |
|
| 5127 |
|
| 5128 |
|
| 5129 |
|
| 5130 |
|
| 5131 |
|
| 5132 |
|
| 5133 |
|
| 5134 |
|
| 5135 |
|
| 5136 |
|
| 5137 |
/** |
| 5138 |
* Plug-in change simple textarea on CodeMirror editor in Source code mode |
| 5139 |
*/ class source extends jodit_core_plugin__WEBPACK_IMPORTED_MODULE_7__.Plugin { |
| 5140 |
onInsertHTML(html) { |
| 5141 |
if (!this.j.o.readonly && !this.j.isEditorMode()) { |
| 5142 |
var _this_sourceEditor; |
| 5143 |
(_this_sourceEditor = this.sourceEditor) === null || _this_sourceEditor === void 0 ? void 0 : _this_sourceEditor.insertRaw(html); |
| 5144 |
this.toWYSIWYG(); |
| 5145 |
return false; |
| 5146 |
} |
| 5147 |
} |
| 5148 |
/** |
| 5149 |
* Update source editor from WYSIWYG area |
| 5150 |
*/ fromWYSIWYG(force = false) { |
| 5151 |
if (!this.__lock || force === true) { |
| 5152 |
this.__lock = true; |
| 5153 |
const new_value = this.j.getEditorValue(false, jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.SOURCE_CONSUMER); |
| 5154 |
if (new_value !== this.getMirrorValue()) { |
| 5155 |
this.setMirrorValue(new_value); |
| 5156 |
} |
| 5157 |
this.__lock = false; |
| 5158 |
} |
| 5159 |
} |
| 5160 |
/** |
| 5161 |
* Update WYSIWYG area from source editor |
| 5162 |
*/ toWYSIWYG() { |
| 5163 |
if (this.__lock) { |
| 5164 |
return; |
| 5165 |
} |
| 5166 |
const value = this.getMirrorValue(); |
| 5167 |
if (value === this.__oldMirrorValue) { |
| 5168 |
return; |
| 5169 |
} |
| 5170 |
this.__lock = true; |
| 5171 |
this.j.value = value; |
| 5172 |
this.__lock = false; |
| 5173 |
this.__oldMirrorValue = value; |
| 5174 |
} |
| 5175 |
getNormalPosition(pos, str) { |
| 5176 |
str = str.replace(/<(script|style|iframe)[^>]*>[^]*?<\/\1>/im, (m)=>{ |
| 5177 |
let res = ''; |
| 5178 |
for(let i = 0; i < m.length; i += 1){ |
| 5179 |
res += jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.INVISIBLE_SPACE; |
| 5180 |
} |
| 5181 |
return res; |
| 5182 |
}); |
| 5183 |
while(pos > 0 && str[pos] === jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.INVISIBLE_SPACE){ |
| 5184 |
pos--; |
| 5185 |
} |
| 5186 |
let start = pos; |
| 5187 |
while(start > 0){ |
| 5188 |
start--; |
| 5189 |
if (str[start] === '<' && str[start + 1] !== undefined && str[start + 1].match(/[\w/]+/i)) { |
| 5190 |
return start; |
| 5191 |
} |
| 5192 |
if (str[start] === '>') { |
| 5193 |
return pos; |
| 5194 |
} |
| 5195 |
} |
| 5196 |
return pos; |
| 5197 |
} |
| 5198 |
clnInv(str) { |
| 5199 |
return str.replace(jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.INVISIBLE_SPACE_REG_EXP(), ''); |
| 5200 |
} |
| 5201 |
onSelectAll(command) { |
| 5202 |
if (command.toLowerCase() === 'selectall' && this.j.getRealMode() === jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.MODE_SOURCE) { |
| 5203 |
var _this_sourceEditor; |
| 5204 |
(_this_sourceEditor = this.sourceEditor) === null || _this_sourceEditor === void 0 ? void 0 : _this_sourceEditor.selectAll(); |
| 5205 |
return false; |
| 5206 |
} |
| 5207 |
} |
| 5208 |
getMirrorValue() { |
| 5209 |
var _this_sourceEditor; |
| 5210 |
return ((_this_sourceEditor = this.sourceEditor) === null || _this_sourceEditor === void 0 ? void 0 : _this_sourceEditor.getValue()) || ''; |
| 5211 |
} |
| 5212 |
setMirrorValue(value) { |
| 5213 |
var _this_sourceEditor; |
| 5214 |
(_this_sourceEditor = this.sourceEditor) === null || _this_sourceEditor === void 0 ? void 0 : _this_sourceEditor.setValue(value); |
| 5215 |
} |
| 5216 |
setFocusToMirror() { |
| 5217 |
var _this_sourceEditor; |
| 5218 |
(_this_sourceEditor = this.sourceEditor) === null || _this_sourceEditor === void 0 ? void 0 : _this_sourceEditor.focus(); |
| 5219 |
} |
| 5220 |
saveSelection() { |
| 5221 |
if (this.j.getRealMode() === jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.MODE_WYSIWYG) { |
| 5222 |
this.j.s.save(); |
| 5223 |
this.j.synchronizeValues(); |
| 5224 |
this.fromWYSIWYG(true); |
| 5225 |
} else { |
| 5226 |
if (this.j.o.editHTMLDocumentMode) { |
| 5227 |
return; |
| 5228 |
} |
| 5229 |
const value = this.getMirrorValue(); |
| 5230 |
if (this.getSelectionStart() === this.getSelectionEnd()) { |
| 5231 |
const marker = this.j.s.marker(true); |
| 5232 |
const selectionStart = this.getNormalPosition(this.getSelectionStart(), this.getMirrorValue()); |
| 5233 |
this.setMirrorValue(value.substring(0, selectionStart) + this.clnInv(marker.outerHTML) + value.substring(selectionStart)); |
| 5234 |
} else { |
| 5235 |
const markerStart = this.j.s.marker(true); |
| 5236 |
const markerEnd = this.j.s.marker(false); |
| 5237 |
const selectionStart = this.getNormalPosition(this.getSelectionStart(), value); |
| 5238 |
const selectionEnd = this.getNormalPosition(this.getSelectionEnd(), value); |
| 5239 |
this.setMirrorValue(value.slice(0, selectionStart) + this.clnInv(markerStart.outerHTML) + value.slice(selectionStart, selectionEnd) + this.clnInv(markerEnd.outerHTML) + value.slice(selectionEnd)); |
| 5240 |
} |
| 5241 |
this.toWYSIWYG(); |
| 5242 |
} |
| 5243 |
} |
| 5244 |
removeSelection() { |
| 5245 |
if (this.j.getRealMode() === jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.MODE_WYSIWYG) { |
| 5246 |
this.__lock = true; |
| 5247 |
this.j.s.restore(); |
| 5248 |
this.__lock = false; |
| 5249 |
return; |
| 5250 |
} |
| 5251 |
let value = this.getMirrorValue(); |
| 5252 |
let selectionStart = 0, selectionEnd = 0; |
| 5253 |
try { |
| 5254 |
value = value.replace(/<span[^>]+data-jodit-selection_marker=(["'])start\1[^>]*>[<>]*?<\/span>/gim, this.tempMarkerStart).replace(/<span[^>]+data-jodit-selection_marker=(["'])end\1[^>]*>[<>]*?<\/span>/gim, this.tempMarkerEnd); |
| 5255 |
if (!this.j.o.editHTMLDocumentMode && this.j.o.beautifyHTML) { |
| 5256 |
const html = this.j.e.fire('beautifyHTML', value); |
| 5257 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.isString)(html)) { |
| 5258 |
value = html; |
| 5259 |
} |
| 5260 |
} |
| 5261 |
selectionStart = value.indexOf(this.tempMarkerStart); |
| 5262 |
selectionEnd = selectionStart; |
| 5263 |
value = value.replace(this.tempMarkerStartReg, ''); |
| 5264 |
if (selectionStart !== -1) { |
| 5265 |
const selectionEndCursor = value.indexOf(this.tempMarkerEnd); |
| 5266 |
if (selectionEndCursor !== -1) { |
| 5267 |
selectionEnd = selectionEndCursor; |
| 5268 |
} |
| 5269 |
} |
| 5270 |
value = value.replace(this.tempMarkerEndReg, ''); |
| 5271 |
} finally{ |
| 5272 |
value = value.replace(this.tempMarkerEndReg, '').replace(this.tempMarkerStartReg, ''); |
| 5273 |
} |
| 5274 |
this.setMirrorValue(value); |
| 5275 |
this.setMirrorSelectionRange(selectionStart, selectionEnd); |
| 5276 |
this.toWYSIWYG(); |
| 5277 |
this.setFocusToMirror(); // need for setting focus after change mode |
| 5278 |
} |
| 5279 |
setMirrorSelectionRange(start, end) { |
| 5280 |
var _this_sourceEditor; |
| 5281 |
(_this_sourceEditor = this.sourceEditor) === null || _this_sourceEditor === void 0 ? void 0 : _this_sourceEditor.setSelectionRange(start, end); |
| 5282 |
} |
| 5283 |
onReadonlyReact() { |
| 5284 |
var _this_sourceEditor; |
| 5285 |
(_this_sourceEditor = this.sourceEditor) === null || _this_sourceEditor === void 0 ? void 0 : _this_sourceEditor.setReadOnly(this.j.o.readonly); |
| 5286 |
} |
| 5287 |
/** @override */ afterInit(editor) { |
| 5288 |
this.mirrorContainer = editor.c.div('jodit-source'); |
| 5289 |
editor.workplace.appendChild(this.mirrorContainer); |
| 5290 |
editor.e.on('afterAddPlace changePlace afterInit', ()=>{ |
| 5291 |
editor.workplace.appendChild(this.mirrorContainer); |
| 5292 |
}); |
| 5293 |
this.sourceEditor = (0,_editor_factory__WEBPACK_IMPORTED_MODULE_9__.createSourceEditor)('area', editor, this.mirrorContainer, this.toWYSIWYG, this.fromWYSIWYG); |
| 5294 |
editor.e.on(editor.ow, 'keydown', (e)=>{ |
| 5295 |
var _this_sourceEditor; |
| 5296 |
if (e.key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.KEY_ESC && ((_this_sourceEditor = this.sourceEditor) === null || _this_sourceEditor === void 0 ? void 0 : _this_sourceEditor.isFocused)) { |
| 5297 |
this.sourceEditor.blur(); |
| 5298 |
} |
| 5299 |
}); |
| 5300 |
this.onReadonlyReact(); |
| 5301 |
editor.e.on('placeholder.source', (text)=>{ |
| 5302 |
var _this_sourceEditor; |
| 5303 |
(_this_sourceEditor = this.sourceEditor) === null || _this_sourceEditor === void 0 ? void 0 : _this_sourceEditor.setPlaceHolder(text); |
| 5304 |
}).on('change.source', this.syncValueFromWYSIWYG).on('beautifyHTML', (html)=>html); |
| 5305 |
if (editor.o.beautifyHTML) { |
| 5306 |
const addEventListener = ()=>{ |
| 5307 |
if (editor.isInDestruct) { |
| 5308 |
return false; |
| 5309 |
} |
| 5310 |
const html_beautify = editor.ow.html_beautify; |
| 5311 |
if (html_beautify && !editor.isInDestruct) { |
| 5312 |
var _editor_events; |
| 5313 |
(_editor_events = editor.events) === null || _editor_events === void 0 ? void 0 : _editor_events.off('beautifyHTML').on('beautifyHTML', (html)=>html_beautify(html)); |
| 5314 |
return true; |
| 5315 |
} |
| 5316 |
return false; |
| 5317 |
}; |
| 5318 |
if (!addEventListener()) { |
| 5319 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.loadNext)(editor, editor.o.beautifyHTMLCDNUrlsJS).then(addEventListener, ()=>null); |
| 5320 |
} |
| 5321 |
} |
| 5322 |
this.syncValueFromWYSIWYG(true); |
| 5323 |
this.initSourceEditor(editor); |
| 5324 |
} |
| 5325 |
syncValueFromWYSIWYG(force = false) { |
| 5326 |
const editor = this.j; |
| 5327 |
if (editor.getMode() === jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.MODE_SPLIT || editor.getMode() === jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.MODE_SOURCE) { |
| 5328 |
this.fromWYSIWYG(force); |
| 5329 |
} |
| 5330 |
} |
| 5331 |
initSourceEditor(editor) { |
| 5332 |
if (editor.o.sourceEditor !== 'area') { |
| 5333 |
const sourceEditor = (0,_editor_factory__WEBPACK_IMPORTED_MODULE_9__.createSourceEditor)(editor.o.sourceEditor, editor, this.mirrorContainer, this.toWYSIWYG, this.fromWYSIWYG); |
| 5334 |
sourceEditor.onReadyAlways(()=>{ |
| 5335 |
var _this_sourceEditor, _editor_events; |
| 5336 |
(_this_sourceEditor = this.sourceEditor) === null || _this_sourceEditor === void 0 ? void 0 : _this_sourceEditor.destruct(); |
| 5337 |
this.sourceEditor = sourceEditor; |
| 5338 |
this.syncValueFromWYSIWYG(true); |
| 5339 |
(_editor_events = editor.events) === null || _editor_events === void 0 ? void 0 : _editor_events.fire('sourceEditorReady', editor); |
| 5340 |
}); |
| 5341 |
} else { |
| 5342 |
var _this_sourceEditor; |
| 5343 |
(_this_sourceEditor = this.sourceEditor) === null || _this_sourceEditor === void 0 ? void 0 : _this_sourceEditor.onReadyAlways(()=>{ |
| 5344 |
var _editor_events; |
| 5345 |
this.syncValueFromWYSIWYG(true); |
| 5346 |
(_editor_events = editor.events) === null || _editor_events === void 0 ? void 0 : _editor_events.fire('sourceEditorReady', editor); |
| 5347 |
}); |
| 5348 |
} |
| 5349 |
} |
| 5350 |
/** @override */ beforeDestruct() { |
| 5351 |
if (this.sourceEditor) { |
| 5352 |
this.sourceEditor.destruct(); |
| 5353 |
delete this.sourceEditor; |
| 5354 |
} |
| 5355 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeRemove(this.mirrorContainer); |
| 5356 |
} |
| 5357 |
constructor(...args){ |
| 5358 |
super(...args), /** @override */ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "buttons", [ |
| 5359 |
{ |
| 5360 |
name: 'source', |
| 5361 |
group: 'source' |
| 5362 |
} |
| 5363 |
]), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "sourceEditor", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "mirrorContainer", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__lock", false), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__oldMirrorValue", ''), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "tempMarkerStart", '{start-jodit-selection}'), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "tempMarkerStartReg", /{start-jodit-selection}/g), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "tempMarkerEnd", '{end-jodit-selection}'), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "tempMarkerEndReg", /{end-jodit-selection}/g), // override it for ace editors |
| 5364 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "getSelectionStart", ()=>{ |
| 5365 |
var _ref; |
| 5366 |
var _this_sourceEditor; |
| 5367 |
return (_ref = (_this_sourceEditor = this.sourceEditor) === null || _this_sourceEditor === void 0 ? void 0 : _this_sourceEditor.getSelectionStart()) !== null && _ref !== void 0 ? _ref : 0; |
| 5368 |
}), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "getSelectionEnd", ()=>{ |
| 5369 |
var _ref; |
| 5370 |
var _this_sourceEditor; |
| 5371 |
return (_ref = (_this_sourceEditor = this.sourceEditor) === null || _this_sourceEditor === void 0 ? void 0 : _this_sourceEditor.getSelectionEnd()) !== null && _ref !== void 0 ? _ref : 0; |
| 5372 |
}); |
| 5373 |
} |
| 5374 |
} |
| 5375 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 5376 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.watch)(':insertHTML.source') |
| 5377 |
], source.prototype, "onInsertHTML", null); |
| 5378 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 5379 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 5380 |
], source.prototype, "fromWYSIWYG", null); |
| 5381 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 5382 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 5383 |
], source.prototype, "toWYSIWYG", null); |
| 5384 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 5385 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 5386 |
], source.prototype, "getNormalPosition", null); |
| 5387 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 5388 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.watch)(':beforeCommand.source') |
| 5389 |
], source.prototype, "onSelectAll", null); |
| 5390 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 5391 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.watch)(':beforeSetMode.source') |
| 5392 |
], source.prototype, "saveSelection", null); |
| 5393 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 5394 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.watch)(':afterSetMode.source') |
| 5395 |
], source.prototype, "removeSelection", null); |
| 5396 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 5397 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 5398 |
], source.prototype, "setMirrorSelectionRange", null); |
| 5399 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 5400 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.watch)(':readonly.source') |
| 5401 |
], source.prototype, "onReadonlyReact", null); |
| 5402 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 5403 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 5404 |
], source.prototype, "syncValueFromWYSIWYG", null); |
| 5405 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_5__.pluginSystem.add('source', source); |
| 5406 |
|
| 5407 |
|
| 5408 |
/***/ }), |
| 5409 |
|
| 5410 |
/***/ 14006: |
| 5411 |
/***/ (function(module) { |
| 5412 |
|
| 5413 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M1216 320q0 26-19 45t-45 19h-128v1024h128q26 0 45 19t19 45-19 45l-256 256q-19 19-45 19t-45-19l-256-256q-19-19-19-45t19-45 45-19h128v-1024h-128q-26 0-45-19t-19-45 19-45l256-256q19-19 45-19t45 19l256 256q19 19 19 45z\"/> </svg>" |
| 5414 |
|
| 5415 |
/***/ }), |
| 5416 |
|
| 5417 |
/***/ 14017: |
| 5418 |
/***/ (function(module) { |
| 5419 |
|
| 5420 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M384 544v576q0 13-9.5 22.5t-22.5 9.5q-14 0-23-9l-288-288q-9-9-9-23t9-23l288-288q9-9 23-9 13 0 22.5 9.5t9.5 22.5zm1408 768v192q0 13-9.5 22.5t-22.5 9.5h-1728q-13 0-22.5-9.5t-9.5-22.5v-192q0-13 9.5-22.5t22.5-9.5h1728q13 0 22.5 9.5t9.5 22.5zm0-384v192q0 13-9.5 22.5t-22.5 9.5h-1088q-13 0-22.5-9.5t-9.5-22.5v-192q0-13 9.5-22.5t22.5-9.5h1088q13 0 22.5 9.5t9.5 22.5zm0-384v192q0 13-9.5 22.5t-22.5 9.5h-1088q-13 0-22.5-9.5t-9.5-22.5v-192q0-13 9.5-22.5t22.5-9.5h1088q13 0 22.5 9.5t9.5 22.5zm0-384v192q0 13-9.5 22.5t-22.5 9.5h-1728q-13 0-22.5-9.5t-9.5-22.5v-192q0-13 9.5-22.5t22.5-9.5h1728q13 0 22.5 9.5t9.5 22.5z\"/> </svg>" |
| 5421 |
|
| 5422 |
/***/ }), |
| 5423 |
|
| 5424 |
/***/ 14099: |
| 5425 |
/***/ (function(module) { |
| 5426 |
|
| 5427 |
/*! |
| 5428 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 5429 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 5430 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 5431 |
*/ module.exports = { |
| 5432 |
symbols: 'Símbolo' |
| 5433 |
}; |
| 5434 |
|
| 5435 |
|
| 5436 |
/***/ }), |
| 5437 |
|
| 5438 |
/***/ 14228: |
| 5439 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 5440 |
|
| 5441 |
"use strict"; |
| 5442 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 5443 |
/* harmony export */ abort: function() { return /* binding */ abort; } |
| 5444 |
/* harmony export */ }); |
| 5445 |
/*! |
| 5446 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 5447 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 5448 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 5449 |
*/ /** |
| 5450 |
* @module helpers/utils |
| 5451 |
*/ /** |
| 5452 |
* `AbortError` is not a separate exception, but rather a {@link DOMException} with a special `name`. |
| 5453 |
* https://webidl.spec.whatwg.org/#aborterror |
| 5454 |
*/ function abort(message = 'Aborted') { |
| 5455 |
return new DOMException(message, 'AbortError'); |
| 5456 |
} |
| 5457 |
|
| 5458 |
|
| 5459 |
/***/ }), |
| 5460 |
|
| 5461 |
/***/ 14248: |
| 5462 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 5463 |
|
| 5464 |
"use strict"; |
| 5465 |
/* unused harmony export resizeCells */ |
| 5466 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 5467 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 5468 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(81937); |
| 5469 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(84839); |
| 5470 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(23211); |
| 5471 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(28077); |
| 5472 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(65946); |
| 5473 |
/* harmony import */ var jodit_modules__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(60936); |
| 5474 |
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(51822); |
| 5475 |
/*! |
| 5476 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 5477 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 5478 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 5479 |
*/ /** |
| 5480 |
* [[include:plugins/resize-cells/README.md]] |
| 5481 |
* @packageDocumentation |
| 5482 |
* @module plugins/resize-cells |
| 5483 |
*/ |
| 5484 |
|
| 5485 |
|
| 5486 |
|
| 5487 |
|
| 5488 |
|
| 5489 |
|
| 5490 |
|
| 5491 |
|
| 5492 |
|
| 5493 |
const key = 'table_processor_observer-resize'; |
| 5494 |
/** |
| 5495 |
* Process tables in editor |
| 5496 |
*/ class resizeCells extends jodit_modules__WEBPACK_IMPORTED_MODULE_7__.Plugin { |
| 5497 |
/** |
| 5498 |
* Shortcut for Table module |
| 5499 |
*/ get module() { |
| 5500 |
return this.j.getInstance('Table', this.j.o); |
| 5501 |
} |
| 5502 |
/** |
| 5503 |
* Now editor has rtl direction |
| 5504 |
*/ get isRTL() { |
| 5505 |
return this.j.o.direction === 'rtl'; |
| 5506 |
} |
| 5507 |
showResizeHandle() { |
| 5508 |
this.j.async.clearTimeout(this.hideTimeout); |
| 5509 |
this.j.workplace.appendChild(this.resizeHandler); |
| 5510 |
} |
| 5511 |
hideResizeHandle() { |
| 5512 |
this.hideTimeout = this.j.async.setTimeout(()=>{ |
| 5513 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeRemove(this.resizeHandler); |
| 5514 |
}, { |
| 5515 |
timeout: this.j.defaultTimeout, |
| 5516 |
label: 'hideResizer' |
| 5517 |
}); |
| 5518 |
} |
| 5519 |
/** |
| 5520 |
* Click on resize handle |
| 5521 |
*/ onHandleMouseDown(event) { |
| 5522 |
if (this.j.isLocked) { |
| 5523 |
return; |
| 5524 |
} |
| 5525 |
this.drag = true; |
| 5526 |
this.j.e.on(this.j.ow, 'mouseup.resize-cells touchend.resize-cells', this.onMouseUp).on(this.j.ew, 'mousemove.table touchmove.table', this.onMouseMove); |
| 5527 |
this.startX = event.clientX; |
| 5528 |
this.j.lock(key); |
| 5529 |
this.resizeHandler.classList.add('jodit-table-resizer_moved'); |
| 5530 |
let box, tableBox = this.workTable.getBoundingClientRect(); |
| 5531 |
this.minX = 0; |
| 5532 |
this.maxX = 1000000; |
| 5533 |
if (this.wholeTable != null) { |
| 5534 |
tableBox = this.workTable.parentNode.getBoundingClientRect(); |
| 5535 |
this.minX = tableBox.left; |
| 5536 |
this.maxX = this.minX + tableBox.width; |
| 5537 |
} else { |
| 5538 |
// find maximum columns |
| 5539 |
const coordinate = this.module.formalCoordinate(this.workTable, this.workCell, true); |
| 5540 |
this.module.formalMatrix(this.workTable, (td, i, j)=>{ |
| 5541 |
if (coordinate[1] === j) { |
| 5542 |
box = td.getBoundingClientRect(); |
| 5543 |
this.minX = Math.max(box.left + jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.NEARBY / 2, this.minX); |
| 5544 |
} |
| 5545 |
if (coordinate[1] + (this.isRTL ? -1 : 1) === j) { |
| 5546 |
box = td.getBoundingClientRect(); |
| 5547 |
this.maxX = Math.min(box.left + box.width - jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.NEARBY / 2, this.maxX); |
| 5548 |
} |
| 5549 |
}); |
| 5550 |
} |
| 5551 |
return false; |
| 5552 |
} |
| 5553 |
/** |
| 5554 |
* Mouse move after click on resize handle |
| 5555 |
*/ onMouseMove(event) { |
| 5556 |
if (!this.drag) { |
| 5557 |
return; |
| 5558 |
} |
| 5559 |
this.j.e.fire('closeAllPopups'); |
| 5560 |
let x = event.clientX; |
| 5561 |
const workplacePosition = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.offset)(this.resizeHandler.parentNode || this.j.od.documentElement, this.j, this.j.od, true); |
| 5562 |
if (x < this.minX) { |
| 5563 |
x = this.minX; |
| 5564 |
} |
| 5565 |
if (x > this.maxX) { |
| 5566 |
x = this.maxX; |
| 5567 |
} |
| 5568 |
this.resizeDelta = x - this.startX + (!this.j.o.iframe ? 0 : workplacePosition.left); |
| 5569 |
this.resizeHandler.style.left = x - (this.j.o.iframe ? 0 : workplacePosition.left) + 'px'; |
| 5570 |
const sel = this.j.s.sel; |
| 5571 |
sel && sel.removeAllRanges(); |
| 5572 |
} |
| 5573 |
/** |
| 5574 |
* Mouse up every where after move and click |
| 5575 |
*/ onMouseUp(e) { |
| 5576 |
if (this.selectMode || this.drag) { |
| 5577 |
this.selectMode = false; |
| 5578 |
this.j.unlock(); |
| 5579 |
} |
| 5580 |
if (!this.resizeHandler || !this.drag) { |
| 5581 |
return; |
| 5582 |
} |
| 5583 |
this.drag = false; |
| 5584 |
this.j.e.off(this.j.ew, 'mousemove.table touchmove.table', this.onMouseMove); |
| 5585 |
this.resizeHandler.classList.remove('jodit-table-resizer_moved'); |
| 5586 |
if (this.startX !== e.clientX) { |
| 5587 |
// resize column |
| 5588 |
if (this.wholeTable == null) { |
| 5589 |
this.resizeColumns(); |
| 5590 |
} else { |
| 5591 |
this.resizeTable(); |
| 5592 |
} |
| 5593 |
} |
| 5594 |
this.j.synchronizeValues(); |
| 5595 |
this.j.s.focus(); |
| 5596 |
} |
| 5597 |
/** |
| 5598 |
* Resize only one column |
| 5599 |
*/ resizeColumns() { |
| 5600 |
const delta = this.resizeDelta; |
| 5601 |
const marked = []; |
| 5602 |
const tableModule = this.module; |
| 5603 |
tableModule.setColumnWidthByDelta(this.workTable, tableModule.formalCoordinate(this.workTable, this.workCell, true)[1], delta, true, marked); |
| 5604 |
const nextTD = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.call)(this.isRTL ? jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.prev : jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.next, this.workCell, jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isCell, this.workCell.parentNode); |
| 5605 |
tableModule.setColumnWidthByDelta(this.workTable, tableModule.formalCoordinate(this.workTable, nextTD)[1], -delta, false, marked); |
| 5606 |
} |
| 5607 |
/** |
| 5608 |
* Resize whole table |
| 5609 |
*/ resizeTable() { |
| 5610 |
const delta = this.resizeDelta * (this.isRTL ? -1 : 1); |
| 5611 |
const width = this.workTable.offsetWidth, parentWidth = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.getContentWidth)(this.workTable.parentNode, this.j.ew); |
| 5612 |
// for RTL use mirror logic |
| 5613 |
const rightSide = !this.wholeTable; |
| 5614 |
const needChangeWidth = this.isRTL ? !rightSide : rightSide; |
| 5615 |
// right side |
| 5616 |
if (needChangeWidth) { |
| 5617 |
this.workTable.style.width = (width + delta) / parentWidth * 100 + '%'; |
| 5618 |
} else { |
| 5619 |
const side = this.isRTL ? 'marginRight' : 'marginLeft'; |
| 5620 |
const margin = parseInt(this.j.ew.getComputedStyle(this.workTable)[side] || '0', 10); |
| 5621 |
this.workTable.style.width = (width - delta) / parentWidth * 100 + '%'; |
| 5622 |
this.workTable.style[side] = (margin + delta) / parentWidth * 100 + '%'; |
| 5623 |
} |
| 5624 |
} |
| 5625 |
/** |
| 5626 |
* Memoize current cell |
| 5627 |
* |
| 5628 |
* @param wholeTable - resize whole table by left side, |
| 5629 |
* false - resize whole table by right side, null - resize column |
| 5630 |
*/ setWorkCell(cell, wholeTable = null) { |
| 5631 |
this.wholeTable = wholeTable; |
| 5632 |
this.workCell = cell; |
| 5633 |
this.workTable = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.up(cell, (elm)=>jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isTag(elm, 'table'), this.j.editor); |
| 5634 |
} |
| 5635 |
/** |
| 5636 |
* Calc helper resize handle position |
| 5637 |
*/ calcHandlePosition(table, cell, offsetX = 0, delta = 0) { |
| 5638 |
const box = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.offset)(cell, this.j, this.j.ed); |
| 5639 |
if (offsetX > jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.NEARBY && offsetX < box.width - jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.NEARBY) { |
| 5640 |
this.hideResizeHandle(); |
| 5641 |
return; |
| 5642 |
} |
| 5643 |
const workplacePosition = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.offset)(this.j.workplace, this.j, this.j.od, true), parentBox = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.offset)(table, this.j, this.j.ed); |
| 5644 |
this.resizeHandler.style.left = (offsetX <= jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.NEARBY ? box.left : box.left + box.width) - workplacePosition.left + delta + 'px'; |
| 5645 |
Object.assign(this.resizeHandler.style, { |
| 5646 |
height: parentBox.height + 'px', |
| 5647 |
top: parentBox.top - workplacePosition.top + 'px' |
| 5648 |
}); |
| 5649 |
this.showResizeHandle(); |
| 5650 |
if (offsetX <= jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.NEARBY) { |
| 5651 |
const prevTD = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.call)(this.isRTL ? jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.next : jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.prev, cell, jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isCell, cell.parentNode); |
| 5652 |
this.setWorkCell(prevTD || cell, prevTD ? null : true); |
| 5653 |
} else { |
| 5654 |
const nextTD = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.call)(!this.isRTL ? jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.next : jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.prev, cell, jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isCell, cell.parentNode); |
| 5655 |
this.setWorkCell(cell, !nextTD ? false : null); |
| 5656 |
} |
| 5657 |
} |
| 5658 |
/** @override */ afterInit(editor) { |
| 5659 |
if (!editor.o.tableAllowCellResize) { |
| 5660 |
return; |
| 5661 |
} |
| 5662 |
editor.e.off(this.j.ow, '.resize-cells').off('.resize-cells').on('change.resize-cells afterCommand.resize-cells afterSetMode.resize-cells', ()=>{ |
| 5663 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.$$)('table', editor.editor).forEach(this.observe); |
| 5664 |
}).on(this.j.ow, 'scroll.resize-cells', ()=>{ |
| 5665 |
if (!this.drag) { |
| 5666 |
return; |
| 5667 |
} |
| 5668 |
const parent = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.up(this.workCell, (elm)=>jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isTag(elm, 'table'), editor.editor); |
| 5669 |
if (parent) { |
| 5670 |
const parentBox = parent.getBoundingClientRect(); |
| 5671 |
this.resizeHandler.style.top = parentBox.top + 'px'; |
| 5672 |
} |
| 5673 |
}).on('beforeSetMode.resize-cells', ()=>{ |
| 5674 |
const tableModule = this.module; |
| 5675 |
tableModule.getAllSelectedCells().forEach((td)=>{ |
| 5676 |
tableModule.removeSelection(td); |
| 5677 |
tableModule.normalizeTable(jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.closest(td, 'table', editor.editor)); |
| 5678 |
}); |
| 5679 |
}); |
| 5680 |
} |
| 5681 |
/** |
| 5682 |
* Add to every Table listeners |
| 5683 |
*/ observe(table) { |
| 5684 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.dataBind)(table, key)) { |
| 5685 |
return; |
| 5686 |
} |
| 5687 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.dataBind)(table, key, true); |
| 5688 |
this.j.e.on(table, 'mouseleave.resize-cells', (e)=>{ |
| 5689 |
if (this.resizeHandler && this.resizeHandler !== e.relatedTarget) { |
| 5690 |
this.hideResizeHandle(); |
| 5691 |
} |
| 5692 |
}).on(table, 'mousemove.resize-cells touchmove.resize-cells', this.j.async.throttle((event)=>{ |
| 5693 |
if (this.j.isLocked) { |
| 5694 |
return; |
| 5695 |
} |
| 5696 |
const cell = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.up(event.target, jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isCell, table); |
| 5697 |
if (!cell) { |
| 5698 |
return; |
| 5699 |
} |
| 5700 |
this.calcHandlePosition(table, cell, event.offsetX); |
| 5701 |
}, { |
| 5702 |
timeout: this.j.defaultTimeout |
| 5703 |
})); |
| 5704 |
this.createResizeHandle(); |
| 5705 |
} |
| 5706 |
beforeDestruct(jodit) { |
| 5707 |
if (jodit.events) { |
| 5708 |
jodit.e.off(this.j.ow, '.resize-cells'); |
| 5709 |
jodit.e.off('.resize-cells'); |
| 5710 |
} |
| 5711 |
} |
| 5712 |
constructor(...args){ |
| 5713 |
super(...args), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "selectMode", false), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "resizeDelta", 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "resizeHandler", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "createResizeHandle", ()=>{ |
| 5714 |
if (!this.resizeHandler) { |
| 5715 |
this.resizeHandler = this.j.c.div('jodit-table-resizer'); |
| 5716 |
this.j.e.on(this.resizeHandler, 'mousedown.table touchstart.table', this.onHandleMouseDown).on(this.resizeHandler, 'mouseenter.table', ()=>{ |
| 5717 |
this.j.async.clearTimeout(this.hideTimeout); |
| 5718 |
}); |
| 5719 |
} |
| 5720 |
}), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "hideTimeout", 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "drag", false), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "wholeTable", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "workCell", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "workTable", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "minX", 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "maxX", 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "startX", 0); |
| 5721 |
} |
| 5722 |
} |
| 5723 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 5724 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 5725 |
], resizeCells.prototype, "onHandleMouseDown", null); |
| 5726 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 5727 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 5728 |
], resizeCells.prototype, "onMouseMove", null); |
| 5729 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 5730 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 5731 |
], resizeCells.prototype, "onMouseUp", null); |
| 5732 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 5733 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 5734 |
], resizeCells.prototype, "observe", null); |
| 5735 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_5__.pluginSystem.add('resizeCells', resizeCells); |
| 5736 |
|
| 5737 |
|
| 5738 |
/***/ }), |
| 5739 |
|
| 5740 |
/***/ 14305: |
| 5741 |
/***/ (function(module) { |
| 5742 |
|
| 5743 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M1171 960q0 13-10 23l-466 466q-10 10-23 10t-23-10l-50-50q-10-10-10-23t10-23l393-393-393-393q-10-10-10-23t10-23l50-50q10-10 23-10t23 10l466 466q10 10 10 23z\"/> </svg>" |
| 5744 |
|
| 5745 |
/***/ }), |
| 5746 |
|
| 5747 |
/***/ 14907: |
| 5748 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 5749 |
|
| 5750 |
"use strict"; |
| 5751 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5266); |
| 5752 |
/*! |
| 5753 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 5754 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 5755 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 5756 |
*/ /** |
| 5757 |
* @module plugins/hotkeys |
| 5758 |
*/ |
| 5759 |
jodit_config__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.commandToHotkeys = { |
| 5760 |
removeFormat: [ |
| 5761 |
'ctrl+shift+m', |
| 5762 |
'cmd+shift+m' |
| 5763 |
], |
| 5764 |
insertOrderedList: [ |
| 5765 |
'ctrl+shift+7', |
| 5766 |
'cmd+shift+7' |
| 5767 |
], |
| 5768 |
insertUnorderedList: [ |
| 5769 |
'ctrl+shift+8, cmd+shift+8' |
| 5770 |
], |
| 5771 |
selectall: [ |
| 5772 |
'ctrl+a', |
| 5773 |
'cmd+a' |
| 5774 |
] |
| 5775 |
}; |
| 5776 |
|
| 5777 |
|
| 5778 |
/***/ }), |
| 5779 |
|
| 5780 |
/***/ 15200: |
| 5781 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 5782 |
|
| 5783 |
"use strict"; |
| 5784 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 5785 |
/* harmony export */ findMostNestedNeighbor: function() { return /* binding */ findMostNestedNeighbor; }, |
| 5786 |
/* harmony export */ getMoveFilter: function() { return /* binding */ getMoveFilter; } |
| 5787 |
/* harmony export */ }); |
| 5788 |
/* harmony import */ var jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(27795); |
| 5789 |
/*! |
| 5790 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 5791 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 5792 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 5793 |
*/ /** |
| 5794 |
* @module plugins/backspace |
| 5795 |
*/ |
| 5796 |
/** |
| 5797 |
* Finds the nearest neighbor that would be in the maximum nesting depth. |
| 5798 |
* Ie if neighbor `<DIV><SPAN>Text` then return Text node. |
| 5799 |
* @private |
| 5800 |
*/ function findMostNestedNeighbor(node, right, root, onlyInlide = false) { |
| 5801 |
const nextChild = (node)=>right ? node.firstChild : node.lastChild; |
| 5802 |
let next = jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.findNotEmptyNeighbor(node, !right, root); |
| 5803 |
if (onlyInlide && jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isElement(next) && !jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isInlineBlock(next)) { |
| 5804 |
return null; |
| 5805 |
} |
| 5806 |
if (next) { |
| 5807 |
do { |
| 5808 |
if (nextChild(next)) { |
| 5809 |
next = nextChild(next); |
| 5810 |
} else { |
| 5811 |
return next; |
| 5812 |
} |
| 5813 |
}while (next) |
| 5814 |
} |
| 5815 |
return null; |
| 5816 |
} |
| 5817 |
/** |
| 5818 |
* @private |
| 5819 |
*/ function getMoveFilter(jodit) { |
| 5820 |
return (node)=>jodit.e.fire('backSpaceIsMovedIgnore', node) !== true; |
| 5821 |
} |
| 5822 |
|
| 5823 |
|
| 5824 |
/***/ }), |
| 5825 |
|
| 5826 |
/***/ 15223: |
| 5827 |
/***/ (function(module) { |
| 5828 |
|
| 5829 |
/*! |
| 5830 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 5831 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 5832 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 5833 |
*/ module.exports = { |
| 5834 |
'copy-format': '複製格式' |
| 5835 |
}; |
| 5836 |
|
| 5837 |
|
| 5838 |
/***/ }), |
| 5839 |
|
| 5840 |
/***/ 15366: |
| 5841 |
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { |
| 5842 |
|
| 5843 |
"use strict"; |
| 5844 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 5845 |
/* harmony export */ _: function() { return /* binding */ _object_spread_props; } |
| 5846 |
/* harmony export */ }); |
| 5847 |
function ownKeys(object, enumerableOnly) { |
| 5848 |
var keys = Object.keys(object); |
| 5849 |
if (Object.getOwnPropertySymbols) { |
| 5850 |
var symbols = Object.getOwnPropertySymbols(object); |
| 5851 |
if (enumerableOnly) { |
| 5852 |
symbols = symbols.filter(function(sym) { |
| 5853 |
return Object.getOwnPropertyDescriptor(object, sym).enumerable; |
| 5854 |
}); |
| 5855 |
} |
| 5856 |
keys.push.apply(keys, symbols); |
| 5857 |
} |
| 5858 |
return keys; |
| 5859 |
} |
| 5860 |
function _object_spread_props(target, source) { |
| 5861 |
source = source != null ? source : {}; |
| 5862 |
if (Object.getOwnPropertyDescriptors) Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); |
| 5863 |
else { |
| 5864 |
ownKeys(Object(source)).forEach(function(key) { |
| 5865 |
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); |
| 5866 |
}); |
| 5867 |
} |
| 5868 |
return target; |
| 5869 |
} |
| 5870 |
|
| 5871 |
|
| 5872 |
|
| 5873 |
/***/ }), |
| 5874 |
|
| 5875 |
/***/ 15367: |
| 5876 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 5877 |
|
| 5878 |
"use strict"; |
| 5879 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 5880 |
/* harmony export */ UIButtonGroup: function() { return /* binding */ UIButtonGroup; } |
| 5881 |
/* harmony export */ }); |
| 5882 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 5883 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 5884 |
/* harmony import */ var jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(91672); |
| 5885 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(28712); |
| 5886 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_3__); |
| 5887 |
/* harmony import */ var jodit_core_ui_button_button_button__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(53681); |
| 5888 |
/* harmony import */ var jodit_core_ui_group_group__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(63468); |
| 5889 |
/*! |
| 5890 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 5891 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 5892 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 5893 |
*/ /** |
| 5894 |
* @module ui/button |
| 5895 |
*/ |
| 5896 |
|
| 5897 |
|
| 5898 |
|
| 5899 |
|
| 5900 |
|
| 5901 |
|
| 5902 |
class UIButtonGroup extends jodit_core_ui_group_group__WEBPACK_IMPORTED_MODULE_5__.UIGroup { |
| 5903 |
/** @override */ className() { |
| 5904 |
return 'UIButtonGroup'; |
| 5905 |
} |
| 5906 |
/** @override */ render(options) { |
| 5907 |
return `<div> |
| 5908 |
<div class="&__label">~${options.label}~</div> |
| 5909 |
<div class="&__options"></div> |
| 5910 |
</div>`; |
| 5911 |
} |
| 5912 |
/** @override */ appendChildToContainer(childContainer) { |
| 5913 |
const options = this.getElm('options'); |
| 5914 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_3__.assert)(options != null, 'Options does not exist'); |
| 5915 |
options.appendChild(childContainer); |
| 5916 |
} |
| 5917 |
select(indexOrValue) { |
| 5918 |
var _this_options_onChange, _this_options; |
| 5919 |
this.elements.forEach((elm, index)=>{ |
| 5920 |
if (index === indexOrValue || elm.state.value === indexOrValue) { |
| 5921 |
elm.state.activated = true; |
| 5922 |
} else if (this.options.radio) { |
| 5923 |
elm.state.activated = false; |
| 5924 |
} |
| 5925 |
}); |
| 5926 |
const result = this.elements.filter((elm)=>elm.state.activated).map((elm)=>({ |
| 5927 |
text: elm.state.text, |
| 5928 |
value: elm.state.value |
| 5929 |
})); |
| 5930 |
this.jodit.e.fire(this, 'select', result); |
| 5931 |
(_this_options_onChange = (_this_options = this.options).onChange) === null || _this_options_onChange === void 0 ? void 0 : _this_options_onChange.call(_this_options, result); |
| 5932 |
} |
| 5933 |
constructor(jodit, options = { |
| 5934 |
radio: true |
| 5935 |
}){ |
| 5936 |
var _options_value; |
| 5937 |
var _options_options; |
| 5938 |
super(jodit, (_options_options = options.options) === null || _options_options === void 0 ? void 0 : _options_options.map((opt)=>{ |
| 5939 |
const btn = new jodit_core_ui_button_button_button__WEBPACK_IMPORTED_MODULE_4__.UIButton(jodit, { |
| 5940 |
text: opt.text, |
| 5941 |
value: opt.value, |
| 5942 |
variant: 'primary' |
| 5943 |
}); |
| 5944 |
btn.onAction(()=>{ |
| 5945 |
this.select(opt.value); |
| 5946 |
}); |
| 5947 |
return btn; |
| 5948 |
}), options), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "options", void 0), this.options = options; |
| 5949 |
this.select((_options_value = options.value) !== null && _options_value !== void 0 ? _options_value : 0); |
| 5950 |
} |
| 5951 |
} |
| 5952 |
UIButtonGroup = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 5953 |
jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_2__.component |
| 5954 |
], UIButtonGroup); |
| 5955 |
|
| 5956 |
|
| 5957 |
/***/ }), |
| 5958 |
|
| 5959 |
/***/ 15753: |
| 5960 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 5961 |
|
| 5962 |
"use strict"; |
| 5963 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 5964 |
/* harmony export */ ColorPickerWidget: function() { return /* reexport safe */ _color_picker_color_picker__WEBPACK_IMPORTED_MODULE_0__.ColorPickerWidget; }, |
| 5965 |
/* harmony export */ FileSelectorWidget: function() { return /* reexport safe */ _file_selector_file_selector__WEBPACK_IMPORTED_MODULE_1__.FileSelectorWidget; }, |
| 5966 |
/* harmony export */ TabsWidget: function() { return /* reexport safe */ _tabs_tabs__WEBPACK_IMPORTED_MODULE_2__.TabsWidget; } |
| 5967 |
/* harmony export */ }); |
| 5968 |
/* harmony import */ var _color_picker_color_picker__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(72348); |
| 5969 |
/* harmony import */ var _file_selector_file_selector__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(18762); |
| 5970 |
/* harmony import */ var _tabs_tabs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(89636); |
| 5971 |
/*! |
| 5972 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 5973 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 5974 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 5975 |
*/ /** |
| 5976 |
* [[include:modules/widget/README.md]] |
| 5977 |
* @packageDocumentation |
| 5978 |
* @module modules/widget |
| 5979 |
*/ |
| 5980 |
|
| 5981 |
|
| 5982 |
|
| 5983 |
|
| 5984 |
/***/ }), |
| 5985 |
|
| 5986 |
/***/ 15982: |
| 5987 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 5988 |
|
| 5989 |
"use strict"; |
| 5990 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 5991 |
/* harmony export */ findControlType: function() { return /* binding */ findControlType; }, |
| 5992 |
/* harmony export */ getControlType: function() { return /* binding */ getControlType; } |
| 5993 |
/* harmony export */ }); |
| 5994 |
/* harmony import */ var _swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(41411); |
| 5995 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(65946); |
| 5996 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5266); |
| 5997 |
/*! |
| 5998 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 5999 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 6000 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 6001 |
*/ /** |
| 6002 |
* @module ui |
| 6003 |
*/ |
| 6004 |
|
| 6005 |
|
| 6006 |
/** |
| 6007 |
* Get control for button name |
| 6008 |
* @private |
| 6009 |
*/ function getControlType(button, controls) { |
| 6010 |
let buttonControl; |
| 6011 |
if (!controls) { |
| 6012 |
controls = jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.defaultOptions.controls; |
| 6013 |
} |
| 6014 |
if (!(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__.isString)(button)) { |
| 6015 |
buttonControl = (0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__._)({ |
| 6016 |
name: 'empty' |
| 6017 |
}, (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__.ConfigFlatten)(button)); |
| 6018 |
if (controls[buttonControl.name] !== undefined) { |
| 6019 |
buttonControl = (0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__._)({}, (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__.ConfigFlatten)(controls[buttonControl.name]), (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__.ConfigFlatten)(buttonControl)); |
| 6020 |
} |
| 6021 |
} else { |
| 6022 |
buttonControl = findControlType(button, controls) || { |
| 6023 |
name: button, |
| 6024 |
command: button, |
| 6025 |
tooltip: button |
| 6026 |
}; |
| 6027 |
} |
| 6028 |
return buttonControl; |
| 6029 |
} |
| 6030 |
/** |
| 6031 |
* @private |
| 6032 |
*/ function findControlType(path, controls) { |
| 6033 |
// eslint-disable-next-line prefer-const |
| 6034 |
let [namespaceOrKey, key] = path.split(/\./); |
| 6035 |
let store = controls; |
| 6036 |
if (key != null) { |
| 6037 |
if (controls[namespaceOrKey] !== undefined) { |
| 6038 |
store = controls[namespaceOrKey]; |
| 6039 |
} |
| 6040 |
} else { |
| 6041 |
key = namespaceOrKey; |
| 6042 |
} |
| 6043 |
// const list = store[key]?.list; |
| 6044 |
return store[key] ? (0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__._)({ |
| 6045 |
name: key |
| 6046 |
}, (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__.ConfigFlatten)(store[key])) : undefined; |
| 6047 |
} |
| 6048 |
|
| 6049 |
|
| 6050 |
/***/ }), |
| 6051 |
|
| 6052 |
/***/ 16849: |
| 6053 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 6054 |
|
| 6055 |
"use strict"; |
| 6056 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 6057 |
/* harmony export */ alignElement: function() { return /* binding */ alignElement; }, |
| 6058 |
/* harmony export */ clearAlign: function() { return /* binding */ clearAlign; }, |
| 6059 |
/* harmony export */ hAlignElement: function() { return /* binding */ hAlignElement; } |
| 6060 |
/* harmony export */ }); |
| 6061 |
/* harmony import */ var jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(27795); |
| 6062 |
/* harmony import */ var jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(80991); |
| 6063 |
/*! |
| 6064 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 6065 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 6066 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 6067 |
*/ /** |
| 6068 |
* @module helpers/utils |
| 6069 |
*/ |
| 6070 |
|
| 6071 |
/** |
| 6072 |
* Align image |
| 6073 |
*/ function hAlignElement(image, align) { |
| 6074 |
if (align && align !== 'normal') { |
| 6075 |
if (align !== 'center') { |
| 6076 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_1__.css)(image, 'float', align); |
| 6077 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_1__.clearCenterAlign)(image); |
| 6078 |
} else { |
| 6079 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_1__.css)(image, { |
| 6080 |
float: '', |
| 6081 |
display: 'block', |
| 6082 |
marginLeft: 'auto', |
| 6083 |
marginRight: 'auto' |
| 6084 |
}); |
| 6085 |
} |
| 6086 |
} else { |
| 6087 |
if ((0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_1__.css)(image, 'float') && [ |
| 6088 |
'right', |
| 6089 |
'left' |
| 6090 |
].indexOf((0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_1__.css)(image, 'float').toString().toLowerCase()) !== -1) { |
| 6091 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_1__.css)(image, 'float', ''); |
| 6092 |
} |
| 6093 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_1__.clearCenterAlign)(image); |
| 6094 |
} |
| 6095 |
} |
| 6096 |
/** |
| 6097 |
* Remove text-align style for all selected children |
| 6098 |
*/ function clearAlign(node) { |
| 6099 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.each(node, (elm)=>{ |
| 6100 |
if (jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isHTMLElement(elm)) { |
| 6101 |
if (elm.style.textAlign) { |
| 6102 |
elm.style.textAlign = ''; |
| 6103 |
if (!elm.style.cssText.trim().length) { |
| 6104 |
elm.removeAttribute('style'); |
| 6105 |
} |
| 6106 |
} |
| 6107 |
} |
| 6108 |
}); |
| 6109 |
} |
| 6110 |
/** |
| 6111 |
* Apply align for element |
| 6112 |
*/ function alignElement(command, box) { |
| 6113 |
if (jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isNode(box) && jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isElement(box)) { |
| 6114 |
clearAlign(box); |
| 6115 |
switch(command.toLowerCase()){ |
| 6116 |
case 'justifyfull': |
| 6117 |
box.style.textAlign = 'justify'; |
| 6118 |
break; |
| 6119 |
case 'justifyright': |
| 6120 |
box.style.textAlign = 'right'; |
| 6121 |
break; |
| 6122 |
case 'justifyleft': |
| 6123 |
box.style.textAlign = 'left'; |
| 6124 |
break; |
| 6125 |
case 'justifycenter': |
| 6126 |
box.style.textAlign = 'center'; |
| 6127 |
break; |
| 6128 |
} |
| 6129 |
} |
| 6130 |
} |
| 6131 |
|
| 6132 |
|
| 6133 |
/***/ }), |
| 6134 |
|
| 6135 |
/***/ 16964: |
| 6136 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 6137 |
|
| 6138 |
"use strict"; |
| 6139 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 6140 |
/* harmony export */ Component: function() { return /* reexport safe */ _component__WEBPACK_IMPORTED_MODULE_0__.Component; }, |
| 6141 |
/* harmony export */ STATUSES: function() { return /* reexport safe */ _statuses__WEBPACK_IMPORTED_MODULE_1__.STATUSES; }, |
| 6142 |
/* harmony export */ ViewComponent: function() { return /* reexport safe */ _view_component__WEBPACK_IMPORTED_MODULE_2__.ViewComponent; } |
| 6143 |
/* harmony export */ }); |
| 6144 |
/* harmony import */ var _component__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(80251); |
| 6145 |
/* harmony import */ var _statuses__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(69364); |
| 6146 |
/* harmony import */ var _view_component__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(59609); |
| 6147 |
/*! |
| 6148 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 6149 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 6150 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 6151 |
*/ /** |
| 6152 |
* @module component |
| 6153 |
*/ |
| 6154 |
|
| 6155 |
|
| 6156 |
|
| 6157 |
|
| 6158 |
/***/ }), |
| 6159 |
|
| 6160 |
/***/ 17306: |
| 6161 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 6162 |
|
| 6163 |
"use strict"; |
| 6164 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 6165 |
/* harmony export */ UIImagePositionTab: function() { return /* binding */ UIImagePositionTab; } |
| 6166 |
/* harmony export */ }); |
| 6167 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 6168 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 6169 |
/* harmony import */ var jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(91672); |
| 6170 |
/* harmony import */ var jodit_core_decorators_hook_hook__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(29200); |
| 6171 |
/* harmony import */ var jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(68616); |
| 6172 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(65946); |
| 6173 |
/* harmony import */ var jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(85932); |
| 6174 |
/* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(7909); |
| 6175 |
/* harmony import */ var jodit_core_ui_element__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(96007); |
| 6176 |
/* harmony import */ var jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(29434); |
| 6177 |
/* harmony import */ var _utils_utils__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(10808); |
| 6178 |
/*! |
| 6179 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 6180 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 6181 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 6182 |
*/ /** |
| 6183 |
* @module plugins/image-properties |
| 6184 |
*/ |
| 6185 |
|
| 6186 |
|
| 6187 |
|
| 6188 |
|
| 6189 |
|
| 6190 |
|
| 6191 |
|
| 6192 |
|
| 6193 |
|
| 6194 |
|
| 6195 |
class UIImagePositionTab extends jodit_core_ui_element__WEBPACK_IMPORTED_MODULE_8__.UIElement { |
| 6196 |
className() { |
| 6197 |
return 'UIImagePositionTab'; |
| 6198 |
} |
| 6199 |
render({ availableClasses }) { |
| 6200 |
return `<div class="jodit-form__group &__editMargins"> |
| 6201 |
<label>~Margins~</label> |
| 6202 |
<div class="jodit-grid jodit_vertical_middle"> |
| 6203 |
<input class="jodit_col-lg-1-5 jodit-input &__marginTop" type="text" placeholder="~top~"/> |
| 6204 |
<a style="text-align: center;" class="jodit-properties__lock jodit_col-lg-1-5 &__lockMargin">*lock*</a> |
| 6205 |
<input disabled="disabled" class="jodit_col-lg-1-5 jodit-input &__marginRight" type="text" placeholder="~right~"/> |
| 6206 |
<input disabled="disabled" class="jodit_col-lg-1-5 jodit-input &__marginBottom" type="text" placeholder="~bottom~"/> |
| 6207 |
<input disabled="disabled" class="jodit_col-lg-1-5 jodit-input &__marginLeft" type="text" placeholder="~left~"/> |
| 6208 |
</div> |
| 6209 |
</div> |
| 6210 |
<div class="jodit-form__group &__editAlign"> |
| 6211 |
<label>~Align~</label> |
| 6212 |
<select class="jodit-select &__align"> |
| 6213 |
<option value="">~--Not Set--~</option> |
| 6214 |
<option value="left">~Left~</option> |
| 6215 |
<option value="center">~Center~</option> |
| 6216 |
<option value="right">~Right~</option> |
| 6217 |
</select> |
| 6218 |
</div> |
| 6219 |
<div class="jodit-form__group &__editStyle"> |
| 6220 |
<label>~Styles~</label> |
| 6221 |
<input type="text" class="jodit-input &__style"/> |
| 6222 |
</div> |
| 6223 |
<div class="jodit-form__group &__editClass"> |
| 6224 |
<label>~Classes~</label> |
| 6225 |
${(()=>{ |
| 6226 |
const classInput = []; |
| 6227 |
if (availableClasses && availableClasses.length > 0) { |
| 6228 |
classInput.push('<select class="jodit-input jodit-select &__classes">'); |
| 6229 |
availableClasses.forEach((item)=>{ |
| 6230 |
if ((0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_6__.isString)(item)) { |
| 6231 |
classInput.push(`<option value="${item}">${item}</option>`); |
| 6232 |
} else { |
| 6233 |
classInput.push(`<option value="${item[0]}">${item[1]}</option>`); |
| 6234 |
} |
| 6235 |
}); |
| 6236 |
classInput.push('</select>'); |
| 6237 |
} else { |
| 6238 |
classInput.push('<input type="text" class="jodit-input &__classes"/>'); |
| 6239 |
} |
| 6240 |
return classInput.join(''); |
| 6241 |
})()} |
| 6242 |
</div> |
| 6243 |
<div class="jodit-form__group &__editId"> |
| 6244 |
<label>Id</label> |
| 6245 |
<input type="text" class="jodit-input &__id"/> |
| 6246 |
</div> |
| 6247 |
<div |
| 6248 |
class="jodit-form__group &__editBorderRadius" |
| 6249 |
> |
| 6250 |
<label>~Border radius~</label> |
| 6251 |
<input type="number" class="jodit-input &__borderRadius"/> |
| 6252 |
</div>`; |
| 6253 |
} |
| 6254 |
onStateAlignChange() { |
| 6255 |
const align = this.getElm('align'); |
| 6256 |
align.value = this.state.values.align; |
| 6257 |
} |
| 6258 |
onChangeAlign() { |
| 6259 |
const align = this.getElm('align'); |
| 6260 |
this.state.values.align = align.value; |
| 6261 |
} |
| 6262 |
onStateValuesBorderRadiusChange() { |
| 6263 |
const borderRadius = this.getElm('borderRadius'); |
| 6264 |
borderRadius.value = this.state.values.borderRadius.toString(); |
| 6265 |
} |
| 6266 |
onChangeBorderRadius() { |
| 6267 |
const borderRadius = this.getElm('borderRadius'); |
| 6268 |
this.state.values.borderRadius = parseFloat(borderRadius.value); |
| 6269 |
} |
| 6270 |
onStateValuesIdChange() { |
| 6271 |
const id = this.getElm('id'); |
| 6272 |
id.value = this.state.values.id; |
| 6273 |
} |
| 6274 |
onChangeId() { |
| 6275 |
const id = this.getElm('id'); |
| 6276 |
this.state.values.id = id.value; |
| 6277 |
} |
| 6278 |
onStateValuesStyleChange() { |
| 6279 |
const style = this.getElm('style'); |
| 6280 |
style.value = this.state.values.style; |
| 6281 |
} |
| 6282 |
onChangeStyle() { |
| 6283 |
const style = this.getElm('style'); |
| 6284 |
this.state.values.style = style.value; |
| 6285 |
} |
| 6286 |
onStateValuesClassesChange() { |
| 6287 |
const classes = this.getElm('classes'); |
| 6288 |
classes.value = this.state.values.classes; |
| 6289 |
} |
| 6290 |
onChangClasses() { |
| 6291 |
const classes = this.getElm('classes'); |
| 6292 |
this.state.values.classes = classes.value; |
| 6293 |
} |
| 6294 |
onLockMarginClick(e) { |
| 6295 |
this.state.marginIsLocked = !this.state.marginIsLocked; |
| 6296 |
e.preventDefault(); |
| 6297 |
} |
| 6298 |
onChangeMarginIsLocked() { |
| 6299 |
const marginBottom = this.getElm('marginBottom'); |
| 6300 |
const marginRight = this.getElm('marginRight'); |
| 6301 |
const marginLeft = this.getElm('marginLeft'); |
| 6302 |
const lockMargin = this.getElm('lockMargin'); |
| 6303 |
[ |
| 6304 |
marginRight, |
| 6305 |
marginBottom, |
| 6306 |
marginLeft |
| 6307 |
].forEach((elm)=>{ |
| 6308 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_7__.attr)(elm, 'disabled', this.state.marginIsLocked || null); |
| 6309 |
}); |
| 6310 |
lockMargin.innerHTML = jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_9__.Icon.get(this.state.marginIsLocked ? 'lock' : 'unlock'); |
| 6311 |
if (this.state.marginIsLocked) { |
| 6312 |
const marginTop = this.state.values.marginTop; |
| 6313 |
this.state.values.marginRight = marginTop; |
| 6314 |
this.state.values.marginBottom = marginTop; |
| 6315 |
this.state.values.marginLeft = marginTop; |
| 6316 |
} |
| 6317 |
} |
| 6318 |
onStateValuesMarginChange() { |
| 6319 |
const marginTop = this.getElm('marginTop'); |
| 6320 |
const marginRight = this.getElm('marginRight'); |
| 6321 |
const marginBottom = this.getElm('marginBottom'); |
| 6322 |
const marginLeft = this.getElm('marginLeft'); |
| 6323 |
marginTop.value = this.state.values.marginTop.toString(); |
| 6324 |
marginRight.value = this.state.values.marginRight.toString(); |
| 6325 |
marginBottom.value = this.state.values.marginBottom.toString(); |
| 6326 |
marginLeft.value = this.state.values.marginLeft.toString(); |
| 6327 |
} |
| 6328 |
onChangeMargin() { |
| 6329 |
const marginTop = this.getElm('marginTop'); |
| 6330 |
const marginRight = this.getElm('marginRight'); |
| 6331 |
const marginBottom = this.getElm('marginBottom'); |
| 6332 |
const marginLeft = this.getElm('marginLeft'); |
| 6333 |
this.state.values.marginTop = (0,_utils_utils__WEBPACK_IMPORTED_MODULE_10__.normalSizeFromString)(marginTop.value); |
| 6334 |
if (this.state.marginIsLocked) { |
| 6335 |
this.state.values.marginRight = this.state.values.marginTop; |
| 6336 |
this.state.values.marginBottom = this.state.values.marginTop; |
| 6337 |
this.state.values.marginLeft = this.state.values.marginTop; |
| 6338 |
} else { |
| 6339 |
this.state.values.marginRight = (0,_utils_utils__WEBPACK_IMPORTED_MODULE_10__.normalSizeFromString)(marginRight.value); |
| 6340 |
this.state.values.marginBottom = (0,_utils_utils__WEBPACK_IMPORTED_MODULE_10__.normalSizeFromString)(marginBottom.value); |
| 6341 |
this.state.values.marginLeft = (0,_utils_utils__WEBPACK_IMPORTED_MODULE_10__.normalSizeFromString)(marginLeft.value); |
| 6342 |
} |
| 6343 |
} |
| 6344 |
hideFieldByOptions() { |
| 6345 |
const opt = this.j.o.image; |
| 6346 |
[ |
| 6347 |
[ |
| 6348 |
'editMargins', |
| 6349 |
'editMargins' |
| 6350 |
], |
| 6351 |
[ |
| 6352 |
'editAlign', |
| 6353 |
'editAlign' |
| 6354 |
], |
| 6355 |
[ |
| 6356 |
'editStyle', |
| 6357 |
'editStyle' |
| 6358 |
], |
| 6359 |
[ |
| 6360 |
'editClass', |
| 6361 |
'editClass' |
| 6362 |
], |
| 6363 |
[ |
| 6364 |
'editId', |
| 6365 |
'editId' |
| 6366 |
], |
| 6367 |
[ |
| 6368 |
'editBorderRadius', |
| 6369 |
'editBorderRadius' |
| 6370 |
] |
| 6371 |
].forEach(([optKey, elmKey])=>{ |
| 6372 |
const elm = this.getElm(elmKey); |
| 6373 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.css)(elm, 'display', opt[optKey] ? null : 'none'); |
| 6374 |
}); |
| 6375 |
} |
| 6376 |
constructor(jodit, state, handlers){ |
| 6377 |
super(jodit, { |
| 6378 |
availableClasses: jodit.o.image.availableClasses |
| 6379 |
}), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "state", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "handlers", void 0), this.state = state, this.handlers = handlers; |
| 6380 |
} |
| 6381 |
} |
| 6382 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 6383 |
(0,jodit_core_decorators_hook_hook__WEBPACK_IMPORTED_MODULE_3__.hook)('ready'), |
| 6384 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_4__.watch)('state.values.align') |
| 6385 |
], UIImagePositionTab.prototype, "onStateAlignChange", null); |
| 6386 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 6387 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_4__.watch)('align:change') |
| 6388 |
], UIImagePositionTab.prototype, "onChangeAlign", null); |
| 6389 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 6390 |
(0,jodit_core_decorators_hook_hook__WEBPACK_IMPORTED_MODULE_3__.hook)('ready'), |
| 6391 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_4__.watch)('state.values.borderRadius') |
| 6392 |
], UIImagePositionTab.prototype, "onStateValuesBorderRadiusChange", null); |
| 6393 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 6394 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_4__.watch)('borderRadius:change') |
| 6395 |
], UIImagePositionTab.prototype, "onChangeBorderRadius", null); |
| 6396 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 6397 |
(0,jodit_core_decorators_hook_hook__WEBPACK_IMPORTED_MODULE_3__.hook)('ready'), |
| 6398 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_4__.watch)('state.values.id') |
| 6399 |
], UIImagePositionTab.prototype, "onStateValuesIdChange", null); |
| 6400 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 6401 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_4__.watch)('id:change') |
| 6402 |
], UIImagePositionTab.prototype, "onChangeId", null); |
| 6403 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 6404 |
(0,jodit_core_decorators_hook_hook__WEBPACK_IMPORTED_MODULE_3__.hook)('ready'), |
| 6405 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_4__.watch)('state.values.style') |
| 6406 |
], UIImagePositionTab.prototype, "onStateValuesStyleChange", null); |
| 6407 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 6408 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_4__.watch)('style:change') |
| 6409 |
], UIImagePositionTab.prototype, "onChangeStyle", null); |
| 6410 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 6411 |
(0,jodit_core_decorators_hook_hook__WEBPACK_IMPORTED_MODULE_3__.hook)('ready'), |
| 6412 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_4__.watch)('state.values.classes') |
| 6413 |
], UIImagePositionTab.prototype, "onStateValuesClassesChange", null); |
| 6414 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 6415 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_4__.watch)('classes:change') |
| 6416 |
], UIImagePositionTab.prototype, "onChangClasses", null); |
| 6417 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 6418 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_4__.watch)('lockMargin:click') |
| 6419 |
], UIImagePositionTab.prototype, "onLockMarginClick", null); |
| 6420 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 6421 |
(0,jodit_core_decorators_hook_hook__WEBPACK_IMPORTED_MODULE_3__.hook)('ready'), |
| 6422 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_4__.watch)('state.marginIsLocked') |
| 6423 |
], UIImagePositionTab.prototype, "onChangeMarginIsLocked", null); |
| 6424 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 6425 |
(0,jodit_core_decorators_hook_hook__WEBPACK_IMPORTED_MODULE_3__.hook)('ready'), |
| 6426 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_4__.watch)([ |
| 6427 |
'state.values.marginTop', |
| 6428 |
'state.values.marginRight', |
| 6429 |
'state.values.marginBottom', |
| 6430 |
'state.values.marginLeft' |
| 6431 |
]) |
| 6432 |
], UIImagePositionTab.prototype, "onStateValuesMarginChange", null); |
| 6433 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 6434 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_4__.watch)([ |
| 6435 |
'marginTop:change', |
| 6436 |
'marginRight:change', |
| 6437 |
'marginBottom:change', |
| 6438 |
'marginLeft:change' |
| 6439 |
]) |
| 6440 |
], UIImagePositionTab.prototype, "onChangeMargin", null); |
| 6441 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 6442 |
(0,jodit_core_decorators_hook_hook__WEBPACK_IMPORTED_MODULE_3__.hook)('ready') |
| 6443 |
], UIImagePositionTab.prototype, "hideFieldByOptions", null); |
| 6444 |
UIImagePositionTab = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 6445 |
jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_2__.component |
| 6446 |
], UIImagePositionTab); |
| 6447 |
|
| 6448 |
|
| 6449 |
/***/ }), |
| 6450 |
|
| 6451 |
/***/ 17312: |
| 6452 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 6453 |
|
| 6454 |
"use strict"; |
| 6455 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 6456 |
/* harmony export */ isArray: function() { return /* binding */ isArray; } |
| 6457 |
/* harmony export */ }); |
| 6458 |
/*! |
| 6459 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 6460 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 6461 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 6462 |
*/ /** |
| 6463 |
* @module helpers/checker |
| 6464 |
*/ /** |
| 6465 |
* Check if element is array |
| 6466 |
*/ function isArray(elm) { |
| 6467 |
return Array.isArray(elm); |
| 6468 |
} |
| 6469 |
|
| 6470 |
|
| 6471 |
/***/ }), |
| 6472 |
|
| 6473 |
/***/ 17338: |
| 6474 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 6475 |
|
| 6476 |
"use strict"; |
| 6477 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 6478 |
/* harmony export */ Ajax: function() { return /* binding */ Ajax; } |
| 6479 |
/* harmony export */ }); |
| 6480 |
/* harmony import */ var _swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(49376); |
| 6481 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(25045); |
| 6482 |
/* harmony import */ var _swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(41411); |
| 6483 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(31635); |
| 6484 |
/* harmony import */ var jodit_core_async__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(91231); |
| 6485 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(81937); |
| 6486 |
/* harmony import */ var jodit_core_decorators_autobind_autobind__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(49574); |
| 6487 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(65946); |
| 6488 |
/* harmony import */ var jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(33201); |
| 6489 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(5266); |
| 6490 |
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(37102); |
| 6491 |
/* harmony import */ var _response__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(32855); |
| 6492 |
/*! |
| 6493 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 6494 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 6495 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 6496 |
*/ /** |
| 6497 |
* [[include:core/request/README.md]] |
| 6498 |
* @packageDocumentation |
| 6499 |
* @module request |
| 6500 |
*/ |
| 6501 |
|
| 6502 |
|
| 6503 |
|
| 6504 |
|
| 6505 |
|
| 6506 |
|
| 6507 |
|
| 6508 |
|
| 6509 |
|
| 6510 |
|
| 6511 |
|
| 6512 |
class Ajax { |
| 6513 |
className() { |
| 6514 |
return 'Ajax'; |
| 6515 |
} |
| 6516 |
__buildParams(obj, prefix) { |
| 6517 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_7__.isPlainObject)(obj) && this.options.contentType && this.options.contentType.includes('application/json')) { |
| 6518 |
return JSON.stringify(obj); |
| 6519 |
} |
| 6520 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_7__.isFunction)(this.o.queryBuild)) { |
| 6521 |
return this.o.queryBuild.call(this, obj, prefix); |
| 6522 |
} |
| 6523 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_7__.isString)(obj) || obj instanceof jodit_core_constants__WEBPACK_IMPORTED_MODULE_5__.globalWindow.FormData || typeof obj === 'object' && obj != null && (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_7__.isFunction)(obj.append)) { |
| 6524 |
return obj; |
| 6525 |
} |
| 6526 |
return (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_7__.buildQuery)(obj); |
| 6527 |
} |
| 6528 |
get o() { |
| 6529 |
return this.options; |
| 6530 |
} |
| 6531 |
abort() { |
| 6532 |
if (this.__isFulfilled) { |
| 6533 |
return this; |
| 6534 |
} |
| 6535 |
try { |
| 6536 |
this.__isFulfilled = true; |
| 6537 |
this.xhr.abort(); |
| 6538 |
} catch (unused) {} |
| 6539 |
return this; |
| 6540 |
} |
| 6541 |
send() { |
| 6542 |
this.__activated = true; |
| 6543 |
const { xhr, o } = this; |
| 6544 |
const request = this.prepareRequest(); |
| 6545 |
return this.__async.promise((resolve, reject)=>(0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 6546 |
var _o_withCredentials; |
| 6547 |
const onReject = ()=>{ |
| 6548 |
this.__isFulfilled = true; |
| 6549 |
reject(jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_8__.connection('Connection error')); |
| 6550 |
}; |
| 6551 |
const onResolve = ()=>{ |
| 6552 |
this.__isFulfilled = true; |
| 6553 |
resolve(new _response__WEBPACK_IMPORTED_MODULE_11__.Response(request, xhr.status, xhr.statusText, !xhr.responseType ? xhr.responseText : xhr.response)); |
| 6554 |
}; |
| 6555 |
xhr.onload = onResolve; |
| 6556 |
xhr.onabort = ()=>{ |
| 6557 |
this.__isFulfilled = true; |
| 6558 |
reject(jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_8__.abort('Abort connection')); |
| 6559 |
}; |
| 6560 |
xhr.onerror = onReject; |
| 6561 |
xhr.ontimeout = onReject; |
| 6562 |
if (o.responseType) { |
| 6563 |
xhr.responseType = o.responseType; |
| 6564 |
} |
| 6565 |
xhr.onprogress = (e)=>{ |
| 6566 |
var _this_options_onProgress, _this_options; |
| 6567 |
let percentComplete = 0; |
| 6568 |
if (e.lengthComputable) { |
| 6569 |
percentComplete = e.loaded / e.total * 100; |
| 6570 |
} |
| 6571 |
(_this_options_onProgress = (_this_options = this.options).onProgress) === null || _this_options_onProgress === void 0 ? void 0 : _this_options_onProgress.call(_this_options, percentComplete); |
| 6572 |
}; |
| 6573 |
xhr.onreadystatechange = ()=>{ |
| 6574 |
var _this_options_onProgress, _this_options; |
| 6575 |
(_this_options_onProgress = (_this_options = this.options).onProgress) === null || _this_options_onProgress === void 0 ? void 0 : _this_options_onProgress.call(_this_options, 10); |
| 6576 |
if (xhr.readyState === XMLHttpRequest.DONE) { |
| 6577 |
if (o.successStatuses.includes(xhr.status)) { |
| 6578 |
onResolve(); |
| 6579 |
} else if (xhr.statusText) { |
| 6580 |
this.__isFulfilled = true; |
| 6581 |
reject(jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_8__.connection(xhr.statusText)); |
| 6582 |
} |
| 6583 |
} |
| 6584 |
}; |
| 6585 |
xhr.withCredentials = (_o_withCredentials = o.withCredentials) !== null && _o_withCredentials !== void 0 ? _o_withCredentials : false; |
| 6586 |
const { url, data, method } = request; |
| 6587 |
xhr.open(method, url, true); |
| 6588 |
if (o.contentType && xhr.setRequestHeader) { |
| 6589 |
xhr.setRequestHeader('Content-type', o.contentType); |
| 6590 |
} |
| 6591 |
let { headers } = o; |
| 6592 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_7__.isFunction)(headers)) { |
| 6593 |
headers = yield headers.call(this); |
| 6594 |
} |
| 6595 |
if (headers && xhr.setRequestHeader) { |
| 6596 |
Object.keys(headers).forEach((key)=>{ |
| 6597 |
xhr.setRequestHeader(key, headers[key]); |
| 6598 |
}); |
| 6599 |
} |
| 6600 |
// IE |
| 6601 |
this.__async.setTimeout(()=>{ |
| 6602 |
xhr.send(data ? this.__buildParams(data) : undefined); |
| 6603 |
}, 0); |
| 6604 |
}).call(this)); |
| 6605 |
} |
| 6606 |
prepareRequest() { |
| 6607 |
if (!this.o.url) { |
| 6608 |
throw jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_8__.error('Need URL for AJAX request'); |
| 6609 |
} |
| 6610 |
let url = this.o.url; |
| 6611 |
const data = this.o.data; |
| 6612 |
const method = (this.o.method || 'get').toLowerCase(); |
| 6613 |
if (method === 'get' && data && (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_7__.isPlainObject)(data)) { |
| 6614 |
const qIndex = url.indexOf('?'); |
| 6615 |
if (qIndex !== -1) { |
| 6616 |
const urlData = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_7__.parseQuery)(url); |
| 6617 |
url = url.substring(0, qIndex) + '?' + (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_7__.buildQuery)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_2__._)({}, urlData, data)); |
| 6618 |
} else { |
| 6619 |
url += '?' + (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_7__.buildQuery)(this.o.data); |
| 6620 |
} |
| 6621 |
} |
| 6622 |
const request = { |
| 6623 |
url, |
| 6624 |
method, |
| 6625 |
data |
| 6626 |
}; |
| 6627 |
Ajax.log.splice(100); |
| 6628 |
Ajax.log.push(request); |
| 6629 |
return request; |
| 6630 |
} |
| 6631 |
destruct() { |
| 6632 |
if (!this.__isDestructed) { |
| 6633 |
this.__isDestructed = true; |
| 6634 |
if (this.__activated && !this.__isFulfilled) { |
| 6635 |
this.abort(); |
| 6636 |
this.__isFulfilled = true; |
| 6637 |
} |
| 6638 |
this.__async.destruct(); |
| 6639 |
} |
| 6640 |
} |
| 6641 |
constructor(options, defaultAjaxOptions = jodit_config__WEBPACK_IMPORTED_MODULE_9__.Config.prototype.defaultAjaxOptions){ |
| 6642 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(this, "__async", new jodit_core_async__WEBPACK_IMPORTED_MODULE_4__.Async()); |
| 6643 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(this, "xhr", void 0); |
| 6644 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(this, "options", void 0); |
| 6645 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(this, "__isFulfilled", false); |
| 6646 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(this, "__activated", false); |
| 6647 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(this, "__isDestructed", false); |
| 6648 |
this.options = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_7__.ConfigProto)(options || {}, defaultAjaxOptions); |
| 6649 |
this.xhr = this.o.xhr ? this.o.xhr() : new XMLHttpRequest(); |
| 6650 |
} |
| 6651 |
} |
| 6652 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(Ajax, "log", []); |
| 6653 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__.__decorate)([ |
| 6654 |
jodit_core_decorators_autobind_autobind__WEBPACK_IMPORTED_MODULE_6__.autobind |
| 6655 |
], Ajax.prototype, "destruct", null); |
| 6656 |
|
| 6657 |
|
| 6658 |
/***/ }), |
| 6659 |
|
| 6660 |
/***/ 17481: |
| 6661 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 6662 |
|
| 6663 |
"use strict"; |
| 6664 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 6665 |
/* harmony export */ extractSelectedPart: function() { return /* binding */ extractSelectedPart; } |
| 6666 |
/* harmony export */ }); |
| 6667 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 6668 |
/* harmony import */ var jodit_core_helpers_checker_is_marker__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(23175); |
| 6669 |
/* harmony import */ var jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(4040); |
| 6670 |
/* harmony import */ var jodit_core_helpers_utils_utils__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(71125); |
| 6671 |
/*! |
| 6672 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 6673 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 6674 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 6675 |
*/ |
| 6676 |
|
| 6677 |
|
| 6678 |
|
| 6679 |
/** |
| 6680 |
* If the selection area is inside an element that matches the commit (suitable relative), |
| 6681 |
* but does not completely fill it. |
| 6682 |
* Then the method cuts the parent and leaves itself in a copy of the parent (suitable relative) in the middle. |
| 6683 |
* |
| 6684 |
* @example |
| 6685 |
* Apply strong to |
| 6686 |
* ```html |
| 6687 |
* <strong><span>some<font>SELECTED</font>text</span></strong> |
| 6688 |
* ``` |
| 6689 |
* Should extract selection from parent `strong` |
| 6690 |
* ```html |
| 6691 |
* `<strong><span>some</span></strong><strong><span><font>SELECTED</font></span></strong><strong><span>test</span></strong> |
| 6692 |
* ``` |
| 6693 |
* @private |
| 6694 |
*/ function extractSelectedPart(wrapper, font, jodit) { |
| 6695 |
const range = jodit.s.createRange(); |
| 6696 |
// Left part |
| 6697 |
const leftEdge = (0,jodit_core_helpers_checker_is_marker__WEBPACK_IMPORTED_MODULE_1__.isMarker)(font.previousSibling) ? font.previousSibling : font; |
| 6698 |
range.setStartBefore(wrapper); |
| 6699 |
range.setEndBefore(leftEdge); |
| 6700 |
extractAndMove(wrapper, range, true); |
| 6701 |
// Right part |
| 6702 |
const rightEdge = (0,jodit_core_helpers_checker_is_marker__WEBPACK_IMPORTED_MODULE_1__.isMarker)(font.nextSibling) ? font.nextSibling : font; |
| 6703 |
range.setStartAfter(rightEdge); |
| 6704 |
range.setEndAfter(wrapper); |
| 6705 |
extractAndMove(wrapper, range, false); |
| 6706 |
} |
| 6707 |
/** |
| 6708 |
* Retrieves content before after the selected area, clears it if it is empty, and inserts before after the framed selection |
| 6709 |
* @private |
| 6710 |
*/ function extractAndMove(wrapper, range, left) { |
| 6711 |
const fragment = range.extractContents(); |
| 6712 |
if ((!fragment.textContent || !(0,jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_2__.trim)(fragment.textContent).length) && fragment.firstChild) { |
| 6713 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.unwrap(fragment.firstChild); |
| 6714 |
} |
| 6715 |
if (wrapper.parentNode) { |
| 6716 |
(0,jodit_core_helpers_utils_utils__WEBPACK_IMPORTED_MODULE_3__.call)(left ? jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.before : jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.after, wrapper, fragment); |
| 6717 |
} |
| 6718 |
} |
| 6719 |
|
| 6720 |
|
| 6721 |
/***/ }), |
| 6722 |
|
| 6723 |
/***/ 17523: |
| 6724 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 6725 |
|
| 6726 |
"use strict"; |
| 6727 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 6728 |
/* harmony export */ cases: function() { return /* binding */ cases; } |
| 6729 |
/* harmony export */ }); |
| 6730 |
/* harmony import */ var _check_join_neighbors__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(26106); |
| 6731 |
/* harmony import */ var _check_join_two_lists__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(80951); |
| 6732 |
/* harmony import */ var _check_remove_char__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(58881); |
| 6733 |
/* harmony import */ var _check_remove_content_not_editable__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(68709); |
| 6734 |
/* harmony import */ var _check_remove_empty_neighbor__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(5771); |
| 6735 |
/* harmony import */ var _check_remove_empty_parent__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(2409); |
| 6736 |
/* harmony import */ var _check_remove_unbreakable_element__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(93890); |
| 6737 |
/* harmony import */ var _check_table_cell__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(12443); |
| 6738 |
/* harmony import */ var _check_unwrap_first_list_item__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(10157); |
| 6739 |
/*! |
| 6740 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 6741 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 6742 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 6743 |
*/ /** |
| 6744 |
* @module plugins/backspace |
| 6745 |
*/ |
| 6746 |
|
| 6747 |
|
| 6748 |
|
| 6749 |
|
| 6750 |
|
| 6751 |
|
| 6752 |
|
| 6753 |
|
| 6754 |
/** |
| 6755 |
* @private |
| 6756 |
*/ const cases = [ |
| 6757 |
_check_remove_unbreakable_element__WEBPACK_IMPORTED_MODULE_6__.checkRemoveUnbreakableElement, |
| 6758 |
_check_remove_content_not_editable__WEBPACK_IMPORTED_MODULE_3__.checkRemoveContentNotEditable, |
| 6759 |
_check_remove_char__WEBPACK_IMPORTED_MODULE_2__.checkRemoveChar, |
| 6760 |
_check_table_cell__WEBPACK_IMPORTED_MODULE_7__.checkTableCell, |
| 6761 |
_check_remove_empty_parent__WEBPACK_IMPORTED_MODULE_5__.checkRemoveEmptyParent, |
| 6762 |
_check_remove_empty_neighbor__WEBPACK_IMPORTED_MODULE_4__.checkRemoveEmptyNeighbor, |
| 6763 |
_check_join_two_lists__WEBPACK_IMPORTED_MODULE_1__.checkJoinTwoLists, |
| 6764 |
_check_join_neighbors__WEBPACK_IMPORTED_MODULE_0__.checkJoinNeighbors, |
| 6765 |
_check_unwrap_first_list_item__WEBPACK_IMPORTED_MODULE_8__.checkUnwrapFirstListItem |
| 6766 |
]; |
| 6767 |
|
| 6768 |
|
| 6769 |
/***/ }), |
| 6770 |
|
| 6771 |
/***/ 17610: |
| 6772 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 6773 |
|
| 6774 |
"use strict"; |
| 6775 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 6776 |
/* harmony export */ FileBrowser: function() { return /* reexport safe */ _file_browser__WEBPACK_IMPORTED_MODULE_0__.FileBrowser; } |
| 6777 |
/* harmony export */ }); |
| 6778 |
/* harmony import */ var _file_browser__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(62623); |
| 6779 |
/*! |
| 6780 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 6781 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 6782 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 6783 |
*/ /** |
| 6784 |
* [[include:modules/file-browser/README.md]] |
| 6785 |
* @packageDocumentation |
| 6786 |
* @module modules/file-browser |
| 6787 |
*/ |
| 6788 |
|
| 6789 |
|
| 6790 |
/***/ }), |
| 6791 |
|
| 6792 |
/***/ 17780: |
| 6793 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 6794 |
|
| 6795 |
"use strict"; |
| 6796 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 6797 |
/* harmony export */ DEFAULT_SOURCE_NAME: function() { return /* binding */ DEFAULT_SOURCE_NAME; }, |
| 6798 |
/* harmony export */ "default": function() { return /* binding */ DataProvider; } |
| 6799 |
/* harmony export */ }); |
| 6800 |
/* harmony import */ var _swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(49376); |
| 6801 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(25045); |
| 6802 |
/* harmony import */ var _swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(41411); |
| 6803 |
/* harmony import */ var _swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(15366); |
| 6804 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(31635); |
| 6805 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(81937); |
| 6806 |
/* harmony import */ var jodit_core_decorators_autobind_autobind__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(49574); |
| 6807 |
/* harmony import */ var jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(91565); |
| 6808 |
/* harmony import */ var jodit_core_helpers_normalize_normalize_relative_path__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(96340); |
| 6809 |
/* harmony import */ var jodit_core_helpers_utils_config_proto__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(77483); |
| 6810 |
/* harmony import */ var jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(33201); |
| 6811 |
/* harmony import */ var jodit_core_helpers_utils_set__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(52144); |
| 6812 |
/* harmony import */ var jodit_core_request_ajax__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(17338); |
| 6813 |
/* harmony import */ var jodit_modules_file_browser_builders_item__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(58664); |
| 6814 |
/*! |
| 6815 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 6816 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 6817 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 6818 |
*/ /** |
| 6819 |
* @module modules/file-browser |
| 6820 |
*/ |
| 6821 |
|
| 6822 |
|
| 6823 |
|
| 6824 |
|
| 6825 |
|
| 6826 |
|
| 6827 |
|
| 6828 |
|
| 6829 |
|
| 6830 |
|
| 6831 |
|
| 6832 |
|
| 6833 |
|
| 6834 |
const DEFAULT_SOURCE_NAME = 'default'; |
| 6835 |
const possibleRules = new Set([ |
| 6836 |
'allowFiles', |
| 6837 |
'allowFileMove', |
| 6838 |
'allowFileUpload', |
| 6839 |
'allowFileUploadRemote', |
| 6840 |
'allowFileRemove', |
| 6841 |
'allowFileRename', |
| 6842 |
'allowFolders', |
| 6843 |
'allowFolderMove', |
| 6844 |
'allowFolderCreate', |
| 6845 |
'allowFolderRemove', |
| 6846 |
'allowFolderRename', |
| 6847 |
'allowImageResize', |
| 6848 |
'allowImageCrop' |
| 6849 |
]); |
| 6850 |
class DataProvider { |
| 6851 |
/** |
| 6852 |
* Alias for options |
| 6853 |
*/ get o() { |
| 6854 |
return this.options; |
| 6855 |
} |
| 6856 |
get(name) { |
| 6857 |
const instances = this.__ajaxInstances; |
| 6858 |
if (instances.has(name)) { |
| 6859 |
const ajax = instances.get(name); |
| 6860 |
ajax === null || ajax === void 0 ? void 0 : ajax.abort(); |
| 6861 |
instances.delete(name); |
| 6862 |
} |
| 6863 |
const opts = (0,jodit_core_helpers_utils_config_proto__WEBPACK_IMPORTED_MODULE_9__.ConfigProto)(this.options[name] !== undefined ? this.options[name] : {}, (0,jodit_core_helpers_utils_config_proto__WEBPACK_IMPORTED_MODULE_9__.ConfigProto)({ |
| 6864 |
onProgress: this.progressHandler |
| 6865 |
}, this.o.ajax)); |
| 6866 |
if (opts.prepareData) { |
| 6867 |
opts.data = opts.prepareData.call(this, opts.data); |
| 6868 |
} |
| 6869 |
const ajax = new jodit_core_request_ajax__WEBPACK_IMPORTED_MODULE_12__.Ajax(opts); |
| 6870 |
instances.set(name, ajax); |
| 6871 |
const promise = ajax.send(); |
| 6872 |
promise.finally(()=>{ |
| 6873 |
ajax.destruct(); |
| 6874 |
instances.delete(name); |
| 6875 |
this.progressHandler(100); |
| 6876 |
}).catch(()=>null); |
| 6877 |
return promise.then((resp)=>resp.json()).then((resp)=>{ |
| 6878 |
if (resp && !this.isSuccess(resp)) { |
| 6879 |
throw new Error(this.getMessage(resp)); |
| 6880 |
} |
| 6881 |
return resp; |
| 6882 |
}); |
| 6883 |
} |
| 6884 |
onProgress(callback) { |
| 6885 |
this.progressHandler = callback; |
| 6886 |
} |
| 6887 |
/** |
| 6888 |
* Load permissions for path and source |
| 6889 |
*/ permissions(path, source) { |
| 6890 |
return (0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 6891 |
if (!this.o.permissions) { |
| 6892 |
return null; |
| 6893 |
} |
| 6894 |
this.o.permissions.data.path = path; |
| 6895 |
this.o.permissions.data.source = source; |
| 6896 |
if (this.o.permissions.url) { |
| 6897 |
return this.get('permissions').then((resp)=>{ |
| 6898 |
if (this.parent.isInDestruct) { |
| 6899 |
throw (0,jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_10__.abort)(); |
| 6900 |
} |
| 6901 |
let process = this.o.permissions.process; |
| 6902 |
if (!process) { |
| 6903 |
process = this.o.ajax.process; |
| 6904 |
} |
| 6905 |
if (process) { |
| 6906 |
const respData = process.call(self, resp); |
| 6907 |
if (respData.data.permissions) { |
| 6908 |
this.parent.events.fire(this, 'changePermissions', this.__currentPermissions, respData.data.permissions); |
| 6909 |
this.__currentPermissions = respData.data.permissions; |
| 6910 |
} |
| 6911 |
} |
| 6912 |
return this.__currentPermissions; |
| 6913 |
}); |
| 6914 |
} |
| 6915 |
return null; |
| 6916 |
}).call(this); |
| 6917 |
} |
| 6918 |
canI(action) { |
| 6919 |
const rule = 'allow' + action; |
| 6920 |
if (!jodit_core_constants__WEBPACK_IMPORTED_MODULE_5__.IS_PROD) { |
| 6921 |
if (!possibleRules.has(rule)) { |
| 6922 |
throw (0,jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_10__.error)('Wrong action ' + action); |
| 6923 |
} |
| 6924 |
} |
| 6925 |
const presetValue = this.o.permissionsPresets[rule]; |
| 6926 |
if (presetValue !== undefined) { |
| 6927 |
return presetValue; |
| 6928 |
} |
| 6929 |
return this.__currentPermissions == null || this.__currentPermissions[rule] === undefined || this.__currentPermissions[rule]; |
| 6930 |
} |
| 6931 |
__items(path, source, mods, onResult) { |
| 6932 |
const opt = this.options; |
| 6933 |
if (!opt.items) { |
| 6934 |
return Promise.reject(Error('Set Items api options')); |
| 6935 |
} |
| 6936 |
opt.items.data.path = path; |
| 6937 |
opt.items.data.source = source; |
| 6938 |
opt.items.data.mods = mods; |
| 6939 |
return this.get('items').then((resp)=>{ |
| 6940 |
let process = this.o.items.process; |
| 6941 |
if (!process) { |
| 6942 |
process = this.o.ajax.process; |
| 6943 |
} |
| 6944 |
if (process) { |
| 6945 |
resp = process.call(self, resp); |
| 6946 |
} |
| 6947 |
return onResult(resp); |
| 6948 |
}); |
| 6949 |
} |
| 6950 |
/** |
| 6951 |
* Load items list by path and source |
| 6952 |
*/ items(path, source, mods = {}) { |
| 6953 |
return this.__items(path, source, mods, (resp)=>this.__generateItemsList(resp.data.sources, mods)); |
| 6954 |
} |
| 6955 |
/** |
| 6956 |
* Load items list by path and source |
| 6957 |
*/ itemsEx(path, source, mods = {}) { |
| 6958 |
const calcTotal = (sources)=>sources.reduce((acc, source)=>acc + source.files.length, 0); |
| 6959 |
return this.__items(path, source, mods, (resp)=>({ |
| 6960 |
items: this.__generateItemsList(resp.data.sources, mods), |
| 6961 |
loadedTotal: calcTotal(resp.data.sources) |
| 6962 |
})); |
| 6963 |
} |
| 6964 |
__generateItemsList(sources, mods = {}) { |
| 6965 |
const elements = []; |
| 6966 |
const canBeFile = (item)=>item.type === 'folder' || !mods.onlyImages || item.isImage === undefined || item.isImage; |
| 6967 |
const inFilter = (item)=>{ |
| 6968 |
var _mods_filterWord; |
| 6969 |
return !((_mods_filterWord = mods.filterWord) === null || _mods_filterWord === void 0 ? void 0 : _mods_filterWord.length) || this.o.filter === undefined || this.o.filter(item, mods.filterWord); |
| 6970 |
}; |
| 6971 |
sources.forEach((source)=>{ |
| 6972 |
if (source.files && source.files.length) { |
| 6973 |
const { sort } = this.o; |
| 6974 |
if ((0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_7__.isFunction)(sort) && mods.sortBy) { |
| 6975 |
source.files.sort((a, b)=>sort(a, b, mods.sortBy)); |
| 6976 |
} |
| 6977 |
source.files.forEach((item)=>{ |
| 6978 |
if (inFilter(item) && canBeFile(item)) { |
| 6979 |
elements.push(jodit_modules_file_browser_builders_item__WEBPACK_IMPORTED_MODULE_13__.FileBrowserItem.create((0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_3__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_2__._)({}, item), { |
| 6980 |
sourceName: source.name, |
| 6981 |
source |
| 6982 |
}))); |
| 6983 |
} |
| 6984 |
}); |
| 6985 |
} |
| 6986 |
}); |
| 6987 |
return elements; |
| 6988 |
} |
| 6989 |
tree(path, source) { |
| 6990 |
return (0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 6991 |
path = (0,jodit_core_helpers_normalize_normalize_relative_path__WEBPACK_IMPORTED_MODULE_8__.normalizeRelativePath)(path); |
| 6992 |
if (!this.o.folder) { |
| 6993 |
return Promise.reject(Error('Set Folder Api options')); |
| 6994 |
} |
| 6995 |
yield this.permissions(path, source); |
| 6996 |
this.o.folder.data.path = path; |
| 6997 |
this.o.folder.data.source = source; |
| 6998 |
return this.get('folder').then((resp)=>{ |
| 6999 |
let process = this.o.folder.process; |
| 7000 |
if (!process) { |
| 7001 |
process = this.o.ajax.process; |
| 7002 |
} |
| 7003 |
if (process) { |
| 7004 |
resp = process.call(self, resp); |
| 7005 |
} |
| 7006 |
return resp.data.sources; |
| 7007 |
}); |
| 7008 |
}).call(this); |
| 7009 |
} |
| 7010 |
/** |
| 7011 |
* Get path by url. You can use this method in another modules |
| 7012 |
*/ getPathByUrl(url) { |
| 7013 |
(0,jodit_core_helpers_utils_set__WEBPACK_IMPORTED_MODULE_11__.set)('options.getLocalFileByUrl.data.url', url, this); |
| 7014 |
return this.get('getLocalFileByUrl').then((resp)=>{ |
| 7015 |
if (this.isSuccess(resp)) { |
| 7016 |
return resp.data; |
| 7017 |
} |
| 7018 |
throw (0,jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_10__.error)(this.getMessage(resp)); |
| 7019 |
}); |
| 7020 |
} |
| 7021 |
/** |
| 7022 |
* Create a directory on the server |
| 7023 |
* |
| 7024 |
* @param name - Name the new folder |
| 7025 |
* @param path - Relative directory in which you want create a folder |
| 7026 |
* @param source - Server source key |
| 7027 |
*/ createFolder(name, path, source) { |
| 7028 |
const { create } = this.o; |
| 7029 |
if (!create) { |
| 7030 |
throw (0,jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_10__.error)('Set Create api options'); |
| 7031 |
} |
| 7032 |
create.data.source = source; |
| 7033 |
create.data.path = path; |
| 7034 |
create.data.name = name; |
| 7035 |
return this.get('create').then((resp)=>{ |
| 7036 |
if (this.isSuccess(resp)) { |
| 7037 |
return true; |
| 7038 |
} |
| 7039 |
throw (0,jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_10__.error)(this.getMessage(resp)); |
| 7040 |
}); |
| 7041 |
} |
| 7042 |
/** |
| 7043 |
* Move a file / directory on the server |
| 7044 |
* |
| 7045 |
* @param filepath - The relative path to the file / folder source |
| 7046 |
* @param path - Relative to the directory where you want to move the file / folder |
| 7047 |
*/ move(filepath, path, source, isFile) { |
| 7048 |
const mode = isFile ? 'fileMove' : 'folderMove'; |
| 7049 |
const option = this.options[mode]; |
| 7050 |
if (!option) { |
| 7051 |
throw (0,jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_10__.error)('Set Move api options'); |
| 7052 |
} |
| 7053 |
option.data.from = filepath; |
| 7054 |
option.data.path = path; |
| 7055 |
option.data.source = source; |
| 7056 |
return this.get(mode).then((resp)=>{ |
| 7057 |
if (this.isSuccess(resp)) { |
| 7058 |
return true; |
| 7059 |
} |
| 7060 |
throw (0,jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_10__.error)(this.getMessage(resp)); |
| 7061 |
}); |
| 7062 |
} |
| 7063 |
/** |
| 7064 |
* Deleting item |
| 7065 |
* |
| 7066 |
* @param path - Relative path |
| 7067 |
* @param file - The filename |
| 7068 |
* @param source - Source |
| 7069 |
*/ __remove(action, path, file, source) { |
| 7070 |
const fr = this.o[action]; |
| 7071 |
if (!fr) { |
| 7072 |
throw (0,jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_10__.error)(`Set "${action}" api options`); |
| 7073 |
} |
| 7074 |
fr.data.path = path; |
| 7075 |
fr.data.name = file; |
| 7076 |
fr.data.source = source; |
| 7077 |
return this.get(action).then((resp)=>{ |
| 7078 |
if (fr.process) { |
| 7079 |
resp = fr.process.call(this, resp); |
| 7080 |
} |
| 7081 |
return this.getMessage(resp); |
| 7082 |
}); |
| 7083 |
} |
| 7084 |
/** |
| 7085 |
* Deleting a file |
| 7086 |
* |
| 7087 |
* @param path - Relative path |
| 7088 |
* @param file - The filename |
| 7089 |
* @param source - Source |
| 7090 |
*/ fileRemove(path, file, source) { |
| 7091 |
return this.__remove('fileRemove', path, file, source); |
| 7092 |
} |
| 7093 |
/** |
| 7094 |
* Deleting a folder |
| 7095 |
* |
| 7096 |
* @param path - Relative path |
| 7097 |
* @param file - The filename |
| 7098 |
* @param source - Source |
| 7099 |
*/ folderRemove(path, file, source) { |
| 7100 |
return this.__remove('folderRemove', path, file, source); |
| 7101 |
} |
| 7102 |
/** |
| 7103 |
* Rename action |
| 7104 |
* |
| 7105 |
* @param path - Relative path |
| 7106 |
* @param name - Old name |
| 7107 |
* @param newname - New name |
| 7108 |
* @param source - Source |
| 7109 |
*/ __rename(action, path, name, newname, source) { |
| 7110 |
const fr = this.o[action]; |
| 7111 |
if (!fr) { |
| 7112 |
throw (0,jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_10__.error)(`Set "${action}" api options`); |
| 7113 |
} |
| 7114 |
fr.data.path = path; |
| 7115 |
fr.data.name = name; |
| 7116 |
fr.data.newname = newname; |
| 7117 |
fr.data.source = source; |
| 7118 |
return this.get(action).then((resp)=>{ |
| 7119 |
if (fr.process) { |
| 7120 |
resp = fr.process.call(self, resp); |
| 7121 |
} |
| 7122 |
return this.getMessage(resp); |
| 7123 |
}); |
| 7124 |
} |
| 7125 |
/** |
| 7126 |
* Rename folder |
| 7127 |
*/ folderRename(path, name, newname, source) { |
| 7128 |
return this.__rename('folderRename', path, name, newname, source); |
| 7129 |
} |
| 7130 |
/** |
| 7131 |
* Rename file |
| 7132 |
*/ fileRename(path, name, newname, source) { |
| 7133 |
return this.__rename('fileRename', path, name, newname, source); |
| 7134 |
} |
| 7135 |
__changeImage(type, path, source, name, newname, box) { |
| 7136 |
if (!this.o[type]) { |
| 7137 |
this.o[type] = { |
| 7138 |
data: {} |
| 7139 |
}; |
| 7140 |
} |
| 7141 |
const query = this.o[type]; |
| 7142 |
if (query.data === undefined) { |
| 7143 |
query.data = { |
| 7144 |
action: type |
| 7145 |
}; |
| 7146 |
} |
| 7147 |
query.data.newname = newname || name; |
| 7148 |
if (box) { |
| 7149 |
query.data.box = box; |
| 7150 |
} |
| 7151 |
query.data.path = path; |
| 7152 |
query.data.name = name; |
| 7153 |
query.data.source = source; |
| 7154 |
return this.get(type).then(()=>{ |
| 7155 |
return true; |
| 7156 |
}); |
| 7157 |
} |
| 7158 |
/** |
| 7159 |
* Send command to server to crop image |
| 7160 |
*/ crop(path, source, name, newname, box) { |
| 7161 |
return this.__changeImage('crop', path, source, name, newname, box); |
| 7162 |
} |
| 7163 |
/** |
| 7164 |
* Send command to server to resize image |
| 7165 |
*/ resize(path, source, name, newname, box) { |
| 7166 |
return this.__changeImage('resize', path, source, name, newname, box); |
| 7167 |
} |
| 7168 |
getMessage(resp) { |
| 7169 |
return this.options.getMessage(resp); |
| 7170 |
} |
| 7171 |
isSuccess(resp) { |
| 7172 |
return this.options.isSuccess(resp); |
| 7173 |
} |
| 7174 |
destruct() { |
| 7175 |
this.__ajaxInstances.forEach((a)=>a.destruct()); |
| 7176 |
this.__ajaxInstances.clear(); |
| 7177 |
} |
| 7178 |
constructor(parent, options){ |
| 7179 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(this, "parent", void 0); |
| 7180 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(this, "options", void 0); |
| 7181 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(this, "__currentPermissions", void 0); |
| 7182 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(this, "__ajaxInstances", void 0); |
| 7183 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(this, "progressHandler", void 0); |
| 7184 |
this.parent = parent; |
| 7185 |
this.options = options; |
| 7186 |
this.__currentPermissions = null; |
| 7187 |
this.__ajaxInstances = new Map(); |
| 7188 |
this.progressHandler = (ignore)=>{}; |
| 7189 |
} |
| 7190 |
} |
| 7191 |
|
| 7192 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_4__.__decorate)([ |
| 7193 |
jodit_core_decorators_autobind_autobind__WEBPACK_IMPORTED_MODULE_6__.autobind |
| 7194 |
], DataProvider.prototype, "onProgress", null); |
| 7195 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_4__.__decorate)([ |
| 7196 |
jodit_core_decorators_autobind_autobind__WEBPACK_IMPORTED_MODULE_6__.autobind |
| 7197 |
], DataProvider.prototype, "permissions", null); |
| 7198 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_4__.__decorate)([ |
| 7199 |
jodit_core_decorators_autobind_autobind__WEBPACK_IMPORTED_MODULE_6__.autobind |
| 7200 |
], DataProvider.prototype, "canI", null); |
| 7201 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_4__.__decorate)([ |
| 7202 |
jodit_core_decorators_autobind_autobind__WEBPACK_IMPORTED_MODULE_6__.autobind |
| 7203 |
], DataProvider.prototype, "items", null); |
| 7204 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_4__.__decorate)([ |
| 7205 |
jodit_core_decorators_autobind_autobind__WEBPACK_IMPORTED_MODULE_6__.autobind |
| 7206 |
], DataProvider.prototype, "itemsEx", null); |
| 7207 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_4__.__decorate)([ |
| 7208 |
jodit_core_decorators_autobind_autobind__WEBPACK_IMPORTED_MODULE_6__.autobind |
| 7209 |
], DataProvider.prototype, "tree", null); |
| 7210 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_4__.__decorate)([ |
| 7211 |
jodit_core_decorators_autobind_autobind__WEBPACK_IMPORTED_MODULE_6__.autobind |
| 7212 |
], DataProvider.prototype, "getPathByUrl", null); |
| 7213 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_4__.__decorate)([ |
| 7214 |
jodit_core_decorators_autobind_autobind__WEBPACK_IMPORTED_MODULE_6__.autobind |
| 7215 |
], DataProvider.prototype, "createFolder", null); |
| 7216 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_4__.__decorate)([ |
| 7217 |
jodit_core_decorators_autobind_autobind__WEBPACK_IMPORTED_MODULE_6__.autobind |
| 7218 |
], DataProvider.prototype, "move", null); |
| 7219 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_4__.__decorate)([ |
| 7220 |
jodit_core_decorators_autobind_autobind__WEBPACK_IMPORTED_MODULE_6__.autobind |
| 7221 |
], DataProvider.prototype, "fileRemove", null); |
| 7222 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_4__.__decorate)([ |
| 7223 |
jodit_core_decorators_autobind_autobind__WEBPACK_IMPORTED_MODULE_6__.autobind |
| 7224 |
], DataProvider.prototype, "folderRemove", null); |
| 7225 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_4__.__decorate)([ |
| 7226 |
jodit_core_decorators_autobind_autobind__WEBPACK_IMPORTED_MODULE_6__.autobind |
| 7227 |
], DataProvider.prototype, "folderRename", null); |
| 7228 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_4__.__decorate)([ |
| 7229 |
jodit_core_decorators_autobind_autobind__WEBPACK_IMPORTED_MODULE_6__.autobind |
| 7230 |
], DataProvider.prototype, "fileRename", null); |
| 7231 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_4__.__decorate)([ |
| 7232 |
jodit_core_decorators_autobind_autobind__WEBPACK_IMPORTED_MODULE_6__.autobind |
| 7233 |
], DataProvider.prototype, "crop", null); |
| 7234 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_4__.__decorate)([ |
| 7235 |
jodit_core_decorators_autobind_autobind__WEBPACK_IMPORTED_MODULE_6__.autobind |
| 7236 |
], DataProvider.prototype, "resize", null); |
| 7237 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_4__.__decorate)([ |
| 7238 |
jodit_core_decorators_autobind_autobind__WEBPACK_IMPORTED_MODULE_6__.autobind |
| 7239 |
], DataProvider.prototype, "getMessage", null); |
| 7240 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_4__.__decorate)([ |
| 7241 |
jodit_core_decorators_autobind_autobind__WEBPACK_IMPORTED_MODULE_6__.autobind |
| 7242 |
], DataProvider.prototype, "isSuccess", null); |
| 7243 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_4__.__decorate)([ |
| 7244 |
jodit_core_decorators_autobind_autobind__WEBPACK_IMPORTED_MODULE_6__.autobind |
| 7245 |
], DataProvider.prototype, "destruct", null); |
| 7246 |
|
| 7247 |
|
| 7248 |
/***/ }), |
| 7249 |
|
| 7250 |
/***/ 17849: |
| 7251 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 7252 |
|
| 7253 |
"use strict"; |
| 7254 |
/* harmony import */ var jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(28686); |
| 7255 |
/* harmony import */ var jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(80991); |
| 7256 |
/*! |
| 7257 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 7258 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 7259 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 7260 |
*/ /** |
| 7261 |
* @module plugins/inline-popup |
| 7262 |
*/ |
| 7263 |
|
| 7264 |
const cmd = (control)=>control.args && (0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_0__.isString)(control.args[0]) ? control.args[0].toLowerCase() : ''; |
| 7265 |
/* harmony default export */ __webpack_exports__["default"] = ([ |
| 7266 |
'brushCell', |
| 7267 |
{ |
| 7268 |
name: 'valign', |
| 7269 |
list: [ |
| 7270 |
'Top', |
| 7271 |
'Middle', |
| 7272 |
'Bottom', |
| 7273 |
'Normal' |
| 7274 |
], |
| 7275 |
childTemplate: (_, __, value)=>value, |
| 7276 |
exec: (editor, table, { control })=>{ |
| 7277 |
const command = cmd(control); |
| 7278 |
editor.getInstance('Table', editor.o).getAllSelectedCells().forEach((cell)=>{ |
| 7279 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_1__.css)(cell, 'vertical-align', command === 'normal' ? '' : command); |
| 7280 |
}); |
| 7281 |
}, |
| 7282 |
tooltip: 'Vertical align' |
| 7283 |
}, |
| 7284 |
{ |
| 7285 |
name: 'splitv', |
| 7286 |
list: { |
| 7287 |
tablesplitv: 'Split vertical', |
| 7288 |
tablesplitg: 'Split horizontal' |
| 7289 |
}, |
| 7290 |
tooltip: 'Split' |
| 7291 |
}, |
| 7292 |
{ |
| 7293 |
name: 'align', |
| 7294 |
icon: 'left' |
| 7295 |
}, |
| 7296 |
'\n', |
| 7297 |
{ |
| 7298 |
name: 'merge', |
| 7299 |
command: 'tablemerge', |
| 7300 |
tooltip: 'Merge' |
| 7301 |
}, |
| 7302 |
{ |
| 7303 |
name: 'addcolumn', |
| 7304 |
list: { |
| 7305 |
tableaddcolumnbefore: 'Insert column before', |
| 7306 |
tableaddcolumnafter: 'Insert column after' |
| 7307 |
}, |
| 7308 |
exec: (editor, table, { control })=>{ |
| 7309 |
if (!(0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_0__.isJoditObject)(editor)) { |
| 7310 |
return; |
| 7311 |
} |
| 7312 |
if (!control.args) { |
| 7313 |
return false; |
| 7314 |
} |
| 7315 |
const command = cmd(control); |
| 7316 |
editor.execCommand(command, false, table); |
| 7317 |
}, |
| 7318 |
tooltip: 'Add column' |
| 7319 |
}, |
| 7320 |
{ |
| 7321 |
name: 'addrow', |
| 7322 |
list: { |
| 7323 |
tableaddrowbefore: 'Insert row above', |
| 7324 |
tableaddrowafter: 'Insert row below' |
| 7325 |
}, |
| 7326 |
exec: (editor, table, { control })=>{ |
| 7327 |
if (!(0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_0__.isJoditObject)(editor)) { |
| 7328 |
return; |
| 7329 |
} |
| 7330 |
if (!control.args) { |
| 7331 |
return false; |
| 7332 |
} |
| 7333 |
const command = cmd(control); |
| 7334 |
editor.execCommand(command, false, table); |
| 7335 |
}, |
| 7336 |
tooltip: 'Add row' |
| 7337 |
}, |
| 7338 |
{ |
| 7339 |
name: 'delete', |
| 7340 |
icon: 'bin', |
| 7341 |
list: { |
| 7342 |
tablebin: 'Delete table', |
| 7343 |
tablebinrow: 'Delete row', |
| 7344 |
tablebincolumn: 'Delete column', |
| 7345 |
tableempty: 'Empty cell' |
| 7346 |
}, |
| 7347 |
exec: (editor, table, { control })=>{ |
| 7348 |
if (!(0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_0__.isJoditObject)(editor)) { |
| 7349 |
return; |
| 7350 |
} |
| 7351 |
if (!control.args) { |
| 7352 |
return false; |
| 7353 |
} |
| 7354 |
const command = cmd(control); |
| 7355 |
editor.execCommand(command, false, table); |
| 7356 |
editor.e.fire('hidePopup'); |
| 7357 |
}, |
| 7358 |
tooltip: 'Delete' |
| 7359 |
} |
| 7360 |
]); |
| 7361 |
|
| 7362 |
|
| 7363 |
/***/ }), |
| 7364 |
|
| 7365 |
/***/ 18073: |
| 7366 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 7367 |
|
| 7368 |
"use strict"; |
| 7369 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 7370 |
/* harmony export */ size: function() { return /* binding */ size; } |
| 7371 |
/* harmony export */ }); |
| 7372 |
/* harmony import */ var jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(28686); |
| 7373 |
/*! |
| 7374 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 7375 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 7376 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 7377 |
*/ /** |
| 7378 |
* @module helpers/size |
| 7379 |
*/ |
| 7380 |
function size(subject) { |
| 7381 |
if ((0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_0__.isString)(subject) || (0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_0__.isArray)(subject)) { |
| 7382 |
return subject.length; |
| 7383 |
} |
| 7384 |
if ((0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_0__.isPlainObject)(subject)) { |
| 7385 |
return Object.keys(subject).length; |
| 7386 |
} |
| 7387 |
return 0; |
| 7388 |
} |
| 7389 |
|
| 7390 |
|
| 7391 |
/***/ }), |
| 7392 |
|
| 7393 |
/***/ 18080: |
| 7394 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 7395 |
|
| 7396 |
"use strict"; |
| 7397 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 7398 |
/* harmony export */ i18n: function() { return /* binding */ i18n; }, |
| 7399 |
/* harmony export */ sprintf: function() { return /* binding */ sprintf; } |
| 7400 |
/* harmony export */ }); |
| 7401 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 7402 |
/* harmony import */ var jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(85932); |
| 7403 |
/* harmony import */ var jodit_core_helpers_string_ucfirst__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(99436); |
| 7404 |
/* harmony import */ var jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(93640); |
| 7405 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(5266); |
| 7406 |
/*! |
| 7407 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 7408 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 7409 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 7410 |
*/ /** |
| 7411 |
* @module helpers/string |
| 7412 |
*/ |
| 7413 |
|
| 7414 |
|
| 7415 |
|
| 7416 |
|
| 7417 |
/** |
| 7418 |
* Simple variant sprintf function |
| 7419 |
*/ const sprintf = (str, args)=>{ |
| 7420 |
if (!args || !args.length) { |
| 7421 |
return str; |
| 7422 |
} |
| 7423 |
const reg = /%([sd])/g; |
| 7424 |
let fnd = reg.exec(str); |
| 7425 |
let res = str, i = 0; |
| 7426 |
while(fnd && args[i] !== undefined){ |
| 7427 |
res = res.replace(fnd[0], args[i].toString()); |
| 7428 |
i += 1; |
| 7429 |
fnd = reg.exec(str); |
| 7430 |
} |
| 7431 |
return res; |
| 7432 |
}; |
| 7433 |
/** |
| 7434 |
* Internationalization method. Uses Jodit.lang object |
| 7435 |
* @example |
| 7436 |
* ```javascript |
| 7437 |
* var editor = Jodit.make("#redactor", { |
| 7438 |
* language: 'ru' |
| 7439 |
* }); |
| 7440 |
* console.log(editor.i18n('Cancel')) //Отмена; |
| 7441 |
* |
| 7442 |
* Jodit.defaultOptions.language = 'ru'; |
| 7443 |
* console.log(Jodit.prototype.i18n('Cancel')) //Отмена |
| 7444 |
* |
| 7445 |
* Jodit.lang.cs = { |
| 7446 |
* Cancel: 'Zrušit' |
| 7447 |
* }; |
| 7448 |
* Jodit.defaultOptions.language = 'cs'; |
| 7449 |
* console.log(Jodit.prototype.i18n('Cancel')) //Zrušit |
| 7450 |
* |
| 7451 |
* Jodit.lang.cs = { |
| 7452 |
* 'Hello world': 'Hello \s Good \s' |
| 7453 |
* }; |
| 7454 |
* Jodit.defaultOptions.language = 'cs'; |
| 7455 |
* console.log(Jodit.prototype.i18n('Hello world', 'mr.Perkins', 'day')) //Hello mr.Perkins Good day |
| 7456 |
* ``` |
| 7457 |
*/ function i18n(key, params, options) { |
| 7458 |
if (!(0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_1__.isString)(key)) { |
| 7459 |
throw (0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_3__.error)('i18n: Need string in first argument'); |
| 7460 |
} |
| 7461 |
if (!key.length) { |
| 7462 |
return key; |
| 7463 |
} |
| 7464 |
const debug = Boolean(options === null || options === void 0 ? void 0 : options.debugLanguage); |
| 7465 |
let store = {}; |
| 7466 |
const parse = (value)=>params && params.length ? sprintf(value, params) : value, defaultLanguage = (0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_3__.defaultLanguage)(jodit_config__WEBPACK_IMPORTED_MODULE_4__.Config.defaultOptions.language, jodit_config__WEBPACK_IMPORTED_MODULE_4__.Config.defaultOptions.language), language = (0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_3__.defaultLanguage)(options === null || options === void 0 ? void 0 : options.language, defaultLanguage), tryGet = (store)=>{ |
| 7467 |
if (!store) { |
| 7468 |
return; |
| 7469 |
} |
| 7470 |
if ((0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_1__.isString)(store[key])) { |
| 7471 |
return parse(store[key]); |
| 7472 |
} |
| 7473 |
const lcKey = key.toLowerCase(); |
| 7474 |
if ((0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_1__.isString)(store[lcKey])) { |
| 7475 |
return parse(store[lcKey]); |
| 7476 |
} |
| 7477 |
const ucfKey = (0,jodit_core_helpers_string_ucfirst__WEBPACK_IMPORTED_MODULE_2__.ucfirst)(key); |
| 7478 |
if ((0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_1__.isString)(store[ucfKey])) { |
| 7479 |
return parse(store[ucfKey]); |
| 7480 |
} |
| 7481 |
return; |
| 7482 |
}; |
| 7483 |
if (jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.lang[language] !== undefined) { |
| 7484 |
store = jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.lang[language]; |
| 7485 |
} else if (!debug) { |
| 7486 |
if (jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.lang[defaultLanguage] !== undefined) { |
| 7487 |
store = jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.lang[defaultLanguage]; |
| 7488 |
} else { |
| 7489 |
store = jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.lang.en; |
| 7490 |
} |
| 7491 |
} |
| 7492 |
const i18nOvr = options === null || options === void 0 ? void 0 : options.i18n; |
| 7493 |
if (i18nOvr && i18nOvr[language]) { |
| 7494 |
const result = tryGet(i18nOvr[language]); |
| 7495 |
if (result) { |
| 7496 |
return result; |
| 7497 |
} |
| 7498 |
} |
| 7499 |
const result = tryGet(store); |
| 7500 |
if (result) { |
| 7501 |
return result; |
| 7502 |
} |
| 7503 |
if (!debug && jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.lang.en && (0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_1__.isString)(jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.lang.en[key]) && jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.lang.en[key]) { |
| 7504 |
return parse(jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.lang.en[key]); |
| 7505 |
} |
| 7506 |
if (debug) { |
| 7507 |
return '{' + key + '}'; |
| 7508 |
} |
| 7509 |
if (!jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.IS_PROD && language !== 'en') { |
| 7510 |
console.warn(`i18n need "${key}" in "${language}"`); |
| 7511 |
} |
| 7512 |
return parse(key); |
| 7513 |
} |
| 7514 |
|
| 7515 |
|
| 7516 |
/***/ }), |
| 7517 |
|
| 7518 |
/***/ 18272: |
| 7519 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 7520 |
|
| 7521 |
"use strict"; |
| 7522 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 7523 |
/* harmony export */ makeContextMenu: function() { return /* binding */ makeContextMenu; }, |
| 7524 |
/* harmony export */ makeDataProvider: function() { return /* binding */ makeDataProvider; } |
| 7525 |
/* harmony export */ }); |
| 7526 |
/* harmony import */ var jodit_modules_context_menu_context_menu__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(67399); |
| 7527 |
/* harmony import */ var _data_provider__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(17780); |
| 7528 |
/*! |
| 7529 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 7530 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 7531 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 7532 |
*/ /** |
| 7533 |
* @module modules/file-browser |
| 7534 |
*/ |
| 7535 |
|
| 7536 |
function makeDataProvider(parent, options) { |
| 7537 |
return new _data_provider__WEBPACK_IMPORTED_MODULE_1__["default"](parent, options); |
| 7538 |
} |
| 7539 |
function makeContextMenu(parent) { |
| 7540 |
return new jodit_modules_context_menu_context_menu__WEBPACK_IMPORTED_MODULE_0__.ContextMenu(parent); |
| 7541 |
} |
| 7542 |
|
| 7543 |
|
| 7544 |
/***/ }), |
| 7545 |
|
| 7546 |
/***/ 18303: |
| 7547 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 7548 |
|
| 7549 |
"use strict"; |
| 7550 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 7551 |
/* harmony export */ isVoid: function() { return /* binding */ isVoid; } |
| 7552 |
/* harmony export */ }); |
| 7553 |
/*! |
| 7554 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 7555 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 7556 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 7557 |
*/ /** |
| 7558 |
* @module helpers/checker |
| 7559 |
*/ /** |
| 7560 |
* Check value is undefined or null |
| 7561 |
*/ function isVoid(value) { |
| 7562 |
// eslint-disable-next-line eqeqeq |
| 7563 |
return value === undefined || value === null; |
| 7564 |
} |
| 7565 |
|
| 7566 |
|
| 7567 |
/***/ }), |
| 7568 |
|
| 7569 |
/***/ 18377: |
| 7570 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 7571 |
|
| 7572 |
"use strict"; |
| 7573 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 7574 |
/* harmony export */ normalizePath: function() { return /* binding */ normalizePath; } |
| 7575 |
/* harmony export */ }); |
| 7576 |
/* harmony import */ var jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(4040); |
| 7577 |
/*! |
| 7578 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 7579 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 7580 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 7581 |
*/ /** |
| 7582 |
* @module helpers/normalize |
| 7583 |
*/ |
| 7584 |
/** |
| 7585 |
* Replaces back slashes and correctly concatenates several parts of the path. |
| 7586 |
*/ const normalizePath = (...path)=>{ |
| 7587 |
return path.filter((part)=>(0,jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_0__.trim)(part).length).map((part, index)=>{ |
| 7588 |
part = part.replace(/([^:])[\\/]+/g, '$1/'); |
| 7589 |
if (index) { |
| 7590 |
part = part.replace(/^\//, ''); |
| 7591 |
} |
| 7592 |
if (index !== path.length - 1) { |
| 7593 |
part = part.replace(/\/$/, ''); |
| 7594 |
} |
| 7595 |
return part; |
| 7596 |
}).join('/'); |
| 7597 |
}; |
| 7598 |
|
| 7599 |
|
| 7600 |
/***/ }), |
| 7601 |
|
| 7602 |
/***/ 18380: |
| 7603 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 7604 |
|
| 7605 |
"use strict"; |
| 7606 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 7607 |
/* harmony export */ readMargins: function() { return /* binding */ readMargins; } |
| 7608 |
/* harmony export */ }); |
| 7609 |
/* harmony import */ var jodit_core_helpers_string_kebab_case__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(74264); |
| 7610 |
/*! |
| 7611 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 7612 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 7613 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 7614 |
*/ /** |
| 7615 |
* @module plugins/image-properties |
| 7616 |
*/ |
| 7617 |
/** @private */ function readMargins(image, values, state) { |
| 7618 |
// Margins |
| 7619 |
let equal = true, wasEmptyField = false; |
| 7620 |
[ |
| 7621 |
'marginTop', |
| 7622 |
'marginRight', |
| 7623 |
'marginBottom', |
| 7624 |
'marginLeft' |
| 7625 |
].forEach((id)=>{ |
| 7626 |
let value = image.style.getPropertyValue((0,jodit_core_helpers_string_kebab_case__WEBPACK_IMPORTED_MODULE_0__.kebabCase)(id)); |
| 7627 |
if (!value) { |
| 7628 |
wasEmptyField = true; |
| 7629 |
values[id] = 0; |
| 7630 |
return; |
| 7631 |
} |
| 7632 |
if (/^[0-9]+(px)?$/.test(value)) { |
| 7633 |
value = parseInt(value, 10); |
| 7634 |
} |
| 7635 |
values[id] = value; |
| 7636 |
if (wasEmptyField && values[id] || equal && id !== 'marginTop' && values[id] !== values.marginTop) { |
| 7637 |
equal = false; |
| 7638 |
} |
| 7639 |
}); |
| 7640 |
state.marginIsLocked = equal; |
| 7641 |
} |
| 7642 |
|
| 7643 |
|
| 7644 |
/***/ }), |
| 7645 |
|
| 7646 |
/***/ 18605: |
| 7647 |
/***/ (function(module) { |
| 7648 |
|
| 7649 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M1025 1369v167h-248l-159-252-24-42q-8-9-11-21h-3l-9 21q-10 20-25 44l-155 250h-258v-167h128l197-291-185-272h-137v-168h276l139 228q2 4 23 42 8 9 11 21h3q3-9 11-21l25-42 140-228h257v168h-125l-184 267 204 296h109zm637-679v206h-514l-3-27q-4-28-4-46 0-64 26-117t65-86.5 84-65 84-54.5 65-54 26-64q0-38-29.5-62.5t-70.5-24.5q-51 0-97 39-14 11-36 38l-105-92q26-37 63-66 83-65 188-65 110 0 178 59.5t68 158.5q0 56-24.5 103t-62 76.5-81.5 58.5-82 50.5-65.5 51.5-30.5 63h232v-80h126z\"/> </svg>" |
| 7650 |
|
| 7651 |
/***/ }), |
| 7652 |
|
| 7653 |
/***/ 18762: |
| 7654 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 7655 |
|
| 7656 |
"use strict"; |
| 7657 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 7658 |
/* harmony export */ FileSelectorWidget: function() { return /* binding */ FileSelectorWidget; } |
| 7659 |
/* harmony export */ }); |
| 7660 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 7661 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(65946); |
| 7662 |
/* harmony import */ var jodit_core_ui__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(4099); |
| 7663 |
/* harmony import */ var jodit_modules_widget_tabs_tabs__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(89636); |
| 7664 |
/*! |
| 7665 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 7666 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 7667 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 7668 |
*/ /** |
| 7669 |
* [[include:modules/widget/file-selector/README.md]] |
| 7670 |
* @packageDocumentation |
| 7671 |
* @module modules/widget/file-selector |
| 7672 |
*/ |
| 7673 |
|
| 7674 |
|
| 7675 |
|
| 7676 |
/** |
| 7677 |
* Generate 3 tabs |
| 7678 |
* upload - Use Drag and Drop |
| 7679 |
* url - By specifying the image url |
| 7680 |
* filebrowser - After opening the file browser. In the absence of one of the parameters will be less tabs |
| 7681 |
* |
| 7682 |
* @param callbacks - Object with keys `url`, `upload` and `filebrowser`, values which are callback |
| 7683 |
* functions with different parameters |
| 7684 |
*/ const FileSelectorWidget = (editor, callbacks, elm, close, isImage = true)=>{ |
| 7685 |
let currentImage; |
| 7686 |
const tabs = []; |
| 7687 |
const options = editor.o.uploader; |
| 7688 |
if (callbacks.upload && (options.url || options.insertImageAsBase64URI || options.customUploadFunction)) { |
| 7689 |
const dragBox = editor.c.fromHTML('<div class="jodit-drag-and-drop__file-box">' + `<strong>${editor.i18n(isImage ? 'Drop image' : 'Drop file')}</strong>` + `<span><br>${editor.i18n('or click')}</span>` + `<input type="file" accept="${isImage ? 'image/*' : '*'}" tabindex="-1" dir="auto" multiple=""/>` + '</div>'); |
| 7690 |
editor.uploader.bind(dragBox, (resp)=>{ |
| 7691 |
const handler = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__.isFunction)(callbacks.upload) ? callbacks.upload : options.defaultHandlerSuccess; |
| 7692 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__.isFunction)(handler)) { |
| 7693 |
handler.call(editor, resp); |
| 7694 |
} |
| 7695 |
editor.e.fire('closeAllPopups'); |
| 7696 |
}, (error)=>{ |
| 7697 |
editor.message.error(error.message); |
| 7698 |
editor.e.fire('closeAllPopups'); |
| 7699 |
}); |
| 7700 |
tabs.push({ |
| 7701 |
icon: 'upload', |
| 7702 |
name: 'Upload', |
| 7703 |
content: dragBox |
| 7704 |
}); |
| 7705 |
} |
| 7706 |
if (callbacks.filebrowser) { |
| 7707 |
if (editor.o.filebrowser.ajax.url || editor.o.filebrowser.items.url) { |
| 7708 |
tabs.push({ |
| 7709 |
icon: 'folder', |
| 7710 |
name: 'Browse', |
| 7711 |
content: ()=>{ |
| 7712 |
close && close(); |
| 7713 |
if (callbacks.filebrowser) { |
| 7714 |
editor.filebrowser.open(callbacks.filebrowser, isImage); |
| 7715 |
} |
| 7716 |
} |
| 7717 |
}); |
| 7718 |
} |
| 7719 |
} |
| 7720 |
if (callbacks.url) { |
| 7721 |
const button = new jodit_core_ui__WEBPACK_IMPORTED_MODULE_2__.UIButton(editor, { |
| 7722 |
type: 'submit', |
| 7723 |
variant: 'primary', |
| 7724 |
text: 'Insert' |
| 7725 |
}), form = new jodit_core_ui__WEBPACK_IMPORTED_MODULE_2__.UIForm(editor, [ |
| 7726 |
new jodit_core_ui__WEBPACK_IMPORTED_MODULE_2__.UIInput(editor, { |
| 7727 |
required: true, |
| 7728 |
label: 'URL', |
| 7729 |
name: 'url', |
| 7730 |
type: 'text', |
| 7731 |
placeholder: 'https://' |
| 7732 |
}), |
| 7733 |
new jodit_core_ui__WEBPACK_IMPORTED_MODULE_2__.UIInput(editor, { |
| 7734 |
name: 'text', |
| 7735 |
label: 'Alternative text' |
| 7736 |
}), |
| 7737 |
new jodit_core_ui__WEBPACK_IMPORTED_MODULE_2__.UIBlock(editor, [ |
| 7738 |
button |
| 7739 |
]) |
| 7740 |
]); |
| 7741 |
currentImage = null; |
| 7742 |
if (elm && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isText(elm) && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isComment(elm) && (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(elm, 'img') || (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__.$$)('img', elm).length)) { |
| 7743 |
currentImage = elm.tagName === 'IMG' ? elm : (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__.$$)('img', elm)[0]; |
| 7744 |
val(form.container, 'input[name=url]', (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__.attr)(currentImage, 'src')); |
| 7745 |
val(form.container, 'input[name=text]', (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__.attr)(currentImage, 'alt')); |
| 7746 |
button.state.text = 'Update'; |
| 7747 |
} |
| 7748 |
if (elm && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(elm, 'a')) { |
| 7749 |
val(form.container, 'input[name=url]', (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__.attr)(elm, 'href')); |
| 7750 |
val(form.container, 'input[name=text]', (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__.attr)(elm, 'title')); |
| 7751 |
button.state.text = 'Update'; |
| 7752 |
} |
| 7753 |
form.onSubmit((data)=>{ |
| 7754 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__.isFunction)(callbacks.url)) { |
| 7755 |
callbacks.url.call(editor, data.url, data.text); |
| 7756 |
} |
| 7757 |
}); |
| 7758 |
tabs.push({ |
| 7759 |
icon: 'link', |
| 7760 |
name: 'URL', |
| 7761 |
content: form.container |
| 7762 |
}); |
| 7763 |
} |
| 7764 |
return (0,jodit_modules_widget_tabs_tabs__WEBPACK_IMPORTED_MODULE_3__.TabsWidget)(editor, tabs); |
| 7765 |
}; |
| 7766 |
function val(elm, selector, value) { |
| 7767 |
const child = elm.querySelector(selector); |
| 7768 |
if (!child) { |
| 7769 |
return ''; |
| 7770 |
} |
| 7771 |
if (value) { |
| 7772 |
child.value = value; |
| 7773 |
} |
| 7774 |
return child.value; |
| 7775 |
} |
| 7776 |
|
| 7777 |
|
| 7778 |
/***/ }), |
| 7779 |
|
| 7780 |
/***/ 18855: |
| 7781 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 7782 |
|
| 7783 |
"use strict"; |
| 7784 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 7785 |
/* harmony export */ Plugin: function() { return /* binding */ Plugin; } |
| 7786 |
/* harmony export */ }); |
| 7787 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 7788 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 7789 |
/* harmony import */ var jodit_core_component__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(16964); |
| 7790 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(84839); |
| 7791 |
/* harmony import */ var jodit_core_helpers_checker_is_jodit_object__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(24497); |
| 7792 |
/*! |
| 7793 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 7794 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 7795 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 7796 |
*/ /** |
| 7797 |
* [[include:core/plugin/README.md]] |
| 7798 |
* @packageDocumentation |
| 7799 |
* @module plugin |
| 7800 |
*/ |
| 7801 |
|
| 7802 |
|
| 7803 |
|
| 7804 |
|
| 7805 |
class Plugin extends jodit_core_component__WEBPACK_IMPORTED_MODULE_2__.ViewComponent { |
| 7806 |
/** @override */ className() { |
| 7807 |
return 'Plugin'; |
| 7808 |
} |
| 7809 |
__afterPluginSystemInit() { |
| 7810 |
const { j, buttons } = this; |
| 7811 |
if (buttons && (0,jodit_core_helpers_checker_is_jodit_object__WEBPACK_IMPORTED_MODULE_4__.isJoditObject)(j)) { |
| 7812 |
buttons.forEach((btn)=>{ |
| 7813 |
j.registerButton(btn); |
| 7814 |
}); |
| 7815 |
} |
| 7816 |
} |
| 7817 |
__afterInit() { |
| 7818 |
this.__inited = true; |
| 7819 |
this.setStatus(jodit_core_component__WEBPACK_IMPORTED_MODULE_2__.STATUSES.ready); |
| 7820 |
this.afterInit(this.jodit); |
| 7821 |
} |
| 7822 |
init(jodit) { |
| 7823 |
if (this.jodit.isReady) { |
| 7824 |
this.afterInit(this.jodit); |
| 7825 |
this.__afterPluginSystemInit(); |
| 7826 |
this.jodit.e.fire('rebuildToolbar'); |
| 7827 |
} |
| 7828 |
} |
| 7829 |
__beforeDestruct() { |
| 7830 |
if (this.isInDestruct) { |
| 7831 |
return; |
| 7832 |
} |
| 7833 |
const { j } = this; |
| 7834 |
j.e.off('afterPluginSystemInit', this.__afterPluginSystemInit).off('afterInit', this.__afterInit).off('beforeDestruct', this.destruct); |
| 7835 |
this.setStatus(jodit_core_component__WEBPACK_IMPORTED_MODULE_2__.STATUSES.beforeDestruct); |
| 7836 |
if (!this.__inited) { |
| 7837 |
return super.destruct(); |
| 7838 |
} |
| 7839 |
if ((0,jodit_core_helpers_checker_is_jodit_object__WEBPACK_IMPORTED_MODULE_4__.isJoditObject)(j)) { |
| 7840 |
var _this_buttons; |
| 7841 |
(_this_buttons = this.buttons) === null || _this_buttons === void 0 ? void 0 : _this_buttons.forEach((btn)=>{ |
| 7842 |
j === null || j === void 0 ? void 0 : j.unregisterButton(btn); |
| 7843 |
}); |
| 7844 |
} |
| 7845 |
this.beforeDestruct(this.j); |
| 7846 |
super.destruct(); |
| 7847 |
} |
| 7848 |
constructor(jodit){ |
| 7849 |
super(jodit), /** @override */ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "buttons", []), /** |
| 7850 |
* Plugin have CSS style and it should be loaded |
| 7851 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "hasStyle", false), /** |
| 7852 |
* Additional plugin styles can be written simply as inline styles |
| 7853 |
* ```js |
| 7854 |
* class A extends Jodit.modules.Plugin { |
| 7855 |
* styles = 'h1{color: red}'; |
| 7856 |
* } |
| 7857 |
* ``` |
| 7858 |
* Will only be applied if the plugin is activated |
| 7859 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "styles", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__inited", false); |
| 7860 |
jodit.e.on('afterPluginSystemInit', this.__afterPluginSystemInit).on('afterInit', this.__afterInit).on('beforeDestruct', this.__beforeDestruct); |
| 7861 |
} |
| 7862 |
} |
| 7863 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(Plugin, "requires", []); |
| 7864 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 7865 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 7866 |
], Plugin.prototype, "__afterPluginSystemInit", null); |
| 7867 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 7868 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 7869 |
], Plugin.prototype, "__afterInit", null); |
| 7870 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 7871 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 7872 |
], Plugin.prototype, "__beforeDestruct", null); |
| 7873 |
|
| 7874 |
|
| 7875 |
/***/ }), |
| 7876 |
|
| 7877 |
/***/ 18869: |
| 7878 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 7879 |
|
| 7880 |
"use strict"; |
| 7881 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 7882 |
/* harmony export */ EventHandlersStore: function() { return /* binding */ EventHandlersStore; }, |
| 7883 |
/* harmony export */ defaultNameSpace: function() { return /* binding */ defaultNameSpace; } |
| 7884 |
/* harmony export */ }); |
| 7885 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 7886 |
/* harmony import */ var jodit_core_helpers_array_to_array__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(88475); |
| 7887 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(28712); |
| 7888 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_2__); |
| 7889 |
/*! |
| 7890 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 7891 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 7892 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 7893 |
*/ /** |
| 7894 |
* @module event-emitter |
| 7895 |
*/ |
| 7896 |
|
| 7897 |
|
| 7898 |
const defaultNameSpace = 'JoditEventDefaultNamespace'; |
| 7899 |
class EventHandlersStore { |
| 7900 |
get(event, namespace) { |
| 7901 |
if (this.__store.has(namespace)) { |
| 7902 |
const ns = this.__store.get(namespace); |
| 7903 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_2__.assert)(ns, '-'); |
| 7904 |
return ns[event]; |
| 7905 |
} |
| 7906 |
} |
| 7907 |
indexOf(event, namespace, originalCallback) { |
| 7908 |
const blocks = this.get(event, namespace); |
| 7909 |
if (blocks) { |
| 7910 |
for(let i = 0; i < blocks.length; i += 1){ |
| 7911 |
if (blocks[i].originalCallback === originalCallback) { |
| 7912 |
return i; |
| 7913 |
} |
| 7914 |
} |
| 7915 |
} |
| 7916 |
return false; |
| 7917 |
} |
| 7918 |
namespaces(withoutDefault = false) { |
| 7919 |
const nss = (0,jodit_core_helpers_array_to_array__WEBPACK_IMPORTED_MODULE_1__.toArray)(this.__store.keys()); |
| 7920 |
return withoutDefault ? nss.filter((ns)=>ns !== defaultNameSpace) : nss; |
| 7921 |
} |
| 7922 |
events(namespace) { |
| 7923 |
const ns = this.__store.get(namespace); |
| 7924 |
return ns ? Object.keys(ns) : []; |
| 7925 |
} |
| 7926 |
set(event, namespace, data, onTop = false) { |
| 7927 |
let ns = this.__store.get(namespace); |
| 7928 |
if (!ns) { |
| 7929 |
ns = {}; |
| 7930 |
this.__store.set(namespace, ns); |
| 7931 |
} |
| 7932 |
if (ns[event] === undefined) { |
| 7933 |
ns[event] = []; |
| 7934 |
} |
| 7935 |
if (!onTop) { |
| 7936 |
ns[event].push(data); |
| 7937 |
} else { |
| 7938 |
ns[event].unshift(data); |
| 7939 |
} |
| 7940 |
} |
| 7941 |
clear() { |
| 7942 |
this.__store.clear(); |
| 7943 |
} |
| 7944 |
clearEvents(namespace, event) { |
| 7945 |
const ns = this.__store.get(namespace); |
| 7946 |
if (ns && ns[event]) { |
| 7947 |
delete ns[event]; |
| 7948 |
if (!Object.keys(ns).length) { |
| 7949 |
this.__store.delete(namespace); |
| 7950 |
} |
| 7951 |
} |
| 7952 |
} |
| 7953 |
isEmpty() { |
| 7954 |
return this.__store.size === 0; |
| 7955 |
} |
| 7956 |
constructor(){ |
| 7957 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__store", new Map()); |
| 7958 |
} |
| 7959 |
} |
| 7960 |
|
| 7961 |
|
| 7962 |
/***/ }), |
| 7963 |
|
| 7964 |
/***/ 18929: |
| 7965 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 7966 |
|
| 7967 |
"use strict"; |
| 7968 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 7969 |
/* harmony import */ var jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(29434); |
| 7970 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5266); |
| 7971 |
/* harmony import */ var _source_svg__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(9103); |
| 7972 |
/* harmony import */ var _source_svg__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_source_svg__WEBPACK_IMPORTED_MODULE_3__); |
| 7973 |
/*! |
| 7974 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 7975 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 7976 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 7977 |
*/ /** |
| 7978 |
* @module plugins/source |
| 7979 |
*/ |
| 7980 |
|
| 7981 |
|
| 7982 |
|
| 7983 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.beautifyHTML = !jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.IS_IE; |
| 7984 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.sourceEditor = 'ace'; |
| 7985 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.sourceEditorNativeOptions = { |
| 7986 |
/** |
| 7987 |
* Show gutter |
| 7988 |
*/ showGutter: true, |
| 7989 |
/** |
| 7990 |
* Default theme |
| 7991 |
*/ theme: 'ace/theme/idle_fingers', |
| 7992 |
/** |
| 7993 |
* Default mode |
| 7994 |
*/ mode: 'ace/mode/html', |
| 7995 |
/** |
| 7996 |
* Wrap lines. Possible values - "off", 80-100..., true, "free" |
| 7997 |
*/ wrap: true, |
| 7998 |
/** |
| 7999 |
* Highlight active line |
| 8000 |
*/ highlightActiveLine: true |
| 8001 |
}; |
| 8002 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.sourceEditorCDNUrlsJS = [ |
| 8003 |
'https://cdnjs.cloudflare.com/ajax/libs/ace/1.4.2/ace.js' |
| 8004 |
]; |
| 8005 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.beautifyHTMLCDNUrlsJS = [ |
| 8006 |
'https://cdnjs.cloudflare.com/ajax/libs/js-beautify/1.14.4/beautify.min.js', |
| 8007 |
'https://cdnjs.cloudflare.com/ajax/libs/js-beautify/1.14.4/beautify-html.min.js' |
| 8008 |
]; |
| 8009 |
jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_1__.Icon.set('source', (_source_svg__WEBPACK_IMPORTED_MODULE_3___default())); |
| 8010 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.controls.source = { |
| 8011 |
mode: jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.MODE_SPLIT, |
| 8012 |
exec: (editor)=>{ |
| 8013 |
editor.toggleMode(); |
| 8014 |
}, |
| 8015 |
isActive: (editor)=>{ |
| 8016 |
return editor.getRealMode() === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.MODE_SOURCE; |
| 8017 |
}, |
| 8018 |
tooltip: 'Change mode' |
| 8019 |
}; |
| 8020 |
|
| 8021 |
|
| 8022 |
/***/ }), |
| 8023 |
|
| 8024 |
/***/ 18993: |
| 8025 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 8026 |
|
| 8027 |
"use strict"; |
| 8028 |
/* harmony import */ var jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(29434); |
| 8029 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(5266); |
| 8030 |
/* harmony import */ var _symbols_svg__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(81875); |
| 8031 |
/* harmony import */ var _symbols_svg__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_symbols_svg__WEBPACK_IMPORTED_MODULE_2__); |
| 8032 |
/*! |
| 8033 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 8034 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 8035 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 8036 |
*/ /** |
| 8037 |
* @module plugins/symbols |
| 8038 |
*/ |
| 8039 |
|
| 8040 |
|
| 8041 |
jodit_config__WEBPACK_IMPORTED_MODULE_1__.Config.prototype.usePopupForSpecialCharacters = false; |
| 8042 |
jodit_config__WEBPACK_IMPORTED_MODULE_1__.Config.prototype.specialCharacters = [ |
| 8043 |
'!', |
| 8044 |
'"', |
| 8045 |
'#', |
| 8046 |
'$', |
| 8047 |
'%', |
| 8048 |
'&', |
| 8049 |
"'", |
| 8050 |
'(', |
| 8051 |
')', |
| 8052 |
'*', |
| 8053 |
'+', |
| 8054 |
'-', |
| 8055 |
'.', |
| 8056 |
'/', |
| 8057 |
'0', |
| 8058 |
'1', |
| 8059 |
'2', |
| 8060 |
'3', |
| 8061 |
'4', |
| 8062 |
'5', |
| 8063 |
'6', |
| 8064 |
'7', |
| 8065 |
'8', |
| 8066 |
'9', |
| 8067 |
':', |
| 8068 |
';', |
| 8069 |
'<', |
| 8070 |
'=', |
| 8071 |
'>', |
| 8072 |
'?', |
| 8073 |
'@', |
| 8074 |
'A', |
| 8075 |
'B', |
| 8076 |
'C', |
| 8077 |
'D', |
| 8078 |
'E', |
| 8079 |
'F', |
| 8080 |
'G', |
| 8081 |
'H', |
| 8082 |
'I', |
| 8083 |
'J', |
| 8084 |
'K', |
| 8085 |
'L', |
| 8086 |
'M', |
| 8087 |
'N', |
| 8088 |
'O', |
| 8089 |
'P', |
| 8090 |
'Q', |
| 8091 |
'R', |
| 8092 |
'S', |
| 8093 |
'T', |
| 8094 |
'U', |
| 8095 |
'V', |
| 8096 |
'W', |
| 8097 |
'X', |
| 8098 |
'Y', |
| 8099 |
'Z', |
| 8100 |
'[', |
| 8101 |
']', |
| 8102 |
'^', |
| 8103 |
'_', |
| 8104 |
'`', |
| 8105 |
'a', |
| 8106 |
'b', |
| 8107 |
'c', |
| 8108 |
'd', |
| 8109 |
'e', |
| 8110 |
'f', |
| 8111 |
'g', |
| 8112 |
'h', |
| 8113 |
'i', |
| 8114 |
'j', |
| 8115 |
'k', |
| 8116 |
'l', |
| 8117 |
'm', |
| 8118 |
'n', |
| 8119 |
'o', |
| 8120 |
'p', |
| 8121 |
'q', |
| 8122 |
'r', |
| 8123 |
's', |
| 8124 |
't', |
| 8125 |
'u', |
| 8126 |
'v', |
| 8127 |
'w', |
| 8128 |
'x', |
| 8129 |
'y', |
| 8130 |
'z', |
| 8131 |
'{', |
| 8132 |
'|', |
| 8133 |
'}', |
| 8134 |
'~', |
| 8135 |
'€', |
| 8136 |
'‘', |
| 8137 |
'’', |
| 8138 |
'“', |
| 8139 |
'”', |
| 8140 |
'–', |
| 8141 |
'—', |
| 8142 |
'¡', |
| 8143 |
'¢', |
| 8144 |
'£', |
| 8145 |
'¤', |
| 8146 |
'¥', |
| 8147 |
'¦', |
| 8148 |
'§', |
| 8149 |
'¨', |
| 8150 |
'©', |
| 8151 |
'ª', |
| 8152 |
'«', |
| 8153 |
'»', |
| 8154 |
'¬', |
| 8155 |
'®', |
| 8156 |
'¯', |
| 8157 |
'°', |
| 8158 |
'²', |
| 8159 |
'³', |
| 8160 |
'´', |
| 8161 |
'µ', |
| 8162 |
'¶', |
| 8163 |
'·', |
| 8164 |
'¸', |
| 8165 |
'¹', |
| 8166 |
'º', |
| 8167 |
'¼', |
| 8168 |
'½', |
| 8169 |
'¾', |
| 8170 |
'¿', |
| 8171 |
'À', |
| 8172 |
'Á', |
| 8173 |
'Â', |
| 8174 |
'Ã', |
| 8175 |
'Ä', |
| 8176 |
'Å', |
| 8177 |
'Æ', |
| 8178 |
'Ç', |
| 8179 |
'È', |
| 8180 |
'É', |
| 8181 |
'Ê', |
| 8182 |
'Ë', |
| 8183 |
'Ì', |
| 8184 |
'Í', |
| 8185 |
'Î', |
| 8186 |
'Ï', |
| 8187 |
'Ð', |
| 8188 |
'Ñ', |
| 8189 |
'Ò', |
| 8190 |
'Ó', |
| 8191 |
'Ô', |
| 8192 |
'Õ', |
| 8193 |
'Ö', |
| 8194 |
'×', |
| 8195 |
'Ø', |
| 8196 |
'Ù', |
| 8197 |
'Ú', |
| 8198 |
'Û', |
| 8199 |
'Ü', |
| 8200 |
'Ý', |
| 8201 |
'Þ', |
| 8202 |
'ß', |
| 8203 |
'à', |
| 8204 |
'á', |
| 8205 |
'â', |
| 8206 |
'ã', |
| 8207 |
'ä', |
| 8208 |
'å', |
| 8209 |
'æ', |
| 8210 |
'ç', |
| 8211 |
'è', |
| 8212 |
'é', |
| 8213 |
'ê', |
| 8214 |
'ë', |
| 8215 |
'ì', |
| 8216 |
'í', |
| 8217 |
'î', |
| 8218 |
'ï', |
| 8219 |
'ð', |
| 8220 |
'ñ', |
| 8221 |
'ò', |
| 8222 |
'ó', |
| 8223 |
'ô', |
| 8224 |
'õ', |
| 8225 |
'ö', |
| 8226 |
'÷', |
| 8227 |
'ø', |
| 8228 |
'ù', |
| 8229 |
'ú', |
| 8230 |
'û', |
| 8231 |
'ü', |
| 8232 |
'ý', |
| 8233 |
'þ', |
| 8234 |
'ÿ', |
| 8235 |
'Œ', |
| 8236 |
'œ', |
| 8237 |
'Ŵ', |
| 8238 |
'Ŷ', |
| 8239 |
'ŵ', |
| 8240 |
'ŷ', |
| 8241 |
'‚', |
| 8242 |
'‛', |
| 8243 |
'„', |
| 8244 |
'…', |
| 8245 |
'™', |
| 8246 |
'►', |
| 8247 |
'•', |
| 8248 |
'→', |
| 8249 |
'⇒', |
| 8250 |
'⇔', |
| 8251 |
'♦', |
| 8252 |
'≈' |
| 8253 |
]; |
| 8254 |
jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_0__.Icon.set('symbols', (_symbols_svg__WEBPACK_IMPORTED_MODULE_2___default())); |
| 8255 |
jodit_config__WEBPACK_IMPORTED_MODULE_1__.Config.prototype.controls.symbols = { |
| 8256 |
hotkeys: [ |
| 8257 |
'ctrl+shift+i', |
| 8258 |
'cmd+shift+i' |
| 8259 |
], |
| 8260 |
tooltip: 'Insert Special Character', |
| 8261 |
popup: (editor, current, close)=>{ |
| 8262 |
const container = editor.e.fire('generateSpecialCharactersTable.symbols'); |
| 8263 |
if (container) { |
| 8264 |
if (editor.o.usePopupForSpecialCharacters) { |
| 8265 |
const box = editor.c.div(); |
| 8266 |
box.classList.add('jodit-symbols'); |
| 8267 |
box.appendChild(container); |
| 8268 |
editor.e.on(container, 'close_dialog', close); |
| 8269 |
return box; |
| 8270 |
} |
| 8271 |
editor.alert(container, 'Select Special Character', undefined, 'jodit-symbols').bindDestruct(editor); |
| 8272 |
const a = container.querySelector('a'); |
| 8273 |
a && a.focus(); |
| 8274 |
} |
| 8275 |
return; |
| 8276 |
} |
| 8277 |
}; |
| 8278 |
|
| 8279 |
|
| 8280 |
/***/ }), |
| 8281 |
|
| 8282 |
/***/ 19147: |
| 8283 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 8284 |
|
| 8285 |
"use strict"; |
| 8286 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 8287 |
/* harmony export */ NUMBER_FIELDS_REG: function() { return /* binding */ NUMBER_FIELDS_REG; }, |
| 8288 |
/* harmony export */ normalizeCssNumericValue: function() { return /* binding */ normalizeCssNumericValue; }, |
| 8289 |
/* harmony export */ normalizeCssValue: function() { return /* binding */ normalizeCssValue; } |
| 8290 |
/* harmony export */ }); |
| 8291 |
/* harmony import */ var jodit_core_helpers_checker_is_numeric__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(70222); |
| 8292 |
/* harmony import */ var jodit_core_helpers_checker_is_void__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(18303); |
| 8293 |
/* harmony import */ var jodit_core_helpers_color_color_to_hex__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(93387); |
| 8294 |
/* harmony import */ var jodit_core_helpers_string_kebab_case__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(74264); |
| 8295 |
/*! |
| 8296 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 8297 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 8298 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 8299 |
*/ /** |
| 8300 |
* @module helpers/normalize |
| 8301 |
*/ |
| 8302 |
|
| 8303 |
|
| 8304 |
|
| 8305 |
const NUMBER_FIELDS_REG = /^(left|top|bottom|right|width|min|max|height|margin|padding|fontsize|font-size)/i; |
| 8306 |
function normalizeCssNumericValue(key, value) { |
| 8307 |
if (!(0,jodit_core_helpers_checker_is_void__WEBPACK_IMPORTED_MODULE_1__.isVoid)(value) && NUMBER_FIELDS_REG.test(key) && (0,jodit_core_helpers_checker_is_numeric__WEBPACK_IMPORTED_MODULE_0__.isNumeric)(value.toString())) { |
| 8308 |
return parseInt(value.toString(), 10) + 'px'; |
| 8309 |
} |
| 8310 |
return value; |
| 8311 |
} |
| 8312 |
function normalizeCssValue(key, value) { |
| 8313 |
switch((0,jodit_core_helpers_string_kebab_case__WEBPACK_IMPORTED_MODULE_3__.kebabCase)(key)){ |
| 8314 |
case 'font-weight': |
| 8315 |
switch(value.toString().toLowerCase()){ |
| 8316 |
case '700': |
| 8317 |
case 'bold': |
| 8318 |
return 700; |
| 8319 |
case '400': |
| 8320 |
case 'normal': |
| 8321 |
return 400; |
| 8322 |
case '900': |
| 8323 |
case 'heavy': |
| 8324 |
return 900; |
| 8325 |
} |
| 8326 |
return (0,jodit_core_helpers_checker_is_numeric__WEBPACK_IMPORTED_MODULE_0__.isNumeric)(value) ? Number(value) : value; |
| 8327 |
} |
| 8328 |
if (/color/i.test(key) && /^rgb/i.test(value.toString())) { |
| 8329 |
return (0,jodit_core_helpers_color_color_to_hex__WEBPACK_IMPORTED_MODULE_2__.colorToHex)(value.toString()) || value; |
| 8330 |
} |
| 8331 |
return value; |
| 8332 |
} |
| 8333 |
|
| 8334 |
|
| 8335 |
/***/ }), |
| 8336 |
|
| 8337 |
/***/ 19549: |
| 8338 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 8339 |
|
| 8340 |
"use strict"; |
| 8341 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 8342 |
/* harmony export */ getSuitParent: function() { return /* binding */ getSuitParent; } |
| 8343 |
/* harmony export */ }); |
| 8344 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 8345 |
/* harmony import */ var _is_normal_node__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(83653); |
| 8346 |
/* harmony import */ var _is_suit_element__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(73019); |
| 8347 |
/*! |
| 8348 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 8349 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 8350 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 8351 |
*/ |
| 8352 |
|
| 8353 |
|
| 8354 |
/** |
| 8355 |
* Checks if the parent of an element is suitable for applying styles, if applicable, then returns the parent * |
| 8356 |
* |
| 8357 |
* @param style - styles to be applied |
| 8358 |
* @param node - checked item |
| 8359 |
* @param root - editor root |
| 8360 |
* @private |
| 8361 |
*/ function getSuitParent(style, node, root) { |
| 8362 |
const { parentNode } = node; |
| 8363 |
if (parentNode === root || !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isHTMLElement(parentNode) || jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.next(node, _is_normal_node__WEBPACK_IMPORTED_MODULE_1__.isNormalNode, parentNode) || jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.prev(node, _is_normal_node__WEBPACK_IMPORTED_MODULE_1__.isNormalNode, parentNode)) { |
| 8364 |
return null; |
| 8365 |
} |
| 8366 |
// <h3><span style="color:red">|test|</span></h3> => apply <h2> |
| 8367 |
if (style.isElementCommit && style.elementIsBlock && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isBlock(parentNode)) { |
| 8368 |
return getSuitParent(style, parentNode, root); |
| 8369 |
} |
| 8370 |
if ((0,_is_suit_element__WEBPACK_IMPORTED_MODULE_2__.isSuitElement)(style, parentNode, false) && (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isBlock(parentNode) || style.elementIsBlock)) { |
| 8371 |
return parentNode; |
| 8372 |
} |
| 8373 |
// <strong style="color:red"><em>|test|</em></strong> => apply <strong> |
| 8374 |
if (style.isElementCommit && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isBlock(parentNode)) { |
| 8375 |
return getSuitParent(style, parentNode, root); |
| 8376 |
} |
| 8377 |
return null; |
| 8378 |
} |
| 8379 |
|
| 8380 |
|
| 8381 |
/***/ }), |
| 8382 |
|
| 8383 |
/***/ 20784: |
| 8384 |
/***/ (function(module) { |
| 8385 |
|
| 8386 |
module.exports = "<svg viewBox=\"0 0 48 48\" xmlns=\"http://www.w3.org/2000/svg\"> <path stroke=\"null\" d=\"m42.276011,26.302547c0.098397,-0.76605 0.172194,-1.54407 0.172194,-2.33406s-0.073797,-1.56801 -0.172194,-2.33406l5.202718,-3.961917c0.467384,-0.359086 0.602679,-1.005441 0.29519,-1.532101l-4.919828,-8.29489c-0.307489,-0.51469 -0.947067,-0.730142 -1.500548,-0.51469l-6.125186,2.405877c-1.266856,-0.945594 -2.656707,-1.747553 -4.157255,-2.357999l-0.922468,-6.343855c-0.110696,-0.562568 -0.614979,-1.005441 -1.229957,-1.005441l-9.839656,0c-0.614979,0 -1.119261,0.442873 -1.217657,1.005441l-0.922468,6.343855c-1.500548,0.610446 -2.890399,1.400436 -4.157255,2.357999l-6.125186,-2.405877c-0.553481,-0.203482 -1.193058,0 -1.500548,0.51469l-4.919828,8.29489c-0.307489,0.51469 -0.172194,1.161045 0.29519,1.532101l5.190419,3.961917c-0.098397,0.76605 -0.172194,1.54407 -0.172194,2.33406s0.073797,1.56801 0.172194,2.33406l-5.190419,3.961917c-0.467384,0.359086 -0.602679,1.005441 -0.29519,1.532101l4.919828,8.29489c0.307489,0.51469 0.947067,0.730142 1.500548,0.51469l6.125186,-2.405877c1.266856,0.945594 2.656707,1.747553 4.157255,2.357999l0.922468,6.343855c0.098397,0.562568 0.602679,1.005441 1.217657,1.005441l9.839656,0c0.614979,0 1.119261,-0.442873 1.217657,-1.005441l0.922468,-6.343855c1.500548,-0.610446 2.890399,-1.400436 4.157255,-2.357999l6.125186,2.405877c0.553481,0.203482 1.193058,0 1.500548,-0.51469l4.919828,-8.29489c0.307489,-0.51469 0.172194,-1.161045 -0.29519,-1.532101l-5.190419,-3.961917zm-18.277162,6.044617c-4.759934,0 -8.609699,-3.746465 -8.609699,-8.378677s3.849766,-8.378677 8.609699,-8.378677s8.609699,3.746465 8.609699,8.378677s-3.849766,8.378677 -8.609699,8.378677z\"/> </svg>" |
| 8387 |
|
| 8388 |
/***/ }), |
| 8389 |
|
| 8390 |
/***/ 21132: |
| 8391 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 8392 |
|
| 8393 |
"use strict"; |
| 8394 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 8395 |
/* harmony export */ applyMargin: function() { return /* binding */ applyMargin; } |
| 8396 |
/* harmony export */ }); |
| 8397 |
/* harmony import */ var jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(80991); |
| 8398 |
/* harmony import */ var _utils_utils__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(10808); |
| 8399 |
/*! |
| 8400 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 8401 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 8402 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 8403 |
*/ /** |
| 8404 |
* @module plugins/image-properties |
| 8405 |
*/ |
| 8406 |
|
| 8407 |
/** @private */ function applyMargin(j, marginTop, marginRight, marginBottom, marginLeft, image, marginIsLocked) { |
| 8408 |
const margins = [ |
| 8409 |
marginTop, |
| 8410 |
marginRight, |
| 8411 |
marginBottom, |
| 8412 |
marginLeft |
| 8413 |
]; |
| 8414 |
const applyMargin = (key, value)=>{ |
| 8415 |
const oldValue = (0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_0__.css)(image, key); |
| 8416 |
const v = (0,_utils_utils__WEBPACK_IMPORTED_MODULE_1__.normalSizeToString)(value); |
| 8417 |
if (oldValue.toString() !== v.toString()) { |
| 8418 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_0__.css)(image, key, v); |
| 8419 |
} |
| 8420 |
}; |
| 8421 |
if (!marginIsLocked) { |
| 8422 |
const sides = [ |
| 8423 |
'margin-top', |
| 8424 |
'margin-right', |
| 8425 |
'margin-bottom', |
| 8426 |
'margin-left' |
| 8427 |
]; |
| 8428 |
margins.forEach((margin, index)=>{ |
| 8429 |
const side = sides[index]; |
| 8430 |
applyMargin(side, margin); |
| 8431 |
}); |
| 8432 |
} else { |
| 8433 |
applyMargin('margin', marginTop); |
| 8434 |
} |
| 8435 |
} |
| 8436 |
|
| 8437 |
|
| 8438 |
/***/ }), |
| 8439 |
|
| 8440 |
/***/ 21195: |
| 8441 |
/***/ (function(module) { |
| 8442 |
|
| 8443 |
module.exports["default"] = ["なにかタイプしてください","Joditについて","Jodit Editor","Jodit ユーザーズ・ガイド","詳しい使い方","ライセンス詳細についてはJodit Webサイトを確認ください:","フルバージョンを購入","Copyright © XDSoft.net - Chupurnov Valeriy. All rights reserved.","Anchor","新しいタブで開く","エディターのサイズ(フル/ノーマル)","書式をクリア","テキストの色","やり直し","元に戻す","太字","斜体","箇条書き","番号付きリスト","中央揃え","両端揃え","左揃え","右揃え","区切り線を挿入","画像を挿入","ファイルを挿入","Youtube/Vimeo 動画","リンクを挿入","フォントサイズ","フォント","テキストのスタイル","指定なし","タイトル1","タイトル2","タイトル3","タイトル4","引用","コード","挿入","表を挿入","インデント減","インデント増","特殊文字を選択","特殊文字を挿入","書式を貼付け","編集モード切替え","マージン","上","右","下","左","スタイル","クラス","配置","右寄せ","中央寄せ","左寄せ","指定なし","ソース","タイトル","代替テキスト","リンク","新しいタブで開く","画像","ファイル","高度な設定","画像のプロパティー","キャンセル","確定","File Browser","Error on load list","Error on load folders","Are you sure?","Enter Directory name","Create directory","type name","ここに画像をドロップ","ここにファイルをドロップ","or クリック","代替テキスト","アップロード","ブラウズ","背景","文字","上","中央","下","左に列を挿入","右に列を挿入","上に行を挿入","下に行を挿入","表を削除","行を削除","列を削除","セルを空にする","文字数: %d","単語数: %d","取り消し線","下線","上付き文字","下付き文字","切り取り","すべて選択","Pause","検索","置換","交換","貼付け","選択した内容を貼付け","source","bold","italic","brush","link","undo","redo","table","image","eraser","paragraph","fontsize","video","font","about","print","underline","strikethrough","indent","outdent","fullsize","shrink","分割線","箇条書き","番号付きリスト","切り取り","すべて選択","埋め込みコード","リンクを開く","リンクを編集","No follow","リンク解除","更新","鉛筆","サイトを確認","URL","編集","水平方向の配置","Filter","Sort by changed","Sort by name","Sort by size","Add folder","リセット","保存","Save as ...","リサイズ","Crop","幅","高さ","縦横比を保持","はい","いいえ","移除","選択","選択: %s","垂直方向の配置","分割","セルの結合","列を追加","行を追加","ライセンス: %s","削除","セルの分割(垂直方向)","セルの分割(水平方向)","境界線","HTMLコードを保持しますか?","HTMLで貼付け","HTMLを保持","HTMLをテキストにする","テキストだけ","You can only edit your own images. Download this image on the host?","The image has been successfully uploaded to the host!","パレット","There are no files","Rename","Enter new name","プレビュー","ダウンロード","貼り付け","お使いのブラウザはクリップボードを使用できません","コピー","copy","角の丸み","全て表示","適用","まだこの分野","を入力してくださいウェブアドレス","デフォルト","白丸","黒丸","四角","見","探前","由来","The pasted content is coming from a Microsoft Word/Excel document. Do you want to keep the format or clean it up?","Word Paste Detected","Clean","クラス名を挿入","カスタムサイズ変更のためのAltキーを押します",null,null,null,"全部"] |
| 8444 |
|
| 8445 |
/***/ }), |
| 8446 |
|
| 8447 |
/***/ 21513: |
| 8448 |
/***/ (function(module) { |
| 8449 |
|
| 8450 |
/*! |
| 8451 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 8452 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 8453 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 8454 |
*/ module.exports = { |
| 8455 |
'copy-format': 'Format de copie' |
| 8456 |
}; |
| 8457 |
|
| 8458 |
|
| 8459 |
/***/ }), |
| 8460 |
|
| 8461 |
/***/ 22289: |
| 8462 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 8463 |
|
| 8464 |
"use strict"; |
| 8465 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 8466 |
/* harmony export */ isBoolean: function() { return /* binding */ isBoolean; } |
| 8467 |
/* harmony export */ }); |
| 8468 |
/*! |
| 8469 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 8470 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 8471 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 8472 |
*/ /** |
| 8473 |
* @module helpers/checker |
| 8474 |
*/ function isBoolean(elm) { |
| 8475 |
return typeof elm === 'boolean'; |
| 8476 |
} |
| 8477 |
|
| 8478 |
|
| 8479 |
/***/ }), |
| 8480 |
|
| 8481 |
/***/ 22380: |
| 8482 |
/***/ (function(module) { |
| 8483 |
|
| 8484 |
/*! |
| 8485 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 8486 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 8487 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 8488 |
*/ module.exports = { |
| 8489 |
'copy-format': 'Copiar formato' |
| 8490 |
}; |
| 8491 |
|
| 8492 |
|
| 8493 |
/***/ }), |
| 8494 |
|
| 8495 |
/***/ 22533: |
| 8496 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 8497 |
|
| 8498 |
"use strict"; |
| 8499 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 8500 |
/* harmony export */ ToolbarButton: function() { return /* binding */ ToolbarButton; } |
| 8501 |
/* harmony export */ }); |
| 8502 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 8503 |
/* harmony import */ var _swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(41411); |
| 8504 |
/* harmony import */ var _swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(15366); |
| 8505 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(31635); |
| 8506 |
/* harmony import */ var jodit_core_component_statuses__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(69364); |
| 8507 |
/* harmony import */ var jodit_core_decorators_autobind_autobind__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(49574); |
| 8508 |
/* harmony import */ var jodit_core_decorators_cache_cache__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(51676); |
| 8509 |
/* harmony import */ var jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(91672); |
| 8510 |
/* harmony import */ var jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(68616); |
| 8511 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(23211); |
| 8512 |
/* harmony import */ var jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(17312); |
| 8513 |
/* harmony import */ var jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(91565); |
| 8514 |
/* harmony import */ var jodit_core_helpers_checker_is_jodit_object__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(24497); |
| 8515 |
/* harmony import */ var jodit_core_helpers_checker_is_plain_object__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(62101); |
| 8516 |
/* harmony import */ var jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(85932); |
| 8517 |
/* harmony import */ var jodit_core_helpers_size__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(86878); |
| 8518 |
/* harmony import */ var jodit_core_helpers_string_camel_case__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(57821); |
| 8519 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(28712); |
| 8520 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_17___default = /*#__PURE__*/__webpack_require__.n(jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_17__); |
| 8521 |
/* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(7909); |
| 8522 |
/* harmony import */ var jodit_core_helpers_utils_utils__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(71125); |
| 8523 |
/* harmony import */ var jodit_core_ui_button__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(59400); |
| 8524 |
/* harmony import */ var jodit_core_ui_helpers_get_control_type__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(15982); |
| 8525 |
/* harmony import */ var jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(29434); |
| 8526 |
/* harmony import */ var jodit_core_ui_popup_popup__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__(51116); |
| 8527 |
/* harmony import */ var _factory__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__(4274); |
| 8528 |
/*! |
| 8529 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 8530 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 8531 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 8532 |
*/ /** |
| 8533 |
* [[include:modules/toolbar/button/README.md]] |
| 8534 |
* @packageDocumentation |
| 8535 |
* @module modules/toolbar/button |
| 8536 |
*/ |
| 8537 |
|
| 8538 |
|
| 8539 |
|
| 8540 |
|
| 8541 |
|
| 8542 |
|
| 8543 |
|
| 8544 |
|
| 8545 |
|
| 8546 |
|
| 8547 |
|
| 8548 |
|
| 8549 |
|
| 8550 |
|
| 8551 |
|
| 8552 |
|
| 8553 |
|
| 8554 |
|
| 8555 |
|
| 8556 |
|
| 8557 |
|
| 8558 |
|
| 8559 |
|
| 8560 |
|
| 8561 |
|
| 8562 |
class ToolbarButton extends jodit_core_ui_button__WEBPACK_IMPORTED_MODULE_20__.UIButton { |
| 8563 |
className() { |
| 8564 |
return 'ToolbarButton'; |
| 8565 |
} |
| 8566 |
getRole() { |
| 8567 |
return 'listitem'; |
| 8568 |
} |
| 8569 |
updateAriaLabel() { |
| 8570 |
super.updateAriaLabel(); |
| 8571 |
if (this.trigger) { |
| 8572 |
const i8nTooltip = this.state.tooltip ? this.jodit.i18n(this.state.tooltip) : null; |
| 8573 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_18__.attr)(this.trigger, 'aria-label', i8nTooltip); |
| 8574 |
} |
| 8575 |
} |
| 8576 |
/** |
| 8577 |
* Get parent toolbar |
| 8578 |
*/ get toolbar() { |
| 8579 |
const ToolbarCollection = (0,jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_7__.getComponentClass)('ToolbarCollection'); |
| 8580 |
return this.closest(ToolbarCollection); |
| 8581 |
} |
| 8582 |
update() { |
| 8583 |
var _control_value, _control_update; |
| 8584 |
const { control, state } = this; |
| 8585 |
const tc = this.toolbar; |
| 8586 |
if (!tc) { |
| 8587 |
return; |
| 8588 |
} |
| 8589 |
const value = (_control_value = control.value) === null || _control_value === void 0 ? void 0 : _control_value.call(control, tc.jodit, this); |
| 8590 |
if (value !== undefined) { |
| 8591 |
state.value = value; |
| 8592 |
} |
| 8593 |
state.disabled = this.__calculateDisabledStatus(tc); |
| 8594 |
state.activated = this.__calculateActivatedStatus(tc); |
| 8595 |
(_control_update = control.update) === null || _control_update === void 0 ? void 0 : _control_update.call(control, tc.jodit, this); |
| 8596 |
} |
| 8597 |
/** |
| 8598 |
* Calculates whether the button is active |
| 8599 |
*/ __calculateActivatedStatus(tc) { |
| 8600 |
var _this_control_isActive, _this_control; |
| 8601 |
if ((0,jodit_core_helpers_checker_is_jodit_object__WEBPACK_IMPORTED_MODULE_12__.isJoditObject)(this.j) && !this.j.editorIsActive) { |
| 8602 |
return false; |
| 8603 |
} |
| 8604 |
if ((_this_control_isActive = (_this_control = this.control).isActive) === null || _this_control_isActive === void 0 ? void 0 : _this_control_isActive.call(_this_control, this.j, this)) { |
| 8605 |
return true; |
| 8606 |
} |
| 8607 |
return Boolean(tc && tc.shouldBeActive(this)); |
| 8608 |
} |
| 8609 |
/** |
| 8610 |
* Calculates whether an element is blocked for the user |
| 8611 |
*/ __calculateDisabledStatus(tc) { |
| 8612 |
var _this_control_isDisabled, _this_control; |
| 8613 |
if (this.j.o.disabled) { |
| 8614 |
return true; |
| 8615 |
} |
| 8616 |
if (this.j.o.readonly && (!this.j.o.activeButtonsInReadOnly || !this.j.o.activeButtonsInReadOnly.includes(this.control.name))) { |
| 8617 |
return true; |
| 8618 |
} |
| 8619 |
if ((_this_control_isDisabled = (_this_control = this.control).isDisabled) === null || _this_control_isDisabled === void 0 ? void 0 : _this_control_isDisabled.call(_this_control, this.j, this)) { |
| 8620 |
return true; |
| 8621 |
} |
| 8622 |
return Boolean(tc && tc.shouldBeDisabled(this)); |
| 8623 |
} |
| 8624 |
onChangeActivated() { |
| 8625 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_18__.attr)(this.button, 'aria-pressed', this.state.activated); |
| 8626 |
super.onChangeActivated(); |
| 8627 |
} |
| 8628 |
onChangeText() { |
| 8629 |
if ((0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_11__.isFunction)(this.control.template)) { |
| 8630 |
this.text.innerHTML = this.control.template(this.j, this.control.name, this.j.i18n(this.state.text)); |
| 8631 |
} else { |
| 8632 |
super.onChangeText(); |
| 8633 |
} |
| 8634 |
this.setMod('text-icons', Boolean(this.text.innerText.trim().length)); |
| 8635 |
} |
| 8636 |
onChangeTabIndex() { |
| 8637 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_18__.attr)(this.button, 'tabindex', this.state.tabIndex); |
| 8638 |
} |
| 8639 |
createContainer() { |
| 8640 |
const cn = this.componentName; |
| 8641 |
const container = this.j.c.span(cn); |
| 8642 |
const button = super.createContainer(); |
| 8643 |
button.classList.remove(cn); |
| 8644 |
button.classList.add(cn + '__button'); |
| 8645 |
Object.defineProperty(button, 'component', { |
| 8646 |
value: this |
| 8647 |
}); |
| 8648 |
container.appendChild(button); |
| 8649 |
const trigger = this.j.c.fromHTML(`<span role="button" aria-haspopup="true" aria-expanded="false" class="${cn}__trigger">${jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_22__.Icon.get('chevron')}</span>`); |
| 8650 |
// For caching |
| 8651 |
button.appendChild(trigger); |
| 8652 |
return container; |
| 8653 |
} |
| 8654 |
/** @override */ focus() { |
| 8655 |
var _this_container_querySelector; |
| 8656 |
(_this_container_querySelector = this.container.querySelector('button')) === null || _this_container_querySelector === void 0 ? void 0 : _this_container_querySelector.focus(); |
| 8657 |
} |
| 8658 |
onChangeHasTrigger() { |
| 8659 |
if (this.state.hasTrigger) { |
| 8660 |
this.container.appendChild(this.trigger); |
| 8661 |
} else { |
| 8662 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_9__.Dom.safeRemove(this.trigger); |
| 8663 |
} |
| 8664 |
this.setMod('with-trigger', this.state.hasTrigger || null); |
| 8665 |
} |
| 8666 |
/** @override */ onChangeDisabled() { |
| 8667 |
const disabled = this.state.disabled ? 'disabled' : null; |
| 8668 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_18__.attr)(this.trigger, 'disabled', disabled); |
| 8669 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_18__.attr)(this.button, 'disabled', disabled); |
| 8670 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_18__.attr)(this.container, 'disabled', disabled); |
| 8671 |
} |
| 8672 |
/** |
| 8673 |
* Init constant data from control |
| 8674 |
*/ __initFromControl() { |
| 8675 |
const { control: ctr, state } = this; |
| 8676 |
this.updateSize(); |
| 8677 |
state.name = ctr.name; |
| 8678 |
const { textIcons } = this.j.o; |
| 8679 |
if (textIcons === true || (0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_11__.isFunction)(textIcons) && textIcons(ctr.name) || ctr.template) { |
| 8680 |
state.icon = (0,jodit_core_ui_button__WEBPACK_IMPORTED_MODULE_20__.UIButtonState)().icon; |
| 8681 |
state.text = ctr.text || ctr.name; |
| 8682 |
} else { |
| 8683 |
if (ctr.iconURL) { |
| 8684 |
state.icon.iconURL = ctr.iconURL; |
| 8685 |
} else { |
| 8686 |
var _this_j_o_extraIcons; |
| 8687 |
const name = ctr.icon || ctr.name; |
| 8688 |
state.icon.name = jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_22__.Icon.exists(name) || ((_this_j_o_extraIcons = this.j.o.extraIcons) === null || _this_j_o_extraIcons === void 0 ? void 0 : _this_j_o_extraIcons[name]) ? name : ''; |
| 8689 |
} |
| 8690 |
if (!ctr.iconURL && !state.icon.name) { |
| 8691 |
state.text = ctr.text || ctr.name; |
| 8692 |
} |
| 8693 |
} |
| 8694 |
if (ctr.tooltip) { |
| 8695 |
state.tooltip = (0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_11__.isFunction)(ctr.tooltip) ? ctr.tooltip(this.j, ctr, this) : ctr.tooltip; |
| 8696 |
} |
| 8697 |
state.hasTrigger = Boolean(ctr.list || ctr.popup && ctr.exec); |
| 8698 |
} |
| 8699 |
/** |
| 8700 |
* Click on trigger button |
| 8701 |
*/ onTriggerClick(e) { |
| 8702 |
if (this.openedPopup) { |
| 8703 |
this.__closePopup(); |
| 8704 |
return; |
| 8705 |
} |
| 8706 |
const { control: ctr } = this; |
| 8707 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_18__.attr)(this.trigger, 'aria-expanded', true); |
| 8708 |
e.buffer = { |
| 8709 |
actionTrigger: this |
| 8710 |
}; |
| 8711 |
if (ctr.list) { |
| 8712 |
return this.__openControlList(ctr); |
| 8713 |
} |
| 8714 |
if ((0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_11__.isFunction)(ctr.popup)) { |
| 8715 |
const popup = this.openPopup(); |
| 8716 |
popup.parentElement = this; |
| 8717 |
try { |
| 8718 |
if (this.j.e.fire((0,jodit_core_helpers_string_camel_case__WEBPACK_IMPORTED_MODULE_16__.camelCase)(`before-${ctr.name}-open-popup`), this.target, ctr, popup) !== false) { |
| 8719 |
var _ref, _ref1; |
| 8720 |
var _this_toolbar; |
| 8721 |
const target = (_ref = (_ref1 = (_this_toolbar = this.toolbar) === null || _this_toolbar === void 0 ? void 0 : _this_toolbar.getTarget(this)) !== null && _ref1 !== void 0 ? _ref1 : this.target) !== null && _ref !== void 0 ? _ref : null; |
| 8722 |
const elm = ctr.popup(this.j, target, this.__closePopup, this); |
| 8723 |
if (elm) { |
| 8724 |
popup.setContent((0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_14__.isString)(elm) ? this.j.c.fromHTML(elm) : elm).open(()=>(0,jodit_core_helpers_size__WEBPACK_IMPORTED_MODULE_15__.position)(this.container), false, this.j.o.allowTabNavigation ? this.container : undefined); |
| 8725 |
} else { |
| 8726 |
this.__closePopup(); |
| 8727 |
} |
| 8728 |
} |
| 8729 |
} catch (e) { |
| 8730 |
this.__closePopup(); |
| 8731 |
throw e; |
| 8732 |
} |
| 8733 |
/** |
| 8734 |
* Fired after the popup was opened for some control button |
| 8735 |
*/ /** |
| 8736 |
* Close all opened popups |
| 8737 |
*/ this.j.e.fire((0,jodit_core_helpers_string_camel_case__WEBPACK_IMPORTED_MODULE_16__.camelCase)(`after-${ctr.name}-open-popup`), popup.container); |
| 8738 |
} |
| 8739 |
} |
| 8740 |
/** |
| 8741 |
* Create an open popup list |
| 8742 |
*/ __openControlList(control) { |
| 8743 |
var _this_jodit_options_controls; |
| 8744 |
const controls = (_this_jodit_options_controls = this.jodit.options.controls) !== null && _this_jodit_options_controls !== void 0 ? _this_jodit_options_controls : {}, getControl = (key)=>(0,jodit_core_ui_helpers_get_control_type__WEBPACK_IMPORTED_MODULE_21__.findControlType)(key, controls); |
| 8745 |
const list = control.list; |
| 8746 |
const menu = this.openPopup(); |
| 8747 |
const toolbar = (0,_factory__WEBPACK_IMPORTED_MODULE_24__.makeCollection)(this.j); |
| 8748 |
menu.parentElement = this; |
| 8749 |
toolbar.parentElement = menu; |
| 8750 |
toolbar.mode = 'vertical'; |
| 8751 |
const isListItem = (key)=>(0,jodit_core_helpers_checker_is_plain_object__WEBPACK_IMPORTED_MODULE_13__.isPlainObject)(key) && 'title' in key && 'value' in key; |
| 8752 |
const getButton = (key, value)=>{ |
| 8753 |
if ((0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_14__.isString)(value) && getControl(value)) { |
| 8754 |
return (0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_1__._)({ |
| 8755 |
name: value.toString() |
| 8756 |
}, getControl(value)); |
| 8757 |
} |
| 8758 |
if ((0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_14__.isString)(key) && getControl(key)) { |
| 8759 |
return (0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_1__._)({ |
| 8760 |
name: key.toString() |
| 8761 |
}, getControl(key), typeof value === 'object' ? value : {}); |
| 8762 |
} |
| 8763 |
if (isListItem(key)) { |
| 8764 |
value = key.value; |
| 8765 |
key = key.title; |
| 8766 |
} |
| 8767 |
const { childTemplate } = control; |
| 8768 |
const childControl = { |
| 8769 |
name: key.toString(), |
| 8770 |
template: childTemplate && ((j, k, v)=>childTemplate(j, k, v, this)), |
| 8771 |
exec: control.childExec ? (view, current, options)=>{ |
| 8772 |
var _control_childExec; |
| 8773 |
return (_control_childExec = control.childExec) === null || _control_childExec === void 0 ? void 0 : _control_childExec.call(control, view, current, (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_2__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_1__._)({}, options), { |
| 8774 |
parentControl: control |
| 8775 |
})); |
| 8776 |
} : control.exec, |
| 8777 |
data: control.data, |
| 8778 |
command: control.command, |
| 8779 |
isActive: control.isChildActive, |
| 8780 |
value: control.value, |
| 8781 |
isDisabled: control.isChildDisabled, |
| 8782 |
mode: control.mode, |
| 8783 |
args: [ |
| 8784 |
...control.args ? control.args : [], |
| 8785 |
key, |
| 8786 |
value |
| 8787 |
] |
| 8788 |
}; |
| 8789 |
if ((0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_14__.isString)(value)) { |
| 8790 |
childControl.text = value; |
| 8791 |
} |
| 8792 |
return childControl; |
| 8793 |
}; |
| 8794 |
toolbar.build((0,jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_10__.isArray)(list) ? list.map(getButton) : (0,jodit_core_helpers_utils_utils__WEBPACK_IMPORTED_MODULE_19__.keys)(list, false).map((key)=>getButton(key, list[key])), this.target); |
| 8795 |
menu.setContent(toolbar).open(()=>(0,jodit_core_helpers_size__WEBPACK_IMPORTED_MODULE_15__.position)(this.container), false, this.j.o.allowTabNavigation ? this.container : undefined); |
| 8796 |
this.state.activated = true; |
| 8797 |
} |
| 8798 |
onOutsideClick(e) { |
| 8799 |
if (!this.openedPopup) { |
| 8800 |
return; |
| 8801 |
} |
| 8802 |
if (!e || !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_9__.Dom.isNode(e.target) || !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_9__.Dom.isOrContains(this.container, e.target) && !this.openedPopup.isOwnClick(e)) { |
| 8803 |
this.__closePopup(); |
| 8804 |
} |
| 8805 |
} |
| 8806 |
openPopup() { |
| 8807 |
this.__closePopup(); |
| 8808 |
this.openedPopup = new jodit_core_ui_popup_popup__WEBPACK_IMPORTED_MODULE_23__.Popup(this.j, false); |
| 8809 |
this.j.e.on(this.ow, 'mousedown touchstart', this.onOutsideClick).on('escape closeAllPopups', this.onOutsideClick); |
| 8810 |
return this.openedPopup; |
| 8811 |
} |
| 8812 |
__closePopup() { |
| 8813 |
if (this.openedPopup) { |
| 8814 |
this.j.e.off(this.ow, 'mousedown touchstart', this.onOutsideClick).off('escape closeAllPopups', this.onOutsideClick); |
| 8815 |
this.state.activated = false; |
| 8816 |
this.openedPopup.close(); |
| 8817 |
this.openedPopup.destruct(); |
| 8818 |
this.openedPopup = null; |
| 8819 |
if (this.trigger) { |
| 8820 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_18__.attr)(this.trigger, 'aria-expanded', false); |
| 8821 |
} |
| 8822 |
} |
| 8823 |
} |
| 8824 |
/** |
| 8825 |
* Click handler |
| 8826 |
*/ onClick(originalEvent) { |
| 8827 |
const { control: ctr } = this; |
| 8828 |
if ((0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_11__.isFunction)(ctr.exec)) { |
| 8829 |
var _ref, _ref1; |
| 8830 |
var _this_toolbar; |
| 8831 |
const target = (_ref = (_ref1 = (_this_toolbar = this.toolbar) === null || _this_toolbar === void 0 ? void 0 : _this_toolbar.getTarget(this)) !== null && _ref1 !== void 0 ? _ref1 : this.target) !== null && _ref !== void 0 ? _ref : null; |
| 8832 |
const result = ctr.exec(this.j, target, { |
| 8833 |
control: ctr, |
| 8834 |
originalEvent, |
| 8835 |
button: this |
| 8836 |
}); |
| 8837 |
// For memorise exec |
| 8838 |
if (result !== false && result !== true) { |
| 8839 |
var _this_j_e, _this_j, /** |
| 8840 |
* Fired after calling `button.exec` function |
| 8841 |
*/ _this_j_e1, _this_j1; |
| 8842 |
(_this_j = this.j) === null || _this_j === void 0 ? void 0 : (_this_j_e = _this_j.e) === null || _this_j_e === void 0 ? void 0 : _this_j_e.fire('synchro'); |
| 8843 |
if (this.parentElement) { |
| 8844 |
this.parentElement.update(); |
| 8845 |
} |
| 8846 |
(_this_j1 = this.j) === null || _this_j1 === void 0 ? void 0 : (_this_j_e1 = _this_j1.e) === null || _this_j_e1 === void 0 ? void 0 : _this_j_e1.fire('closeAllPopups afterExec'); |
| 8847 |
} |
| 8848 |
if (result !== false) { |
| 8849 |
return; |
| 8850 |
} |
| 8851 |
} |
| 8852 |
if (ctr.list) { |
| 8853 |
return this.__openControlList(ctr); |
| 8854 |
} |
| 8855 |
if ((0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_11__.isFunction)(ctr.popup)) { |
| 8856 |
return this.onTriggerClick(originalEvent); |
| 8857 |
} |
| 8858 |
if (ctr.command || ctr.name) { |
| 8859 |
(0,jodit_core_helpers_utils_utils__WEBPACK_IMPORTED_MODULE_19__.call)((0,jodit_core_helpers_checker_is_jodit_object__WEBPACK_IMPORTED_MODULE_12__.isJoditObject)(this.j) ? this.j.execCommand.bind(this.j) : this.j.od.execCommand.bind(this.j.od), ctr.command || ctr.name, false, ctr.args && ctr.args[0]); |
| 8860 |
this.j.e.fire('closeAllPopups'); |
| 8861 |
} |
| 8862 |
} |
| 8863 |
destruct() { |
| 8864 |
this.__closePopup(); |
| 8865 |
return super.destruct(); |
| 8866 |
} |
| 8867 |
constructor(jodit, control, target = null){ |
| 8868 |
super(jodit), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "control", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "target", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "state", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "trigger", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "openedPopup", void 0), this.control = control, this.target = target, this.state = (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_2__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_1__._)({}, (0,jodit_core_ui_button__WEBPACK_IMPORTED_MODULE_20__.UIButtonState)()), { |
| 8869 |
theme: 'toolbar', |
| 8870 |
currentValue: '', |
| 8871 |
hasTrigger: false |
| 8872 |
}), this.openedPopup = null; |
| 8873 |
const button = this.getElm('button'); |
| 8874 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_17__.assert)(button, 'Element button should exists'); |
| 8875 |
this.button = button; |
| 8876 |
Object.defineProperty(button, 'component', { |
| 8877 |
value: this, |
| 8878 |
configurable: true |
| 8879 |
}); |
| 8880 |
const trigger = this.getElm('trigger'); |
| 8881 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_17__.assert)(trigger, 'Element trigger should exists'); |
| 8882 |
this.trigger = trigger; |
| 8883 |
trigger.remove(); |
| 8884 |
// Prevent lost focus |
| 8885 |
jodit.e.on([ |
| 8886 |
this.button, |
| 8887 |
this.trigger |
| 8888 |
], 'mousedown', (e)=>e.preventDefault()); |
| 8889 |
this.onAction(this.onClick); |
| 8890 |
this.hookStatus(jodit_core_component_statuses__WEBPACK_IMPORTED_MODULE_4__.STATUSES.ready, ()=>{ |
| 8891 |
this.__initFromControl(); |
| 8892 |
this.update(); |
| 8893 |
}); |
| 8894 |
if (control.mods) { |
| 8895 |
Object.keys(control.mods).forEach((mod)=>{ |
| 8896 |
control.mods && this.setMod(mod, control.mods[mod]); |
| 8897 |
}); |
| 8898 |
} |
| 8899 |
} |
| 8900 |
} |
| 8901 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__.__decorate)([ |
| 8902 |
jodit_core_decorators_cache_cache__WEBPACK_IMPORTED_MODULE_6__.cacheHTML |
| 8903 |
], ToolbarButton.prototype, "createContainer", null); |
| 8904 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__.__decorate)([ |
| 8905 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_8__.watch)('state.hasTrigger', { |
| 8906 |
immediately: false |
| 8907 |
}) |
| 8908 |
], ToolbarButton.prototype, "onChangeHasTrigger", null); |
| 8909 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__.__decorate)([ |
| 8910 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_8__.watch)('trigger:click') |
| 8911 |
], ToolbarButton.prototype, "onTriggerClick", null); |
| 8912 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__.__decorate)([ |
| 8913 |
jodit_core_decorators_autobind_autobind__WEBPACK_IMPORTED_MODULE_5__.autobind |
| 8914 |
], ToolbarButton.prototype, "onOutsideClick", null); |
| 8915 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__.__decorate)([ |
| 8916 |
jodit_core_decorators_autobind_autobind__WEBPACK_IMPORTED_MODULE_5__.autobind |
| 8917 |
], ToolbarButton.prototype, "__closePopup", null); |
| 8918 |
ToolbarButton = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__.__decorate)([ |
| 8919 |
jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_7__.component |
| 8920 |
], ToolbarButton); |
| 8921 |
|
| 8922 |
|
| 8923 |
/***/ }), |
| 8924 |
|
| 8925 |
/***/ 22852: |
| 8926 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 8927 |
|
| 8928 |
"use strict"; |
| 8929 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 8930 |
/* harmony export */ stripTags: function() { return /* binding */ stripTags; } |
| 8931 |
/* harmony export */ }); |
| 8932 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 8933 |
/* harmony import */ var jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(85932); |
| 8934 |
/* harmony import */ var jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(4040); |
| 8935 |
/* harmony import */ var jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(93640); |
| 8936 |
/*! |
| 8937 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 8938 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 8939 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 8940 |
*/ /** |
| 8941 |
* @module helpers/html |
| 8942 |
*/ |
| 8943 |
|
| 8944 |
|
| 8945 |
|
| 8946 |
const NEW_LINE_TAGS = new Set([ |
| 8947 |
'div', |
| 8948 |
'p', |
| 8949 |
'br', |
| 8950 |
'h1', |
| 8951 |
'h2', |
| 8952 |
'h3', |
| 8953 |
'h4', |
| 8954 |
'h5', |
| 8955 |
'h6', |
| 8956 |
'hr' |
| 8957 |
]); |
| 8958 |
const INVISIBLE_TAGS = new Set([ |
| 8959 |
'script', |
| 8960 |
'style' |
| 8961 |
]); |
| 8962 |
const ALONE_TAGS = new Set([ |
| 8963 |
'br', |
| 8964 |
'hr', |
| 8965 |
'input' |
| 8966 |
]); |
| 8967 |
/** |
| 8968 |
* Extract plain text from HTML text |
| 8969 |
*/ function stripTags(html, doc = document, exclude = null) { |
| 8970 |
const tmp = doc.createElement('div'); |
| 8971 |
if ((0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_1__.isString)(html)) { |
| 8972 |
tmp.innerHTML = html; |
| 8973 |
} else { |
| 8974 |
tmp.appendChild(html); |
| 8975 |
} |
| 8976 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_3__.$$)('*', tmp).forEach((p)=>{ |
| 8977 |
const pr = p.parentNode; |
| 8978 |
if (!pr) { |
| 8979 |
return; |
| 8980 |
} |
| 8981 |
if (exclude && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(p, exclude)) { |
| 8982 |
const tag = p.nodeName.toLowerCase(); |
| 8983 |
const text = !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(p, ALONE_TAGS) ? `%%%jodit-${tag}%%%${stripTags(p.innerHTML, doc, exclude)}%%%/jodit-${tag}%%%` : `%%%jodit-single-${tag}%%%`; |
| 8984 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.before(p, doc.createTextNode(text)); |
| 8985 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(p); |
| 8986 |
return; |
| 8987 |
} |
| 8988 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(p, INVISIBLE_TAGS)) { |
| 8989 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(p); |
| 8990 |
return; |
| 8991 |
} |
| 8992 |
if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(p, NEW_LINE_TAGS)) { |
| 8993 |
return; |
| 8994 |
} |
| 8995 |
const nx = p.nextSibling; |
| 8996 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isText(nx) && /^\s/.test(nx.nodeValue || '')) { |
| 8997 |
return; |
| 8998 |
} |
| 8999 |
if (nx) { |
| 9000 |
pr.insertBefore(doc.createTextNode(' '), nx); |
| 9001 |
} |
| 9002 |
}); |
| 9003 |
return restoreTags((0,jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_2__.trim)(tmp.innerText)); |
| 9004 |
} |
| 9005 |
function restoreTags(content) { |
| 9006 |
return content.replace(/%%%(\/)?jodit(-single)?-([\w\n]+)%%%/g, (_, isClosed, isSingle, tag)=>`<${isClosed ? '/' : ''}${tag}>`); |
| 9007 |
} |
| 9008 |
|
| 9009 |
|
| 9010 |
/***/ }), |
| 9011 |
|
| 9012 |
/***/ 22998: |
| 9013 |
/***/ (function(module) { |
| 9014 |
|
| 9015 |
/*! |
| 9016 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 9017 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 9018 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 9019 |
*/ module.exports = { |
| 9020 |
'copy-format': 'Formátum másolás' |
| 9021 |
}; |
| 9022 |
|
| 9023 |
|
| 9024 |
/***/ }), |
| 9025 |
|
| 9026 |
/***/ 23112: |
| 9027 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 9028 |
|
| 9029 |
"use strict"; |
| 9030 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 9031 |
/* harmony export */ dataURItoBlob: function() { return /* binding */ dataURItoBlob; } |
| 9032 |
/* harmony export */ }); |
| 9033 |
/*! |
| 9034 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 9035 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 9036 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 9037 |
*/ /** |
| 9038 |
* @module modules/uploader |
| 9039 |
*/ /** |
| 9040 |
* Convert dataURI to Blob |
| 9041 |
*/ function dataURItoBlob(dataURI) { |
| 9042 |
// convert base64 to raw binary data held in a string |
| 9043 |
// doesn't handle URLEncoded DataURIs - see SO answer #6850276 for code that does this |
| 9044 |
const byteString = atob(dataURI.split(',')[1]), // separate out the mime component |
| 9045 |
mimeString = dataURI.split(',')[0].split(':')[1].split(';')[0], // write the bytes of the string to an ArrayBuffer |
| 9046 |
ab = new ArrayBuffer(byteString.length), ia = new Uint8Array(ab); |
| 9047 |
for(let i = 0; i < byteString.length; i += 1){ |
| 9048 |
ia[i] = byteString.charCodeAt(i); |
| 9049 |
} |
| 9050 |
return new Blob([ |
| 9051 |
ia.buffer |
| 9052 |
], { |
| 9053 |
type: mimeString |
| 9054 |
}); |
| 9055 |
} |
| 9056 |
|
| 9057 |
|
| 9058 |
/***/ }), |
| 9059 |
|
| 9060 |
/***/ 23175: |
| 9061 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 9062 |
|
| 9063 |
"use strict"; |
| 9064 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 9065 |
/* harmony export */ isMarker: function() { return /* binding */ isMarker; } |
| 9066 |
/* harmony export */ }); |
| 9067 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 9068 |
/*! |
| 9069 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 9070 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 9071 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 9072 |
*/ /** |
| 9073 |
* @module helpers/checker |
| 9074 |
*/ |
| 9075 |
/** |
| 9076 |
* Define element is selection helper |
| 9077 |
* @deprecated use Dom.isMarker instead |
| 9078 |
*/ function isMarker(elm) { |
| 9079 |
return jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isMarker(elm); |
| 9080 |
} |
| 9081 |
|
| 9082 |
|
| 9083 |
/***/ }), |
| 9084 |
|
| 9085 |
/***/ 23183: |
| 9086 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 9087 |
|
| 9088 |
"use strict"; |
| 9089 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 9090 |
/* harmony export */ Elms: function() { return /* binding */ Elms; } |
| 9091 |
/* harmony export */ }); |
| 9092 |
/* harmony import */ var jodit_core_helpers_array_to_array__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(88475); |
| 9093 |
/*! |
| 9094 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 9095 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 9096 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 9097 |
*/ /** |
| 9098 |
* @module traits |
| 9099 |
*/ |
| 9100 |
class Elms { |
| 9101 |
/** |
| 9102 |
* Return element with BEM class name |
| 9103 |
*/ getElm(elementName) { |
| 9104 |
return this.container.querySelector(`.${this.getFullElName(elementName)}`); |
| 9105 |
} |
| 9106 |
/** |
| 9107 |
* Return elements with BEM class name |
| 9108 |
*/ getElms(elementName) { |
| 9109 |
return (0,jodit_core_helpers_array_to_array__WEBPACK_IMPORTED_MODULE_0__.toArray)(this.container.querySelectorAll(`.${this.getFullElName(elementName)}`)); |
| 9110 |
} |
| 9111 |
} |
| 9112 |
|
| 9113 |
|
| 9114 |
/***/ }), |
| 9115 |
|
| 9116 |
/***/ 23211: |
| 9117 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 9118 |
|
| 9119 |
"use strict"; |
| 9120 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 9121 |
/* harmony export */ Dom: function() { return /* binding */ Dom; } |
| 9122 |
/* harmony export */ }); |
| 9123 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 9124 |
/* harmony import */ var jodit_core_helpers_array_to_array__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(88475); |
| 9125 |
/* harmony import */ var jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(17312); |
| 9126 |
/* harmony import */ var jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(91565); |
| 9127 |
/* harmony import */ var jodit_core_helpers_checker_is_html__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(46248); |
| 9128 |
/* harmony import */ var jodit_core_helpers_checker_is_set__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(3213); |
| 9129 |
/* harmony import */ var jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(85932); |
| 9130 |
/* harmony import */ var jodit_core_helpers_checker_is_void__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(18303); |
| 9131 |
/* harmony import */ var jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(4040); |
| 9132 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(28712); |
| 9133 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_9__); |
| 9134 |
/* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(7909); |
| 9135 |
/* harmony import */ var jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(80991); |
| 9136 |
/* harmony import */ var jodit_core_helpers_utils_data_bind__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(36400); |
| 9137 |
/* harmony import */ var jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(33201); |
| 9138 |
/* harmony import */ var jodit_core_helpers_utils_utils__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(71125); |
| 9139 |
/*! |
| 9140 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 9141 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 9142 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 9143 |
*/ /** |
| 9144 |
* [[include:core/dom/README.md]] |
| 9145 |
* @packageDocumentation |
| 9146 |
* @module dom |
| 9147 |
*/ |
| 9148 |
|
| 9149 |
|
| 9150 |
|
| 9151 |
|
| 9152 |
|
| 9153 |
|
| 9154 |
|
| 9155 |
|
| 9156 |
|
| 9157 |
|
| 9158 |
|
| 9159 |
|
| 9160 |
|
| 9161 |
|
| 9162 |
|
| 9163 |
/** |
| 9164 |
* Module for working with DOM |
| 9165 |
*/ class Dom { |
| 9166 |
/** |
| 9167 |
* Remove all content from element |
| 9168 |
*/ static detach(node) { |
| 9169 |
while(node && node.firstChild){ |
| 9170 |
node.removeChild(node.firstChild); |
| 9171 |
} |
| 9172 |
} |
| 9173 |
/** |
| 9174 |
* Wrap all inline next siblings |
| 9175 |
*/ static wrapNextInline(current, tag, editor) { |
| 9176 |
let tmp; |
| 9177 |
const first = current; |
| 9178 |
let last = current; |
| 9179 |
editor.s.save(); |
| 9180 |
let needFindNext = false; |
| 9181 |
do { |
| 9182 |
needFindNext = false; |
| 9183 |
tmp = last.nextSibling; |
| 9184 |
if (tmp && !Dom.isBlock(tmp) && !Dom.isTag(tmp, 'br')) { |
| 9185 |
needFindNext = true; |
| 9186 |
last = tmp; |
| 9187 |
} |
| 9188 |
}while (needFindNext) |
| 9189 |
return Dom.__wrapElements(tag, editor, first, last); |
| 9190 |
} |
| 9191 |
static __wrapElements(tag, editor, first, last) { |
| 9192 |
const wrapper = (0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_6__.isString)(tag) ? editor.createInside.element(tag) : tag; |
| 9193 |
if (first.parentNode) { |
| 9194 |
first.parentNode.insertBefore(wrapper, first); |
| 9195 |
} |
| 9196 |
let next = first; |
| 9197 |
while(next){ |
| 9198 |
next = first.nextSibling; |
| 9199 |
wrapper.appendChild(first); |
| 9200 |
if (first === last || !next) { |
| 9201 |
break; |
| 9202 |
} |
| 9203 |
first = next; |
| 9204 |
} |
| 9205 |
editor.s.restore(); |
| 9206 |
return wrapper; |
| 9207 |
} |
| 9208 |
/** |
| 9209 |
* Wrap all inline siblings |
| 9210 |
*/ static wrapInline(current, tag, editor) { |
| 9211 |
let tmp; |
| 9212 |
let first = current; |
| 9213 |
let last = current; |
| 9214 |
editor.s.save(); |
| 9215 |
let needFindNext = false; |
| 9216 |
do { |
| 9217 |
needFindNext = false; |
| 9218 |
tmp = first.previousSibling; |
| 9219 |
if (tmp && !Dom.isBlock(tmp)) { |
| 9220 |
needFindNext = true; |
| 9221 |
first = tmp; |
| 9222 |
} |
| 9223 |
}while (needFindNext) |
| 9224 |
do { |
| 9225 |
needFindNext = false; |
| 9226 |
tmp = last.nextSibling; |
| 9227 |
if (tmp && !Dom.isBlock(tmp)) { |
| 9228 |
needFindNext = true; |
| 9229 |
last = tmp; |
| 9230 |
} |
| 9231 |
}while (needFindNext) |
| 9232 |
return Dom.__wrapElements(tag, editor, first, last); |
| 9233 |
} |
| 9234 |
/** |
| 9235 |
* Wrap node inside another node |
| 9236 |
*/ static wrap(current, tag, create) { |
| 9237 |
const wrapper = (0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_6__.isString)(tag) ? create.element(tag) : tag; |
| 9238 |
if (Dom.isNode(current)) { |
| 9239 |
if (!current.parentNode) { |
| 9240 |
throw (0,jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_13__.error)('Element should be in DOM'); |
| 9241 |
} |
| 9242 |
current.parentNode.insertBefore(wrapper, current); |
| 9243 |
wrapper.appendChild(current); |
| 9244 |
} else { |
| 9245 |
const fragment = current.extractContents(); |
| 9246 |
current.insertNode(wrapper); |
| 9247 |
wrapper.appendChild(fragment); |
| 9248 |
} |
| 9249 |
return wrapper; |
| 9250 |
} |
| 9251 |
/** |
| 9252 |
* Remove parent of node and insert this node instead that parent |
| 9253 |
*/ static unwrap(node) { |
| 9254 |
const parent = node.parentNode; |
| 9255 |
if (parent) { |
| 9256 |
while(node.firstChild){ |
| 9257 |
parent.insertBefore(node.firstChild, node); |
| 9258 |
} |
| 9259 |
Dom.safeRemove(node); |
| 9260 |
} |
| 9261 |
} |
| 9262 |
/** |
| 9263 |
* Call functions for all nodes between `start` and `end` |
| 9264 |
*/ static between(start, end, callback) { |
| 9265 |
let next = start; |
| 9266 |
while(next && next !== end){ |
| 9267 |
if (start !== next && callback(next)) { |
| 9268 |
break; |
| 9269 |
} |
| 9270 |
let step = next.firstChild || next.nextSibling; |
| 9271 |
if (!step) { |
| 9272 |
while(next && !next.nextSibling){ |
| 9273 |
next = next.parentNode; |
| 9274 |
} |
| 9275 |
step = next === null || next === void 0 ? void 0 : next.nextSibling; |
| 9276 |
} |
| 9277 |
next = step; |
| 9278 |
} |
| 9279 |
} |
| 9280 |
static replace(elm, newTagName, create, withAttributes = false, notMoveContent = false) { |
| 9281 |
if ((0,jodit_core_helpers_checker_is_html__WEBPACK_IMPORTED_MODULE_4__.isHTML)(newTagName)) { |
| 9282 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_9__.assert)(create, 'Need create instance for new tag'); |
| 9283 |
newTagName = create.fromHTML(newTagName); |
| 9284 |
} |
| 9285 |
let tag; |
| 9286 |
if ((0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_6__.isString)(newTagName)) { |
| 9287 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_9__.assert)(create, 'Need create instance for new tag'); |
| 9288 |
tag = create.element(newTagName); |
| 9289 |
} else { |
| 9290 |
tag = newTagName; |
| 9291 |
} |
| 9292 |
if (!notMoveContent) { |
| 9293 |
while(elm.firstChild){ |
| 9294 |
tag.appendChild(elm.firstChild); |
| 9295 |
} |
| 9296 |
} |
| 9297 |
if (withAttributes && Dom.isElement(elm) && Dom.isElement(tag)) { |
| 9298 |
(0,jodit_core_helpers_array_to_array__WEBPACK_IMPORTED_MODULE_1__.toArray)(elm.attributes).forEach((attr)=>{ |
| 9299 |
tag.setAttribute(attr.name, attr.value); |
| 9300 |
}); |
| 9301 |
} |
| 9302 |
if (elm.parentNode) { |
| 9303 |
elm.parentNode.replaceChild(tag, elm); |
| 9304 |
} |
| 9305 |
return tag; |
| 9306 |
} |
| 9307 |
/** |
| 9308 |
* Checks whether the Node text and blank (in this case it may contain invisible auxiliary characters , |
| 9309 |
* it is also empty ) |
| 9310 |
* |
| 9311 |
* @param node - The element of wood to be checked |
| 9312 |
*/ static isEmptyTextNode(node) { |
| 9313 |
return Dom.isText(node) && (!node.nodeValue || node.nodeValue.replace(jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE_REG_EXP(), '').trim().length === 0); |
| 9314 |
} |
| 9315 |
static isEmptyContent(node) { |
| 9316 |
return Dom.each(node, (elm)=>Dom.isEmptyTextNode(elm)); |
| 9317 |
} |
| 9318 |
/** |
| 9319 |
* The node is editable |
| 9320 |
*/ static isContentEditable(node, root) { |
| 9321 |
return Dom.isNode(node) && !Dom.closest(node, (elm)=>Dom.isElement(elm) && elm.getAttribute('contenteditable') === 'false', root); |
| 9322 |
} |
| 9323 |
static isEmpty(node, condNoEmptyElement = jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.NO_EMPTY_TAGS) { |
| 9324 |
if (!node) { |
| 9325 |
return true; |
| 9326 |
} |
| 9327 |
let cond; |
| 9328 |
if (!(0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_3__.isFunction)(condNoEmptyElement)) { |
| 9329 |
cond = (elm)=>condNoEmptyElement.has(elm.nodeName.toLowerCase()); |
| 9330 |
} else { |
| 9331 |
cond = condNoEmptyElement; |
| 9332 |
} |
| 9333 |
const emptyText = (node)=>node.nodeValue == null || (0,jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_8__.trim)(node.nodeValue).length === 0; |
| 9334 |
if (Dom.isText(node)) { |
| 9335 |
return emptyText(node); |
| 9336 |
} |
| 9337 |
return !(Dom.isElement(node) && cond(node)) && Dom.each(node, (elm)=>{ |
| 9338 |
if (Dom.isText(elm) && !emptyText(elm) || Dom.isElement(elm) && cond(elm)) { |
| 9339 |
return false; |
| 9340 |
} |
| 9341 |
}); |
| 9342 |
} |
| 9343 |
/** |
| 9344 |
* Returns true if it is a DOM node |
| 9345 |
*/ static isNode(object) { |
| 9346 |
// Duck-typing |
| 9347 |
return Boolean(object && (0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_6__.isString)(object.nodeName) && typeof object.nodeType === 'number' && object.childNodes && (0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_3__.isFunction)(object.appendChild)); |
| 9348 |
} |
| 9349 |
/** |
| 9350 |
* Check if element is table cell |
| 9351 |
*/ static isCell(elm) { |
| 9352 |
return Dom.isNode(elm) && (elm.nodeName === 'TD' || elm.nodeName === 'TH'); |
| 9353 |
} |
| 9354 |
/** |
| 9355 |
* Check if element is a list element UL or OL |
| 9356 |
*/ static isList(elm) { |
| 9357 |
return Dom.isTag(elm, jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.LIST_TAGS); |
| 9358 |
} |
| 9359 |
/** |
| 9360 |
* Check if element is a part of list element LI |
| 9361 |
*/ static isLeaf(elm) { |
| 9362 |
return Dom.isTag(elm, 'li'); |
| 9363 |
} |
| 9364 |
/** |
| 9365 |
* Check is element is Image element |
| 9366 |
*/ static isImage(elm) { |
| 9367 |
return Dom.isNode(elm) && /^(img|svg|picture|canvas)$/i.test(elm.nodeName); |
| 9368 |
} |
| 9369 |
/** |
| 9370 |
* Check the `node` is a block element |
| 9371 |
* @param node - Object to check |
| 9372 |
*/ static isBlock(node) { |
| 9373 |
return !(0,jodit_core_helpers_checker_is_void__WEBPACK_IMPORTED_MODULE_7__.isVoid)(node) && typeof node === 'object' && Dom.isNode(node) && jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.IS_BLOCK.test(node.nodeName); |
| 9374 |
} |
| 9375 |
/** |
| 9376 |
* Check if element is text node |
| 9377 |
*/ static isText(node) { |
| 9378 |
return Boolean(node && node.nodeType === Node.TEXT_NODE); |
| 9379 |
} |
| 9380 |
/** |
| 9381 |
* Check if element is comment node |
| 9382 |
*/ static isComment(node) { |
| 9383 |
return Boolean(node && node.nodeType === Node.COMMENT_NODE); |
| 9384 |
} |
| 9385 |
/** |
| 9386 |
* Check if element is element node |
| 9387 |
*/ static isElement(node) { |
| 9388 |
var _node_ownerDocument; |
| 9389 |
if (!Dom.isNode(node)) { |
| 9390 |
return false; |
| 9391 |
} |
| 9392 |
const win = (_node_ownerDocument = node.ownerDocument) === null || _node_ownerDocument === void 0 ? void 0 : _node_ownerDocument.defaultView; |
| 9393 |
return Boolean(win && node.nodeType === Node.ELEMENT_NODE); |
| 9394 |
} |
| 9395 |
/** |
| 9396 |
* Check if element is document fragment |
| 9397 |
*/ static isFragment(node) { |
| 9398 |
var _node_ownerDocument; |
| 9399 |
if (!Dom.isNode(node)) { |
| 9400 |
return false; |
| 9401 |
} |
| 9402 |
const win = (_node_ownerDocument = node.ownerDocument) === null || _node_ownerDocument === void 0 ? void 0 : _node_ownerDocument.defaultView; |
| 9403 |
return Boolean(win && node.nodeType === Node.DOCUMENT_FRAGMENT_NODE); |
| 9404 |
} |
| 9405 |
/** |
| 9406 |
* Check if element is HTMLElement node |
| 9407 |
*/ static isHTMLElement(node) { |
| 9408 |
var _node_ownerDocument; |
| 9409 |
if (!Dom.isNode(node)) { |
| 9410 |
return false; |
| 9411 |
} |
| 9412 |
const win = (_node_ownerDocument = node.ownerDocument) === null || _node_ownerDocument === void 0 ? void 0 : _node_ownerDocument.defaultView; |
| 9413 |
return Boolean(win && node instanceof win.HTMLElement); |
| 9414 |
} |
| 9415 |
/** |
| 9416 |
* Check element is inline block |
| 9417 |
*/ static isInlineBlock(node) { |
| 9418 |
return Dom.isElement(node) && !/^(BR|HR)$/i.test(node.tagName) && [ |
| 9419 |
'inline', |
| 9420 |
'inline-block' |
| 9421 |
].indexOf((0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_11__.css)(node, 'display').toString()) !== -1; |
| 9422 |
} |
| 9423 |
/** |
| 9424 |
* It's block and it can be split |
| 9425 |
*/ static canSplitBlock(node) { |
| 9426 |
return !(0,jodit_core_helpers_checker_is_void__WEBPACK_IMPORTED_MODULE_7__.isVoid)(node) && Dom.isHTMLElement(node) && Dom.isBlock(node) && !/^(TD|TH|CAPTION|FORM)$/.test(node.nodeName) && node.style !== undefined && !/^(fixed|absolute)/i.test(node.style.position); |
| 9427 |
} |
| 9428 |
/** |
| 9429 |
* Get last matched node inside root |
| 9430 |
*/ static last(root, condition) { |
| 9431 |
let last = root === null || root === void 0 ? void 0 : root.lastChild; |
| 9432 |
if (!last) { |
| 9433 |
return null; |
| 9434 |
} |
| 9435 |
do { |
| 9436 |
if (condition(last)) { |
| 9437 |
return last; |
| 9438 |
} |
| 9439 |
let next = last.lastChild; |
| 9440 |
if (!next) { |
| 9441 |
next = last.previousSibling; |
| 9442 |
} |
| 9443 |
if (!next && last.parentNode !== root) { |
| 9444 |
do { |
| 9445 |
last = last.parentNode; |
| 9446 |
}while (last && !(last === null || last === void 0 ? void 0 : last.previousSibling) && last.parentNode !== root) |
| 9447 |
next = last === null || last === void 0 ? void 0 : last.previousSibling; |
| 9448 |
} |
| 9449 |
last = next; |
| 9450 |
}while (last) |
| 9451 |
return null; |
| 9452 |
} |
| 9453 |
/** |
| 9454 |
* Find previous node |
| 9455 |
*/ static prev(node, condition, root, withChild = true) { |
| 9456 |
return Dom.find(node, condition, root, false, withChild); |
| 9457 |
} |
| 9458 |
/** |
| 9459 |
* Find next node what `condition(next) === true` |
| 9460 |
*/ static next(node, condition, root, withChild = true) { |
| 9461 |
return Dom.find(node, condition, root, true, withChild); |
| 9462 |
} |
| 9463 |
static prevWithClass(node, className) { |
| 9464 |
return Dom.prev(node, (node)=>{ |
| 9465 |
return Dom.isElement(node) && node.classList.contains(className); |
| 9466 |
}, node.parentNode); |
| 9467 |
} |
| 9468 |
static nextWithClass(node, className) { |
| 9469 |
return Dom.next(node, (elm)=>Dom.isElement(elm) && elm.classList.contains(className), node.parentNode); |
| 9470 |
} |
| 9471 |
/** |
| 9472 |
* Find next/prev node what `condition(next) === true` |
| 9473 |
*/ static find(node, condition, root, leftToRight = true, withChild = true) { |
| 9474 |
const gen = this.nextGen(node, root, leftToRight, withChild); |
| 9475 |
let item = gen.next(); |
| 9476 |
while(!item.done){ |
| 9477 |
if (condition(item.value)) { |
| 9478 |
return item.value; |
| 9479 |
} |
| 9480 |
item = gen.next(); |
| 9481 |
} |
| 9482 |
return null; |
| 9483 |
} |
| 9484 |
/** |
| 9485 |
* Find next/prev node what `condition(next) === true` |
| 9486 |
*/ static *nextGen(start, root, leftToRight = true, withChild = true) { |
| 9487 |
const stack = []; |
| 9488 |
let currentNode = start; |
| 9489 |
do { |
| 9490 |
let next = leftToRight ? currentNode.nextSibling : currentNode.previousSibling; |
| 9491 |
while(next){ |
| 9492 |
stack.unshift(next); |
| 9493 |
next = leftToRight ? next.nextSibling : next.previousSibling; |
| 9494 |
} |
| 9495 |
yield* this.runInStack(start, stack, leftToRight, withChild); |
| 9496 |
currentNode = currentNode.parentNode; |
| 9497 |
}while (currentNode && currentNode !== root) |
| 9498 |
return null; |
| 9499 |
} |
| 9500 |
/** |
| 9501 |
* It goes through all the internal elements of the node, causing a callback function |
| 9502 |
* |
| 9503 |
* @param elm - the element whose children and descendants you want to iterate over |
| 9504 |
* @param callback - It called for each item found |
| 9505 |
* @example |
| 9506 |
* ```javascript |
| 9507 |
* Jodit.modules.Dom.each(editor.s.current(), function (node) { |
| 9508 |
* if (node.nodeType === Node.TEXT_NODE) { |
| 9509 |
* node.nodeValue = node.nodeValue.replace(Jodit.INVISIBLE_SPACE_REG_EX, '') // remove all of the text element codes invisible character |
| 9510 |
* } |
| 9511 |
* }); |
| 9512 |
* ``` |
| 9513 |
*/ static each(elm, callback, leftToRight = true) { |
| 9514 |
const gen = this.eachGen(elm, leftToRight); |
| 9515 |
let item = gen.next(); |
| 9516 |
while(!item.done){ |
| 9517 |
if (callback(item.value) === false) { |
| 9518 |
return false; |
| 9519 |
} |
| 9520 |
item = gen.next(); |
| 9521 |
} |
| 9522 |
return true; |
| 9523 |
} |
| 9524 |
static eachGen(root, leftToRight = true) { |
| 9525 |
return this.runInStack(root, [ |
| 9526 |
root |
| 9527 |
], leftToRight); |
| 9528 |
} |
| 9529 |
static *runInStack(start, stack, leftToRight, withChild = true) { |
| 9530 |
while(stack.length){ |
| 9531 |
const item = stack.pop(); |
| 9532 |
if (withChild) { |
| 9533 |
let child = leftToRight ? item.lastChild : item.firstChild; |
| 9534 |
while(child){ |
| 9535 |
stack.push(child); |
| 9536 |
child = leftToRight ? child.previousSibling : child.nextSibling; |
| 9537 |
} |
| 9538 |
} |
| 9539 |
if (start !== item) { |
| 9540 |
yield item; |
| 9541 |
} |
| 9542 |
} |
| 9543 |
} |
| 9544 |
/** |
| 9545 |
* Find next/prev node what `condition(next) === true` |
| 9546 |
*/ static findWithCurrent(node, condition, root, sibling = 'nextSibling', child = 'firstChild') { |
| 9547 |
let next = node; |
| 9548 |
do { |
| 9549 |
if (condition(next)) { |
| 9550 |
return next || null; |
| 9551 |
} |
| 9552 |
if (child && next && next[child]) { |
| 9553 |
const nextOne = Dom.findWithCurrent(next[child], condition, next, sibling, child); |
| 9554 |
if (nextOne) { |
| 9555 |
return nextOne; |
| 9556 |
} |
| 9557 |
} |
| 9558 |
while(next && !next[sibling] && next !== root){ |
| 9559 |
next = next.parentNode; |
| 9560 |
} |
| 9561 |
if (next && next[sibling] && next !== root) { |
| 9562 |
next = next[sibling]; |
| 9563 |
} |
| 9564 |
}while (next && next !== root) |
| 9565 |
return null; |
| 9566 |
} |
| 9567 |
/** |
| 9568 |
* Get not empty sibling |
| 9569 |
*/ static findSibling(node, left = true, cond = (n)=>!Dom.isEmptyTextNode(n)) { |
| 9570 |
let sibling = Dom.sibling(node, left); |
| 9571 |
while(sibling && !cond(sibling)){ |
| 9572 |
sibling = Dom.sibling(sibling, left); |
| 9573 |
} |
| 9574 |
return sibling && cond(sibling) ? sibling : null; |
| 9575 |
} |
| 9576 |
/** |
| 9577 |
* Returns the nearest non-empty sibling |
| 9578 |
*/ static findNotEmptySibling(node, left) { |
| 9579 |
return Dom.findSibling(node, left, (n)=>{ |
| 9580 |
var _n_nodeValue; |
| 9581 |
return !Dom.isEmptyTextNode(n) && Boolean(!Dom.isText(n) || ((_n_nodeValue = n.nodeValue) === null || _n_nodeValue === void 0 ? void 0 : _n_nodeValue.length) && (0,jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_8__.trim)(n.nodeValue)); |
| 9582 |
}); |
| 9583 |
} |
| 9584 |
/** |
| 9585 |
* Returns the nearest non-empty neighbor |
| 9586 |
*/ static findNotEmptyNeighbor(node, left, root) { |
| 9587 |
return (0,jodit_core_helpers_utils_utils__WEBPACK_IMPORTED_MODULE_14__.call)(left ? Dom.prev : Dom.next, node, (n)=>Boolean(n && (!(Dom.isText(n) || Dom.isComment(n)) || (0,jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_8__.trim)((n === null || n === void 0 ? void 0 : n.nodeValue) || '').length)), root); |
| 9588 |
} |
| 9589 |
static sibling(node, left) { |
| 9590 |
return left ? node.previousSibling : node.nextSibling; |
| 9591 |
} |
| 9592 |
/** |
| 9593 |
* It goes through all the elements in ascending order, and checks to see if they meet the predetermined condition |
| 9594 |
*/ static up(node, condition, root, checkRoot = false) { |
| 9595 |
let start = node; |
| 9596 |
if (!start) { |
| 9597 |
return null; |
| 9598 |
} |
| 9599 |
do { |
| 9600 |
if (condition(start)) { |
| 9601 |
return start; |
| 9602 |
} |
| 9603 |
if (start === root || !start.parentNode) { |
| 9604 |
break; |
| 9605 |
} |
| 9606 |
start = start.parentNode; |
| 9607 |
}while (start && start !== root) |
| 9608 |
if (start === root && checkRoot && condition(start)) { |
| 9609 |
return start; |
| 9610 |
} |
| 9611 |
return null; |
| 9612 |
} |
| 9613 |
static closest(node, tagsOrCondition, root) { |
| 9614 |
let condition; |
| 9615 |
const lc = (s)=>s.toLowerCase(); |
| 9616 |
if ((0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_3__.isFunction)(tagsOrCondition)) { |
| 9617 |
condition = tagsOrCondition; |
| 9618 |
} else if ((0,jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_2__.isArray)(tagsOrCondition) || (0,jodit_core_helpers_checker_is_set__WEBPACK_IMPORTED_MODULE_5__.isSet)(tagsOrCondition)) { |
| 9619 |
const set = (0,jodit_core_helpers_checker_is_set__WEBPACK_IMPORTED_MODULE_5__.isSet)(tagsOrCondition) ? tagsOrCondition : new Set(tagsOrCondition.map(lc)); |
| 9620 |
condition = (tag)=>Boolean(tag && set.has(lc(tag.nodeName))); |
| 9621 |
} else { |
| 9622 |
condition = (tag)=>Boolean(tag && lc(tagsOrCondition) === lc(tag.nodeName)); |
| 9623 |
} |
| 9624 |
return Dom.up(node, condition, root); |
| 9625 |
} |
| 9626 |
/** |
| 9627 |
* Furthest parent node matching condition |
| 9628 |
*/ static furthest(node, condition, root) { |
| 9629 |
let matchedParent = null, current = node === null || node === void 0 ? void 0 : node.parentElement; |
| 9630 |
while(current && current !== root){ |
| 9631 |
if (condition(current)) { |
| 9632 |
matchedParent = current; |
| 9633 |
} |
| 9634 |
current = current === null || current === void 0 ? void 0 : current.parentElement; |
| 9635 |
} |
| 9636 |
return matchedParent; |
| 9637 |
} |
| 9638 |
/** |
| 9639 |
* Append new element in the start of root |
| 9640 |
*/ static appendChildFirst(root, newElement) { |
| 9641 |
const child = root.firstChild; |
| 9642 |
if (child) { |
| 9643 |
if (child !== newElement) { |
| 9644 |
root.insertBefore(newElement, child); |
| 9645 |
} |
| 9646 |
} else { |
| 9647 |
root.appendChild(newElement); |
| 9648 |
} |
| 9649 |
} |
| 9650 |
/** |
| 9651 |
* Insert newElement after element |
| 9652 |
*/ static after(elm, newElement) { |
| 9653 |
const { parentNode } = elm; |
| 9654 |
if (!parentNode) { |
| 9655 |
return; |
| 9656 |
} |
| 9657 |
if (parentNode.lastChild === elm) { |
| 9658 |
parentNode.appendChild(newElement); |
| 9659 |
} else { |
| 9660 |
parentNode.insertBefore(newElement, elm.nextSibling); |
| 9661 |
} |
| 9662 |
} |
| 9663 |
/** |
| 9664 |
* Insert newElement before element |
| 9665 |
*/ static before(elm, newElement) { |
| 9666 |
const { parentNode } = elm; |
| 9667 |
if (!parentNode) { |
| 9668 |
return; |
| 9669 |
} |
| 9670 |
parentNode.insertBefore(newElement, elm); |
| 9671 |
} |
| 9672 |
/** |
| 9673 |
* Insert newElement as first child inside element |
| 9674 |
*/ static prepend(root, newElement) { |
| 9675 |
root.insertBefore(newElement, root.firstChild); |
| 9676 |
} |
| 9677 |
static append(root, newElement) { |
| 9678 |
if ((0,jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_2__.isArray)(newElement)) { |
| 9679 |
newElement.forEach((node)=>{ |
| 9680 |
this.append(root, node); |
| 9681 |
}); |
| 9682 |
} else { |
| 9683 |
root.appendChild(newElement); |
| 9684 |
} |
| 9685 |
} |
| 9686 |
/** |
| 9687 |
* Move all content to another element |
| 9688 |
*/ static moveContent(from, to, inStart = false, filter = ()=>true) { |
| 9689 |
const fragment = (from.ownerDocument || jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.globalDocument).createDocumentFragment(); |
| 9690 |
(0,jodit_core_helpers_array_to_array__WEBPACK_IMPORTED_MODULE_1__.toArray)(from.childNodes).filter((elm)=>{ |
| 9691 |
if (filter(elm)) { |
| 9692 |
return true; |
| 9693 |
} |
| 9694 |
Dom.safeRemove(elm); |
| 9695 |
return false; |
| 9696 |
}).forEach((node)=>{ |
| 9697 |
fragment.appendChild(node); |
| 9698 |
}); |
| 9699 |
if (!inStart || !to.firstChild) { |
| 9700 |
to.appendChild(fragment); |
| 9701 |
} else { |
| 9702 |
to.insertBefore(fragment, to.firstChild); |
| 9703 |
} |
| 9704 |
} |
| 9705 |
/** |
| 9706 |
* Check root contains child or equal child |
| 9707 |
*/ static isOrContains(root, child, onlyContains = false) { |
| 9708 |
if (root === child) { |
| 9709 |
return !onlyContains; |
| 9710 |
} |
| 9711 |
return Boolean(child && root && this.up(child, (nd)=>nd === root, root, true)); |
| 9712 |
} |
| 9713 |
/** |
| 9714 |
* Safe remove element from DOM |
| 9715 |
*/ static safeRemove(...nodes) { |
| 9716 |
nodes.forEach((node)=>Dom.isNode(node) && node.parentNode && node.parentNode.removeChild(node)); |
| 9717 |
} |
| 9718 |
static safeInsertNode(range, node) { |
| 9719 |
range.collapsed || range.deleteContents(); |
| 9720 |
const child = Dom.isFragment(node) ? node.lastChild : node; |
| 9721 |
if (range.startContainer === range.endContainer && range.collapsed && Dom.isTag(range.startContainer, jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INSEPARABLE_TAGS)) { |
| 9722 |
Dom.after(range.startContainer, node); |
| 9723 |
} else { |
| 9724 |
range.insertNode(node); |
| 9725 |
child && range.setStartBefore(child); |
| 9726 |
} |
| 9727 |
range.collapse(true); |
| 9728 |
// https://developer.mozilla.org/en-US/docs/Web/API/Range/insertNode |
| 9729 |
// if the new node is to be added to a text Node, that Node is split at the |
| 9730 |
// insertion point, and the insertion occurs between the two text nodes. |
| 9731 |
[ |
| 9732 |
node.nextSibling, |
| 9733 |
node.previousSibling |
| 9734 |
].forEach((n)=>Dom.isText(n) && !n.nodeValue && Dom.safeRemove(n)); |
| 9735 |
} |
| 9736 |
/** |
| 9737 |
* Hide element |
| 9738 |
*/ static hide(node) { |
| 9739 |
if (!node) { |
| 9740 |
return; |
| 9741 |
} |
| 9742 |
(0,jodit_core_helpers_utils_data_bind__WEBPACK_IMPORTED_MODULE_12__.dataBind)(node, '__old_display', node.style.display); |
| 9743 |
node.style.display = 'none'; |
| 9744 |
} |
| 9745 |
/** |
| 9746 |
* Show element |
| 9747 |
*/ static show(node) { |
| 9748 |
if (!node) { |
| 9749 |
return; |
| 9750 |
} |
| 9751 |
const display = (0,jodit_core_helpers_utils_data_bind__WEBPACK_IMPORTED_MODULE_12__.dataBind)(node, '__old_display'); |
| 9752 |
if (node.style.display === 'none') { |
| 9753 |
node.style.display = display || ''; |
| 9754 |
} |
| 9755 |
} |
| 9756 |
static isTag(node, tagNames) { |
| 9757 |
if (!this.isElement(node)) { |
| 9758 |
return false; |
| 9759 |
} |
| 9760 |
const nameL = node.tagName.toLowerCase(); |
| 9761 |
const nameU = node.tagName.toUpperCase(); |
| 9762 |
if (tagNames instanceof Set) { |
| 9763 |
return tagNames.has(nameL) || tagNames.has(nameU); |
| 9764 |
} |
| 9765 |
if (Array.isArray(tagNames)) { |
| 9766 |
throw new TypeError('Dom.isTag does not support array'); |
| 9767 |
} |
| 9768 |
const tags = tagNames; |
| 9769 |
if (nameL === tags || nameU === tags) { |
| 9770 |
return true; |
| 9771 |
} |
| 9772 |
return false; |
| 9773 |
} |
| 9774 |
/** |
| 9775 |
* Marks an item as temporary |
| 9776 |
*/ static markTemporary(element, attributes) { |
| 9777 |
attributes && (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_10__.attr)(element, attributes); |
| 9778 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_10__.attr)(element, jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.TEMP_ATTR, true); |
| 9779 |
return element; |
| 9780 |
} |
| 9781 |
/** |
| 9782 |
* Check if element is temporary |
| 9783 |
*/ static isTemporary(element) { |
| 9784 |
if (!Dom.isElement(element)) { |
| 9785 |
return false; |
| 9786 |
} |
| 9787 |
return Dom.isMarker(element) || (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_10__.attr)(element, jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.TEMP_ATTR) === 'true'; |
| 9788 |
} |
| 9789 |
/** |
| 9790 |
* Define element is selection helper |
| 9791 |
*/ static isMarker(elm) { |
| 9792 |
return Dom.isNode(elm) && Dom.isTag(elm, 'span') && elm.hasAttribute('data-' + jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.MARKER_CLASS); |
| 9793 |
} |
| 9794 |
/** |
| 9795 |
* Replace temporary elements from string |
| 9796 |
*/ static replaceTemporaryFromString(value) { |
| 9797 |
return value.replace(/<([a-z]+)[^>]+data-jodit-temp[^>]+>(.+?)<\/\1>/gi, '$2'); |
| 9798 |
} |
| 9799 |
/** |
| 9800 |
* Get temporary list |
| 9801 |
* @deprecated Just do not use it, it is not needed anymore |
| 9802 |
*/ static temporaryList(root) { |
| 9803 |
return (0,jodit_core_helpers_array_to_array__WEBPACK_IMPORTED_MODULE_1__.toArray)(root.querySelectorAll(`[${jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.TEMP_ATTR}]`)); |
| 9804 |
} |
| 9805 |
constructor(){ |
| 9806 |
throw new Error('Dom is static module'); |
| 9807 |
} |
| 9808 |
} |
| 9809 |
|
| 9810 |
|
| 9811 |
/***/ }), |
| 9812 |
|
| 9813 |
/***/ 23283: |
| 9814 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 9815 |
|
| 9816 |
"use strict"; |
| 9817 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 9818 |
/* harmony export */ isNativeFunction: function() { return /* binding */ isNativeFunction; } |
| 9819 |
/* harmony export */ }); |
| 9820 |
/*! |
| 9821 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 9822 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 9823 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 9824 |
*/ /** |
| 9825 |
* @module helpers/checker |
| 9826 |
*/ /** |
| 9827 |
* Check if function or method was not replaced on some custom implementation |
| 9828 |
*/ function isNativeFunction(f) { |
| 9829 |
return Boolean(f) && (typeof f).toLowerCase() === 'function' && (f === Function.prototype || /^\s*function\s*(\b[a-z$_][a-z0-9$_]*\b)*\s*\((|([a-z$_][a-z0-9$_]*)(\s*,[a-z$_][a-z0-9$_]*)*)\)\s*{\s*\[native code]\s*}\s*$/i.test(String(f))); |
| 9830 |
} |
| 9831 |
|
| 9832 |
|
| 9833 |
/***/ }), |
| 9834 |
|
| 9835 |
/***/ 23422: |
| 9836 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 9837 |
|
| 9838 |
"use strict"; |
| 9839 |
/* unused harmony export paste */ |
| 9840 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 9841 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 9842 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(81937); |
| 9843 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(84839); |
| 9844 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(23211); |
| 9845 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(28077); |
| 9846 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(65946); |
| 9847 |
/* harmony import */ var jodit_core_plugin_plugin__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(18855); |
| 9848 |
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(38187); |
| 9849 |
/* harmony import */ var _helpers__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(54308); |
| 9850 |
/*! |
| 9851 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 9852 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 9853 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 9854 |
*/ /** |
| 9855 |
* [[include:plugins/paste/README.md]] |
| 9856 |
* @packageDocumentation |
| 9857 |
* @module plugins/paste |
| 9858 |
*/ |
| 9859 |
|
| 9860 |
|
| 9861 |
|
| 9862 |
|
| 9863 |
|
| 9864 |
|
| 9865 |
|
| 9866 |
|
| 9867 |
|
| 9868 |
/** |
| 9869 |
* Ask before paste HTML source |
| 9870 |
*/ class paste extends jodit_core_plugin_plugin__WEBPACK_IMPORTED_MODULE_7__.Plugin { |
| 9871 |
/** @override **/ afterInit(jodit) { |
| 9872 |
jodit.e.on('paste.paste', this.onPaste).on('pasteStack.paste', (item)=>this.pasteStack.push(item)); |
| 9873 |
if (jodit.o.nl2brInPlainText) { |
| 9874 |
this.j.e.on('processPaste.paste', this.onProcessPasteReplaceNl2Br); |
| 9875 |
} |
| 9876 |
} |
| 9877 |
/** @override **/ beforeDestruct(jodit) { |
| 9878 |
jodit.e.off('paste.paste', this.onPaste).off('processPaste.paste', this.onProcessPasteReplaceNl2Br).off('.paste'); |
| 9879 |
} |
| 9880 |
/** |
| 9881 |
* Paste event handler |
| 9882 |
*/ onPaste(e) { |
| 9883 |
try { |
| 9884 |
if (this.customPasteProcess(e) === false || this.j.e.fire('beforePaste', e) === false) { |
| 9885 |
e.preventDefault(); |
| 9886 |
return false; |
| 9887 |
} |
| 9888 |
this.defaultPasteProcess(e); |
| 9889 |
} finally{ |
| 9890 |
this.j.e.fire('afterPaste', e); |
| 9891 |
} |
| 9892 |
} |
| 9893 |
/** |
| 9894 |
* Process before paste |
| 9895 |
*/ customPasteProcess(e) { |
| 9896 |
if (!this.j.o.processPasteHTML) { |
| 9897 |
return; |
| 9898 |
} |
| 9899 |
const dt = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.getDataTransfer)(e), texts = [ |
| 9900 |
dt === null || dt === void 0 ? void 0 : dt.getData(jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.TEXT_PLAIN), |
| 9901 |
dt === null || dt === void 0 ? void 0 : dt.getData(jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.TEXT_HTML), |
| 9902 |
dt === null || dt === void 0 ? void 0 : dt.getData(jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.TEXT_RTF) |
| 9903 |
]; |
| 9904 |
for (const value of texts){ |
| 9905 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.isHTML)(value) && (this.j.e.fire('processHTML', e, value, { |
| 9906 |
plain: texts[0], |
| 9907 |
html: texts[1], |
| 9908 |
rtf: texts[2] |
| 9909 |
}) || this.processHTML(e, value))) { |
| 9910 |
return false; |
| 9911 |
} |
| 9912 |
} |
| 9913 |
} |
| 9914 |
/** |
| 9915 |
* Default paster process |
| 9916 |
*/ defaultPasteProcess(e) { |
| 9917 |
const dt = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.getDataTransfer)(e); |
| 9918 |
let text = (dt === null || dt === void 0 ? void 0 : dt.getData(jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.TEXT_HTML)) || (dt === null || dt === void 0 ? void 0 : dt.getData(jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.TEXT_PLAIN)); |
| 9919 |
if (dt && text && (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.trim)(text) !== '') { |
| 9920 |
const result = this.j.e.fire('processPaste', e, text, (0,_helpers__WEBPACK_IMPORTED_MODULE_9__.getAllTypes)(dt)); |
| 9921 |
if (result !== undefined) { |
| 9922 |
text = result; |
| 9923 |
} |
| 9924 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.isString)(text) || jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isNode(text)) { |
| 9925 |
this.__insertByType(e, text, this.j.o.defaultActionOnPaste); |
| 9926 |
} |
| 9927 |
e.preventDefault(); |
| 9928 |
e.stopPropagation(); |
| 9929 |
} |
| 9930 |
} |
| 9931 |
/** |
| 9932 |
* Process usual HTML text fragment |
| 9933 |
*/ processHTML(e, html) { |
| 9934 |
if (!this.j.o.askBeforePasteHTML) { |
| 9935 |
return false; |
| 9936 |
} |
| 9937 |
if (this.j.o.memorizeChoiceWhenPasteFragment) { |
| 9938 |
const cached = this.pasteStack.find((cachedItem)=>cachedItem.html === html); |
| 9939 |
if (cached) { |
| 9940 |
this.__insertByType(e, html, cached.action || this.j.o.defaultActionOnPaste); |
| 9941 |
return true; |
| 9942 |
} |
| 9943 |
} |
| 9944 |
if (this._isDialogOpened) { |
| 9945 |
return true; |
| 9946 |
} |
| 9947 |
const dialog = (0,_helpers__WEBPACK_IMPORTED_MODULE_9__.askInsertTypeDialog)(this.j, 'Your code is similar to HTML. Keep as HTML?', 'Paste as HTML', (insertType)=>{ |
| 9948 |
this._isDialogOpened = false; |
| 9949 |
this.__insertByType(e, html, insertType); |
| 9950 |
}, this.j.o.pasteHTMLActionList); |
| 9951 |
if (dialog) { |
| 9952 |
this._isDialogOpened = true; |
| 9953 |
dialog.e.on('beforeClose', ()=>{ |
| 9954 |
this._isDialogOpened = false; |
| 9955 |
}); |
| 9956 |
} |
| 9957 |
return true; |
| 9958 |
} |
| 9959 |
/** |
| 9960 |
* Insert HTML by option type |
| 9961 |
*/ __insertByType(e, html, action) { |
| 9962 |
this.pasteStack.push({ |
| 9963 |
html, |
| 9964 |
action |
| 9965 |
}); |
| 9966 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.isString)(html)) { |
| 9967 |
this.j.buffer.set(jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.CLIPBOARD_ID, html); |
| 9968 |
switch(action){ |
| 9969 |
case jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.INSERT_CLEAR_HTML: |
| 9970 |
html = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.cleanFromWord)(html); |
| 9971 |
break; |
| 9972 |
case jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.INSERT_ONLY_TEXT: |
| 9973 |
html = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.stripTags)(html, this.j.ed, new Set(this.j.o.pasteExcludeStripTags)); |
| 9974 |
break; |
| 9975 |
case jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.INSERT_AS_TEXT: |
| 9976 |
html = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.htmlspecialchars)(html); |
| 9977 |
break; |
| 9978 |
default: |
| 9979 |
{ |
| 9980 |
const newHTML = this.j.e.fire('onCustomPasteHTMLOption', action, html, e); |
| 9981 |
if (typeof newHTML === 'string') { |
| 9982 |
html = newHTML; |
| 9983 |
} |
| 9984 |
} |
| 9985 |
} |
| 9986 |
} |
| 9987 |
(0,_helpers__WEBPACK_IMPORTED_MODULE_9__.pasteInsertHtml)(e, this.j, html); |
| 9988 |
} |
| 9989 |
/** |
| 9990 |
* Replace all \\n chars in plain text to br |
| 9991 |
*/ onProcessPasteReplaceNl2Br(ignore, text, type) { |
| 9992 |
if (type === jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.TEXT_PLAIN + ';' && !(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.isHTML)(text)) { |
| 9993 |
return (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.nl2br)(text); |
| 9994 |
} |
| 9995 |
} |
| 9996 |
constructor(...args){ |
| 9997 |
super(...args), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "pasteStack", new jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.LimitedStack(20)), /** |
| 9998 |
* The dialog box was already open |
| 9999 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "_isDialogOpened", false); |
| 10000 |
} |
| 10001 |
} |
| 10002 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 10003 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 10004 |
], paste.prototype, "onPaste", null); |
| 10005 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 10006 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 10007 |
], paste.prototype, "onProcessPasteReplaceNl2Br", null); |
| 10008 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_5__.pluginSystem.add('paste', paste); |
| 10009 |
|
| 10010 |
|
| 10011 |
/***/ }), |
| 10012 |
|
| 10013 |
/***/ 23599: |
| 10014 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 10015 |
|
| 10016 |
"use strict"; |
| 10017 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 10018 |
/* harmony export */ position: function() { return /* binding */ position; } |
| 10019 |
/* harmony export */ }); |
| 10020 |
/* harmony import */ var jodit_core_helpers_checker_is_jodit_object__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(24497); |
| 10021 |
/*! |
| 10022 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 10023 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 10024 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 10025 |
*/ /** |
| 10026 |
* @module helpers/size |
| 10027 |
*/ |
| 10028 |
/** |
| 10029 |
* Calculate screen element position |
| 10030 |
*/ function position(elm, jodit, recurse = false) { |
| 10031 |
var _elm_offsetWidth, _elm_offsetHeight; |
| 10032 |
const rect = elm.getBoundingClientRect(); |
| 10033 |
let xPos = rect.left, yPos = rect.top; |
| 10034 |
if ((0,jodit_core_helpers_checker_is_jodit_object__WEBPACK_IMPORTED_MODULE_0__.isJoditObject)(jodit) && jodit.iframe && jodit.ed.body.contains(elm) && !recurse) { |
| 10035 |
const { left, top } = position(jodit.iframe, jodit, true); |
| 10036 |
xPos += left; |
| 10037 |
yPos += top; |
| 10038 |
} |
| 10039 |
return { |
| 10040 |
left: Math.round(xPos), |
| 10041 |
top: Math.round(yPos), |
| 10042 |
width: Math.round((_elm_offsetWidth = elm.offsetWidth) !== null && _elm_offsetWidth !== void 0 ? _elm_offsetWidth : rect.width), |
| 10043 |
height: Math.round((_elm_offsetHeight = elm.offsetHeight) !== null && _elm_offsetHeight !== void 0 ? _elm_offsetHeight : rect.height) |
| 10044 |
}; |
| 10045 |
} |
| 10046 |
|
| 10047 |
|
| 10048 |
/***/ }), |
| 10049 |
|
| 10050 |
/***/ 24475: |
| 10051 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 10052 |
|
| 10053 |
"use strict"; |
| 10054 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 10055 |
/* harmony export */ Storage: function() { return /* binding */ Storage; }, |
| 10056 |
/* harmony export */ StorageKey: function() { return /* binding */ StorageKey; } |
| 10057 |
/* harmony export */ }); |
| 10058 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 10059 |
/* harmony import */ var jodit_core_helpers_string_camel_case__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(57821); |
| 10060 |
/* harmony import */ var _engines_local_storage_provider__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(59807); |
| 10061 |
/* harmony import */ var _engines_memory_storage_provider__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(9505); |
| 10062 |
/*! |
| 10063 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 10064 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 10065 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 10066 |
*/ /** |
| 10067 |
* [[include:core/storage/README.md]] |
| 10068 |
* @packageDocumentation |
| 10069 |
* @module storage |
| 10070 |
*/ |
| 10071 |
|
| 10072 |
|
| 10073 |
|
| 10074 |
const StorageKey = 'Jodit_'; |
| 10075 |
class Storage { |
| 10076 |
set(key, value) { |
| 10077 |
this.provider.set((0,jodit_core_helpers_string_camel_case__WEBPACK_IMPORTED_MODULE_1__.camelCase)(this.prefix + key), value); |
| 10078 |
return this; |
| 10079 |
} |
| 10080 |
delete(key) { |
| 10081 |
this.provider.delete((0,jodit_core_helpers_string_camel_case__WEBPACK_IMPORTED_MODULE_1__.camelCase)(this.prefix + key)); |
| 10082 |
return this; |
| 10083 |
} |
| 10084 |
get(key) { |
| 10085 |
return this.provider.get((0,jodit_core_helpers_string_camel_case__WEBPACK_IMPORTED_MODULE_1__.camelCase)(this.prefix + key)); |
| 10086 |
} |
| 10087 |
exists(key) { |
| 10088 |
return this.provider.exists((0,jodit_core_helpers_string_camel_case__WEBPACK_IMPORTED_MODULE_1__.camelCase)(this.prefix + key)); |
| 10089 |
} |
| 10090 |
clear() { |
| 10091 |
this.provider.clear(); |
| 10092 |
return this; |
| 10093 |
} |
| 10094 |
static makeStorage(persistentOrStrategy = false, suffix) { |
| 10095 |
let provider; |
| 10096 |
if (persistentOrStrategy === 'localStorage' || persistentOrStrategy === 'sessionStorage') { |
| 10097 |
if ((0,_engines_local_storage_provider__WEBPACK_IMPORTED_MODULE_2__.canUsePersistentStorage)(persistentOrStrategy)) { |
| 10098 |
provider = new _engines_local_storage_provider__WEBPACK_IMPORTED_MODULE_2__.LocalStorageProvider(StorageKey + (suffix || ''), persistentOrStrategy); |
| 10099 |
} |
| 10100 |
} else if (persistentOrStrategy === true) { |
| 10101 |
if ((0,_engines_local_storage_provider__WEBPACK_IMPORTED_MODULE_2__.canUsePersistentStorage)('localStorage')) { |
| 10102 |
provider = new _engines_local_storage_provider__WEBPACK_IMPORTED_MODULE_2__.LocalStorageProvider(StorageKey + (suffix || '')); |
| 10103 |
} |
| 10104 |
} |
| 10105 |
if (!provider) { |
| 10106 |
provider = new _engines_memory_storage_provider__WEBPACK_IMPORTED_MODULE_3__.MemoryStorageProvider(); |
| 10107 |
} |
| 10108 |
return new Storage(provider, suffix); |
| 10109 |
} |
| 10110 |
constructor(provider, suffix){ |
| 10111 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "provider", void 0); |
| 10112 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "prefix", void 0); |
| 10113 |
this.provider = provider; |
| 10114 |
this.prefix = StorageKey; |
| 10115 |
if (suffix) { |
| 10116 |
this.prefix += suffix; |
| 10117 |
} |
| 10118 |
} |
| 10119 |
} |
| 10120 |
|
| 10121 |
|
| 10122 |
/***/ }), |
| 10123 |
|
| 10124 |
/***/ 24497: |
| 10125 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 10126 |
|
| 10127 |
"use strict"; |
| 10128 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 10129 |
/* harmony export */ isJoditObject: function() { return /* binding */ isJoditObject; } |
| 10130 |
/* harmony export */ }); |
| 10131 |
/* harmony import */ var _is_function__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(91565); |
| 10132 |
/*! |
| 10133 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 10134 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 10135 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 10136 |
*/ /** |
| 10137 |
* @module helpers/checker |
| 10138 |
*/ |
| 10139 |
/** |
| 10140 |
* Check if element is instance of Jodit |
| 10141 |
*/ function isJoditObject(jodit) { |
| 10142 |
return Boolean(jodit && jodit instanceof Object && (0,_is_function__WEBPACK_IMPORTED_MODULE_0__.isFunction)(jodit.constructor) && // @ts-ignore |
| 10143 |
(typeof Jodit !== 'undefined' && jodit instanceof Jodit || jodit.isJodit)); |
| 10144 |
} |
| 10145 |
|
| 10146 |
|
| 10147 |
/***/ }), |
| 10148 |
|
| 10149 |
/***/ 24641: |
| 10150 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 10151 |
|
| 10152 |
"use strict"; |
| 10153 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 10154 |
/* harmony export */ UICheckbox: function() { return /* binding */ UICheckbox; } |
| 10155 |
/* harmony export */ }); |
| 10156 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 10157 |
/* harmony import */ var _swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(41411); |
| 10158 |
/* harmony import */ var _swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(15366); |
| 10159 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(31635); |
| 10160 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(84839); |
| 10161 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(23211); |
| 10162 |
/* harmony import */ var jodit_core_ui_form_inputs_input_input__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(65273); |
| 10163 |
/*! |
| 10164 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 10165 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 10166 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 10167 |
*/ /** |
| 10168 |
* @module ui/form |
| 10169 |
*/ |
| 10170 |
|
| 10171 |
|
| 10172 |
|
| 10173 |
|
| 10174 |
|
| 10175 |
|
| 10176 |
|
| 10177 |
class UICheckbox extends jodit_core_ui_form_inputs_input_input__WEBPACK_IMPORTED_MODULE_6__.UIInput { |
| 10178 |
/** @override */ className() { |
| 10179 |
return 'UICheckbox'; |
| 10180 |
} |
| 10181 |
/** @override */ render() { |
| 10182 |
return this.j.c.element('label', { |
| 10183 |
className: this.componentName |
| 10184 |
}); |
| 10185 |
} |
| 10186 |
onChangeChecked() { |
| 10187 |
this.value = this.state.checked.toString(); |
| 10188 |
this.nativeInput.checked = this.state.checked; |
| 10189 |
this.setMod('checked', this.state.checked); |
| 10190 |
} |
| 10191 |
onChangeNativeCheckBox() { |
| 10192 |
this.state.checked = this.nativeInput.checked; |
| 10193 |
} |
| 10194 |
onChangeSwitch() { |
| 10195 |
this.setMod('switch', this.state.switch); |
| 10196 |
let slider = this.getElm('switch-slider'); |
| 10197 |
if (this.state.switch) { |
| 10198 |
if (!slider) { |
| 10199 |
slider = this.j.c.div(this.getFullElName('switch-slider')); |
| 10200 |
} |
| 10201 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_5__.Dom.after(this.nativeInput, slider); |
| 10202 |
} else { |
| 10203 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_5__.Dom.safeRemove(slider); |
| 10204 |
} |
| 10205 |
} |
| 10206 |
/** @override **/ constructor(jodit, options){ |
| 10207 |
super(jodit, (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_2__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_1__._)({}, options), { |
| 10208 |
type: 'checkbox' |
| 10209 |
})), /** @override */ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "state", (0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_1__._)({}, UICheckbox.defaultState)); |
| 10210 |
Object.assign(this.state, options); |
| 10211 |
} |
| 10212 |
} |
| 10213 |
/** @override */ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(UICheckbox, "defaultState", (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_2__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_1__._)({}, jodit_core_ui_form_inputs_input_input__WEBPACK_IMPORTED_MODULE_6__.UIInput.defaultState), { |
| 10214 |
checked: false, |
| 10215 |
switch: false |
| 10216 |
})); |
| 10217 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__.__decorate)([ |
| 10218 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__.watch)('state.checked'), |
| 10219 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__.hook)('ready') |
| 10220 |
], UICheckbox.prototype, "onChangeChecked", null); |
| 10221 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__.__decorate)([ |
| 10222 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__.watch)('nativeInput:change') |
| 10223 |
], UICheckbox.prototype, "onChangeNativeCheckBox", null); |
| 10224 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__.__decorate)([ |
| 10225 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__.watch)('state.switch'), |
| 10226 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__.hook)('ready') |
| 10227 |
], UICheckbox.prototype, "onChangeSwitch", null); |
| 10228 |
UICheckbox = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__.__decorate)([ |
| 10229 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__.component |
| 10230 |
], UICheckbox); |
| 10231 |
|
| 10232 |
|
| 10233 |
/***/ }), |
| 10234 |
|
| 10235 |
/***/ 24735: |
| 10236 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 10237 |
|
| 10238 |
"use strict"; |
| 10239 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 10240 |
/* harmony export */ Async: function() { return /* binding */ Async; } |
| 10241 |
/* harmony export */ }); |
| 10242 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 10243 |
/* harmony import */ var _swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(41411); |
| 10244 |
/* harmony import */ var _swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(15366); |
| 10245 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(81937); |
| 10246 |
/* harmony import */ var jodit_core_helpers_async__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(61077); |
| 10247 |
/* harmony import */ var jodit_core_helpers_checker_is_abort_error__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(72068); |
| 10248 |
/* harmony import */ var jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(91565); |
| 10249 |
/* harmony import */ var jodit_core_helpers_checker_is_number__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(72412); |
| 10250 |
/* harmony import */ var jodit_core_helpers_checker_is_plain_object__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(62101); |
| 10251 |
/* harmony import */ var jodit_core_helpers_checker_is_promise__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(52100); |
| 10252 |
/* harmony import */ var jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(85932); |
| 10253 |
/* harmony import */ var jodit_core_helpers_checker_is_void__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(18303); |
| 10254 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(28712); |
| 10255 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_12___default = /*#__PURE__*/__webpack_require__.n(jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_12__); |
| 10256 |
/* harmony import */ var jodit_core_helpers_utils_error_errors_abort_error__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(14228); |
| 10257 |
/*! |
| 10258 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 10259 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 10260 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 10261 |
*/ /** |
| 10262 |
* [[include:core/async/README.md]] |
| 10263 |
* @packageDocumentation |
| 10264 |
* @module async |
| 10265 |
*/ |
| 10266 |
|
| 10267 |
|
| 10268 |
|
| 10269 |
|
| 10270 |
|
| 10271 |
|
| 10272 |
|
| 10273 |
|
| 10274 |
|
| 10275 |
|
| 10276 |
|
| 10277 |
|
| 10278 |
|
| 10279 |
class Async { |
| 10280 |
delay(timeout) { |
| 10281 |
return this.promise((resolve)=>this.setTimeout(resolve, timeout)); |
| 10282 |
} |
| 10283 |
setTimeout(callback, timeout, ...args) { |
| 10284 |
if (this.isDestructed) { |
| 10285 |
return 0; |
| 10286 |
} |
| 10287 |
let options = {}; |
| 10288 |
if ((0,jodit_core_helpers_checker_is_void__WEBPACK_IMPORTED_MODULE_11__.isVoid)(timeout)) { |
| 10289 |
timeout = 0; |
| 10290 |
} |
| 10291 |
if (!(0,jodit_core_helpers_checker_is_number__WEBPACK_IMPORTED_MODULE_7__.isNumber)(timeout)) { |
| 10292 |
options = timeout; |
| 10293 |
timeout = options.timeout || 0; |
| 10294 |
} |
| 10295 |
if (options.label) { |
| 10296 |
this.clearLabel(options.label); |
| 10297 |
} |
| 10298 |
const timer = (0,jodit_core_helpers_async__WEBPACK_IMPORTED_MODULE_4__.setTimeout)(callback, timeout, ...args); |
| 10299 |
const key = options.label || timer; |
| 10300 |
this.timers.set(key, timer); |
| 10301 |
this.__callbacks.set(key, callback); |
| 10302 |
return timer; |
| 10303 |
} |
| 10304 |
updateTimeout(label, timeout) { |
| 10305 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_12__.assert)(label && this.timers.has(label), 'Label does not exist'); |
| 10306 |
if (!label || !this.timers.has(label)) { |
| 10307 |
return null; |
| 10308 |
} |
| 10309 |
const callback = this.__callbacks.get(label); |
| 10310 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_12__.assert)((0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_6__.isFunction)(callback), 'Callback is not a function'); |
| 10311 |
return this.setTimeout(callback, { |
| 10312 |
label, |
| 10313 |
timeout |
| 10314 |
}); |
| 10315 |
} |
| 10316 |
clearLabel(label) { |
| 10317 |
if (label && this.timers.has(label)) { |
| 10318 |
(0,jodit_core_helpers_async__WEBPACK_IMPORTED_MODULE_4__.clearTimeout)(this.timers.get(label)); |
| 10319 |
this.timers.delete(label); |
| 10320 |
this.__callbacks.delete(label); |
| 10321 |
} |
| 10322 |
} |
| 10323 |
clearTimeout(timerOrLabel) { |
| 10324 |
if ((0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_10__.isString)(timerOrLabel)) { |
| 10325 |
return this.clearLabel(timerOrLabel); |
| 10326 |
} |
| 10327 |
(0,jodit_core_helpers_async__WEBPACK_IMPORTED_MODULE_4__.clearTimeout)(timerOrLabel); |
| 10328 |
this.timers.delete(timerOrLabel); |
| 10329 |
this.__callbacks.delete(timerOrLabel); |
| 10330 |
} |
| 10331 |
/** |
| 10332 |
* Debouncing enforces that a function not be called again until a certain amount of time has passed without |
| 10333 |
* it being called. As in "execute this function only if 100 milliseconds have passed without it being called." |
| 10334 |
* |
| 10335 |
* @example |
| 10336 |
* ```javascript |
| 10337 |
* var jodit = Jodit.make('.editor'); |
| 10338 |
* jodit.e.on('mousemove', jodit.async.debounce(() => { |
| 10339 |
* // Do expensive things |
| 10340 |
* }, 100)); |
| 10341 |
* ``` |
| 10342 |
*/ debounce(fn, timeout, firstCallImmediately = false) { |
| 10343 |
let timer = 0, fired = false; |
| 10344 |
const promises = []; |
| 10345 |
const callFn = (...args)=>{ |
| 10346 |
if (!fired) { |
| 10347 |
timer = 0; |
| 10348 |
const res = fn(...args); |
| 10349 |
fired = true; |
| 10350 |
if (promises.length) { |
| 10351 |
const runPromises = ()=>{ |
| 10352 |
promises.forEach((res)=>res()); |
| 10353 |
promises.length = 0; |
| 10354 |
}; |
| 10355 |
(0,jodit_core_helpers_checker_is_promise__WEBPACK_IMPORTED_MODULE_9__.isPromise)(res) ? res.finally(runPromises) : runPromises(); |
| 10356 |
} |
| 10357 |
} |
| 10358 |
}; |
| 10359 |
const onFire = (...args)=>{ |
| 10360 |
fired = false; |
| 10361 |
if (!timeout) { |
| 10362 |
callFn(...args); |
| 10363 |
} else { |
| 10364 |
if (!timer && firstCallImmediately) { |
| 10365 |
callFn(...args); |
| 10366 |
} |
| 10367 |
(0,jodit_core_helpers_async__WEBPACK_IMPORTED_MODULE_4__.clearTimeout)(timer); |
| 10368 |
timer = this.setTimeout(()=>callFn(...args), (0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_6__.isFunction)(timeout) ? timeout() : timeout); |
| 10369 |
this.timers.set(fn, timer); |
| 10370 |
} |
| 10371 |
}; |
| 10372 |
return (0,jodit_core_helpers_checker_is_plain_object__WEBPACK_IMPORTED_MODULE_8__.isPlainObject)(timeout) && timeout.promisify ? (...args)=>{ |
| 10373 |
const promise = this.promise((res)=>{ |
| 10374 |
promises.push(res); |
| 10375 |
}).catch((e)=>{ |
| 10376 |
if ((0,jodit_core_helpers_checker_is_abort_error__WEBPACK_IMPORTED_MODULE_5__.isAbortError)(e)) { |
| 10377 |
return null; |
| 10378 |
} |
| 10379 |
throw e; |
| 10380 |
}); |
| 10381 |
onFire(...args); |
| 10382 |
return promise; |
| 10383 |
} : onFire; |
| 10384 |
} |
| 10385 |
microDebounce(fn, firstCallImmediately = false) { |
| 10386 |
let scheduled = false; |
| 10387 |
let needCall = true; |
| 10388 |
let savedArgs; |
| 10389 |
return (...args)=>{ |
| 10390 |
savedArgs = args; |
| 10391 |
if (scheduled) { |
| 10392 |
needCall = true; |
| 10393 |
return; |
| 10394 |
} |
| 10395 |
needCall = true; |
| 10396 |
if (firstCallImmediately) { |
| 10397 |
needCall = false; |
| 10398 |
fn(...savedArgs); |
| 10399 |
} |
| 10400 |
scheduled = true; |
| 10401 |
this.__queueMicrotaskNative(()=>{ |
| 10402 |
scheduled = false; |
| 10403 |
if (this.isDestructed) { |
| 10404 |
return; |
| 10405 |
} |
| 10406 |
needCall && fn(...savedArgs); |
| 10407 |
}); |
| 10408 |
}; |
| 10409 |
} |
| 10410 |
/** |
| 10411 |
* Throttling enforces a maximum number of times a function can be called over time. |
| 10412 |
* As in "execute this function at most once every 100 milliseconds." |
| 10413 |
* |
| 10414 |
* @example |
| 10415 |
* ```javascript |
| 10416 |
* var jodit = Jodit.make('.editor'); |
| 10417 |
* jodit.e.on(document.body, 'scroll', jodit.async.throttle(function() { |
| 10418 |
* // Do expensive things |
| 10419 |
* }, 100)); |
| 10420 |
* ``` |
| 10421 |
*/ throttle(fn, timeout, ignore = false) { |
| 10422 |
let timer = null, needInvoke, callee, lastArgs; |
| 10423 |
return (...args)=>{ |
| 10424 |
needInvoke = true; |
| 10425 |
lastArgs = args; |
| 10426 |
if (!timeout) { |
| 10427 |
fn(...lastArgs); |
| 10428 |
return; |
| 10429 |
} |
| 10430 |
if (!timer) { |
| 10431 |
callee = ()=>{ |
| 10432 |
if (needInvoke) { |
| 10433 |
fn(...lastArgs); |
| 10434 |
needInvoke = false; |
| 10435 |
timer = this.setTimeout(callee, (0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_6__.isFunction)(timeout) ? timeout() : timeout); |
| 10436 |
this.timers.set(callee, timer); |
| 10437 |
} else { |
| 10438 |
timer = null; |
| 10439 |
} |
| 10440 |
}; |
| 10441 |
callee(); |
| 10442 |
} |
| 10443 |
}; |
| 10444 |
} |
| 10445 |
promise(executor) { |
| 10446 |
let rejectCallback = ()=>{}; |
| 10447 |
const promise = new Promise((resolve, reject)=>{ |
| 10448 |
rejectCallback = ()=>reject((0,jodit_core_helpers_utils_error_errors_abort_error__WEBPACK_IMPORTED_MODULE_13__.abort)('Abort async')); |
| 10449 |
this.promisesRejections.add(rejectCallback); |
| 10450 |
executor(resolve, reject); |
| 10451 |
}); |
| 10452 |
if (!promise.finally && typeof process !== 'undefined' && !jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.IS_ES_NEXT) { |
| 10453 |
promise.finally = (onfinally)=>{ |
| 10454 |
promise.then(onfinally).catch(onfinally); |
| 10455 |
return promise; |
| 10456 |
}; |
| 10457 |
} |
| 10458 |
promise.finally(()=>{ |
| 10459 |
this.promisesRejections.delete(rejectCallback); |
| 10460 |
}).catch(()=>null); |
| 10461 |
promise.rejectCallback = rejectCallback; |
| 10462 |
return promise; |
| 10463 |
} |
| 10464 |
/** |
| 10465 |
* Get Promise status |
| 10466 |
*/ promiseState(p) { |
| 10467 |
if (p.status) { |
| 10468 |
return p.status; |
| 10469 |
} |
| 10470 |
// Hi IE11 |
| 10471 |
if (!Promise.race) { |
| 10472 |
return new Promise((resolve)=>{ |
| 10473 |
p.then((v)=>{ |
| 10474 |
resolve('fulfilled'); |
| 10475 |
return v; |
| 10476 |
}, (e)=>{ |
| 10477 |
resolve('rejected'); |
| 10478 |
throw e; |
| 10479 |
}); |
| 10480 |
this.setTimeout(()=>{ |
| 10481 |
resolve('pending'); |
| 10482 |
}, 100); |
| 10483 |
}); |
| 10484 |
} |
| 10485 |
const t = {}; |
| 10486 |
return Promise.race([ |
| 10487 |
p, |
| 10488 |
t |
| 10489 |
]).then((v)=>v === t ? 'pending' : 'fulfilled', ()=>'rejected'); |
| 10490 |
} |
| 10491 |
requestIdleCallback(callback, options = { |
| 10492 |
timeout: 100 |
| 10493 |
}) { |
| 10494 |
const request = this.__requestIdleCallbackNative(callback, options); |
| 10495 |
this.__requestsIdle.add(request); |
| 10496 |
return request; |
| 10497 |
} |
| 10498 |
requestIdlePromise(options) { |
| 10499 |
return this.promise((res)=>{ |
| 10500 |
const request = this.requestIdleCallback(()=>res(request), options); |
| 10501 |
}); |
| 10502 |
} |
| 10503 |
/** |
| 10504 |
* Try to use scheduler.postTask if it is available https://wicg.github.io/scheduling-apis/ |
| 10505 |
*/ schedulerPostTask(task, options = { |
| 10506 |
delay: 0, |
| 10507 |
priority: 'user-visible' |
| 10508 |
}) { |
| 10509 |
const controller = new AbortController(); |
| 10510 |
if (options.signal) { |
| 10511 |
options.signal.addEventListener('abort', ()=>controller.abort()); |
| 10512 |
} |
| 10513 |
this.__controllers.add(controller); |
| 10514 |
// @ts-ignore |
| 10515 |
if (typeof globalThis.scheduler !== 'undefined') { |
| 10516 |
const scheduler = globalThis.scheduler; |
| 10517 |
const promise = scheduler.postTask(task, (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_2__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_1__._)({}, options), { |
| 10518 |
signal: controller.signal |
| 10519 |
})); |
| 10520 |
promise.finally(()=>{ |
| 10521 |
this.__controllers.delete(controller); |
| 10522 |
}).catch(()=>null); |
| 10523 |
return promise; |
| 10524 |
} |
| 10525 |
return this.promise((resolve, reject)=>{ |
| 10526 |
const timeout = this.setTimeout(()=>{ |
| 10527 |
try { |
| 10528 |
resolve(task()); |
| 10529 |
} catch (e) { |
| 10530 |
reject(e); |
| 10531 |
} |
| 10532 |
this.__controllers.delete(controller); |
| 10533 |
}, options.delay || 1); |
| 10534 |
controller.signal.addEventListener('abort', ()=>{ |
| 10535 |
this.clearTimeout(timeout); |
| 10536 |
this.__controllers.delete(controller); |
| 10537 |
reject((0,jodit_core_helpers_utils_error_errors_abort_error__WEBPACK_IMPORTED_MODULE_13__.abort)()); |
| 10538 |
}); |
| 10539 |
}); |
| 10540 |
} |
| 10541 |
schedulerYield() { |
| 10542 |
return this.schedulerPostTask(()=>{}, { |
| 10543 |
priority: 'user-visible' |
| 10544 |
}); |
| 10545 |
} |
| 10546 |
cancelIdleCallback(request) { |
| 10547 |
this.__requestsIdle.delete(request); |
| 10548 |
return this.__cancelIdleCallbackNative(request); |
| 10549 |
} |
| 10550 |
requestAnimationFrame(callback) { |
| 10551 |
const request = requestAnimationFrame(callback); |
| 10552 |
this.__requestsRaf.add(request); |
| 10553 |
return request; |
| 10554 |
} |
| 10555 |
cancelAnimationFrame(request) { |
| 10556 |
this.__requestsRaf.delete(request); |
| 10557 |
cancelAnimationFrame(request); |
| 10558 |
} |
| 10559 |
clear() { |
| 10560 |
this.__requestsIdle.forEach((key)=>this.cancelIdleCallback(key)); |
| 10561 |
this.__requestsRaf.forEach((key)=>this.cancelAnimationFrame(key)); |
| 10562 |
this.__controllers.forEach((controller)=>controller.abort()); |
| 10563 |
this.timers.forEach((key)=>(0,jodit_core_helpers_async__WEBPACK_IMPORTED_MODULE_4__.clearTimeout)(this.timers.get(key))); |
| 10564 |
this.timers.clear(); |
| 10565 |
this.promisesRejections.forEach((reject)=>reject()); |
| 10566 |
this.promisesRejections.clear(); |
| 10567 |
} |
| 10568 |
destruct() { |
| 10569 |
this.clear(); |
| 10570 |
this.isDestructed = true; |
| 10571 |
} |
| 10572 |
constructor(){ |
| 10573 |
var _ref, _ref1, _ref2; |
| 10574 |
var _queueMicrotask, _window_requestIdleCallback, _window_cancelIdleCallback; |
| 10575 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "timers", new Map()); |
| 10576 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__callbacks", new Map()); |
| 10577 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__queueMicrotaskNative", (_ref = (_queueMicrotask = queueMicrotask) === null || _queueMicrotask === void 0 ? void 0 : _queueMicrotask.bind(window)) !== null && _ref !== void 0 ? _ref : Promise.resolve().then.bind(Promise.resolve())); |
| 10578 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "promisesRejections", new Set()); |
| 10579 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__requestsIdle", new Set()); |
| 10580 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__controllers", new Set()); |
| 10581 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__requestsRaf", new Set()); |
| 10582 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__requestIdleCallbackNative", (_ref1 = (_window_requestIdleCallback = window['requestIdleCallback']) === null || _window_requestIdleCallback === void 0 ? void 0 : _window_requestIdleCallback.bind(window)) !== null && _ref1 !== void 0 ? _ref1 : (callback, options)=>{ |
| 10583 |
var _ref; |
| 10584 |
const start = Date.now(); |
| 10585 |
return this.setTimeout(()=>{ |
| 10586 |
callback({ |
| 10587 |
didTimeout: false, |
| 10588 |
timeRemaining: ()=>Math.max(0, 50 - (Date.now() - start)) |
| 10589 |
}); |
| 10590 |
}, (_ref = options === null || options === void 0 ? void 0 : options.timeout) !== null && _ref !== void 0 ? _ref : 1); |
| 10591 |
}); |
| 10592 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__cancelIdleCallbackNative", (_ref2 = (_window_cancelIdleCallback = window['cancelIdleCallback']) === null || _window_cancelIdleCallback === void 0 ? void 0 : _window_cancelIdleCallback.bind(window)) !== null && _ref2 !== void 0 ? _ref2 : (request)=>{ |
| 10593 |
this.clearTimeout(request); |
| 10594 |
}); |
| 10595 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "isDestructed", false); |
| 10596 |
} |
| 10597 |
} |
| 10598 |
|
| 10599 |
|
| 10600 |
/***/ }), |
| 10601 |
|
| 10602 |
/***/ 24772: |
| 10603 |
/***/ (function(module) { |
| 10604 |
|
| 10605 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 24 24\"> <path stroke-width=\"0\" d=\"M22,20.6L3.4,2H8V0H0v8h2V3.4L20.6,22H16v2h8v-8h-2V20.6z M16,0v2h4.7l-6.3,6.3l1.4,1.4L22,3.5V8h2V0H16z M8.3,14.3L2,20.6V16H0v8h8v-2H3.5l6.3-6.3L8.3,14.3z\"/> </svg>" |
| 10606 |
|
| 10607 |
/***/ }), |
| 10608 |
|
| 10609 |
/***/ 24968: |
| 10610 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 10611 |
|
| 10612 |
"use strict"; |
| 10613 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 10614 |
/* harmony export */ derive: function() { return /* binding */ derive; } |
| 10615 |
/* harmony export */ }); |
| 10616 |
/* harmony import */ var jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(91565); |
| 10617 |
/*! |
| 10618 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 10619 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 10620 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 10621 |
*/ /** |
| 10622 |
* [[include:core/decorators/derive/README.md]] |
| 10623 |
* @packageDocumentation |
| 10624 |
* @module decorators/derive |
| 10625 |
*/ |
| 10626 |
function derive(...traits) { |
| 10627 |
return (target)=>{ |
| 10628 |
const origin = target.prototype; |
| 10629 |
for(let i = 0; i < traits.length; i++){ |
| 10630 |
const trait = traits[i]; |
| 10631 |
const keys = Object.getOwnPropertyNames(trait.prototype); |
| 10632 |
for(let j = 0; j < keys.length; j++){ |
| 10633 |
const key = keys[j], method = Object.getOwnPropertyDescriptor(trait.prototype, key); |
| 10634 |
const canDerive = method != null && (0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_0__.isFunction)(method.value) && !(0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_0__.isFunction)(origin[key]); |
| 10635 |
if (canDerive) { |
| 10636 |
Object.defineProperty(origin, key, { |
| 10637 |
enumerable: true, |
| 10638 |
configurable: true, |
| 10639 |
writable: true, |
| 10640 |
value: function(...args) { |
| 10641 |
return method.value.call(this, ...args); |
| 10642 |
} |
| 10643 |
}); |
| 10644 |
} |
| 10645 |
} |
| 10646 |
} |
| 10647 |
}; |
| 10648 |
} |
| 10649 |
|
| 10650 |
|
| 10651 |
/***/ }), |
| 10652 |
|
| 10653 |
/***/ 25045: |
| 10654 |
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { |
| 10655 |
|
| 10656 |
"use strict"; |
| 10657 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 10658 |
/* harmony export */ _: function() { return /* binding */ _define_property; } |
| 10659 |
/* harmony export */ }); |
| 10660 |
function _define_property(obj, key, value) { |
| 10661 |
if (key in obj) { |
| 10662 |
Object.defineProperty(obj, key, { |
| 10663 |
value: value, |
| 10664 |
enumerable: true, |
| 10665 |
configurable: true, |
| 10666 |
writable: true |
| 10667 |
}); |
| 10668 |
} else obj[key] = value; |
| 10669 |
return obj; |
| 10670 |
} |
| 10671 |
|
| 10672 |
|
| 10673 |
|
| 10674 |
/***/ }), |
| 10675 |
|
| 10676 |
/***/ 25090: |
| 10677 |
/***/ (function(module) { |
| 10678 |
|
| 10679 |
module.exports["default"] = ["Ecrivez ici","A propos de Jodit","Editeur Jodit","Guide de l'utilisateur","Aide détaillée à l'utilisation","Consulter la licence sur notre site web:","Acheter la version complète","Copyright © XDSoft.net - Chupurnov Valeriy. Tous droits réservés.","Ancre","Ouvrir dans un nouvel onglet","Ouvrir l'éditeur en pleine page","Supprimer le formattage","Modifier la couleur du fond ou du texte","Refaire","Défaire","Gras","Italique","Liste non ordonnée","Liste ordonnée","Centrer","Justifier","Aligner à gauche ","Aligner à droite","Insérer une ligne horizontale","Insérer une image","Insérer un fichier","Insérer une vidéo","Insérer un lien","Taille des caractères","Famille des caractères","Bloc formatté","Normal","Titre 1","Titre 2","Titre 3","Titre 4","Citation","Code","Insérer","Insérer un tableau","Diminuer le retrait","Retrait plus","Sélectionnez un caractère spécial","Insérer un caractère spécial","Cloner le format","Mode wysiwyg <-> code html","Marges","haut","droite","Bas","gauche","Styles","Classes","Alignement","Droite","Centre","Gauche","--Non disponible--","Source","Titre","Alternative","Lien","Ouvrir le lien dans un nouvel onglet","Image","fichier","Avancé","Propriétés de l'image","Annuler","OK","Explorateur de fichiers","Erreur de liste de chargement","Erreur de dossier de chargement","Etes-vous sûrs ?","Entrer le nom de dossier","Créer un dossier","type de fichier","Coller une image","Déposer un fichier","ou cliquer","Texte de remplacemement","Charger","Chercher","Arrière-plan","Texte","Haut","Milieu","Bas","Insérer une colonne avant","Insérer une colonne après","Insérer une ligne au dessus","Insérer une ligne en dessous","Supprimer le tableau","Supprimer la ligne","Supprimer la colonne","Vider la cellule","Symboles: %d","Mots: %d","Barrer","Souligner","exposant","indice","Couper la sélection","Tout sélectionner","Pause","Rechercher","Remplacer par","Remplacer","Coller","Choisissez le contenu à coller","la source","gras","italique","pinceau","lien","annuler","refaire","tableau","image","gomme","clause","taille de police","Video","police","à propos de l'éditeur","impression","souligné","barré","indentation","retrait","taille réelle","taille conventionnelle","la ligne","Liste","Liste numérotée","Couper","Sélectionner tout","Code d'intégration","Ouvrir le lien","Modifier le lien","Attribut Nofollow","Supprimer le lien","Mettre à jour","Pour éditer","Voir","URL","Modifier","Alignement horizontal","Filtre","Trier par modification","Trier par nom","Trier par taille","Créer le dossier","Restaurer","Sauvegarder","Enregistrer sous","Changer la taille","Taille de garniture","Largeur","Hauteur","Garder les proportions","Oui","Non","Supprimer","Mettre en évidence","Mettre en évidence: %s","Alignement vertical","Split","aller","Ajouter une colonne","Ajouter une rangée","Licence: %s","Effacer","Split vertical","Split horizontal","Bordure","Votre texte que vous essayez de coller est similaire au HTML. Collez-le en HTML?","Coller en HTML?","Sauvegarder l'original","Coller en tant que texte","Coller le texte seulement","Vous ne pouvez éditer que vos propres images. Téléchargez cette image sur l'hôte?","L'image a été téléchargée avec succès sur le serveur!","Palette","Il n'y a aucun fichier dans ce répertoire.","renommer","Entrez un nouveau nom","Aperçu","Télécharger","Coller à partir du presse-papiers","Votre navigateur ne prend pas en charge l'accès direct au presse-papiers.","Copier la sélection","copie","Rayon des bordures","Afficher tous","Appliquer","Veuillez remplir ce champ","Veuillez entrer une adresse web","Par défaut","Cercle","Point","Quadratique","Trouver","Précédent","Suivant","Le contenu que vous insérez provient d'un document Microsoft Word / Excel. Voulez-vous enregistrer le format ou l'effacer?","C'est peut-être un fragment de Word ou Excel","Nettoyer","Insérer un nom de classe","Appuyez sur Alt pour un redimensionnement personnalisé",null,null,null,"Tout sélectionner"] |
| 10680 |
|
| 10681 |
/***/ }), |
| 10682 |
|
| 10683 |
/***/ 25182: |
| 10684 |
/***/ (function(module) { |
| 10685 |
|
| 10686 |
module.exports["default"] = ["输入一些内容","关于Jodit","Jodit Editor","开发者指南","使用帮助","有关许可证的信息,请访问我们的网站:","购买完整版本","Copyright © XDSoft.net - Chupurnov Valeriy. 版权所有","Anchor","在新窗口打开","全屏编辑","清除样式","颜色","重做","撤销","粗体","斜体","符号列表","编号","居中","对齐文本","左对齐","右对齐","分割线","图片","文件","视频","链接","字号","字体","格式块","默认","标题1","标题2","标题3","标题4","引用","代码","插入","表格","减少缩进","增加缩进","选择特殊符号","特殊符号","格式复制","改变模式","外边距(Margins)","top","right","bottom","left","样式","Classes","对齐方式","居右","居中","居左","无","Src","Title","Alternative","Link","在新窗口打开链接","图片","file","高级","图片属性","取消","确定","文件管理","加载list错误","加载folders错误","你确定吗?","输入路径","创建路径","type name","拖动图片到此","拖动文件到此","或点击","Alternative text","上传","浏览","背景色","文字","顶部","中间","底部","在之前插入列","在之后插入列","在之前插入行","在之后插入行","删除表格","删除行","删除列","清除内容","字符数: %d","单词数: %d","删除线","下划线","上标","下标","剪切","全选","Break","查找","替换为","替换","粘贴","选择内容并粘贴","源码","粗体","斜体","颜色","链接","撤销","重做","表格","图片","橡皮擦","段落","字号","视频","字体","关于","打印","下划线","上出现","增加缩进","减少缩进","全屏","收缩","分割线","无序列表","顺序列表","剪切","全选","嵌入代码","打开链接","编辑链接","No follow","取消链接","更新","铅笔","预览","URL","编辑","水平对齐","筛选","修改时间排序","名称排序","大小排序","新建文件夹","重置","保存","保存为","调整大小","剪切","宽","高","保持长宽比","是","不","移除","选择","选择: %s","垂直对齐","拆分","合并","添加列","添加行","许可证: %s","删除","垂直拆分","水平拆分","边框","你粘贴的文本是一段html代码,是否保留源格式","html粘贴","保留源格式","把html代码视为普通文本","只保留文本","你只能编辑你自己的图片。Download this image on the host?","图片上传成功","调色板","此目录中沒有文件。","重命名","输入新名称","预览","下载","粘贴从剪贴板","你浏览器不支持直接访问的剪贴板。","复制选中内容","复制","边界半径","显示所有","应用","请填写这个字段","请输入一个网址","默认","圆圈","点","方形","搜索","查找上一个","查找下一个","正在粘贴 Word/Excel 的文本,是否保留源格式?","文本粘贴","匹配目标格式","插入班级名称","按Alt自定义调整大小",null,null,null,"全部"] |
| 10687 |
|
| 10688 |
/***/ }), |
| 10689 |
|
| 10690 |
/***/ 25222: |
| 10691 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 10692 |
|
| 10693 |
"use strict"; |
| 10694 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 10695 |
/* harmony export */ AsyncStorage: function() { return /* reexport safe */ _async_storage__WEBPACK_IMPORTED_MODULE_0__.AsyncStorage; }, |
| 10696 |
/* harmony export */ IndexedDBProvider: function() { return /* reexport safe */ _engines_indexed_db_provider__WEBPACK_IMPORTED_MODULE_1__.IndexedDBProvider; }, |
| 10697 |
/* harmony export */ LocalStorageProvider: function() { return /* reexport safe */ _engines_local_storage_provider__WEBPACK_IMPORTED_MODULE_2__.LocalStorageProvider; }, |
| 10698 |
/* harmony export */ MemoryStorageProvider: function() { return /* reexport safe */ _engines_memory_storage_provider__WEBPACK_IMPORTED_MODULE_3__.MemoryStorageProvider; }, |
| 10699 |
/* harmony export */ Storage: function() { return /* reexport safe */ _storage__WEBPACK_IMPORTED_MODULE_4__.Storage; }, |
| 10700 |
/* harmony export */ StorageKey: function() { return /* reexport safe */ _storage__WEBPACK_IMPORTED_MODULE_4__.StorageKey; }, |
| 10701 |
/* harmony export */ canUseIndexedDB: function() { return /* reexport safe */ _engines_indexed_db_provider__WEBPACK_IMPORTED_MODULE_1__.canUseIndexedDB; }, |
| 10702 |
/* harmony export */ canUsePersistentStorage: function() { return /* reexport safe */ _engines_local_storage_provider__WEBPACK_IMPORTED_MODULE_2__.canUsePersistentStorage; }, |
| 10703 |
/* harmony export */ clearUseIndexedDBCache: function() { return /* reexport safe */ _engines_indexed_db_provider__WEBPACK_IMPORTED_MODULE_1__.clearUseIndexedDBCache; } |
| 10704 |
/* harmony export */ }); |
| 10705 |
/* harmony import */ var _async_storage__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(8006); |
| 10706 |
/* harmony import */ var _engines_indexed_db_provider__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(91162); |
| 10707 |
/* harmony import */ var _engines_local_storage_provider__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(59807); |
| 10708 |
/* harmony import */ var _engines_memory_storage_provider__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(9505); |
| 10709 |
/* harmony import */ var _storage__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(24475); |
| 10710 |
/*! |
| 10711 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 10712 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 10713 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 10714 |
*/ /** |
| 10715 |
* @module storage |
| 10716 |
*/ |
| 10717 |
|
| 10718 |
|
| 10719 |
|
| 10720 |
|
| 10721 |
|
| 10722 |
|
| 10723 |
/***/ }), |
| 10724 |
|
| 10725 |
/***/ 25501: |
| 10726 |
/***/ (function(module) { |
| 10727 |
|
| 10728 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M1744 1408q33 0 42 18.5t-11 44.5l-126 162q-20 26-49 26t-49-26l-126-162q-20-26-11-44.5t42-18.5h80v-1024h-80q-33 0-42-18.5t11-44.5l126-162q20-26 49-26t49 26l126 162q20 26 11 44.5t-42 18.5h-80v1024h80zm-1663-1279l54 27q12 5 211 5 44 0 132-2t132-2q36 0 107.5.5t107.5.5h293q6 0 21 .5t20.5 0 16-3 17.5-9 15-17.5l42-1q4 0 14 .5t14 .5q2 112 2 336 0 80-5 109-39 14-68 18-25-44-54-128-3-9-11-48t-14.5-73.5-7.5-35.5q-6-8-12-12.5t-15.5-6-13-2.5-18-.5-16.5.5q-17 0-66.5-.5t-74.5-.5-64 2-71 6q-9 81-8 136 0 94 2 388t2 455q0 16-2.5 71.5t0 91.5 12.5 69q40 21 124 42.5t120 37.5q5 40 5 50 0 14-3 29l-34 1q-76 2-218-8t-207-10q-50 0-151 9t-152 9q-3-51-3-52v-9q17-27 61.5-43t98.5-29 78-27q19-42 19-383 0-101-3-303t-3-303v-117q0-2 .5-15.5t.5-25-1-25.5-3-24-5-14q-11-12-162-12-33 0-93 12t-80 26q-19 13-34 72.5t-31.5 111-42.5 53.5q-42-26-56-44v-383z\"/> </svg>" |
| 10729 |
|
| 10730 |
/***/ }), |
| 10731 |
|
| 10732 |
/***/ 25974: |
| 10733 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 10734 |
|
| 10735 |
"use strict"; |
| 10736 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 10737 |
/* harmony export */ makeInstance: function() { return /* binding */ makeInstance; } |
| 10738 |
/* harmony export */ }); |
| 10739 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 10740 |
/* harmony import */ var jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(91565); |
| 10741 |
/*! |
| 10742 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 10743 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 10744 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 10745 |
*/ /** |
| 10746 |
* @module plugin |
| 10747 |
*/ |
| 10748 |
|
| 10749 |
/** |
| 10750 |
* Create instance of plugin |
| 10751 |
* @private |
| 10752 |
*/ function makeInstance(jodit, plugin) { |
| 10753 |
try { |
| 10754 |
try { |
| 10755 |
// @ts-ignore |
| 10756 |
return (0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_1__.isFunction)(plugin) ? new plugin(jodit) : plugin; |
| 10757 |
} catch (e) { |
| 10758 |
if ((0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_1__.isFunction)(plugin) && !plugin.prototype) { |
| 10759 |
return plugin(jodit); |
| 10760 |
} |
| 10761 |
} |
| 10762 |
} catch (e) { |
| 10763 |
console.error(e); |
| 10764 |
if (!jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.IS_PROD) { |
| 10765 |
throw e; |
| 10766 |
} |
| 10767 |
} |
| 10768 |
return null; |
| 10769 |
} |
| 10770 |
|
| 10771 |
|
| 10772 |
/***/ }), |
| 10773 |
|
| 10774 |
/***/ 26106: |
| 10775 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 10776 |
|
| 10777 |
"use strict"; |
| 10778 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 10779 |
/* harmony export */ checkJoinNeighbors: function() { return /* binding */ checkJoinNeighbors; } |
| 10780 |
/* harmony export */ }); |
| 10781 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 10782 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(23211); |
| 10783 |
/* harmony import */ var jodit_plugins_backspace_helpers__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(15200); |
| 10784 |
/*! |
| 10785 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 10786 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 10787 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 10788 |
*/ /** |
| 10789 |
* @module plugins/backspace |
| 10790 |
*/ |
| 10791 |
|
| 10792 |
|
| 10793 |
/** |
| 10794 |
* Check if two separate elements can be connected |
| 10795 |
* @private |
| 10796 |
*/ function checkJoinNeighbors(jodit, fakeNode, backspace) { |
| 10797 |
let nextBox = fakeNode, mainClosestBox = nextBox; |
| 10798 |
// Find the main big closest element |
| 10799 |
while(nextBox && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.findNotEmptySibling(nextBox, backspace) && nextBox.parentElement !== jodit.editor){ |
| 10800 |
nextBox = nextBox.parentElement; |
| 10801 |
mainClosestBox = nextBox; |
| 10802 |
} |
| 10803 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isElement(mainClosestBox) && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isContentEditable(mainClosestBox, jodit.editor)) { |
| 10804 |
const sibling = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.findNotEmptySibling(mainClosestBox, backspace); |
| 10805 |
if (sibling && (checkMoveListContent(jodit, mainClosestBox, sibling, backspace) || moveContentAndRemoveEmpty(jodit, mainClosestBox, sibling, backspace))) { |
| 10806 |
jodit.s.setCursorBefore(fakeNode); |
| 10807 |
return true; |
| 10808 |
} |
| 10809 |
} |
| 10810 |
return false; |
| 10811 |
} |
| 10812 |
function checkMoveListContent(jodit, mainClosestBox, sibling, backspace) { |
| 10813 |
// Process UL/LI/OL cases |
| 10814 |
const siblingIsList = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isTag(sibling, jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.LIST_TAGS); |
| 10815 |
const boxIsList = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isTag(mainClosestBox, jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.LIST_TAGS); |
| 10816 |
const elementChild = (elm, side)=>side ? elm.firstElementChild : elm.lastElementChild; |
| 10817 |
if (boxIsList) { |
| 10818 |
sibling = jodit.createInside.element(jodit.o.enterBlock); |
| 10819 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.before(mainClosestBox, sibling); |
| 10820 |
return moveContentAndRemoveEmpty(jodit, elementChild(mainClosestBox, backspace), sibling, backspace); |
| 10821 |
} |
| 10822 |
if (sibling && siblingIsList && !boxIsList) { |
| 10823 |
return moveContentAndRemoveEmpty(jodit, mainClosestBox, elementChild(sibling, !backspace), backspace); |
| 10824 |
} |
| 10825 |
return false; |
| 10826 |
} |
| 10827 |
function moveContentAndRemoveEmpty(jodit, mainClosestBox, sibling, backspace) { |
| 10828 |
// Move content and remove empty nodes |
| 10829 |
if (mainClosestBox && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isElement(sibling)) { |
| 10830 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.moveContent(mainClosestBox, sibling, !backspace, (0,jodit_plugins_backspace_helpers__WEBPACK_IMPORTED_MODULE_2__.getMoveFilter)(jodit)); |
| 10831 |
let remove = mainClosestBox; |
| 10832 |
while(remove && remove !== jodit.editor && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isEmpty(remove)){ |
| 10833 |
const parent = remove.parentElement; |
| 10834 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.safeRemove(remove); |
| 10835 |
remove = parent; |
| 10836 |
} |
| 10837 |
return true; |
| 10838 |
} |
| 10839 |
return false; |
| 10840 |
} |
| 10841 |
|
| 10842 |
|
| 10843 |
/***/ }), |
| 10844 |
|
| 10845 |
/***/ 26136: |
| 10846 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 10847 |
|
| 10848 |
"use strict"; |
| 10849 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 10850 |
/* harmony export */ browser: function() { return /* binding */ browser; } |
| 10851 |
/* harmony export */ }); |
| 10852 |
/*! |
| 10853 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 10854 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 10855 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 10856 |
*/ /** |
| 10857 |
* @module helpers/utils |
| 10858 |
*/ /** |
| 10859 |
* Module returns method that is used to determine the browser |
| 10860 |
* @example |
| 10861 |
* ```javascript |
| 10862 |
* console.log(Jodit.modules.Helpers.browser('mse')); |
| 10863 |
* console.log(Jodit.modules.Helpers.browser('chrome')); |
| 10864 |
* console.log($Jodit.modules.Helpers.browser('opera')); |
| 10865 |
* console.log(Jodit.modules.Helpers.browser('firefox')); |
| 10866 |
* console.log(Jodit.modules.Helpers.browser('mse') && Jodit.modules.Helpers.browser('version') > 10); |
| 10867 |
* ``` |
| 10868 |
*/ const browser = (browser)=>{ |
| 10869 |
const ua = navigator.userAgent.toLowerCase(), match = /(firefox)[\s/]([\w.]+)/.exec(ua) || /(chrome)[\s/]([\w.]+)/.exec(ua) || /(webkit)[\s/]([\w.]+)/.exec(ua) || /(opera)(?:.*version)[\s/]([\w.]+)/.exec(ua) || /(msie)[\s]([\w.]+)/.exec(ua) || /(trident)\/([\w.]+)/.exec(ua) || ua.indexOf('compatible') < 0 || []; |
| 10870 |
if (browser === 'version') { |
| 10871 |
return match[2]; |
| 10872 |
} |
| 10873 |
if (browser === 'webkit') { |
| 10874 |
return match[1] === 'chrome' || match[1] === 'webkit'; |
| 10875 |
} |
| 10876 |
if (browser === 'ff') { |
| 10877 |
return match[1] === 'firefox'; |
| 10878 |
} |
| 10879 |
if (browser === 'msie') { |
| 10880 |
return match[1] === 'trident' || match[1] === 'msie'; |
| 10881 |
} |
| 10882 |
return match[1] === browser; |
| 10883 |
}; |
| 10884 |
|
| 10885 |
|
| 10886 |
/***/ }), |
| 10887 |
|
| 10888 |
/***/ 26633: |
| 10889 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 10890 |
|
| 10891 |
"use strict"; |
| 10892 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 10893 |
/* harmony export */ readAlign: function() { return /* binding */ readAlign; } |
| 10894 |
/* harmony export */ }); |
| 10895 |
/* harmony import */ var jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(80991); |
| 10896 |
/*! |
| 10897 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 10898 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 10899 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 10900 |
*/ /** |
| 10901 |
* @module plugins/image-properties |
| 10902 |
*/ |
| 10903 |
/** |
| 10904 |
* @private |
| 10905 |
*/ function readAlign(image, values) { |
| 10906 |
// Align |
| 10907 |
if (image.style.cssFloat && [ |
| 10908 |
'left', |
| 10909 |
'right' |
| 10910 |
].indexOf(image.style.cssFloat.toLowerCase()) !== -1) { |
| 10911 |
values.align = (0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_0__.css)(image, 'float'); |
| 10912 |
} else { |
| 10913 |
if ((0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_0__.css)(image, 'display') === 'block' && image.style.marginLeft === 'auto' && image.style.marginRight === 'auto') { |
| 10914 |
values.align = 'center'; |
| 10915 |
} else { |
| 10916 |
values.align = ''; |
| 10917 |
} |
| 10918 |
} |
| 10919 |
} |
| 10920 |
|
| 10921 |
|
| 10922 |
/***/ }), |
| 10923 |
|
| 10924 |
/***/ 27137: |
| 10925 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 10926 |
|
| 10927 |
"use strict"; |
| 10928 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 10929 |
/* harmony export */ UIImagePropertiesForm: function() { return /* binding */ UIImagePropertiesForm; } |
| 10930 |
/* harmony export */ }); |
| 10931 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 10932 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 10933 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(84839); |
| 10934 |
/* harmony import */ var jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(91672); |
| 10935 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(65946); |
| 10936 |
/* harmony import */ var jodit_core_ui_group_group__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(63468); |
| 10937 |
/* harmony import */ var jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(29434); |
| 10938 |
/* harmony import */ var jodit_modules_widget__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(15753); |
| 10939 |
/* harmony import */ var _ui_image_main_tab__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(29596); |
| 10940 |
/* harmony import */ var _ui_image_position_tab__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(17306); |
| 10941 |
/*! |
| 10942 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 10943 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 10944 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 10945 |
*/ /** |
| 10946 |
* @module plugins/image-properties |
| 10947 |
*/ |
| 10948 |
|
| 10949 |
|
| 10950 |
|
| 10951 |
|
| 10952 |
|
| 10953 |
|
| 10954 |
|
| 10955 |
|
| 10956 |
|
| 10957 |
|
| 10958 |
class UIImagePropertiesForm extends jodit_core_ui_group_group__WEBPACK_IMPORTED_MODULE_5__.UIGroup { |
| 10959 |
className() { |
| 10960 |
return 'UIImagePropertiesForm'; |
| 10961 |
} |
| 10962 |
appendChildToContainer() {} |
| 10963 |
getElm(elementName) { |
| 10964 |
const selfElm = super.getElm(elementName); |
| 10965 |
if (selfElm) { |
| 10966 |
return selfElm; |
| 10967 |
} |
| 10968 |
for (const child of this.elements){ |
| 10969 |
const elm = child.getElm(elementName); |
| 10970 |
if (elm) { |
| 10971 |
return elm; |
| 10972 |
} |
| 10973 |
} |
| 10974 |
return null; |
| 10975 |
} |
| 10976 |
render() { |
| 10977 |
return `<form> |
| 10978 |
<div class="jodit-grid jodit-grid_xs-column"> |
| 10979 |
<div class="jodit_col-lg-2-5 jodit_col-xs-5-5"> |
| 10980 |
<div class="&__view-box"> |
| 10981 |
<div class="&__imageView"> |
| 10982 |
<img class="&__imageViewSrc" src="" alt=""/> |
| 10983 |
</div> |
| 10984 |
<div class="jodit-form__group &__imageSizes"> |
| 10985 |
<input type="text" class="jodit-input &__imageWidth"/> |
| 10986 |
<a class="&__lockSize">${jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_6__.Icon.get('lock')}</a> |
| 10987 |
<input type="text" class="&__imageHeight jodit-input"/> |
| 10988 |
</div> |
| 10989 |
</div> |
| 10990 |
</div> |
| 10991 |
<div class="jodit_col-lg-3-5 jodit_col-xs-5-5 &__tabsBox"></div> |
| 10992 |
</div> |
| 10993 |
</form>`; |
| 10994 |
} |
| 10995 |
onChangeSizeIsLocked() { |
| 10996 |
const lockSize = this.getElm('lockSize'); |
| 10997 |
const imageWidth = this.getElm('imageWidth'); |
| 10998 |
lockSize.innerHTML = jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_6__.Icon.get(this.state.sizeIsLocked ? 'lock' : 'unlock'); |
| 10999 |
this.setMod('lock-size', this.state.sizeIsLocked); |
| 11000 |
this.j.e.fire(imageWidth, 'change'); |
| 11001 |
} |
| 11002 |
onLockSizeClick() { |
| 11003 |
this.state.sizeIsLocked = !this.state.sizeIsLocked; |
| 11004 |
} |
| 11005 |
onStateValuesSizeChange() { |
| 11006 |
const imageWidth = this.getElm('imageWidth'); |
| 11007 |
const imageHeight = this.getElm('imageHeight'); |
| 11008 |
if (imageWidth !== this.j.od.activeElement) { |
| 11009 |
imageWidth.value = this.state.values.imageWidth.toString(); |
| 11010 |
} |
| 11011 |
if (imageHeight !== this.j.od.activeElement) { |
| 11012 |
imageHeight.value = this.state.values.imageHeight.toString(); |
| 11013 |
} |
| 11014 |
} |
| 11015 |
onImageWidthChange(e) { |
| 11016 |
const imageWidth = this.getElm('imageWidth'); |
| 11017 |
const imageHeight = this.getElm('imageHeight'); |
| 11018 |
if (!this.state.sizeIsLocked || !(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.isNumeric)(imageWidth.value) || !(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.isNumeric)(imageHeight.value)) { |
| 11019 |
this.state.values.imageWidth = imageWidth.value; |
| 11020 |
this.state.values.imageHeight = imageHeight.value; |
| 11021 |
return; |
| 11022 |
} |
| 11023 |
const w = parseFloat(imageWidth.value), h = parseFloat(imageHeight.value); |
| 11024 |
if (e.target === imageWidth) { |
| 11025 |
this.state.values.imageWidth = w; |
| 11026 |
this.state.values.imageHeight = Math.round(w / this.state.ratio); |
| 11027 |
} else { |
| 11028 |
this.state.values.imageWidth = Math.round(h * this.state.ratio); |
| 11029 |
this.state.values.imageHeight = h; |
| 11030 |
} |
| 11031 |
} |
| 11032 |
onStateValuesImageSrcChange() { |
| 11033 |
const { imageSrc } = this.state.values; |
| 11034 |
if (!imageSrc) { |
| 11035 |
return; |
| 11036 |
} |
| 11037 |
const imageViewSrc = this.getElm('imageViewSrc'); |
| 11038 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.attr)(imageViewSrc, 'src', imageSrc); |
| 11039 |
const image = new Image(); |
| 11040 |
image.src = imageSrc; |
| 11041 |
this.state.image = image; |
| 11042 |
} |
| 11043 |
hideFieldByOptions() { |
| 11044 |
const opt = this.j.o.image; |
| 11045 |
[ |
| 11046 |
[ |
| 11047 |
'editSize', |
| 11048 |
'imageSizes' |
| 11049 |
], |
| 11050 |
[ |
| 11051 |
'showPreview', |
| 11052 |
'imageView' |
| 11053 |
] |
| 11054 |
].forEach(([optKey, elmKey])=>{ |
| 11055 |
const elm = this.getElm(elmKey); |
| 11056 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.css)(elm, 'display', opt[optKey] ? null : 'none'); |
| 11057 |
}); |
| 11058 |
} |
| 11059 |
constructor(jodit, state, activeTabState, handlers){ |
| 11060 |
super(jodit), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "state", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "handlers", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__mainTab", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__positionTab", void 0), this.state = state, this.handlers = handlers, this.__mainTab = new _ui_image_main_tab__WEBPACK_IMPORTED_MODULE_8__.UIImageMainTab(this.jodit, this.state, this.handlers), this.__positionTab = new _ui_image_position_tab__WEBPACK_IMPORTED_MODULE_9__.UIImagePositionTab(this.jodit, this.state, this.handlers); |
| 11061 |
this.getElm('tabsBox').appendChild((0,jodit_modules_widget__WEBPACK_IMPORTED_MODULE_7__.TabsWidget)(jodit, [ |
| 11062 |
{ |
| 11063 |
name: 'Image', |
| 11064 |
content: this.__mainTab |
| 11065 |
}, |
| 11066 |
{ |
| 11067 |
name: 'Advanced', |
| 11068 |
content: this.__positionTab |
| 11069 |
} |
| 11070 |
], activeTabState)); |
| 11071 |
this.setMod('lock-size', this.state.sizeIsLocked); |
| 11072 |
this.append(this.__mainTab).append(this.__positionTab); |
| 11073 |
} |
| 11074 |
} |
| 11075 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 11076 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.hook)('ready'), |
| 11077 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.watch)('state.sizeIsLocked') |
| 11078 |
], UIImagePropertiesForm.prototype, "onChangeSizeIsLocked", null); |
| 11079 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 11080 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.watch)('lockSize:click') |
| 11081 |
], UIImagePropertiesForm.prototype, "onLockSizeClick", null); |
| 11082 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 11083 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.hook)('ready'), |
| 11084 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.watch)([ |
| 11085 |
'state.values.imageWidth', |
| 11086 |
'state.values.imageHeight' |
| 11087 |
]) |
| 11088 |
], UIImagePropertiesForm.prototype, "onStateValuesSizeChange", null); |
| 11089 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 11090 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.watch)([ |
| 11091 |
'imageWidth:change', |
| 11092 |
'imageHeight:change', |
| 11093 |
'imageWidth:keydown', |
| 11094 |
'imageHeight:keydown', |
| 11095 |
'imageWidth:mousedown', |
| 11096 |
'imageHeight:mousedown', |
| 11097 |
'imageWidth:paste', |
| 11098 |
'imageHeight:paste' |
| 11099 |
]), |
| 11100 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.debounce)() |
| 11101 |
], UIImagePropertiesForm.prototype, "onImageWidthChange", null); |
| 11102 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 11103 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.hook)('ready'), |
| 11104 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.watch)('state.values.imageSrc') |
| 11105 |
], UIImagePropertiesForm.prototype, "onStateValuesImageSrcChange", null); |
| 11106 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 11107 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.hook)('ready') |
| 11108 |
], UIImagePropertiesForm.prototype, "hideFieldByOptions", null); |
| 11109 |
UIImagePropertiesForm = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 11110 |
jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_3__.component |
| 11111 |
], UIImagePropertiesForm); |
| 11112 |
|
| 11113 |
|
| 11114 |
/***/ }), |
| 11115 |
|
| 11116 |
/***/ 27611: |
| 11117 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 11118 |
|
| 11119 |
"use strict"; |
| 11120 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 11121 |
/* harmony export */ tryRemoveNode: function() { return /* binding */ tryRemoveNode; } |
| 11122 |
/* harmony export */ }); |
| 11123 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 11124 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(23211); |
| 11125 |
/* harmony import */ var jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(4040); |
| 11126 |
/*! |
| 11127 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 11128 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 11129 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 11130 |
*/ /** |
| 11131 |
* @module plugins/clean-html |
| 11132 |
*/ |
| 11133 |
|
| 11134 |
|
| 11135 |
/** |
| 11136 |
* @private |
| 11137 |
*/ function tryRemoveNode(jodit, nodeElm, hadEffect, allowTags, denyTags, currentSelectionNode) { |
| 11138 |
if (isRemovableNode(jodit, nodeElm, currentSelectionNode, allowTags, denyTags)) { |
| 11139 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.safeRemove(nodeElm); |
| 11140 |
return true; |
| 11141 |
} |
| 11142 |
return hadEffect; |
| 11143 |
} |
| 11144 |
/** |
| 11145 |
* @private |
| 11146 |
*/ function isRemovableNode(jodit, node, current, allow, deny) { |
| 11147 |
if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isText(node)) { |
| 11148 |
if (allow && !allow[node.nodeName]) { |
| 11149 |
return true; |
| 11150 |
} |
| 11151 |
if (!allow && deny && deny[node.nodeName]) { |
| 11152 |
return true; |
| 11153 |
} |
| 11154 |
} |
| 11155 |
if (!jodit.o.cleanHTML.removeEmptyElements) { |
| 11156 |
return false; |
| 11157 |
} |
| 11158 |
return jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isElement(node) && node.nodeName.match(jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.IS_INLINE) != null && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isTemporary(node) && (0,jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_2__.trimInv)(node.innerHTML).length === 0 && (current == null || !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isOrContains(node, current)); |
| 11159 |
} |
| 11160 |
|
| 11161 |
|
| 11162 |
/***/ }), |
| 11163 |
|
| 11164 |
/***/ 27795: |
| 11165 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 11166 |
|
| 11167 |
"use strict"; |
| 11168 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 11169 |
/* harmony export */ Dom: function() { return /* reexport safe */ _dom__WEBPACK_IMPORTED_MODULE_0__.Dom; }, |
| 11170 |
/* harmony export */ LazyWalker: function() { return /* reexport safe */ _lazy_walker__WEBPACK_IMPORTED_MODULE_1__.LazyWalker; } |
| 11171 |
/* harmony export */ }); |
| 11172 |
/* harmony import */ var _dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 11173 |
/* harmony import */ var _lazy_walker__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(1080); |
| 11174 |
/*! |
| 11175 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 11176 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 11177 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 11178 |
*/ /** |
| 11179 |
* @module dom |
| 11180 |
*/ |
| 11181 |
|
| 11182 |
|
| 11183 |
|
| 11184 |
/***/ }), |
| 11185 |
|
| 11186 |
/***/ 27978: |
| 11187 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 11188 |
|
| 11189 |
"use strict"; |
| 11190 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 11191 |
/* harmony export */ normalizeKeyAliases: function() { return /* binding */ normalizeKeyAliases; } |
| 11192 |
/* harmony export */ }); |
| 11193 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 11194 |
/* harmony import */ var jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(4040); |
| 11195 |
/*! |
| 11196 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 11197 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 11198 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 11199 |
*/ /** |
| 11200 |
* @module helpers/normalize |
| 11201 |
*/ |
| 11202 |
|
| 11203 |
/** |
| 11204 |
* Normalize keys to some standard name |
| 11205 |
*/ function normalizeKeyAliases(keys) { |
| 11206 |
const memory = {}; |
| 11207 |
const order = { |
| 11208 |
meta: 1, |
| 11209 |
ctrl: 2, |
| 11210 |
control: 2, |
| 11211 |
alt: 3, |
| 11212 |
shift: 4, |
| 11213 |
space: 5 |
| 11214 |
}; |
| 11215 |
return keys.replace(/\+\+/g, '+add').split(/[\s]*\+[\s]*/).map((key)=>(0,jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_1__.trim)(key.toLowerCase())).map((key)=>jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_ALIASES[key] || key).sort((a, b)=>{ |
| 11216 |
if (order[a] && !order[b]) { |
| 11217 |
return -1; |
| 11218 |
} |
| 11219 |
if (!order[a] && order[b]) { |
| 11220 |
return 1; |
| 11221 |
} |
| 11222 |
if (order[a] && order[b]) { |
| 11223 |
return order[a] - order[b]; |
| 11224 |
} |
| 11225 |
return a > b ? 1 : -1; |
| 11226 |
}).filter((key)=>!memory[key] && key !== '' && (memory[key] = true)).join('+'); |
| 11227 |
} |
| 11228 |
|
| 11229 |
|
| 11230 |
/***/ }), |
| 11231 |
|
| 11232 |
/***/ 27987: |
| 11233 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 11234 |
|
| 11235 |
"use strict"; |
| 11236 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 11237 |
/* harmony export */ UISpacer: function() { return /* binding */ UISpacer; } |
| 11238 |
/* harmony export */ }); |
| 11239 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(31635); |
| 11240 |
/* harmony import */ var jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(91672); |
| 11241 |
/* harmony import */ var jodit_core_ui_element__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(96007); |
| 11242 |
|
| 11243 |
/*! |
| 11244 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 11245 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 11246 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 11247 |
*/ /** |
| 11248 |
* @module ui/group |
| 11249 |
*/ |
| 11250 |
|
| 11251 |
class UISpacer extends jodit_core_ui_element__WEBPACK_IMPORTED_MODULE_2__.UIElement { |
| 11252 |
className() { |
| 11253 |
return 'UISpacer'; |
| 11254 |
} |
| 11255 |
} |
| 11256 |
UISpacer = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_0__.__decorate)([ |
| 11257 |
jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_1__.component |
| 11258 |
], UISpacer); |
| 11259 |
|
| 11260 |
|
| 11261 |
/***/ }), |
| 11262 |
|
| 11263 |
/***/ 28077: |
| 11264 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 11265 |
|
| 11266 |
"use strict"; |
| 11267 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 11268 |
/* harmony export */ eventEmitter: function() { return /* binding */ eventEmitter; }, |
| 11269 |
/* harmony export */ extendLang: function() { return /* binding */ extendLang; }, |
| 11270 |
/* harmony export */ getContainer: function() { return /* binding */ getContainer; }, |
| 11271 |
/* harmony export */ getPopupViewRoot: function() { return /* binding */ getPopupViewRoot; }, |
| 11272 |
/* harmony export */ instances: function() { return /* binding */ instances; }, |
| 11273 |
/* harmony export */ modules: function() { return /* binding */ modules; }, |
| 11274 |
/* harmony export */ pluginSystem: function() { return /* binding */ pluginSystem; }, |
| 11275 |
/* harmony export */ uniqueUid: function() { return /* binding */ uniqueUid; } |
| 11276 |
/* harmony export */ }); |
| 11277 |
/* harmony import */ var jodit_core_helpers_checker_is_jodit_object__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(24497); |
| 11278 |
/* harmony import */ var jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(85932); |
| 11279 |
/* harmony import */ var jodit_core_helpers_checker_is_view_object__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(31534); |
| 11280 |
/* harmony import */ var jodit_core_helpers_string_kebab_case__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(74264); |
| 11281 |
/* harmony import */ var jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(80991); |
| 11282 |
/* harmony import */ var jodit_core_helpers_utils_get_class_name__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(421); |
| 11283 |
/* harmony import */ var jodit_core_plugin_plugin_system__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(85305); |
| 11284 |
/* harmony import */ var _event_emitter_global__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(42689); |
| 11285 |
/* harmony import */ var _constants__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(81937); |
| 11286 |
/* harmony import */ var _dom__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(27795); |
| 11287 |
/*! |
| 11288 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 11289 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 11290 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 11291 |
*/ /** |
| 11292 |
* @module global |
| 11293 |
*/ |
| 11294 |
|
| 11295 |
|
| 11296 |
|
| 11297 |
|
| 11298 |
|
| 11299 |
|
| 11300 |
|
| 11301 |
|
| 11302 |
|
| 11303 |
const instances = {}; |
| 11304 |
let counter = 1; |
| 11305 |
const uuids = new Set(); |
| 11306 |
/** |
| 11307 |
* Generate global unique uid |
| 11308 |
*/ function uniqueUid() { |
| 11309 |
function gen() { |
| 11310 |
counter += 10 * (Math.random() + 1); |
| 11311 |
return Math.round(counter).toString(16); |
| 11312 |
} |
| 11313 |
let uid = gen(); |
| 11314 |
while(uuids.has(uid)){ |
| 11315 |
uid = gen(); |
| 11316 |
} |
| 11317 |
uuids.add(uid); |
| 11318 |
return uid; |
| 11319 |
} |
| 11320 |
const pluginSystem = new jodit_core_plugin_plugin_system__WEBPACK_IMPORTED_MODULE_6__.PluginSystem({ |
| 11321 |
getContainer |
| 11322 |
}); |
| 11323 |
const modules = {}; |
| 11324 |
const extendLang = (langs)=>{ |
| 11325 |
Object.keys(langs).forEach((key)=>{ |
| 11326 |
if (_constants__WEBPACK_IMPORTED_MODULE_8__.lang[key]) { |
| 11327 |
Object.assign(_constants__WEBPACK_IMPORTED_MODULE_8__.lang[key], langs[key]); |
| 11328 |
} else { |
| 11329 |
_constants__WEBPACK_IMPORTED_MODULE_8__.lang[key] = langs[key]; |
| 11330 |
} |
| 11331 |
}); |
| 11332 |
}; |
| 11333 |
const boxes = new WeakMap(); |
| 11334 |
/** |
| 11335 |
* Create unique box(HTMLCotainer) and remove it after destroy |
| 11336 |
*/ function getContainer(jodit, classFunc, tag = 'div', createInsideEditor = false) { |
| 11337 |
const name = (0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_1__.isString)(classFunc) ? classFunc : classFunc ? (0,jodit_core_helpers_utils_get_class_name__WEBPACK_IMPORTED_MODULE_5__.getClassName)(classFunc.prototype) : 'jodit-utils'; |
| 11338 |
const data = boxes.get(jodit) || {}, key = name + tag; |
| 11339 |
const view = (0,jodit_core_helpers_checker_is_view_object__WEBPACK_IMPORTED_MODULE_2__.isViewObject)(jodit) ? jodit : jodit.j; |
| 11340 |
let body = null; |
| 11341 |
if (!data[key]) { |
| 11342 |
let c = view.c; |
| 11343 |
body = getPopupViewRoot(view.o, view.container, jodit.od.body); |
| 11344 |
if (createInsideEditor && (0,jodit_core_helpers_checker_is_jodit_object__WEBPACK_IMPORTED_MODULE_0__.isJoditObject)(jodit) && jodit.od !== jodit.ed) { |
| 11345 |
c = jodit.createInside; |
| 11346 |
const place = tag === 'style' ? jodit.ed.head : jodit.ed.body; |
| 11347 |
body = (0,jodit_core_helpers_checker_is_jodit_object__WEBPACK_IMPORTED_MODULE_0__.isJoditObject)(jodit) && jodit.o.shadowRoot ? jodit.o.shadowRoot : place; |
| 11348 |
} |
| 11349 |
const box = c.element(tag, { |
| 11350 |
className: `jodit jodit-${(0,jodit_core_helpers_string_kebab_case__WEBPACK_IMPORTED_MODULE_3__.kebabCase)(name)}-container jodit-box` |
| 11351 |
}); |
| 11352 |
box.classList.add(`jodit_theme_${view.o.theme || 'default'}`); |
| 11353 |
body.appendChild(box); |
| 11354 |
data[key] = box; |
| 11355 |
jodit.hookStatus('beforeDestruct', ()=>{ |
| 11356 |
view.events.off(box); |
| 11357 |
_dom__WEBPACK_IMPORTED_MODULE_9__.Dom.safeRemove(box); |
| 11358 |
delete data[key]; |
| 11359 |
if (Object.keys(data).length) { |
| 11360 |
boxes.delete(jodit); |
| 11361 |
} |
| 11362 |
}); |
| 11363 |
boxes.set(jodit, data); |
| 11364 |
view.events.fire('getContainer', box); |
| 11365 |
} |
| 11366 |
data[key].classList.remove('jodit_theme_default', 'jodit_theme_dark'); |
| 11367 |
data[key].classList.add(`jodit_theme_${view.o.theme || 'default'}`); |
| 11368 |
return data[key]; |
| 11369 |
} |
| 11370 |
/** |
| 11371 |
* Get root element for view |
| 11372 |
* @internal |
| 11373 |
*/ function getPopupViewRoot(o, container, defaultRoot) { |
| 11374 |
var _ref, _ref1, _o_popupRoot; |
| 11375 |
return (_ref = (_ref1 = (_o_popupRoot = o.popupRoot) !== null && _o_popupRoot !== void 0 ? _o_popupRoot : o.shadowRoot) !== null && _ref1 !== void 0 ? _ref1 : _dom__WEBPACK_IMPORTED_MODULE_9__.Dom.closest(container, (parentElement)=>_dom__WEBPACK_IMPORTED_MODULE_9__.Dom.isHTMLElement(parentElement) && (_dom__WEBPACK_IMPORTED_MODULE_9__.Dom.isTag(parentElement, 'dialog') || [ |
| 11376 |
'fixed', |
| 11377 |
'absolute' |
| 11378 |
].includes((0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_4__.css)(parentElement, 'position'))), defaultRoot)) !== null && _ref !== void 0 ? _ref : defaultRoot; |
| 11379 |
} |
| 11380 |
/** |
| 11381 |
* Global event emitter |
| 11382 |
* @deprecated use `import { eventEmitter } from 'jodit/core/event-emitter/global';` |
| 11383 |
*/ const eventEmitter = _event_emitter_global__WEBPACK_IMPORTED_MODULE_7__.eventEmitter; |
| 11384 |
|
| 11385 |
|
| 11386 |
/***/ }), |
| 11387 |
|
| 11388 |
/***/ 28286: |
| 11389 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 11390 |
|
| 11391 |
"use strict"; |
| 11392 |
/* unused harmony export backspace */ |
| 11393 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 11394 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(81937); |
| 11395 |
/* harmony import */ var jodit_core_dom__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(27795); |
| 11396 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(28077); |
| 11397 |
/* harmony import */ var jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(91565); |
| 11398 |
/* harmony import */ var jodit_core_plugin__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(91206); |
| 11399 |
/* harmony import */ var jodit_core_selection_helpers__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(42259); |
| 11400 |
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(33831); |
| 11401 |
/* harmony import */ var _cases_check_not_collapsed__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(89827); |
| 11402 |
/* harmony import */ var _cases__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(17523); |
| 11403 |
/*! |
| 11404 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 11405 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 11406 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 11407 |
*/ /** |
| 11408 |
* [[include:plugins/backspace/README.md]] |
| 11409 |
* @packageDocumentation |
| 11410 |
* @module plugins/backspace |
| 11411 |
*/ |
| 11412 |
|
| 11413 |
|
| 11414 |
|
| 11415 |
|
| 11416 |
|
| 11417 |
|
| 11418 |
|
| 11419 |
|
| 11420 |
|
| 11421 |
class backspace extends jodit_core_plugin__WEBPACK_IMPORTED_MODULE_5__.Plugin { |
| 11422 |
afterInit(jodit) { |
| 11423 |
jodit.registerCommand('deleteButton', { |
| 11424 |
exec: ()=>this.onDelete(false), |
| 11425 |
hotkeys: jodit.o.delete.hotkeys.delete |
| 11426 |
}, { |
| 11427 |
stopPropagation: false |
| 11428 |
}).registerCommand('backspaceButton', { |
| 11429 |
exec: ()=>this.onDelete(true), |
| 11430 |
hotkeys: jodit.o.delete.hotkeys.backspace |
| 11431 |
}, { |
| 11432 |
stopPropagation: false |
| 11433 |
}).registerCommand('deleteWordButton', { |
| 11434 |
exec: ()=>this.onDelete(false, 'word'), |
| 11435 |
hotkeys: jodit.o.delete.hotkeys.deleteWord |
| 11436 |
}).registerCommand('backspaceWordButton', { |
| 11437 |
exec: ()=>this.onDelete(true, 'word'), |
| 11438 |
hotkeys: jodit.o.delete.hotkeys.backspaceWord |
| 11439 |
}).registerCommand('deleteSentenceButton', { |
| 11440 |
exec: ()=>this.onDelete(false, 'sentence'), |
| 11441 |
hotkeys: jodit.o.delete.hotkeys.deleteSentence |
| 11442 |
}).registerCommand('backspaceSentenceButton', { |
| 11443 |
exec: ()=>this.onDelete(true, 'sentence'), |
| 11444 |
hotkeys: jodit.o.delete.hotkeys.backspaceSentence |
| 11445 |
}); |
| 11446 |
} |
| 11447 |
beforeDestruct(jodit) { |
| 11448 |
jodit.e.off('afterCommand.delete'); |
| 11449 |
} |
| 11450 |
/** |
| 11451 |
* Listener BackSpace or Delete button |
| 11452 |
*/ onDelete(backspace, mode = 'char') { |
| 11453 |
const jodit = this.j; |
| 11454 |
const sel = jodit.selection; |
| 11455 |
if (!sel.isFocused()) { |
| 11456 |
sel.focus(); |
| 11457 |
} |
| 11458 |
if ((0,_cases_check_not_collapsed__WEBPACK_IMPORTED_MODULE_8__.checkNotCollapsed)(jodit)) { |
| 11459 |
return false; |
| 11460 |
} |
| 11461 |
const range = sel.range; |
| 11462 |
const fakeNode = jodit.createInside.text(jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.INVISIBLE_SPACE); |
| 11463 |
try { |
| 11464 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_2__.Dom.safeInsertNode(range, fakeNode); |
| 11465 |
if (!jodit_core_dom__WEBPACK_IMPORTED_MODULE_2__.Dom.isOrContains(jodit.editor, fakeNode)) { |
| 11466 |
return; |
| 11467 |
} |
| 11468 |
if (jodit.e.fire('backSpaceBeforeCases', backspace, fakeNode)) { |
| 11469 |
return false; |
| 11470 |
} |
| 11471 |
(0,jodit_core_selection_helpers__WEBPACK_IMPORTED_MODULE_6__.moveNodeInsideStart)(jodit, fakeNode, backspace); |
| 11472 |
if (_cases__WEBPACK_IMPORTED_MODULE_9__.cases.some((func)=>{ |
| 11473 |
if ((0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_4__.isFunction)(func) && func(jodit, fakeNode, backspace, mode)) { |
| 11474 |
if (!jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.IS_PROD) { |
| 11475 |
console.info('Remove case:', func.name); |
| 11476 |
} |
| 11477 |
return true; |
| 11478 |
} |
| 11479 |
})) { |
| 11480 |
return false; |
| 11481 |
} |
| 11482 |
} catch (e) { |
| 11483 |
if (!jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.IS_PROD) { |
| 11484 |
console.error(e); |
| 11485 |
} |
| 11486 |
throw e; |
| 11487 |
} finally{ |
| 11488 |
jodit.e.fire('backSpaceAfterDelete', backspace, fakeNode); |
| 11489 |
this.safeRemoveEmptyNode(fakeNode); |
| 11490 |
} |
| 11491 |
return false; |
| 11492 |
} |
| 11493 |
/** |
| 11494 |
* Remove node and replace cursor position out of it |
| 11495 |
*/ safeRemoveEmptyNode(fakeNode) { |
| 11496 |
const { range } = this.j.s; |
| 11497 |
if (range.startContainer === fakeNode) { |
| 11498 |
if (fakeNode.previousSibling) { |
| 11499 |
if (jodit_core_dom__WEBPACK_IMPORTED_MODULE_2__.Dom.isText(fakeNode.previousSibling)) { |
| 11500 |
var _ref; |
| 11501 |
var _fakeNode_previousSibling_nodeValue; |
| 11502 |
range.setStart(fakeNode.previousSibling, (_ref = (_fakeNode_previousSibling_nodeValue = fakeNode.previousSibling.nodeValue) === null || _fakeNode_previousSibling_nodeValue === void 0 ? void 0 : _fakeNode_previousSibling_nodeValue.length) !== null && _ref !== void 0 ? _ref : 0); |
| 11503 |
} else { |
| 11504 |
range.setStartAfter(fakeNode.previousSibling); |
| 11505 |
} |
| 11506 |
} else if (fakeNode.nextSibling) { |
| 11507 |
if (jodit_core_dom__WEBPACK_IMPORTED_MODULE_2__.Dom.isText(fakeNode.nextSibling)) { |
| 11508 |
range.setStart(fakeNode.nextSibling, 0); |
| 11509 |
} else { |
| 11510 |
range.setStartBefore(fakeNode.nextSibling); |
| 11511 |
} |
| 11512 |
} |
| 11513 |
range.collapse(true); |
| 11514 |
this.j.s.selectRange(range); |
| 11515 |
} |
| 11516 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_2__.Dom.safeRemove(fakeNode); |
| 11517 |
} |
| 11518 |
} |
| 11519 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(backspace, "requires", [ |
| 11520 |
'hotkeys' |
| 11521 |
]); |
| 11522 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_3__.pluginSystem.add('backspace', backspace); |
| 11523 |
|
| 11524 |
|
| 11525 |
/***/ }), |
| 11526 |
|
| 11527 |
/***/ 28686: |
| 11528 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 11529 |
|
| 11530 |
"use strict"; |
| 11531 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 11532 |
/* harmony export */ hasBrowserColorPicker: function() { return /* reexport safe */ _has_browser_color_picker__WEBPACK_IMPORTED_MODULE_0__.hasBrowserColorPicker; }, |
| 11533 |
/* harmony export */ hasContainer: function() { return /* reexport safe */ _is_imp_interface__WEBPACK_IMPORTED_MODULE_8__.hasContainer; }, |
| 11534 |
/* harmony export */ isAbortError: function() { return /* reexport safe */ _is_abort_error__WEBPACK_IMPORTED_MODULE_1__.isAbortError; }, |
| 11535 |
/* harmony export */ isArray: function() { return /* reexport safe */ _is_array__WEBPACK_IMPORTED_MODULE_2__.isArray; }, |
| 11536 |
/* harmony export */ isBoolean: function() { return /* reexport safe */ _is_boolean__WEBPACK_IMPORTED_MODULE_3__.isBoolean; }, |
| 11537 |
/* harmony export */ isDestructable: function() { return /* reexport safe */ _is_imp_interface__WEBPACK_IMPORTED_MODULE_8__.isDestructable; }, |
| 11538 |
/* harmony export */ isEqual: function() { return /* reexport safe */ _is_equal__WEBPACK_IMPORTED_MODULE_4__.isEqual; }, |
| 11539 |
/* harmony export */ isFastEqual: function() { return /* reexport safe */ _is_equal__WEBPACK_IMPORTED_MODULE_4__.isFastEqual; }, |
| 11540 |
/* harmony export */ isFunction: function() { return /* reexport safe */ _is_function__WEBPACK_IMPORTED_MODULE_5__.isFunction; }, |
| 11541 |
/* harmony export */ isHTML: function() { return /* reexport safe */ _is_html__WEBPACK_IMPORTED_MODULE_6__.isHTML; }, |
| 11542 |
/* harmony export */ isHtmlFromWord: function() { return /* reexport safe */ _is_html_from_word__WEBPACK_IMPORTED_MODULE_7__.isHtmlFromWord; }, |
| 11543 |
/* harmony export */ isInitable: function() { return /* reexport safe */ _is_imp_interface__WEBPACK_IMPORTED_MODULE_8__.isInitable; }, |
| 11544 |
/* harmony export */ isInt: function() { return /* reexport safe */ _is_int__WEBPACK_IMPORTED_MODULE_9__.isInt; }, |
| 11545 |
/* harmony export */ isJoditObject: function() { return /* reexport safe */ _is_jodit_object__WEBPACK_IMPORTED_MODULE_10__.isJoditObject; }, |
| 11546 |
/* harmony export */ isLicense: function() { return /* reexport safe */ _is_license__WEBPACK_IMPORTED_MODULE_11__.isLicense; }, |
| 11547 |
/* harmony export */ isMarker: function() { return /* reexport safe */ _is_marker__WEBPACK_IMPORTED_MODULE_12__.isMarker; }, |
| 11548 |
/* harmony export */ isNativeFunction: function() { return /* reexport safe */ _is_native_function__WEBPACK_IMPORTED_MODULE_13__.isNativeFunction; }, |
| 11549 |
/* harmony export */ isNumber: function() { return /* reexport safe */ _is_number__WEBPACK_IMPORTED_MODULE_14__.isNumber; }, |
| 11550 |
/* harmony export */ isNumeric: function() { return /* reexport safe */ _is_numeric__WEBPACK_IMPORTED_MODULE_15__.isNumeric; }, |
| 11551 |
/* harmony export */ isPlainObject: function() { return /* reexport safe */ _is_plain_object__WEBPACK_IMPORTED_MODULE_16__.isPlainObject; }, |
| 11552 |
/* harmony export */ isPromise: function() { return /* reexport safe */ _is_promise__WEBPACK_IMPORTED_MODULE_17__.isPromise; }, |
| 11553 |
/* harmony export */ isSet: function() { return /* reexport safe */ _is_set__WEBPACK_IMPORTED_MODULE_18__.isSet; }, |
| 11554 |
/* harmony export */ isString: function() { return /* reexport safe */ _is_string__WEBPACK_IMPORTED_MODULE_19__.isString; }, |
| 11555 |
/* harmony export */ isStringArray: function() { return /* reexport safe */ _is_string__WEBPACK_IMPORTED_MODULE_19__.isStringArray; }, |
| 11556 |
/* harmony export */ isURL: function() { return /* reexport safe */ _is_url__WEBPACK_IMPORTED_MODULE_20__.isURL; }, |
| 11557 |
/* harmony export */ isValidName: function() { return /* reexport safe */ _is_valid_name__WEBPACK_IMPORTED_MODULE_21__.isValidName; }, |
| 11558 |
/* harmony export */ isViewObject: function() { return /* reexport safe */ _is_view_object__WEBPACK_IMPORTED_MODULE_22__.isViewObject; }, |
| 11559 |
/* harmony export */ isVoid: function() { return /* reexport safe */ _is_void__WEBPACK_IMPORTED_MODULE_23__.isVoid; }, |
| 11560 |
/* harmony export */ isWindow: function() { return /* reexport safe */ _is_window__WEBPACK_IMPORTED_MODULE_24__.isWindow; } |
| 11561 |
/* harmony export */ }); |
| 11562 |
/* harmony import */ var _has_browser_color_picker__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(98740); |
| 11563 |
/* harmony import */ var _is_abort_error__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(72068); |
| 11564 |
/* harmony import */ var _is_array__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(17312); |
| 11565 |
/* harmony import */ var _is_boolean__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(22289); |
| 11566 |
/* harmony import */ var _is_equal__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(94013); |
| 11567 |
/* harmony import */ var _is_function__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(91565); |
| 11568 |
/* harmony import */ var _is_html__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(46248); |
| 11569 |
/* harmony import */ var _is_html_from_word__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(82166); |
| 11570 |
/* harmony import */ var _is_imp_interface__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(52433); |
| 11571 |
/* harmony import */ var _is_int__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(99732); |
| 11572 |
/* harmony import */ var _is_jodit_object__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(24497); |
| 11573 |
/* harmony import */ var _is_license__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(44998); |
| 11574 |
/* harmony import */ var _is_marker__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(23175); |
| 11575 |
/* harmony import */ var _is_native_function__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(23283); |
| 11576 |
/* harmony import */ var _is_number__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(72412); |
| 11577 |
/* harmony import */ var _is_numeric__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(70222); |
| 11578 |
/* harmony import */ var _is_plain_object__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(62101); |
| 11579 |
/* harmony import */ var _is_promise__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(52100); |
| 11580 |
/* harmony import */ var _is_set__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(3213); |
| 11581 |
/* harmony import */ var _is_string__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(85932); |
| 11582 |
/* harmony import */ var _is_url__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(91764); |
| 11583 |
/* harmony import */ var _is_valid_name__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(50083); |
| 11584 |
/* harmony import */ var _is_view_object__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(31534); |
| 11585 |
/* harmony import */ var _is_void__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__(18303); |
| 11586 |
/* harmony import */ var _is_window__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__(3513); |
| 11587 |
/*! |
| 11588 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 11589 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 11590 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 11591 |
*/ /** |
| 11592 |
* @module helpers/checker |
| 11593 |
*/ |
| 11594 |
|
| 11595 |
|
| 11596 |
|
| 11597 |
|
| 11598 |
|
| 11599 |
|
| 11600 |
|
| 11601 |
|
| 11602 |
|
| 11603 |
|
| 11604 |
|
| 11605 |
|
| 11606 |
|
| 11607 |
|
| 11608 |
|
| 11609 |
|
| 11610 |
|
| 11611 |
|
| 11612 |
|
| 11613 |
|
| 11614 |
|
| 11615 |
|
| 11616 |
|
| 11617 |
|
| 11618 |
|
| 11619 |
|
| 11620 |
/***/ }), |
| 11621 |
|
| 11622 |
/***/ 28712: |
| 11623 |
/***/ (function(module) { |
| 11624 |
|
| 11625 |
"use strict"; |
| 11626 |
module.exports = {assert(){}};; |
| 11627 |
|
| 11628 |
/***/ }), |
| 11629 |
|
| 11630 |
/***/ 28723: |
| 11631 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 11632 |
|
| 11633 |
"use strict"; |
| 11634 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 11635 |
/* harmony export */ $$: function() { return /* binding */ $$; }, |
| 11636 |
/* harmony export */ cssPath: function() { return /* binding */ cssPath; }, |
| 11637 |
/* harmony export */ getXPathByElement: function() { return /* binding */ getXPathByElement; }, |
| 11638 |
/* harmony export */ refs: function() { return /* binding */ refs; }, |
| 11639 |
/* harmony export */ resolveElement: function() { return /* binding */ resolveElement; } |
| 11640 |
/* harmony export */ }); |
| 11641 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 11642 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(23211); |
| 11643 |
/* harmony import */ var jodit_core_helpers_array_to_array__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(88475); |
| 11644 |
/* harmony import */ var jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(85932); |
| 11645 |
/* harmony import */ var jodit_core_helpers_string_camel_case__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(57821); |
| 11646 |
/* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(7909); |
| 11647 |
/* harmony import */ var jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(33201); |
| 11648 |
/*! |
| 11649 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 11650 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 11651 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 11652 |
*/ /** |
| 11653 |
* @module helpers/utils |
| 11654 |
*/ |
| 11655 |
|
| 11656 |
|
| 11657 |
|
| 11658 |
|
| 11659 |
|
| 11660 |
|
| 11661 |
let temp = 1; |
| 11662 |
const $$temp = ()=>{ |
| 11663 |
temp++; |
| 11664 |
return temp; |
| 11665 |
}; |
| 11666 |
/** |
| 11667 |
* @deprecated Do not use it in new code |
| 11668 |
*/ function $$(selector, root) { |
| 11669 |
let result; |
| 11670 |
if (!jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.IS_ES_NEXT && /:scope/.test(selector) && jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.IS_IE && !(root && root.nodeType === Node.DOCUMENT_NODE)) { |
| 11671 |
const id = root.id, temp_id = id || '_selector_id_' + String(Math.random()).slice(2) + $$temp(); |
| 11672 |
selector = selector.replace(/:scope/g, '#' + temp_id); |
| 11673 |
!id && root.setAttribute('id', temp_id); |
| 11674 |
result = root.parentNode.querySelectorAll(selector); |
| 11675 |
if (!id) { |
| 11676 |
root.removeAttribute('id'); |
| 11677 |
} |
| 11678 |
} else { |
| 11679 |
result = root.querySelectorAll(selector); |
| 11680 |
} |
| 11681 |
return [].slice.call(result); |
| 11682 |
} |
| 11683 |
/** |
| 11684 |
* Calculate XPath selector |
| 11685 |
*/ const getXPathByElement = (element, root)=>{ |
| 11686 |
if (!element || element.nodeType !== Node.ELEMENT_NODE) { |
| 11687 |
return ''; |
| 11688 |
} |
| 11689 |
if (!element.parentNode || root === element) { |
| 11690 |
return ''; |
| 11691 |
} |
| 11692 |
if (element.id) { |
| 11693 |
return "//*[@id='" + element.id + "']"; |
| 11694 |
} |
| 11695 |
const sames = [].filter.call(element.parentNode.childNodes, (x)=>x.nodeName === element.nodeName); |
| 11696 |
return getXPathByElement(element.parentNode, root) + '/' + element.nodeName.toLowerCase() + (sames.length > 1 ? '[' + ((0,jodit_core_helpers_array_to_array__WEBPACK_IMPORTED_MODULE_2__.toArray)(sames).indexOf(element) + 1) + ']' : ''); |
| 11697 |
}; |
| 11698 |
/** |
| 11699 |
* Find all `ref` or `data-ref` elements inside HTMLElement |
| 11700 |
*/ const refs = (root)=>{ |
| 11701 |
if ('container' in root) { |
| 11702 |
root = root.container; |
| 11703 |
} |
| 11704 |
return $$('[ref],[data-ref]', root).reduce((def, child)=>{ |
| 11705 |
const key = (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_5__.attr)(child, '-ref'); |
| 11706 |
if (key && (0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_3__.isString)(key)) { |
| 11707 |
def[(0,jodit_core_helpers_string_camel_case__WEBPACK_IMPORTED_MODULE_4__.camelCase)(key)] = child; |
| 11708 |
def[key] = child; |
| 11709 |
} |
| 11710 |
return def; |
| 11711 |
}, {}); |
| 11712 |
}; |
| 11713 |
/** |
| 11714 |
* Calculate full CSS selector |
| 11715 |
*/ const cssPath = (el)=>{ |
| 11716 |
if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isElement(el)) { |
| 11717 |
return null; |
| 11718 |
} |
| 11719 |
const path = []; |
| 11720 |
let start = el; |
| 11721 |
while(start && start.nodeType === Node.ELEMENT_NODE){ |
| 11722 |
let selector = start.nodeName.toLowerCase(); |
| 11723 |
if (start.id) { |
| 11724 |
selector += '#' + start.id; |
| 11725 |
path.unshift(selector); |
| 11726 |
break; |
| 11727 |
} else { |
| 11728 |
let sib = start, nth = 1; |
| 11729 |
do { |
| 11730 |
sib = sib.previousElementSibling; |
| 11731 |
if (sib && sib.nodeName.toLowerCase() === selector) { |
| 11732 |
nth++; |
| 11733 |
} |
| 11734 |
}while (sib) |
| 11735 |
selector += ':nth-of-type(' + nth + ')'; |
| 11736 |
} |
| 11737 |
path.unshift(selector); |
| 11738 |
start = start.parentNode; |
| 11739 |
} |
| 11740 |
return path.join(' > '); |
| 11741 |
}; |
| 11742 |
/** |
| 11743 |
* Try to find element by selector |
| 11744 |
*/ function resolveElement(element, od) { |
| 11745 |
let resolved = element; |
| 11746 |
if ((0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_3__.isString)(element)) { |
| 11747 |
try { |
| 11748 |
resolved = od.querySelector(element); |
| 11749 |
} catch (unused) { |
| 11750 |
throw (0,jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_6__.error)('String "' + element + '" should be valid HTML selector'); |
| 11751 |
} |
| 11752 |
} |
| 11753 |
// Duck checking |
| 11754 |
if (!resolved || typeof resolved !== 'object' || !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isElement(resolved) || !resolved.cloneNode) { |
| 11755 |
throw (0,jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_6__.error)('Element "' + element + '" should be string or HTMLElement instance'); |
| 11756 |
} |
| 11757 |
return resolved; |
| 11758 |
} |
| 11759 |
|
| 11760 |
|
| 11761 |
/***/ }), |
| 11762 |
|
| 11763 |
/***/ 28771: |
| 11764 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 11765 |
|
| 11766 |
"use strict"; |
| 11767 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 11768 |
/* harmony export */ openImageEditorDialog: function() { return /* binding */ openImageEditorDialog; } |
| 11769 |
/* harmony export */ }); |
| 11770 |
/* harmony import */ var jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(85932); |
| 11771 |
/* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(7909); |
| 11772 |
/* harmony import */ var jodit_modules_image_editor_image_editor__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(43271); |
| 11773 |
/*! |
| 11774 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 11775 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 11776 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 11777 |
*/ /** |
| 11778 |
* @module plugins/image-properties |
| 11779 |
*/ |
| 11780 |
|
| 11781 |
|
| 11782 |
/** |
| 11783 |
* Open image editor dialog |
| 11784 |
* @private |
| 11785 |
*/ function openImageEditorDialog(j, state) { |
| 11786 |
const url = (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(state.image, 'src') || '', a = j.c.element('a'), loadExternal = ()=>{ |
| 11787 |
if (a.host !== location.host) { |
| 11788 |
j.confirm('You can only edit your own images. Download this image on the host?', (yes)=>{ |
| 11789 |
if (yes && j.uploader) { |
| 11790 |
j.uploader.uploadRemoteImage(a.href.toString(), (resp)=>{ |
| 11791 |
j.alert('The image has been successfully uploaded to the host!', ()=>{ |
| 11792 |
if ((0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_0__.isString)(resp.newfilename)) { |
| 11793 |
state.values.imageSrc = resp.baseurl + resp.newfilename; |
| 11794 |
} |
| 11795 |
}); |
| 11796 |
}, (error)=>{ |
| 11797 |
j.alert('There was an error loading %s', error.message); |
| 11798 |
}); |
| 11799 |
} |
| 11800 |
}); |
| 11801 |
return; |
| 11802 |
} |
| 11803 |
}; |
| 11804 |
a.href = url; |
| 11805 |
j.filebrowser.dataProvider.getPathByUrl(a.href.toString()).then((resp)=>{ |
| 11806 |
jodit_modules_image_editor_image_editor__WEBPACK_IMPORTED_MODULE_2__.openImageEditor.call(j.filebrowser, a.href, resp.name, resp.path, resp.source, ()=>{ |
| 11807 |
const timestamp = new Date().getTime(); |
| 11808 |
state.values.imageSrc = url + (url.indexOf('?') !== -1 ? '' : '?') + '&_tmp=' + timestamp.toString(); |
| 11809 |
}, (error)=>{ |
| 11810 |
j.alert(error.message); |
| 11811 |
}); |
| 11812 |
}).catch((error)=>{ |
| 11813 |
j.alert(error.message, loadExternal); |
| 11814 |
}); |
| 11815 |
} |
| 11816 |
|
| 11817 |
|
| 11818 |
/***/ }), |
| 11819 |
|
| 11820 |
/***/ 29200: |
| 11821 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 11822 |
|
| 11823 |
"use strict"; |
| 11824 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 11825 |
/* harmony export */ hook: function() { return /* binding */ hook; } |
| 11826 |
/* harmony export */ }); |
| 11827 |
/* harmony import */ var jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(91565); |
| 11828 |
/* harmony import */ var jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(33201); |
| 11829 |
/*! |
| 11830 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 11831 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 11832 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 11833 |
*/ /** |
| 11834 |
* [[include:core/decorators/hook/README.md]] |
| 11835 |
* @packageDocumentation |
| 11836 |
* @module decorators/hook |
| 11837 |
*/ |
| 11838 |
|
| 11839 |
/** |
| 11840 |
* Call on some component status |
| 11841 |
*/ function hook(status) { |
| 11842 |
return (target, propertyKey)=>{ |
| 11843 |
if (!(0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_0__.isFunction)(target[propertyKey])) { |
| 11844 |
throw (0,jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_1__.error)('Handler must be a Function'); |
| 11845 |
} |
| 11846 |
target.hookStatus(status, (component)=>{ |
| 11847 |
component[propertyKey].call(component); |
| 11848 |
}); |
| 11849 |
}; |
| 11850 |
} |
| 11851 |
|
| 11852 |
|
| 11853 |
/***/ }), |
| 11854 |
|
| 11855 |
/***/ 29348: |
| 11856 |
/***/ (function(module) { |
| 11857 |
|
| 11858 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"><path d=\"M1534 189v73q0 29-18.5 61t-42.5 32q-50 0-54 1-26 6-32 31-3 11-3 64v1152q0 25-18 43t-43 18h-108q-25 0-43-18t-18-43v-1218h-143v1218q0 25-17.5 43t-43.5 18h-108q-26 0-43.5-18t-17.5-43v-496q-147-12-245-59-126-58-192-179-64-117-64-259 0-166 88-286 88-118 209-159 111-37 417-37h479q25 0 43 18t18 43z\"/></svg>" |
| 11859 |
|
| 11860 |
/***/ }), |
| 11861 |
|
| 11862 |
/***/ 29433: |
| 11863 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 11864 |
|
| 11865 |
"use strict"; |
| 11866 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 11867 |
/* harmony export */ StatusBar: function() { return /* binding */ StatusBar; } |
| 11868 |
/* harmony export */ }); |
| 11869 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 11870 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 11871 |
/* harmony import */ var jodit_core_component__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(16964); |
| 11872 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(84839); |
| 11873 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(23211); |
| 11874 |
/* harmony import */ var jodit_core_traits_elms__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(23183); |
| 11875 |
/* harmony import */ var jodit_core_traits_mods__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(81987); |
| 11876 |
/*! |
| 11877 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 11878 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 11879 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 11880 |
*/ /** |
| 11881 |
* [[include:modules/status-bar/README.md]] |
| 11882 |
* @packageDocumentation |
| 11883 |
* @module modules/status-bar |
| 11884 |
*/ |
| 11885 |
|
| 11886 |
|
| 11887 |
|
| 11888 |
|
| 11889 |
|
| 11890 |
|
| 11891 |
|
| 11892 |
class StatusBar extends jodit_core_component__WEBPACK_IMPORTED_MODULE_2__.ViewComponent { |
| 11893 |
className() { |
| 11894 |
return 'StatusBar'; |
| 11895 |
} |
| 11896 |
/** |
| 11897 |
* Hide statusbar |
| 11898 |
*/ hide() { |
| 11899 |
this.container.classList.add('jodit_hidden'); |
| 11900 |
} |
| 11901 |
/** |
| 11902 |
* Show statusbar |
| 11903 |
*/ show() { |
| 11904 |
this.container.classList.remove('jodit_hidden'); |
| 11905 |
} |
| 11906 |
/** |
| 11907 |
* Status bar is shown |
| 11908 |
*/ get isShown() { |
| 11909 |
return !this.container.classList.contains('jodit_hidden'); |
| 11910 |
} |
| 11911 |
/** |
| 11912 |
* Height of statusbar |
| 11913 |
*/ getHeight() { |
| 11914 |
var _ref; |
| 11915 |
var _this_container; |
| 11916 |
return (_ref = (_this_container = this.container) === null || _this_container === void 0 ? void 0 : _this_container.offsetHeight) !== null && _ref !== void 0 ? _ref : 0; |
| 11917 |
} |
| 11918 |
findEmpty(inTheRight = false) { |
| 11919 |
const items = this.getElms(inTheRight ? 'item-right' : 'item'); |
| 11920 |
for(let i = 0; i < items.length; i += 1){ |
| 11921 |
if (!items[i].innerHTML.trim().length) { |
| 11922 |
return items[i]; |
| 11923 |
} |
| 11924 |
} |
| 11925 |
return; |
| 11926 |
} |
| 11927 |
/** |
| 11928 |
* Add element in statusbar |
| 11929 |
*/ append(child, inTheRight = false) { |
| 11930 |
var _this_container; |
| 11931 |
const wrapper = this.findEmpty(inTheRight) || this.j.c.div(this.getFullElName('item')); |
| 11932 |
if (inTheRight) { |
| 11933 |
wrapper.classList.add(this.getFullElName('item-right')); |
| 11934 |
} |
| 11935 |
wrapper.appendChild(child); |
| 11936 |
(_this_container = this.container) === null || _this_container === void 0 ? void 0 : _this_container.appendChild(wrapper); |
| 11937 |
if (this.j.o.statusbar) { |
| 11938 |
this.show(); |
| 11939 |
} |
| 11940 |
this.j.e.fire('resize'); |
| 11941 |
} |
| 11942 |
destruct() { |
| 11943 |
if (this.isInDestruct) { |
| 11944 |
return; |
| 11945 |
} |
| 11946 |
this.setStatus(jodit_core_component__WEBPACK_IMPORTED_MODULE_2__.STATUSES.beforeDestruct); |
| 11947 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeRemove(this.container); |
| 11948 |
super.destruct(); |
| 11949 |
} |
| 11950 |
constructor(jodit, target){ |
| 11951 |
super(jodit), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "target", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "container", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "mods", void 0), this.target = target, this.mods = {}; |
| 11952 |
this.container = jodit.c.div('jodit-status-bar'); |
| 11953 |
target.appendChild(this.container); |
| 11954 |
this.hide(); |
| 11955 |
} |
| 11956 |
} |
| 11957 |
StatusBar = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 11958 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.component, |
| 11959 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.derive)(jodit_core_traits_mods__WEBPACK_IMPORTED_MODULE_6__.Mods, jodit_core_traits_elms__WEBPACK_IMPORTED_MODULE_5__.Elms) |
| 11960 |
], StatusBar); |
| 11961 |
|
| 11962 |
|
| 11963 |
/***/ }), |
| 11964 |
|
| 11965 |
/***/ 29434: |
| 11966 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 11967 |
|
| 11968 |
"use strict"; |
| 11969 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 11970 |
/* harmony export */ Icon: function() { return /* binding */ Icon; } |
| 11971 |
/* harmony export */ }); |
| 11972 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 11973 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(81937); |
| 11974 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(65946); |
| 11975 |
/* harmony import */ var jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(80991); |
| 11976 |
/*! |
| 11977 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 11978 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 11979 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 11980 |
*/ /** |
| 11981 |
* @module ui |
| 11982 |
*/ |
| 11983 |
|
| 11984 |
|
| 11985 |
|
| 11986 |
class Icon { |
| 11987 |
static getIcon(name) { |
| 11988 |
if (/<svg/i.test(name)) { |
| 11989 |
return name; |
| 11990 |
} |
| 11991 |
const icon = Icon.icons[name] || Icon.icons[name.replace(/-/g, '_')] || Icon.icons[name.replace(/_/g, '-')] || Icon.icons[(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_2__.camelCase)(name)] || Icon.icons[(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_2__.kebabCase)(name)] || Icon.icons[name.toLowerCase()]; |
| 11992 |
if (!jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.IS_PROD && !icon) { |
| 11993 |
console.warn(`Icon "${name}" not found`); |
| 11994 |
} |
| 11995 |
return icon; |
| 11996 |
} |
| 11997 |
/** |
| 11998 |
* Check if icon exist in store |
| 11999 |
*/ static exists(name) { |
| 12000 |
return this.getIcon(name) !== undefined; |
| 12001 |
} |
| 12002 |
/** |
| 12003 |
* Return SVG icon |
| 12004 |
*/ static get(name, defaultValue = '<span></span>') { |
| 12005 |
return this.getIcon(name) || defaultValue; |
| 12006 |
} |
| 12007 |
/** |
| 12008 |
* Set SVG in store |
| 12009 |
*/ static set(name, value) { |
| 12010 |
this.icons[name.replace('_', '-')] = value; |
| 12011 |
return this; |
| 12012 |
} |
| 12013 |
/** |
| 12014 |
* Make icon html element |
| 12015 |
*/ static makeIcon(jodit, icon) { |
| 12016 |
if (!icon) { |
| 12017 |
return; |
| 12018 |
} |
| 12019 |
let iconElement; |
| 12020 |
const { name, iconURL, fill } = icon; |
| 12021 |
const clearName = name.replace(/[^a-zA-Z0-9]/g, '_'); |
| 12022 |
let iconFromEvent; |
| 12023 |
if (!/<svg/.test(name)) { |
| 12024 |
var _jodit_o_getIcon, _jodit_o; |
| 12025 |
iconFromEvent = (_jodit_o_getIcon = (_jodit_o = jodit.o).getIcon) === null || _jodit_o_getIcon === void 0 ? void 0 : _jodit_o_getIcon.call(_jodit_o, name, clearName); |
| 12026 |
} |
| 12027 |
const cacheKey = `${name}${iconURL}${fill}${iconFromEvent !== null && iconFromEvent !== void 0 ? iconFromEvent : ''}`; |
| 12028 |
if (jodit.o.cache && this.__cache.has(cacheKey)) { |
| 12029 |
var _this___cache_get; |
| 12030 |
return (_this___cache_get = this.__cache.get(cacheKey)) === null || _this___cache_get === void 0 ? void 0 : _this___cache_get.cloneNode(true); |
| 12031 |
} |
| 12032 |
if (iconURL) { |
| 12033 |
iconElement = jodit.c.span(); |
| 12034 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_3__.css)(iconElement, 'backgroundImage', 'url(' + iconURL.replace('{basePath}', (jodit === null || jodit === void 0 ? void 0 : jodit.basePath) || '') + ')'); |
| 12035 |
} else { |
| 12036 |
var _jodit_o_extraIcons; |
| 12037 |
const svg = iconFromEvent || Icon.get(name, '') || ((_jodit_o_extraIcons = jodit.o.extraIcons) === null || _jodit_o_extraIcons === void 0 ? void 0 : _jodit_o_extraIcons[name]); |
| 12038 |
if (svg) { |
| 12039 |
iconElement = jodit.c.fromHTML(svg.trim()); |
| 12040 |
if (!/^<svg/i.test(name)) { |
| 12041 |
iconElement.classList.add('jodit-icon_' + clearName); |
| 12042 |
} |
| 12043 |
} |
| 12044 |
} |
| 12045 |
if (iconElement) { |
| 12046 |
iconElement.classList.add('jodit-icon'); |
| 12047 |
iconElement.style.fill = fill; |
| 12048 |
jodit.o.cache && this.__cache.set(cacheKey, iconElement.cloneNode(true)); |
| 12049 |
} |
| 12050 |
return iconElement; |
| 12051 |
} |
| 12052 |
} |
| 12053 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(Icon, "icons", {}); |
| 12054 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(Icon, "__cache", new Map()); |
| 12055 |
|
| 12056 |
|
| 12057 |
/***/ }), |
| 12058 |
|
| 12059 |
/***/ 29596: |
| 12060 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 12061 |
|
| 12062 |
"use strict"; |
| 12063 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 12064 |
/* harmony export */ UIImageMainTab: function() { return /* binding */ UIImageMainTab; } |
| 12065 |
/* harmony export */ }); |
| 12066 |
/* harmony import */ var _swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(49376); |
| 12067 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(25045); |
| 12068 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(31635); |
| 12069 |
/* harmony import */ var jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(91672); |
| 12070 |
/* harmony import */ var jodit_core_decorators_hook_hook__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(29200); |
| 12071 |
/* harmony import */ var jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(68616); |
| 12072 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(65946); |
| 12073 |
/* harmony import */ var jodit_core_ui_group_group__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(63468); |
| 12074 |
/*! |
| 12075 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 12076 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 12077 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 12078 |
*/ /** |
| 12079 |
* @module plugins/image-properties |
| 12080 |
*/ |
| 12081 |
|
| 12082 |
|
| 12083 |
|
| 12084 |
|
| 12085 |
|
| 12086 |
|
| 12087 |
|
| 12088 |
class UIImageMainTab extends jodit_core_ui_group_group__WEBPACK_IMPORTED_MODULE_7__.UIGroup { |
| 12089 |
className() { |
| 12090 |
return 'UIImageMainTab'; |
| 12091 |
} |
| 12092 |
appendChildToContainer() { |
| 12093 |
// Do nothing |
| 12094 |
} |
| 12095 |
render() { |
| 12096 |
return `<div class="jodit-form__group &__editSrc"> |
| 12097 |
<label>~Src~</label> |
| 12098 |
<div class="jodit-input_group"> |
| 12099 |
<input class="jodit-input &__imageSrc" type="text"/> |
| 12100 |
<div class="jodit-input_group-buttons &__fixImage"> |
| 12101 |
<a class="jodit-button &__changeImage">*image*</a> |
| 12102 |
<a class="jodit-button &__editImage">*crop*</a> |
| 12103 |
</div> |
| 12104 |
</div> |
| 12105 |
</div> |
| 12106 |
<div class="jodit-form__group &__editTitle"> |
| 12107 |
<label>~Title~</label> |
| 12108 |
<input type="text" class="jodit-input &__imageTitle"/> |
| 12109 |
</div> |
| 12110 |
<div class="jodit-form__group &__editAlt"> |
| 12111 |
<label>~Alternative~</label> |
| 12112 |
<input type="text" class="jodit-input &__imageAlt"/> |
| 12113 |
</div> |
| 12114 |
<div class="jodit-form__group &__editLink"> |
| 12115 |
<label>~Link~</label> |
| 12116 |
<input type="text" class="jodit-input &__imageLink"/> |
| 12117 |
</div> |
| 12118 |
<div class="jodit-form__group &__editLinkTarget"> |
| 12119 |
<label class="jodit_vertical_middle"> |
| 12120 |
<input type="checkbox" class="jodit-checkbox &__imageLinkOpenInNewTab"/> |
| 12121 |
<span>~Open link in new tab~</span> |
| 12122 |
</label> |
| 12123 |
</div>`; |
| 12124 |
} |
| 12125 |
onStateImageSrcChange() { |
| 12126 |
return (0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 12127 |
const imageSrc = this.getElm('imageSrc'); |
| 12128 |
imageSrc.value = this.state.values.imageSrc; |
| 12129 |
}).call(this); |
| 12130 |
} |
| 12131 |
onImageSrcChange() { |
| 12132 |
this.state.values.imageSrc = this.getElm('imageSrc').value; |
| 12133 |
} |
| 12134 |
/** |
| 12135 |
* Open image editor |
| 12136 |
*/ onEditImageClick(e) { |
| 12137 |
this.handlers.openImageEditor(); |
| 12138 |
e.stopPropagation(); |
| 12139 |
} |
| 12140 |
/** |
| 12141 |
* Open popup with filebrowser/uploader buttons for image |
| 12142 |
*/ onChangeImageClick(e) { |
| 12143 |
this.handlers.openImagePopup(this.getElm('changeImage')); |
| 12144 |
e.stopPropagation(); |
| 12145 |
} |
| 12146 |
onStateTitleChange() { |
| 12147 |
const title = this.getElm('imageTitle'); |
| 12148 |
title.value = this.state.values.imageTitle; |
| 12149 |
} |
| 12150 |
onTitleChange() { |
| 12151 |
this.state.values.imageTitle = this.getElm('imageTitle').value; |
| 12152 |
} |
| 12153 |
onStateAltChange() { |
| 12154 |
const alt = this.getElm('imageAlt'); |
| 12155 |
alt.value = this.state.values.imageAlt; |
| 12156 |
} |
| 12157 |
onAltChange() { |
| 12158 |
this.state.values.imageAlt = this.getElm('imageAlt').value; |
| 12159 |
} |
| 12160 |
onStateImageLinkChange() { |
| 12161 |
const imageLink = this.getElm('imageLink'); |
| 12162 |
imageLink.value = this.state.values.imageLink; |
| 12163 |
} |
| 12164 |
onImageLinkChange() { |
| 12165 |
this.state.values.imageLink = this.getElm('imageLink').value; |
| 12166 |
} |
| 12167 |
onStateImageLinkOpenInNewTabChange() { |
| 12168 |
const imageLinkOpenInNewTab = this.getElm('imageLinkOpenInNewTab'); |
| 12169 |
imageLinkOpenInNewTab.checked = this.state.values.imageLinkOpenInNewTab; |
| 12170 |
} |
| 12171 |
onImageLinkOpenInNewTabChange() { |
| 12172 |
this.state.values.imageLinkOpenInNewTab = this.getElm('imageLinkOpenInNewTab').checked; |
| 12173 |
} |
| 12174 |
hideFieldByOptions() { |
| 12175 |
const o = this.j.o; |
| 12176 |
const opt = o.image; |
| 12177 |
[ |
| 12178 |
[ |
| 12179 |
'editSrc', |
| 12180 |
'editSrc' |
| 12181 |
], |
| 12182 |
[ |
| 12183 |
'editTitle', |
| 12184 |
'editTitle' |
| 12185 |
], |
| 12186 |
[ |
| 12187 |
'editAlt', |
| 12188 |
'editAlt' |
| 12189 |
], |
| 12190 |
[ |
| 12191 |
'editLink', |
| 12192 |
'editLink' |
| 12193 |
], |
| 12194 |
[ |
| 12195 |
'editLink', |
| 12196 |
'editLinkTarget' |
| 12197 |
], |
| 12198 |
[ |
| 12199 |
'useImageEditor', |
| 12200 |
'editImage' |
| 12201 |
] |
| 12202 |
].forEach(([optKey, elmKey])=>{ |
| 12203 |
const elm = this.getElm(elmKey); |
| 12204 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.css)(elm, 'display', opt[optKey] ? null : 'none'); |
| 12205 |
}); |
| 12206 |
const changeImage = this.getElm('changeImage'); |
| 12207 |
const needShowChangeImage = Boolean(o.filebrowser.ajax.url || o.uploader.url); |
| 12208 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.css)(changeImage, 'display', needShowChangeImage ? null : 'none'); |
| 12209 |
const editImage = this.getElm('editImage'); |
| 12210 |
const needShowEditImage = Boolean(o.filebrowser.ajax.url) && opt.useImageEditor; |
| 12211 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.css)(editImage, 'display', needShowEditImage ? null : 'none'); |
| 12212 |
const fixImage = this.getElm('fixImage'); |
| 12213 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.css)(fixImage, 'display', needShowChangeImage || needShowEditImage ? null : 'none'); |
| 12214 |
} |
| 12215 |
constructor(view, state, handlers){ |
| 12216 |
super(view), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(this, "state", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(this, "handlers", void 0), this.state = state, this.handlers = handlers; |
| 12217 |
} |
| 12218 |
} |
| 12219 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 12220 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__.watch)('state.values.imageSrc') |
| 12221 |
], UIImageMainTab.prototype, "onStateImageSrcChange", null); |
| 12222 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 12223 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__.watch)('imageSrc:change') |
| 12224 |
], UIImageMainTab.prototype, "onImageSrcChange", null); |
| 12225 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 12226 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__.watch)('editImage:click') |
| 12227 |
], UIImageMainTab.prototype, "onEditImageClick", null); |
| 12228 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 12229 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__.watch)('changeImage:click') |
| 12230 |
], UIImageMainTab.prototype, "onChangeImageClick", null); |
| 12231 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 12232 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__.watch)('state.values.imageTitle') |
| 12233 |
], UIImageMainTab.prototype, "onStateTitleChange", null); |
| 12234 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 12235 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__.watch)('imageTitle:change') |
| 12236 |
], UIImageMainTab.prototype, "onTitleChange", null); |
| 12237 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 12238 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__.watch)('state.values.imageAlt') |
| 12239 |
], UIImageMainTab.prototype, "onStateAltChange", null); |
| 12240 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 12241 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__.watch)('imageAlt:change') |
| 12242 |
], UIImageMainTab.prototype, "onAltChange", null); |
| 12243 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 12244 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__.watch)('state.values.imageLink') |
| 12245 |
], UIImageMainTab.prototype, "onStateImageLinkChange", null); |
| 12246 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 12247 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__.watch)('imageLink:change') |
| 12248 |
], UIImageMainTab.prototype, "onImageLinkChange", null); |
| 12249 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 12250 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__.watch)('state.values.imageLinkOpenInNewTab') |
| 12251 |
], UIImageMainTab.prototype, "onStateImageLinkOpenInNewTabChange", null); |
| 12252 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 12253 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__.watch)('imageLinkOpenInNewTab:change') |
| 12254 |
], UIImageMainTab.prototype, "onImageLinkOpenInNewTabChange", null); |
| 12255 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 12256 |
(0,jodit_core_decorators_hook_hook__WEBPACK_IMPORTED_MODULE_4__.hook)('ready') |
| 12257 |
], UIImageMainTab.prototype, "hideFieldByOptions", null); |
| 12258 |
UIImageMainTab = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 12259 |
jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_3__.component |
| 12260 |
], UIImageMainTab); |
| 12261 |
|
| 12262 |
|
| 12263 |
/***/ }), |
| 12264 |
|
| 12265 |
/***/ 29953: |
| 12266 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 12267 |
|
| 12268 |
"use strict"; |
| 12269 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 12270 |
/* harmony export */ ConnectionError: function() { return /* reexport safe */ _connection_error__WEBPACK_IMPORTED_MODULE_1__.ConnectionError; }, |
| 12271 |
/* harmony export */ OptionsError: function() { return /* reexport safe */ _options_error__WEBPACK_IMPORTED_MODULE_2__.OptionsError; }, |
| 12272 |
/* harmony export */ abort: function() { return /* reexport safe */ _abort_error__WEBPACK_IMPORTED_MODULE_0__.abort; } |
| 12273 |
/* harmony export */ }); |
| 12274 |
/* harmony import */ var _abort_error__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(14228); |
| 12275 |
/* harmony import */ var _connection_error__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(58250); |
| 12276 |
/* harmony import */ var _options_error__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(11080); |
| 12277 |
/*! |
| 12278 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 12279 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 12280 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 12281 |
*/ /** |
| 12282 |
* @module helpers/utils |
| 12283 |
*/ |
| 12284 |
|
| 12285 |
|
| 12286 |
|
| 12287 |
|
| 12288 |
/***/ }), |
| 12289 |
|
| 12290 |
/***/ 30062: |
| 12291 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 12292 |
|
| 12293 |
"use strict"; |
| 12294 |
/* unused harmony export copyFormat */ |
| 12295 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 12296 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(28077); |
| 12297 |
/* harmony import */ var jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(80991); |
| 12298 |
/* harmony import */ var jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(29434); |
| 12299 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(5266); |
| 12300 |
/* harmony import */ var _copy_format_svg__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(3843); |
| 12301 |
/* harmony import */ var _copy_format_svg__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_copy_format_svg__WEBPACK_IMPORTED_MODULE_5__); |
| 12302 |
/* harmony import */ var _langs__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(38639); |
| 12303 |
/*! |
| 12304 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 12305 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 12306 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 12307 |
*/ /** |
| 12308 |
* [[include:plugins/copy-format/README.md]] |
| 12309 |
* @packageDocumentation |
| 12310 |
* @module plugins/clipboard |
| 12311 |
*/ |
| 12312 |
|
| 12313 |
|
| 12314 |
|
| 12315 |
|
| 12316 |
|
| 12317 |
|
| 12318 |
const pluginKey = 'copy-format'; |
| 12319 |
/** |
| 12320 |
* Plug-in copy and paste formatting from one element to another |
| 12321 |
*/ const copyStyles = [ |
| 12322 |
'lineHeight', |
| 12323 |
'fontWeight', |
| 12324 |
'fontStyle', |
| 12325 |
'fontSize', |
| 12326 |
'fontFamily', |
| 12327 |
'color', |
| 12328 |
'margin', |
| 12329 |
'padding', |
| 12330 |
'borderWidth', |
| 12331 |
'borderStyle', |
| 12332 |
'borderColor', |
| 12333 |
'borderRadius', |
| 12334 |
'backgroundColor', |
| 12335 |
'textDecorationLine' |
| 12336 |
]; |
| 12337 |
const getStyle = (editor, key, box, defaultStyles)=>{ |
| 12338 |
let result = (0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_2__.css)(box, key); |
| 12339 |
if (result === defaultStyles[key]) { |
| 12340 |
if (box.parentNode && box !== editor.editor && box.parentNode !== editor.editor) { |
| 12341 |
result = getStyle(editor, key, box.parentNode, defaultStyles); |
| 12342 |
} else { |
| 12343 |
result = undefined; |
| 12344 |
} |
| 12345 |
} |
| 12346 |
return result; |
| 12347 |
}; |
| 12348 |
const getStyles = (editor, box, defaultStyles)=>{ |
| 12349 |
const result = {}; |
| 12350 |
if (box) { |
| 12351 |
copyStyles.forEach((key)=>{ |
| 12352 |
result[key] = getStyle(editor, key, box, defaultStyles); |
| 12353 |
if (key.match(/border(Style|Color)/) && !result.borderWidth) { |
| 12354 |
result[key] = undefined; |
| 12355 |
} |
| 12356 |
}); |
| 12357 |
} |
| 12358 |
return result; |
| 12359 |
}; |
| 12360 |
jodit_config__WEBPACK_IMPORTED_MODULE_4__.Config.prototype.controls.copyformat = { |
| 12361 |
exec: (editor, current, { button })=>{ |
| 12362 |
if (!current) { |
| 12363 |
return; |
| 12364 |
} |
| 12365 |
if (editor.buffer.exists(pluginKey)) { |
| 12366 |
editor.buffer.delete(pluginKey); |
| 12367 |
editor.e.off(editor.editor, 'mouseup.' + pluginKey); |
| 12368 |
} else { |
| 12369 |
const defaultStyles = {}, box = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.up(current, (elm)=>elm && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isText(elm), editor.editor) || editor.editor; |
| 12370 |
const ideal = editor.createInside.span(); |
| 12371 |
editor.editor.appendChild(ideal); |
| 12372 |
copyStyles.forEach((key)=>{ |
| 12373 |
defaultStyles[key] = (0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_2__.css)(ideal, key); |
| 12374 |
}); |
| 12375 |
if (ideal !== editor.editor) { |
| 12376 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(ideal); |
| 12377 |
} |
| 12378 |
const format = getStyles(editor, box, defaultStyles); |
| 12379 |
const onMouseUp = ()=>{ |
| 12380 |
editor.buffer.delete(pluginKey); |
| 12381 |
const currentNode = editor.s.current(); |
| 12382 |
if (currentNode) { |
| 12383 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(currentNode, 'img')) { |
| 12384 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_2__.css)(currentNode, format); |
| 12385 |
} else { |
| 12386 |
editor.s.commitStyle({ |
| 12387 |
attributes: { |
| 12388 |
style: format |
| 12389 |
} |
| 12390 |
}); |
| 12391 |
} |
| 12392 |
} |
| 12393 |
editor.e.off(editor.editor, 'mouseup.' + pluginKey); |
| 12394 |
}; |
| 12395 |
editor.e.on(editor.editor, 'mouseup.' + pluginKey, onMouseUp); |
| 12396 |
editor.buffer.set(pluginKey, true); |
| 12397 |
} |
| 12398 |
button.update(); |
| 12399 |
}, |
| 12400 |
isActive: (editor)=>editor.buffer.exists(pluginKey), |
| 12401 |
tooltip: 'Paint format' |
| 12402 |
}; |
| 12403 |
function copyFormat(editor) { |
| 12404 |
editor.registerButton({ |
| 12405 |
name: 'copyformat', |
| 12406 |
group: 'clipboard' |
| 12407 |
}); |
| 12408 |
(0,jodit_core_global__WEBPACK_IMPORTED_MODULE_1__.extendLang)(_langs__WEBPACK_IMPORTED_MODULE_6__); |
| 12409 |
} |
| 12410 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_1__.pluginSystem.add('copyformat', copyFormat); |
| 12411 |
jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_3__.Icon.set('copyformat', (_copy_format_svg__WEBPACK_IMPORTED_MODULE_5___default())); |
| 12412 |
|
| 12413 |
|
| 12414 |
/***/ }), |
| 12415 |
|
| 12416 |
/***/ 30110: |
| 12417 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 12418 |
|
| 12419 |
"use strict"; |
| 12420 |
/* unused harmony export tableKeyboardNavigation */ |
| 12421 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 12422 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(23211); |
| 12423 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(28077); |
| 12424 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(65946); |
| 12425 |
/* harmony import */ var jodit_modules_table_table__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(98803); |
| 12426 |
/*! |
| 12427 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 12428 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 12429 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 12430 |
*/ /** |
| 12431 |
* [[include:plugins/table-keyboard-navigation/README.md]] |
| 12432 |
* @packageDocumentation |
| 12433 |
* @module plugins/table-keyboard-navigation |
| 12434 |
*/ |
| 12435 |
|
| 12436 |
|
| 12437 |
|
| 12438 |
|
| 12439 |
const WORK_KEYS = new Set([ |
| 12440 |
jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_TAB, |
| 12441 |
jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_LEFT, |
| 12442 |
jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_RIGHT, |
| 12443 |
jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_UP, |
| 12444 |
jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_DOWN |
| 12445 |
]); |
| 12446 |
/** |
| 12447 |
* Process navigates key pressing in table cell |
| 12448 |
*/ function tableKeyboardNavigation(editor) { |
| 12449 |
editor.e.off('.tableKeyboardNavigation').on('keydown.tableKeyboardNavigation', (event)=>{ |
| 12450 |
const { key } = event; |
| 12451 |
const cell = findCell(editor, key); |
| 12452 |
if (!cell) { |
| 12453 |
return; |
| 12454 |
} |
| 12455 |
const tableModule = editor.getInstance(jodit_modules_table_table__WEBPACK_IMPORTED_MODULE_4__.Table, editor.o); |
| 12456 |
const table = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.closest(cell, 'table', editor.editor); |
| 12457 |
let next = null; |
| 12458 |
const isPrev = key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_LEFT || event.shiftKey; |
| 12459 |
const getNextCell = ()=>(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.call)(isPrev ? jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.prev : jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.next, cell, jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isCell, table); |
| 12460 |
switch(key){ |
| 12461 |
case jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_TAB: |
| 12462 |
case jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_LEFT: |
| 12463 |
{ |
| 12464 |
next = getNextCell(); |
| 12465 |
if (!next) { |
| 12466 |
tableModule.appendRow(table, !isPrev ? false : table.querySelector('tr'), !isPrev); |
| 12467 |
next = getNextCell(); |
| 12468 |
} |
| 12469 |
break; |
| 12470 |
} |
| 12471 |
case jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_UP: |
| 12472 |
case jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_DOWN: |
| 12473 |
{ |
| 12474 |
const matrix = tableModule.formalMatrix(table); |
| 12475 |
const [row, column] = tableModule.formalCoordinate(table, cell); |
| 12476 |
if (key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_UP) { |
| 12477 |
if (matrix[row - 1] !== undefined) { |
| 12478 |
next = matrix[row - 1][column]; |
| 12479 |
} |
| 12480 |
} else { |
| 12481 |
if (matrix[row + 1] !== undefined) { |
| 12482 |
next = matrix[row + 1][column]; |
| 12483 |
} |
| 12484 |
} |
| 12485 |
} |
| 12486 |
break; |
| 12487 |
} |
| 12488 |
if (!next) { |
| 12489 |
return; |
| 12490 |
} |
| 12491 |
editor.e.fire('hidePopup hideResizer'); |
| 12492 |
if (!next.firstChild) { |
| 12493 |
const first = editor.createInside.element('br'); |
| 12494 |
next.appendChild(first); |
| 12495 |
editor.s.setCursorBefore(first); |
| 12496 |
} else { |
| 12497 |
if (key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_TAB) { |
| 12498 |
editor.s.select(next, true); |
| 12499 |
} else { |
| 12500 |
editor.s.setCursorIn(next, key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_RIGHT || key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_DOWN); |
| 12501 |
} |
| 12502 |
} |
| 12503 |
editor.synchronizeValues(); |
| 12504 |
return false; |
| 12505 |
}); |
| 12506 |
} |
| 12507 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_2__.pluginSystem.add('tableKeyboardNavigation', tableKeyboardNavigation); |
| 12508 |
function findCell(editor, key) { |
| 12509 |
if (!WORK_KEYS.has(key)) { |
| 12510 |
return; |
| 12511 |
} |
| 12512 |
const current = editor.s.current(); |
| 12513 |
if (!current) { |
| 12514 |
return; |
| 12515 |
} |
| 12516 |
const cell = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.up(current, jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isCell, editor.editor); |
| 12517 |
if (!cell) { |
| 12518 |
return; |
| 12519 |
} |
| 12520 |
const { range } = editor.s; |
| 12521 |
if (key !== jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_TAB && current !== cell) { |
| 12522 |
const isNextDirection = key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_RIGHT || key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_DOWN; |
| 12523 |
const hasNext = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.call)(!isNextDirection ? jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.prev : jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.next, current, (elm)=>key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_UP || key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_DOWN ? jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isTag(elm, 'br') : Boolean(elm), cell); |
| 12524 |
if (!isNextDirection && (hasNext || key !== jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_UP && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isText(current) && range.startOffset !== 0) || isNextDirection && (hasNext || key !== jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_DOWN && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isText(current) && current.nodeValue && range.startOffset !== current.nodeValue.length)) { |
| 12525 |
return; |
| 12526 |
} |
| 12527 |
} |
| 12528 |
return cell; |
| 12529 |
} |
| 12530 |
|
| 12531 |
|
| 12532 |
/***/ }), |
| 12533 |
|
| 12534 |
/***/ 30893: |
| 12535 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 12536 |
|
| 12537 |
"use strict"; |
| 12538 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 12539 |
/* harmony export */ applyStyles: function() { return /* binding */ applyStyles; } |
| 12540 |
/* harmony export */ }); |
| 12541 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 12542 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(23211); |
| 12543 |
/* harmony import */ var jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(4040); |
| 12544 |
/* harmony import */ var jodit_core_helpers_utils_selector__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(28723); |
| 12545 |
/*! |
| 12546 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 12547 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 12548 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 12549 |
*/ /** |
| 12550 |
* @module helpers/html |
| 12551 |
*/ |
| 12552 |
|
| 12553 |
|
| 12554 |
|
| 12555 |
function normalizeCSS(s) { |
| 12556 |
return s.replace(/mso-[a-z-]+:[\s]*[^;]+;/gi, '').replace(/mso-[a-z-]+:[\s]*[^";']+$/gi, '').replace(/border[a-z-]*:[\s]*[^;]+;/gi, '').replace(/([0-9.]+)(pt|cm)/gi, (match, units, metrics)=>{ |
| 12557 |
switch(metrics.toLowerCase()){ |
| 12558 |
case 'pt': |
| 12559 |
return (parseFloat(units) * 1.328).toFixed(0) + 'px'; |
| 12560 |
case 'cm': |
| 12561 |
return (parseFloat(units) * 0.02645833).toFixed(0) + 'px'; |
| 12562 |
} |
| 12563 |
return match; |
| 12564 |
}); |
| 12565 |
} |
| 12566 |
/** |
| 12567 |
* If the HTML has CSS rules with selectors, |
| 12568 |
* it applies them to the selectors in the HTML itself |
| 12569 |
* and then removes the selector styles, leaving only the inline ones. |
| 12570 |
*/ function applyStyles(html) { |
| 12571 |
if (html.indexOf('<html ') === -1) { |
| 12572 |
return html; |
| 12573 |
} |
| 12574 |
html = html.substring(html.indexOf('<html '), html.length); |
| 12575 |
html = html.substring(0, html.lastIndexOf('</html>') + '</html>'.length); |
| 12576 |
const iframe = jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.globalDocument.createElement('iframe'); |
| 12577 |
iframe.style.display = 'none'; |
| 12578 |
jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.globalDocument.body.appendChild(iframe); |
| 12579 |
let convertedString = '', collection = []; |
| 12580 |
try { |
| 12581 |
const iframeDoc = iframe.contentDocument || (iframe.contentWindow ? iframe.contentWindow.document : null); |
| 12582 |
if (iframeDoc) { |
| 12583 |
iframeDoc.open(); |
| 12584 |
iframeDoc.write(html); |
| 12585 |
iframeDoc.close(); |
| 12586 |
try { |
| 12587 |
for(let i = 0; i < iframeDoc.styleSheets.length; i += 1){ |
| 12588 |
const rules = iframeDoc.styleSheets[i].cssRules; |
| 12589 |
for(let idx = 0; idx < rules.length; idx += 1){ |
| 12590 |
if (rules[idx].selectorText === '') { |
| 12591 |
continue; |
| 12592 |
} |
| 12593 |
collection = (0,jodit_core_helpers_utils_selector__WEBPACK_IMPORTED_MODULE_3__.$$)(rules[idx].selectorText, iframeDoc.body); |
| 12594 |
collection.forEach((elm)=>{ |
| 12595 |
elm.style.cssText = normalizeCSS(rules[idx].style.cssText + ';' + elm.style.cssText); |
| 12596 |
}); |
| 12597 |
} |
| 12598 |
} |
| 12599 |
} catch (e) { |
| 12600 |
if (!jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.IS_PROD) { |
| 12601 |
throw e; |
| 12602 |
} |
| 12603 |
} |
| 12604 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.each(iframeDoc.body, (node)=>{ |
| 12605 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isElement(node)) { |
| 12606 |
const elm = node; |
| 12607 |
const css = elm.getAttribute('style'); |
| 12608 |
if (css) { |
| 12609 |
elm.style.cssText = normalizeCSS(css); |
| 12610 |
} |
| 12611 |
if (elm.hasAttribute('style') && !elm.getAttribute('style')) { |
| 12612 |
elm.removeAttribute('style'); |
| 12613 |
} |
| 12614 |
} |
| 12615 |
}); |
| 12616 |
convertedString = iframeDoc.firstChild ? (0,jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_2__.trim)(iframeDoc.body.innerHTML) : ''; |
| 12617 |
} |
| 12618 |
} catch (unused) {} finally{ |
| 12619 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.safeRemove(iframe); |
| 12620 |
} |
| 12621 |
if (convertedString) { |
| 12622 |
html = convertedString; |
| 12623 |
} |
| 12624 |
return (0,jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_2__.trim)(html.replace(/<(\/)?(html|colgroup|col|o:p)[^>]*>/g, '').replace(/<!--[^>]*>/g, '')); |
| 12625 |
} |
| 12626 |
|
| 12627 |
|
| 12628 |
/***/ }), |
| 12629 |
|
| 12630 |
/***/ 31125: |
| 12631 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 12632 |
|
| 12633 |
"use strict"; |
| 12634 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 12635 |
/* harmony export */ elementsMap: function() { return /* binding */ elementsMap; } |
| 12636 |
/* harmony export */ }); |
| 12637 |
/*! |
| 12638 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 12639 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 12640 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 12641 |
*/ /** |
| 12642 |
* @module modules/file-browser |
| 12643 |
*/ const map = new WeakMap(); |
| 12644 |
/** |
| 12645 |
* Returns a map of the file's key correspondence to its DOM element in the file browser |
| 12646 |
* @private |
| 12647 |
*/ const elementsMap = (view)=>{ |
| 12648 |
let result = map.get(view); |
| 12649 |
if (!result) { |
| 12650 |
result = {}; |
| 12651 |
map.set(view, result); |
| 12652 |
} |
| 12653 |
return result; |
| 12654 |
}; |
| 12655 |
|
| 12656 |
|
| 12657 |
/***/ }), |
| 12658 |
|
| 12659 |
/***/ 31230: |
| 12660 |
/***/ (function(module) { |
| 12661 |
|
| 12662 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 24 24\"> <g transform=\"translate(-251.000000, -443.000000)\"> <g transform=\"translate(215.000000, 119.000000)\"/> <path d=\"M252,448 L256,448 L256,444 L252,444 L252,448 Z M257,448 L269,448 L269,446 L257,446 L257,448 Z M257,464 L269,464 L269,462 L257,462 L257,464 Z M270,444 L270,448 L274,448 L274,444 L270,444 Z M252,462 L252,466 L256,466 L256,462 L252,462 Z M270,462 L270,466 L274,466 L274,462 L270,462 Z M254,461 L256,461 L256,449 L254,449 L254,461 Z M270,461 L272,461 L272,449 L270,449 L270,461 Z\"/> </g> </svg>" |
| 12663 |
|
| 12664 |
/***/ }), |
| 12665 |
|
| 12666 |
/***/ 31365: |
| 12667 |
/***/ (function(module) { |
| 12668 |
|
| 12669 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 32 32\"> <path d=\"M27 4l-15 15-7-7-5 5 12 12 20-20z\"/> </svg>" |
| 12670 |
|
| 12671 |
/***/ }), |
| 12672 |
|
| 12673 |
/***/ 31371: |
| 12674 |
/***/ (function(module) { |
| 12675 |
|
| 12676 |
/*! |
| 12677 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 12678 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 12679 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 12680 |
*/ module.exports = { |
| 12681 |
'copy-format': 'Kopyalama Biçimi' |
| 12682 |
}; |
| 12683 |
|
| 12684 |
|
| 12685 |
/***/ }), |
| 12686 |
|
| 12687 |
/***/ 31534: |
| 12688 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 12689 |
|
| 12690 |
"use strict"; |
| 12691 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 12692 |
/* harmony export */ isViewObject: function() { return /* binding */ isViewObject; } |
| 12693 |
/* harmony export */ }); |
| 12694 |
/* harmony import */ var _is_function__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(91565); |
| 12695 |
/*! |
| 12696 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 12697 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 12698 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 12699 |
*/ /** |
| 12700 |
* @module helpers/checker |
| 12701 |
*/ |
| 12702 |
/** |
| 12703 |
* Check if an element is instance of View |
| 12704 |
*/ function isViewObject(jodit) { |
| 12705 |
return Boolean(jodit && jodit instanceof Object && (0,_is_function__WEBPACK_IMPORTED_MODULE_0__.isFunction)(jodit.constructor) && jodit.isView); |
| 12706 |
} |
| 12707 |
|
| 12708 |
|
| 12709 |
/***/ }), |
| 12710 |
|
| 12711 |
/***/ 31635: |
| 12712 |
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { |
| 12713 |
|
| 12714 |
"use strict"; |
| 12715 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 12716 |
/* harmony export */ __decorate: function() { return /* binding */ __decorate; } |
| 12717 |
/* harmony export */ }); |
| 12718 |
/* unused harmony exports __extends, __assign, __rest, __param, __esDecorate, __runInitializers, __propKey, __setFunctionName, __metadata, __awaiter, __generator, __createBinding, __exportStar, __values, __read, __spread, __spreadArrays, __spreadArray, __await, __asyncGenerator, __asyncDelegator, __asyncValues, __makeTemplateObject, __importStar, __importDefault, __classPrivateFieldGet, __classPrivateFieldSet, __classPrivateFieldIn, __addDisposableResource, __disposeResources, __rewriteRelativeImportExtension */ |
| 12719 |
/****************************************************************************** |
| 12720 |
Copyright (c) Microsoft Corporation. |
| 12721 |
|
| 12722 |
Permission to use, copy, modify, and/or distribute this software for any |
| 12723 |
purpose with or without fee is hereby granted. |
| 12724 |
|
| 12725 |
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH |
| 12726 |
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY |
| 12727 |
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, |
| 12728 |
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM |
| 12729 |
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR |
| 12730 |
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR |
| 12731 |
PERFORMANCE OF THIS SOFTWARE. |
| 12732 |
***************************************************************************** */ |
| 12733 |
/* global Reflect, Promise, SuppressedError, Symbol, Iterator */ |
| 12734 |
|
| 12735 |
var extendStatics = function(d, b) { |
| 12736 |
extendStatics = Object.setPrototypeOf || |
| 12737 |
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || |
| 12738 |
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; |
| 12739 |
return extendStatics(d, b); |
| 12740 |
}; |
| 12741 |
|
| 12742 |
function __extends(d, b) { |
| 12743 |
if (typeof b !== "function" && b !== null) |
| 12744 |
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null"); |
| 12745 |
extendStatics(d, b); |
| 12746 |
function __() { this.constructor = d; } |
| 12747 |
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); |
| 12748 |
} |
| 12749 |
|
| 12750 |
var __assign = function() { |
| 12751 |
__assign = Object.assign || function __assign(t) { |
| 12752 |
for (var s, i = 1, n = arguments.length; i < n; i++) { |
| 12753 |
s = arguments[i]; |
| 12754 |
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p]; |
| 12755 |
} |
| 12756 |
return t; |
| 12757 |
} |
| 12758 |
return __assign.apply(this, arguments); |
| 12759 |
} |
| 12760 |
|
| 12761 |
function __rest(s, e) { |
| 12762 |
var t = {}; |
| 12763 |
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) |
| 12764 |
t[p] = s[p]; |
| 12765 |
if (s != null && typeof Object.getOwnPropertySymbols === "function") |
| 12766 |
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) { |
| 12767 |
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) |
| 12768 |
t[p[i]] = s[p[i]]; |
| 12769 |
} |
| 12770 |
return t; |
| 12771 |
} |
| 12772 |
|
| 12773 |
function __decorate(decorators, target, key, desc) { |
| 12774 |
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d; |
| 12775 |
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc); |
| 12776 |
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r; |
| 12777 |
return c > 3 && r && Object.defineProperty(target, key, r), r; |
| 12778 |
} |
| 12779 |
|
| 12780 |
function __param(paramIndex, decorator) { |
| 12781 |
return function (target, key) { decorator(target, key, paramIndex); } |
| 12782 |
} |
| 12783 |
|
| 12784 |
function __esDecorate(ctor, descriptorIn, decorators, contextIn, initializers, extraInitializers) { |
| 12785 |
function accept(f) { if (f !== void 0 && typeof f !== "function") throw new TypeError("Function expected"); return f; } |
| 12786 |
var kind = contextIn.kind, key = kind === "getter" ? "get" : kind === "setter" ? "set" : "value"; |
| 12787 |
var target = !descriptorIn && ctor ? contextIn["static"] ? ctor : ctor.prototype : null; |
| 12788 |
var descriptor = descriptorIn || (target ? Object.getOwnPropertyDescriptor(target, contextIn.name) : {}); |
| 12789 |
var _, done = false; |
| 12790 |
for (var i = decorators.length - 1; i >= 0; i--) { |
| 12791 |
var context = {}; |
| 12792 |
for (var p in contextIn) context[p] = p === "access" ? {} : contextIn[p]; |
| 12793 |
for (var p in contextIn.access) context.access[p] = contextIn.access[p]; |
| 12794 |
context.addInitializer = function (f) { if (done) throw new TypeError("Cannot add initializers after decoration has completed"); extraInitializers.push(accept(f || null)); }; |
| 12795 |
var result = (0, decorators[i])(kind === "accessor" ? { get: descriptor.get, set: descriptor.set } : descriptor[key], context); |
| 12796 |
if (kind === "accessor") { |
| 12797 |
if (result === void 0) continue; |
| 12798 |
if (result === null || typeof result !== "object") throw new TypeError("Object expected"); |
| 12799 |
if (_ = accept(result.get)) descriptor.get = _; |
| 12800 |
if (_ = accept(result.set)) descriptor.set = _; |
| 12801 |
if (_ = accept(result.init)) initializers.unshift(_); |
| 12802 |
} |
| 12803 |
else if (_ = accept(result)) { |
| 12804 |
if (kind === "field") initializers.unshift(_); |
| 12805 |
else descriptor[key] = _; |
| 12806 |
} |
| 12807 |
} |
| 12808 |
if (target) Object.defineProperty(target, contextIn.name, descriptor); |
| 12809 |
done = true; |
| 12810 |
}; |
| 12811 |
|
| 12812 |
function __runInitializers(thisArg, initializers, value) { |
| 12813 |
var useValue = arguments.length > 2; |
| 12814 |
for (var i = 0; i < initializers.length; i++) { |
| 12815 |
value = useValue ? initializers[i].call(thisArg, value) : initializers[i].call(thisArg); |
| 12816 |
} |
| 12817 |
return useValue ? value : void 0; |
| 12818 |
}; |
| 12819 |
|
| 12820 |
function __propKey(x) { |
| 12821 |
return typeof x === "symbol" ? x : "".concat(x); |
| 12822 |
}; |
| 12823 |
|
| 12824 |
function __setFunctionName(f, name, prefix) { |
| 12825 |
if (typeof name === "symbol") name = name.description ? "[".concat(name.description, "]") : ""; |
| 12826 |
return Object.defineProperty(f, "name", { configurable: true, value: prefix ? "".concat(prefix, " ", name) : name }); |
| 12827 |
}; |
| 12828 |
|
| 12829 |
function __metadata(metadataKey, metadataValue) { |
| 12830 |
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(metadataKey, metadataValue); |
| 12831 |
} |
| 12832 |
|
| 12833 |
function __awaiter(thisArg, _arguments, P, generator) { |
| 12834 |
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } |
| 12835 |
return new (P || (P = Promise))(function (resolve, reject) { |
| 12836 |
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } |
| 12837 |
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } |
| 12838 |
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } |
| 12839 |
step((generator = generator.apply(thisArg, _arguments || [])).next()); |
| 12840 |
}); |
| 12841 |
} |
| 12842 |
|
| 12843 |
function __generator(thisArg, body) { |
| 12844 |
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g = Object.create((typeof Iterator === "function" ? Iterator : Object).prototype); |
| 12845 |
return g.next = verb(0), g["throw"] = verb(1), g["return"] = verb(2), typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g; |
| 12846 |
function verb(n) { return function (v) { return step([n, v]); }; } |
| 12847 |
function step(op) { |
| 12848 |
if (f) throw new TypeError("Generator is already executing."); |
| 12849 |
while (g && (g = 0, op[0] && (_ = 0)), _) try { |
| 12850 |
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t; |
| 12851 |
if (y = 0, t) op = [op[0] & 2, t.value]; |
| 12852 |
switch (op[0]) { |
| 12853 |
case 0: case 1: t = op; break; |
| 12854 |
case 4: _.label++; return { value: op[1], done: false }; |
| 12855 |
case 5: _.label++; y = op[1]; op = [0]; continue; |
| 12856 |
case 7: op = _.ops.pop(); _.trys.pop(); continue; |
| 12857 |
default: |
| 12858 |
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; } |
| 12859 |
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; } |
| 12860 |
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; } |
| 12861 |
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; } |
| 12862 |
if (t[2]) _.ops.pop(); |
| 12863 |
_.trys.pop(); continue; |
| 12864 |
} |
| 12865 |
op = body.call(thisArg, _); |
| 12866 |
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; } |
| 12867 |
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true }; |
| 12868 |
} |
| 12869 |
} |
| 12870 |
|
| 12871 |
var __createBinding = Object.create ? (function(o, m, k, k2) { |
| 12872 |
if (k2 === undefined) k2 = k; |
| 12873 |
var desc = Object.getOwnPropertyDescriptor(m, k); |
| 12874 |
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) { |
| 12875 |
desc = { enumerable: true, get: function() { return m[k]; } }; |
| 12876 |
} |
| 12877 |
Object.defineProperty(o, k2, desc); |
| 12878 |
}) : (function(o, m, k, k2) { |
| 12879 |
if (k2 === undefined) k2 = k; |
| 12880 |
o[k2] = m[k]; |
| 12881 |
}); |
| 12882 |
|
| 12883 |
function __exportStar(m, o) { |
| 12884 |
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(o, p)) __createBinding(o, m, p); |
| 12885 |
} |
| 12886 |
|
| 12887 |
function __values(o) { |
| 12888 |
var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0; |
| 12889 |
if (m) return m.call(o); |
| 12890 |
if (o && typeof o.length === "number") return { |
| 12891 |
next: function () { |
| 12892 |
if (o && i >= o.length) o = void 0; |
| 12893 |
return { value: o && o[i++], done: !o }; |
| 12894 |
} |
| 12895 |
}; |
| 12896 |
throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined."); |
| 12897 |
} |
| 12898 |
|
| 12899 |
function __read(o, n) { |
| 12900 |
var m = typeof Symbol === "function" && o[Symbol.iterator]; |
| 12901 |
if (!m) return o; |
| 12902 |
var i = m.call(o), r, ar = [], e; |
| 12903 |
try { |
| 12904 |
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value); |
| 12905 |
} |
| 12906 |
catch (error) { e = { error: error }; } |
| 12907 |
finally { |
| 12908 |
try { |
| 12909 |
if (r && !r.done && (m = i["return"])) m.call(i); |
| 12910 |
} |
| 12911 |
finally { if (e) throw e.error; } |
| 12912 |
} |
| 12913 |
return ar; |
| 12914 |
} |
| 12915 |
|
| 12916 |
/** @deprecated */ |
| 12917 |
function __spread() { |
| 12918 |
for (var ar = [], i = 0; i < arguments.length; i++) |
| 12919 |
ar = ar.concat(__read(arguments[i])); |
| 12920 |
return ar; |
| 12921 |
} |
| 12922 |
|
| 12923 |
/** @deprecated */ |
| 12924 |
function __spreadArrays() { |
| 12925 |
for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length; |
| 12926 |
for (var r = Array(s), k = 0, i = 0; i < il; i++) |
| 12927 |
for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++) |
| 12928 |
r[k] = a[j]; |
| 12929 |
return r; |
| 12930 |
} |
| 12931 |
|
| 12932 |
function __spreadArray(to, from, pack) { |
| 12933 |
if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) { |
| 12934 |
if (ar || !(i in from)) { |
| 12935 |
if (!ar) ar = Array.prototype.slice.call(from, 0, i); |
| 12936 |
ar[i] = from[i]; |
| 12937 |
} |
| 12938 |
} |
| 12939 |
return to.concat(ar || Array.prototype.slice.call(from)); |
| 12940 |
} |
| 12941 |
|
| 12942 |
function __await(v) { |
| 12943 |
return this instanceof __await ? (this.v = v, this) : new __await(v); |
| 12944 |
} |
| 12945 |
|
| 12946 |
function __asyncGenerator(thisArg, _arguments, generator) { |
| 12947 |
if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined."); |
| 12948 |
var g = generator.apply(thisArg, _arguments || []), i, q = []; |
| 12949 |
return i = Object.create((typeof AsyncIterator === "function" ? AsyncIterator : Object).prototype), verb("next"), verb("throw"), verb("return", awaitReturn), i[Symbol.asyncIterator] = function () { return this; }, i; |
| 12950 |
function awaitReturn(f) { return function (v) { return Promise.resolve(v).then(f, reject); }; } |
| 12951 |
function verb(n, f) { if (g[n]) { i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; if (f) i[n] = f(i[n]); } } |
| 12952 |
function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } } |
| 12953 |
function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); } |
| 12954 |
function fulfill(value) { resume("next", value); } |
| 12955 |
function reject(value) { resume("throw", value); } |
| 12956 |
function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); } |
| 12957 |
} |
| 12958 |
|
| 12959 |
function __asyncDelegator(o) { |
| 12960 |
var i, p; |
| 12961 |
return i = {}, verb("next"), verb("throw", function (e) { throw e; }), verb("return"), i[Symbol.iterator] = function () { return this; }, i; |
| 12962 |
function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: false } : f ? f(v) : v; } : f; } |
| 12963 |
} |
| 12964 |
|
| 12965 |
function __asyncValues(o) { |
| 12966 |
if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined."); |
| 12967 |
var m = o[Symbol.asyncIterator], i; |
| 12968 |
return m ? m.call(o) : (o = typeof __values === "function" ? __values(o) : o[Symbol.iterator](), i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i); |
| 12969 |
function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; } |
| 12970 |
function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); } |
| 12971 |
} |
| 12972 |
|
| 12973 |
function __makeTemplateObject(cooked, raw) { |
| 12974 |
if (Object.defineProperty) { Object.defineProperty(cooked, "raw", { value: raw }); } else { cooked.raw = raw; } |
| 12975 |
return cooked; |
| 12976 |
}; |
| 12977 |
|
| 12978 |
var __setModuleDefault = Object.create ? (function(o, v) { |
| 12979 |
Object.defineProperty(o, "default", { enumerable: true, value: v }); |
| 12980 |
}) : function(o, v) { |
| 12981 |
o["default"] = v; |
| 12982 |
}; |
| 12983 |
|
| 12984 |
var ownKeys = function(o) { |
| 12985 |
ownKeys = Object.getOwnPropertyNames || function (o) { |
| 12986 |
var ar = []; |
| 12987 |
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k; |
| 12988 |
return ar; |
| 12989 |
}; |
| 12990 |
return ownKeys(o); |
| 12991 |
}; |
| 12992 |
|
| 12993 |
function __importStar(mod) { |
| 12994 |
if (mod && mod.__esModule) return mod; |
| 12995 |
var result = {}; |
| 12996 |
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]); |
| 12997 |
__setModuleDefault(result, mod); |
| 12998 |
return result; |
| 12999 |
} |
| 13000 |
|
| 13001 |
function __importDefault(mod) { |
| 13002 |
return (mod && mod.__esModule) ? mod : { default: mod }; |
| 13003 |
} |
| 13004 |
|
| 13005 |
function __classPrivateFieldGet(receiver, state, kind, f) { |
| 13006 |
if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a getter"); |
| 13007 |
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it"); |
| 13008 |
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver); |
| 13009 |
} |
| 13010 |
|
| 13011 |
function __classPrivateFieldSet(receiver, state, value, kind, f) { |
| 13012 |
if (kind === "m") throw new TypeError("Private method is not writable"); |
| 13013 |
if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a setter"); |
| 13014 |
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it"); |
| 13015 |
return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value; |
| 13016 |
} |
| 13017 |
|
| 13018 |
function __classPrivateFieldIn(state, receiver) { |
| 13019 |
if (receiver === null || (typeof receiver !== "object" && typeof receiver !== "function")) throw new TypeError("Cannot use 'in' operator on non-object"); |
| 13020 |
return typeof state === "function" ? receiver === state : state.has(receiver); |
| 13021 |
} |
| 13022 |
|
| 13023 |
function __addDisposableResource(env, value, async) { |
| 13024 |
if (value !== null && value !== void 0) { |
| 13025 |
if (typeof value !== "object" && typeof value !== "function") throw new TypeError("Object expected."); |
| 13026 |
var dispose, inner; |
| 13027 |
if (async) { |
| 13028 |
if (!Symbol.asyncDispose) throw new TypeError("Symbol.asyncDispose is not defined."); |
| 13029 |
dispose = value[Symbol.asyncDispose]; |
| 13030 |
} |
| 13031 |
if (dispose === void 0) { |
| 13032 |
if (!Symbol.dispose) throw new TypeError("Symbol.dispose is not defined."); |
| 13033 |
dispose = value[Symbol.dispose]; |
| 13034 |
if (async) inner = dispose; |
| 13035 |
} |
| 13036 |
if (typeof dispose !== "function") throw new TypeError("Object not disposable."); |
| 13037 |
if (inner) dispose = function() { try { inner.call(this); } catch (e) { return Promise.reject(e); } }; |
| 13038 |
env.stack.push({ value: value, dispose: dispose, async: async }); |
| 13039 |
} |
| 13040 |
else if (async) { |
| 13041 |
env.stack.push({ async: true }); |
| 13042 |
} |
| 13043 |
return value; |
| 13044 |
} |
| 13045 |
|
| 13046 |
var _SuppressedError = typeof SuppressedError === "function" ? SuppressedError : function (error, suppressed, message) { |
| 13047 |
var e = new Error(message); |
| 13048 |
return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e; |
| 13049 |
}; |
| 13050 |
|
| 13051 |
function __disposeResources(env) { |
| 13052 |
function fail(e) { |
| 13053 |
env.error = env.hasError ? new _SuppressedError(e, env.error, "An error was suppressed during disposal.") : e; |
| 13054 |
env.hasError = true; |
| 13055 |
} |
| 13056 |
var r, s = 0; |
| 13057 |
function next() { |
| 13058 |
while (r = env.stack.pop()) { |
| 13059 |
try { |
| 13060 |
if (!r.async && s === 1) return s = 0, env.stack.push(r), Promise.resolve().then(next); |
| 13061 |
if (r.dispose) { |
| 13062 |
var result = r.dispose.call(r.value); |
| 13063 |
if (r.async) return s |= 2, Promise.resolve(result).then(next, function(e) { fail(e); return next(); }); |
| 13064 |
} |
| 13065 |
else s |= 1; |
| 13066 |
} |
| 13067 |
catch (e) { |
| 13068 |
fail(e); |
| 13069 |
} |
| 13070 |
} |
| 13071 |
if (s === 1) return env.hasError ? Promise.reject(env.error) : Promise.resolve(); |
| 13072 |
if (env.hasError) throw env.error; |
| 13073 |
} |
| 13074 |
return next(); |
| 13075 |
} |
| 13076 |
|
| 13077 |
function __rewriteRelativeImportExtension(path, preserveJsx) { |
| 13078 |
if (typeof path === "string" && /^\.\.?\//.test(path)) { |
| 13079 |
return path.replace(/\.(tsx)$|((?:\.d)?)((?:\.[^./]+?)?)\.([cm]?)ts$/i, function (m, tsx, d, ext, cm) { |
| 13080 |
return tsx ? preserveJsx ? ".jsx" : ".js" : d && (!ext || !cm) ? m : (d + ext + "." + cm.toLowerCase() + "js"); |
| 13081 |
}); |
| 13082 |
} |
| 13083 |
return path; |
| 13084 |
} |
| 13085 |
|
| 13086 |
/* unused harmony default export */ var __WEBPACK_DEFAULT_EXPORT__ = ({ |
| 13087 |
__extends, |
| 13088 |
__assign, |
| 13089 |
__rest, |
| 13090 |
__decorate, |
| 13091 |
__param, |
| 13092 |
__esDecorate, |
| 13093 |
__runInitializers, |
| 13094 |
__propKey, |
| 13095 |
__setFunctionName, |
| 13096 |
__metadata, |
| 13097 |
__awaiter, |
| 13098 |
__generator, |
| 13099 |
__createBinding, |
| 13100 |
__exportStar, |
| 13101 |
__values, |
| 13102 |
__read, |
| 13103 |
__spread, |
| 13104 |
__spreadArrays, |
| 13105 |
__spreadArray, |
| 13106 |
__await, |
| 13107 |
__asyncGenerator, |
| 13108 |
__asyncDelegator, |
| 13109 |
__asyncValues, |
| 13110 |
__makeTemplateObject, |
| 13111 |
__importStar, |
| 13112 |
__importDefault, |
| 13113 |
__classPrivateFieldGet, |
| 13114 |
__classPrivateFieldSet, |
| 13115 |
__classPrivateFieldIn, |
| 13116 |
__addDisposableResource, |
| 13117 |
__disposeResources, |
| 13118 |
__rewriteRelativeImportExtension, |
| 13119 |
}); |
| 13120 |
|
| 13121 |
|
| 13122 |
/***/ }), |
| 13123 |
|
| 13124 |
/***/ 31927: |
| 13125 |
/***/ (function(module) { |
| 13126 |
|
| 13127 |
module.exports["default"] = ["Scrivi qualcosa...","A proposito di Jodit","Jodit Editor","Guida utente di Jodit","contiene una guida dettagliata per l'uso.","Per informazioni sulla licenza, si prega di visitare il nostro sito web:","Acquista la versione completa","Copyright © XDSoft.net - Chupurnov Valeriy. Tutti i diritti riservati.","Link","Apri in una nuova scheda","Apri l'editor a schermo intero","Pulisci Formattazione","Colore di sfondo o del testo","Ripristina","Annulla","Grassetto","Corsivo","Inserisci lista non ordinata","Inserisci lista ordinata","Allinea al centro","Allineamento Giustificato","Allinea a Sinistra","Allinea a Destra","Inserisci una linea orizzontale","Inserisci immagine","Inserisci un file","Inserisci video Youtube/Vimeo","Inserisci link","Dimensione carattere","Tipo di font","Inserisci blocco","Normale","Intestazione 1","Intestazione 2","Intestazione 3","Intestazione 4","Citazione","Codice","Inserisci","Inserisci tabella","Riduci il rientro","Aumenta il rientro","Seleziona un carattere speciale","Inserisci un carattere speciale","Copia formato","Cambia modalita'","Margini","su","destra","giù","sinistra","Stili CSS","Classi CSS","Allinea","Destra","Centro","Sinistra","--Non Impostato--","Fonte","Titolo","Testo Alternativo","Link","Apri il link in una nuova scheda","Immagine","Archivio","Avanzato","Proprietà dell'immagine","Annulla","Accetta","Cerca file","Errore durante il caricamento dell'elenco","Errore durante il caricamento delle cartelle","Sei sicuro?","Inserisci il nome della cartella","Crea cartella","Digita il nome","Cancella immagine","Cancella file","o clicca","Testo alternativo","Carica","Sfoglia","Sfondo","Testo","Su","Centro","Sotto","Inserisci la colonna prima","Inserisci la colonna dopo","Inserisci la riga sopra","Inserisci la riga sotto","Elimina tabella","Elimina riga","Elimina colonna","Cella vuota","Caratteri: %d","Parole: %d","Barrato","Sottolineato","indice","pedice","Taglia selezione","Seleziona tutto","Pausa","Cerca per","Sostituisci con","Sostituisci","Incolla","Seleziona il contenuto da incollare","risorsa","Grassetto","Corsivo","Pennello","Link","Annulla","Ripristina","Tabella","Immagine","Gomma","Paragrafo","Dimensione del carattere","Video","Font","Approposito di","Stampa","Sottolineato","Barrato","aumenta rientro","riduci rientro","espandi","comprimi","linea orizzontale","lista non ordinata","lista ordinata","Taglia","Seleziona tutto","Includi codice","Apri link","Modifica link","Non seguire","Rimuovi link","Aggiorna","Per modificare","Recensione"," URL","Modifica","Allineamento orizzontale","Filtro","Ordina per data di modifica","Ordina per nome","Ordina per dimensione","Aggiungi cartella","Reset","Salva","Salva con nome...","Ridimensiona","Ritaglia","Larghezza","Altezza","Mantieni le proporzioni","Si","No","Rimuovi","Seleziona","Seleziona: %s","Allineamento verticala","Dividi","Fondi","Aggiungi colonna","Aggiungi riga","Licenza: %s","Cancella","Dividi verticalmente","Dividi orizzontale","Bordo","Il codice è simile all'HTML. Mantieni come HTML?","Incolla come HTML","Mantieni","Inserisci come testo","Inserisci solo il testo","Puoi modificare solo le tue immagini. Vuoi scaricare questa immagine dal server?","L'immagine è stata caricata correttamente sul server!","tavolozza","Non ci sono file in questa directory.","Rinomina","Inserisci un nuovo nome","anteprima","Scarica","Incolla dagli appunti","Il tuo browser non supporta l'accesso diretto agli appunti.","Copia selezione","copia","Border radius","Mostra tutti","Applica","Si prega di compilare questo campo","Si prega di inserire un indirizzo web","Default","Cerchio","Punto","Quadrato","Trova","Trova Precedente","Trova Successivo","Il contenuto incollato proviene da un documento Microsoft Word / Excel. Vuoi mantenere il formato o pulirlo?","Incolla testo da Word rilevato","Pulisci","Inserisci il nome della classe","Premere Alt per il ridimensionamento personalizzato",null,null,null,"Tutto"] |
| 13128 |
|
| 13129 |
/***/ }), |
| 13130 |
|
| 13131 |
/***/ 32013: |
| 13132 |
/***/ (function(module) { |
| 13133 |
|
| 13134 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M1472 930v318q0 119-84.5 203.5t-203.5 84.5h-832q-119 0-203.5-84.5t-84.5-203.5v-832q0-119 84.5-203.5t203.5-84.5h832q63 0 117 25 15 7 18 23 3 17-9 29l-49 49q-10 10-23 10-3 0-9-2-23-6-45-6h-832q-66 0-113 47t-47 113v832q0 66 47 113t113 47h832q66 0 113-47t47-113v-254q0-13 9-22l64-64q10-10 23-10 6 0 12 3 20 8 20 29zm231-489l-814 814q-24 24-57 24t-57-24l-430-430q-24-24-24-57t24-57l110-110q24-24 57-24t57 24l263 263 647-647q24-24 57-24t57 24l110 110q24 24 24 57t-24 57z\"/> </svg>" |
| 13135 |
|
| 13136 |
/***/ }), |
| 13137 |
|
| 13138 |
/***/ 32328: |
| 13139 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 13140 |
|
| 13141 |
"use strict"; |
| 13142 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 13143 |
/* harmony export */ splitArray: function() { return /* binding */ splitArray; } |
| 13144 |
/* harmony export */ }); |
| 13145 |
/*! |
| 13146 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 13147 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 13148 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 13149 |
*/ /** |
| 13150 |
* @module helpers/array |
| 13151 |
*/ /** |
| 13152 |
* Return an array from string or array |
| 13153 |
* ```javascript |
| 13154 |
* Jodit.modules.Helpers.splitArray('1,2,3') // ['1', '2', '3'] |
| 13155 |
* Jodit.modules.Helpers.splitArray(['1', '2', '3']) // ['1', '2', '3'] |
| 13156 |
* ``` |
| 13157 |
*/ function splitArray(a) { |
| 13158 |
return Array.isArray(a) ? a : a.split(/[,\s]+/); |
| 13159 |
} |
| 13160 |
|
| 13161 |
|
| 13162 |
/***/ }), |
| 13163 |
|
| 13164 |
/***/ 32855: |
| 13165 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 13166 |
|
| 13167 |
"use strict"; |
| 13168 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 13169 |
/* harmony export */ Response: function() { return /* binding */ Response; } |
| 13170 |
/* harmony export */ }); |
| 13171 |
/* harmony import */ var _swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(49376); |
| 13172 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(25045); |
| 13173 |
/*! |
| 13174 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 13175 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 13176 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 13177 |
*/ /** |
| 13178 |
* @module request |
| 13179 |
*/ |
| 13180 |
|
| 13181 |
class Response { |
| 13182 |
get url() { |
| 13183 |
return this.request.url; |
| 13184 |
} |
| 13185 |
json() { |
| 13186 |
return (0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 13187 |
return JSON.parse(this.body); |
| 13188 |
}).call(this); |
| 13189 |
} |
| 13190 |
text() { |
| 13191 |
return Promise.resolve(this.body); |
| 13192 |
} |
| 13193 |
blob() { |
| 13194 |
return (0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 13195 |
return this.body; |
| 13196 |
}).call(this); |
| 13197 |
} |
| 13198 |
constructor(request, status, statusText, body){ |
| 13199 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(this, "status", void 0); |
| 13200 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(this, "statusText", void 0); |
| 13201 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(this, "request", void 0); |
| 13202 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(this, "body", void 0); |
| 13203 |
this.request = request; |
| 13204 |
this.status = status; |
| 13205 |
this.statusText = statusText; |
| 13206 |
this.body = body; |
| 13207 |
} |
| 13208 |
} |
| 13209 |
|
| 13210 |
|
| 13211 |
/***/ }), |
| 13212 |
|
| 13213 |
/***/ 33201: |
| 13214 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 13215 |
|
| 13216 |
"use strict"; |
| 13217 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 13218 |
/* harmony export */ ConnectionError: function() { return /* reexport safe */ _errors___WEBPACK_IMPORTED_MODULE_1__.ConnectionError; }, |
| 13219 |
/* harmony export */ OptionsError: function() { return /* reexport safe */ _errors___WEBPACK_IMPORTED_MODULE_1__.OptionsError; }, |
| 13220 |
/* harmony export */ abort: function() { return /* reexport safe */ _errors___WEBPACK_IMPORTED_MODULE_1__.abort; }, |
| 13221 |
/* harmony export */ connection: function() { return /* reexport safe */ _error__WEBPACK_IMPORTED_MODULE_0__.connection; }, |
| 13222 |
/* harmony export */ error: function() { return /* reexport safe */ _error__WEBPACK_IMPORTED_MODULE_0__.error; }, |
| 13223 |
/* harmony export */ options: function() { return /* reexport safe */ _error__WEBPACK_IMPORTED_MODULE_0__.options; } |
| 13224 |
/* harmony export */ }); |
| 13225 |
/* harmony import */ var _error__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(38027); |
| 13226 |
/* harmony import */ var _errors___WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(29953); |
| 13227 |
/*! |
| 13228 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 13229 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 13230 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 13231 |
*/ /** |
| 13232 |
* @module helpers/utils |
| 13233 |
*/ |
| 13234 |
|
| 13235 |
|
| 13236 |
|
| 13237 |
/***/ }), |
| 13238 |
|
| 13239 |
/***/ 33433: |
| 13240 |
/***/ (function(module) { |
| 13241 |
|
| 13242 |
/*! |
| 13243 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 13244 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 13245 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 13246 |
*/ module.exports = { |
| 13247 |
symbols: 'symbol' |
| 13248 |
}; |
| 13249 |
|
| 13250 |
|
| 13251 |
/***/ }), |
| 13252 |
|
| 13253 |
/***/ 33511: |
| 13254 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 13255 |
|
| 13256 |
"use strict"; |
| 13257 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 13258 |
/* harmony export */ Stack: function() { return /* binding */ Stack; } |
| 13259 |
/* harmony export */ }); |
| 13260 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 13261 |
/*! |
| 13262 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 13263 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 13264 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 13265 |
*/ /** |
| 13266 |
* @module modules/history |
| 13267 |
*/ |
| 13268 |
class Stack { |
| 13269 |
get length() { |
| 13270 |
return this.commands.length; |
| 13271 |
} |
| 13272 |
clearRedo() { |
| 13273 |
this.commands.length = this.stackPosition + 1; |
| 13274 |
} |
| 13275 |
clear() { |
| 13276 |
this.commands.length = 0; |
| 13277 |
this.stackPosition = -1; |
| 13278 |
} |
| 13279 |
push(command) { |
| 13280 |
this.clearRedo(); |
| 13281 |
this.commands.push(command); |
| 13282 |
this.stackPosition += 1; |
| 13283 |
if (this.commands.length > this.size) { |
| 13284 |
this.commands.shift(); |
| 13285 |
this.stackPosition -= 1; |
| 13286 |
} |
| 13287 |
} |
| 13288 |
replace(command) { |
| 13289 |
this.commands[this.stackPosition] = command; |
| 13290 |
} |
| 13291 |
current() { |
| 13292 |
return this.commands[this.stackPosition]; |
| 13293 |
} |
| 13294 |
undo() { |
| 13295 |
if (this.canUndo()) { |
| 13296 |
if (this.commands[this.stackPosition]) { |
| 13297 |
this.commands[this.stackPosition].undo(); |
| 13298 |
} |
| 13299 |
this.stackPosition -= 1; |
| 13300 |
return true; |
| 13301 |
} |
| 13302 |
return false; |
| 13303 |
} |
| 13304 |
redo() { |
| 13305 |
if (this.canRedo()) { |
| 13306 |
this.stackPosition += 1; |
| 13307 |
if (this.commands[this.stackPosition]) { |
| 13308 |
this.commands[this.stackPosition].redo(); |
| 13309 |
} |
| 13310 |
return true; |
| 13311 |
} |
| 13312 |
return false; |
| 13313 |
} |
| 13314 |
canUndo() { |
| 13315 |
return this.stackPosition >= 0; |
| 13316 |
} |
| 13317 |
canRedo() { |
| 13318 |
return this.stackPosition < this.commands.length - 1; |
| 13319 |
} |
| 13320 |
constructor(size){ |
| 13321 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "size", void 0); |
| 13322 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "commands", void 0); |
| 13323 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "stackPosition", void 0); |
| 13324 |
this.size = size; |
| 13325 |
this.commands = []; |
| 13326 |
this.stackPosition = -1; |
| 13327 |
} |
| 13328 |
} |
| 13329 |
|
| 13330 |
|
| 13331 |
/***/ }), |
| 13332 |
|
| 13333 |
/***/ 33831: |
| 13334 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 13335 |
|
| 13336 |
"use strict"; |
| 13337 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5266); |
| 13338 |
/*! |
| 13339 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 13340 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 13341 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 13342 |
*/ /** |
| 13343 |
* @module plugins/backspace |
| 13344 |
*/ |
| 13345 |
jodit_config__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.delete = { |
| 13346 |
hotkeys: { |
| 13347 |
delete: [ |
| 13348 |
'delete', |
| 13349 |
'cmd+backspace' |
| 13350 |
], |
| 13351 |
deleteWord: [ |
| 13352 |
'ctrl+delete', |
| 13353 |
'cmd+alt+backspace', |
| 13354 |
'ctrl+alt+backspace' |
| 13355 |
], |
| 13356 |
deleteSentence: [ |
| 13357 |
'ctrl+shift+delete', |
| 13358 |
'cmd+shift+delete' |
| 13359 |
], |
| 13360 |
backspace: [ |
| 13361 |
'backspace' |
| 13362 |
], |
| 13363 |
backspaceWord: [ |
| 13364 |
'ctrl+backspace' |
| 13365 |
], |
| 13366 |
backspaceSentence: [ |
| 13367 |
'ctrl+shift+backspace', |
| 13368 |
'cmd+shift+backspace' |
| 13369 |
] |
| 13370 |
} |
| 13371 |
}; |
| 13372 |
|
| 13373 |
|
| 13374 |
/***/ }), |
| 13375 |
|
| 13376 |
/***/ 34027: |
| 13377 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 13378 |
|
| 13379 |
"use strict"; |
| 13380 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 13381 |
/* harmony export */ getScrollParent: function() { return /* binding */ getScrollParent; } |
| 13382 |
/* harmony export */ }); |
| 13383 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 13384 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(23211); |
| 13385 |
/* harmony import */ var jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(93640); |
| 13386 |
/*! |
| 13387 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 13388 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 13389 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 13390 |
*/ /** |
| 13391 |
* @module helpers/size |
| 13392 |
*/ |
| 13393 |
|
| 13394 |
|
| 13395 |
function getScrollParent(node) { |
| 13396 |
if (!node) { |
| 13397 |
return null; |
| 13398 |
} |
| 13399 |
const isElement = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isHTMLElement(node); |
| 13400 |
const overflowY = isElement && (0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_2__.css)(node, 'overflowY'); |
| 13401 |
const isScrollable = isElement && overflowY !== 'visible' && overflowY !== 'hidden'; |
| 13402 |
if (isScrollable && node.scrollHeight >= node.clientHeight) { |
| 13403 |
return node; |
| 13404 |
} |
| 13405 |
return getScrollParent(node.parentNode) || jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.globalDocument.scrollingElement || jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.globalDocument.body; |
| 13406 |
} |
| 13407 |
|
| 13408 |
|
| 13409 |
/***/ }), |
| 13410 |
|
| 13411 |
/***/ 34045: |
| 13412 |
/***/ (function(module) { |
| 13413 |
|
| 13414 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M1664 256v448q0 26-19 45t-45 19h-448q-42 0-59-40-17-39 14-69l138-138q-148-137-349-137-104 0-198.5 40.5t-163.5 109.5-109.5 163.5-40.5 198.5 40.5 198.5 109.5 163.5 163.5 109.5 198.5 40.5q119 0 225-52t179-147q7-10 23-12 14 0 25 9l137 138q9 8 9.5 20.5t-7.5 22.5q-109 132-264 204.5t-327 72.5q-156 0-298-61t-245-164-164-245-61-298 61-298 164-245 245-164 298-61q147 0 284.5 55.5t244.5 156.5l130-129q29-31 70-14 39 17 39 59z\"/> </svg>" |
| 13415 |
|
| 13416 |
/***/ }), |
| 13417 |
|
| 13418 |
/***/ 34142: |
| 13419 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 13420 |
|
| 13421 |
"use strict"; |
| 13422 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(28077); |
| 13423 |
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(48899); |
| 13424 |
/*! |
| 13425 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 13426 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 13427 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 13428 |
*/ /** |
| 13429 |
* [[include:plugins/video/README.md]] |
| 13430 |
* @packageDocumentation |
| 13431 |
* @module plugins/video |
| 13432 |
*/ |
| 13433 |
|
| 13434 |
function video(editor) { |
| 13435 |
editor.registerButton({ |
| 13436 |
name: 'video', |
| 13437 |
group: 'media' |
| 13438 |
}); |
| 13439 |
} |
| 13440 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_0__.pluginSystem.add('video', video); |
| 13441 |
|
| 13442 |
|
| 13443 |
/***/ }), |
| 13444 |
|
| 13445 |
/***/ 34269: |
| 13446 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 13447 |
|
| 13448 |
"use strict"; |
| 13449 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 13450 |
/* harmony export */ nativeListeners: function() { return /* binding */ nativeListeners; } |
| 13451 |
/* harmony export */ }); |
| 13452 |
/* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7909); |
| 13453 |
/* harmony import */ var jodit_core_helpers_utils_ctrl_key__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(77213); |
| 13454 |
/* harmony import */ var jodit_modules_file_browser_builders_context_menu__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(61334); |
| 13455 |
/* harmony import */ var jodit_modules_file_browser_builders_elements_map__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(31125); |
| 13456 |
/* harmony import */ var jodit_modules_file_browser_builders_utils__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(66206); |
| 13457 |
/* harmony import */ var jodit_modules_file_browser_fetch_load_tree__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(53202); |
| 13458 |
/*! |
| 13459 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 13460 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 13461 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 13462 |
*/ /** |
| 13463 |
* @module modules/file-browser |
| 13464 |
*/ |
| 13465 |
|
| 13466 |
|
| 13467 |
|
| 13468 |
|
| 13469 |
|
| 13470 |
/** |
| 13471 |
* @private |
| 13472 |
*/ function nativeListeners() { |
| 13473 |
let dragElement = false; |
| 13474 |
const elmMap = (0,jodit_modules_file_browser_builders_elements_map__WEBPACK_IMPORTED_MODULE_3__.elementsMap)(this); |
| 13475 |
const self = this; |
| 13476 |
self.e.on(self.tree.container, 'dragstart', (e)=>{ |
| 13477 |
const a = (0,jodit_modules_file_browser_builders_utils__WEBPACK_IMPORTED_MODULE_4__.getItem)(e.target, self.container); |
| 13478 |
if (!a) { |
| 13479 |
return; |
| 13480 |
} |
| 13481 |
if (self.o.moveFolder) { |
| 13482 |
dragElement = a; |
| 13483 |
} |
| 13484 |
}).on(self.tree.container, 'drop', (e)=>{ |
| 13485 |
if ((self.o.moveFile || self.o.moveFolder) && dragElement) { |
| 13486 |
let path = (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_0__.attr)(dragElement, '-path') || ''; |
| 13487 |
// move folder |
| 13488 |
if (!self.o.moveFolder && dragElement.classList.contains(this.tree.getFullElName('item'))) { |
| 13489 |
return false; |
| 13490 |
} |
| 13491 |
// move file |
| 13492 |
if (dragElement.classList.contains(this.files.getFullElName('item'))) { |
| 13493 |
path += (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_0__.attr)(dragElement, '-name'); |
| 13494 |
if (!self.o.moveFile) { |
| 13495 |
return false; |
| 13496 |
} |
| 13497 |
} |
| 13498 |
const a = (0,jodit_modules_file_browser_builders_utils__WEBPACK_IMPORTED_MODULE_4__.getItem)(e.target, self.container); |
| 13499 |
if (!a) { |
| 13500 |
return; |
| 13501 |
} |
| 13502 |
self.dataProvider.move(path, (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_0__.attr)(a, '-path') || '', (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_0__.attr)(a, '-source') || '', dragElement.classList.contains(this.files.getFullElName('item'))).then(()=>(0,jodit_modules_file_browser_fetch_load_tree__WEBPACK_IMPORTED_MODULE_5__.loadTree)(this)).catch(self.status); |
| 13503 |
dragElement = false; |
| 13504 |
} |
| 13505 |
}).on(self.files.container, 'contextmenu', (0,jodit_modules_file_browser_builders_context_menu__WEBPACK_IMPORTED_MODULE_2__["default"])(self)).on(self.files.container, 'click', (e)=>{ |
| 13506 |
if (!(0,jodit_core_helpers_utils_ctrl_key__WEBPACK_IMPORTED_MODULE_1__.ctrlKey)(e)) { |
| 13507 |
this.state.activeElements = []; |
| 13508 |
} |
| 13509 |
}).on(self.files.container, 'click', (e)=>{ |
| 13510 |
const a = (0,jodit_modules_file_browser_builders_utils__WEBPACK_IMPORTED_MODULE_4__.getItem)(e.target, self.container); |
| 13511 |
if (!a) { |
| 13512 |
return; |
| 13513 |
} |
| 13514 |
const item = (0,jodit_modules_file_browser_builders_utils__WEBPACK_IMPORTED_MODULE_4__.elementToItem)(a, elmMap); |
| 13515 |
if (!item) { |
| 13516 |
return; |
| 13517 |
} |
| 13518 |
if (!(0,jodit_core_helpers_utils_ctrl_key__WEBPACK_IMPORTED_MODULE_1__.ctrlKey)(e)) { |
| 13519 |
self.state.activeElements = [ |
| 13520 |
item |
| 13521 |
]; |
| 13522 |
} else { |
| 13523 |
self.state.activeElements = [ |
| 13524 |
...self.state.activeElements, |
| 13525 |
item |
| 13526 |
]; |
| 13527 |
} |
| 13528 |
e.stopPropagation(); |
| 13529 |
return false; |
| 13530 |
}).on(self.files.container, 'dragstart', (e)=>{ |
| 13531 |
if (self.o.moveFile) { |
| 13532 |
const a = (0,jodit_modules_file_browser_builders_utils__WEBPACK_IMPORTED_MODULE_4__.getItem)(e.target, self.container); |
| 13533 |
if (!a) { |
| 13534 |
return; |
| 13535 |
} |
| 13536 |
dragElement = a; |
| 13537 |
} |
| 13538 |
}).on(self.container, 'drop', (e)=>e.preventDefault()); |
| 13539 |
} |
| 13540 |
|
| 13541 |
|
| 13542 |
/***/ }), |
| 13543 |
|
| 13544 |
/***/ 34287: |
| 13545 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 13546 |
|
| 13547 |
"use strict"; |
| 13548 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 13549 |
/* harmony export */ checkBR: function() { return /* binding */ checkBR; } |
| 13550 |
/* harmony export */ }); |
| 13551 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 13552 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(23211); |
| 13553 |
/* harmony import */ var jodit_core_helpers_utils_scroll_into_view__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(60898); |
| 13554 |
/*! |
| 13555 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 13556 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 13557 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 13558 |
*/ /** |
| 13559 |
* @module plugins/enter |
| 13560 |
*/ |
| 13561 |
|
| 13562 |
|
| 13563 |
/** |
| 13564 |
* Checks the possibility and necessity of inserting a BR instead of a block |
| 13565 |
* @private |
| 13566 |
*/ function checkBR(fake, jodit, shiftKeyPressed) { |
| 13567 |
const isMultiLineBlock = Boolean(jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.closest(fake, [ |
| 13568 |
'pre', |
| 13569 |
'blockquote' |
| 13570 |
], jodit.editor)); |
| 13571 |
const isCell = !isMultiLineBlock && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.closest(fake, [ |
| 13572 |
'td', |
| 13573 |
'th' |
| 13574 |
], jodit.editor); |
| 13575 |
const isBRMode = jodit.o.enter.toLowerCase() === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.BR.toLowerCase(); |
| 13576 |
// if you use <br> defaultTag for break line or when was entered SHIFt key or in <td> or <th> or <blockquote> |
| 13577 |
if (isBRMode || isCell || shiftKeyPressed && !isMultiLineBlock || !shiftKeyPressed && isMultiLineBlock) { |
| 13578 |
// 2 BR before |
| 13579 |
if (isMultiLineBlock && checkSeveralBR(fake)) { |
| 13580 |
return false; |
| 13581 |
} |
| 13582 |
const br = jodit.createInside.element('br'); |
| 13583 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.before(fake, br); |
| 13584 |
if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.findNotEmptySibling(br, false)) { |
| 13585 |
const clone = br.cloneNode(); |
| 13586 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.after(br, clone); |
| 13587 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.before(clone, fake); |
| 13588 |
} |
| 13589 |
(0,jodit_core_helpers_utils_scroll_into_view__WEBPACK_IMPORTED_MODULE_2__.scrollIntoViewIfNeeded)(br, jodit.editor, jodit.ed); |
| 13590 |
return true; |
| 13591 |
} |
| 13592 |
return false; |
| 13593 |
} |
| 13594 |
function checkSeveralBR(fake) { |
| 13595 |
// 2 BR before |
| 13596 |
const preBr = brBefore(brBefore(fake)); |
| 13597 |
if (preBr) { |
| 13598 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.safeRemove(brBefore(fake)); |
| 13599 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.safeRemove(preBr); |
| 13600 |
return true; |
| 13601 |
} |
| 13602 |
return false; |
| 13603 |
} |
| 13604 |
function brBefore(start) { |
| 13605 |
if (!start) { |
| 13606 |
return false; |
| 13607 |
} |
| 13608 |
const prev = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.findSibling(start, true); |
| 13609 |
if (!prev || !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isTag(prev, 'br')) { |
| 13610 |
return false; |
| 13611 |
} |
| 13612 |
return prev; |
| 13613 |
} |
| 13614 |
|
| 13615 |
|
| 13616 |
/***/ }), |
| 13617 |
|
| 13618 |
/***/ 34396: |
| 13619 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 13620 |
|
| 13621 |
"use strict"; |
| 13622 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 13623 |
/* harmony export */ ProgressBar: function() { return /* binding */ ProgressBar; } |
| 13624 |
/* harmony export */ }); |
| 13625 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 13626 |
/* harmony import */ var jodit_core_ui_element__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(96007); |
| 13627 |
/*! |
| 13628 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 13629 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 13630 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 13631 |
*/ /** |
| 13632 |
* [[include:core/ui/progress-bar/README.md]] |
| 13633 |
* @packageDocumentation |
| 13634 |
* @module ui/progress-bar |
| 13635 |
*/ |
| 13636 |
|
| 13637 |
|
| 13638 |
class ProgressBar extends jodit_core_ui_element__WEBPACK_IMPORTED_MODULE_1__.UIElement { |
| 13639 |
/** @override */ className() { |
| 13640 |
return 'ProgressBar'; |
| 13641 |
} |
| 13642 |
/** @override */ render() { |
| 13643 |
return '<div><div></div></div>'; |
| 13644 |
} |
| 13645 |
/** |
| 13646 |
* Show progress bar |
| 13647 |
*/ show() { |
| 13648 |
const container = this.j.workplace || this.j.container; |
| 13649 |
container.appendChild(this.container); |
| 13650 |
return this; |
| 13651 |
} |
| 13652 |
hide() { |
| 13653 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(this.container); |
| 13654 |
return this; |
| 13655 |
} |
| 13656 |
progress(percentage) { |
| 13657 |
this.container.style.width = percentage.toFixed(2) + '%'; |
| 13658 |
return this; |
| 13659 |
} |
| 13660 |
destruct() { |
| 13661 |
this.hide(); |
| 13662 |
return super.destruct(); |
| 13663 |
} |
| 13664 |
} |
| 13665 |
|
| 13666 |
|
| 13667 |
/***/ }), |
| 13668 |
|
| 13669 |
/***/ 34582: |
| 13670 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 13671 |
|
| 13672 |
"use strict"; |
| 13673 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 13674 |
/* harmony export */ toggleOrderedList: function() { return /* binding */ toggleOrderedList; } |
| 13675 |
/* harmony export */ }); |
| 13676 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 13677 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(28712); |
| 13678 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_1__); |
| 13679 |
/* harmony import */ var jodit_core_selection_style_api_extract__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(17481); |
| 13680 |
/* harmony import */ var jodit_core_selection_style_api_toggle_attributes__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(82794); |
| 13681 |
/* harmony import */ var jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(98394); |
| 13682 |
/* harmony import */ var _wrap_list__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(97110); |
| 13683 |
/*! |
| 13684 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 13685 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 13686 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 13687 |
*/ |
| 13688 |
|
| 13689 |
|
| 13690 |
|
| 13691 |
|
| 13692 |
|
| 13693 |
/** |
| 13694 |
* Replaces `ul->ol` or `ol->ul`, apply styles to the list, or remove a list item from it |
| 13695 |
* @private |
| 13696 |
*/ function toggleOrderedList(commitStyle, li, jodit, mode) { |
| 13697 |
if (!li) { |
| 13698 |
return mode; |
| 13699 |
} |
| 13700 |
const list = li.parentElement; |
| 13701 |
if (!list) { |
| 13702 |
return mode; |
| 13703 |
} |
| 13704 |
const result = jodit.e.fire(`${jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_4__._PREFIX}BeforeToggleList`, mode, commitStyle, list); |
| 13705 |
if (result !== undefined) { |
| 13706 |
return result; |
| 13707 |
} |
| 13708 |
const hook = jodit.e.fire.bind(jodit.e, `${jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_4__._PREFIX}AfterToggleList`); |
| 13709 |
if (mode !== jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_4__.UNWRAP) { |
| 13710 |
const isChangeMode = (0,jodit_core_selection_style_api_toggle_attributes__WEBPACK_IMPORTED_MODULE_3__.toggleAttributes)(commitStyle, li.parentElement, jodit, jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_4__.INITIAL, true) === jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_4__.CHANGE; |
| 13711 |
// ul => ol, ol => ul or ul => ul.class1 |
| 13712 |
if (mode === jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_4__.REPLACE || isChangeMode || list.tagName.toLowerCase() !== commitStyle.element) { |
| 13713 |
const wrapper = unwrapList(jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_4__.REPLACE, list, li, jodit, commitStyle); |
| 13714 |
const newList = (0,_wrap_list__WEBPACK_IMPORTED_MODULE_5__.wrapList)(commitStyle, wrapper, jodit); |
| 13715 |
hook(jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_4__.REPLACE, newList, commitStyle); |
| 13716 |
return jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_4__.REPLACE; |
| 13717 |
} |
| 13718 |
} |
| 13719 |
const wrapper = unwrapList(jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_4__.UNWRAP, list, li, jodit, commitStyle); |
| 13720 |
hook(jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_4__.UNWRAP, wrapper, commitStyle); |
| 13721 |
return jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_4__.UNWRAP; |
| 13722 |
} |
| 13723 |
function unwrapList(mode, list, li, jodit, cs) { |
| 13724 |
const result = jodit.e.fire(`${jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_4__._PREFIX}BeforeUnwrapList`, mode, list, cs); |
| 13725 |
if (result) { |
| 13726 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_1__.assert)(jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isHTMLElement(result), `${jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_4__._PREFIX}BeforeUnwrapList hook must return HTMLElement`); |
| 13727 |
return result; |
| 13728 |
} |
| 13729 |
(0,jodit_core_selection_style_api_extract__WEBPACK_IMPORTED_MODULE_2__.extractSelectedPart)(list, li, jodit); |
| 13730 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_1__.assert)(jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isHTMLElement(li.parentElement), 'Element should be inside the list'); |
| 13731 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.unwrap(li.parentElement); |
| 13732 |
return jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.replace(li, jodit.o.enter.toLowerCase() !== 'br' ? jodit.o.enter : jodit.createInside.fragment(), jodit.createInside); |
| 13733 |
} |
| 13734 |
|
| 13735 |
|
| 13736 |
/***/ }), |
| 13737 |
|
| 13738 |
/***/ 34672: |
| 13739 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 13740 |
|
| 13741 |
"use strict"; |
| 13742 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 13743 |
/* harmony export */ processEmptyLILeaf: function() { return /* binding */ processEmptyLILeaf; } |
| 13744 |
/* harmony export */ }); |
| 13745 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 13746 |
/* harmony import */ var jodit_core_helpers_utils_selector__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(28723); |
| 13747 |
/* harmony import */ var _insert_paragraph__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(65710); |
| 13748 |
/*! |
| 13749 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 13750 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 13751 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 13752 |
*/ /** |
| 13753 |
* @module plugins/enter |
| 13754 |
*/ |
| 13755 |
|
| 13756 |
|
| 13757 |
/** |
| 13758 |
* Handles pressing the Enter key inside an empty LI inside a list |
| 13759 |
* @private |
| 13760 |
*/ function processEmptyLILeaf(fake, jodit, li) { |
| 13761 |
const list = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(li, [ |
| 13762 |
'ol', |
| 13763 |
'ul' |
| 13764 |
], jodit.editor); |
| 13765 |
if (!list) { |
| 13766 |
return; |
| 13767 |
} |
| 13768 |
const parentLi = list.parentElement, listInsideLeaf = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isLeaf(parentLi); |
| 13769 |
const container = listInsideLeaf ? parentLi : list; |
| 13770 |
// Empty element in the middle of the list |
| 13771 |
const leftRange = jodit.s.createRange(); |
| 13772 |
leftRange.setStartAfter(li); |
| 13773 |
leftRange.setEndAfter(list); |
| 13774 |
const rightPart = leftRange.extractContents(); |
| 13775 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.after(container, fake); |
| 13776 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(li); |
| 13777 |
if (!(0,jodit_core_helpers_utils_selector__WEBPACK_IMPORTED_MODULE_1__.$$)('li', list).length) { |
| 13778 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(list); |
| 13779 |
} |
| 13780 |
const newLi = (0,_insert_paragraph__WEBPACK_IMPORTED_MODULE_2__.insertParagraph)(fake, jodit, listInsideLeaf ? 'li' : jodit.o.enter); |
| 13781 |
if (!rightPart.querySelector('li')) { |
| 13782 |
return; |
| 13783 |
} |
| 13784 |
if (listInsideLeaf) { |
| 13785 |
newLi.appendChild(rightPart); |
| 13786 |
} else { |
| 13787 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.after(newLi, rightPart); |
| 13788 |
} |
| 13789 |
} |
| 13790 |
|
| 13791 |
|
| 13792 |
/***/ }), |
| 13793 |
|
| 13794 |
/***/ 34689: |
| 13795 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 13796 |
|
| 13797 |
"use strict"; |
| 13798 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5266); |
| 13799 |
/*! |
| 13800 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 13801 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 13802 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 13803 |
*/ /** |
| 13804 |
* @module plugins/image-properties |
| 13805 |
*/ |
| 13806 |
jodit_config__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.image = { |
| 13807 |
dialogWidth: 600, |
| 13808 |
openOnDblClick: true, |
| 13809 |
editSrc: true, |
| 13810 |
useImageEditor: true, |
| 13811 |
editTitle: true, |
| 13812 |
editAlt: true, |
| 13813 |
editLink: true, |
| 13814 |
editSize: true, |
| 13815 |
editBorderRadius: true, |
| 13816 |
editMargins: true, |
| 13817 |
editClass: true, |
| 13818 |
availableClasses: [], |
| 13819 |
editStyle: true, |
| 13820 |
editId: true, |
| 13821 |
editAlign: true, |
| 13822 |
showPreview: true, |
| 13823 |
selectImageAfterClose: true |
| 13824 |
}; |
| 13825 |
|
| 13826 |
|
| 13827 |
/***/ }), |
| 13828 |
|
| 13829 |
/***/ 35099: |
| 13830 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 13831 |
|
| 13832 |
"use strict"; |
| 13833 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 13834 |
/* harmony export */ View: function() { return /* binding */ View; } |
| 13835 |
/* harmony export */ }); |
| 13836 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 13837 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 13838 |
/* harmony import */ var jodit_core_component__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(16964); |
| 13839 |
/* harmony import */ var jodit_core_component_component__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(80251); |
| 13840 |
/* harmony import */ var jodit_core_component_statuses__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(69364); |
| 13841 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(81937); |
| 13842 |
/* harmony import */ var jodit_core_create_create__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(76517); |
| 13843 |
/* harmony import */ var jodit_core_decorators_cache_cache__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(51676); |
| 13844 |
/* harmony import */ var jodit_core_decorators_derive_derive__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(24968); |
| 13845 |
/* harmony import */ var jodit_core_decorators_hook_hook__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(29200); |
| 13846 |
/* harmony import */ var jodit_core_dom__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(27795); |
| 13847 |
/* harmony import */ var jodit_core_event_emitter__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(1496); |
| 13848 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(28077); |
| 13849 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(65946); |
| 13850 |
/* harmony import */ var jodit_core_storage_async_storage__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(8006); |
| 13851 |
/* harmony import */ var jodit_core_storage_storage__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(24475); |
| 13852 |
/* harmony import */ var jodit_core_traits_elms__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(23183); |
| 13853 |
/* harmony import */ var jodit_core_traits_mods__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(81987); |
| 13854 |
/* harmony import */ var jodit_core_ui_progress_bar_progress_bar__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(34396); |
| 13855 |
/* harmony import */ var jodit_modules_messages_messages__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(10081); |
| 13856 |
/*! |
| 13857 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 13858 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 13859 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 13860 |
*/ /** |
| 13861 |
* [[include:core/view/README.md]] |
| 13862 |
* @packageDocumentation |
| 13863 |
* @module view |
| 13864 |
*/ |
| 13865 |
|
| 13866 |
|
| 13867 |
|
| 13868 |
|
| 13869 |
|
| 13870 |
|
| 13871 |
|
| 13872 |
|
| 13873 |
|
| 13874 |
|
| 13875 |
|
| 13876 |
|
| 13877 |
|
| 13878 |
|
| 13879 |
|
| 13880 |
|
| 13881 |
|
| 13882 |
|
| 13883 |
|
| 13884 |
class View extends jodit_core_component_component__WEBPACK_IMPORTED_MODULE_3__.Component { |
| 13885 |
/** |
| 13886 |
* Get a path for loading extra staff |
| 13887 |
*/ get basePath() { |
| 13888 |
if (this.o.basePath) { |
| 13889 |
return this.o.basePath; |
| 13890 |
} |
| 13891 |
return jodit_core_constants__WEBPACK_IMPORTED_MODULE_5__.BASE_PATH; |
| 13892 |
} |
| 13893 |
/** |
| 13894 |
* Plugin autoloader should load minified version of the file |
| 13895 |
*/ get minified() { |
| 13896 |
if (this.o.minified !== undefined) { |
| 13897 |
return this.o.minified; |
| 13898 |
} |
| 13899 |
return jodit_core_constants__WEBPACK_IMPORTED_MODULE_5__.BASE_PATH_IS_MIN; |
| 13900 |
} |
| 13901 |
/** |
| 13902 |
* Return a default timeout period in milliseconds for some debounce or throttle functions. |
| 13903 |
* By default, `{history.timeout}` options |
| 13904 |
*/ get defaultTimeout() { |
| 13905 |
return (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_13__.isVoid)(this.o.defaultTimeout) ? 100 : this.o.defaultTimeout; |
| 13906 |
} |
| 13907 |
/** |
| 13908 |
* Some extra data inside editor |
| 13909 |
* @see copyformat plugin |
| 13910 |
*/ get buffer() { |
| 13911 |
return jodit_core_storage_storage__WEBPACK_IMPORTED_MODULE_15__.Storage.makeStorage(); |
| 13912 |
} |
| 13913 |
get message() { |
| 13914 |
return this.getMessageModule(this.container); |
| 13915 |
} |
| 13916 |
getMessageModule(container) { |
| 13917 |
return new jodit_modules_messages_messages__WEBPACK_IMPORTED_MODULE_19__.UIMessages(this, container); |
| 13918 |
} |
| 13919 |
/** |
| 13920 |
* Container for persistent set/get value |
| 13921 |
* @deprecated Use asyncStorage instead |
| 13922 |
*/ get storage() { |
| 13923 |
return jodit_core_storage_storage__WEBPACK_IMPORTED_MODULE_15__.Storage.makeStorage(true, this.id); |
| 13924 |
} |
| 13925 |
/** |
| 13926 |
* Container for persistent set/get value |
| 13927 |
*/ get asyncStorage() { |
| 13928 |
return jodit_core_storage_async_storage__WEBPACK_IMPORTED_MODULE_14__.AsyncStorage.makeStorage(true, this.id); |
| 13929 |
} |
| 13930 |
/** |
| 13931 |
* Short alias for `create` |
| 13932 |
*/ get c() { |
| 13933 |
return this.create; |
| 13934 |
} |
| 13935 |
get container() { |
| 13936 |
return this.__container; |
| 13937 |
} |
| 13938 |
set container(container) { |
| 13939 |
this.__container = container; |
| 13940 |
} |
| 13941 |
/** |
| 13942 |
* Short alias for `events` |
| 13943 |
*/ get e() { |
| 13944 |
return this.events; |
| 13945 |
} |
| 13946 |
/** |
| 13947 |
* progress_bar Progress bar |
| 13948 |
*/ get progressbar() { |
| 13949 |
return new jodit_core_ui_progress_bar_progress_bar__WEBPACK_IMPORTED_MODULE_18__.ProgressBar(this); |
| 13950 |
} |
| 13951 |
get options() { |
| 13952 |
return this.__options; |
| 13953 |
} |
| 13954 |
set options(options) { |
| 13955 |
this.__options = options; |
| 13956 |
} |
| 13957 |
/** |
| 13958 |
* Short alias for options |
| 13959 |
*/ get o() { |
| 13960 |
return this.options; |
| 13961 |
} |
| 13962 |
/** |
| 13963 |
* Internationalization method. Uses Jodit.lang object |
| 13964 |
*/ i18n(text, ...params) { |
| 13965 |
return (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_13__.i18n)(text, params, this.options); |
| 13966 |
} |
| 13967 |
toggleFullSize(isFullSize) { |
| 13968 |
if (isFullSize === undefined) { |
| 13969 |
isFullSize = !this.__isFullSize; |
| 13970 |
} |
| 13971 |
if (isFullSize === this.__isFullSize) { |
| 13972 |
return; |
| 13973 |
} |
| 13974 |
this.__isFullSize = isFullSize; |
| 13975 |
this.e.fire('toggleFullSize', isFullSize); |
| 13976 |
} |
| 13977 |
/** |
| 13978 |
* View is locked |
| 13979 |
*/ get isLocked() { |
| 13980 |
return this.__whoLocked !== ''; |
| 13981 |
} |
| 13982 |
/** |
| 13983 |
* Disable selecting |
| 13984 |
*/ lock(name = 'any') { |
| 13985 |
if (!this.isLocked) { |
| 13986 |
this.__whoLocked = name; |
| 13987 |
return true; |
| 13988 |
} |
| 13989 |
return false; |
| 13990 |
} |
| 13991 |
/** |
| 13992 |
* Enable selecting |
| 13993 |
*/ unlock() { |
| 13994 |
if (this.isLocked) { |
| 13995 |
this.__whoLocked = ''; |
| 13996 |
return true; |
| 13997 |
} |
| 13998 |
return false; |
| 13999 |
} |
| 14000 |
/** |
| 14001 |
* View is in fullSize |
| 14002 |
*/ get isFullSize() { |
| 14003 |
return this.__isFullSize; |
| 14004 |
} |
| 14005 |
/** |
| 14006 |
* Return current version |
| 14007 |
*/ getVersion() { |
| 14008 |
return View.version; |
| 14009 |
} |
| 14010 |
static getVersion() { |
| 14011 |
return View.version; |
| 14012 |
} |
| 14013 |
/** @override */ initOptions(options) { |
| 14014 |
this.options = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_13__.ConfigProto)(options || {}, (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_13__.ConfigProto)(this.options || {}, View.defaultOptions)); |
| 14015 |
} |
| 14016 |
/** |
| 14017 |
* Can change ownerWindow here |
| 14018 |
*/ initOwners() { |
| 14019 |
var _this_o_ownerWindow; |
| 14020 |
this.ownerWindow = (_this_o_ownerWindow = this.o.ownerWindow) !== null && _this_o_ownerWindow !== void 0 ? _this_o_ownerWindow : window; |
| 14021 |
} |
| 14022 |
/** |
| 14023 |
* Add option's event handlers in emitter |
| 14024 |
*/ attachEvents(options) { |
| 14025 |
if (!options) { |
| 14026 |
return; |
| 14027 |
} |
| 14028 |
const e = options === null || options === void 0 ? void 0 : options.events; |
| 14029 |
e && Object.keys(e).forEach((key)=>this.e.on(key, e[key])); |
| 14030 |
} |
| 14031 |
getInstance(moduleNameOrConstructor, options) { |
| 14032 |
const moduleName = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_13__.isFunction)(moduleNameOrConstructor) ? moduleNameOrConstructor.prototype.className() : moduleNameOrConstructor; |
| 14033 |
const instance = this.e.fire((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_13__.camelCase)('getInstance_' + moduleName), options); |
| 14034 |
if (instance) { |
| 14035 |
return instance; |
| 14036 |
} |
| 14037 |
const module = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_13__.isFunction)(moduleNameOrConstructor) ? moduleNameOrConstructor : jodit_core_global__WEBPACK_IMPORTED_MODULE_12__.modules[moduleName], mi = this.__modulesInstances; |
| 14038 |
if (!(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_13__.isFunction)(module)) { |
| 14039 |
throw (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_13__.error)('Need real module name'); |
| 14040 |
} |
| 14041 |
if (!mi.has(moduleName)) { |
| 14042 |
const instance = module.prototype instanceof jodit_core_component__WEBPACK_IMPORTED_MODULE_2__.ViewComponent ? new module(this, options) : new module(options); |
| 14043 |
this.components.add(instance); |
| 14044 |
mi.set(moduleName, instance); |
| 14045 |
} |
| 14046 |
return mi.get(moduleName); |
| 14047 |
} |
| 14048 |
/** Add some element to box */ addDisclaimer(elm) { |
| 14049 |
this.container.appendChild(elm); |
| 14050 |
} |
| 14051 |
/** |
| 14052 |
* Call before destruct |
| 14053 |
*/ beforeDestruct() { |
| 14054 |
this.e.fire(jodit_core_component_statuses__WEBPACK_IMPORTED_MODULE_4__.STATUSES.beforeDestruct, this); |
| 14055 |
this.components.forEach((component)=>{ |
| 14056 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_13__.isDestructable)(component) && !component.isInDestruct) { |
| 14057 |
component.destruct(); |
| 14058 |
} |
| 14059 |
}); |
| 14060 |
this.components.clear(); |
| 14061 |
} |
| 14062 |
/** @override */ destruct() { |
| 14063 |
var _cached, _cached1, _cached2, _cached3; |
| 14064 |
if (this.isDestructed) { |
| 14065 |
return; |
| 14066 |
} |
| 14067 |
(_cached = (0,jodit_core_decorators_cache_cache__WEBPACK_IMPORTED_MODULE_7__.cached)(this, 'progressbar')) === null || _cached === void 0 ? void 0 : _cached.destruct(); |
| 14068 |
(_cached1 = (0,jodit_core_decorators_cache_cache__WEBPACK_IMPORTED_MODULE_7__.cached)(this, 'message')) === null || _cached1 === void 0 ? void 0 : _cached1.destruct(); |
| 14069 |
(_cached2 = (0,jodit_core_decorators_cache_cache__WEBPACK_IMPORTED_MODULE_7__.cached)(this, 'asyncStorage')) === null || _cached2 === void 0 ? void 0 : _cached2.close(); |
| 14070 |
if (this.events) { |
| 14071 |
this.events.destruct(); |
| 14072 |
// @ts-ignore |
| 14073 |
this.events = undefined; |
| 14074 |
} |
| 14075 |
(_cached3 = (0,jodit_core_decorators_cache_cache__WEBPACK_IMPORTED_MODULE_7__.cached)(this, 'buffer')) === null || _cached3 === void 0 ? void 0 : _cached3.clear(); |
| 14076 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_10__.Dom.safeRemove(this.container); |
| 14077 |
super.destruct(); |
| 14078 |
} |
| 14079 |
constructor(options, isJodit = false){ |
| 14080 |
var _ref; |
| 14081 |
super(), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "isJodit", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "isView", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "parent", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "mods", void 0), /** |
| 14082 |
* ID attribute for a source element, id add `{id}_editor` it's editor's id |
| 14083 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "id", void 0), /** |
| 14084 |
* All created ViewComponent inside this view |
| 14085 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "components", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "events", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "create", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__container", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "OPTIONS", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__options", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__isFullSize", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__whoLocked", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "isLockedNotBy", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__modulesInstances", void 0), this.isJodit = isJodit, this.isView = true, this.parent = null, this.mods = {}, this.components = new Set(), this.OPTIONS = View.defaultOptions, this.__isFullSize = false, this.__whoLocked = '', this.isLockedNotBy = (name)=>this.isLocked && this.__whoLocked !== name, this.__modulesInstances = new Map(); |
| 14086 |
this.id = new Date().getTime().toString(); |
| 14087 |
this.initOptions(options); |
| 14088 |
this.initOwners(); |
| 14089 |
this.events = (_ref = options === null || options === void 0 ? void 0 : options.eventEmmiter) !== null && _ref !== void 0 ? _ref : new jodit_core_event_emitter__WEBPACK_IMPORTED_MODULE_11__.EventEmitter(this.od); |
| 14090 |
this.create = new jodit_core_create_create__WEBPACK_IMPORTED_MODULE_6__.Create(this.od); |
| 14091 |
this.__container = this.c.div(`jodit ${this.componentName}`); |
| 14092 |
} |
| 14093 |
} |
| 14094 |
// from webpack.config.ts |
| 14095 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(View, "ES", jodit_core_constants__WEBPACK_IMPORTED_MODULE_5__.ES); |
| 14096 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(View, "version", jodit_core_constants__WEBPACK_IMPORTED_MODULE_5__.APP_VERSION); |
| 14097 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(View, "esNext", jodit_core_constants__WEBPACK_IMPORTED_MODULE_5__.IS_ES_NEXT); // from webpack.config.ts |
| 14098 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(View, "esModern", jodit_core_constants__WEBPACK_IMPORTED_MODULE_5__.IS_ES_MODERN); // from webpack.config.ts |
| 14099 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(View, "defaultOptions", void 0); |
| 14100 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 14101 |
jodit_core_decorators_cache_cache__WEBPACK_IMPORTED_MODULE_7__.cache |
| 14102 |
], View.prototype, "buffer", null); |
| 14103 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 14104 |
jodit_core_decorators_cache_cache__WEBPACK_IMPORTED_MODULE_7__.cache |
| 14105 |
], View.prototype, "message", null); |
| 14106 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 14107 |
jodit_core_decorators_cache_cache__WEBPACK_IMPORTED_MODULE_7__.cache |
| 14108 |
], View.prototype, "storage", null); |
| 14109 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 14110 |
jodit_core_decorators_cache_cache__WEBPACK_IMPORTED_MODULE_7__.cache |
| 14111 |
], View.prototype, "asyncStorage", null); |
| 14112 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 14113 |
jodit_core_decorators_cache_cache__WEBPACK_IMPORTED_MODULE_7__.cache |
| 14114 |
], View.prototype, "c", null); |
| 14115 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 14116 |
jodit_core_decorators_cache_cache__WEBPACK_IMPORTED_MODULE_7__.cache |
| 14117 |
], View.prototype, "e", null); |
| 14118 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 14119 |
jodit_core_decorators_cache_cache__WEBPACK_IMPORTED_MODULE_7__.cache |
| 14120 |
], View.prototype, "progressbar", null); |
| 14121 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 14122 |
(0,jodit_core_decorators_hook_hook__WEBPACK_IMPORTED_MODULE_9__.hook)(jodit_core_component_statuses__WEBPACK_IMPORTED_MODULE_4__.STATUSES.beforeDestruct) |
| 14123 |
], View.prototype, "beforeDestruct", null); |
| 14124 |
View = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 14125 |
(0,jodit_core_decorators_derive_derive__WEBPACK_IMPORTED_MODULE_8__.derive)(jodit_core_traits_mods__WEBPACK_IMPORTED_MODULE_17__.Mods, jodit_core_traits_elms__WEBPACK_IMPORTED_MODULE_16__.Elms) |
| 14126 |
], View); |
| 14127 |
View.defaultOptions = { |
| 14128 |
extraButtons: [], |
| 14129 |
cache: true, |
| 14130 |
textIcons: false, |
| 14131 |
namespace: '', |
| 14132 |
removeButtons: [], |
| 14133 |
zIndex: 100002, |
| 14134 |
defaultTimeout: 100, |
| 14135 |
fullsize: false, |
| 14136 |
showTooltip: true, |
| 14137 |
useNativeTooltip: false, |
| 14138 |
buttons: [], |
| 14139 |
globalFullSize: true, |
| 14140 |
language: 'auto' |
| 14141 |
}; |
| 14142 |
|
| 14143 |
|
| 14144 |
/***/ }), |
| 14145 |
|
| 14146 |
/***/ 35104: |
| 14147 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 14148 |
|
| 14149 |
"use strict"; |
| 14150 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 14151 |
/* harmony export */ replaceOldTags: function() { return /* binding */ replaceOldTags; } |
| 14152 |
/* harmony export */ }); |
| 14153 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 14154 |
/*! |
| 14155 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 14156 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 14157 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 14158 |
*/ /** |
| 14159 |
* @module plugins/clean-html |
| 14160 |
*/ |
| 14161 |
/** |
| 14162 |
* @private |
| 14163 |
*/ function replaceOldTags(jodit, nodeElm, hadEffect) { |
| 14164 |
const newNodeElm = replaceIfMatched(jodit, nodeElm, jodit.o.cleanHTML.replaceOldTags); |
| 14165 |
if (nodeElm !== newNodeElm) { |
| 14166 |
nodeElm = newNodeElm; |
| 14167 |
return true; |
| 14168 |
} |
| 14169 |
return hadEffect; |
| 14170 |
} |
| 14171 |
/** |
| 14172 |
* Replaces an element with a newer one if specified in the configuration match |
| 14173 |
* @private |
| 14174 |
*/ function replaceIfMatched(jodit, oldParent, list) { |
| 14175 |
if (!list || !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isHTMLElement(oldParent)) { |
| 14176 |
return oldParent; |
| 14177 |
} |
| 14178 |
const tagName = list[oldParent.nodeName.toLowerCase()] || list[oldParent.nodeName]; |
| 14179 |
if (tagName) { |
| 14180 |
return jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.replace(oldParent, tagName, jodit.createInside, true, false); |
| 14181 |
} |
| 14182 |
return oldParent; |
| 14183 |
} |
| 14184 |
|
| 14185 |
|
| 14186 |
/***/ }), |
| 14187 |
|
| 14188 |
/***/ 35109: |
| 14189 |
/***/ (function(module) { |
| 14190 |
|
| 14191 |
/*! |
| 14192 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 14193 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 14194 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 14195 |
*/ module.exports = { |
| 14196 |
'copy-format': 'format kopii' |
| 14197 |
}; |
| 14198 |
|
| 14199 |
|
| 14200 |
/***/ }), |
| 14201 |
|
| 14202 |
/***/ 35676: |
| 14203 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 14204 |
|
| 14205 |
"use strict"; |
| 14206 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 14207 |
/* harmony export */ UISeparator: function() { return /* binding */ UISeparator; } |
| 14208 |
/* harmony export */ }); |
| 14209 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(31635); |
| 14210 |
/* harmony import */ var jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(91672); |
| 14211 |
/* harmony import */ var jodit_core_ui_element__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(96007); |
| 14212 |
|
| 14213 |
/*! |
| 14214 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 14215 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 14216 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 14217 |
*/ /** |
| 14218 |
* @module ui/group |
| 14219 |
*/ |
| 14220 |
|
| 14221 |
class UISeparator extends jodit_core_ui_element__WEBPACK_IMPORTED_MODULE_2__.UIElement { |
| 14222 |
className() { |
| 14223 |
return 'UISeparator'; |
| 14224 |
} |
| 14225 |
} |
| 14226 |
UISeparator = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_0__.__decorate)([ |
| 14227 |
jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_1__.component |
| 14228 |
], UISeparator); |
| 14229 |
|
| 14230 |
|
| 14231 |
/***/ }), |
| 14232 |
|
| 14233 |
/***/ 35718: |
| 14234 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 14235 |
|
| 14236 |
"use strict"; |
| 14237 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 14238 |
/* harmony export */ idle: function() { return /* binding */ idle; } |
| 14239 |
/* harmony export */ }); |
| 14240 |
/* harmony import */ var jodit_core_component__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(16964); |
| 14241 |
/* harmony import */ var jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(91565); |
| 14242 |
/* harmony import */ var jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(33201); |
| 14243 |
/*! |
| 14244 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 14245 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 14246 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 14247 |
*/ /** |
| 14248 |
* [[include:core/decorators/idle/README.md]] |
| 14249 |
* @packageDocumentation |
| 14250 |
* @module decorators/idle |
| 14251 |
*/ |
| 14252 |
|
| 14253 |
|
| 14254 |
function idle() { |
| 14255 |
return (target, propertyKey)=>{ |
| 14256 |
if (!(0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_1__.isFunction)(target[propertyKey])) { |
| 14257 |
throw (0,jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_2__.error)('Handler must be a Function'); |
| 14258 |
} |
| 14259 |
target.hookStatus(jodit_core_component__WEBPACK_IMPORTED_MODULE_0__.STATUSES.ready, (component)=>{ |
| 14260 |
const { async } = component; |
| 14261 |
const originalMethod = component[propertyKey]; |
| 14262 |
component[propertyKey] = (...args)=>async.requestIdleCallback(originalMethod.bind(component, ...args)); |
| 14263 |
}); |
| 14264 |
}; |
| 14265 |
} |
| 14266 |
|
| 14267 |
|
| 14268 |
/***/ }), |
| 14269 |
|
| 14270 |
/***/ 36310: |
| 14271 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 14272 |
|
| 14273 |
"use strict"; |
| 14274 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 14275 |
/* harmony export */ parseQuery: function() { return /* binding */ parseQuery; } |
| 14276 |
/* harmony export */ }); |
| 14277 |
/*! |
| 14278 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 14279 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 14280 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 14281 |
*/ /** |
| 14282 |
* @module helpers/utils |
| 14283 |
*/ /** |
| 14284 |
* Parse query string |
| 14285 |
*/ const parseQuery = (queryString)=>{ |
| 14286 |
const query = {}, a = queryString.substring(1).split('&'); |
| 14287 |
for(let i = 0; i < a.length; i += 1){ |
| 14288 |
const keyValue = a[i].split('='); |
| 14289 |
query[decodeURIComponent(keyValue[0])] = decodeURIComponent(keyValue[1] || ''); |
| 14290 |
} |
| 14291 |
return query; |
| 14292 |
}; |
| 14293 |
|
| 14294 |
|
| 14295 |
/***/ }), |
| 14296 |
|
| 14297 |
/***/ 36327: |
| 14298 |
/***/ (function(module) { |
| 14299 |
|
| 14300 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"><path d=\"M1600 736v192q0 40-28 68t-68 28h-416v416q0 40-28 68t-68 28h-192q-40 0-68-28t-28-68v-416h-416q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h416v-416q0-40 28-68t68-28h192q40 0 68 28t28 68v416h416q40 0 68 28t28 68z\"/></svg>" |
| 14301 |
|
| 14302 |
/***/ }), |
| 14303 |
|
| 14304 |
/***/ 36339: |
| 14305 |
/***/ (function(module) { |
| 14306 |
|
| 14307 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M1792 352v1088q0 42-39 59-13 5-25 5-27 0-45-19l-403-403v166q0 119-84.5 203.5t-203.5 84.5h-704q-119 0-203.5-84.5t-84.5-203.5v-704q0-119 84.5-203.5t203.5-84.5h704q119 0 203.5 84.5t84.5 203.5v165l403-402q18-19 45-19 12 0 25 5 39 17 39 59z\"/> </svg>" |
| 14308 |
|
| 14309 |
/***/ }), |
| 14310 |
|
| 14311 |
/***/ 36400: |
| 14312 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 14313 |
|
| 14314 |
"use strict"; |
| 14315 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 14316 |
/* harmony export */ dataBind: function() { return /* binding */ dataBind; } |
| 14317 |
/* harmony export */ }); |
| 14318 |
/* harmony import */ var jodit_core_helpers_checker_is_view_object__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(31534); |
| 14319 |
/*! |
| 14320 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 14321 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 14322 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 14323 |
*/ /** |
| 14324 |
* @module helpers/utils |
| 14325 |
*/ |
| 14326 |
const store = new WeakMap(); |
| 14327 |
const dataBind = (elm, key, value)=>{ |
| 14328 |
let itemStore = store.get(elm); |
| 14329 |
if (!itemStore) { |
| 14330 |
itemStore = {}; |
| 14331 |
store.set(elm, itemStore); |
| 14332 |
let e = null; |
| 14333 |
if ((0,jodit_core_helpers_checker_is_view_object__WEBPACK_IMPORTED_MODULE_0__.isViewObject)(elm.j)) { |
| 14334 |
e = elm.j.e; |
| 14335 |
} |
| 14336 |
if ((0,jodit_core_helpers_checker_is_view_object__WEBPACK_IMPORTED_MODULE_0__.isViewObject)(elm)) { |
| 14337 |
e = elm.e; |
| 14338 |
} |
| 14339 |
e && e.on('beforeDestruct', ()=>{ |
| 14340 |
store.delete(elm); |
| 14341 |
}); |
| 14342 |
} |
| 14343 |
if (value === undefined) { |
| 14344 |
return itemStore[key]; |
| 14345 |
} |
| 14346 |
itemStore[key] = value; |
| 14347 |
return value; |
| 14348 |
}; |
| 14349 |
|
| 14350 |
|
| 14351 |
/***/ }), |
| 14352 |
|
| 14353 |
/***/ 36664: |
| 14354 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 14355 |
|
| 14356 |
"use strict"; |
| 14357 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 14358 |
/* harmony export */ selfListeners: function() { return /* binding */ selfListeners; } |
| 14359 |
/* harmony export */ }); |
| 14360 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(65946); |
| 14361 |
/* harmony import */ var jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(28686); |
| 14362 |
/* harmony import */ var jodit_modules_file_browser_data_provider__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(17780); |
| 14363 |
/* harmony import */ var jodit_modules_file_browser_fetch_delete_file__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(1305); |
| 14364 |
/* harmony import */ var jodit_modules_file_browser_fetch_load_items__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(1488); |
| 14365 |
/* harmony import */ var jodit_modules_file_browser_fetch_load_tree__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(53202); |
| 14366 |
/* harmony import */ var jodit_modules_image_editor_image_editor__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(43271); |
| 14367 |
/*! |
| 14368 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 14369 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 14370 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 14371 |
*/ /** |
| 14372 |
* @module modules/file-browser |
| 14373 |
*/ |
| 14374 |
|
| 14375 |
|
| 14376 |
|
| 14377 |
|
| 14378 |
|
| 14379 |
|
| 14380 |
/** |
| 14381 |
* @private |
| 14382 |
*/ function selfListeners() { |
| 14383 |
const state = this.state, dp = this.dataProvider, self = this; |
| 14384 |
self.e.on('view.filebrowser', (view)=>{ |
| 14385 |
if (view !== state.view) { |
| 14386 |
state.view = view; |
| 14387 |
} |
| 14388 |
}).on('sort.filebrowser', (value)=>{ |
| 14389 |
if (value !== state.sortBy) { |
| 14390 |
state.sortBy = value; |
| 14391 |
(0,jodit_modules_file_browser_fetch_load_items__WEBPACK_IMPORTED_MODULE_4__.loadItems)(self); |
| 14392 |
} |
| 14393 |
}).on('filter.filebrowser', (value)=>{ |
| 14394 |
if (value !== state.filterWord) { |
| 14395 |
state.filterWord = value; |
| 14396 |
(0,jodit_modules_file_browser_fetch_load_items__WEBPACK_IMPORTED_MODULE_4__.loadItems)(self); |
| 14397 |
} |
| 14398 |
}).on('openFolder.filebrowser', (data)=>{ |
| 14399 |
let path; |
| 14400 |
if (data.name === '..') { |
| 14401 |
path = data.path.split('/').filter((p)=>p.length).slice(0, -1).join('/'); |
| 14402 |
} else { |
| 14403 |
path = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_0__.normalizePath)(data.path, data.name); |
| 14404 |
} |
| 14405 |
self.state.currentPath = path; |
| 14406 |
self.state.currentSource = data.name === '.' ? jodit_modules_file_browser_data_provider__WEBPACK_IMPORTED_MODULE_2__.DEFAULT_SOURCE_NAME : data.source; |
| 14407 |
}).on('removeFolder.filebrowser', (data)=>{ |
| 14408 |
self.confirm('Are you sure?', 'Delete', (yes)=>{ |
| 14409 |
if (yes) { |
| 14410 |
dp.folderRemove(data.path, data.name, data.source).then((message)=>{ |
| 14411 |
self.status(message, true); |
| 14412 |
return (0,jodit_modules_file_browser_fetch_load_tree__WEBPACK_IMPORTED_MODULE_5__.loadTree)(self); |
| 14413 |
}).catch(self.status); |
| 14414 |
} |
| 14415 |
}); |
| 14416 |
}).on('renameFolder.filebrowser', (data)=>{ |
| 14417 |
self.prompt('Enter new name', 'Rename', (newName)=>{ |
| 14418 |
if (!(0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_1__.isValidName)(newName)) { |
| 14419 |
self.status(self.i18n('Enter new name')); |
| 14420 |
return false; |
| 14421 |
} |
| 14422 |
dp.folderRename(data.path, data.name, newName, data.source).then((message)=>{ |
| 14423 |
self.state.activeElements = []; |
| 14424 |
self.status(message, true); |
| 14425 |
return (0,jodit_modules_file_browser_fetch_load_tree__WEBPACK_IMPORTED_MODULE_5__.loadTree)(self); |
| 14426 |
}).catch(self.status); |
| 14427 |
return; |
| 14428 |
}, 'type name', data.name); |
| 14429 |
}).on('addFolder.filebrowser', (data)=>{ |
| 14430 |
self.prompt('Enter Directory name', 'Create directory', (name)=>{ |
| 14431 |
dp.createFolder(name, data.path, data.source).then(()=>(0,jodit_modules_file_browser_fetch_load_tree__WEBPACK_IMPORTED_MODULE_5__.loadTree)(self)).catch(self.status); |
| 14432 |
}, 'type name'); |
| 14433 |
}).on('fileRemove.filebrowser', ()=>{ |
| 14434 |
if (self.state.activeElements.length) { |
| 14435 |
self.confirm('Are you sure?', '', (yes)=>{ |
| 14436 |
if (yes) { |
| 14437 |
const promises = []; |
| 14438 |
self.state.activeElements.forEach((item)=>{ |
| 14439 |
promises.push((0,jodit_modules_file_browser_fetch_delete_file__WEBPACK_IMPORTED_MODULE_3__.deleteFile)(self, item.file || item.name || '', item.sourceName)); |
| 14440 |
}); |
| 14441 |
self.state.activeElements = []; |
| 14442 |
Promise.all(promises).then(()=>(0,jodit_modules_file_browser_fetch_load_tree__WEBPACK_IMPORTED_MODULE_5__.loadTree)(self).catch(self.status), self.status); |
| 14443 |
} |
| 14444 |
}); |
| 14445 |
} |
| 14446 |
}).on('edit.filebrowser', ()=>{ |
| 14447 |
if (self.state.activeElements.length === 1) { |
| 14448 |
const [file] = this.state.activeElements; |
| 14449 |
jodit_modules_image_editor_image_editor__WEBPACK_IMPORTED_MODULE_6__.openImageEditor.call(self, file.fileURL, file.file || '', file.path, file.sourceName); |
| 14450 |
} |
| 14451 |
}).on('fileRename.filebrowser', (name, path, source)=>{ |
| 14452 |
if (self.state.activeElements.length === 1) { |
| 14453 |
self.prompt('Enter new name', 'Rename', (newName)=>{ |
| 14454 |
if (!(0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_1__.isValidName)(newName)) { |
| 14455 |
self.status(self.i18n('Enter new name')); |
| 14456 |
return false; |
| 14457 |
} |
| 14458 |
dp.fileRename(path, name, newName, source).then((message)=>{ |
| 14459 |
self.state.activeElements = []; |
| 14460 |
self.status(message, true); |
| 14461 |
(0,jodit_modules_file_browser_fetch_load_items__WEBPACK_IMPORTED_MODULE_4__.loadItems)(self); |
| 14462 |
}).catch(self.status); |
| 14463 |
return; |
| 14464 |
}, 'type name', name); |
| 14465 |
} |
| 14466 |
}).on('update.filebrowser', ()=>{ |
| 14467 |
(0,jodit_modules_file_browser_fetch_load_tree__WEBPACK_IMPORTED_MODULE_5__.loadTree)(this).then(this.status, this.status); |
| 14468 |
}); |
| 14469 |
} |
| 14470 |
|
| 14471 |
|
| 14472 |
/***/ }), |
| 14473 |
|
| 14474 |
/***/ 36833: |
| 14475 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 14476 |
|
| 14477 |
"use strict"; |
| 14478 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 14479 |
/* harmony export */ buildQuery: function() { return /* binding */ buildQuery; } |
| 14480 |
/* harmony export */ }); |
| 14481 |
/* harmony import */ var jodit_core_helpers_checker_is_plain_object__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(62101); |
| 14482 |
/*! |
| 14483 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 14484 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 14485 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 14486 |
*/ /** |
| 14487 |
* @module helpers/utils |
| 14488 |
*/ |
| 14489 |
/** |
| 14490 |
* Build query string |
| 14491 |
*/ const buildQuery = (data, prefix)=>{ |
| 14492 |
const str = []; |
| 14493 |
const enc = encodeURIComponent; |
| 14494 |
for(const dataKey in data){ |
| 14495 |
if (Object.prototype.hasOwnProperty.call(data, dataKey)) { |
| 14496 |
const k = prefix ? prefix + '[' + dataKey + ']' : dataKey; |
| 14497 |
const v = data[dataKey]; |
| 14498 |
str.push((0,jodit_core_helpers_checker_is_plain_object__WEBPACK_IMPORTED_MODULE_0__.isPlainObject)(v) ? buildQuery(v, k) : enc(k) + '=' + enc(v)); |
| 14499 |
} |
| 14500 |
} |
| 14501 |
return str.join('&'); |
| 14502 |
}; |
| 14503 |
|
| 14504 |
|
| 14505 |
/***/ }), |
| 14506 |
|
| 14507 |
/***/ 37102: |
| 14508 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 14509 |
|
| 14510 |
"use strict"; |
| 14511 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5266); |
| 14512 |
/*! |
| 14513 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 14514 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 14515 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 14516 |
*/ /** |
| 14517 |
* @module request |
| 14518 |
*/ |
| 14519 |
jodit_config__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.defaultAjaxOptions = { |
| 14520 |
successStatuses: [ |
| 14521 |
200, |
| 14522 |
201, |
| 14523 |
202 |
| 14524 |
], |
| 14525 |
method: 'GET', |
| 14526 |
url: '', |
| 14527 |
data: null, |
| 14528 |
contentType: 'application/x-www-form-urlencoded; charset=UTF-8', |
| 14529 |
headers: { |
| 14530 |
'X-REQUESTED-WITH': 'XMLHttpRequest' // compatible with jQuery |
| 14531 |
}, |
| 14532 |
withCredentials: false, |
| 14533 |
xhr () { |
| 14534 |
return new XMLHttpRequest(); |
| 14535 |
} |
| 14536 |
}; |
| 14537 |
|
| 14538 |
|
| 14539 |
/***/ }), |
| 14540 |
|
| 14541 |
/***/ 37333: |
| 14542 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 14543 |
|
| 14544 |
"use strict"; |
| 14545 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 14546 |
/* harmony export */ Alert: function() { return /* reexport safe */ _alert__WEBPACK_IMPORTED_MODULE_0__.Alert; }, |
| 14547 |
/* harmony export */ Confirm: function() { return /* reexport safe */ _confirm__WEBPACK_IMPORTED_MODULE_1__.Confirm; }, |
| 14548 |
/* harmony export */ Dialog: function() { return /* reexport safe */ _dialog__WEBPACK_IMPORTED_MODULE_2__.Dialog; }, |
| 14549 |
/* harmony export */ Prompt: function() { return /* reexport safe */ _prompt__WEBPACK_IMPORTED_MODULE_3__.Prompt; } |
| 14550 |
/* harmony export */ }); |
| 14551 |
/* harmony import */ var _alert__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(91535); |
| 14552 |
/* harmony import */ var _confirm__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(88329); |
| 14553 |
/* harmony import */ var _dialog__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(76841); |
| 14554 |
/* harmony import */ var _prompt__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(74103); |
| 14555 |
/*! |
| 14556 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 14557 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 14558 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 14559 |
*/ /** |
| 14560 |
* [[include:modules/dialog/README.md]] |
| 14561 |
* @packageDocumentation |
| 14562 |
* @module modules/dialog |
| 14563 |
*/ |
| 14564 |
|
| 14565 |
|
| 14566 |
|
| 14567 |
|
| 14568 |
|
| 14569 |
/***/ }), |
| 14570 |
|
| 14571 |
/***/ 37427: |
| 14572 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 14573 |
|
| 14574 |
"use strict"; |
| 14575 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 14576 |
/* harmony export */ humanSizeToBytes: function() { return /* binding */ humanSizeToBytes; } |
| 14577 |
/* harmony export */ }); |
| 14578 |
/*! |
| 14579 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 14580 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 14581 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 14582 |
*/ /** |
| 14583 |
* @module helpers/utils |
| 14584 |
*/ /** |
| 14585 |
* Converts from human readable file size (kb,mb,gb,tb) to bytes |
| 14586 |
* @param human - readable file size. Example 1gb or 11.2mb |
| 14587 |
*/ const humanSizeToBytes = (human)=>{ |
| 14588 |
if (/^[0-9.]+$/.test(human.toString())) { |
| 14589 |
return parseFloat(human); |
| 14590 |
} |
| 14591 |
const format = human.substr(-2, 2).toUpperCase(), formats = [ |
| 14592 |
'KB', |
| 14593 |
'MB', |
| 14594 |
'GB', |
| 14595 |
'TB' |
| 14596 |
], number = parseFloat(human.substr(0, human.length - 2)); |
| 14597 |
return formats.indexOf(format) !== -1 ? number * Math.pow(1024, formats.indexOf(format) + 1) : parseInt(human, 10); |
| 14598 |
}; |
| 14599 |
|
| 14600 |
|
| 14601 |
/***/ }), |
| 14602 |
|
| 14603 |
/***/ 37431: |
| 14604 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 14605 |
|
| 14606 |
"use strict"; |
| 14607 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 14608 |
/* harmony export */ isInlineBlock: function() { return /* binding */ isInlineBlock; }, |
| 14609 |
/* harmony export */ removeFormatForCollapsedSelection: function() { return /* binding */ removeFormatForCollapsedSelection; } |
| 14610 |
/* harmony export */ }); |
| 14611 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 14612 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(23211); |
| 14613 |
/*! |
| 14614 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 14615 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 14616 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 14617 |
*/ /** |
| 14618 |
* @module plugins/clean-html |
| 14619 |
*/ |
| 14620 |
|
| 14621 |
/** |
| 14622 |
* For collapsed selection move cursor outside or split inline block |
| 14623 |
* @private |
| 14624 |
*/ function removeFormatForCollapsedSelection(jodit, fake) { |
| 14625 |
const { s } = jodit; |
| 14626 |
let fakeNode = fake; |
| 14627 |
if (!fakeNode) { |
| 14628 |
fakeNode = jodit.createInside.fake(); |
| 14629 |
const { range } = s; |
| 14630 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.safeInsertNode(range, fakeNode); |
| 14631 |
range.collapse(); |
| 14632 |
} |
| 14633 |
const mainInline = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.furthest(fakeNode, isInlineBlock, jodit.editor); |
| 14634 |
if (mainInline) { |
| 14635 |
if (s.cursorOnTheLeft(mainInline)) { |
| 14636 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.before(mainInline, fakeNode); |
| 14637 |
} else if (s.cursorOnTheRight(mainInline)) { |
| 14638 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.after(mainInline, fakeNode); |
| 14639 |
} else { |
| 14640 |
const leftHand = s.splitSelection(mainInline); |
| 14641 |
leftHand && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.after(leftHand, fakeNode); |
| 14642 |
} |
| 14643 |
} |
| 14644 |
if (!fake) { |
| 14645 |
s.setCursorBefore(fakeNode); |
| 14646 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.safeRemove(fakeNode); |
| 14647 |
} |
| 14648 |
} |
| 14649 |
/** |
| 14650 |
* Element has inline display mode |
| 14651 |
* @private |
| 14652 |
*/ function isInlineBlock(node) { |
| 14653 |
return jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isInlineBlock(node) && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isTag(node, jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INSEPARABLE_TAGS); |
| 14654 |
} |
| 14655 |
|
| 14656 |
|
| 14657 |
/***/ }), |
| 14658 |
|
| 14659 |
/***/ 38027: |
| 14660 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 14661 |
|
| 14662 |
"use strict"; |
| 14663 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 14664 |
/* harmony export */ connection: function() { return /* binding */ connection; }, |
| 14665 |
/* harmony export */ error: function() { return /* binding */ error; }, |
| 14666 |
/* harmony export */ options: function() { return /* binding */ options; } |
| 14667 |
/* harmony export */ }); |
| 14668 |
/* harmony import */ var _errors__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(29953); |
| 14669 |
/*! |
| 14670 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 14671 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 14672 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 14673 |
*/ /** |
| 14674 |
* @module helpers/utils |
| 14675 |
*/ |
| 14676 |
/** |
| 14677 |
* Helper for create Error object |
| 14678 |
*/ function error(message) { |
| 14679 |
return new TypeError(message); |
| 14680 |
} |
| 14681 |
function connection(message) { |
| 14682 |
return new _errors__WEBPACK_IMPORTED_MODULE_0__.ConnectionError(message); |
| 14683 |
} |
| 14684 |
function options(message) { |
| 14685 |
return new _errors__WEBPACK_IMPORTED_MODULE_0__.OptionsError(message); |
| 14686 |
} |
| 14687 |
|
| 14688 |
|
| 14689 |
/***/ }), |
| 14690 |
|
| 14691 |
/***/ 38187: |
| 14692 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 14693 |
|
| 14694 |
"use strict"; |
| 14695 |
/* harmony import */ var _swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(49376); |
| 14696 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(81937); |
| 14697 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5266); |
| 14698 |
/* harmony import */ var _helpers__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(54308); |
| 14699 |
/*! |
| 14700 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 14701 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 14702 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 14703 |
*/ /** |
| 14704 |
* @module plugins/paste |
| 14705 |
*/ |
| 14706 |
|
| 14707 |
|
| 14708 |
|
| 14709 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.askBeforePasteHTML = true; |
| 14710 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.processPasteHTML = true; |
| 14711 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.scrollToPastedContent = true; |
| 14712 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.pasteExcludeStripTags = [ |
| 14713 |
'br', |
| 14714 |
'hr' |
| 14715 |
]; |
| 14716 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.pasteHTMLActionList = [ |
| 14717 |
{ |
| 14718 |
value: jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.INSERT_AS_HTML, |
| 14719 |
text: 'Keep' |
| 14720 |
}, |
| 14721 |
{ |
| 14722 |
value: jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.INSERT_AS_TEXT, |
| 14723 |
text: 'Insert as Text' |
| 14724 |
}, |
| 14725 |
{ |
| 14726 |
value: jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.INSERT_ONLY_TEXT, |
| 14727 |
text: 'Insert only Text' |
| 14728 |
} |
| 14729 |
]; |
| 14730 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.memorizeChoiceWhenPasteFragment = false; |
| 14731 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.nl2brInPlainText = true; |
| 14732 |
const psKey = 'pasteStorage'; |
| 14733 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.controls.paste = { |
| 14734 |
tooltip: 'Paste from clipboard', |
| 14735 |
exec (_0, _1, _2) { |
| 14736 |
return (0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*(editor, _, { control }) { |
| 14737 |
if (control.name === psKey) { |
| 14738 |
editor.execCommand('showPasteStorage'); |
| 14739 |
return; |
| 14740 |
} |
| 14741 |
editor.s.focus(); |
| 14742 |
let text = '', error = true; |
| 14743 |
if (navigator.clipboard) { |
| 14744 |
try { |
| 14745 |
const items = yield navigator.clipboard.read(); |
| 14746 |
if (items && items.length) { |
| 14747 |
const textBlob = yield items[0].getType(jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.TEXT_PLAIN); |
| 14748 |
text = yield new Response(textBlob).text(); |
| 14749 |
} |
| 14750 |
error = false; |
| 14751 |
} catch (e) { |
| 14752 |
if (!jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.IS_PROD) { |
| 14753 |
// eslint-disable-next-line no-console |
| 14754 |
console.log(e); |
| 14755 |
} |
| 14756 |
} |
| 14757 |
if (error) { |
| 14758 |
try { |
| 14759 |
text = yield navigator.clipboard.readText(); |
| 14760 |
error = false; |
| 14761 |
} catch (e) { |
| 14762 |
if (!jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.IS_PROD) { |
| 14763 |
// eslint-disable-next-line no-console |
| 14764 |
console.log(e); |
| 14765 |
} |
| 14766 |
} |
| 14767 |
} |
| 14768 |
} |
| 14769 |
if (error) { |
| 14770 |
text = editor.buffer.get(jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.CLIPBOARD_ID) || ''; |
| 14771 |
error = text.length === 0; |
| 14772 |
} |
| 14773 |
const value = editor.value; |
| 14774 |
if (error) { |
| 14775 |
editor.ed.execCommand('paste'); |
| 14776 |
error = value === editor.value; |
| 14777 |
!error && editor.e.fire('afterPaste'); |
| 14778 |
} else if (text.length) { |
| 14779 |
(0,_helpers__WEBPACK_IMPORTED_MODULE_3__.pasteInsertHtml)(null, editor, text); |
| 14780 |
editor.e.fire('afterPaste'); |
| 14781 |
} else { |
| 14782 |
if (error) { |
| 14783 |
editor.alert("Your browser doesn't support direct access to the clipboard.", ()=>void editor.s.focus()); |
| 14784 |
} |
| 14785 |
} |
| 14786 |
}).apply(this, arguments); |
| 14787 |
}, |
| 14788 |
list: { |
| 14789 |
[psKey]: 'Paste Storage' |
| 14790 |
}, |
| 14791 |
isChildDisabled (j) { |
| 14792 |
return j.e.fire('pasteStorageList') < 2; |
| 14793 |
} |
| 14794 |
}; |
| 14795 |
|
| 14796 |
|
| 14797 |
/***/ }), |
| 14798 |
|
| 14799 |
/***/ 38639: |
| 14800 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 14801 |
|
| 14802 |
"use strict"; |
| 14803 |
__webpack_require__.r(__webpack_exports__); |
| 14804 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 14805 |
/* harmony export */ ar: function() { return /* reexport default from dynamic */ _ar_js__WEBPACK_IMPORTED_MODULE_0___default.a; }, |
| 14806 |
/* harmony export */ cs_cz: function() { return /* reexport default from dynamic */ _cs_cz_js__WEBPACK_IMPORTED_MODULE_1___default.a; }, |
| 14807 |
/* harmony export */ de: function() { return /* reexport default from dynamic */ _de_js__WEBPACK_IMPORTED_MODULE_2___default.a; }, |
| 14808 |
/* harmony export */ es: function() { return /* reexport default from dynamic */ _es_js__WEBPACK_IMPORTED_MODULE_3___default.a; }, |
| 14809 |
/* harmony export */ fa: function() { return /* reexport default from dynamic */ _ar_js__WEBPACK_IMPORTED_MODULE_0___default.a; }, |
| 14810 |
/* harmony export */ fi: function() { return /* reexport default from dynamic */ _ar_js__WEBPACK_IMPORTED_MODULE_0___default.a; }, |
| 14811 |
/* harmony export */ fr: function() { return /* reexport default from dynamic */ _fr_js__WEBPACK_IMPORTED_MODULE_4___default.a; }, |
| 14812 |
/* harmony export */ he: function() { return /* reexport default from dynamic */ _ar_js__WEBPACK_IMPORTED_MODULE_0___default.a; }, |
| 14813 |
/* harmony export */ hu: function() { return /* reexport default from dynamic */ _hu_js__WEBPACK_IMPORTED_MODULE_5___default.a; }, |
| 14814 |
/* harmony export */ id: function() { return /* reexport default from dynamic */ _ar_js__WEBPACK_IMPORTED_MODULE_0___default.a; }, |
| 14815 |
/* harmony export */ it: function() { return /* reexport default from dynamic */ _it_js__WEBPACK_IMPORTED_MODULE_6___default.a; }, |
| 14816 |
/* harmony export */ ja: function() { return /* reexport default from dynamic */ _ja_js__WEBPACK_IMPORTED_MODULE_7___default.a; }, |
| 14817 |
/* harmony export */ ko: function() { return /* reexport default from dynamic */ _ar_js__WEBPACK_IMPORTED_MODULE_0___default.a; }, |
| 14818 |
/* harmony export */ mn: function() { return /* reexport default from dynamic */ _ar_js__WEBPACK_IMPORTED_MODULE_0___default.a; }, |
| 14819 |
/* harmony export */ nl: function() { return /* reexport default from dynamic */ _nl_js__WEBPACK_IMPORTED_MODULE_8___default.a; }, |
| 14820 |
/* harmony export */ pl: function() { return /* reexport default from dynamic */ _pl_js__WEBPACK_IMPORTED_MODULE_9___default.a; }, |
| 14821 |
/* harmony export */ pt_br: function() { return /* reexport default from dynamic */ _pt_br_js__WEBPACK_IMPORTED_MODULE_10___default.a; }, |
| 14822 |
/* harmony export */ ru: function() { return /* reexport default from dynamic */ _ar_js__WEBPACK_IMPORTED_MODULE_0___default.a; }, |
| 14823 |
/* harmony export */ tr: function() { return /* reexport default from dynamic */ _tr_js__WEBPACK_IMPORTED_MODULE_11___default.a; }, |
| 14824 |
/* harmony export */ zh_cn: function() { return /* reexport default from dynamic */ _zh_cn_js__WEBPACK_IMPORTED_MODULE_12___default.a; }, |
| 14825 |
/* harmony export */ zh_tw: function() { return /* reexport default from dynamic */ _zh_tw_js__WEBPACK_IMPORTED_MODULE_13___default.a; } |
| 14826 |
/* harmony export */ }); |
| 14827 |
/* harmony import */ var _ar_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(41324); |
| 14828 |
/* harmony import */ var _ar_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_ar_js__WEBPACK_IMPORTED_MODULE_0__); |
| 14829 |
/* harmony import */ var _cs_cz_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(3787); |
| 14830 |
/* harmony import */ var _cs_cz_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_cs_cz_js__WEBPACK_IMPORTED_MODULE_1__); |
| 14831 |
/* harmony import */ var _de_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(83778); |
| 14832 |
/* harmony import */ var _de_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_de_js__WEBPACK_IMPORTED_MODULE_2__); |
| 14833 |
/* harmony import */ var _es_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(70577); |
| 14834 |
/* harmony import */ var _es_js__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_es_js__WEBPACK_IMPORTED_MODULE_3__); |
| 14835 |
/* harmony import */ var _fr_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(21513); |
| 14836 |
/* harmony import */ var _fr_js__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_fr_js__WEBPACK_IMPORTED_MODULE_4__); |
| 14837 |
/* harmony import */ var _hu_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(22998); |
| 14838 |
/* harmony import */ var _hu_js__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_hu_js__WEBPACK_IMPORTED_MODULE_5__); |
| 14839 |
/* harmony import */ var _it_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(66568); |
| 14840 |
/* harmony import */ var _it_js__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(_it_js__WEBPACK_IMPORTED_MODULE_6__); |
| 14841 |
/* harmony import */ var _ja_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(83708); |
| 14842 |
/* harmony import */ var _ja_js__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(_ja_js__WEBPACK_IMPORTED_MODULE_7__); |
| 14843 |
/* harmony import */ var _nl_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(58067); |
| 14844 |
/* harmony import */ var _nl_js__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(_nl_js__WEBPACK_IMPORTED_MODULE_8__); |
| 14845 |
/* harmony import */ var _pl_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(35109); |
| 14846 |
/* harmony import */ var _pl_js__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(_pl_js__WEBPACK_IMPORTED_MODULE_9__); |
| 14847 |
/* harmony import */ var _pt_br_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(22380); |
| 14848 |
/* harmony import */ var _pt_br_js__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(_pt_br_js__WEBPACK_IMPORTED_MODULE_10__); |
| 14849 |
/* harmony import */ var _tr_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(31371); |
| 14850 |
/* harmony import */ var _tr_js__WEBPACK_IMPORTED_MODULE_11___default = /*#__PURE__*/__webpack_require__.n(_tr_js__WEBPACK_IMPORTED_MODULE_11__); |
| 14851 |
/* harmony import */ var _zh_cn_js__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(41599); |
| 14852 |
/* harmony import */ var _zh_cn_js__WEBPACK_IMPORTED_MODULE_12___default = /*#__PURE__*/__webpack_require__.n(_zh_cn_js__WEBPACK_IMPORTED_MODULE_12__); |
| 14853 |
/* harmony import */ var _zh_tw_js__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(15223); |
| 14854 |
/* harmony import */ var _zh_tw_js__WEBPACK_IMPORTED_MODULE_13___default = /*#__PURE__*/__webpack_require__.n(_zh_tw_js__WEBPACK_IMPORTED_MODULE_13__); |
| 14855 |
/*! |
| 14856 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 14857 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 14858 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 14859 |
*/ |
| 14860 |
|
| 14861 |
|
| 14862 |
|
| 14863 |
|
| 14864 |
|
| 14865 |
|
| 14866 |
|
| 14867 |
|
| 14868 |
|
| 14869 |
|
| 14870 |
|
| 14871 |
|
| 14872 |
|
| 14873 |
|
| 14874 |
|
| 14875 |
|
| 14876 |
|
| 14877 |
|
| 14878 |
|
| 14879 |
|
| 14880 |
|
| 14881 |
|
| 14882 |
|
| 14883 |
/***/ }), |
| 14884 |
|
| 14885 |
/***/ 38681: |
| 14886 |
/***/ (function(module) { |
| 14887 |
|
| 14888 |
module.exports = "<svg viewBox=\"0 0 18.151 18.151\" xmlns=\"http://www.w3.org/2000/svg\"> <g> <path stroke-width=\"0\" d=\"M6.237,16.546H3.649V1.604h5.916v5.728c0.474-0.122,0.968-0.194,1.479-0.194 c0.042,0,0.083,0.006,0.125,0.006V0H2.044v18.15h5.934C7.295,17.736,6.704,17.19,6.237,16.546z\"/> <path stroke-width=\"0\" d=\"M11.169,8.275c-2.723,0-4.938,2.215-4.938,4.938s2.215,4.938,4.938,4.938s4.938-2.215,4.938-4.938 S13.892,8.275,11.169,8.275z M11.169,16.81c-1.983,0-3.598-1.612-3.598-3.598c0-1.983,1.614-3.597,3.598-3.597 s3.597,1.613,3.597,3.597C14.766,15.198,13.153,16.81,11.169,16.81z\"/> <polygon stroke-width=\"0\" points=\"11.792,11.073 10.502,11.073 10.502,12.578 9.03,12.578 9.03,13.868 10.502,13.868 10.502,15.352 11.792,15.352 11.792,13.868 13.309,13.868 13.309,12.578 11.792,12.578 \"/> </g> </svg>" |
| 14889 |
|
| 14890 |
/***/ }), |
| 14891 |
|
| 14892 |
/***/ 39000: |
| 14893 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 14894 |
|
| 14895 |
"use strict"; |
| 14896 |
/* unused harmony export indent */ |
| 14897 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 14898 |
/* harmony import */ var jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(27795); |
| 14899 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(28077); |
| 14900 |
/* harmony import */ var jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(93640); |
| 14901 |
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(42360); |
| 14902 |
/* harmony import */ var _helpers__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(11917); |
| 14903 |
/*! |
| 14904 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 14905 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 14906 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 14907 |
*/ /** |
| 14908 |
* [[include:plugins/indent/README.md]] |
| 14909 |
* @packageDocumentation |
| 14910 |
* @module plugins/indent |
| 14911 |
*/ |
| 14912 |
|
| 14913 |
|
| 14914 |
|
| 14915 |
|
| 14916 |
|
| 14917 |
const applyIndentToBox = (processedElements, currentBox, editor, command)=>{ |
| 14918 |
if (!currentBox) { |
| 14919 |
return; |
| 14920 |
} |
| 14921 |
if (processedElements.has(currentBox)) { |
| 14922 |
return; |
| 14923 |
} |
| 14924 |
const key = (0,_helpers__WEBPACK_IMPORTED_MODULE_5__.getKey)(editor.o.direction, currentBox); |
| 14925 |
processedElements.add(currentBox); |
| 14926 |
let value = currentBox.style[key] ? parseInt(currentBox.style[key], 10) : 0; |
| 14927 |
value += editor.o.indentMargin * (command === 'outdent' ? -1 : 1); |
| 14928 |
currentBox.style[key] = value > 0 ? value + 'px' : ''; |
| 14929 |
if (!(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_3__.attr)(currentBox, 'style')) { |
| 14930 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_3__.attr)(currentBox, 'style', null); |
| 14931 |
} |
| 14932 |
}; |
| 14933 |
/** |
| 14934 |
* Indents the line containing the selection or insertion point. |
| 14935 |
*/ function indent(editor) { |
| 14936 |
editor.registerButton({ |
| 14937 |
name: 'indent', |
| 14938 |
group: 'indent' |
| 14939 |
}).registerButton({ |
| 14940 |
name: 'outdent', |
| 14941 |
group: 'indent' |
| 14942 |
}); |
| 14943 |
const indentCommand = (command)=>{ |
| 14944 |
const processedElements = new Set(); |
| 14945 |
const { enter, enterBlock } = editor.o; |
| 14946 |
const isBrMode = enter.toLowerCase() === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.BR; |
| 14947 |
const current = editor.s.current(); |
| 14948 |
if (isBrMode && editor.s.isCollapsed()) { |
| 14949 |
if (current) { |
| 14950 |
const box = jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.wrapNextInline(current, enterBlock, editor); |
| 14951 |
applyIndentToBox(processedElements, box, editor, command); |
| 14952 |
return false; |
| 14953 |
} |
| 14954 |
} |
| 14955 |
editor.s.eachSelection((current)=>{ |
| 14956 |
editor.s.save(); |
| 14957 |
let currentBox = current ? jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.up(current, jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isBlock, editor.editor) : false; |
| 14958 |
if (!currentBox && current) { |
| 14959 |
currentBox = (0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_3__.call)(!isBrMode ? jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.wrapInline : jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.wrapNextInline, current, !isBrMode ? enter.toLowerCase() : enterBlock, editor); |
| 14960 |
} |
| 14961 |
if (!currentBox) { |
| 14962 |
editor.s.restore(); |
| 14963 |
return false; |
| 14964 |
} |
| 14965 |
applyIndentToBox(processedElements, currentBox, editor, command); |
| 14966 |
editor.s.restore(); |
| 14967 |
}); |
| 14968 |
editor.synchronizeValues(); |
| 14969 |
return false; |
| 14970 |
}; |
| 14971 |
editor.registerCommand('indent', { |
| 14972 |
exec: indentCommand, |
| 14973 |
hotkeys: [ |
| 14974 |
'ctrl+]', |
| 14975 |
'cmd+]' |
| 14976 |
] |
| 14977 |
}); |
| 14978 |
editor.registerCommand('outdent', { |
| 14979 |
exec: indentCommand, |
| 14980 |
hotkeys: [ |
| 14981 |
'ctrl+[', |
| 14982 |
'cmd+[' |
| 14983 |
] |
| 14984 |
}); |
| 14985 |
} |
| 14986 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_2__.pluginSystem.add('indent', indent); |
| 14987 |
|
| 14988 |
|
| 14989 |
/***/ }), |
| 14990 |
|
| 14991 |
/***/ 39188: |
| 14992 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 14993 |
|
| 14994 |
"use strict"; |
| 14995 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 14996 |
/* harmony export */ fillEmptyParagraph: function() { return /* binding */ fillEmptyParagraph; } |
| 14997 |
/* harmony export */ }); |
| 14998 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 14999 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(23211); |
| 15000 |
/*! |
| 15001 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 15002 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 15003 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 15004 |
*/ /** |
| 15005 |
* @module plugins/clean-html |
| 15006 |
*/ |
| 15007 |
|
| 15008 |
const TABLE_CONTAINER_TAGS = new Set([ |
| 15009 |
'table', |
| 15010 |
'tbody', |
| 15011 |
'thead', |
| 15012 |
'tfoot', |
| 15013 |
'tr' |
| 15014 |
]); |
| 15015 |
/** |
| 15016 |
* @private |
| 15017 |
*/ function fillEmptyParagraph(jodit, nodeElm, hadEffect) { |
| 15018 |
if (jodit.o.cleanHTML.fillEmptyParagraph && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isBlock(nodeElm) && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isEmpty(nodeElm, jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INSEPARABLE_TAGS) && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isTag(nodeElm, TABLE_CONTAINER_TAGS)) { |
| 15019 |
const br = jodit.createInside.element('br'); |
| 15020 |
nodeElm.appendChild(br); |
| 15021 |
return true; |
| 15022 |
} |
| 15023 |
return hadEffect; |
| 15024 |
} |
| 15025 |
|
| 15026 |
|
| 15027 |
/***/ }), |
| 15028 |
|
| 15029 |
/***/ 39199: |
| 15030 |
/***/ (function(module) { |
| 15031 |
|
| 15032 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M1664 896q0 156-61 298t-164 245-245 164-298 61q-172 0-327-72.5t-264-204.5q-7-10-6.5-22.5t8.5-20.5l137-138q10-9 25-9 16 2 23 12 73 95 179 147t225 52q104 0 198.5-40.5t163.5-109.5 109.5-163.5 40.5-198.5-40.5-198.5-109.5-163.5-163.5-109.5-198.5-40.5q-98 0-188 35.5t-160 101.5l137 138q31 30 14 69-17 40-59 40h-448q-26 0-45-19t-19-45v-448q0-42 40-59 39-17 69 14l130 129q107-101 244.5-156.5t284.5-55.5q156 0 298 61t245 164 164 245 61 298z\"/> </svg>" |
| 15033 |
|
| 15034 |
/***/ }), |
| 15035 |
|
| 15036 |
/***/ 39386: |
| 15037 |
/***/ (function(module) { |
| 15038 |
|
| 15039 |
module.exports["default"] = ["Escriba algo...","Acerca de Jodit","Jodit Editor","Guía de usuario Jodit","contiene ayuda detallada para el uso.","Para información sobre la licencia, por favor visite nuestro sitio:","Compre la versión completa","Copyright © XDSoft.net - Chupurnov Valeriy. Todos los derechos reservados.","Anclar","Abrir en nueva pestaña","Abrir editor en pantalla completa","Limpiar formato","Color de relleno o de letra","Rehacer","Deshacer","Negrita","Cursiva","Insertar lista no ordenada","Insertar lista ordenada","Alinear Centrado","Alinear Justificado","Alinear Izquierda","Alinear Derecha","Insertar línea horizontal","Insertar imagen","Insertar archivo","Insertar video de Youtube/vimeo","Insertar vínculo","Tamaño de letra","Familia de letra","Insertar bloque","Normal","Encabezado 1","Encabezado 2","Encabezado 3","Encabezado 4","Cita","Código","Insertar","Insertar tabla","Disminuir sangría","Aumentar sangría","Seleccionar caracter especial","Insertar caracter especial","Copiar formato","Cambiar modo","Márgenes","arriba","derecha","abajo","izquierda","Estilos CSS","Clases CSS","Alinear","Derecha","Centrado","Izquierda","--No Establecido--","Fuente","Título","Texto Alternativo","Vínculo","Abrir vínculo en nueva pestaña","Imagen","Archivo","Avanzado","Propiedades de imagen","Cancelar","Aceptar","Buscar archivo","Error al cargar la lista","Error al cargar las carpetas","¿Está seguro?","Entre nombre de carpeta","Crear carpeta","Entre el nombre","Soltar imagen","Soltar archivo","o click","Texto alternativo","Subir","Buscar","Fondo","Texto","Arriba","Centro","Abajo","Insertar columna antes","Interar columna después","Insertar fila arriba","Insertar fila debajo","Borrar tabla","Borrar fila","Borrar columna","Vaciar celda","Caracteres: %d","Palabras: %d","Tachado","Subrayado","superíndice","subíndice","Cortar selección","Seleccionar todo","Pausa","Buscar","Reemplazar con","Reemplazar","Pegar","Seleccionar contenido para pegar","HTML","negrita","cursiva","Brocha","Vínculo","deshacer","rehacer","Tabla","Imagen","Borrar","Párrafo","Tamaño de letra","Video","Letra","Acerca de","Imprimir","subrayar","tachar","sangría","quitar sangría","Tamaño completo","encoger","línea horizontal","lista sin ordenar","lista ordenada","Cortar","Seleccionar todo","Incluir código","Abrir vínculo","Editar vínculo","No seguir","Desvincular","Actualizar","Para editar","Ver","URL","Editar","Alineación horizontal","Filtrar","Ordenar por fecha modificación","Ordenar por nombre","Ordenar por tamaño","Agregar carpeta","Resetear","Guardar","Guardar como...","Redimensionar","Recortar","Ancho","Alto","Mantener relación de aspecto","Si","No","Quitar","Seleccionar","Seleccionar: %s","Alineación vertical","Dividir","Mezclar","Agregar columna","Agregar fila","Licencia: %s","Borrar","Dividir vertical","Dividir horizontal","Borde","El código es similar a HTML. ¿Mantener como HTML?","Pegar como HTML?","Mantener","Insertar como texto","Insertar solo texto","Solo puedes editar tus propias imágenes. ¿Descargar esta imagen en el servidor?","¡La imagen se ha subido correctamente al servidor!","paleta","No hay archivos en este directorio.","renombrar","Ingresa un nuevo nombre","avance","Descargar","Pegar desde el portapapeles","Su navegador no soporta el acceso directo en el portapapeles.","Selección de copia","copia","Radio frontera","Mostrar todos los","Aplicar","Por favor, rellene este campo","Por favor, introduzca una dirección web","Predeterminado","Círculo","Punto","Cuadro","Encontrar","Buscar Anterior","Buscar Siguiente","El contenido pegado proviene de un documento de Microsoft Word/Excel. ¿Desea mantener el formato o limpiarlo?","Pegado desde Word detectado","Limpiar","Insertar nombre de clase","Presione Alt para cambiar el tamaño personalizado",null,null,null,"Todo"] |
| 15040 |
|
| 15041 |
/***/ }), |
| 15042 |
|
| 15043 |
/***/ 39608: |
| 15044 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 15045 |
|
| 15046 |
"use strict"; |
| 15047 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 15048 |
/* harmony export */ isInsideInvisibleElement: function() { return /* binding */ isInsideInvisibleElement; } |
| 15049 |
/* harmony export */ }); |
| 15050 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 15051 |
/*! |
| 15052 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 15053 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 15054 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 15055 |
*/ |
| 15056 |
/** |
| 15057 |
* Check if FONT inside STYLE or SCRIPT element |
| 15058 |
* @private |
| 15059 |
*/ function isInsideInvisibleElement(font, root) { |
| 15060 |
return Boolean(jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(font, [ |
| 15061 |
'style', |
| 15062 |
'script' |
| 15063 |
], root)); |
| 15064 |
} |
| 15065 |
|
| 15066 |
|
| 15067 |
/***/ }), |
| 15068 |
|
| 15069 |
/***/ 39709: |
| 15070 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 15071 |
|
| 15072 |
"use strict"; |
| 15073 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 15074 |
/* harmony export */ ToolbarButton: function() { return /* reexport safe */ _button__WEBPACK_IMPORTED_MODULE_0__.ToolbarButton; }, |
| 15075 |
/* harmony export */ ToolbarContent: function() { return /* reexport safe */ _content__WEBPACK_IMPORTED_MODULE_1__.ToolbarContent; }, |
| 15076 |
/* harmony export */ ToolbarSelect: function() { return /* reexport safe */ _select_select__WEBPACK_IMPORTED_MODULE_2__.ToolbarSelect; } |
| 15077 |
/* harmony export */ }); |
| 15078 |
/* harmony import */ var _button__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(22533); |
| 15079 |
/* harmony import */ var _content__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(5772); |
| 15080 |
/* harmony import */ var _select_select__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(61764); |
| 15081 |
/*! |
| 15082 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 15083 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 15084 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 15085 |
*/ /** |
| 15086 |
* @module modules/toolbar/button |
| 15087 |
*/ |
| 15088 |
|
| 15089 |
|
| 15090 |
|
| 15091 |
|
| 15092 |
/***/ }), |
| 15093 |
|
| 15094 |
/***/ 39858: |
| 15095 |
/***/ (function(module) { |
| 15096 |
|
| 15097 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M704 1376v-704q0-14-9-23t-23-9h-64q-14 0-23 9t-9 23v704q0 14 9 23t23 9h64q14 0 23-9t9-23zm256 0v-704q0-14-9-23t-23-9h-64q-14 0-23 9t-9 23v704q0 14 9 23t23 9h64q14 0 23-9t9-23zm256 0v-704q0-14-9-23t-23-9h-64q-14 0-23 9t-9 23v704q0 14 9 23t23 9h64q14 0 23-9t9-23zm-544-992h448l-48-117q-7-9-17-11h-317q-10 2-17 11zm928 32v64q0 14-9 23t-23 9h-96v948q0 83-47 143.5t-113 60.5h-832q-66 0-113-58.5t-47-141.5v-952h-96q-14 0-23-9t-9-23v-64q0-14 9-23t23-9h309l70-167q15-37 54-63t79-26h320q40 0 79 26t54 63l70 167h309q14 0 23 9t9 23z\"/> </svg>" |
| 15098 |
|
| 15099 |
/***/ }), |
| 15100 |
|
| 15101 |
/***/ 39978: |
| 15102 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 15103 |
|
| 15104 |
"use strict"; |
| 15105 |
/* unused harmony export imageProcessor */ |
| 15106 |
/* harmony import */ var _swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(49376); |
| 15107 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 15108 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(81937); |
| 15109 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(84839); |
| 15110 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(28077); |
| 15111 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(65946); |
| 15112 |
/* harmony import */ var jodit_core_plugin__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(91206); |
| 15113 |
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(51034); |
| 15114 |
/*! |
| 15115 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 15116 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 15117 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 15118 |
*/ /** |
| 15119 |
* [[include:plugins/image-processor/README.md]] |
| 15120 |
* @packageDocumentation |
| 15121 |
* @module plugins/image-processor |
| 15122 |
*/ |
| 15123 |
|
| 15124 |
|
| 15125 |
|
| 15126 |
|
| 15127 |
|
| 15128 |
|
| 15129 |
|
| 15130 |
const JODIT_IMAGE_PROCESSOR_BINDED = '__jodit_imageprocessor_binded'; |
| 15131 |
const JODIT_IMAGE_BLOB_ID = JODIT_IMAGE_PROCESSOR_BINDED + 'blob-id'; |
| 15132 |
/** |
| 15133 |
* Change editor's size after load all images |
| 15134 |
*/ class imageProcessor extends jodit_core_plugin__WEBPACK_IMPORTED_MODULE_6__.Plugin { |
| 15135 |
afterInit(jodit) {} |
| 15136 |
beforeDestruct(jodit) { |
| 15137 |
const buffer = (0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.cached)(jodit, 'buffer'); |
| 15138 |
const list = buffer === null || buffer === void 0 ? void 0 : buffer.get(JODIT_IMAGE_BLOB_ID); |
| 15139 |
if (buffer && list) { |
| 15140 |
const keys = Object.keys(list); |
| 15141 |
for (const uri of keys){ |
| 15142 |
URL.revokeObjectURL(uri); |
| 15143 |
} |
| 15144 |
buffer.delete(JODIT_IMAGE_BLOB_ID); |
| 15145 |
} |
| 15146 |
} |
| 15147 |
onAfterGetValueFromEditor(data, consumer) { |
| 15148 |
if (consumer !== jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.SOURCE_CONSUMER) { |
| 15149 |
return this.onBeforeSetElementValue(data); |
| 15150 |
} |
| 15151 |
} |
| 15152 |
onBeforeSetElementValue(data) { |
| 15153 |
const { jodit: editor } = this; |
| 15154 |
if (!editor.o.imageProcessor.replaceDataURIToBlobIdInView) { |
| 15155 |
return; |
| 15156 |
} |
| 15157 |
const list = editor.buffer.get(JODIT_IMAGE_BLOB_ID); |
| 15158 |
if (list) { |
| 15159 |
const keys = Object.keys(list); |
| 15160 |
for (const uri of keys){ |
| 15161 |
while(data.value.includes(uri)){ |
| 15162 |
data.value = data.value.replace(uri, list[uri]); |
| 15163 |
} |
| 15164 |
} |
| 15165 |
} |
| 15166 |
} |
| 15167 |
afterChange(data) { |
| 15168 |
return (0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 15169 |
const { jodit: editor } = this; |
| 15170 |
if (!editor.editor) { |
| 15171 |
return; |
| 15172 |
} |
| 15173 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.$$)('img', editor.editor).forEach((elm)=>{ |
| 15174 |
if (!(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.dataBind)(elm, JODIT_IMAGE_PROCESSOR_BINDED)) { |
| 15175 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.dataBind)(elm, JODIT_IMAGE_PROCESSOR_BINDED, true); |
| 15176 |
if (!elm.complete) { |
| 15177 |
editor.e.on(elm, 'load', function ElementOnLoad() { |
| 15178 |
var _editor_e; |
| 15179 |
!editor.isInDestruct && ((_editor_e = editor.e) === null || _editor_e === void 0 ? void 0 : _editor_e.fire('resize')); |
| 15180 |
editor.e.off(elm, 'load', ElementOnLoad); |
| 15181 |
}); |
| 15182 |
} |
| 15183 |
if (elm.src && /^data:/.test(elm.src)) { |
| 15184 |
replaceDataURIToBlobUUID(editor, elm); |
| 15185 |
} |
| 15186 |
editor.e.on(elm, 'mousedown touchstart', ()=>{ |
| 15187 |
editor.s.select(elm); |
| 15188 |
}); |
| 15189 |
} |
| 15190 |
}); |
| 15191 |
}).call(this); |
| 15192 |
} |
| 15193 |
} |
| 15194 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 15195 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.watch)(':afterGetValueFromEditor') |
| 15196 |
], imageProcessor.prototype, "onAfterGetValueFromEditor", null); |
| 15197 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 15198 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.watch)(':beforeSetElementValue') |
| 15199 |
], imageProcessor.prototype, "onBeforeSetElementValue", null); |
| 15200 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 15201 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.watch)([ |
| 15202 |
':change', |
| 15203 |
':afterInit', |
| 15204 |
':changePlace' |
| 15205 |
]), |
| 15206 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.debounce)() |
| 15207 |
], imageProcessor.prototype, "afterChange", null); |
| 15208 |
function replaceDataURIToBlobUUID(editor, elm) { |
| 15209 |
if (!editor.o.imageProcessor.replaceDataURIToBlobIdInView) { |
| 15210 |
return; |
| 15211 |
} |
| 15212 |
if (typeof ArrayBuffer === 'undefined' || typeof URL === 'undefined') { |
| 15213 |
return; |
| 15214 |
} |
| 15215 |
const dataUri = elm.src, blob = dataURItoBlob(dataUri); |
| 15216 |
elm.src = URL.createObjectURL(blob); |
| 15217 |
editor.e.fire('internalUpdate'); |
| 15218 |
const { buffer } = editor; |
| 15219 |
const list = buffer.get(JODIT_IMAGE_BLOB_ID) || {}; |
| 15220 |
list[elm.src] = dataUri; |
| 15221 |
editor.buffer.set(JODIT_IMAGE_BLOB_ID, list); |
| 15222 |
} |
| 15223 |
// https://stackoverflow.com/a/12300351 |
| 15224 |
function dataURItoBlob(dataURI) { |
| 15225 |
// convert base64 to raw binary data held in a string |
| 15226 |
// doesn't handle URLEncoded DataURIs - see SO answer #6850276 for code that does this |
| 15227 |
const byteString = atob(dataURI.split(',')[1]); |
| 15228 |
// separate out the mime component |
| 15229 |
const mimeString = dataURI.split(',')[0].split(':')[1].split(';')[0]; |
| 15230 |
// write the bytes of the string to an ArrayBuffer |
| 15231 |
const ab = new ArrayBuffer(byteString.length); |
| 15232 |
// create a view into the buffer |
| 15233 |
const ia = new Uint8Array(ab); |
| 15234 |
// set the bytes of the buffer to the correct values |
| 15235 |
for(let i = 0; i < byteString.length; i++){ |
| 15236 |
ia[i] = byteString.charCodeAt(i); |
| 15237 |
} |
| 15238 |
// write the ArrayBuffer to a blob, and you're done |
| 15239 |
return new Blob([ |
| 15240 |
ab |
| 15241 |
], { |
| 15242 |
type: mimeString |
| 15243 |
}); |
| 15244 |
} |
| 15245 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_4__.pluginSystem.add('imageProcessor', imageProcessor); |
| 15246 |
|
| 15247 |
|
| 15248 |
/***/ }), |
| 15249 |
|
| 15250 |
/***/ 40013: |
| 15251 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 15252 |
|
| 15253 |
"use strict"; |
| 15254 |
/* harmony import */ var jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(17312); |
| 15255 |
/* harmony import */ var jodit_core_helpers_checker_is_jodit_object__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(24497); |
| 15256 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5266); |
| 15257 |
/*! |
| 15258 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 15259 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 15260 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 15261 |
*/ /** |
| 15262 |
* @module modules/uploader |
| 15263 |
*/ |
| 15264 |
|
| 15265 |
|
| 15266 |
/** |
| 15267 |
* Module for processing download documents and images by Drag and Drop |
| 15268 |
* Drag and Drop files |
| 15269 |
*/ jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.enableDragAndDropFileToEditor = true; |
| 15270 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.uploader = { |
| 15271 |
url: '', |
| 15272 |
insertImageAsBase64URI: false, |
| 15273 |
imagesExtensions: [ |
| 15274 |
'jpg', |
| 15275 |
'png', |
| 15276 |
'jpeg', |
| 15277 |
'gif' |
| 15278 |
], |
| 15279 |
headers: null, |
| 15280 |
data: null, |
| 15281 |
filesVariableName (i) { |
| 15282 |
return `files[${i}]`; |
| 15283 |
}, |
| 15284 |
withCredentials: false, |
| 15285 |
pathVariableName: 'path', |
| 15286 |
format: 'json', |
| 15287 |
method: 'POST', |
| 15288 |
prepareData (formData) { |
| 15289 |
return formData; |
| 15290 |
}, |
| 15291 |
isSuccess (resp) { |
| 15292 |
return resp.success; |
| 15293 |
}, |
| 15294 |
getMessage (resp) { |
| 15295 |
return resp.data.messages !== undefined && (0,jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_0__.isArray)(resp.data.messages) ? resp.data.messages.join(' ') : ''; |
| 15296 |
}, |
| 15297 |
/** |
| 15298 |
* @see [[IUploader.processFileName]] |
| 15299 |
*/ processFileName (key, file, name) { |
| 15300 |
return [ |
| 15301 |
key, |
| 15302 |
file, |
| 15303 |
name |
| 15304 |
]; |
| 15305 |
}, |
| 15306 |
process (resp) { |
| 15307 |
return resp.data; |
| 15308 |
}, |
| 15309 |
error (e) { |
| 15310 |
this.j.message.error(e.message, 4000); |
| 15311 |
}, |
| 15312 |
getDisplayName (baseurl, filename) { |
| 15313 |
return baseurl + filename; |
| 15314 |
}, |
| 15315 |
defaultHandlerSuccess (resp) { |
| 15316 |
const j = this.j || this; |
| 15317 |
if (!(0,jodit_core_helpers_checker_is_jodit_object__WEBPACK_IMPORTED_MODULE_1__.isJoditObject)(j)) { |
| 15318 |
return; |
| 15319 |
} |
| 15320 |
if (resp.files && resp.files.length) { |
| 15321 |
resp.files.forEach((filename, index)=>{ |
| 15322 |
const [tagName, attr] = resp.isImages && resp.isImages[index] ? [ |
| 15323 |
'img', |
| 15324 |
'src' |
| 15325 |
] : [ |
| 15326 |
'a', |
| 15327 |
'href' |
| 15328 |
]; |
| 15329 |
const elm = j.createInside.element(tagName); |
| 15330 |
elm.setAttribute(attr, resp.baseurl + filename); |
| 15331 |
if (tagName === 'a') { |
| 15332 |
elm.textContent = j.o.uploader.getDisplayName.call(this, resp.baseurl, filename); |
| 15333 |
} |
| 15334 |
if (tagName === 'img') { |
| 15335 |
j.s.insertImage(elm, null, j.o.imageDefaultWidth); |
| 15336 |
} else { |
| 15337 |
j.s.insertNode(elm); |
| 15338 |
} |
| 15339 |
}); |
| 15340 |
} |
| 15341 |
}, |
| 15342 |
defaultHandlerError (e) { |
| 15343 |
this.j.message.error(e.message); |
| 15344 |
}, |
| 15345 |
contentType (requestData) { |
| 15346 |
return this.ow.FormData !== undefined && typeof requestData !== 'string' ? false : 'application/x-www-form-urlencoded; charset=UTF-8'; |
| 15347 |
} |
| 15348 |
}; |
| 15349 |
|
| 15350 |
|
| 15351 |
/***/ }), |
| 15352 |
|
| 15353 |
/***/ 40037: |
| 15354 |
/***/ (function(module) { |
| 15355 |
|
| 15356 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path stroke-width=\"0\" d=\"M381 1620q0 80-54.5 126t-135.5 46q-106 0-172-66l57-88q49 45 106 45 29 0 50.5-14.5t21.5-42.5q0-64-105-56l-26-56q8-10 32.5-43.5t42.5-54 37-38.5v-1q-16 0-48.5 1t-48.5 1v53h-106v-152h333v88l-95 115q51 12 81 49t30 88zm2-627v159h-362q-6-36-6-54 0-51 23.5-93t56.5-68 66-47.5 56.5-43.5 23.5-45q0-25-14.5-38.5t-39.5-13.5q-46 0-81 58l-85-59q24-51 71.5-79.5t105.5-28.5q73 0 123 41.5t50 112.5q0 50-34 91.5t-75 64.5-75.5 50.5-35.5 52.5h127v-60h105zm1409 319v192q0 13-9.5 22.5t-22.5 9.5h-1216q-13 0-22.5-9.5t-9.5-22.5v-192q0-14 9-23t23-9h1216q13 0 22.5 9.5t9.5 22.5zm-1408-899v99h-335v-99h107q0-41 .5-122t.5-121v-12h-2q-8 17-50 54l-71-76 136-127h106v404h108zm1408 387v192q0 13-9.5 22.5t-22.5 9.5h-1216q-13 0-22.5-9.5t-9.5-22.5v-192q0-14 9-23t23-9h1216q13 0 22.5 9.5t9.5 22.5zm0-512v192q0 13-9.5 22.5t-22.5 9.5h-1216q-13 0-22.5-9.5t-9.5-22.5v-192q0-13 9.5-22.5t22.5-9.5h1216q13 0 22.5 9.5t9.5 22.5z\"/> </svg>" |
| 15357 |
|
| 15358 |
/***/ }), |
| 15359 |
|
| 15360 |
/***/ 40253: |
| 15361 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 15362 |
|
| 15363 |
"use strict"; |
| 15364 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 15365 |
/* harmony export */ getStrongControlTypes: function() { return /* binding */ getStrongControlTypes; } |
| 15366 |
/* harmony export */ }); |
| 15367 |
/* harmony import */ var jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(17312); |
| 15368 |
/* harmony import */ var jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(93640); |
| 15369 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5266); |
| 15370 |
/* harmony import */ var _get_control_type__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(15982); |
| 15371 |
/*! |
| 15372 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 15373 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 15374 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 15375 |
*/ /** |
| 15376 |
* @module ui |
| 15377 |
*/ |
| 15378 |
|
| 15379 |
|
| 15380 |
|
| 15381 |
/** |
| 15382 |
* @private |
| 15383 |
*/ function getStrongControlTypes(items, controls) { |
| 15384 |
const elements = (0,jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_0__.isArray)(items) ? items : (0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__.keys)(items, false).map((key)=>{ |
| 15385 |
const value = items[key] || {}; |
| 15386 |
return (0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__.ConfigProto)({ |
| 15387 |
name: key |
| 15388 |
}, value); |
| 15389 |
}); |
| 15390 |
return elements.map((item)=>(0,_get_control_type__WEBPACK_IMPORTED_MODULE_3__.getControlType)(item, controls || jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.defaultOptions.controls)); |
| 15391 |
} |
| 15392 |
|
| 15393 |
|
| 15394 |
/***/ }), |
| 15395 |
|
| 15396 |
/***/ 40291: |
| 15397 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 15398 |
|
| 15399 |
"use strict"; |
| 15400 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5266); |
| 15401 |
/*! |
| 15402 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 15403 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 15404 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 15405 |
*/ /** |
| 15406 |
* @module plugins/bold |
| 15407 |
*/ |
| 15408 |
jodit_config__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.controls.subscript = { |
| 15409 |
tags: [ |
| 15410 |
'sub' |
| 15411 |
], |
| 15412 |
tooltip: 'subscript' |
| 15413 |
}; |
| 15414 |
jodit_config__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.controls.superscript = { |
| 15415 |
tags: [ |
| 15416 |
'sup' |
| 15417 |
], |
| 15418 |
tooltip: 'superscript' |
| 15419 |
}; |
| 15420 |
jodit_config__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.controls.bold = { |
| 15421 |
tagRegExp: /^(strong|b)$/i, |
| 15422 |
tags: [ |
| 15423 |
'strong', |
| 15424 |
'b' |
| 15425 |
], |
| 15426 |
css: { |
| 15427 |
'font-weight': [ |
| 15428 |
'bold', |
| 15429 |
'700' |
| 15430 |
] |
| 15431 |
}, |
| 15432 |
tooltip: 'Bold' |
| 15433 |
}; |
| 15434 |
jodit_config__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.controls.italic = { |
| 15435 |
tagRegExp: /^(em|i)$/i, |
| 15436 |
tags: [ |
| 15437 |
'em', |
| 15438 |
'i' |
| 15439 |
], |
| 15440 |
css: { |
| 15441 |
'font-style': 'italic' |
| 15442 |
}, |
| 15443 |
tooltip: 'Italic' |
| 15444 |
}; |
| 15445 |
jodit_config__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.controls.underline = { |
| 15446 |
tagRegExp: /^(u)$/i, |
| 15447 |
tags: [ |
| 15448 |
'u' |
| 15449 |
], |
| 15450 |
css: { |
| 15451 |
'text-decoration-line': 'underline' |
| 15452 |
}, |
| 15453 |
tooltip: 'Underline' |
| 15454 |
}; |
| 15455 |
jodit_config__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.controls.strikethrough = { |
| 15456 |
tagRegExp: /^(s)$/i, |
| 15457 |
tags: [ |
| 15458 |
's' |
| 15459 |
], |
| 15460 |
css: { |
| 15461 |
'text-decoration-line': 'line-through' |
| 15462 |
}, |
| 15463 |
tooltip: 'Strike through' |
| 15464 |
}; |
| 15465 |
|
| 15466 |
|
| 15467 |
/***/ }), |
| 15468 |
|
| 15469 |
/***/ 41111: |
| 15470 |
/***/ (function(module) { |
| 15471 |
|
| 15472 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M384 1662l17-85q6-2 81.5-21.5t111.5-37.5q28-35 41-101 1-7 62-289t114-543.5 52-296.5v-25q-24-13-54.5-18.5t-69.5-8-58-5.5l19-103q33 2 120 6.5t149.5 7 120.5 2.5q48 0 98.5-2.5t121-7 98.5-6.5q-5 39-19 89-30 10-101.5 28.5t-108.5 33.5q-8 19-14 42.5t-9 40-7.5 45.5-6.5 42q-27 148-87.5 419.5t-77.5 355.5q-2 9-13 58t-20 90-16 83.5-6 57.5l1 18q17 4 185 31-3 44-16 99-11 0-32.5 1.5t-32.5 1.5q-29 0-87-10t-86-10q-138-2-206-2-51 0-143 9t-121 11z\"/> </svg>" |
| 15473 |
|
| 15474 |
/***/ }), |
| 15475 |
|
| 15476 |
/***/ 41324: |
| 15477 |
/***/ (function(module) { |
| 15478 |
|
| 15479 |
"use strict"; |
| 15480 |
module.exports = __WEBPACK_EXTERNAL_MODULE__41324__; |
| 15481 |
|
| 15482 |
/***/ }), |
| 15483 |
|
| 15484 |
/***/ 41360: |
| 15485 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 15486 |
|
| 15487 |
"use strict"; |
| 15488 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 15489 |
/* harmony export */ nonenumerable: function() { return /* binding */ nonenumerable; } |
| 15490 |
/* harmony export */ }); |
| 15491 |
/*! |
| 15492 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 15493 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 15494 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 15495 |
*/ /** |
| 15496 |
* [[include:core/decorators/nonenumerable/README.md]] |
| 15497 |
* @packageDocumentation |
| 15498 |
* @module decorators/nonenumerable |
| 15499 |
*/ const nonenumerable = (target, propertyKey)=>{ |
| 15500 |
const descriptor = Object.getOwnPropertyDescriptor(target, propertyKey) || {}; |
| 15501 |
if (descriptor.enumerable !== false) { |
| 15502 |
Object.defineProperty(target, propertyKey, { |
| 15503 |
enumerable: false, |
| 15504 |
set (value) { |
| 15505 |
Object.defineProperty(this, propertyKey, { |
| 15506 |
enumerable: false, |
| 15507 |
writable: true, |
| 15508 |
value |
| 15509 |
}); |
| 15510 |
} |
| 15511 |
}); |
| 15512 |
} |
| 15513 |
}; |
| 15514 |
|
| 15515 |
|
| 15516 |
/***/ }), |
| 15517 |
|
| 15518 |
/***/ 41411: |
| 15519 |
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { |
| 15520 |
|
| 15521 |
"use strict"; |
| 15522 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 15523 |
/* harmony export */ _: function() { return /* binding */ _object_spread; } |
| 15524 |
/* harmony export */ }); |
| 15525 |
/* harmony import */ var _define_property_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 15526 |
|
| 15527 |
function _object_spread(target) { |
| 15528 |
for(var i = 1; i < arguments.length; i++){ |
| 15529 |
var source = arguments[i] != null ? arguments[i] : {}; |
| 15530 |
var ownKeys = Object.keys(source); |
| 15531 |
if (typeof Object.getOwnPropertySymbols === "function") { |
| 15532 |
ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function(sym) { |
| 15533 |
return Object.getOwnPropertyDescriptor(source, sym).enumerable; |
| 15534 |
})); |
| 15535 |
} |
| 15536 |
ownKeys.forEach(function(key) { |
| 15537 |
(0,_define_property_js__WEBPACK_IMPORTED_MODULE_0__._)(target, key, source[key]); |
| 15538 |
}); |
| 15539 |
} |
| 15540 |
return target; |
| 15541 |
} |
| 15542 |
|
| 15543 |
|
| 15544 |
|
| 15545 |
/***/ }), |
| 15546 |
|
| 15547 |
/***/ 41599: |
| 15548 |
/***/ (function(module) { |
| 15549 |
|
| 15550 |
/*! |
| 15551 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 15552 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 15553 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 15554 |
*/ module.exports = { |
| 15555 |
'copy-format': '复制格式' |
| 15556 |
}; |
| 15557 |
|
| 15558 |
|
| 15559 |
/***/ }), |
| 15560 |
|
| 15561 |
/***/ 42259: |
| 15562 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 15563 |
|
| 15564 |
"use strict"; |
| 15565 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 15566 |
/* harmony export */ cursorInTheEdgeOfString: function() { return /* binding */ cursorInTheEdgeOfString; }, |
| 15567 |
/* harmony export */ findCorrectCurrentNode: function() { return /* binding */ findCorrectCurrentNode; }, |
| 15568 |
/* harmony export */ moveNodeInsideStart: function() { return /* reexport safe */ _move_node_inside_start__WEBPACK_IMPORTED_MODULE_2__.moveNodeInsideStart; } |
| 15569 |
/* harmony export */ }); |
| 15570 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 15571 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(23211); |
| 15572 |
/* harmony import */ var _move_node_inside_start__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(89817); |
| 15573 |
/* harmony import */ var _move_the_node_along_the_edge_outward__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(7470); |
| 15574 |
/*! |
| 15575 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 15576 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 15577 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 15578 |
*/ /** |
| 15579 |
* @module selection |
| 15580 |
*/ |
| 15581 |
|
| 15582 |
|
| 15583 |
|
| 15584 |
/** |
| 15585 |
* Check if the cursor is at the edge of the string |
| 15586 |
* @private |
| 15587 |
*/ function cursorInTheEdgeOfString(container, offset, start, end) { |
| 15588 |
var _container_nodeValue; |
| 15589 |
const text = ((_container_nodeValue = container.nodeValue) === null || _container_nodeValue === void 0 ? void 0 : _container_nodeValue.length) ? container.nodeValue : ''; |
| 15590 |
if (end && text.replace((0,jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE_REG_EXP_END)(), '').length > offset) { |
| 15591 |
return true; |
| 15592 |
} |
| 15593 |
const inv = (0,jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE_REG_EXP_START)().exec(text); |
| 15594 |
return start && (inv && inv[0].length < offset || !inv && offset > 0); |
| 15595 |
} |
| 15596 |
function findCorrectCurrentNode(node, range, rightMode, isCollapsed, checkChild, child) { |
| 15597 |
node = range.startContainer.childNodes[range.startOffset]; |
| 15598 |
if (!node) { |
| 15599 |
node = range.startContainer.childNodes[range.startOffset - 1]; |
| 15600 |
rightMode = true; |
| 15601 |
} |
| 15602 |
if (node && isCollapsed && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isText(node)) { |
| 15603 |
// test Current method - Cursor in the left of some SPAN |
| 15604 |
if (!rightMode && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isText(node.previousSibling)) { |
| 15605 |
node = node.previousSibling; |
| 15606 |
} else if (checkChild) { |
| 15607 |
let current = child(node); |
| 15608 |
while(current){ |
| 15609 |
if (current && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isText(current)) { |
| 15610 |
node = current; |
| 15611 |
break; |
| 15612 |
} |
| 15613 |
current = child(current); |
| 15614 |
} |
| 15615 |
} |
| 15616 |
} |
| 15617 |
if (node && !isCollapsed && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isText(node)) { |
| 15618 |
let leftChild = node, rightChild = node; |
| 15619 |
do { |
| 15620 |
leftChild = leftChild.firstChild; |
| 15621 |
rightChild = rightChild.lastChild; |
| 15622 |
}while (leftChild && rightChild && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isText(leftChild)) |
| 15623 |
if (leftChild === rightChild && leftChild && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isText(leftChild)) { |
| 15624 |
node = leftChild; |
| 15625 |
} |
| 15626 |
} |
| 15627 |
return { |
| 15628 |
node, |
| 15629 |
rightMode |
| 15630 |
}; |
| 15631 |
} |
| 15632 |
|
| 15633 |
|
| 15634 |
/***/ }), |
| 15635 |
|
| 15636 |
/***/ 42360: |
| 15637 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 15638 |
|
| 15639 |
"use strict"; |
| 15640 |
/* harmony import */ var jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(27795); |
| 15641 |
/* harmony import */ var jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(29434); |
| 15642 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5266); |
| 15643 |
/* harmony import */ var _icons_indent_svg__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(67176); |
| 15644 |
/* harmony import */ var _icons_indent_svg__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_icons_indent_svg__WEBPACK_IMPORTED_MODULE_3__); |
| 15645 |
/* harmony import */ var _icons_outdent_svg__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(14017); |
| 15646 |
/* harmony import */ var _icons_outdent_svg__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_icons_outdent_svg__WEBPACK_IMPORTED_MODULE_4__); |
| 15647 |
/* harmony import */ var _helpers__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(11917); |
| 15648 |
/*! |
| 15649 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 15650 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 15651 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 15652 |
*/ /** |
| 15653 |
* @module plugins/indent |
| 15654 |
*/ |
| 15655 |
|
| 15656 |
|
| 15657 |
|
| 15658 |
|
| 15659 |
|
| 15660 |
jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_1__.Icon.set('indent', (_icons_indent_svg__WEBPACK_IMPORTED_MODULE_3___default())).set('outdent', (_icons_outdent_svg__WEBPACK_IMPORTED_MODULE_4___default())); |
| 15661 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.controls.indent = { |
| 15662 |
tooltip: 'Increase Indent' |
| 15663 |
}; |
| 15664 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.controls.outdent = { |
| 15665 |
isDisabled: (editor)=>{ |
| 15666 |
const current = editor.s.current(); |
| 15667 |
if (current) { |
| 15668 |
const currentBox = jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(current, jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isBlock, editor.editor); |
| 15669 |
if (currentBox) { |
| 15670 |
const arrow = (0,_helpers__WEBPACK_IMPORTED_MODULE_5__.getKey)(editor.o.direction, currentBox); |
| 15671 |
return !currentBox.style[arrow] || parseInt(currentBox.style[arrow], 10) <= 0; |
| 15672 |
} |
| 15673 |
} |
| 15674 |
return true; |
| 15675 |
}, |
| 15676 |
tooltip: 'Decrease Indent' |
| 15677 |
}; |
| 15678 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.indentMargin = 10; |
| 15679 |
|
| 15680 |
|
| 15681 |
/***/ }), |
| 15682 |
|
| 15683 |
/***/ 42412: |
| 15684 |
/***/ (function(module) { |
| 15685 |
|
| 15686 |
/*! |
| 15687 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 15688 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 15689 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 15690 |
*/ module.exports = { |
| 15691 |
symbols: 'Szimbólum' |
| 15692 |
}; |
| 15693 |
|
| 15694 |
|
| 15695 |
/***/ }), |
| 15696 |
|
| 15697 |
/***/ 42462: |
| 15698 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 15699 |
|
| 15700 |
"use strict"; |
| 15701 |
/* unused harmony export color */ |
| 15702 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(28077); |
| 15703 |
/* harmony import */ var jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(65946); |
| 15704 |
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(8071); |
| 15705 |
/*! |
| 15706 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 15707 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 15708 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 15709 |
*/ /** |
| 15710 |
* [[include:plugins/color/README.md]] |
| 15711 |
* @packageDocumentation |
| 15712 |
* @module plugins/color |
| 15713 |
*/ |
| 15714 |
|
| 15715 |
|
| 15716 |
/** |
| 15717 |
* Process commands `background` and `forecolor` |
| 15718 |
*/ function color(editor) { |
| 15719 |
editor.registerButton({ |
| 15720 |
name: 'brush', |
| 15721 |
group: 'color' |
| 15722 |
}); |
| 15723 |
const callback = (command, second, third)=>{ |
| 15724 |
const colorHEX = (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.normalizeColor)(third); |
| 15725 |
switch(command){ |
| 15726 |
case 'background': |
| 15727 |
editor.s.commitStyle({ |
| 15728 |
attributes: { |
| 15729 |
style: { |
| 15730 |
backgroundColor: !colorHEX ? '' : colorHEX |
| 15731 |
} |
| 15732 |
} |
| 15733 |
}); |
| 15734 |
break; |
| 15735 |
case 'forecolor': |
| 15736 |
editor.s.commitStyle({ |
| 15737 |
attributes: { |
| 15738 |
style: { |
| 15739 |
color: !colorHEX ? '' : colorHEX |
| 15740 |
} |
| 15741 |
} |
| 15742 |
}); |
| 15743 |
break; |
| 15744 |
} |
| 15745 |
editor.synchronizeValues(); |
| 15746 |
return false; |
| 15747 |
}; |
| 15748 |
editor.registerCommand('forecolor', callback).registerCommand('background', callback); |
| 15749 |
} |
| 15750 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_0__.pluginSystem.add('color', color); |
| 15751 |
|
| 15752 |
|
| 15753 |
/***/ }), |
| 15754 |
|
| 15755 |
/***/ 42573: |
| 15756 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 15757 |
|
| 15758 |
"use strict"; |
| 15759 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 15760 |
/* harmony export */ ToolbarCollection: function() { return /* binding */ ToolbarCollection; } |
| 15761 |
/* harmony export */ }); |
| 15762 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 15763 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 15764 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(84839); |
| 15765 |
/* harmony import */ var jodit_core_decorators_autobind_autobind__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(49574); |
| 15766 |
/* harmony import */ var jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(91672); |
| 15767 |
/* harmony import */ var jodit_core_decorators_hook_hook__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(29200); |
| 15768 |
/* harmony import */ var jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(68616); |
| 15769 |
/* harmony import */ var jodit_core_helpers_utils_error_error__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(38027); |
| 15770 |
/* harmony import */ var jodit_core_ui_group_list__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(97959); |
| 15771 |
/* harmony import */ var jodit_modules_toolbar_factory__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(4274); |
| 15772 |
/*! |
| 15773 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 15774 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 15775 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 15776 |
*/ /** |
| 15777 |
* [[include:modules/toolbar/collection/README.md]] |
| 15778 |
* @packageDocumentation |
| 15779 |
* @module modules/toolbar/collection |
| 15780 |
*/ |
| 15781 |
|
| 15782 |
|
| 15783 |
|
| 15784 |
|
| 15785 |
|
| 15786 |
|
| 15787 |
|
| 15788 |
|
| 15789 |
|
| 15790 |
|
| 15791 |
class ToolbarCollection extends jodit_core_ui_group_list__WEBPACK_IMPORTED_MODULE_8__.UIList { |
| 15792 |
className() { |
| 15793 |
return 'ToolbarCollection'; |
| 15794 |
} |
| 15795 |
getRole() { |
| 15796 |
return 'toolbar'; |
| 15797 |
} |
| 15798 |
/** |
| 15799 |
* First button in a list |
| 15800 |
*/ get firstButton() { |
| 15801 |
const [button] = this.buttons; |
| 15802 |
return button || null; |
| 15803 |
} |
| 15804 |
makeButton(control, target = null) { |
| 15805 |
return (0,jodit_modules_toolbar_factory__WEBPACK_IMPORTED_MODULE_9__.makeButton)(this.j, control, target); |
| 15806 |
} |
| 15807 |
makeSelect(control, target = null) { |
| 15808 |
return (0,jodit_modules_toolbar_factory__WEBPACK_IMPORTED_MODULE_9__.makeSelect)(this.j, control, target); |
| 15809 |
} |
| 15810 |
/** |
| 15811 |
* Button should be active |
| 15812 |
*/ shouldBeActive(button) { |
| 15813 |
return undefined; |
| 15814 |
} |
| 15815 |
/** |
| 15816 |
* The Button should be disabled |
| 15817 |
*/ shouldBeDisabled(button) { |
| 15818 |
return undefined; |
| 15819 |
} |
| 15820 |
/** |
| 15821 |
* Returns current target for button |
| 15822 |
*/ getTarget(button) { |
| 15823 |
return button.target || null; |
| 15824 |
} |
| 15825 |
__immediateUpdate() { |
| 15826 |
if (this.isDestructed || this.j.isLocked) { |
| 15827 |
return; |
| 15828 |
} |
| 15829 |
super.update(); |
| 15830 |
this.j.e.fire('afterUpdateToolbar', this); |
| 15831 |
} |
| 15832 |
update() { |
| 15833 |
this.__immediateUpdate(); |
| 15834 |
} |
| 15835 |
/** |
| 15836 |
* Set direction |
| 15837 |
*/ setDirection(direction) { |
| 15838 |
this.container.style.direction = direction; |
| 15839 |
this.container.setAttribute('dir', direction); |
| 15840 |
} |
| 15841 |
__initEvents() { |
| 15842 |
this.j.e.on(this.__listenEvents, this.update).on('afterSetMode focus', this.__immediateUpdate); |
| 15843 |
} |
| 15844 |
hide() { |
| 15845 |
this.container.remove(); |
| 15846 |
} |
| 15847 |
show() { |
| 15848 |
this.appendTo(this.j.toolbarContainer); |
| 15849 |
} |
| 15850 |
showInline(bound) { |
| 15851 |
throw (0,jodit_core_helpers_utils_error_error__WEBPACK_IMPORTED_MODULE_7__.error)('The method is not implemented for this class.'); |
| 15852 |
} |
| 15853 |
/** @override **/ build(items, target = null) { |
| 15854 |
const itemsWithGroupps = this.j.e.fire('beforeToolbarBuild', items); |
| 15855 |
if (itemsWithGroupps) { |
| 15856 |
items = itemsWithGroupps; |
| 15857 |
} |
| 15858 |
super.build(items, target); |
| 15859 |
return this; |
| 15860 |
} |
| 15861 |
/** @override **/ destruct() { |
| 15862 |
if (this.isDestructed) { |
| 15863 |
return; |
| 15864 |
} |
| 15865 |
this.j.e.off(this.__listenEvents, this.update).off('afterSetMode focus', this.__immediateUpdate); |
| 15866 |
super.destruct(); |
| 15867 |
} |
| 15868 |
constructor(jodit){ |
| 15869 |
super(jodit), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__listenEvents", 'updatePlugins updateToolbar changeStack mousedown mouseup keydown change readonly afterResize ' + 'selectionchange changeSelection focus afterSetMode touchstart focus blur'); |
| 15870 |
} |
| 15871 |
} |
| 15872 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 15873 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_6__.watch)(':afterInit'), |
| 15874 |
jodit_core_decorators_autobind_autobind__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 15875 |
], ToolbarCollection.prototype, "__immediateUpdate", null); |
| 15876 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 15877 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.debounce)((ctx)=>ctx.j.defaultTimeout, true) |
| 15878 |
], ToolbarCollection.prototype, "update", null); |
| 15879 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 15880 |
(0,jodit_core_decorators_hook_hook__WEBPACK_IMPORTED_MODULE_5__.hook)('ready') |
| 15881 |
], ToolbarCollection.prototype, "__initEvents", null); |
| 15882 |
ToolbarCollection = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 15883 |
jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_4__.component |
| 15884 |
], ToolbarCollection); |
| 15885 |
|
| 15886 |
|
| 15887 |
/***/ }), |
| 15888 |
|
| 15889 |
/***/ 42689: |
| 15890 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 15891 |
|
| 15892 |
"use strict"; |
| 15893 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 15894 |
/* harmony export */ eventEmitter: function() { return /* binding */ eventEmitter; } |
| 15895 |
/* harmony export */ }); |
| 15896 |
/* harmony import */ var _event_emitter__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(93747); |
| 15897 |
/*! |
| 15898 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 15899 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 15900 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 15901 |
*/ /** |
| 15902 |
* @module event-emitter |
| 15903 |
*/ |
| 15904 |
const eventEmitter = new _event_emitter__WEBPACK_IMPORTED_MODULE_0__.EventEmitter(); |
| 15905 |
|
| 15906 |
|
| 15907 |
/***/ }), |
| 15908 |
|
| 15909 |
/***/ 42766: |
| 15910 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 15911 |
|
| 15912 |
"use strict"; |
| 15913 |
/* unused harmony export addNewLine */ |
| 15914 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 15915 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 15916 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(84839); |
| 15917 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(28077); |
| 15918 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(65946); |
| 15919 |
/* harmony import */ var jodit_modules__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(60936); |
| 15920 |
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(10685); |
| 15921 |
/*! |
| 15922 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 15923 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 15924 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 15925 |
*/ /** |
| 15926 |
* [[include:plugins/add-new-line/README.md]] |
| 15927 |
* @packageDocumentation |
| 15928 |
* @module plugins/add-new-line |
| 15929 |
*/ |
| 15930 |
|
| 15931 |
|
| 15932 |
|
| 15933 |
|
| 15934 |
|
| 15935 |
|
| 15936 |
|
| 15937 |
const ns = 'addnewline'; |
| 15938 |
/** |
| 15939 |
* Create helper for adding new paragraph(Jodit.defaultOptions.enter tag) before iframe, table or image |
| 15940 |
*/ class addNewLine extends jodit_modules__WEBPACK_IMPORTED_MODULE_5__.Plugin { |
| 15941 |
__show() { |
| 15942 |
if (this.j.o.readonly || this.j.isLocked) { |
| 15943 |
return; |
| 15944 |
} |
| 15945 |
this.j.async.clearTimeout(this.__timeout); |
| 15946 |
if (this.__isShown) { |
| 15947 |
return; |
| 15948 |
} |
| 15949 |
this.__isShown = true; |
| 15950 |
this.j.container.appendChild(this.__line); |
| 15951 |
this.__line.style.width = this.j.container.clientWidth + 'px'; |
| 15952 |
} |
| 15953 |
onLock(isLocked) { |
| 15954 |
if (isLocked && this.__isShown) { |
| 15955 |
this.__hideForce(); |
| 15956 |
} |
| 15957 |
} |
| 15958 |
__hide() { |
| 15959 |
if (!this.__isShown || this.__lineInFocus) { |
| 15960 |
return; |
| 15961 |
} |
| 15962 |
this.__timeout = this.j.async.setTimeout(this.__hideForce, { |
| 15963 |
timeout: 500, |
| 15964 |
label: 'add-new-line-hide' |
| 15965 |
}); |
| 15966 |
} |
| 15967 |
afterInit(editor) { |
| 15968 |
if (!editor.o.addNewLine) { |
| 15969 |
return; |
| 15970 |
} |
| 15971 |
editor.e.on(this.__line, 'mousemove', (e)=>{ |
| 15972 |
e.stopPropagation(); |
| 15973 |
}).on(this.__line, 'mousedown touchstart', this.__onClickLine).on('change', this.__hideForce).on(this.__line, 'mouseenter', ()=>{ |
| 15974 |
this.j.async.clearTimeout(this.__timeout); |
| 15975 |
this.__lineInFocus = true; |
| 15976 |
}).on(this.__line, 'mouseleave', ()=>{ |
| 15977 |
this.__lineInFocus = false; |
| 15978 |
}).on('changePlace', this.__addEventListeners.bind(this)); |
| 15979 |
this.__addEventListeners(); |
| 15980 |
} |
| 15981 |
__addEventListeners() { |
| 15982 |
const editor = this.j; |
| 15983 |
editor.e.off(editor.editor, '.' + ns).off(editor.container, '.' + ns).off('.' + ns).on([ |
| 15984 |
editor.ow, |
| 15985 |
editor.ew, |
| 15986 |
editor.editor |
| 15987 |
], 'scroll' + '.' + ns, this.__hideForce).on('finishedCleanHTMLWorker' + '.' + ns, this.__hideForce).on(editor.editor, 'click' + '.' + ns, this.__hide).on(editor.container, 'mouseleave' + '.' + ns, this.__hide).on(editor.editor, 'mousemove' + '.' + ns, this.__onMouseMove); |
| 15988 |
} |
| 15989 |
onDblClickEditor(e) { |
| 15990 |
const editor = this.j; |
| 15991 |
if (!editor.o.readonly && editor.o.addNewLineOnDBLClick && e.target === editor.editor && editor.s.isCollapsed()) { |
| 15992 |
const editorBound = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.offset)(editor.editor, editor, editor.ed); |
| 15993 |
const top = e.pageY - editor.ew.scrollX; |
| 15994 |
const p = editor.createInside.element(editor.o.enter); |
| 15995 |
if (Math.abs(top - editorBound.top) < Math.abs(top - (editorBound.height + editorBound.top)) && editor.editor.firstChild) { |
| 15996 |
editor.editor.insertBefore(p, editor.editor.firstChild); |
| 15997 |
} else { |
| 15998 |
editor.editor.appendChild(p); |
| 15999 |
} |
| 16000 |
editor.s.setCursorIn(p); |
| 16001 |
editor.synchronizeValues(); |
| 16002 |
this.__hideForce(); |
| 16003 |
e.preventDefault(); |
| 16004 |
} |
| 16005 |
} |
| 16006 |
__onMouseMove(e) { |
| 16007 |
const editor = this.j; |
| 16008 |
let currentElement = editor.ed.elementFromPoint(e.clientX, e.clientY); |
| 16009 |
if (!jodit_modules__WEBPACK_IMPORTED_MODULE_5__.Dom.isHTMLElement(currentElement) || !jodit_modules__WEBPACK_IMPORTED_MODULE_5__.Dom.isOrContains(editor.editor, currentElement)) { |
| 16010 |
return; |
| 16011 |
} |
| 16012 |
if (editor.editor !== currentElement && !this.__isMatchedTag(currentElement)) { |
| 16013 |
currentElement = jodit_modules__WEBPACK_IMPORTED_MODULE_5__.Dom.closest(currentElement, this.__isMatchedTag, editor.editor); |
| 16014 |
} |
| 16015 |
if (!currentElement) { |
| 16016 |
this.__hide(); |
| 16017 |
return; |
| 16018 |
} |
| 16019 |
if (this.__isMatchedTag(currentElement)) { |
| 16020 |
const parentBox = jodit_modules__WEBPACK_IMPORTED_MODULE_5__.Dom.up(currentElement, jodit_modules__WEBPACK_IMPORTED_MODULE_5__.Dom.isBlock, editor.editor); |
| 16021 |
if (parentBox && parentBox !== editor.editor) { |
| 16022 |
currentElement = parentBox; |
| 16023 |
} |
| 16024 |
} |
| 16025 |
const pos = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.position)(currentElement, this.j); |
| 16026 |
let top = false; |
| 16027 |
let { clientY, clientX } = e; |
| 16028 |
if (this.j.iframe) { |
| 16029 |
const { top, left } = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.position)(this.j.iframe, this.j, true); |
| 16030 |
clientY += top; |
| 16031 |
clientX += left; |
| 16032 |
} |
| 16033 |
const delta = this.j.o.addNewLineDeltaShow; |
| 16034 |
if (Math.abs(clientY - pos.top) <= delta) { |
| 16035 |
top = pos.top; |
| 16036 |
this.__isBeforeContent = true; |
| 16037 |
} else if (Math.abs(clientY - (pos.top + pos.height)) <= delta) { |
| 16038 |
top = pos.top + pos.height; |
| 16039 |
this.__isBeforeContent = false; |
| 16040 |
} |
| 16041 |
const isEditor = editor.editor === currentElement; |
| 16042 |
if (top !== false && (isEditor && !this.__isBeforeContent || !isEditor && !(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.call)(this.__isBeforeContent ? jodit_modules__WEBPACK_IMPORTED_MODULE_5__.Dom.prev : jodit_modules__WEBPACK_IMPORTED_MODULE_5__.Dom.next, currentElement, this.__canGetFocus, editor.editor))) { |
| 16043 |
this.__line.style.top = top + 'px'; |
| 16044 |
this.__current = currentElement; |
| 16045 |
this.__show(); |
| 16046 |
this.__line.style.setProperty('--jd-anl-handle-offset', clientX - pos.left - 10 + 'px'); |
| 16047 |
} else { |
| 16048 |
this.__current = false; |
| 16049 |
this.__hide(); |
| 16050 |
} |
| 16051 |
} |
| 16052 |
/** @override */ beforeDestruct() { |
| 16053 |
this.j.async.clearTimeout(this.__timeout); |
| 16054 |
this.j.e.off(this.__line).off('changePlace', this.__addEventListeners); |
| 16055 |
jodit_modules__WEBPACK_IMPORTED_MODULE_5__.Dom.safeRemove(this.__line); |
| 16056 |
this.j.e.off([ |
| 16057 |
this.j.ow, |
| 16058 |
this.j.ew, |
| 16059 |
this.j.editor |
| 16060 |
], '.' + ns).off(this.j.container, '.' + ns).off('.' + ns); |
| 16061 |
} |
| 16062 |
constructor(...args){ |
| 16063 |
super(...args), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__line", this.j.c.fromHTML(`<div role="button" tabindex="-1" title="${this.j.i18n('Break')}" class="jodit-add-new-line"><span>${jodit_modules__WEBPACK_IMPORTED_MODULE_5__.Icon.get('enter')}</span></div>`)), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__isMatchedTag", (node)=>Boolean(node && this.j.o.addNewLineTagsTriggers.includes(node.nodeName.toLowerCase()))), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__timeout", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__isBeforeContent", false), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__current", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__lineInFocus", false), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__isShown", false), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__hideForce", ()=>{ |
| 16064 |
if (!this.__isShown) { |
| 16065 |
return; |
| 16066 |
} |
| 16067 |
this.__isShown = false; |
| 16068 |
this.j.async.clearTimeout(this.__timeout); |
| 16069 |
this.__lineInFocus = false; |
| 16070 |
jodit_modules__WEBPACK_IMPORTED_MODULE_5__.Dom.safeRemove(this.__line); |
| 16071 |
this.__line.style.setProperty('--jd-anl-handle-offset', '0'); |
| 16072 |
}), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__canGetFocus", (elm)=>{ |
| 16073 |
return elm != null && jodit_modules__WEBPACK_IMPORTED_MODULE_5__.Dom.isBlock(elm) && !/^(img|table|iframe|hr)$/i.test(elm.nodeName); |
| 16074 |
}), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__onClickLine", (e)=>{ |
| 16075 |
const editor = this.j; |
| 16076 |
const p = editor.createInside.element(editor.o.enter); |
| 16077 |
if (this.__isBeforeContent && this.__current && this.__current.parentNode) { |
| 16078 |
if (this.__current === editor.editor) { |
| 16079 |
jodit_modules__WEBPACK_IMPORTED_MODULE_5__.Dom.prepend(editor.editor, p); |
| 16080 |
} else { |
| 16081 |
this.__current.parentNode.insertBefore(p, this.__current); |
| 16082 |
} |
| 16083 |
} else { |
| 16084 |
editor.editor.appendChild(p); |
| 16085 |
} |
| 16086 |
editor.s.setCursorIn(p); |
| 16087 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.scrollIntoViewIfNeeded)(p, editor.editor, editor.ed); |
| 16088 |
editor.synchronizeValues(); |
| 16089 |
this.__hideForce(); |
| 16090 |
e.preventDefault(); |
| 16091 |
}); |
| 16092 |
} |
| 16093 |
} |
| 16094 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 16095 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.watch)(':lock') |
| 16096 |
], addNewLine.prototype, "onLock", null); |
| 16097 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 16098 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.autobind |
| 16099 |
], addNewLine.prototype, "__hide", null); |
| 16100 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 16101 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.watch)(':dblclick') |
| 16102 |
], addNewLine.prototype, "onDblClickEditor", null); |
| 16103 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 16104 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.throttle)((ctx)=>ctx.defaultTimeout) |
| 16105 |
], addNewLine.prototype, "__onMouseMove", null); |
| 16106 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_3__.pluginSystem.add('addNewLine', addNewLine); |
| 16107 |
|
| 16108 |
|
| 16109 |
/***/ }), |
| 16110 |
|
| 16111 |
/***/ 42820: |
| 16112 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 16113 |
|
| 16114 |
"use strict"; |
| 16115 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 16116 |
/* harmony export */ LimitedStack: function() { return /* binding */ LimitedStack; } |
| 16117 |
/* harmony export */ }); |
| 16118 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 16119 |
/*! |
| 16120 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 16121 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 16122 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 16123 |
*/ /** |
| 16124 |
* @module helpers/utils |
| 16125 |
*/ |
| 16126 |
class LimitedStack { |
| 16127 |
push(item) { |
| 16128 |
this.stack.push(item); |
| 16129 |
if (this.stack.length > this.limit) { |
| 16130 |
this.stack.shift(); |
| 16131 |
} |
| 16132 |
return this; |
| 16133 |
} |
| 16134 |
pop() { |
| 16135 |
return this.stack.pop(); |
| 16136 |
} |
| 16137 |
find(clb) { |
| 16138 |
return this.stack.find(clb); |
| 16139 |
} |
| 16140 |
constructor(limit){ |
| 16141 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "limit", void 0); |
| 16142 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "stack", void 0); |
| 16143 |
this.limit = limit; |
| 16144 |
this.stack = []; |
| 16145 |
} |
| 16146 |
} |
| 16147 |
|
| 16148 |
|
| 16149 |
/***/ }), |
| 16150 |
|
| 16151 |
/***/ 43218: |
| 16152 |
/***/ (function(module) { |
| 16153 |
|
| 16154 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M512 1248v192q0 40-28 68t-68 28h-320q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h320q40 0 68 28t28 68zm0-512v192q0 40-28 68t-68 28h-320q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h320q40 0 68 28t28 68zm640 512v192q0 40-28 68t-68 28h-320q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h320q40 0 68 28t28 68zm-640-1024v192q0 40-28 68t-68 28h-320q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h320q40 0 68 28t28 68zm640 512v192q0 40-28 68t-68 28h-320q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h320q40 0 68 28t28 68zm640 512v192q0 40-28 68t-68 28h-320q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h320q40 0 68 28t28 68zm-640-1024v192q0 40-28 68t-68 28h-320q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h320q40 0 68 28t28 68zm640 512v192q0 40-28 68t-68 28h-320q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h320q40 0 68 28t28 68zm0-512v192q0 40-28 68t-68 28h-320q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h320q40 0 68 28t28 68z\"/> </svg>" |
| 16155 |
|
| 16156 |
/***/ }), |
| 16157 |
|
| 16158 |
/***/ 43271: |
| 16159 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 16160 |
|
| 16161 |
"use strict"; |
| 16162 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 16163 |
/* harmony export */ ImageEditor: function() { return /* binding */ ImageEditor; }, |
| 16164 |
/* harmony export */ openImageEditor: function() { return /* binding */ openImageEditor; } |
| 16165 |
/* harmony export */ }); |
| 16166 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 16167 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 16168 |
/* harmony import */ var jodit_core_component__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(16964); |
| 16169 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(84839); |
| 16170 |
/* harmony import */ var jodit_core_dom__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(27795); |
| 16171 |
/* harmony import */ var jodit_core_helpers_array_to_array__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(88475); |
| 16172 |
/* harmony import */ var jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(4040); |
| 16173 |
/* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(7909); |
| 16174 |
/* harmony import */ var jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(80991); |
| 16175 |
/* harmony import */ var jodit_core_helpers_utils_selector__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(28723); |
| 16176 |
/* harmony import */ var jodit_core_helpers_utils_utils__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(71125); |
| 16177 |
/* harmony import */ var jodit_core_ui_button__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(59400); |
| 16178 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(5266); |
| 16179 |
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(54500); |
| 16180 |
/* harmony import */ var _templates_form__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(8908); |
| 16181 |
/*! |
| 16182 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 16183 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 16184 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 16185 |
*/ /** |
| 16186 |
* [[include:modules/image-editor/README.md]] |
| 16187 |
* @packageDocumentation |
| 16188 |
* @module modules/image-editor |
| 16189 |
*/ |
| 16190 |
|
| 16191 |
|
| 16192 |
|
| 16193 |
|
| 16194 |
|
| 16195 |
|
| 16196 |
|
| 16197 |
|
| 16198 |
|
| 16199 |
|
| 16200 |
|
| 16201 |
|
| 16202 |
|
| 16203 |
|
| 16204 |
|
| 16205 |
const jie = 'jodit-image-editor'; |
| 16206 |
const TABS = { |
| 16207 |
resize: 'resize', |
| 16208 |
crop: 'crop' |
| 16209 |
}; |
| 16210 |
class ImageEditor extends jodit_core_component__WEBPACK_IMPORTED_MODULE_2__.ViewComponent { |
| 16211 |
/** @override */ className() { |
| 16212 |
return 'ImageEditor'; |
| 16213 |
} |
| 16214 |
get o() { |
| 16215 |
return this.options; |
| 16216 |
} |
| 16217 |
/** |
| 16218 |
* Hide image editor |
| 16219 |
*/ hide() { |
| 16220 |
this._dialog.close(); |
| 16221 |
} |
| 16222 |
/** |
| 16223 |
* Open image editor |
| 16224 |
* @example |
| 16225 |
* ```javascript |
| 16226 |
* const jodit = Jodit.make('.editor', { |
| 16227 |
* imageeditor: { |
| 16228 |
* crop: false, |
| 16229 |
* closeAfterSave: true, |
| 16230 |
* width: 500 |
| 16231 |
* } |
| 16232 |
* }); |
| 16233 |
* jodit.imageeditor.open('https://xdsoft.net/jodit/images/test.png', function (name, data, success, failed) { |
| 16234 |
* var img = jodit.node.c('img'); |
| 16235 |
* img.setAttribute('src', 'https://xdsoft.net/jodit/images/test.png'); |
| 16236 |
* if (box.action !== 'resize') { |
| 16237 |
* return failed('Sorry it is work only in resize mode. For croping use FileBrowser'); |
| 16238 |
* } |
| 16239 |
* img.style.width = data.w; |
| 16240 |
* img.style.height = data.h; |
| 16241 |
* jodit.s.insertNode(img); |
| 16242 |
* success(); |
| 16243 |
* }); |
| 16244 |
* ``` |
| 16245 |
*/ open(url, save) { |
| 16246 |
return this.j.async.promise((resolve)=>{ |
| 16247 |
const timestamp = new Date().getTime(); |
| 16248 |
this.image = this.j.c.element('img'); |
| 16249 |
(0,jodit_core_helpers_utils_selector__WEBPACK_IMPORTED_MODULE_9__.$$)('img,.jodit-icon_loader', this.resize_box).forEach(jodit_core_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeRemove); |
| 16250 |
(0,jodit_core_helpers_utils_selector__WEBPACK_IMPORTED_MODULE_9__.$$)('img,.jodit-icon_loader', this.crop_box).forEach(jodit_core_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeRemove); |
| 16251 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_8__.css)(this.cropHandler, 'background', 'transparent'); |
| 16252 |
this.onSave = save; |
| 16253 |
this.resize_box.appendChild(this.j.c.element('i', { |
| 16254 |
class: 'jodit-icon_loader' |
| 16255 |
})); |
| 16256 |
this.crop_box.appendChild(this.j.c.element('i', { |
| 16257 |
class: 'jodit-icon_loader' |
| 16258 |
})); |
| 16259 |
if (/\?/.test(url)) { |
| 16260 |
url += '&_tst=' + timestamp; |
| 16261 |
} else { |
| 16262 |
url += '?_tst=' + timestamp; |
| 16263 |
} |
| 16264 |
this.image.setAttribute('src', url); |
| 16265 |
this._dialog.open(); |
| 16266 |
const { widthInput, heightInput } = (0,jodit_core_helpers_utils_selector__WEBPACK_IMPORTED_MODULE_9__.refs)(this.editor); |
| 16267 |
const onload = ()=>{ |
| 16268 |
if (this.isDestructed) { |
| 16269 |
return; |
| 16270 |
} |
| 16271 |
this.image.removeEventListener('load', onload); |
| 16272 |
this.naturalWidth = this.image.naturalWidth; |
| 16273 |
this.naturalHeight = this.image.naturalHeight; |
| 16274 |
widthInput.value = this.naturalWidth.toString(); |
| 16275 |
heightInput.value = this.naturalHeight.toString(); |
| 16276 |
this.ratio = this.naturalWidth / this.naturalHeight; |
| 16277 |
this.resize_box.appendChild(this.image); |
| 16278 |
this.cropImage = this.image.cloneNode(true); |
| 16279 |
this.crop_box.appendChild(this.cropImage); |
| 16280 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeRemove.apply(null, (0,jodit_core_helpers_utils_selector__WEBPACK_IMPORTED_MODULE_9__.$$)('.jodit-icon_loader', this.editor)); |
| 16281 |
if (this.activeTab === TABS.crop) { |
| 16282 |
this.showCrop(); |
| 16283 |
} |
| 16284 |
this.j.e.fire(this.resizeHandler, 'updatesize'); |
| 16285 |
this.j.e.fire(this.cropHandler, 'updatesize'); |
| 16286 |
this._dialog.setPosition(); |
| 16287 |
this.j.e.fire('afterImageEditor'); |
| 16288 |
resolve(this._dialog); |
| 16289 |
}; |
| 16290 |
this.image.addEventListener('load', onload); |
| 16291 |
if (this.image.complete) { |
| 16292 |
onload(); |
| 16293 |
} |
| 16294 |
}); |
| 16295 |
} |
| 16296 |
onTitleModeClick(e) { |
| 16297 |
const self = this, title = e.target; |
| 16298 |
const slide = title === null || title === void 0 ? void 0 : title.parentElement; |
| 16299 |
if (!slide) { |
| 16300 |
return; |
| 16301 |
} |
| 16302 |
(0,jodit_core_helpers_utils_selector__WEBPACK_IMPORTED_MODULE_9__.$$)(`.${jie}__slider,.${jie}__area`, self.editor).forEach((elm)=>elm.classList.remove(`${jie}_active`)); |
| 16303 |
slide.classList.add(`${jie}_active`); |
| 16304 |
this.activeTab = (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_7__.attr)(slide, '-area') || TABS.resize; |
| 16305 |
const tab = self.editor.querySelector(`.${jie}__area.${jie}__area_` + self.activeTab); |
| 16306 |
if (tab) { |
| 16307 |
tab.classList.add(`${jie}_active`); |
| 16308 |
} |
| 16309 |
if (self.activeTab === TABS.crop) { |
| 16310 |
self.showCrop(); |
| 16311 |
} |
| 16312 |
} |
| 16313 |
onChangeSizeInput(e) { |
| 16314 |
const self = this, input = e.target, { widthInput, heightInput } = (0,jodit_core_helpers_utils_selector__WEBPACK_IMPORTED_MODULE_9__.refs)(this.editor), isWidth = (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_7__.attr)(input, 'data-ref') === 'widthInput', x = parseInt(input.value, 10), minX = isWidth ? self.o.min_width : self.o.min_height, minY = !isWidth ? self.o.min_width : self.o.min_height; |
| 16315 |
let y; |
| 16316 |
if (x > minX) { |
| 16317 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_8__.css)(self.image, isWidth ? 'width' : 'height', x); |
| 16318 |
if (self.resizeUseRatio) { |
| 16319 |
y = isWidth ? Math.round(x / self.ratio) : Math.round(x * self.ratio); |
| 16320 |
if (y > minY) { |
| 16321 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_8__.css)(self.image, !isWidth ? 'width' : 'height', y); |
| 16322 |
if (isWidth) { |
| 16323 |
heightInput.value = y.toString(); |
| 16324 |
} else { |
| 16325 |
widthInput.value = y.toString(); |
| 16326 |
} |
| 16327 |
} |
| 16328 |
} |
| 16329 |
} |
| 16330 |
this.j.e.fire(self.resizeHandler, 'updatesize'); |
| 16331 |
} |
| 16332 |
onResizeHandleMouseDown(e) { |
| 16333 |
const self = this; |
| 16334 |
self.target = e.target; |
| 16335 |
e.preventDefault(); |
| 16336 |
e.stopImmediatePropagation(); |
| 16337 |
self.clicked = true; |
| 16338 |
self.start_x = e.clientX; |
| 16339 |
self.start_y = e.clientY; |
| 16340 |
if (self.activeTab === TABS.crop) { |
| 16341 |
self.top_x = (0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_8__.css)(self.cropHandler, 'left'); |
| 16342 |
self.top_y = (0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_8__.css)(self.cropHandler, 'top'); |
| 16343 |
self.width = self.cropHandler.offsetWidth; |
| 16344 |
self.height = self.cropHandler.offsetHeight; |
| 16345 |
} else { |
| 16346 |
self.width = self.image.offsetWidth; |
| 16347 |
self.height = self.image.offsetHeight; |
| 16348 |
} |
| 16349 |
self.j.e.on(this.j.ow, 'mousemove', this.onGlobalMouseMove).one(this.j.ow, 'mouseup', this.onGlobalMouseUp); |
| 16350 |
} |
| 16351 |
onGlobalMouseUp(e) { |
| 16352 |
if (this.clicked) { |
| 16353 |
this.clicked = false; |
| 16354 |
e.stopImmediatePropagation(); |
| 16355 |
this.j.e.off(this.j.ow, 'mousemove', this.onGlobalMouseMove); |
| 16356 |
} |
| 16357 |
} |
| 16358 |
onGlobalMouseMove(e) { |
| 16359 |
const self = this; |
| 16360 |
if (!self.clicked) { |
| 16361 |
return; |
| 16362 |
} |
| 16363 |
const { widthInput, heightInput } = (0,jodit_core_helpers_utils_selector__WEBPACK_IMPORTED_MODULE_9__.refs)(this.editor); |
| 16364 |
self.diff_x = e.clientX - self.start_x; |
| 16365 |
self.diff_y = e.clientY - self.start_y; |
| 16366 |
if (self.activeTab === TABS.resize && self.resizeUseRatio || self.activeTab === TABS.crop && self.cropUseRatio) { |
| 16367 |
if (self.diff_x) { |
| 16368 |
self.new_w = self.width + self.diff_x; |
| 16369 |
self.new_h = Math.round(self.new_w / self.ratio); |
| 16370 |
} else { |
| 16371 |
self.new_h = self.height + self.diff_y; |
| 16372 |
self.new_w = Math.round(self.new_h * self.ratio); |
| 16373 |
} |
| 16374 |
} else { |
| 16375 |
self.new_w = self.width + self.diff_x; |
| 16376 |
self.new_h = self.height + self.diff_y; |
| 16377 |
} |
| 16378 |
if (self.activeTab === TABS.resize) { |
| 16379 |
if (self.new_w > self.o.resizeMinWidth) { |
| 16380 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_8__.css)(self.image, 'width', self.new_w + 'px'); |
| 16381 |
widthInput.value = self.new_w.toString(); |
| 16382 |
} |
| 16383 |
if (self.new_h > self.o.resizeMinHeight) { |
| 16384 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_8__.css)(self.image, 'height', self.new_h + 'px'); |
| 16385 |
heightInput.value = self.new_h.toString(); |
| 16386 |
} |
| 16387 |
this.j.e.fire(self.resizeHandler, 'updatesize'); |
| 16388 |
} else { |
| 16389 |
if (self.target !== self.cropHandler) { |
| 16390 |
if (self.top_x + self.new_w > self.cropImage.offsetWidth) { |
| 16391 |
self.new_w = self.cropImage.offsetWidth - self.top_x; |
| 16392 |
} |
| 16393 |
if (self.top_y + self.new_h > self.cropImage.offsetHeight) { |
| 16394 |
self.new_h = self.cropImage.offsetHeight - self.top_y; |
| 16395 |
} |
| 16396 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_8__.css)(self.cropHandler, { |
| 16397 |
width: self.new_w, |
| 16398 |
height: self.new_h |
| 16399 |
}); |
| 16400 |
} else { |
| 16401 |
if (self.top_x + self.diff_x + self.cropHandler.offsetWidth > self.cropImage.offsetWidth) { |
| 16402 |
self.diff_x = self.cropImage.offsetWidth - self.top_x - self.cropHandler.offsetWidth; |
| 16403 |
} |
| 16404 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_8__.css)(self.cropHandler, 'left', self.top_x + self.diff_x); |
| 16405 |
if (self.top_y + self.diff_y + self.cropHandler.offsetHeight > self.cropImage.offsetHeight) { |
| 16406 |
self.diff_y = self.cropImage.offsetHeight - self.top_y - self.cropHandler.offsetHeight; |
| 16407 |
} |
| 16408 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_8__.css)(self.cropHandler, 'top', self.top_y + self.diff_y); |
| 16409 |
} |
| 16410 |
this.j.e.fire(self.cropHandler, 'updatesize'); |
| 16411 |
} |
| 16412 |
} |
| 16413 |
/** @override */ destruct() { |
| 16414 |
if (this.isDestructed) { |
| 16415 |
return; |
| 16416 |
} |
| 16417 |
if (this._dialog && !this._dialog.isInDestruct) { |
| 16418 |
this._dialog.destruct(); |
| 16419 |
} |
| 16420 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeRemove(this.editor); |
| 16421 |
if (this.j.e) { |
| 16422 |
this.j.e.off(this.j.ow, 'mousemove', this.onGlobalMouseMove).off(this.j.ow, 'mouseup', this.onGlobalMouseUp).off(this.ow, `.${jie}`).off(`.${jie}`); |
| 16423 |
} |
| 16424 |
super.destruct(); |
| 16425 |
} |
| 16426 |
constructor(editor){ |
| 16427 |
super(editor), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "options", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "onSave", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "resizeUseRatio", true), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "cropUseRatio", true), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "_dialog", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "image", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "cropImage", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "clicked", false), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "target", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "start_x", 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "start_y", 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "top_x", 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "top_y", 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "width", 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "height", 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "activeTab", TABS.resize), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "naturalWidth", 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "naturalHeight", 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "ratio", 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "new_h", 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "new_w", 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "diff_x", 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "diff_y", 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "buttons", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "editor", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "resize_box", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "crop_box", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "sizes", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "resizeHandler", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "cropHandler", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "cropBox", { |
| 16428 |
x: 0, |
| 16429 |
y: 0, |
| 16430 |
w: 0, |
| 16431 |
h: 0 |
| 16432 |
}), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "resizeBox", { |
| 16433 |
w: 0, |
| 16434 |
h: 0 |
| 16435 |
}), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "calcCropBox", ()=>{ |
| 16436 |
const node = this.crop_box.parentNode, w = node.offsetWidth * 0.8, h = node.offsetHeight * 0.8; |
| 16437 |
let wn = w, hn = h; |
| 16438 |
const { naturalWidth: nw, naturalHeight: nh } = this; |
| 16439 |
if (w > nw && h > nh) { |
| 16440 |
wn = nw; |
| 16441 |
hn = nh; |
| 16442 |
} else if (this.ratio > w / h) { |
| 16443 |
wn = w; |
| 16444 |
hn = nh * (w / nw); |
| 16445 |
} else { |
| 16446 |
wn = nw * (h / nh); |
| 16447 |
hn = h; |
| 16448 |
} |
| 16449 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_8__.css)(this.crop_box, { |
| 16450 |
width: wn, |
| 16451 |
height: hn |
| 16452 |
}); |
| 16453 |
}), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "showCrop", ()=>{ |
| 16454 |
if (!this.cropImage) { |
| 16455 |
return; |
| 16456 |
} |
| 16457 |
this.calcCropBox(); |
| 16458 |
const w = this.cropImage.offsetWidth || this.image.offsetWidth || this.image.naturalWidth; |
| 16459 |
this.new_w = ImageEditor.calcValueByPercent(w, this.o.cropDefaultWidth); |
| 16460 |
const h = this.cropImage.offsetHeight || this.image.offsetHeight || this.image.naturalHeight; |
| 16461 |
if (this.cropUseRatio) { |
| 16462 |
this.new_h = this.new_w / this.ratio; |
| 16463 |
} else { |
| 16464 |
this.new_h = ImageEditor.calcValueByPercent(h, this.o.cropDefaultHeight); |
| 16465 |
} |
| 16466 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_8__.css)(this.cropHandler, { |
| 16467 |
backgroundImage: 'url(' + (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_7__.attr)(this.cropImage, 'src') + ')', |
| 16468 |
width: this.new_w, |
| 16469 |
height: this.new_h, |
| 16470 |
left: w / 2 - this.new_w / 2, |
| 16471 |
top: h / 2 - this.new_h / 2 |
| 16472 |
}); |
| 16473 |
this.j.e.fire(this.cropHandler, 'updatesize'); |
| 16474 |
}), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "updateCropBox", ()=>{ |
| 16475 |
if (!this.cropImage) { |
| 16476 |
return; |
| 16477 |
} |
| 16478 |
const ratioX = this.cropImage.offsetWidth / this.naturalWidth, ratioY = this.cropImage.offsetHeight / this.naturalHeight; |
| 16479 |
this.cropBox.x = (0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_8__.css)(this.cropHandler, 'left') / ratioX; |
| 16480 |
this.cropBox.y = (0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_8__.css)(this.cropHandler, 'top') / ratioY; |
| 16481 |
this.cropBox.w = this.cropHandler.offsetWidth / ratioX; |
| 16482 |
this.cropBox.h = this.cropHandler.offsetHeight / ratioY; |
| 16483 |
this.sizes.textContent = this.cropBox.w.toFixed(0) + 'x' + this.cropBox.h.toFixed(0); |
| 16484 |
}), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "updateResizeBox", ()=>{ |
| 16485 |
this.resizeBox.w = this.image.offsetWidth || this.naturalWidth; |
| 16486 |
this.resizeBox.h = this.image.offsetHeight || this.naturalHeight; |
| 16487 |
}), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "setHandlers", ()=>{ |
| 16488 |
const self = this; |
| 16489 |
const { widthInput, heightInput } = (0,jodit_core_helpers_utils_selector__WEBPACK_IMPORTED_MODULE_9__.refs)(this.editor); |
| 16490 |
self.j.e.on([ |
| 16491 |
self.editor.querySelector('.jodit_bottomright'), |
| 16492 |
self.cropHandler |
| 16493 |
], `mousedown.${jie}`, this.onResizeHandleMouseDown).on(this.j.ow, `resize.${jie}`, ()=>{ |
| 16494 |
this.j.e.fire(self.resizeHandler, 'updatesize'); |
| 16495 |
self.showCrop(); |
| 16496 |
this.j.e.fire(self.cropHandler, 'updatesize'); |
| 16497 |
}); |
| 16498 |
self.j.e.on((0,jodit_core_helpers_array_to_array__WEBPACK_IMPORTED_MODULE_5__.toArray)(this.editor.querySelectorAll(`.${jie}__slider-title`)), 'click', this.onTitleModeClick).on([ |
| 16499 |
widthInput, |
| 16500 |
heightInput |
| 16501 |
], 'input', this.onChangeSizeInput); |
| 16502 |
const { keepAspectRatioResize, keepAspectRatioCrop } = (0,jodit_core_helpers_utils_selector__WEBPACK_IMPORTED_MODULE_9__.refs)(this.editor); |
| 16503 |
if (keepAspectRatioResize) { |
| 16504 |
keepAspectRatioResize.addEventListener('change', ()=>{ |
| 16505 |
this.resizeUseRatio = keepAspectRatioResize.checked; |
| 16506 |
}); |
| 16507 |
} |
| 16508 |
if (keepAspectRatioCrop) { |
| 16509 |
keepAspectRatioCrop.addEventListener('change', ()=>{ |
| 16510 |
this.cropUseRatio = keepAspectRatioCrop.checked; |
| 16511 |
}); |
| 16512 |
} |
| 16513 |
self.j.e.on(self.resizeHandler, 'updatesize', ()=>{ |
| 16514 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_8__.css)(self.resizeHandler, { |
| 16515 |
top: 0, |
| 16516 |
left: 0, |
| 16517 |
width: self.image.offsetWidth || self.naturalWidth, |
| 16518 |
height: self.image.offsetHeight || self.naturalHeight |
| 16519 |
}); |
| 16520 |
this.updateResizeBox(); |
| 16521 |
}).on(self.cropHandler, 'updatesize', ()=>{ |
| 16522 |
if (!self.cropImage) { |
| 16523 |
return; |
| 16524 |
} |
| 16525 |
let new_x = (0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_8__.css)(self.cropHandler, 'left'), new_y = (0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_8__.css)(self.cropHandler, 'top'), new_width = self.cropHandler.offsetWidth, new_height = self.cropHandler.offsetHeight; |
| 16526 |
if (new_x < 0) { |
| 16527 |
new_x = 0; |
| 16528 |
} |
| 16529 |
if (new_y < 0) { |
| 16530 |
new_y = 0; |
| 16531 |
} |
| 16532 |
if (new_x + new_width > self.cropImage.offsetWidth) { |
| 16533 |
new_width = self.cropImage.offsetWidth - new_x; |
| 16534 |
if (self.cropUseRatio) { |
| 16535 |
new_height = new_width / self.ratio; |
| 16536 |
} |
| 16537 |
} |
| 16538 |
if (new_y + new_height > self.cropImage.offsetHeight) { |
| 16539 |
new_height = self.cropImage.offsetHeight - new_y; |
| 16540 |
if (self.cropUseRatio) { |
| 16541 |
new_width = new_height * self.ratio; |
| 16542 |
} |
| 16543 |
} |
| 16544 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_8__.css)(self.cropHandler, { |
| 16545 |
width: new_width, |
| 16546 |
height: new_height, |
| 16547 |
left: new_x, |
| 16548 |
top: new_y, |
| 16549 |
backgroundPosition: -new_x - 1 + 'px ' + (-new_y - 1) + 'px', |
| 16550 |
backgroundSize: self.cropImage.offsetWidth + 'px ' + self.cropImage.offsetHeight + 'px' |
| 16551 |
}); |
| 16552 |
self.updateCropBox(); |
| 16553 |
}); |
| 16554 |
Object.values(self.buttons).forEach((button)=>{ |
| 16555 |
button.onAction(()=>{ |
| 16556 |
const data = { |
| 16557 |
action: self.activeTab, |
| 16558 |
box: self.activeTab === TABS.resize ? self.resizeBox : self.cropBox |
| 16559 |
}; |
| 16560 |
switch(button){ |
| 16561 |
case self.buttons.saveas: |
| 16562 |
self.j.prompt('Enter new name', 'Save in new file', (name)=>{ |
| 16563 |
if (!(0,jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_6__.trim)(name)) { |
| 16564 |
self.j.alert('The name should not be empty'); |
| 16565 |
return false; |
| 16566 |
} |
| 16567 |
self.onSave(name, data, self.hide, (e)=>{ |
| 16568 |
self.j.alert(e.message); |
| 16569 |
}); |
| 16570 |
}); |
| 16571 |
break; |
| 16572 |
case self.buttons.save: |
| 16573 |
self.onSave(undefined, data, self.hide, (e)=>{ |
| 16574 |
self.j.alert(e.message); |
| 16575 |
}); |
| 16576 |
break; |
| 16577 |
case self.buttons.reset: |
| 16578 |
if (self.activeTab === TABS.resize) { |
| 16579 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_8__.css)(self.image, { |
| 16580 |
width: null, |
| 16581 |
height: null |
| 16582 |
}); |
| 16583 |
widthInput.value = self.naturalWidth.toString(); |
| 16584 |
heightInput.value = self.naturalHeight.toString(); |
| 16585 |
self.j.e.fire(self.resizeHandler, 'updatesize'); |
| 16586 |
} else { |
| 16587 |
self.showCrop(); |
| 16588 |
} |
| 16589 |
break; |
| 16590 |
} |
| 16591 |
}); |
| 16592 |
}); |
| 16593 |
}); |
| 16594 |
this.options = editor && editor.o && editor.o.imageeditor ? editor.o.imageeditor : jodit_config__WEBPACK_IMPORTED_MODULE_12__.Config.defaultOptions.imageeditor; |
| 16595 |
const o = this.options; |
| 16596 |
this.resizeUseRatio = o.resizeUseRatio; |
| 16597 |
this.cropUseRatio = o.cropUseRatio; |
| 16598 |
this.buttons = { |
| 16599 |
reset: (0,jodit_core_ui_button__WEBPACK_IMPORTED_MODULE_11__.Button)(this.j, 'update', 'Reset'), |
| 16600 |
save: (0,jodit_core_ui_button__WEBPACK_IMPORTED_MODULE_11__.Button)(this.j, 'save', 'Save'), |
| 16601 |
saveas: (0,jodit_core_ui_button__WEBPACK_IMPORTED_MODULE_11__.Button)(this.j, { |
| 16602 |
icon: { |
| 16603 |
name: 'save' |
| 16604 |
}, |
| 16605 |
name: 'save-as', |
| 16606 |
text: 'Save as ...' |
| 16607 |
}) |
| 16608 |
}; |
| 16609 |
this.activeTab = o.resize ? TABS.resize : TABS.crop; |
| 16610 |
this.editor = (0,_templates_form__WEBPACK_IMPORTED_MODULE_14__.form)(this.j, this.options); |
| 16611 |
const { resizeBox, cropBox } = (0,jodit_core_helpers_utils_selector__WEBPACK_IMPORTED_MODULE_9__.refs)(this.editor); |
| 16612 |
this.resize_box = resizeBox; |
| 16613 |
this.crop_box = cropBox; |
| 16614 |
this.sizes = this.editor.querySelector(`.${jie}__area.${jie}__area_crop .jodit-image-editor__sizes`); |
| 16615 |
this.resizeHandler = this.editor.querySelector(`.${jie}__resizer`); |
| 16616 |
this.cropHandler = this.editor.querySelector(`.${jie}__croper`); |
| 16617 |
this._dialog = this.j.dlg({ |
| 16618 |
buttons: [ |
| 16619 |
'fullsize', |
| 16620 |
'dialog.close' |
| 16621 |
] |
| 16622 |
}); |
| 16623 |
this._dialog.setContent(this.editor); |
| 16624 |
this._dialog.setSize(this.o.width, this.o.height); |
| 16625 |
this._dialog.setHeader([ |
| 16626 |
this.buttons.reset, |
| 16627 |
this.buttons.save, |
| 16628 |
this.buttons.saveas |
| 16629 |
]); |
| 16630 |
this.setHandlers(); |
| 16631 |
} |
| 16632 |
} |
| 16633 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(ImageEditor, "calcValueByPercent", (value, percent)=>{ |
| 16634 |
const percentStr = percent.toString(); |
| 16635 |
const valueNbr = parseFloat(value.toString()); |
| 16636 |
let match; |
| 16637 |
match = /^[-+]?[0-9]+(px)?$/.exec(percentStr); |
| 16638 |
if (match) { |
| 16639 |
return parseInt(percentStr, 10); |
| 16640 |
} |
| 16641 |
match = /^([-+]?[0-9.]+)%$/.exec(percentStr); |
| 16642 |
if (match) { |
| 16643 |
return Math.round(valueNbr * (parseFloat(match[1]) / 100)); |
| 16644 |
} |
| 16645 |
return valueNbr || 0; |
| 16646 |
}); |
| 16647 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 16648 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 16649 |
], ImageEditor.prototype, "hide", null); |
| 16650 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 16651 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 16652 |
], ImageEditor.prototype, "open", null); |
| 16653 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 16654 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 16655 |
], ImageEditor.prototype, "onTitleModeClick", null); |
| 16656 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 16657 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.debounce)(), |
| 16658 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 16659 |
], ImageEditor.prototype, "onChangeSizeInput", null); |
| 16660 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 16661 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 16662 |
], ImageEditor.prototype, "onResizeHandleMouseDown", null); |
| 16663 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 16664 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 16665 |
], ImageEditor.prototype, "onGlobalMouseUp", null); |
| 16666 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 16667 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.throttle)(10) |
| 16668 |
], ImageEditor.prototype, "onGlobalMouseMove", null); |
| 16669 |
ImageEditor = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 16670 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.component |
| 16671 |
], ImageEditor); |
| 16672 |
/** |
| 16673 |
* Open Image Editor |
| 16674 |
*/ function openImageEditor(href, name, path, source, onSuccess, onFailed) { |
| 16675 |
return this.getInstance('ImageEditor', this.o).open(href, (newname, box, success, failed)=>(0,jodit_core_helpers_utils_utils__WEBPACK_IMPORTED_MODULE_10__.call)(box.action === 'resize' ? this.dataProvider.resize : this.dataProvider.crop, path, source, name, newname, box.box).then((ok)=>{ |
| 16676 |
if (ok) { |
| 16677 |
success(); |
| 16678 |
if (onSuccess) { |
| 16679 |
onSuccess(); |
| 16680 |
} |
| 16681 |
} |
| 16682 |
}).catch((error)=>{ |
| 16683 |
failed(error); |
| 16684 |
if (onFailed) { |
| 16685 |
onFailed(error); |
| 16686 |
} |
| 16687 |
})); |
| 16688 |
} |
| 16689 |
|
| 16690 |
|
| 16691 |
/***/ }), |
| 16692 |
|
| 16693 |
/***/ 43379: |
| 16694 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 16695 |
|
| 16696 |
"use strict"; |
| 16697 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 16698 |
/* harmony export */ reset: function() { return /* binding */ reset; } |
| 16699 |
/* harmony export */ }); |
| 16700 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 16701 |
/* harmony import */ var jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(91565); |
| 16702 |
/* harmony import */ var _get__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(89308); |
| 16703 |
/*! |
| 16704 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 16705 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 16706 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 16707 |
*/ /** |
| 16708 |
* @module helpers/utils |
| 16709 |
*/ |
| 16710 |
|
| 16711 |
|
| 16712 |
const map = {}; |
| 16713 |
/** |
| 16714 |
* Reset Vanilla JS native function |
| 16715 |
* @example |
| 16716 |
* ```js |
| 16717 |
* reset('Array.from')(Set([1,2,3])) // [1, 2, 3] |
| 16718 |
* ``` |
| 16719 |
* You must use the function derived from the method immediately as its iframe is being removed |
| 16720 |
*/ function reset(key) { |
| 16721 |
var _map_key; |
| 16722 |
if (!(key in map)) { |
| 16723 |
const iframe = jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.globalDocument.createElement('iframe'); |
| 16724 |
try { |
| 16725 |
iframe.src = 'about:blank'; |
| 16726 |
jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.globalDocument.body.appendChild(iframe); |
| 16727 |
if (!iframe.contentWindow) { |
| 16728 |
return null; |
| 16729 |
} |
| 16730 |
const func = (0,_get__WEBPACK_IMPORTED_MODULE_2__.get)(key, iframe.contentWindow), bind = (0,_get__WEBPACK_IMPORTED_MODULE_2__.get)(key.split('.').slice(0, -1).join('.'), iframe.contentWindow); |
| 16731 |
if ((0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_1__.isFunction)(func)) { |
| 16732 |
map[key] = func.bind(bind); |
| 16733 |
} |
| 16734 |
} catch (e) { |
| 16735 |
if (!jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.IS_PROD) { |
| 16736 |
throw e; |
| 16737 |
} |
| 16738 |
} finally{ |
| 16739 |
var _iframe_parentNode; |
| 16740 |
(_iframe_parentNode = iframe.parentNode) === null || _iframe_parentNode === void 0 ? void 0 : _iframe_parentNode.removeChild(iframe); |
| 16741 |
} |
| 16742 |
} |
| 16743 |
return (_map_key = map[key]) !== null && _map_key !== void 0 ? _map_key : null; |
| 16744 |
} |
| 16745 |
|
| 16746 |
|
| 16747 |
/***/ }), |
| 16748 |
|
| 16749 |
/***/ 44636: |
| 16750 |
/***/ (function(module) { |
| 16751 |
|
| 16752 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"><path d=\"M491 1536l91-91-235-235-91 91v107h128v128h107zm523-928q0-22-22-22-10 0-17 7l-542 542q-7 7-7 17 0 22 22 22 10 0 17-7l542-542q7-7 7-17zm-54-192l416 416-832 832h-416v-416zm683 96q0 53-37 90l-166 166-416-416 166-165q36-38 90-38 53 0 91 38l235 234q37 39 37 91z\"/></svg>" |
| 16753 |
|
| 16754 |
/***/ }), |
| 16755 |
|
| 16756 |
/***/ 44906: |
| 16757 |
/***/ (function(module) { |
| 16758 |
|
| 16759 |
module.exports["default"] = ["輸入一些內容","關於Jodit","Jodit Editor","開發者指南","使用幫助","相關授權條款資訊,請造訪我們的網站:","購買完整版本","Copyright © XDSoft.net - Chupurnov Valeriy. All rights reserved.","錨點","在新分頁開啟","全螢幕編輯","清除樣式","顏色","取消復原","復原","粗體","斜體","項目符號清單","編號清單","置中","文字對齊","靠左","靠右","分割線","圖片","檔案","插入 youtube/vimeo 影片","插入連結","文字大小","字型","格式化區塊","內文","標題1","標題2","標題3","標題4","引文","程式碼","插入","表格","減少縮排","增加縮排","選擇特殊符號","特殊符號","格式複製","檢視原始碼","邊距","上","右","下","左","樣式","Classes","對齊方式","靠右","置中","靠左","無","Src","Title","替代","Link","在新分頁開啟連結","圖片","檔案","進階","圖片屬性","取消","確定","檔案瀏覽","清單載入錯誤","資料夾載入錯誤","您確定嗎?","輸入路徑","創建路徑","type name","拖曳圖片至此","拖曳檔案至此","或點擊","替代文字","上傳","瀏覽","背景色","文字","頂部","中間","底部","插入左方欄","插入右方欄","插入上方列","插入下方列","刪除表格","刪除整列","刪除整欄","清除內容","字元數: %d","單字數: %d","刪除線","底線","上標","下標","剪下","全選","斷行","尋找","取代為","取代","貼上","選擇內容並貼上","原始碼","粗體","斜體","顏色","連結","復原","取消復原","表格","圖片","橡皮擦","段落","文字大小","影片","字型","關於","列印","底線","刪除線","增加縮排","減少縮排","全螢幕","縮減","分隔線","項目符號清單","編號清單","剪下","全選","嵌入程式碼","打開連結","編輯連結","No follow","取消連結","更新","鉛筆","查看","URL","編輯","水平對齊","篩選","修改時間排序","名稱排序","大小排序","新增資料夾","重設","儲存","另存為...","調整大小","裁切","寬","高","維持長寬比","是","否","移除","選擇","選擇: %s","垂直對齊","分割","合併","新增欄","新增列","許可證: %s","刪除","垂直分割","水平分割","邊框","您的程式碼與 HTML 類似,是否貼上 HTML 格式?","貼上 HTML","保留原始格式","以純文字貼上","僅貼上內文","您只能編輯您自己的圖片。是否下載此圖片?","圖片上傳成功","調色盤","沒有檔案","重新命名","輸入新名稱","預覽","下載","從剪貼簿貼上","瀏覽器無法存取剪貼簿。","複製已選取項目","複製","邊框圓角","顯示全部","應用","請輸入此欄位","請輸入網址","預設","圓圈","點","方形","尋找","尋找上一個","尋找下一個","正在貼上 Word/Excel 文件的內容,是否保留原始格式?","貼上 Word 格式","清除格式","插入 class 名稱","按住 Alt 以調整自訂大小",null,null,null,"全部"] |
| 16760 |
|
| 16761 |
/***/ }), |
| 16762 |
|
| 16763 |
/***/ 44998: |
| 16764 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 16765 |
|
| 16766 |
"use strict"; |
| 16767 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 16768 |
/* harmony export */ isLicense: function() { return /* binding */ isLicense; } |
| 16769 |
/* harmony export */ }); |
| 16770 |
/* harmony import */ var _is_string__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(85932); |
| 16771 |
/*! |
| 16772 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 16773 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 16774 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 16775 |
*/ /** |
| 16776 |
* @module helpers/checker |
| 16777 |
*/ |
| 16778 |
const isLicense = (license)=>(0,_is_string__WEBPACK_IMPORTED_MODULE_0__.isString)(license) && license.length === 23 && /^[a-z0-9]{5}-[a-z0-9]{5}-[a-z0-9]{5}-[a-z0-9]{5}$/i.test(license); |
| 16779 |
|
| 16780 |
|
| 16781 |
/***/ }), |
| 16782 |
|
| 16783 |
/***/ 45062: |
| 16784 |
/***/ (function(module) { |
| 16785 |
|
| 16786 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M1025 1369v167h-248l-159-252-24-42q-8-9-11-21h-3l-9 21q-10 20-25 44l-155 250h-258v-167h128l197-291-185-272h-137v-168h276l139 228q2 4 23 42 8 9 11 21h3q3-9 11-21l25-42 140-228h257v168h-125l-184 267 204 296h109zm639 217v206h-514l-4-27q-3-45-3-46 0-64 26-117t65-86.5 84-65 84-54.5 65-54 26-64q0-38-29.5-62.5t-70.5-24.5q-51 0-97 39-14 11-36 38l-105-92q26-37 63-66 80-65 188-65 110 0 178 59.5t68 158.5q0 66-34.5 118.5t-84 86-99.5 62.5-87 63-41 73h232v-80h126z\"/> </svg>" |
| 16787 |
|
| 16788 |
/***/ }), |
| 16789 |
|
| 16790 |
/***/ 45219: |
| 16791 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 16792 |
|
| 16793 |
"use strict"; |
| 16794 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 16795 |
/* harmony export */ visitNodeWalker: function() { return /* binding */ visitNodeWalker; } |
| 16796 |
/* harmony export */ }); |
| 16797 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 16798 |
/* harmony import */ var _filters__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(91560); |
| 16799 |
/*! |
| 16800 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 16801 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 16802 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 16803 |
*/ /** |
| 16804 |
* @module plugins/clean-html |
| 16805 |
*/ |
| 16806 |
|
| 16807 |
const keys = Object.keys(_filters__WEBPACK_IMPORTED_MODULE_1__); |
| 16808 |
/** |
| 16809 |
* @private |
| 16810 |
*/ function visitNodeWalker(jodit, nodeElm, allowTags, denyTags, currentSelectionNode) { |
| 16811 |
let hadEffect = false; |
| 16812 |
const dcf = jodit.o.cleanHTML.disableCleanFilter; |
| 16813 |
for (const key of keys){ |
| 16814 |
if (dcf && dcf.has(key)) { |
| 16815 |
continue; |
| 16816 |
} |
| 16817 |
const filter = _filters__WEBPACK_IMPORTED_MODULE_1__[key]; |
| 16818 |
const tmp = hadEffect; |
| 16819 |
hadEffect = filter(jodit, nodeElm, hadEffect, allowTags, denyTags, currentSelectionNode); |
| 16820 |
if (!jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.IS_PROD && !tmp && hadEffect) { |
| 16821 |
console.warn(`CleanHTML: Effect "${key}"`); |
| 16822 |
} |
| 16823 |
if (!nodeElm.isConnected) { |
| 16824 |
return true; |
| 16825 |
} |
| 16826 |
} |
| 16827 |
return hadEffect; |
| 16828 |
} |
| 16829 |
|
| 16830 |
|
| 16831 |
/***/ }), |
| 16832 |
|
| 16833 |
/***/ 45244: |
| 16834 |
/***/ (function(module) { |
| 16835 |
|
| 16836 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M1639 1056q0 5-1 7-64 268-268 434.5t-478 166.5q-146 0-282.5-55t-243.5-157l-129 129q-19 19-45 19t-45-19-19-45v-448q0-26 19-45t45-19h448q26 0 45 19t19 45-19 45l-137 137q71 66 161 102t187 36q134 0 250-65t186-179q11-17 53-117 8-23 30-23h192q13 0 22.5 9.5t9.5 22.5zm25-800v448q0 26-19 45t-45 19h-448q-26 0-45-19t-19-45 19-45l138-138q-148-137-349-137-134 0-250 65t-186 179q-11 17-53 117-8 23-30 23h-199q-13 0-22.5-9.5t-9.5-22.5v-7q65-268 270-434.5t480-166.5q146 0 284 55.5t245 156.5l130-129q19-19 45-19t45 19 19 45z\"/> </svg>" |
| 16837 |
|
| 16838 |
/***/ }), |
| 16839 |
|
| 16840 |
/***/ 45512: |
| 16841 |
/***/ (function(module) { |
| 16842 |
|
| 16843 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 10 10\"> <path d=\"M.941 4.523a.75.75 0 1 1 1.06-1.06l3.006 3.005 3.005-3.005a.75.75 0 1 1 1.06 1.06l-3.549 3.55a.75.75 0 0 1-1.168-.136L.941 4.523z\"/> </svg>" |
| 16844 |
|
| 16845 |
/***/ }), |
| 16846 |
|
| 16847 |
/***/ 45664: |
| 16848 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 16849 |
|
| 16850 |
"use strict"; |
| 16851 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 16852 |
/* harmony export */ asArray: function() { return /* reexport safe */ _as_array__WEBPACK_IMPORTED_MODULE_0__.asArray; }, |
| 16853 |
/* harmony export */ splitArray: function() { return /* reexport safe */ _split_array__WEBPACK_IMPORTED_MODULE_1__.splitArray; }, |
| 16854 |
/* harmony export */ toArray: function() { return /* reexport safe */ _to_array__WEBPACK_IMPORTED_MODULE_2__.toArray; } |
| 16855 |
/* harmony export */ }); |
| 16856 |
/* harmony import */ var _as_array__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(78982); |
| 16857 |
/* harmony import */ var _split_array__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(32328); |
| 16858 |
/* harmony import */ var _to_array__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(88475); |
| 16859 |
/*! |
| 16860 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 16861 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 16862 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 16863 |
*/ /** |
| 16864 |
* @module helpers/array |
| 16865 |
*/ |
| 16866 |
|
| 16867 |
|
| 16868 |
|
| 16869 |
|
| 16870 |
/***/ }), |
| 16871 |
|
| 16872 |
/***/ 45674: |
| 16873 |
/***/ (function(module) { |
| 16874 |
|
| 16875 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M896 1152q0-36-20-69-1-1-15.5-22.5t-25.5-38-25-44-21-50.5q-4-16-21-16t-21 16q-7 23-21 50.5t-25 44-25.5 38-15.5 22.5q-20 33-20 69 0 53 37.5 90.5t90.5 37.5 90.5-37.5 37.5-90.5zm512-128q0 212-150 362t-362 150-362-150-150-362q0-145 81-275 6-9 62.5-90.5t101-151 99.5-178 83-201.5q9-30 34-47t51-17 51.5 17 33.5 47q28 93 83 201.5t99.5 178 101 151 62.5 90.5q81 127 81 275z\"/> </svg>" |
| 16876 |
|
| 16877 |
/***/ }), |
| 16878 |
|
| 16879 |
/***/ 45778: |
| 16880 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 16881 |
|
| 16882 |
"use strict"; |
| 16883 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 16884 |
/* harmony export */ formTemplate: function() { return /* binding */ formTemplate; } |
| 16885 |
/* harmony export */ }); |
| 16886 |
/* harmony import */ var jodit_core_ui_button__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(59400); |
| 16887 |
/* harmony import */ var jodit_core_ui_form__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(5658); |
| 16888 |
/*! |
| 16889 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 16890 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 16891 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 16892 |
*/ /** |
| 16893 |
* @module plugins/link |
| 16894 |
*/ |
| 16895 |
|
| 16896 |
const formTemplate = (editor)=>{ |
| 16897 |
const { openInNewTabCheckbox, noFollowCheckbox, modeClassName, selectSizeClassName, selectMultipleClassName, selectOptionsClassName } = editor.o.link; |
| 16898 |
return new jodit_core_ui_form__WEBPACK_IMPORTED_MODULE_1__.UIForm(editor, [ |
| 16899 |
new jodit_core_ui_form__WEBPACK_IMPORTED_MODULE_1__.UIBlock(editor, [ |
| 16900 |
new jodit_core_ui_form__WEBPACK_IMPORTED_MODULE_1__.UIInput(editor, { |
| 16901 |
name: 'url', |
| 16902 |
type: 'text', |
| 16903 |
ref: 'url_input', |
| 16904 |
label: 'URL', |
| 16905 |
placeholder: 'http://', |
| 16906 |
required: true |
| 16907 |
}) |
| 16908 |
]), |
| 16909 |
new jodit_core_ui_form__WEBPACK_IMPORTED_MODULE_1__.UIBlock(editor, [ |
| 16910 |
new jodit_core_ui_form__WEBPACK_IMPORTED_MODULE_1__.UIInput(editor, { |
| 16911 |
name: 'content', |
| 16912 |
ref: 'content_input', |
| 16913 |
label: 'Text' |
| 16914 |
}) |
| 16915 |
], { |
| 16916 |
ref: 'content_input_box' |
| 16917 |
}), |
| 16918 |
modeClassName ? new jodit_core_ui_form__WEBPACK_IMPORTED_MODULE_1__.UIBlock(editor, [ |
| 16919 |
(()=>{ |
| 16920 |
if (modeClassName === 'input') { |
| 16921 |
return new jodit_core_ui_form__WEBPACK_IMPORTED_MODULE_1__.UIInput(editor, { |
| 16922 |
name: 'className', |
| 16923 |
ref: 'className_input', |
| 16924 |
label: 'Class name' |
| 16925 |
}); |
| 16926 |
} |
| 16927 |
if (modeClassName === 'select') { |
| 16928 |
return new jodit_core_ui_form__WEBPACK_IMPORTED_MODULE_1__.UISelect(editor, { |
| 16929 |
name: 'className', |
| 16930 |
ref: 'className_select', |
| 16931 |
label: 'Class name', |
| 16932 |
size: selectSizeClassName, |
| 16933 |
multiple: selectMultipleClassName, |
| 16934 |
options: selectOptionsClassName |
| 16935 |
}); |
| 16936 |
} |
| 16937 |
return null; |
| 16938 |
})() |
| 16939 |
]) : null, |
| 16940 |
openInNewTabCheckbox ? new jodit_core_ui_form__WEBPACK_IMPORTED_MODULE_1__.UICheckbox(editor, { |
| 16941 |
name: 'target', |
| 16942 |
ref: 'target_checkbox', |
| 16943 |
label: 'Open in new tab' |
| 16944 |
}) : null, |
| 16945 |
noFollowCheckbox ? new jodit_core_ui_form__WEBPACK_IMPORTED_MODULE_1__.UICheckbox(editor, { |
| 16946 |
name: 'nofollow', |
| 16947 |
ref: 'nofollow_checkbox', |
| 16948 |
label: 'No follow' |
| 16949 |
}) : null, |
| 16950 |
new jodit_core_ui_form__WEBPACK_IMPORTED_MODULE_1__.UIBlock(editor, [ |
| 16951 |
new jodit_core_ui_button__WEBPACK_IMPORTED_MODULE_0__.UIButton(editor, { |
| 16952 |
name: 'unlink', |
| 16953 |
variant: 'default', |
| 16954 |
text: 'Unlink' |
| 16955 |
}), |
| 16956 |
new jodit_core_ui_button__WEBPACK_IMPORTED_MODULE_0__.UIButton(editor, { |
| 16957 |
name: 'insert', |
| 16958 |
type: 'submit', |
| 16959 |
variant: 'primary', |
| 16960 |
text: 'Insert' |
| 16961 |
}) |
| 16962 |
], { |
| 16963 |
align: 'full' |
| 16964 |
}) |
| 16965 |
]); |
| 16966 |
}; |
| 16967 |
|
| 16968 |
|
| 16969 |
/***/ }), |
| 16970 |
|
| 16971 |
/***/ 45844: |
| 16972 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 16973 |
|
| 16974 |
"use strict"; |
| 16975 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 16976 |
/* harmony export */ TextAreaEditor: function() { return /* binding */ TextAreaEditor; } |
| 16977 |
/* harmony export */ }); |
| 16978 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 16979 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(23211); |
| 16980 |
/* harmony import */ var jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(80991); |
| 16981 |
/* harmony import */ var jodit_plugins_source_editor_sourceEditor__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(94193); |
| 16982 |
/*! |
| 16983 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 16984 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 16985 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 16986 |
*/ /** |
| 16987 |
* @module plugins/source |
| 16988 |
*/ |
| 16989 |
|
| 16990 |
|
| 16991 |
|
| 16992 |
class TextAreaEditor extends jodit_plugins_source_editor_sourceEditor__WEBPACK_IMPORTED_MODULE_3__.SourceEditor { |
| 16993 |
init(editor) { |
| 16994 |
this.instance = editor.c.element('textarea', { |
| 16995 |
class: 'jodit-source__mirror', |
| 16996 |
dir: editor.o.direction === 'rtl' ? 'rtl' : undefined |
| 16997 |
}); |
| 16998 |
this.container.appendChild(this.instance); |
| 16999 |
editor.e.on(this.instance, 'mousedown keydown touchstart input', editor.async.debounce(this.toWYSIWYG, editor.defaultTimeout)).on('setMinHeight.source', (minHeightD)=>{ |
| 17000 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_2__.css)(this.instance, 'minHeight', minHeightD); |
| 17001 |
}).on(this.instance, 'change keydown mousedown touchstart input', this.autosize).on('afterSetMode.source', this.autosize).on(this.instance, 'mousedown focus', (e)=>{ |
| 17002 |
editor.e.fire(e.type, e); |
| 17003 |
}); |
| 17004 |
this.autosize(); |
| 17005 |
this.onReady(); |
| 17006 |
} |
| 17007 |
destruct() { |
| 17008 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.safeRemove(this.instance); |
| 17009 |
} |
| 17010 |
getValue() { |
| 17011 |
return this.instance.value; |
| 17012 |
} |
| 17013 |
setValue(raw) { |
| 17014 |
this.instance.value = raw; |
| 17015 |
} |
| 17016 |
insertRaw(raw) { |
| 17017 |
const value = this.getValue(); |
| 17018 |
if (this.getSelectionStart() >= 0) { |
| 17019 |
const startPos = this.getSelectionStart(), endPos = this.getSelectionEnd(); |
| 17020 |
this.setValue(value.substring(0, startPos) + raw + value.substring(endPos, value.length)); |
| 17021 |
} else { |
| 17022 |
this.setValue(value + raw); |
| 17023 |
} |
| 17024 |
} |
| 17025 |
getSelectionStart() { |
| 17026 |
return this.instance.selectionStart; |
| 17027 |
} |
| 17028 |
getSelectionEnd() { |
| 17029 |
return this.instance.selectionEnd; |
| 17030 |
} |
| 17031 |
setSelectionRange(start, end = start) { |
| 17032 |
this.instance.setSelectionRange(start, end); |
| 17033 |
} |
| 17034 |
get isFocused() { |
| 17035 |
return this.instance === this.j.od.activeElement; |
| 17036 |
} |
| 17037 |
focus() { |
| 17038 |
this.instance.focus(); |
| 17039 |
} |
| 17040 |
blur() { |
| 17041 |
this.instance.blur(); |
| 17042 |
} |
| 17043 |
setPlaceHolder(title) { |
| 17044 |
this.instance.setAttribute('placeholder', title); |
| 17045 |
} |
| 17046 |
setReadOnly(isReadOnly) { |
| 17047 |
if (isReadOnly) { |
| 17048 |
this.instance.setAttribute('readonly', 'true'); |
| 17049 |
} else { |
| 17050 |
this.instance.removeAttribute('readonly'); |
| 17051 |
} |
| 17052 |
} |
| 17053 |
selectAll() { |
| 17054 |
this.instance.select(); |
| 17055 |
} |
| 17056 |
replaceUndoManager() { |
| 17057 |
const { history } = this.jodit; |
| 17058 |
this.j.e.on(this.instance, 'keydown', (e)=>{ |
| 17059 |
if ((e.ctrlKey || e.metaKey) && e.key === 'z') { |
| 17060 |
if (e.shiftKey) { |
| 17061 |
history.redo(); |
| 17062 |
} else { |
| 17063 |
history.undo(); |
| 17064 |
} |
| 17065 |
this.setSelectionRange(this.getValue().length); |
| 17066 |
return false; |
| 17067 |
} |
| 17068 |
}); |
| 17069 |
} |
| 17070 |
constructor(...args){ |
| 17071 |
super(...args), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "autosize", this.j.async.debounce(()=>{ |
| 17072 |
this.instance.style.height = 'auto'; |
| 17073 |
this.instance.style.height = this.instance.scrollHeight + 'px'; |
| 17074 |
}, this.j.defaultTimeout, true)); |
| 17075 |
} |
| 17076 |
} |
| 17077 |
|
| 17078 |
|
| 17079 |
/***/ }), |
| 17080 |
|
| 17081 |
/***/ 46248: |
| 17082 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 17083 |
|
| 17084 |
"use strict"; |
| 17085 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 17086 |
/* harmony export */ isHTML: function() { return /* binding */ isHTML; } |
| 17087 |
/* harmony export */ }); |
| 17088 |
/* harmony import */ var _is_string__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(85932); |
| 17089 |
/*! |
| 17090 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 17091 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 17092 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 17093 |
*/ /** |
| 17094 |
* @module helpers/checker |
| 17095 |
*/ |
| 17096 |
/** |
| 17097 |
* Check if a string is html or not |
| 17098 |
*/ const isHTML = (str)=>(0,_is_string__WEBPACK_IMPORTED_MODULE_0__.isString)(str) && /<([A-Za-z][A-Za-z0-9]*)\b[^>]*>(.*?)<\/\1>/m.test(str.replace(/[\r\n]/g, '')); |
| 17099 |
|
| 17100 |
|
| 17101 |
/***/ }), |
| 17102 |
|
| 17103 |
/***/ 46303: |
| 17104 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 17105 |
|
| 17106 |
"use strict"; |
| 17107 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 17108 |
/* harmony export */ splitFragment: function() { return /* binding */ splitFragment; } |
| 17109 |
/* harmony export */ }); |
| 17110 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 17111 |
/* harmony import */ var jodit_core_helpers_utils_scroll_into_view__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(60898); |
| 17112 |
/* harmony import */ var _insert_paragraph__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(65710); |
| 17113 |
/*! |
| 17114 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 17115 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 17116 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 17117 |
*/ /** |
| 17118 |
* @module plugins/enter |
| 17119 |
*/ |
| 17120 |
|
| 17121 |
|
| 17122 |
/** |
| 17123 |
* Splits a block element into two parts |
| 17124 |
* and adds a new default block in the middle/start/end |
| 17125 |
* @private |
| 17126 |
*/ function splitFragment(fake, jodit, block) { |
| 17127 |
const sel = jodit.s, { enter } = jodit.o; |
| 17128 |
const defaultTag = enter.toLowerCase(); |
| 17129 |
const isLi = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isLeaf(block); |
| 17130 |
const canSplit = block.tagName.toLowerCase() === defaultTag || isLi; |
| 17131 |
const cursorOnTheRight = sel.cursorOnTheRight(block, fake); |
| 17132 |
const cursorOnTheLeft = sel.cursorOnTheLeft(block, fake); |
| 17133 |
if (!canSplit && (cursorOnTheRight || cursorOnTheLeft)) { |
| 17134 |
if (cursorOnTheRight) { |
| 17135 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.after(block, fake); |
| 17136 |
} else { |
| 17137 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.before(block, fake); |
| 17138 |
} |
| 17139 |
(0,_insert_paragraph__WEBPACK_IMPORTED_MODULE_2__.insertParagraph)(fake, jodit, defaultTag); |
| 17140 |
if (cursorOnTheLeft && !cursorOnTheRight) { |
| 17141 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.prepend(block, fake); |
| 17142 |
} |
| 17143 |
return; |
| 17144 |
} |
| 17145 |
const newP = sel.splitSelection(block, fake); |
| 17146 |
(0,jodit_core_helpers_utils_scroll_into_view__WEBPACK_IMPORTED_MODULE_1__.scrollIntoViewIfNeeded)(newP, jodit.editor, jodit.ed); |
| 17147 |
} |
| 17148 |
|
| 17149 |
|
| 17150 |
/***/ }), |
| 17151 |
|
| 17152 |
/***/ 46363: |
| 17153 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 17154 |
|
| 17155 |
"use strict"; |
| 17156 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 17157 |
/* harmony export */ Snapshot: function() { return /* binding */ Snapshot; } |
| 17158 |
/* harmony export */ }); |
| 17159 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 17160 |
/* harmony import */ var jodit_core_component__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(16964); |
| 17161 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(81937); |
| 17162 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(23211); |
| 17163 |
/*! |
| 17164 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 17165 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 17166 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 17167 |
*/ /** |
| 17168 |
* @module modules/history |
| 17169 |
*/ |
| 17170 |
|
| 17171 |
|
| 17172 |
|
| 17173 |
/** |
| 17174 |
* Module for creating snapshot of editor which includes html content and the current selection |
| 17175 |
*/ class Snapshot extends jodit_core_component__WEBPACK_IMPORTED_MODULE_1__.ViewComponent { |
| 17176 |
/** @override */ className() { |
| 17177 |
return 'Snapshot'; |
| 17178 |
} |
| 17179 |
/** |
| 17180 |
* Compare two snapshotes, if and htmls and selections match, then return true |
| 17181 |
* |
| 17182 |
* @param first - the first snapshote |
| 17183 |
* @param second - second shot |
| 17184 |
*/ static equal(first, second) { |
| 17185 |
return first.html === second.html && JSON.stringify(first.range) === JSON.stringify(second.range); |
| 17186 |
} |
| 17187 |
/** |
| 17188 |
* Calc count element before some node in parentNode. All text nodes are joined |
| 17189 |
*/ static countNodesBeforeInParent(elm) { |
| 17190 |
if (!elm.parentNode) { |
| 17191 |
return 0; |
| 17192 |
} |
| 17193 |
const elms = elm.parentNode.childNodes; |
| 17194 |
let count = 0, previous = null; |
| 17195 |
for(let j = 0; j < elms.length; j += 1){ |
| 17196 |
if (previous && !this.isIgnoredNode(elms[j]) && !(jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.isText(previous) && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.isText(elms[j]))) { |
| 17197 |
count += 1; |
| 17198 |
} |
| 17199 |
if (elms[j] === elm) { |
| 17200 |
return count; |
| 17201 |
} |
| 17202 |
previous = elms[j]; |
| 17203 |
} |
| 17204 |
return 0; |
| 17205 |
} |
| 17206 |
/** |
| 17207 |
* Calc normal offset in joined text nodes |
| 17208 |
*/ static strokeOffset(elm, offset) { |
| 17209 |
while(jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.isText(elm)){ |
| 17210 |
elm = elm.previousSibling; |
| 17211 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.isText(elm) && elm.nodeValue) { |
| 17212 |
offset += elm.nodeValue.length; |
| 17213 |
} |
| 17214 |
} |
| 17215 |
return offset; |
| 17216 |
} |
| 17217 |
/** |
| 17218 |
* Calc whole hierarchy path before some element in editor's tree |
| 17219 |
*/ calcHierarchyLadder(elm) { |
| 17220 |
const counts = []; |
| 17221 |
if (!elm || !elm.parentNode || !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.isOrContains(this.j.editor, elm)) { |
| 17222 |
return []; |
| 17223 |
} |
| 17224 |
while(elm && elm !== this.j.editor){ |
| 17225 |
if (elm && !Snapshot.isIgnoredNode(elm)) { |
| 17226 |
counts.push(Snapshot.countNodesBeforeInParent(elm)); |
| 17227 |
} |
| 17228 |
elm = elm.parentNode; |
| 17229 |
} |
| 17230 |
return counts.reverse(); |
| 17231 |
} |
| 17232 |
getElementByLadder(ladder) { |
| 17233 |
let n = this.j.editor, i; |
| 17234 |
for(i = 0; n && i < ladder.length; i += 1){ |
| 17235 |
n = n.childNodes[ladder[i]]; |
| 17236 |
} |
| 17237 |
return n; |
| 17238 |
} |
| 17239 |
get isBlocked() { |
| 17240 |
return this.__isBlocked; |
| 17241 |
} |
| 17242 |
__block(enable) { |
| 17243 |
this.__isBlocked = enable; |
| 17244 |
} |
| 17245 |
transaction(changes) { |
| 17246 |
this.__block(true); |
| 17247 |
this.__levelOfTransaction += 1; |
| 17248 |
try { |
| 17249 |
changes(); |
| 17250 |
} catch (e) { |
| 17251 |
if (!jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.IS_PROD) { |
| 17252 |
throw e; |
| 17253 |
} |
| 17254 |
} finally{ |
| 17255 |
this.__levelOfTransaction -= 1; |
| 17256 |
if (this.__levelOfTransaction === 0) { |
| 17257 |
this.__block(false); |
| 17258 |
} |
| 17259 |
} |
| 17260 |
} |
| 17261 |
/** |
| 17262 |
* Creates object a snapshot of editor: html and the current selection. Current selection calculate by |
| 17263 |
* offset by start document |
| 17264 |
* \{html: string, range: \{startContainer: int, startOffset: int, endContainer: int, endOffset: int\}\} or |
| 17265 |
* \{html: string\} without selection |
| 17266 |
*/ make() { |
| 17267 |
const snapshot = { |
| 17268 |
html: '', |
| 17269 |
range: { |
| 17270 |
startContainer: [], |
| 17271 |
startOffset: 0, |
| 17272 |
endContainer: [], |
| 17273 |
endOffset: 0 |
| 17274 |
} |
| 17275 |
}; |
| 17276 |
snapshot.html = this.__getCleanedEditorValue(this.j.editor); |
| 17277 |
const sel = this.j.s.sel; |
| 17278 |
if (sel && sel.rangeCount) { |
| 17279 |
const range = sel.getRangeAt(0); |
| 17280 |
const startContainer = this.calcHierarchyLadder(range.startContainer); |
| 17281 |
const endContainer = this.calcHierarchyLadder(range.endContainer); |
| 17282 |
let startOffset = Snapshot.strokeOffset(range.startContainer, range.startOffset), endOffset = Snapshot.strokeOffset(range.endContainer, range.endOffset); |
| 17283 |
if (!startContainer.length && range.startContainer !== this.j.editor) { |
| 17284 |
startOffset = 0; |
| 17285 |
} |
| 17286 |
if (!endContainer.length && range.endContainer !== this.j.editor) { |
| 17287 |
endOffset = 0; |
| 17288 |
} |
| 17289 |
snapshot.range = { |
| 17290 |
startContainer, |
| 17291 |
startOffset, |
| 17292 |
endContainer, |
| 17293 |
endOffset |
| 17294 |
}; |
| 17295 |
} |
| 17296 |
return snapshot; |
| 17297 |
} |
| 17298 |
/** |
| 17299 |
* Restores the state of the editor of the snapshot. Rebounding is not only html but selected text |
| 17300 |
* |
| 17301 |
* @param snapshot - snapshot of editor resulting from the `[[Snapshot.make]]` method |
| 17302 |
* @see make |
| 17303 |
*/ restore(snapshot) { |
| 17304 |
this.transaction(()=>{ |
| 17305 |
const scroll = this.storeScrollState(); |
| 17306 |
const html = this.__getCleanedEditorValue(this.j.editor); |
| 17307 |
if (html !== snapshot.html) { |
| 17308 |
this.j.value = snapshot.html; |
| 17309 |
} |
| 17310 |
this.restoreOnlySelection(snapshot); |
| 17311 |
this.restoreScrollState(scroll); |
| 17312 |
}); |
| 17313 |
} |
| 17314 |
storeScrollState() { |
| 17315 |
return [ |
| 17316 |
this.j.ow.scrollY, |
| 17317 |
this.j.editor.scrollTop |
| 17318 |
]; |
| 17319 |
} |
| 17320 |
restoreScrollState(scrolls) { |
| 17321 |
const { j } = this, { ow } = j; |
| 17322 |
ow.scrollTo(ow.scrollX, scrolls[0]); |
| 17323 |
j.editor.scrollTop = scrolls[1]; |
| 17324 |
} |
| 17325 |
/** |
| 17326 |
* Restore selection from snapshot |
| 17327 |
* |
| 17328 |
* @param snapshot - snapshot of editor resulting from the [[Snapshot.make]] method |
| 17329 |
* @see make |
| 17330 |
*/ restoreOnlySelection(snapshot) { |
| 17331 |
try { |
| 17332 |
if (snapshot.range) { |
| 17333 |
const range = this.j.ed.createRange(); |
| 17334 |
range.setStart(this.getElementByLadder(snapshot.range.startContainer), snapshot.range.startOffset); |
| 17335 |
range.setEnd(this.getElementByLadder(snapshot.range.endContainer), snapshot.range.endOffset); |
| 17336 |
this.j.s.selectRange(range); |
| 17337 |
} |
| 17338 |
} catch (__ignore) { |
| 17339 |
this.j.editor.lastChild && this.j.s.setCursorAfter(this.j.editor.lastChild); |
| 17340 |
if (!jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.IS_PROD) { |
| 17341 |
// tslint:disable-next-line:no-console |
| 17342 |
console.warn('Broken snapshot', __ignore); |
| 17343 |
} |
| 17344 |
} |
| 17345 |
} |
| 17346 |
destruct() { |
| 17347 |
this.__block(false); |
| 17348 |
super.destruct(); |
| 17349 |
} |
| 17350 |
static isIgnoredNode(node) { |
| 17351 |
return jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.isText(node) && !node.nodeValue || jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.isTemporary(node); |
| 17352 |
} |
| 17353 |
__getCleanedEditorValue(node) { |
| 17354 |
const clone = node.cloneNode(true); |
| 17355 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.temporaryList(clone).forEach(jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.unwrap); |
| 17356 |
return clone.innerHTML; |
| 17357 |
} |
| 17358 |
constructor(...args){ |
| 17359 |
super(...args), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__isBlocked", false), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__levelOfTransaction", 0); |
| 17360 |
} |
| 17361 |
} |
| 17362 |
|
| 17363 |
|
| 17364 |
/***/ }), |
| 17365 |
|
| 17366 |
/***/ 46533: |
| 17367 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 17368 |
|
| 17369 |
"use strict"; |
| 17370 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 17371 |
/* harmony export */ sendFiles: function() { return /* binding */ sendFiles; } |
| 17372 |
/* harmony export */ }); |
| 17373 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(65946); |
| 17374 |
/* harmony import */ var jodit_modules_uploader_helpers_send__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(77911); |
| 17375 |
/*! |
| 17376 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 17377 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 17378 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 17379 |
*/ /** |
| 17380 |
* @module modules/uploader |
| 17381 |
*/ |
| 17382 |
|
| 17383 |
/** |
| 17384 |
* Send files to server |
| 17385 |
*/ function sendFiles(uploader, files, handlerSuccess, handlerError, process) { |
| 17386 |
if (!files) { |
| 17387 |
return Promise.reject((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_0__.error)('Need files')); |
| 17388 |
} |
| 17389 |
const { o } = uploader; |
| 17390 |
let fileList = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_0__.toArray)(files); |
| 17391 |
if (!fileList.length) { |
| 17392 |
return Promise.reject((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_0__.error)('Need files')); |
| 17393 |
} |
| 17394 |
const promises = []; |
| 17395 |
if (o.insertImageAsBase64URI) { |
| 17396 |
readImagesWithReader(fileList, o.imagesExtensions, promises, uploader, handlerSuccess, o.defaultHandlerSuccess); |
| 17397 |
} |
| 17398 |
fileList = fileList.filter((a)=>a); |
| 17399 |
if (fileList.length) { |
| 17400 |
const form = new FormData(); |
| 17401 |
form.append(o.pathVariableName, uploader.path); |
| 17402 |
form.append('source', uploader.source); |
| 17403 |
let file; |
| 17404 |
for(let i = 0; i < fileList.length; i += 1){ |
| 17405 |
file = fileList[i]; |
| 17406 |
if (file) { |
| 17407 |
const hasRealExtension = /\.\w+$/.test(file.name); |
| 17408 |
const mime = file.type.match(/\/([a-z0-9]+)/i); |
| 17409 |
const extension = mime && mime[1] ? mime[1].toLowerCase() : ''; |
| 17410 |
let newName = fileList[i].name || Math.random().toString().replace('.', ''); |
| 17411 |
if (!hasRealExtension && extension) { |
| 17412 |
let extForReg = extension; |
| 17413 |
if ([ |
| 17414 |
'jpeg', |
| 17415 |
'jpg' |
| 17416 |
].includes(extForReg)) { |
| 17417 |
extForReg = 'jpeg|jpg'; |
| 17418 |
} |
| 17419 |
const reEnd = new RegExp('.(' + extForReg + ')$', 'i'); |
| 17420 |
if (!reEnd.test(newName)) { |
| 17421 |
newName += '.' + extension; |
| 17422 |
} |
| 17423 |
} |
| 17424 |
const [key, iFile, name] = o.processFileName.call(uploader, o.filesVariableName(i), fileList[i], newName); |
| 17425 |
form.append(key, iFile, name); |
| 17426 |
} |
| 17427 |
} |
| 17428 |
if (process) { |
| 17429 |
process(form); |
| 17430 |
} |
| 17431 |
if (o.data && (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_0__.isPlainObject)(o.data)) { |
| 17432 |
Object.keys(o.data).forEach((key)=>{ |
| 17433 |
form.append(key, o.data[key]); |
| 17434 |
}); |
| 17435 |
} |
| 17436 |
o.prepareData.call(uploader, form); |
| 17437 |
promises.push((0,jodit_modules_uploader_helpers_send__WEBPACK_IMPORTED_MODULE_1__.send)(uploader, form).then((resp)=>{ |
| 17438 |
if (o.isSuccess.call(uploader, resp)) { |
| 17439 |
const handler = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_0__.isFunction)(handlerSuccess) ? handlerSuccess : o.defaultHandlerSuccess; |
| 17440 |
handler.call(uploader, o.process.call(uploader, resp)); |
| 17441 |
return resp; |
| 17442 |
} |
| 17443 |
const handler = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_0__.isFunction)(handlerError) ? handlerError : o.defaultHandlerError; |
| 17444 |
handler.call(uploader, (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_0__.error)(o.getMessage.call(uploader, resp))); |
| 17445 |
return resp; |
| 17446 |
}).then(()=>{ |
| 17447 |
uploader.j.events && uploader.j.e.fire('filesWereUploaded'); |
| 17448 |
})); |
| 17449 |
} |
| 17450 |
return Promise.all(promises); |
| 17451 |
} |
| 17452 |
function readImagesWithReader(fileList, imagesExtensions, promises, uploader, handlerSuccess, defaultHandlerSuccess) { |
| 17453 |
let file, i; |
| 17454 |
for(i = 0; i < fileList.length; i += 1){ |
| 17455 |
file = fileList[i]; |
| 17456 |
if (file && file.type) { |
| 17457 |
const mime = file.type.match(/\/([a-z0-9]+)/i); |
| 17458 |
const extension = mime[1] ? mime[1].toLowerCase() : ''; |
| 17459 |
if (!imagesExtensions.includes(extension)) { |
| 17460 |
continue; |
| 17461 |
} |
| 17462 |
const reader = new FileReader(); |
| 17463 |
promises.push(uploader.j.async.promise((resolve, reject)=>{ |
| 17464 |
reader.onerror = reject; |
| 17465 |
reader.onloadend = ()=>{ |
| 17466 |
const resp = { |
| 17467 |
baseurl: '', |
| 17468 |
files: [ |
| 17469 |
reader.result |
| 17470 |
], |
| 17471 |
isImages: [ |
| 17472 |
true |
| 17473 |
] |
| 17474 |
}; |
| 17475 |
const handler = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_0__.isFunction)(handlerSuccess) ? handlerSuccess : defaultHandlerSuccess; |
| 17476 |
handler.call(uploader, resp); |
| 17477 |
resolve(resp); |
| 17478 |
}; |
| 17479 |
reader.readAsDataURL(file); |
| 17480 |
})); |
| 17481 |
fileList[i] = null; |
| 17482 |
} |
| 17483 |
} |
| 17484 |
} |
| 17485 |
|
| 17486 |
|
| 17487 |
/***/ }), |
| 17488 |
|
| 17489 |
/***/ 47670: |
| 17490 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 17491 |
|
| 17492 |
"use strict"; |
| 17493 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5266); |
| 17494 |
/*! |
| 17495 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 17496 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 17497 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 17498 |
*/ /** |
| 17499 |
* @module plugins/select |
| 17500 |
*/ |
| 17501 |
jodit_config__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.select = { |
| 17502 |
normalizeSelectionBeforeCutAndCopy: false, |
| 17503 |
normalizeTripleClick: true |
| 17504 |
}; |
| 17505 |
|
| 17506 |
|
| 17507 |
/***/ }), |
| 17508 |
|
| 17509 |
/***/ 47744: |
| 17510 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 17511 |
|
| 17512 |
"use strict"; |
| 17513 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 17514 |
/* harmony export */ readValuesFromImage: function() { return /* binding */ readValuesFromImage; } |
| 17515 |
/* harmony export */ }); |
| 17516 |
/* harmony import */ var _swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(49376); |
| 17517 |
/* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(7909); |
| 17518 |
/* harmony import */ var _align__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(26633); |
| 17519 |
/* harmony import */ var _link__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(79310); |
| 17520 |
/* harmony import */ var _margin__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(18380); |
| 17521 |
/* harmony import */ var _size__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(57339); |
| 17522 |
/*! |
| 17523 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 17524 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 17525 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 17526 |
*/ /** |
| 17527 |
* @module plugins/image-properties |
| 17528 |
*/ |
| 17529 |
|
| 17530 |
|
| 17531 |
|
| 17532 |
|
| 17533 |
|
| 17534 |
/** |
| 17535 |
* Read values from image and set it to state |
| 17536 |
* @private |
| 17537 |
*/ function readValuesFromImage(j, state) { |
| 17538 |
return (0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 17539 |
const { sourceImage: image, values } = state; |
| 17540 |
(0,_align__WEBPACK_IMPORTED_MODULE_2__.readAlign)(image, values); |
| 17541 |
// Border radius |
| 17542 |
values.borderRadius = parseInt(image.style.borderRadius || '0', 10) || 0; |
| 17543 |
// Id |
| 17544 |
values.id = (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(image, 'id') || ''; |
| 17545 |
// Title |
| 17546 |
values.imageTitle = (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(image, 'title') || ''; |
| 17547 |
// Alt |
| 17548 |
values.imageAlt = (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(image, 'alt') || ''; |
| 17549 |
// Style |
| 17550 |
values.style = (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(image, 'style') || ''; |
| 17551 |
// Classes |
| 17552 |
values.classes = ((0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(image, 'class') || '').replace(/jodit_focused_image[\s]*/, ''); |
| 17553 |
// Margins |
| 17554 |
(0,_margin__WEBPACK_IMPORTED_MODULE_4__.readMargins)(image, values, state); |
| 17555 |
// Link |
| 17556 |
(0,_link__WEBPACK_IMPORTED_MODULE_3__.readLink)(state, j, values); |
| 17557 |
// Src |
| 17558 |
values.imageSrc = (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(image, 'src') || ''; |
| 17559 |
// Image size |
| 17560 |
return (0,_size__WEBPACK_IMPORTED_MODULE_5__.readSizes)(image, values, state); |
| 17561 |
})(); |
| 17562 |
} |
| 17563 |
|
| 17564 |
|
| 17565 |
/***/ }), |
| 17566 |
|
| 17567 |
/***/ 47760: |
| 17568 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 17569 |
|
| 17570 |
"use strict"; |
| 17571 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 17572 |
/* harmony export */ alreadyLoadedList: function() { return /* binding */ alreadyLoadedList; }, |
| 17573 |
/* harmony export */ appendScriptAsync: function() { return /* binding */ appendScriptAsync; }, |
| 17574 |
/* harmony export */ appendStyleAsync: function() { return /* binding */ appendStyleAsync; }, |
| 17575 |
/* harmony export */ loadNext: function() { return /* binding */ loadNext; }, |
| 17576 |
/* harmony export */ loadNextStyle: function() { return /* binding */ loadNextStyle; } |
| 17577 |
/* harmony export */ }); |
| 17578 |
/* harmony import */ var jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(85932); |
| 17579 |
/* harmony import */ var _complete_url__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(91321); |
| 17580 |
/*! |
| 17581 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 17582 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 17583 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 17584 |
*/ /** |
| 17585 |
* @module helpers/utils |
| 17586 |
*/ |
| 17587 |
|
| 17588 |
const alreadyLoadedList = new Map(); |
| 17589 |
const cacheLoaders = (loader)=>{ |
| 17590 |
return (jodit, url)=>{ |
| 17591 |
if (alreadyLoadedList.has(url)) { |
| 17592 |
return alreadyLoadedList.get(url); |
| 17593 |
} |
| 17594 |
const promise = loader(jodit, url); |
| 17595 |
alreadyLoadedList.set(url, promise); |
| 17596 |
return promise; |
| 17597 |
}; |
| 17598 |
}; |
| 17599 |
/** |
| 17600 |
* Load script and return promise |
| 17601 |
*/ const appendScriptAsync = cacheLoaders((jodit, url)=>{ |
| 17602 |
return jodit.async.promise((resolve, reject)=>{ |
| 17603 |
if (jodit.isInDestruct) { |
| 17604 |
return reject(); |
| 17605 |
} |
| 17606 |
const script = jodit.c.element('script', { |
| 17607 |
type: 'text/javascript', |
| 17608 |
crossorigin: 'anonymous', |
| 17609 |
referrerpolicy: 'no-referrer', |
| 17610 |
async: true, |
| 17611 |
src: (0,_complete_url__WEBPACK_IMPORTED_MODULE_1__.completeUrl)(url) |
| 17612 |
}); |
| 17613 |
jodit.e.one(script, 'error', reject).one(script, 'load', resolve); |
| 17614 |
jodit.od.body.appendChild(script); |
| 17615 |
}); |
| 17616 |
}); |
| 17617 |
/** |
| 17618 |
* Download CSS style script |
| 17619 |
*/ const appendStyleAsync = cacheLoaders((jodit, url)=>{ |
| 17620 |
return jodit.async.promise((resolve, reject)=>{ |
| 17621 |
if (jodit.isInDestruct) { |
| 17622 |
return reject(); |
| 17623 |
} |
| 17624 |
const link = jodit.c.element('link'); |
| 17625 |
link.rel = 'stylesheet'; |
| 17626 |
link.media = 'all'; |
| 17627 |
link.crossOrigin = 'anonymous'; |
| 17628 |
const callback = ()=>resolve(link); |
| 17629 |
!jodit.isInDestruct && jodit.e.on(link, 'load', callback).on(link, 'error', reject); |
| 17630 |
link.href = (0,_complete_url__WEBPACK_IMPORTED_MODULE_1__.completeUrl)(url); |
| 17631 |
if (jodit.o.shadowRoot) { |
| 17632 |
jodit.o.shadowRoot.appendChild(link); |
| 17633 |
} else { |
| 17634 |
jodit.od.body.appendChild(link); |
| 17635 |
} |
| 17636 |
}); |
| 17637 |
}); |
| 17638 |
function loadNext(jodit, urls, i = 0) { |
| 17639 |
if (!(0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_0__.isString)(urls[i])) { |
| 17640 |
return Promise.resolve(); |
| 17641 |
} |
| 17642 |
return appendScriptAsync(jodit, urls[i]).then(()=>loadNext(jodit, urls, i + 1)); |
| 17643 |
} |
| 17644 |
function loadNextStyle(jodit, urls, i = 0) { |
| 17645 |
if (!(0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_0__.isString)(urls[i])) { |
| 17646 |
return Promise.resolve(); |
| 17647 |
} |
| 17648 |
return appendStyleAsync(jodit, urls[i]).then(()=>loadNextStyle(jodit, urls, i + 1)); |
| 17649 |
} |
| 17650 |
|
| 17651 |
|
| 17652 |
/***/ }), |
| 17653 |
|
| 17654 |
/***/ 47919: |
| 17655 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 17656 |
|
| 17657 |
"use strict"; |
| 17658 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 17659 |
/* harmony export */ moveCursorOutFromSpecialTags: function() { return /* binding */ moveCursorOutFromSpecialTags; } |
| 17660 |
/* harmony export */ }); |
| 17661 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 17662 |
/*! |
| 17663 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 17664 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 17665 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 17666 |
*/ /** |
| 17667 |
* @module plugins/enter |
| 17668 |
*/ |
| 17669 |
/** |
| 17670 |
* Checks if the cursor is on the edge of a special tag and exits if so |
| 17671 |
* @private |
| 17672 |
*/ function moveCursorOutFromSpecialTags(jodit, fake, tags) { |
| 17673 |
const { s } = jodit; |
| 17674 |
const link = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(fake, tags, jodit.editor); |
| 17675 |
if (link) { |
| 17676 |
if (s.cursorOnTheRight(link, fake)) { |
| 17677 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.after(link, fake); |
| 17678 |
} else if (s.cursorOnTheLeft(link, fake)) { |
| 17679 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.before(link, fake); |
| 17680 |
} |
| 17681 |
} |
| 17682 |
} |
| 17683 |
|
| 17684 |
|
| 17685 |
/***/ }), |
| 17686 |
|
| 17687 |
/***/ 48007: |
| 17688 |
/***/ (function(module) { |
| 17689 |
|
| 17690 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M512 1248v192q0 40-28 68t-68 28h-320q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h320q40 0 68 28t28 68zm0-512v192q0 40-28 68t-68 28h-320q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h320q40 0 68 28t28 68zm1280 512v192q0 40-28 68t-68 28h-960q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h960q40 0 68 28t28 68zm-1280-1024v192q0 40-28 68t-68 28h-320q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h320q40 0 68 28t28 68zm1280 512v192q0 40-28 68t-68 28h-960q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h960q40 0 68 28t28 68zm0-512v192q0 40-28 68t-68 28h-960q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h960q40 0 68 28t28 68z\"/> </svg>" |
| 17691 |
|
| 17692 |
/***/ }), |
| 17693 |
|
| 17694 |
/***/ 48009: |
| 17695 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 17696 |
|
| 17697 |
"use strict"; |
| 17698 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 17699 |
/* harmony export */ normalizeUrl: function() { return /* binding */ normalizeUrl; } |
| 17700 |
/* harmony export */ }); |
| 17701 |
/*! |
| 17702 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 17703 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 17704 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 17705 |
*/ /** |
| 17706 |
* @module helpers/normalize |
| 17707 |
*/ const normalizeUrl = (...urls)=>{ |
| 17708 |
return urls.filter((url)=>url.length).map((url)=>url.replace(/\/$/, '')).join('/').replace(/([^:])[\\/]+/g, '$1/'); |
| 17709 |
}; |
| 17710 |
|
| 17711 |
|
| 17712 |
/***/ }), |
| 17713 |
|
| 17714 |
/***/ 48155: |
| 17715 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 17716 |
|
| 17717 |
"use strict"; |
| 17718 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 17719 |
/* harmony export */ safeHTML: function() { return /* binding */ safeHTML; }, |
| 17720 |
/* harmony export */ sanitizeHTMLElement: function() { return /* binding */ sanitizeHTMLElement; } |
| 17721 |
/* harmony export */ }); |
| 17722 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 17723 |
/* harmony import */ var jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(93640); |
| 17724 |
/*! |
| 17725 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 17726 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 17727 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 17728 |
*/ /** |
| 17729 |
* @module helpers/html |
| 17730 |
*/ |
| 17731 |
|
| 17732 |
/** |
| 17733 |
* Removes dangerous constructs from HTML |
| 17734 |
*/ function safeHTML(box, options) { |
| 17735 |
if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isElement(box) && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isFragment(box)) { |
| 17736 |
return; |
| 17737 |
} |
| 17738 |
if (options.removeOnError) { |
| 17739 |
sanitizeHTMLElement(box); |
| 17740 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__.$$)('[onerror]', box).forEach((elm)=>sanitizeHTMLElement(elm, options)); |
| 17741 |
} |
| 17742 |
if (options.safeJavaScriptLink) { |
| 17743 |
sanitizeHTMLElement(box); |
| 17744 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__.$$)('a[href^="javascript"]', box).forEach((elm)=>sanitizeHTMLElement(elm, options)); |
| 17745 |
} |
| 17746 |
} |
| 17747 |
function sanitizeHTMLElement(elm, { safeJavaScriptLink, removeOnError } = { |
| 17748 |
safeJavaScriptLink: true, |
| 17749 |
removeOnError: true |
| 17750 |
}) { |
| 17751 |
if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isElement(elm)) { |
| 17752 |
return false; |
| 17753 |
} |
| 17754 |
let effected = false; |
| 17755 |
if (removeOnError && elm.hasAttribute('onerror')) { |
| 17756 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__.attr)(elm, 'onerror', null); |
| 17757 |
effected = true; |
| 17758 |
} |
| 17759 |
const href = elm.getAttribute('href'); |
| 17760 |
if (safeJavaScriptLink && href && href.trim().indexOf('javascript') === 0) { |
| 17761 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__.attr)(elm, 'href', location.protocol + '//' + href); |
| 17762 |
effected = true; |
| 17763 |
} |
| 17764 |
return effected; |
| 17765 |
} |
| 17766 |
|
| 17767 |
|
| 17768 |
/***/ }), |
| 17769 |
|
| 17770 |
/***/ 48290: |
| 17771 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 17772 |
|
| 17773 |
"use strict"; |
| 17774 |
/* harmony import */ var jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(27795); |
| 17775 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(65946); |
| 17776 |
/* harmony import */ var jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(93640); |
| 17777 |
/* harmony import */ var jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(29434); |
| 17778 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(5266); |
| 17779 |
/* harmony import */ var _table_svg__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(67447); |
| 17780 |
/* harmony import */ var _table_svg__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_table_svg__WEBPACK_IMPORTED_MODULE_5__); |
| 17781 |
/*! |
| 17782 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 17783 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 17784 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 17785 |
*/ /** |
| 17786 |
* @module plugins/table |
| 17787 |
*/ |
| 17788 |
|
| 17789 |
|
| 17790 |
|
| 17791 |
|
| 17792 |
|
| 17793 |
jodit_config__WEBPACK_IMPORTED_MODULE_4__.Config.prototype.table = { |
| 17794 |
splitBlockOnInsertTable: true, |
| 17795 |
selectionCellStyle: 'border: 1px double #1e88e5 !important;', |
| 17796 |
useExtraClassesOptions: false |
| 17797 |
}; |
| 17798 |
jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_3__.Icon.set('table', (_table_svg__WEBPACK_IMPORTED_MODULE_5___default())); |
| 17799 |
jodit_config__WEBPACK_IMPORTED_MODULE_4__.Config.prototype.controls.table = { |
| 17800 |
data: { |
| 17801 |
cols: 10, |
| 17802 |
rows: 10, |
| 17803 |
classList: { |
| 17804 |
'table table-bordered': 'Bootstrap Bordered', |
| 17805 |
'table table-striped': 'Bootstrap Striped', |
| 17806 |
'table table-dark': 'Bootstrap Dark' |
| 17807 |
} |
| 17808 |
}, |
| 17809 |
popup: (editor, current, close, button)=>{ |
| 17810 |
editor.editor.normalize(); |
| 17811 |
const snapshot = editor.history.snapshot.make(); |
| 17812 |
const control = button.control; |
| 17813 |
const default_rows_count = control.data && control.data.rows ? control.data.rows : 10, default_cols_count = control.data && control.data.cols ? control.data.cols : 10; |
| 17814 |
const generateExtraClasses = ()=>{ |
| 17815 |
if (!editor.o.table.useExtraClassesOptions) { |
| 17816 |
return ''; |
| 17817 |
} |
| 17818 |
const out = []; |
| 17819 |
if (control.data) { |
| 17820 |
const classList = control.data.classList; |
| 17821 |
Object.keys(classList).forEach((classes)=>{ |
| 17822 |
out.push(`<label class="jodit_vertical_middle"><input class="jodit-checkbox" value="${classes}" type="checkbox"/>${classList[classes]}</label>`); |
| 17823 |
}); |
| 17824 |
} |
| 17825 |
return out.join(''); |
| 17826 |
}; |
| 17827 |
const form = editor.c.fromHTML('<form class="jodit-form jodit-form__inserter">' + '<div class="jodit-form__table-creator-box">' + '<div class="jodit-form__container"></div>' + '<div class="jodit-form__options">' + generateExtraClasses() + '</div>' + '</div>' + '<label class="jodit-form__center">' + '<span>1</span> × <span>1</span>' + '</label>' + '</form>'), rows = form.querySelectorAll('span')[0], cols = form.querySelectorAll('span')[1], blocksContainer = form.querySelector('.jodit-form__container'), options = form.querySelector('.jodit-form__options'), cells = []; |
| 17828 |
const cnt = default_rows_count * default_cols_count; |
| 17829 |
for(let i = 0; i < cnt; i += 1){ |
| 17830 |
if (!cells[i]) { |
| 17831 |
cells.push(editor.c.element('span', { |
| 17832 |
dataIndex: i |
| 17833 |
})); |
| 17834 |
} |
| 17835 |
} |
| 17836 |
const mouseenter = (e, index)=>{ |
| 17837 |
const dv = e.target; |
| 17838 |
if (!jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(dv, 'span')) { |
| 17839 |
return; |
| 17840 |
} |
| 17841 |
const k = index === undefined || isNaN(index) ? parseInt((0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_2__.attr)(dv, '-index') || '0', 10) : index || 0; |
| 17842 |
const rows_count = Math.ceil((k + 1) / default_cols_count), cols_count = k % default_cols_count + 1; |
| 17843 |
for(let i = 0; i < cells.length; i += 1){ |
| 17844 |
if (cols_count >= i % default_cols_count + 1 && rows_count >= Math.ceil((i + 1) / default_cols_count)) { |
| 17845 |
cells[i].className = 'jodit_hovered'; |
| 17846 |
} else { |
| 17847 |
cells[i].className = ''; |
| 17848 |
} |
| 17849 |
} |
| 17850 |
cols.textContent = cols_count.toString(); |
| 17851 |
rows.textContent = rows_count.toString(); |
| 17852 |
}; |
| 17853 |
editor.e.on(blocksContainer, 'mousemove', mouseenter).on(blocksContainer, 'touchstart mousedown', (e)=>{ |
| 17854 |
const dv = e.target; |
| 17855 |
e.preventDefault(); |
| 17856 |
e.stopImmediatePropagation(); |
| 17857 |
if (!jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(dv, 'span')) { |
| 17858 |
return; |
| 17859 |
} |
| 17860 |
const k = parseInt((0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_2__.attr)(dv, '-index') || '0', 10); |
| 17861 |
const rows_count = Math.ceil((k + 1) / default_cols_count), cols_count = k % default_cols_count + 1; |
| 17862 |
const crt = editor.createInside, tbody = crt.element('tbody'), table = crt.element('table'); |
| 17863 |
table.appendChild(tbody); |
| 17864 |
let first_td = null, tr, td; |
| 17865 |
for(let i = 1; i <= rows_count; i += 1){ |
| 17866 |
tr = crt.element('tr'); |
| 17867 |
for(let j = 1; j <= cols_count; j += 1){ |
| 17868 |
td = crt.element('td'); |
| 17869 |
if (!first_td) { |
| 17870 |
first_td = td; |
| 17871 |
} |
| 17872 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__.css)(td, 'width', (100 / cols_count).toFixed(4) + '%'); |
| 17873 |
td.appendChild(crt.element('br')); |
| 17874 |
tr.appendChild(crt.text('\n')); |
| 17875 |
tr.appendChild(crt.text('\t')); |
| 17876 |
tr.appendChild(td); |
| 17877 |
} |
| 17878 |
tbody.appendChild(crt.text('\n')); |
| 17879 |
tbody.appendChild(tr); |
| 17880 |
} |
| 17881 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__.$$)('input[type=checkbox]:checked', options).forEach((input)=>{ |
| 17882 |
input.value.split(/[\s]+/).forEach((className)=>{ |
| 17883 |
table.classList.add(className); |
| 17884 |
}); |
| 17885 |
}); |
| 17886 |
editor.s.restore(); |
| 17887 |
editor.s.removeMarkers(); |
| 17888 |
editor.editor.normalize(); |
| 17889 |
editor.history.snapshot.restore(snapshot); |
| 17890 |
const block = jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.furthest(editor.s.current(), jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isBlock, editor.editor); |
| 17891 |
if (block && jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isEmpty(block)) { |
| 17892 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.replace(block, table, undefined, false, true); |
| 17893 |
} else { |
| 17894 |
if (block) { |
| 17895 |
const fake = crt.text('\n'); |
| 17896 |
if (!editor.o.table.splitBlockOnInsertTable) { |
| 17897 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.after(block, fake); |
| 17898 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.after(fake, table); |
| 17899 |
} else { |
| 17900 |
const range = editor.s.range; |
| 17901 |
range.collapse(false); |
| 17902 |
range.insertNode(fake); |
| 17903 |
range.collapse(false); |
| 17904 |
editor.s.selectRange(range); |
| 17905 |
const firstPart = editor.s.splitSelection(block, fake); |
| 17906 |
if (firstPart) { |
| 17907 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.after(firstPart, table); |
| 17908 |
} else { |
| 17909 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.after(block, table); |
| 17910 |
} |
| 17911 |
} |
| 17912 |
} else { |
| 17913 |
editor.s.insertNode(table, false); |
| 17914 |
} |
| 17915 |
} |
| 17916 |
if (first_td) { |
| 17917 |
editor.s.setCursorIn(first_td); |
| 17918 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__.scrollIntoViewIfNeeded)(first_td, editor.editor, editor.ed); |
| 17919 |
} |
| 17920 |
close(); |
| 17921 |
}); |
| 17922 |
if (button && button.parentElement) { |
| 17923 |
for(let i = 0; i < default_rows_count; i += 1){ |
| 17924 |
const row = editor.c.div(); |
| 17925 |
for(let j = 0; j < default_cols_count; j += 1){ |
| 17926 |
row.appendChild(cells[i * default_cols_count + j]); |
| 17927 |
} |
| 17928 |
blocksContainer.appendChild(row); |
| 17929 |
} |
| 17930 |
if (cells[0]) { |
| 17931 |
cells[0].className = 'hovered'; |
| 17932 |
} |
| 17933 |
} |
| 17934 |
return form; |
| 17935 |
}, |
| 17936 |
tooltip: 'Insert table' |
| 17937 |
}; |
| 17938 |
|
| 17939 |
|
| 17940 |
/***/ }), |
| 17941 |
|
| 17942 |
/***/ 48729: |
| 17943 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 17944 |
|
| 17945 |
"use strict"; |
| 17946 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 17947 |
/* harmony export */ FiniteStateMachine: function() { return /* binding */ FiniteStateMachine; } |
| 17948 |
/* harmony export */ }); |
| 17949 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 17950 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(81937); |
| 17951 |
/* harmony import */ var jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(85932); |
| 17952 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(28712); |
| 17953 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_3__); |
| 17954 |
/*! |
| 17955 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 17956 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 17957 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 17958 |
*/ |
| 17959 |
|
| 17960 |
|
| 17961 |
|
| 17962 |
/** |
| 17963 |
* A state machine implementation for applying styles. |
| 17964 |
*/ class FiniteStateMachine { |
| 17965 |
setState(state) { |
| 17966 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_3__.assert)(!this.__previewsStates.has(state), 'Circled states'); |
| 17967 |
this.__previewsStates.add(state); |
| 17968 |
this.__state = state; |
| 17969 |
} |
| 17970 |
getState() { |
| 17971 |
return this.__state; |
| 17972 |
} |
| 17973 |
disableSilent() { |
| 17974 |
this.silent = false; |
| 17975 |
} |
| 17976 |
dispatch(actionName, value) { |
| 17977 |
const action = this.transitions[this.getState()][actionName]; |
| 17978 |
if (action) { |
| 17979 |
const res = action.call(this, value); |
| 17980 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_3__.assert)(res && res !== value, 'Action should return new value'); |
| 17981 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_3__.assert)((0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_2__.isString)(res.next), 'Value should contain the next state'); |
| 17982 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_3__.assert)(res.next !== this.getState(), 'The new state should not be equal to the old one.'); |
| 17983 |
this.setState(res.next); |
| 17984 |
if (!jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.IS_PROD && !this.silent) { |
| 17985 |
// eslint-disable-next-line no-console |
| 17986 |
console.log(`State: ${this.getState()}`); |
| 17987 |
} |
| 17988 |
return res; |
| 17989 |
} |
| 17990 |
throw new Error(`invalid action: ${this.getState()}.${actionName.toString()}`); |
| 17991 |
} |
| 17992 |
constructor(state, transitions){ |
| 17993 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "transitions", void 0); |
| 17994 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__state", void 0); |
| 17995 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "silent", void 0); |
| 17996 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__previewsStates", void 0); |
| 17997 |
this.transitions = transitions; |
| 17998 |
this.silent = true; |
| 17999 |
this.__previewsStates = new Set(); |
| 18000 |
this.setState(state); |
| 18001 |
} |
| 18002 |
} |
| 18003 |
|
| 18004 |
|
| 18005 |
/***/ }), |
| 18006 |
|
| 18007 |
/***/ 48776: |
| 18008 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 18009 |
|
| 18010 |
"use strict"; |
| 18011 |
__webpack_require__.r(__webpack_exports__); |
| 18012 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 18013 |
/* harmony export */ required: function() { return /* binding */ required; }, |
| 18014 |
/* harmony export */ url: function() { return /* binding */ url; } |
| 18015 |
/* harmony export */ }); |
| 18016 |
/* harmony import */ var jodit_core_helpers_checker_is_url__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(91764); |
| 18017 |
/* harmony import */ var jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(4040); |
| 18018 |
/*! |
| 18019 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 18020 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 18021 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 18022 |
*/ /** |
| 18023 |
* @module ui/form |
| 18024 |
*/ |
| 18025 |
|
| 18026 |
/** |
| 18027 |
* Input is required |
| 18028 |
*/ const required = function(input) { |
| 18029 |
if (!(0,jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_1__.trim)(input.value).length) { |
| 18030 |
input.error = 'Please fill out this field'; |
| 18031 |
return false; |
| 18032 |
} |
| 18033 |
return true; |
| 18034 |
}; |
| 18035 |
/** |
| 18036 |
* Input value should be valid URL |
| 18037 |
*/ const url = function(input) { |
| 18038 |
if (!(0,jodit_core_helpers_checker_is_url__WEBPACK_IMPORTED_MODULE_0__.isURL)((0,jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_1__.trim)(input.value))) { |
| 18039 |
input.error = 'Please enter a web address'; |
| 18040 |
return false; |
| 18041 |
} |
| 18042 |
return true; |
| 18043 |
}; |
| 18044 |
|
| 18045 |
|
| 18046 |
/***/ }), |
| 18047 |
|
| 18048 |
/***/ 48838: |
| 18049 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 18050 |
|
| 18051 |
"use strict"; |
| 18052 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 18053 |
/* harmony export */ nl2br: function() { return /* binding */ nl2br; } |
| 18054 |
/* harmony export */ }); |
| 18055 |
/*! |
| 18056 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 18057 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 18058 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 18059 |
*/ /** |
| 18060 |
* @module helpers/html |
| 18061 |
*/ /** |
| 18062 |
* Inserts HTML line breaks before all newlines in a string |
| 18063 |
*/ function nl2br(html) { |
| 18064 |
return html.replace(/\r\n|\r|\n/g, '<br/>'); |
| 18065 |
} |
| 18066 |
|
| 18067 |
|
| 18068 |
/***/ }), |
| 18069 |
|
| 18070 |
/***/ 48842: |
| 18071 |
/***/ (function(module) { |
| 18072 |
|
| 18073 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M789 559l-170 450q33 0 136.5 2t160.5 2q19 0 57-2-87-253-184-452zm-725 1105l2-79q23-7 56-12.5t57-10.5 49.5-14.5 44.5-29 31-50.5l237-616 280-724h128q8 14 11 21l205 480q33 78 106 257.5t114 274.5q15 34 58 144.5t72 168.5q20 45 35 57 19 15 88 29.5t84 20.5q6 38 6 57 0 4-.5 13t-.5 13q-63 0-190-8t-191-8q-76 0-215 7t-178 8q0-43 4-78l131-28q1 0 12.5-2.5t15.5-3.5 14.5-4.5 15-6.5 11-8 9-11 2.5-14q0-16-31-96.5t-72-177.5-42-100l-450-2q-26 58-76.5 195.5t-50.5 162.5q0 22 14 37.5t43.5 24.5 48.5 13.5 57 8.5 41 4q1 19 1 58 0 9-2 27-58 0-174.5-10t-174.5-10q-8 0-26.5 4t-21.5 4q-80 14-188 14z\"/> </svg>" |
| 18074 |
|
| 18075 |
/***/ }), |
| 18076 |
|
| 18077 |
/***/ 48899: |
| 18078 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 18079 |
|
| 18080 |
"use strict"; |
| 18081 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(65946); |
| 18082 |
/* harmony import */ var jodit_core_ui_button__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(59400); |
| 18083 |
/* harmony import */ var jodit_core_ui_form__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5658); |
| 18084 |
/* harmony import */ var jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(29434); |
| 18085 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(5266); |
| 18086 |
/* harmony import */ var jodit_modules_widget__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(15753); |
| 18087 |
/* harmony import */ var _video_svg__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(36339); |
| 18088 |
/* harmony import */ var _video_svg__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(_video_svg__WEBPACK_IMPORTED_MODULE_6__); |
| 18089 |
/*! |
| 18090 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 18091 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 18092 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 18093 |
*/ /** |
| 18094 |
* @module plugins/video |
| 18095 |
*/ |
| 18096 |
|
| 18097 |
|
| 18098 |
|
| 18099 |
|
| 18100 |
|
| 18101 |
|
| 18102 |
jodit_config__WEBPACK_IMPORTED_MODULE_4__.Config.prototype.video = { |
| 18103 |
parseUrlToVideoEmbed: jodit_core_helpers__WEBPACK_IMPORTED_MODULE_0__.convertMediaUrlToVideoEmbed, |
| 18104 |
defaultWidth: 400, |
| 18105 |
defaultHeight: 345 |
| 18106 |
}; |
| 18107 |
jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_3__.Icon.set('video', (_video_svg__WEBPACK_IMPORTED_MODULE_6___default())); |
| 18108 |
jodit_config__WEBPACK_IMPORTED_MODULE_4__.Config.prototype.controls.video = { |
| 18109 |
popup: (jodit, current, close)=>{ |
| 18110 |
const formLink = new jodit_core_ui_form__WEBPACK_IMPORTED_MODULE_2__.UIForm(jodit, [ |
| 18111 |
new jodit_core_ui_form__WEBPACK_IMPORTED_MODULE_2__.UIBlock(jodit, [ |
| 18112 |
new jodit_core_ui_form__WEBPACK_IMPORTED_MODULE_2__.UIInput(jodit, { |
| 18113 |
name: 'url', |
| 18114 |
required: true, |
| 18115 |
label: 'URL', |
| 18116 |
placeholder: 'https://', |
| 18117 |
validators: [ |
| 18118 |
'url' |
| 18119 |
] |
| 18120 |
}) |
| 18121 |
]), |
| 18122 |
new jodit_core_ui_form__WEBPACK_IMPORTED_MODULE_2__.UIBlock(jodit, [ |
| 18123 |
(0,jodit_core_ui_button__WEBPACK_IMPORTED_MODULE_1__.Button)(jodit, '', 'Insert', 'primary').onAction(()=>formLink.submit()) |
| 18124 |
]) |
| 18125 |
]), formCode = new jodit_core_ui_form__WEBPACK_IMPORTED_MODULE_2__.UIForm(jodit, [ |
| 18126 |
new jodit_core_ui_form__WEBPACK_IMPORTED_MODULE_2__.UIBlock(jodit, [ |
| 18127 |
new jodit_core_ui_form__WEBPACK_IMPORTED_MODULE_2__.UITextArea(jodit, { |
| 18128 |
name: 'code', |
| 18129 |
required: true, |
| 18130 |
label: 'Embed code' |
| 18131 |
}) |
| 18132 |
]), |
| 18133 |
new jodit_core_ui_form__WEBPACK_IMPORTED_MODULE_2__.UIBlock(jodit, [ |
| 18134 |
(0,jodit_core_ui_button__WEBPACK_IMPORTED_MODULE_1__.Button)(jodit, '', 'Insert', 'primary').onAction(()=>formCode.submit()) |
| 18135 |
]) |
| 18136 |
]), tabs = [], insertCode = (code)=>{ |
| 18137 |
jodit.s.restore(); |
| 18138 |
jodit.s.insertHTML(code); |
| 18139 |
close(); |
| 18140 |
}; |
| 18141 |
jodit.s.save(); |
| 18142 |
tabs.push({ |
| 18143 |
icon: 'link', |
| 18144 |
name: 'Link', |
| 18145 |
content: formLink.container |
| 18146 |
}, { |
| 18147 |
icon: 'source', |
| 18148 |
name: 'Code', |
| 18149 |
content: formCode.container |
| 18150 |
}); |
| 18151 |
formLink.onSubmit((data)=>{ |
| 18152 |
var _ref; |
| 18153 |
var _jodit_o_video, _jodit_o_video1, _jodit_o_video2; |
| 18154 |
insertCode((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_0__.call)((_ref = (_jodit_o_video = jodit.o.video) === null || _jodit_o_video === void 0 ? void 0 : _jodit_o_video.parseUrlToVideoEmbed) !== null && _ref !== void 0 ? _ref : jodit_core_helpers__WEBPACK_IMPORTED_MODULE_0__.convertMediaUrlToVideoEmbed, data.url, { |
| 18155 |
width: (_jodit_o_video1 = jodit.o.video) === null || _jodit_o_video1 === void 0 ? void 0 : _jodit_o_video1.defaultWidth, |
| 18156 |
height: (_jodit_o_video2 = jodit.o.video) === null || _jodit_o_video2 === void 0 ? void 0 : _jodit_o_video2.defaultHeight |
| 18157 |
})); |
| 18158 |
}); |
| 18159 |
formCode.onSubmit((data)=>{ |
| 18160 |
insertCode(data.code); |
| 18161 |
}); |
| 18162 |
return (0,jodit_modules_widget__WEBPACK_IMPORTED_MODULE_5__.TabsWidget)(jodit, tabs); |
| 18163 |
}, |
| 18164 |
tags: [ |
| 18165 |
'iframe' |
| 18166 |
], |
| 18167 |
tooltip: 'Insert youtube/vimeo video' |
| 18168 |
}; |
| 18169 |
|
| 18170 |
|
| 18171 |
/***/ }), |
| 18172 |
|
| 18173 |
/***/ 49147: |
| 18174 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 18175 |
|
| 18176 |
"use strict"; |
| 18177 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 18178 |
/* harmony export */ applySize: function() { return /* binding */ applySize; } |
| 18179 |
/* harmony export */ }); |
| 18180 |
/* harmony import */ var jodit_core_helpers_checker_is_numeric__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(70222); |
| 18181 |
/* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(7909); |
| 18182 |
/* harmony import */ var jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(80991); |
| 18183 |
/* harmony import */ var _utils_utils__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(10808); |
| 18184 |
/*! |
| 18185 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 18186 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 18187 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 18188 |
*/ /** |
| 18189 |
* @module plugins/image-properties |
| 18190 |
*/ |
| 18191 |
|
| 18192 |
|
| 18193 |
|
| 18194 |
/** @private */ function applySize(image, imageWidth, imageHeight, sizeIsLocked) { |
| 18195 |
// Size |
| 18196 |
if (imageWidth !== image.offsetWidth || imageHeight !== image.offsetHeight) { |
| 18197 |
const updatedWidth = imageWidth ? (0,_utils_utils__WEBPACK_IMPORTED_MODULE_3__.normalSizeToString)(imageWidth) : null; |
| 18198 |
let updatedHeight = imageHeight ? (0,_utils_utils__WEBPACK_IMPORTED_MODULE_3__.normalSizeToString)(imageHeight) : null; |
| 18199 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_2__.css)(image, { |
| 18200 |
width: updatedWidth, |
| 18201 |
height: updatedWidth && sizeIsLocked ? null : updatedHeight |
| 18202 |
}); |
| 18203 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(image, 'width', updatedWidth && (0,jodit_core_helpers_checker_is_numeric__WEBPACK_IMPORTED_MODULE_0__.isNumeric)(imageWidth) && (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(image, 'width') ? updatedWidth : null); |
| 18204 |
if (!(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(image, 'width') || sizeIsLocked) { |
| 18205 |
updatedHeight = null; |
| 18206 |
} |
| 18207 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(image, 'height', updatedHeight); |
| 18208 |
} |
| 18209 |
} |
| 18210 |
|
| 18211 |
|
| 18212 |
/***/ }), |
| 18213 |
|
| 18214 |
/***/ 49376: |
| 18215 |
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { |
| 18216 |
|
| 18217 |
"use strict"; |
| 18218 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 18219 |
/* harmony export */ _: function() { return /* binding */ _async_to_generator; } |
| 18220 |
/* harmony export */ }); |
| 18221 |
function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) { |
| 18222 |
try { |
| 18223 |
var info = gen[key](arg); |
| 18224 |
var value = info.value; |
| 18225 |
} catch (error) { |
| 18226 |
reject(error); |
| 18227 |
return; |
| 18228 |
} |
| 18229 |
if (info.done) resolve(value); |
| 18230 |
else Promise.resolve(value).then(_next, _throw); |
| 18231 |
} |
| 18232 |
function _async_to_generator(fn) { |
| 18233 |
return function() { |
| 18234 |
var self = this, args = arguments; |
| 18235 |
return new Promise(function(resolve, reject) { |
| 18236 |
var gen = fn.apply(self, args); |
| 18237 |
function _next(value) { |
| 18238 |
asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value); |
| 18239 |
} |
| 18240 |
function _throw(err) { |
| 18241 |
asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err); |
| 18242 |
} |
| 18243 |
_next(undefined); |
| 18244 |
}); |
| 18245 |
}; |
| 18246 |
} |
| 18247 |
|
| 18248 |
|
| 18249 |
|
| 18250 |
/***/ }), |
| 18251 |
|
| 18252 |
/***/ 49385: |
| 18253 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 18254 |
|
| 18255 |
"use strict"; |
| 18256 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 18257 |
/* harmony export */ cns: function() { return /* binding */ cns; }, |
| 18258 |
/* harmony export */ markDeprecated: function() { return /* binding */ markDeprecated; } |
| 18259 |
/* harmony export */ }); |
| 18260 |
/*! |
| 18261 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 18262 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 18263 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 18264 |
*/ /** |
| 18265 |
* @module helpers/utils |
| 18266 |
*/ /** |
| 18267 |
* By default, terser will remove all `console.*` but |
| 18268 |
* if you use this object it will not be |
| 18269 |
*/ const cns = console; |
| 18270 |
/** |
| 18271 |
* Mark function as deprecated |
| 18272 |
*/ function markDeprecated(method, names = [ |
| 18273 |
'' |
| 18274 |
], ctx = null) { |
| 18275 |
return (...args)=>{ |
| 18276 |
cns.warn(`Method "${names[0]}" deprecated.` + (names[1] ? ` Use "${names[1]}" instead` : '')); |
| 18277 |
return method.call(ctx, ...args); |
| 18278 |
}; |
| 18279 |
} |
| 18280 |
|
| 18281 |
|
| 18282 |
/***/ }), |
| 18283 |
|
| 18284 |
/***/ 49422: |
| 18285 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 18286 |
|
| 18287 |
"use strict"; |
| 18288 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 18289 |
/* harmony export */ applyLink: function() { return /* binding */ applyLink; } |
| 18290 |
/* harmony export */ }); |
| 18291 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 18292 |
/* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(7909); |
| 18293 |
/*! |
| 18294 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 18295 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 18296 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 18297 |
*/ /** |
| 18298 |
* @module plugins/image-properties |
| 18299 |
*/ |
| 18300 |
|
| 18301 |
/** @private */ function applyLink(j, image, imageLink, imageLinkOpenInNewTab) { |
| 18302 |
// Link |
| 18303 |
let link = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(image, 'a', j.editor); |
| 18304 |
if (imageLink) { |
| 18305 |
if (!link) { |
| 18306 |
link = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.wrap(image, 'a', j.createInside); |
| 18307 |
} |
| 18308 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(link, 'href', imageLink); |
| 18309 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(link, 'target', imageLinkOpenInNewTab ? '_blank' : null); |
| 18310 |
} else { |
| 18311 |
if (link && link.parentNode) { |
| 18312 |
link.parentNode.replaceChild(image, link); |
| 18313 |
} |
| 18314 |
} |
| 18315 |
} |
| 18316 |
|
| 18317 |
|
| 18318 |
/***/ }), |
| 18319 |
|
| 18320 |
/***/ 49574: |
| 18321 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 18322 |
|
| 18323 |
"use strict"; |
| 18324 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 18325 |
/* harmony export */ autobind: function() { return /* binding */ autobind; } |
| 18326 |
/* harmony export */ }); |
| 18327 |
/* harmony import */ var jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(91565); |
| 18328 |
/*! |
| 18329 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 18330 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 18331 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 18332 |
*/ /** |
| 18333 |
* [[include:core/decorators/autobind/README.md]] |
| 18334 |
* @packageDocumentation |
| 18335 |
* @module decorators/autobind |
| 18336 |
*/ |
| 18337 |
/** |
| 18338 |
* Decorator that automatically binds a method to its class instance. |
| 18339 |
* This is useful when passing methods as callbacks to preserve the correct `this` context. |
| 18340 |
* |
| 18341 |
* @example |
| 18342 |
* ```typescript |
| 18343 |
* class MyComponent { |
| 18344 |
* @autobind |
| 18345 |
* handleClick() { |
| 18346 |
* console.log(this); // Always refers to MyComponent instance |
| 18347 |
* } |
| 18348 |
* } |
| 18349 |
* |
| 18350 |
* const component = new MyComponent(); |
| 18351 |
* const button = document.createElement('button'); |
| 18352 |
* button.addEventListener('click', component.handleClick); // `this` is correctly bound |
| 18353 |
* ``` |
| 18354 |
*/ function autobind(_target, propertyKey, descriptor) { |
| 18355 |
if (!(0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_0__.isFunction)(descriptor.value)) { |
| 18356 |
throw new TypeError(`@autobind can only be applied to methods, but "${propertyKey}" is not a function`); |
| 18357 |
} |
| 18358 |
const originalMethod = descriptor.value; |
| 18359 |
return { |
| 18360 |
configurable: true, |
| 18361 |
get () { |
| 18362 |
// Create a bound version of the method and cache it on the instance |
| 18363 |
const boundMethod = originalMethod.bind(this); |
| 18364 |
// Define the bound method as a property on the instance |
| 18365 |
// This ensures the same bound function is returned on subsequent accesses |
| 18366 |
Object.defineProperty(this, propertyKey, { |
| 18367 |
value: boundMethod, |
| 18368 |
configurable: true, |
| 18369 |
writable: true |
| 18370 |
}); |
| 18371 |
return boundMethod; |
| 18372 |
} |
| 18373 |
}; |
| 18374 |
} |
| 18375 |
|
| 18376 |
|
| 18377 |
/***/ }), |
| 18378 |
|
| 18379 |
/***/ 49663: |
| 18380 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 18381 |
|
| 18382 |
"use strict"; |
| 18383 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 18384 |
/* harmony export */ normalizeLicense: function() { return /* binding */ normalizeLicense; } |
| 18385 |
/* harmony export */ }); |
| 18386 |
/*! |
| 18387 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 18388 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 18389 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 18390 |
*/ /** |
| 18391 |
* @module helpers/normalize |
| 18392 |
*/ const normalizeLicense = (license, count = 8)=>{ |
| 18393 |
const parts = []; |
| 18394 |
while(license.length){ |
| 18395 |
parts.push(license.substr(0, count)); |
| 18396 |
license = license.substr(count); |
| 18397 |
} |
| 18398 |
parts[1] = parts[1].replace(/./g, '*'); |
| 18399 |
parts[2] = parts[2].replace(/./g, '*'); |
| 18400 |
return parts.join('-'); |
| 18401 |
}; |
| 18402 |
|
| 18403 |
|
| 18404 |
/***/ }), |
| 18405 |
|
| 18406 |
/***/ 49972: |
| 18407 |
/***/ (function(module) { |
| 18408 |
|
| 18409 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M1760 896q14 0 23 9t9 23v64q0 14-9 23t-23 9h-1728q-14 0-23-9t-9-23v-64q0-14 9-23t23-9h1728zm-1277-64q-28-35-51-80-48-97-48-188 0-181 134-309 133-127 393-127 50 0 167 19 66 12 177 48 10 38 21 118 14 123 14 183 0 18-5 45l-12 3-84-6-14-2q-50-149-103-205-88-91-210-91-114 0-182 59-67 58-67 146 0 73 66 140t279 129q69 20 173 66 58 28 95 52h-743zm507 256h411q7 39 7 92 0 111-41 212-23 55-71 104-37 35-109 81-80 48-153 66-80 21-203 21-114 0-195-23l-140-40q-57-16-72-28-8-8-8-22v-13q0-108-2-156-1-30 0-68l2-37v-44l102-2q15 34 30 71t22.5 56 12.5 27q35 57 80 94 43 36 105 57 59 22 132 22 64 0 139-27 77-26 122-86 47-61 47-129 0-84-81-157-34-29-137-71z\"/> </svg>" |
| 18410 |
|
| 18411 |
/***/ }), |
| 18412 |
|
| 18413 |
/***/ 49983: |
| 18414 |
/***/ (function(module) { |
| 18415 |
|
| 18416 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M1728 608v704q0 92-66 158t-158 66h-1216q-92 0-158-66t-66-158v-960q0-92 66-158t158-66h320q92 0 158 66t66 158v32h672q92 0 158 66t66 158z\"/> </svg>" |
| 18417 |
|
| 18418 |
/***/ }), |
| 18419 |
|
| 18420 |
/***/ 49999: |
| 18421 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 18422 |
|
| 18423 |
"use strict"; |
| 18424 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 18425 |
/* harmony export */ UISelect: function() { return /* binding */ UISelect; } |
| 18426 |
/* harmony export */ }); |
| 18427 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 18428 |
/* harmony import */ var _swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(41411); |
| 18429 |
/* harmony import */ var _swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(15366); |
| 18430 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(31635); |
| 18431 |
/* harmony import */ var jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(91672); |
| 18432 |
/* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(7909); |
| 18433 |
/* harmony import */ var jodit_core_ui_form_inputs_input_input__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(65273); |
| 18434 |
/* harmony import */ var jodit_core_ui_form_validators__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(81488); |
| 18435 |
/*! |
| 18436 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 18437 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 18438 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 18439 |
*/ /** |
| 18440 |
* @module ui/form |
| 18441 |
*/ |
| 18442 |
|
| 18443 |
|
| 18444 |
|
| 18445 |
|
| 18446 |
|
| 18447 |
|
| 18448 |
|
| 18449 |
|
| 18450 |
class UISelect extends jodit_core_ui_form_inputs_input_input__WEBPACK_IMPORTED_MODULE_6__.UIInput { |
| 18451 |
/** @override */ className() { |
| 18452 |
return 'UISelect'; |
| 18453 |
} |
| 18454 |
/** @override **/ createContainer(state) { |
| 18455 |
var _state_options; |
| 18456 |
const container = super.createContainer(state); |
| 18457 |
const { j } = this, { nativeInput } = this; |
| 18458 |
const opt = ()=>j.create.element('option'); |
| 18459 |
if (state.placeholder !== undefined) { |
| 18460 |
const option = opt(); |
| 18461 |
option.value = ''; |
| 18462 |
option.text = j.i18n(state.placeholder); |
| 18463 |
nativeInput.add(option); |
| 18464 |
} |
| 18465 |
(_state_options = state.options) === null || _state_options === void 0 ? void 0 : _state_options.forEach((element)=>{ |
| 18466 |
const option = opt(); |
| 18467 |
option.value = element.value.toString(); |
| 18468 |
option.text = j.i18n(element.text); |
| 18469 |
nativeInput.add(option); |
| 18470 |
}); |
| 18471 |
if (state.size && state.size > 0) { |
| 18472 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_5__.attr)(nativeInput, 'size', state.size); |
| 18473 |
} |
| 18474 |
if (state.multiple) { |
| 18475 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_5__.attr)(nativeInput, 'multiple', ''); |
| 18476 |
} |
| 18477 |
return container; |
| 18478 |
} |
| 18479 |
/** @override **/ createNativeInput() { |
| 18480 |
return this.j.create.element('select'); |
| 18481 |
} |
| 18482 |
/** @override **/ updateValidators() { |
| 18483 |
super.updateValidators(); |
| 18484 |
if (this.state.required) { |
| 18485 |
this.validators.delete(jodit_core_ui_form_validators__WEBPACK_IMPORTED_MODULE_7__.inputValidators.required); |
| 18486 |
this.validators.add(jodit_core_ui_form_validators__WEBPACK_IMPORTED_MODULE_7__.selectValidators.required); |
| 18487 |
} |
| 18488 |
} |
| 18489 |
constructor(jodit, state){ |
| 18490 |
super(jodit, state), /** @override */ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "state", (0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_1__._)({}, UISelect.defaultState)); |
| 18491 |
Object.assign(this.state, state); |
| 18492 |
} |
| 18493 |
} |
| 18494 |
/** @override */ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(UISelect, "defaultState", (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_2__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_1__._)({}, jodit_core_ui_form_inputs_input_input__WEBPACK_IMPORTED_MODULE_6__.UIInput.defaultState), { |
| 18495 |
options: [], |
| 18496 |
size: 1, |
| 18497 |
multiple: false |
| 18498 |
})); |
| 18499 |
UISelect = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__.__decorate)([ |
| 18500 |
jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_4__.component |
| 18501 |
], UISelect); |
| 18502 |
|
| 18503 |
|
| 18504 |
/***/ }), |
| 18505 |
|
| 18506 |
/***/ 50083: |
| 18507 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 18508 |
|
| 18509 |
"use strict"; |
| 18510 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 18511 |
/* harmony export */ isValidName: function() { return /* binding */ isValidName; } |
| 18512 |
/* harmony export */ }); |
| 18513 |
/*! |
| 18514 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 18515 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 18516 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 18517 |
*/ /** |
| 18518 |
* @module helpers/checker |
| 18519 |
*/ /** |
| 18520 |
* Check if name has a normal format |
| 18521 |
*/ function isValidName(name) { |
| 18522 |
if (!name.length) { |
| 18523 |
return false; |
| 18524 |
} |
| 18525 |
return !/[^0-9A-Za-zа-яА-ЯЁё\w\-_. ]/.test(name) && name.trim().length > 0; |
| 18526 |
} |
| 18527 |
|
| 18528 |
|
| 18529 |
/***/ }), |
| 18530 |
|
| 18531 |
/***/ 50294: |
| 18532 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 18533 |
|
| 18534 |
"use strict"; |
| 18535 |
/* unused harmony export font */ |
| 18536 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(28077); |
| 18537 |
/* harmony import */ var jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(65946); |
| 18538 |
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(7433); |
| 18539 |
/*! |
| 18540 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 18541 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 18542 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 18543 |
*/ /** |
| 18544 |
* [[include:plugins/font/README.md]] |
| 18545 |
* @packageDocumentation |
| 18546 |
* @module plugins/font |
| 18547 |
*/ |
| 18548 |
|
| 18549 |
|
| 18550 |
/** |
| 18551 |
* Process commands `fontsize` and `fontname` |
| 18552 |
*/ function font(editor) { |
| 18553 |
editor.registerButton({ |
| 18554 |
name: 'font', |
| 18555 |
group: 'font' |
| 18556 |
}).registerButton({ |
| 18557 |
name: 'fontsize', |
| 18558 |
group: 'font' |
| 18559 |
}); |
| 18560 |
const callback = (command, second, third)=>{ |
| 18561 |
switch(command){ |
| 18562 |
case 'fontsize': |
| 18563 |
editor.s.commitStyle({ |
| 18564 |
attributes: { |
| 18565 |
style: { |
| 18566 |
fontSize: (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.normalizeSize)(third, editor.o.defaultFontSizePoints) |
| 18567 |
} |
| 18568 |
} |
| 18569 |
}); |
| 18570 |
break; |
| 18571 |
case 'fontname': |
| 18572 |
editor.s.commitStyle({ |
| 18573 |
attributes: { |
| 18574 |
style: { |
| 18575 |
fontFamily: third |
| 18576 |
} |
| 18577 |
} |
| 18578 |
}); |
| 18579 |
break; |
| 18580 |
} |
| 18581 |
editor.synchronizeValues(); |
| 18582 |
return false; |
| 18583 |
}; |
| 18584 |
editor.registerCommand('fontsize', callback).registerCommand('fontname', callback); |
| 18585 |
} |
| 18586 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_0__.pluginSystem.add('font', font); |
| 18587 |
|
| 18588 |
|
| 18589 |
/***/ }), |
| 18590 |
|
| 18591 |
/***/ 50982: |
| 18592 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 18593 |
|
| 18594 |
"use strict"; |
| 18595 |
/* unused harmony export hotkeys */ |
| 18596 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 18597 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(81937); |
| 18598 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(28077); |
| 18599 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(65946); |
| 18600 |
/* harmony import */ var jodit_core_plugin__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(91206); |
| 18601 |
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(14907); |
| 18602 |
/*! |
| 18603 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 18604 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 18605 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 18606 |
*/ /** |
| 18607 |
* [[include:plugins/hotkeys/README.md]] |
| 18608 |
* @packageDocumentation |
| 18609 |
* @module plugins/hotkeys |
| 18610 |
*/ |
| 18611 |
|
| 18612 |
|
| 18613 |
|
| 18614 |
|
| 18615 |
|
| 18616 |
/** |
| 18617 |
* Allow set hotkey for command or button |
| 18618 |
*/ class hotkeys extends jodit_core_plugin__WEBPACK_IMPORTED_MODULE_4__.Plugin { |
| 18619 |
/** @override */ afterInit(editor) { |
| 18620 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.keys)(editor.o.commandToHotkeys, false).forEach((commandName)=>{ |
| 18621 |
const shortcuts = editor.o.commandToHotkeys[commandName]; |
| 18622 |
if (shortcuts && ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.isArray)(shortcuts) || (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.isString)(shortcuts))) { |
| 18623 |
editor.registerHotkeyToCommand(shortcuts, commandName); |
| 18624 |
} |
| 18625 |
}); |
| 18626 |
let itIsHotkey = false; |
| 18627 |
editor.e.off('.hotkeys').on([ |
| 18628 |
editor.ow, |
| 18629 |
editor.ew |
| 18630 |
], 'keydown.hotkeys', (e)=>{ |
| 18631 |
if (e.key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.KEY_ESC) { |
| 18632 |
return this.j.e.fire('escape', e); |
| 18633 |
} |
| 18634 |
}).on('keydown.hotkeys', (event)=>{ |
| 18635 |
const shortcut = this.onKeyPress(event); |
| 18636 |
const stop = { |
| 18637 |
shouldStop: true |
| 18638 |
}; |
| 18639 |
const resultOfFire = this.j.e.fire(shortcut + '.hotkey', event.type, stop); |
| 18640 |
if (resultOfFire === false) { |
| 18641 |
if (stop.shouldStop) { |
| 18642 |
itIsHotkey = true; |
| 18643 |
editor.e.stopPropagation('keydown'); |
| 18644 |
return false; |
| 18645 |
} else { |
| 18646 |
event.preventDefault(); |
| 18647 |
} |
| 18648 |
} |
| 18649 |
}, { |
| 18650 |
top: true |
| 18651 |
}).on('keyup.hotkeys', ()=>{ |
| 18652 |
if (itIsHotkey) { |
| 18653 |
itIsHotkey = false; |
| 18654 |
editor.e.stopPropagation('keyup'); |
| 18655 |
return false; |
| 18656 |
} |
| 18657 |
}, { |
| 18658 |
top: true |
| 18659 |
}); |
| 18660 |
} |
| 18661 |
/** @override */ beforeDestruct(jodit) { |
| 18662 |
if (jodit.events) { |
| 18663 |
jodit.e.off('.hotkeys'); |
| 18664 |
} |
| 18665 |
} |
| 18666 |
constructor(...args){ |
| 18667 |
super(...args), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "onKeyPress", (event)=>{ |
| 18668 |
const special = this.specialKeys[event.which]; |
| 18669 |
const character = (event.key || String.fromCharCode(event.which)).toLowerCase(); |
| 18670 |
const modif = [ |
| 18671 |
special || character |
| 18672 |
]; |
| 18673 |
[ |
| 18674 |
'alt', |
| 18675 |
'ctrl', |
| 18676 |
'shift', |
| 18677 |
'meta' |
| 18678 |
].forEach((specialKey)=>{ |
| 18679 |
if (event[specialKey + 'Key'] && special !== specialKey) { |
| 18680 |
modif.push(specialKey); |
| 18681 |
} |
| 18682 |
}); |
| 18683 |
return (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.normalizeKeyAliases)(modif.join('+')); |
| 18684 |
}), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "specialKeys", { |
| 18685 |
8: 'backspace', |
| 18686 |
9: 'tab', |
| 18687 |
10: 'return', |
| 18688 |
13: 'return', |
| 18689 |
16: 'shift', |
| 18690 |
17: 'ctrl', |
| 18691 |
18: 'alt', |
| 18692 |
19: 'pause', |
| 18693 |
20: 'capslock', |
| 18694 |
27: 'esc', |
| 18695 |
32: 'space', |
| 18696 |
33: 'pageup', |
| 18697 |
34: 'pagedown', |
| 18698 |
35: 'end', |
| 18699 |
36: 'home', |
| 18700 |
37: 'left', |
| 18701 |
38: 'up', |
| 18702 |
39: 'right', |
| 18703 |
40: 'down', |
| 18704 |
45: 'insert', |
| 18705 |
46: 'del', |
| 18706 |
59: ';', |
| 18707 |
61: '=', |
| 18708 |
91: 'meta', |
| 18709 |
96: '0', |
| 18710 |
97: '1', |
| 18711 |
98: '2', |
| 18712 |
99: '3', |
| 18713 |
100: '4', |
| 18714 |
101: '5', |
| 18715 |
102: '6', |
| 18716 |
103: '7', |
| 18717 |
104: '8', |
| 18718 |
105: '9', |
| 18719 |
106: '*', |
| 18720 |
107: '+', |
| 18721 |
109: '-', |
| 18722 |
110: '.', |
| 18723 |
111: '/', |
| 18724 |
112: 'f1', |
| 18725 |
113: 'f2', |
| 18726 |
114: 'f3', |
| 18727 |
115: 'f4', |
| 18728 |
116: 'f5', |
| 18729 |
117: 'f6', |
| 18730 |
118: 'f7', |
| 18731 |
119: 'f8', |
| 18732 |
120: 'f9', |
| 18733 |
121: 'f10', |
| 18734 |
122: 'f11', |
| 18735 |
123: 'f12', |
| 18736 |
144: 'numlock', |
| 18737 |
145: 'scroll', |
| 18738 |
173: '-', |
| 18739 |
186: ';', |
| 18740 |
187: '=', |
| 18741 |
188: ',', |
| 18742 |
189: '-', |
| 18743 |
190: '.', |
| 18744 |
191: '/', |
| 18745 |
192: '`', |
| 18746 |
219: '[', |
| 18747 |
220: '\\', |
| 18748 |
221: ']', |
| 18749 |
222: "'" |
| 18750 |
}); |
| 18751 |
} |
| 18752 |
} |
| 18753 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_2__.pluginSystem.add('hotkeys', hotkeys); |
| 18754 |
|
| 18755 |
|
| 18756 |
/***/ }), |
| 18757 |
|
| 18758 |
/***/ 51034: |
| 18759 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 18760 |
|
| 18761 |
"use strict"; |
| 18762 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5266); |
| 18763 |
/*! |
| 18764 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 18765 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 18766 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 18767 |
*/ /** |
| 18768 |
* @module plugins/image-processor |
| 18769 |
*/ |
| 18770 |
jodit_config__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.imageProcessor = { |
| 18771 |
replaceDataURIToBlobIdInView: true |
| 18772 |
}; |
| 18773 |
|
| 18774 |
|
| 18775 |
/***/ }), |
| 18776 |
|
| 18777 |
/***/ 51116: |
| 18778 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 18779 |
|
| 18780 |
"use strict"; |
| 18781 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 18782 |
/* harmony export */ Popup: function() { return /* binding */ Popup; } |
| 18783 |
/* harmony export */ }); |
| 18784 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 18785 |
/* harmony import */ var _swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(41411); |
| 18786 |
/* harmony import */ var _swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(15366); |
| 18787 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(31635); |
| 18788 |
/* harmony import */ var jodit_core_component_component__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(80251); |
| 18789 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(84839); |
| 18790 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(23211); |
| 18791 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(28077); |
| 18792 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(65946); |
| 18793 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(28712); |
| 18794 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_9__); |
| 18795 |
/* harmony import */ var jodit_core_ui_element__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(96007); |
| 18796 |
/* harmony import */ var jodit_core_ui_group_group__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(63468); |
| 18797 |
/*! |
| 18798 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 18799 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 18800 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 18801 |
*/ /** |
| 18802 |
* [[include:core/ui/popup/README.md]] |
| 18803 |
* @packageDocumentation |
| 18804 |
* @module ui/popup |
| 18805 |
*/ |
| 18806 |
|
| 18807 |
|
| 18808 |
|
| 18809 |
|
| 18810 |
|
| 18811 |
|
| 18812 |
|
| 18813 |
|
| 18814 |
|
| 18815 |
|
| 18816 |
|
| 18817 |
|
| 18818 |
const EVENTS_FOR_AUTOCLOSE = [ |
| 18819 |
'escape', |
| 18820 |
'cut', |
| 18821 |
'delete', |
| 18822 |
'backSpaceAfterDelete', |
| 18823 |
'beforeCommandDelete' |
| 18824 |
]; |
| 18825 |
class Popup extends jodit_core_ui_group_group__WEBPACK_IMPORTED_MODULE_11__.UIGroup { |
| 18826 |
className() { |
| 18827 |
return 'Popup'; |
| 18828 |
} |
| 18829 |
appendChildToContainer(childContainer) { |
| 18830 |
const content = this.getElm('content'); |
| 18831 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_9__.assert)(content, 'Content element should exist'); |
| 18832 |
content.appendChild(childContainer); |
| 18833 |
} |
| 18834 |
updateParentElement(target) { |
| 18835 |
if (target !== this && jodit_core_component_component__WEBPACK_IMPORTED_MODULE_4__.Component.isInstanceOf(target, Popup)) { |
| 18836 |
this.__childrenPopups.forEach((popup)=>{ |
| 18837 |
if (!target.closest(popup) && popup.isOpened) { |
| 18838 |
popup.close(); |
| 18839 |
} |
| 18840 |
}); |
| 18841 |
if (!this.__childrenPopups.has(target)) { |
| 18842 |
this.j.e.on(target, 'beforeClose', ()=>{ |
| 18843 |
this.__childrenPopups.delete(target); |
| 18844 |
}); |
| 18845 |
} |
| 18846 |
this.__childrenPopups.add(target); |
| 18847 |
} |
| 18848 |
return super.updateParentElement(target); |
| 18849 |
} |
| 18850 |
/** |
| 18851 |
* Set popup content |
| 18852 |
*/ setContent(content) { |
| 18853 |
if (this.allChildren.length) { |
| 18854 |
throw new Error('Remove children'); |
| 18855 |
} |
| 18856 |
if (jodit_core_component_component__WEBPACK_IMPORTED_MODULE_4__.Component.isInstanceOf(content, jodit_core_ui_element__WEBPACK_IMPORTED_MODULE_10__.UIElement)) { |
| 18857 |
this.append(content); |
| 18858 |
} else { |
| 18859 |
const elm = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_8__.isString)(content) ? this.j.c.fromHTML(content) : content; |
| 18860 |
this.appendChildToContainer(elm); |
| 18861 |
} |
| 18862 |
this.updatePosition(); |
| 18863 |
return this; |
| 18864 |
} |
| 18865 |
/** |
| 18866 |
* Open popup near with some bound |
| 18867 |
*/ open(getBound, keepPosition = false, parentContainer) { |
| 18868 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_8__.markOwner)(this.jodit, this.container); |
| 18869 |
this.container.classList.add(`jodit_theme_${this.jodit.o.theme}`); |
| 18870 |
this.__calculateZIndex(); |
| 18871 |
this.isOpened = true; |
| 18872 |
this.__addGlobalListeners(); |
| 18873 |
this.__targetBound = !keepPosition ? getBound : this.getKeepBound(getBound); |
| 18874 |
if (parentContainer) { |
| 18875 |
parentContainer.appendChild(this.container); |
| 18876 |
} else { |
| 18877 |
const popupContainer = (0,jodit_core_global__WEBPACK_IMPORTED_MODULE_7__.getContainer)(this.jodit, Popup); |
| 18878 |
if (parentContainer !== this.container.parentElement) { |
| 18879 |
popupContainer.appendChild(this.container); |
| 18880 |
} |
| 18881 |
} |
| 18882 |
this.updatePosition(); |
| 18883 |
this.j.e.fire(this, 'afterOpen'); |
| 18884 |
this.j.e.fire('afterOpenPopup', this); |
| 18885 |
return this; |
| 18886 |
} |
| 18887 |
__calculateZIndex() { |
| 18888 |
if (this.container.style.zIndex) { |
| 18889 |
return; |
| 18890 |
} |
| 18891 |
const checkView = (view)=>{ |
| 18892 |
const zIndex = view.container.style.zIndex || view.o.zIndex; |
| 18893 |
if (zIndex) { |
| 18894 |
this.setZIndex(1 + parseInt(zIndex.toString(), 10)); |
| 18895 |
return true; |
| 18896 |
} |
| 18897 |
return false; |
| 18898 |
}; |
| 18899 |
const { j } = this; |
| 18900 |
if (checkView(j)) { |
| 18901 |
return; |
| 18902 |
} |
| 18903 |
let pe = this.parentElement; |
| 18904 |
while(pe){ |
| 18905 |
if (checkView(pe.j)) { |
| 18906 |
return; |
| 18907 |
} |
| 18908 |
if (pe.container.style.zIndex) { |
| 18909 |
this.setZIndex(1 + parseInt(pe.container.style.zIndex.toString(), 10)); |
| 18910 |
return; |
| 18911 |
} |
| 18912 |
if (!pe.parentElement && pe.container.parentElement) { |
| 18913 |
const elm = jodit_core_ui_element__WEBPACK_IMPORTED_MODULE_10__.UIElement.closestElement(pe.container.parentElement, jodit_core_ui_element__WEBPACK_IMPORTED_MODULE_10__.UIElement); |
| 18914 |
if (elm) { |
| 18915 |
pe = elm; |
| 18916 |
continue; |
| 18917 |
} |
| 18918 |
} |
| 18919 |
pe = pe.parentElement; |
| 18920 |
} |
| 18921 |
} |
| 18922 |
/** |
| 18923 |
* Calculate static bound for point |
| 18924 |
*/ getKeepBound(getBound) { |
| 18925 |
const oldBound = getBound(); |
| 18926 |
const elmUnderCursor = this.od.elementFromPoint(oldBound.left, oldBound.top); |
| 18927 |
if (!elmUnderCursor) { |
| 18928 |
return getBound; |
| 18929 |
} |
| 18930 |
const element = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_6__.Dom.isHTMLElement(elmUnderCursor) ? elmUnderCursor : elmUnderCursor.parentElement; |
| 18931 |
const oldPos = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_8__.position)(element, this.j); |
| 18932 |
return ()=>{ |
| 18933 |
const bound = getBound(); |
| 18934 |
const newPos = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_8__.position)(element, this.j); |
| 18935 |
return (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_2__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_1__._)({}, bound), { |
| 18936 |
top: bound.top + (newPos.top - oldPos.top), |
| 18937 |
left: bound.left + (newPos.left - oldPos.left) |
| 18938 |
}); |
| 18939 |
}; |
| 18940 |
} |
| 18941 |
/** |
| 18942 |
* Update container position |
| 18943 |
*/ updatePosition() { |
| 18944 |
if (!this.isOpened) { |
| 18945 |
return this; |
| 18946 |
} |
| 18947 |
const [pos, strategy] = this.__calculatePosition(this.__targetBound(), this.viewBound(), (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_8__.position)(this.container, this.j)); |
| 18948 |
this.setMod('strategy', strategy); |
| 18949 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_8__.css)(this.container, { |
| 18950 |
left: pos.left, |
| 18951 |
top: pos.top |
| 18952 |
}); |
| 18953 |
this.__childrenPopups.forEach((popup)=>popup.updatePosition()); |
| 18954 |
return this; |
| 18955 |
} |
| 18956 |
__throttleUpdatePosition() { |
| 18957 |
this.updatePosition(); |
| 18958 |
} |
| 18959 |
/** |
| 18960 |
* Calculate start point |
| 18961 |
*/ __calculatePosition(target, view, container, defaultStrategy = this.strategy) { |
| 18962 |
const x = { |
| 18963 |
left: target.left, |
| 18964 |
right: target.left - (container.width - target.width) |
| 18965 |
}, y = { |
| 18966 |
bottom: target.top + target.height, |
| 18967 |
top: target.top - container.height |
| 18968 |
}; |
| 18969 |
const list = Object.keys(x).reduce((keys, xKey)=>keys.concat(Object.keys(y).map((yKey)=>`${xKey}${(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_8__.ucfirst)(yKey)}`)), []); |
| 18970 |
const getPointByStrategy = (strategy)=>{ |
| 18971 |
const [xKey, yKey] = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_8__.kebabCase)(strategy).split('-'); |
| 18972 |
return { |
| 18973 |
left: x[xKey], |
| 18974 |
top: y[yKey], |
| 18975 |
width: container.width, |
| 18976 |
height: container.height |
| 18977 |
}; |
| 18978 |
}; |
| 18979 |
const getMatchStrategy = (inBox)=>{ |
| 18980 |
let strategy = null; |
| 18981 |
if (Popup.boxInView(getPointByStrategy(defaultStrategy), inBox)) { |
| 18982 |
strategy = defaultStrategy; |
| 18983 |
} else { |
| 18984 |
strategy = list.find((key)=>{ |
| 18985 |
if (Popup.boxInView(getPointByStrategy(key), inBox)) { |
| 18986 |
return key; |
| 18987 |
} |
| 18988 |
return; |
| 18989 |
}) || null; |
| 18990 |
} |
| 18991 |
return strategy; |
| 18992 |
}; |
| 18993 |
// Try to find match position inside Jodit.container |
| 18994 |
let strategy = getMatchStrategy((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_8__.position)(this.j.container, this.j)); |
| 18995 |
// If not found or is not inside window view |
| 18996 |
if (!strategy || !Popup.boxInView(getPointByStrategy(strategy), view)) { |
| 18997 |
// Find match strategy inside window view |
| 18998 |
strategy = getMatchStrategy(view) || strategy || defaultStrategy; |
| 18999 |
} |
| 19000 |
return [ |
| 19001 |
getPointByStrategy(strategy), |
| 19002 |
strategy |
| 19003 |
]; |
| 19004 |
} |
| 19005 |
/** |
| 19006 |
* Check if one box is inside second |
| 19007 |
*/ static boxInView(box, view) { |
| 19008 |
const accuracy = 2; |
| 19009 |
return box.top - view.top >= -accuracy && box.left - view.left >= -accuracy && view.top + view.height - (box.top + box.height) >= -accuracy && view.left + view.width - (box.left + box.width) >= -accuracy; |
| 19010 |
} |
| 19011 |
/** |
| 19012 |
* Close popup |
| 19013 |
*/ close() { |
| 19014 |
if (!this.isOpened) { |
| 19015 |
return this; |
| 19016 |
} |
| 19017 |
this.isOpened = false; |
| 19018 |
this.__childrenPopups.forEach((popup)=>popup.close()); |
| 19019 |
this.j.e.fire(this, 'beforeClose'); |
| 19020 |
this.j.e.fire('beforePopupClose', this); |
| 19021 |
this.__removeGlobalListeners(); |
| 19022 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_6__.Dom.safeRemove(this.container); |
| 19023 |
return this; |
| 19024 |
} |
| 19025 |
/** |
| 19026 |
* Close popup if click was in outside |
| 19027 |
*/ __closeOnOutsideClick(e) { |
| 19028 |
if (!this.isOpened || this.isOwnClick(e)) { |
| 19029 |
return; |
| 19030 |
} |
| 19031 |
this.close(); |
| 19032 |
} |
| 19033 |
isOwnClick(e) { |
| 19034 |
if (!e.target) { |
| 19035 |
return false; |
| 19036 |
} |
| 19037 |
const box = jodit_core_ui_element__WEBPACK_IMPORTED_MODULE_10__.UIElement.closestElement(e.target, Popup); |
| 19038 |
return Boolean(box && (this === box || box.closest(this))); |
| 19039 |
} |
| 19040 |
__addGlobalListeners() { |
| 19041 |
const up = this.__throttleUpdatePosition, ow = this.ow; |
| 19042 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_7__.eventEmitter.on('closeAllPopups', this.close); |
| 19043 |
if (this.smart) { |
| 19044 |
this.j.e.on(EVENTS_FOR_AUTOCLOSE, this.close).on('mousedown touchstart', this.__closeOnOutsideClick).on(ow, 'mousedown touchstart', this.__closeOnOutsideClick); |
| 19045 |
} |
| 19046 |
this.j.e.on('closeAllPopups', this.close).on('resize', up).on(this.container, 'scroll mousewheel', up).on(ow, 'scroll', up).on(ow, 'resize', up); |
| 19047 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_6__.Dom.up(this.j.container, (box)=>{ |
| 19048 |
box && this.j.e.on(box, 'scroll mousewheel', up); |
| 19049 |
}); |
| 19050 |
} |
| 19051 |
__removeGlobalListeners() { |
| 19052 |
const up = this.__throttleUpdatePosition, ow = this.ow; |
| 19053 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_7__.eventEmitter.off('closeAllPopups', this.close); |
| 19054 |
if (this.smart) { |
| 19055 |
this.j.e.off(EVENTS_FOR_AUTOCLOSE, this.close).off('mousedown touchstart', this.__closeOnOutsideClick).off(ow, 'mousedown touchstart', this.__closeOnOutsideClick); |
| 19056 |
} |
| 19057 |
this.j.e.off('closeAllPopups', this.close).off('resize', up).off(this.container, 'scroll mousewheel', up).off(ow, 'scroll', up).off(ow, 'resize', up); |
| 19058 |
if (this.j.container.isConnected) { |
| 19059 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_6__.Dom.up(this.j.container, (box)=>{ |
| 19060 |
box && this.j.e.off(box, 'scroll mousewheel', up); |
| 19061 |
}); |
| 19062 |
} |
| 19063 |
} |
| 19064 |
/** |
| 19065 |
* Set ZIndex |
| 19066 |
*/ setZIndex(index) { |
| 19067 |
this.container.style.zIndex = index.toString(); |
| 19068 |
} |
| 19069 |
render() { |
| 19070 |
return `<div> |
| 19071 |
<div class="&__content"></div> |
| 19072 |
</div>`; |
| 19073 |
} |
| 19074 |
/** @override **/ destruct() { |
| 19075 |
this.close(); |
| 19076 |
return super.destruct(); |
| 19077 |
} |
| 19078 |
constructor(jodit, smart = true){ |
| 19079 |
super(jodit), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "smart", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "isOpened", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "strategy", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "viewBound", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__targetBound", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__childrenPopups", void 0), this.smart = smart, this.isOpened = false, this.strategy = 'leftBottom', this.viewBound = ()=>({ |
| 19080 |
left: 0, |
| 19081 |
top: 0, |
| 19082 |
width: this.ow.innerWidth, |
| 19083 |
height: this.ow.innerHeight |
| 19084 |
}), this.__childrenPopups = new Set(); |
| 19085 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_8__.attr)(this.container, 'role', 'popup'); |
| 19086 |
} |
| 19087 |
} |
| 19088 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__.__decorate)([ |
| 19089 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_5__.autobind |
| 19090 |
], Popup.prototype, "updatePosition", null); |
| 19091 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__.__decorate)([ |
| 19092 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_5__.throttle)(10), |
| 19093 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_5__.autobind |
| 19094 |
], Popup.prototype, "__throttleUpdatePosition", null); |
| 19095 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__.__decorate)([ |
| 19096 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_5__.autobind |
| 19097 |
], Popup.prototype, "close", null); |
| 19098 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__.__decorate)([ |
| 19099 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_5__.autobind |
| 19100 |
], Popup.prototype, "__closeOnOutsideClick", null); |
| 19101 |
|
| 19102 |
|
| 19103 |
/***/ }), |
| 19104 |
|
| 19105 |
/***/ 51640: |
| 19106 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 19107 |
|
| 19108 |
"use strict"; |
| 19109 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 19110 |
/* harmony export */ FiniteStateMachine: function() { return /* reexport safe */ _finite_state_machine__WEBPACK_IMPORTED_MODULE_1__.FiniteStateMachine; }, |
| 19111 |
/* harmony export */ extractSelectedPart: function() { return /* reexport safe */ _extract__WEBPACK_IMPORTED_MODULE_0__.extractSelectedPart; }, |
| 19112 |
/* harmony export */ getSuitChild: function() { return /* reexport safe */ _get_suit_child__WEBPACK_IMPORTED_MODULE_2__.getSuitChild; }, |
| 19113 |
/* harmony export */ getSuitParent: function() { return /* reexport safe */ _get_suit_parent__WEBPACK_IMPORTED_MODULE_3__.getSuitParent; }, |
| 19114 |
/* harmony export */ isInsideInvisibleElement: function() { return /* reexport safe */ _is_inside_invisible_element__WEBPACK_IMPORTED_MODULE_5__.isInsideInvisibleElement; }, |
| 19115 |
/* harmony export */ suitableClosest: function() { return /* reexport safe */ _is_suit_element__WEBPACK_IMPORTED_MODULE_8__.suitableClosest; }, |
| 19116 |
/* harmony export */ toggleAttributes: function() { return /* reexport safe */ _toggle_attributes__WEBPACK_IMPORTED_MODULE_11__.toggleAttributes; }, |
| 19117 |
/* harmony export */ toggleOrderedList: function() { return /* reexport safe */ _list_toggle_ordered_list__WEBPACK_IMPORTED_MODULE_9__.toggleOrderedList; }, |
| 19118 |
/* harmony export */ unwrapChildren: function() { return /* reexport safe */ _unwrap_children__WEBPACK_IMPORTED_MODULE_12__.unwrapChildren; }, |
| 19119 |
/* harmony export */ wrap: function() { return /* reexport safe */ _wrap__WEBPACK_IMPORTED_MODULE_13__.wrap; } |
| 19120 |
/* harmony export */ }); |
| 19121 |
/* harmony import */ var _extract__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(17481); |
| 19122 |
/* harmony import */ var _finite_state_machine__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(48729); |
| 19123 |
/* harmony import */ var _get_suit_child__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(10171); |
| 19124 |
/* harmony import */ var _get_suit_parent__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(19549); |
| 19125 |
/* harmony import */ var _has_same_style__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(9703); |
| 19126 |
/* harmony import */ var _is_inside_invisible_element__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(39608); |
| 19127 |
/* harmony import */ var _is_normal_node__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(83653); |
| 19128 |
/* harmony import */ var _is_same_attributes__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(95971); |
| 19129 |
/* harmony import */ var _is_suit_element__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(73019); |
| 19130 |
/* harmony import */ var _list_toggle_ordered_list__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(34582); |
| 19131 |
/* harmony import */ var _list_wrap_list__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(97110); |
| 19132 |
/* harmony import */ var _toggle_attributes__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(82794); |
| 19133 |
/* harmony import */ var _unwrap_children__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(89081); |
| 19134 |
/* harmony import */ var _wrap__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(73154); |
| 19135 |
/* harmony import */ var _wrap_unwrapped_text__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(83335); |
| 19136 |
/*! |
| 19137 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 19138 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 19139 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 19140 |
*/ |
| 19141 |
|
| 19142 |
|
| 19143 |
|
| 19144 |
|
| 19145 |
|
| 19146 |
|
| 19147 |
|
| 19148 |
|
| 19149 |
|
| 19150 |
|
| 19151 |
|
| 19152 |
|
| 19153 |
|
| 19154 |
|
| 19155 |
|
| 19156 |
|
| 19157 |
/***/ }), |
| 19158 |
|
| 19159 |
/***/ 51676: |
| 19160 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 19161 |
|
| 19162 |
"use strict"; |
| 19163 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 19164 |
/* harmony export */ cache: function() { return /* binding */ cache; }, |
| 19165 |
/* harmony export */ cacheHTML: function() { return /* binding */ cacheHTML; }, |
| 19166 |
/* harmony export */ cached: function() { return /* binding */ cached; } |
| 19167 |
/* harmony export */ }); |
| 19168 |
/* harmony import */ var jodit_core_component_statuses__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(69364); |
| 19169 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(23211); |
| 19170 |
/* harmony import */ var jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(28686); |
| 19171 |
/* harmony import */ var jodit_core_helpers_utils_error_error__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(38027); |
| 19172 |
/*! |
| 19173 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 19174 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 19175 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 19176 |
*/ /** |
| 19177 |
* [[include:core/decorators/cache/README.md]] |
| 19178 |
* @packageDocumentation |
| 19179 |
* @module decorators/cache |
| 19180 |
*/ |
| 19181 |
|
| 19182 |
|
| 19183 |
|
| 19184 |
/** |
| 19185 |
* Retrieves a cached property value from an object if it exists; otherwise, returns `null`. |
| 19186 |
* |
| 19187 |
* This utility is particularly useful when working with properties that are lazily initialized |
| 19188 |
* or dynamically created, such as getters or cached computations. It ensures you can safely |
| 19189 |
* access the value without triggering initialization or creating a new instance. |
| 19190 |
* |
| 19191 |
* ### Usage Example: |
| 19192 |
* ```typescript |
| 19193 |
* import type { IUIElement } from "jodit"; |
| 19194 |
* |
| 19195 |
* const { component, cache, cached } = Jodit.decorators; |
| 19196 |
* const { UIElement } = Jodit.modules; |
| 19197 |
* |
| 19198 |
* @component |
| 19199 |
* class SomeComponent extends UIElement { |
| 19200 |
* @cache |
| 19201 |
* get someElement(): IUIElement { |
| 19202 |
* return new UIElement(this.jodit); |
| 19203 |
* } |
| 19204 |
* |
| 19205 |
* destruct() { |
| 19206 |
* // Use the cached utility to clean up only if the property is initialized |
| 19207 |
* cached(this, 'someElement')?.destruct(); |
| 19208 |
* super.destruct(); |
| 19209 |
* } |
| 19210 |
* } |
| 19211 |
* ``` |
| 19212 |
* |
| 19213 |
* @param object - The object containing the property to check. |
| 19214 |
* @param property - The name of the property to retrieve from the cache. |
| 19215 |
* @returns The cached value of the property if it exists; otherwise, `null`. |
| 19216 |
* |
| 19217 |
* ### Notes: |
| 19218 |
* - If the property is defined as a getter, the function will return `null` |
| 19219 |
* instead of invoking the getter. |
| 19220 |
* - This function is non-destructive and does not alter the object's state. |
| 19221 |
*/ function cached(object, property) { |
| 19222 |
const descriptor = Object.getOwnPropertyDescriptor(object, property); |
| 19223 |
if (!descriptor || (0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_2__.isFunction)(descriptor.get)) { |
| 19224 |
return null; |
| 19225 |
} |
| 19226 |
return descriptor.value; |
| 19227 |
} |
| 19228 |
/** |
| 19229 |
* A decorator that caches the result of a getter method. Once the getter is accessed for the first time, |
| 19230 |
* its computed value is stored as a property of the object. Subsequent accesses return the cached value |
| 19231 |
* without recalculating it, improving performance and avoiding redundant computations. |
| 19232 |
* |
| 19233 |
* ### Key Features: |
| 19234 |
* - **Lazy Initialization**: The original getter is invoked only once, the first time the property is accessed. |
| 19235 |
* - **Immutability**: After caching, the value is stored as a non-writable, non-configurable property, preventing accidental modifications. |
| 19236 |
* - **Conditional Caching**: If the returned value has a property `noCache` set to `true`, the caching mechanism is bypassed, and the getter is invoked each time. |
| 19237 |
* |
| 19238 |
* ### Usage Example 1: Basic Caching |
| 19239 |
* ```typescript |
| 19240 |
* import { cache } from './decorators'; |
| 19241 |
* |
| 19242 |
* class Example { |
| 19243 |
* private counter = 0; |
| 19244 |
* |
| 19245 |
* @cache |
| 19246 |
* get expensiveComputation(): number { |
| 19247 |
* console.log('Calculating...'); |
| 19248 |
* return ++this.counter; |
| 19249 |
* } |
| 19250 |
* } |
| 19251 |
* |
| 19252 |
* const instance = new Example(); |
| 19253 |
* console.log(instance.expensiveComputation); // Logs "Calculating..." and returns 1 |
| 19254 |
* console.log(instance.expensiveComputation); // Returns 1 (cached value, no calculation) |
| 19255 |
* ``` |
| 19256 |
* |
| 19257 |
* ### Usage Example 2: Integration with Cached Utilities |
| 19258 |
* ```typescript |
| 19259 |
* import { cache, cached } from './decorators'; |
| 19260 |
* import type { IUIElement } from "jodit"; |
| 19261 |
* |
| 19262 |
* const { component } = Jodit.decorators; |
| 19263 |
* const { UIElement } = Jodit.modules; |
| 19264 |
* |
| 19265 |
* @component |
| 19266 |
* class SomeComponent extends UIElement { |
| 19267 |
* @cache |
| 19268 |
* get someElement(): IUIElement { |
| 19269 |
* return new UIElement(this.jodit); |
| 19270 |
* } |
| 19271 |
* |
| 19272 |
* destruct() { |
| 19273 |
* // Use the cached utility to clean up only if the property is initialized |
| 19274 |
* cached(this, 'someElement')?.destruct(); |
| 19275 |
* super.destruct(); |
| 19276 |
* } |
| 19277 |
* } |
| 19278 |
* ``` |
| 19279 |
* |
| 19280 |
* @param _ - The target object (not used directly). |
| 19281 |
* @param name - The name of the property to decorate. |
| 19282 |
* @param descriptor - The property descriptor, which must include a getter method. |
| 19283 |
* @throws Will throw an error if the descriptor does not include a getter. |
| 19284 |
* |
| 19285 |
* ### Notes: |
| 19286 |
* - **Performance**: Ideal for properties that are computationally expensive and do not change after the initial computation. |
| 19287 |
* - **Flexibility**: Supports conditional caching via the `noCache` property in the returned value. |
| 19288 |
* - **Compatibility**: Designed to work seamlessly with objects and classes in TypeScript or JavaScript. |
| 19289 |
*/ function cache(_, name, descriptor) { |
| 19290 |
const getter = descriptor.get; |
| 19291 |
if (!getter) { |
| 19292 |
throw (0,jodit_core_helpers_utils_error_error__WEBPACK_IMPORTED_MODULE_3__.error)('Getter property descriptor expected'); |
| 19293 |
} |
| 19294 |
descriptor.get = function() { |
| 19295 |
const value = getter.call(this); |
| 19296 |
if (value && value.noCache === true) { |
| 19297 |
return value; |
| 19298 |
} |
| 19299 |
Object.defineProperty(this, name, { |
| 19300 |
configurable: descriptor.configurable, |
| 19301 |
enumerable: descriptor.enumerable, |
| 19302 |
writable: false, |
| 19303 |
value |
| 19304 |
}); |
| 19305 |
return value; |
| 19306 |
}; |
| 19307 |
} |
| 19308 |
function cacheHTML(target, _, descriptor) { |
| 19309 |
const fn = descriptor.value; |
| 19310 |
if (!(0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_2__.isFunction)(fn)) { |
| 19311 |
throw (0,jodit_core_helpers_utils_error_error__WEBPACK_IMPORTED_MODULE_3__.error)('Handler must be a Function'); |
| 19312 |
} |
| 19313 |
let useCache = true; |
| 19314 |
const cached = new WeakMap(); |
| 19315 |
descriptor.value = function(...attrs) { |
| 19316 |
if (useCache && cached.has(this.constructor)) { |
| 19317 |
var _cached_get; |
| 19318 |
return (_cached_get = cached.get(this.constructor)) === null || _cached_get === void 0 ? void 0 : _cached_get.cloneNode(true); |
| 19319 |
} |
| 19320 |
const value = fn.apply(this, attrs); |
| 19321 |
if (useCache && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isElement(value)) { |
| 19322 |
cached.set(this.constructor, value); |
| 19323 |
} |
| 19324 |
return useCache ? value.cloneNode(true) : value; |
| 19325 |
}; |
| 19326 |
target.hookStatus(jodit_core_component_statuses__WEBPACK_IMPORTED_MODULE_0__.STATUSES.ready, (component)=>{ |
| 19327 |
const view = (0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_2__.isViewObject)(component) ? component : component.jodit; |
| 19328 |
useCache = Boolean(view.options.cache); |
| 19329 |
}); |
| 19330 |
} |
| 19331 |
|
| 19332 |
|
| 19333 |
/***/ }), |
| 19334 |
|
| 19335 |
/***/ 51822: |
| 19336 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 19337 |
|
| 19338 |
"use strict"; |
| 19339 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5266); |
| 19340 |
/*! |
| 19341 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 19342 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 19343 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 19344 |
*/ /** |
| 19345 |
* @module plugins/resize-cells |
| 19346 |
*/ |
| 19347 |
jodit_config__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.tableAllowCellResize = true; |
| 19348 |
|
| 19349 |
|
| 19350 |
/***/ }), |
| 19351 |
|
| 19352 |
/***/ 51957: |
| 19353 |
/***/ (function(module) { |
| 19354 |
|
| 19355 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 48 48\"> <path d=\"M6 42h4v-4h-4v4zm4-28h-4v4h4v-4zm-4 20h4v-4h-4v4zm8 8h4v-4h-4v4zm-4-36h-4v4h4v-4zm8 0h-4v4h4v-4zm16 0h-4v4h4v-4zm-8 8h-4v4h4v-4zm0-8h-4v4h4v-4zm12 28h4v-4h-4v4zm-16 8h4v-4h-4v4zm-16-16h36v-4h-36v4zm32-20v4h4v-4h-4zm0 12h4v-4h-4v4zm-16 16h4v-4h-4v4zm8 8h4v-4h-4v4zm8 0h4v-4h-4v4z\"/> <path d=\"M0 0h48v48h-48z\" fill=\"none\"/> </svg>" |
| 19356 |
|
| 19357 |
/***/ }), |
| 19358 |
|
| 19359 |
/***/ 52100: |
| 19360 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 19361 |
|
| 19362 |
"use strict"; |
| 19363 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 19364 |
/* harmony export */ isPromise: function() { return /* binding */ isPromise; } |
| 19365 |
/* harmony export */ }); |
| 19366 |
/*! |
| 19367 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 19368 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 19369 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 19370 |
*/ /** |
| 19371 |
* @module helpers/checker |
| 19372 |
*/ function isPromise(val) { |
| 19373 |
return val && typeof val.then === 'function'; |
| 19374 |
} |
| 19375 |
|
| 19376 |
|
| 19377 |
/***/ }), |
| 19378 |
|
| 19379 |
/***/ 52144: |
| 19380 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 19381 |
|
| 19382 |
"use strict"; |
| 19383 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 19384 |
/* harmony export */ set: function() { return /* binding */ set; } |
| 19385 |
/* harmony export */ }); |
| 19386 |
/* harmony import */ var jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(17312); |
| 19387 |
/* harmony import */ var jodit_core_helpers_checker_is_numeric__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(70222); |
| 19388 |
/* harmony import */ var jodit_core_helpers_checker_is_plain_object__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(62101); |
| 19389 |
/* harmony import */ var jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(85932); |
| 19390 |
/*! |
| 19391 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 19392 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 19393 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 19394 |
*/ /** |
| 19395 |
* @module helpers/utils |
| 19396 |
*/ |
| 19397 |
|
| 19398 |
|
| 19399 |
|
| 19400 |
/** |
| 19401 |
* Safe access in tree object |
| 19402 |
* |
| 19403 |
* @example |
| 19404 |
* ```js |
| 19405 |
* const a = {}, b = {}; |
| 19406 |
* Jodit.modules.Helpers.set('a.b.c.d.e', 1, a); |
| 19407 |
* console.log(a);// {a: {b: {c: {d: {e: 1}}}}} |
| 19408 |
* |
| 19409 |
* Jodit.modules.Helpers.set('a.0.e', 1, b); |
| 19410 |
* console.log(b);// {a: [{e: 1}]} |
| 19411 |
* ``` |
| 19412 |
*/ function set(chain, value, obj) { |
| 19413 |
if (!(0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_3__.isString)(chain) || !chain.length) { |
| 19414 |
return; |
| 19415 |
} |
| 19416 |
const parts = chain.split('.'); |
| 19417 |
let result = obj, key = parts[0]; |
| 19418 |
for(let i = 0; i < parts.length - 1; i += 1){ |
| 19419 |
key = parts[i]; |
| 19420 |
if (!(0,jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_0__.isArray)(result[key]) && !(0,jodit_core_helpers_checker_is_plain_object__WEBPACK_IMPORTED_MODULE_2__.isPlainObject)(result[key])) { |
| 19421 |
result[key] = (0,jodit_core_helpers_checker_is_numeric__WEBPACK_IMPORTED_MODULE_1__.isNumeric)(parts[i + 1]) ? [] : {}; |
| 19422 |
} |
| 19423 |
result = result[key]; |
| 19424 |
} |
| 19425 |
if (result) { |
| 19426 |
result[parts[parts.length - 1]] = value; |
| 19427 |
} |
| 19428 |
} |
| 19429 |
|
| 19430 |
|
| 19431 |
/***/ }), |
| 19432 |
|
| 19433 |
/***/ 52433: |
| 19434 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 19435 |
|
| 19436 |
"use strict"; |
| 19437 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 19438 |
/* harmony export */ hasContainer: function() { return /* binding */ hasContainer; }, |
| 19439 |
/* harmony export */ isDestructable: function() { return /* binding */ isDestructable; }, |
| 19440 |
/* harmony export */ isInitable: function() { return /* binding */ isInitable; } |
| 19441 |
/* harmony export */ }); |
| 19442 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 19443 |
/* harmony import */ var _is_function__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(91565); |
| 19444 |
/* harmony import */ var _is_void__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(18303); |
| 19445 |
/*! |
| 19446 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 19447 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 19448 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 19449 |
*/ /** |
| 19450 |
* @module helpers/checker |
| 19451 |
*/ |
| 19452 |
|
| 19453 |
|
| 19454 |
/** |
| 19455 |
* Check value has method init |
| 19456 |
*/ function isInitable(value) { |
| 19457 |
return !(0,_is_void__WEBPACK_IMPORTED_MODULE_2__.isVoid)(value) && (0,_is_function__WEBPACK_IMPORTED_MODULE_1__.isFunction)(value.init); |
| 19458 |
} |
| 19459 |
/** |
| 19460 |
* Check value has method destruct |
| 19461 |
*/ function isDestructable(value) { |
| 19462 |
return !(0,_is_void__WEBPACK_IMPORTED_MODULE_2__.isVoid)(value) && (0,_is_function__WEBPACK_IMPORTED_MODULE_1__.isFunction)(value.destruct); |
| 19463 |
} |
| 19464 |
/** |
| 19465 |
* Check value is instant that implements IContainer |
| 19466 |
*/ function hasContainer(value) { |
| 19467 |
return !(0,_is_void__WEBPACK_IMPORTED_MODULE_2__.isVoid)(value) && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isElement(value.container); |
| 19468 |
} |
| 19469 |
|
| 19470 |
|
| 19471 |
/***/ }), |
| 19472 |
|
| 19473 |
/***/ 52450: |
| 19474 |
/***/ (function(module) { |
| 19475 |
|
| 19476 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M747 1521q74 32 140 32 376 0 376-335 0-114-41-180-27-44-61.5-74t-67.5-46.5-80.5-25-84-10.5-94.5-2q-73 0-101 10 0 53-.5 159t-.5 158q0 8-1 67.5t-.5 96.5 4.5 83.5 12 66.5zm-14-746q42 7 109 7 82 0 143-13t110-44.5 74.5-89.5 25.5-142q0-70-29-122.5t-79-82-108-43.5-124-14q-50 0-130 13 0 50 4 151t4 152q0 27-.5 80t-.5 79q0 46 1 69zm-541 889l2-94q15-4 85-16t106-27q7-12 12.5-27t8.5-33.5 5.5-32.5 3-37.5.5-34v-65.5q0-982-22-1025-4-8-22-14.5t-44.5-11-49.5-7-48.5-4.5-30.5-3l-4-83q98-2 340-11.5t373-9.5q23 0 68.5.5t67.5.5q70 0 136.5 13t128.5 42 108 71 74 104.5 28 137.5q0 52-16.5 95.5t-39 72-64.5 57.5-73 45-84 40q154 35 256.5 134t102.5 248q0 100-35 179.5t-93.5 130.5-138 85.5-163.5 48.5-176 14q-44 0-132-3t-132-3q-106 0-307 11t-231 12z\"/> </svg>" |
| 19477 |
|
| 19478 |
/***/ }), |
| 19479 |
|
| 19480 |
/***/ 52938: |
| 19481 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 19482 |
|
| 19483 |
"use strict"; |
| 19484 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 19485 |
/* harmony export */ wrapText: function() { return /* binding */ wrapText; } |
| 19486 |
/* harmony export */ }); |
| 19487 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 19488 |
/*! |
| 19489 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 19490 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 19491 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 19492 |
*/ /** |
| 19493 |
* @module plugins/enter |
| 19494 |
*/ |
| 19495 |
/** |
| 19496 |
* If there is no container outside, |
| 19497 |
* then we wrap all the nearest inline nodes in a container |
| 19498 |
* @private |
| 19499 |
*/ function wrapText(fake, jodit) { |
| 19500 |
let needWrap = fake; |
| 19501 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.up(needWrap, (node)=>{ |
| 19502 |
if (node && node.hasChildNodes() && node !== jodit.editor) { |
| 19503 |
needWrap = node; |
| 19504 |
} |
| 19505 |
}, jodit.editor); |
| 19506 |
const currentBox = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.wrapInline(needWrap, jodit.o.enter, jodit); |
| 19507 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isEmpty(currentBox)) { |
| 19508 |
const br = jodit.createInside.element('br'); |
| 19509 |
currentBox.appendChild(br); |
| 19510 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.before(br, fake); |
| 19511 |
} |
| 19512 |
return currentBox; |
| 19513 |
} |
| 19514 |
|
| 19515 |
|
| 19516 |
/***/ }), |
| 19517 |
|
| 19518 |
/***/ 53202: |
| 19519 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 19520 |
|
| 19521 |
"use strict"; |
| 19522 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 19523 |
/* harmony export */ loadTree: function() { return /* binding */ loadTree; } |
| 19524 |
/* harmony export */ }); |
| 19525 |
/* harmony import */ var _swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(49376); |
| 19526 |
/* harmony import */ var jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(27795); |
| 19527 |
/* harmony import */ var jodit_modules_file_browser_fetch_load_items__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1488); |
| 19528 |
/*! |
| 19529 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 19530 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 19531 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 19532 |
*/ /** |
| 19533 |
* @module modules/file-browser |
| 19534 |
*/ |
| 19535 |
|
| 19536 |
|
| 19537 |
/** |
| 19538 |
* Loads a list of directories |
| 19539 |
* @private |
| 19540 |
*/ function loadTree(fb) { |
| 19541 |
return (0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 19542 |
fb.tree.setMod('active', true); |
| 19543 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.detach(fb.tree.container); |
| 19544 |
const items = (0,jodit_modules_file_browser_fetch_load_items__WEBPACK_IMPORTED_MODULE_2__.loadItems)(fb); |
| 19545 |
if (fb.o.showFoldersPanel) { |
| 19546 |
fb.tree.setMod('loading', true); |
| 19547 |
const tree = fb.dataProvider.tree(fb.state.currentPath, fb.state.currentSource).then((resp)=>{ |
| 19548 |
fb.state.sources = resp; |
| 19549 |
}).catch(fb.status).finally(()=>fb.tree.setMod('loading', false)); |
| 19550 |
return Promise.all([ |
| 19551 |
tree, |
| 19552 |
items |
| 19553 |
]); |
| 19554 |
} |
| 19555 |
fb.tree.setMod('active', false); |
| 19556 |
return items; |
| 19557 |
})(); |
| 19558 |
} |
| 19559 |
|
| 19560 |
|
| 19561 |
/***/ }), |
| 19562 |
|
| 19563 |
/***/ 53328: |
| 19564 |
/***/ (function(module) { |
| 19565 |
|
| 19566 |
module.exports = "<svg viewBox=\"0 0 13 13\" xmlns=\"http://www.w3.org/2000/svg\"> <path d=\"M5.9814 11.8049C5.59087 11.4144 5.59087 10.7812 5.9814 10.3907L10.224 6.14806C10.6146 5.75754 11.2477 5.75754 11.6383 6.14806C12.0288 6.53859 12.0288 7.17175 11.6383 7.56228L7.39561 11.8049C7.00509 12.1954 6.37192 12.1954 5.9814 11.8049Z\"/> <path d=\"M0.707107 12.0208C0.316582 11.6303 0.316582 10.9971 0.707107 10.6066L10.6066 0.707121C10.9971 0.316597 11.6303 0.316596 12.0208 0.707121C12.4113 1.09764 12.4113 1.73081 12.0208 2.12133L2.12132 12.0208C1.7308 12.4114 1.09763 12.4114 0.707107 12.0208Z\"/> </svg>" |
| 19567 |
|
| 19568 |
/***/ }), |
| 19569 |
|
| 19570 |
/***/ 53390: |
| 19571 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 19572 |
|
| 19573 |
"use strict"; |
| 19574 |
/* unused harmony export formatBlock */ |
| 19575 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(28077); |
| 19576 |
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(96863); |
| 19577 |
/*! |
| 19578 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 19579 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 19580 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 19581 |
*/ /** |
| 19582 |
* [[include:plugins/format-block/README.md]] |
| 19583 |
* @packageDocumentation |
| 19584 |
* @module plugins/format-block |
| 19585 |
*/ |
| 19586 |
|
| 19587 |
/** |
| 19588 |
* Process command - `formatblock` |
| 19589 |
*/ function formatBlock(editor) { |
| 19590 |
editor.registerButton({ |
| 19591 |
name: 'paragraph', |
| 19592 |
group: 'font' |
| 19593 |
}); |
| 19594 |
editor.registerCommand('formatblock', (command, second, third)=>{ |
| 19595 |
editor.s.commitStyle({ |
| 19596 |
element: third |
| 19597 |
}); |
| 19598 |
editor.synchronizeValues(); |
| 19599 |
return false; |
| 19600 |
}); |
| 19601 |
} |
| 19602 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_0__.pluginSystem.add('formatBlock', formatBlock); |
| 19603 |
|
| 19604 |
|
| 19605 |
/***/ }), |
| 19606 |
|
| 19607 |
/***/ 53414: |
| 19608 |
/***/ (function(module) { |
| 19609 |
|
| 19610 |
module.exports["default"] = ["Type something","About Jodit","Jodit Editor","Jodit User's Guide","contains detailed help for using","For information about the license, please go to our website:","Buy full version","Copyright © XDSoft.net - Chupurnov Valeriy. All rights reserved.","Anchor","Open in new tab","Open in fullsize","Clear Formatting","Fill color or set the text color","Redo","Undo","Bold","Italic","Insert Unordered List","Insert Ordered List","Align Center","Align Justify","Align Left","Align Right","Insert Horizontal Line","Insert Image","Insert file","Insert youtube/vimeo video","Insert link","Font size","Font family","Insert format block","Normal","Heading 1","Heading 2","Heading 3","Heading 4","Quote","Code","Insert","Insert table","Decrease Indent","Increase Indent","Select Special Character","Insert Special Character","Paint format","Change mode","Margins","top","right","bottom","left","Styles","Classes","Align","Right","Center","Left","--Not Set--","Src","Title","Alternative","Link","Open link in new tab","Image","file","Advanced","Image properties","Cancel","Ok","File Browser","Error on load list","Error on load folders","Are you sure?","Enter Directory name","Create directory","type name","Drop image","Drop file","or click","Alternative text","Upload","Browse","Background","Text","Top","Middle","Bottom","Insert column before","Insert column after","Insert row above","Insert row below","Delete table","Delete row","Delete column","Empty cell","Chars: %d","Words: %d","Strike through","Underline","superscript","subscript","Cut selection","Select all","Break","Search for","Replace with","Replace","Paste","Choose Content to Paste","source","bold","italic","brush","link","undo","redo","table","image","eraser","paragraph","fontsize","video","font","about","print","underline","strikethrough","indent","outdent","fullsize","shrink","hr","ul","ol","cut","selectall","Embed code","Open link","Edit link","No follow","Unlink","Update","pencil","Eye"," URL","Edit","Horizontal align","Filter","Sort by changed","Sort by name","Sort by size","Add folder","Reset","Save","Save as ...","Resize","Crop","Width","Height","Keep Aspect Ratio","Yes","No","Remove","Select","Select %s","Vertical align","Split","Merge","Add column","Add row","License: %s","Delete","Split vertical","Split horizontal","Border","Your code is similar to HTML. Keep as HTML?","Paste as HTML","Keep","Insert as Text","Insert only Text","You can only edit your own images. Download this image on the host?","The image has been successfully uploaded to the host!","palette","There are no files","Rename","Enter new name","preview","download","Paste from clipboard","Your browser doesn't support direct access to the clipboard.","Copy selection","copy","Border radius","Show all","Apply","Please fill out this field","Please enter a web address","Default","Circle","Dot","Quadrate","Find","Find Previous","Find Next","The pasted content is coming from a Microsoft Word/Excel document. Do you want to keep the format or clean it up?","Word Paste Detected","Clean","Insert className","Press Alt for custom resizing","Line height","spellcheck","Speech Recognize","All"] |
| 19611 |
|
| 19612 |
/***/ }), |
| 19613 |
|
| 19614 |
/***/ 53514: |
| 19615 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 19616 |
|
| 19617 |
"use strict"; |
| 19618 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 19619 |
/* harmony export */ removeInvTextNodes: function() { return /* binding */ removeInvTextNodes; } |
| 19620 |
/* harmony export */ }); |
| 19621 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 19622 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(23211); |
| 19623 |
/*! |
| 19624 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 19625 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 19626 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 19627 |
*/ /** |
| 19628 |
* @module plugins/clean-html |
| 19629 |
*/ |
| 19630 |
|
| 19631 |
/** |
| 19632 |
* @private |
| 19633 |
*/ function removeInvTextNodes(jodit, node, hadEffect, arg, argi, currentNode) { |
| 19634 |
if (currentNode === node || !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isText(node) || node.nodeValue == null) { |
| 19635 |
return hadEffect; |
| 19636 |
} |
| 19637 |
if (!(0,jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE_REG_EXP)().test(node.nodeValue)) { |
| 19638 |
return hadEffect; |
| 19639 |
} |
| 19640 |
const focusBox = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.furthest(currentNode, jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isBlock, jodit.editor); |
| 19641 |
if (!focusBox || jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isOrContains(focusBox, node)) { |
| 19642 |
return hadEffect; |
| 19643 |
} |
| 19644 |
node.nodeValue = node.nodeValue.replace((0,jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE_REG_EXP)(), ''); |
| 19645 |
if (node === currentNode && jodit.s.isCollapsed()) { |
| 19646 |
jodit.s.setCursorAfter(node); |
| 19647 |
} |
| 19648 |
if (!node.nodeValue) { |
| 19649 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.safeRemove(node); |
| 19650 |
} |
| 19651 |
return true; |
| 19652 |
} |
| 19653 |
|
| 19654 |
|
| 19655 |
/***/ }), |
| 19656 |
|
| 19657 |
/***/ 53681: |
| 19658 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 19659 |
|
| 19660 |
"use strict"; |
| 19661 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 19662 |
/* harmony export */ Button: function() { return /* binding */ Button; }, |
| 19663 |
/* harmony export */ UIButton: function() { return /* binding */ UIButton; }, |
| 19664 |
/* harmony export */ UIButtonState: function() { return /* binding */ UIButtonState; } |
| 19665 |
/* harmony export */ }); |
| 19666 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 19667 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 19668 |
/* harmony import */ var jodit_core_component_statuses__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(69364); |
| 19669 |
/* harmony import */ var jodit_core_decorators_cache_cache__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(51676); |
| 19670 |
/* harmony import */ var jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(91672); |
| 19671 |
/* harmony import */ var jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(68616); |
| 19672 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(23211); |
| 19673 |
/* harmony import */ var jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(91565); |
| 19674 |
/* harmony import */ var jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(85932); |
| 19675 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(28712); |
| 19676 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_9__); |
| 19677 |
/* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(7909); |
| 19678 |
/* harmony import */ var jodit_core_ui_element__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(96007); |
| 19679 |
/* harmony import */ var jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(29434); |
| 19680 |
/*! |
| 19681 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 19682 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 19683 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 19684 |
*/ /** |
| 19685 |
* @module ui/button |
| 19686 |
*/ |
| 19687 |
|
| 19688 |
|
| 19689 |
|
| 19690 |
|
| 19691 |
|
| 19692 |
|
| 19693 |
|
| 19694 |
|
| 19695 |
|
| 19696 |
|
| 19697 |
|
| 19698 |
|
| 19699 |
|
| 19700 |
const UIButtonState = ()=>({ |
| 19701 |
size: 'middle', |
| 19702 |
type: 'button', |
| 19703 |
role: 'button', |
| 19704 |
name: '', |
| 19705 |
value: '', |
| 19706 |
variant: 'initial', |
| 19707 |
disabled: false, |
| 19708 |
activated: false, |
| 19709 |
icon: { |
| 19710 |
name: 'empty', |
| 19711 |
fill: '', |
| 19712 |
iconURL: '' |
| 19713 |
}, |
| 19714 |
tooltip: '', |
| 19715 |
text: '', |
| 19716 |
tabIndex: undefined |
| 19717 |
}); |
| 19718 |
class UIButton extends jodit_core_ui_element__WEBPACK_IMPORTED_MODULE_11__.UIElement { |
| 19719 |
/** @override */ className() { |
| 19720 |
return 'UIButton'; |
| 19721 |
} |
| 19722 |
/** |
| 19723 |
* Set state |
| 19724 |
*/ setState(state) { |
| 19725 |
Object.assign(this.state, state); |
| 19726 |
return this; |
| 19727 |
} |
| 19728 |
/** |
| 19729 |
* DOM container for text content |
| 19730 |
*/ get text() { |
| 19731 |
const text = this.getElm('text'); |
| 19732 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_9__.assert)(text, 'Text element not found'); |
| 19733 |
return text; |
| 19734 |
} |
| 19735 |
/** |
| 19736 |
* DOM container for icon |
| 19737 |
*/ get icon() { |
| 19738 |
const icon = this.getElm('icon'); |
| 19739 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_9__.assert)(icon, 'Icon element not found'); |
| 19740 |
return icon; |
| 19741 |
} |
| 19742 |
onChangeSize() { |
| 19743 |
this.setMod('size', this.state.size); |
| 19744 |
} |
| 19745 |
onChangeType() { |
| 19746 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_10__.attr)(this.container, 'type', this.state.type); |
| 19747 |
} |
| 19748 |
onChangeRole() { |
| 19749 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_10__.attr)(this.container, 'role', this.state.role); |
| 19750 |
} |
| 19751 |
/** |
| 19752 |
* Set size from a parent list |
| 19753 |
*/ updateSize() { |
| 19754 |
const UIList = (0,jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_4__.getComponentClass)('UIList'); |
| 19755 |
const pe = this.closest(UIList); |
| 19756 |
if (pe) { |
| 19757 |
this.state.size = pe.buttonSize; |
| 19758 |
return; |
| 19759 |
} |
| 19760 |
} |
| 19761 |
onChangeStatus() { |
| 19762 |
this.setMod('variant', this.state.variant); |
| 19763 |
} |
| 19764 |
onChangeText() { |
| 19765 |
this.text.textContent = this.jodit.i18n(this.state.text); |
| 19766 |
this.updateAriaLabel(); |
| 19767 |
} |
| 19768 |
onChangeTextSetMode() { |
| 19769 |
this.setMod('text-icons', Boolean(this.state.text.trim().length)); |
| 19770 |
} |
| 19771 |
onChangeDisabled() { |
| 19772 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_10__.attr)(this.container, 'disabled', this.state.disabled || null); |
| 19773 |
} |
| 19774 |
onChangeActivated() { |
| 19775 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_10__.attr)(this.container, 'aria-pressed', this.state.activated); |
| 19776 |
} |
| 19777 |
onChangeName() { |
| 19778 |
this.container.classList.add(`${this.componentName}_${this.clearName(this.state.name)}`); |
| 19779 |
this.name = this.state.name; |
| 19780 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_10__.attr)(this.container, 'data-ref', this.state.name); |
| 19781 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_10__.attr)(this.container, 'ref', this.state.name); |
| 19782 |
} |
| 19783 |
onChangeTooltip() { |
| 19784 |
const i8nTooltip = this.state.tooltip ? this.jodit.i18n(this.state.tooltip) : null; |
| 19785 |
if (this.get('j.o.useNativeTooltip')) { |
| 19786 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_10__.attr)(this.container, 'title', i8nTooltip); |
| 19787 |
} |
| 19788 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_10__.attr)(this.container, 'aria-label', i8nTooltip); |
| 19789 |
this.updateAriaLabel(); |
| 19790 |
} |
| 19791 |
updateAriaLabel() { |
| 19792 |
const hasText = this.state.text.trim().length > 0; |
| 19793 |
const i8nTooltip = this.state.tooltip ? this.jodit.i18n(this.state.tooltip) : null; |
| 19794 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_10__.attr)(this.container, 'aria-label', i8nTooltip); |
| 19795 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_10__.attr)(this.button, 'aria-label', !hasText ? i8nTooltip : null); |
| 19796 |
} |
| 19797 |
onChangeTabIndex() { |
| 19798 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_10__.attr)(this.container, 'tabindex', this.state.tabIndex); |
| 19799 |
} |
| 19800 |
onChangeIcon() { |
| 19801 |
const textIcons = this.get('j.o.textIcons'); |
| 19802 |
if (textIcons === true || (0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_7__.isFunction)(textIcons) && textIcons(this.state.name)) { |
| 19803 |
return; |
| 19804 |
} |
| 19805 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_6__.Dom.detach(this.icon); |
| 19806 |
const iconElement = jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_12__.Icon.makeIcon(this.j, this.state.icon); |
| 19807 |
iconElement && this.icon.appendChild(iconElement); |
| 19808 |
} |
| 19809 |
/** |
| 19810 |
* Set focus on an element |
| 19811 |
*/ focus() { |
| 19812 |
this.container.focus(); |
| 19813 |
} |
| 19814 |
/** |
| 19815 |
* Element has focus |
| 19816 |
*/ isFocused() { |
| 19817 |
const { activeElement } = this.od; |
| 19818 |
return Boolean(activeElement && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_6__.Dom.isOrContains(this.container, activeElement)); |
| 19819 |
} |
| 19820 |
/** @override */ createContainer() { |
| 19821 |
const cn = this.componentName; |
| 19822 |
const button = this.j.c.element('button', { |
| 19823 |
class: cn, |
| 19824 |
type: 'button', |
| 19825 |
role: 'button', |
| 19826 |
ariaPressed: false |
| 19827 |
}); |
| 19828 |
const icon = this.j.c.span(cn + '__icon'); |
| 19829 |
const text = this.j.c.span(cn + '__text'); |
| 19830 |
button.appendChild(icon); |
| 19831 |
button.appendChild(text); |
| 19832 |
return button; |
| 19833 |
} |
| 19834 |
destruct() { |
| 19835 |
this.j.e.off(this); |
| 19836 |
this.j.e.off(this.container); |
| 19837 |
return super.destruct(); |
| 19838 |
} |
| 19839 |
/** |
| 19840 |
* Add action handler |
| 19841 |
*/ onAction(callback) { |
| 19842 |
this.actionHandlers.push(callback); |
| 19843 |
return this; |
| 19844 |
} |
| 19845 |
/** |
| 19846 |
* Fire all click handlers |
| 19847 |
*/ __onActionFire(e) { |
| 19848 |
e.buffer = { |
| 19849 |
actionTrigger: this |
| 19850 |
}; |
| 19851 |
this.actionHandlers.forEach((callback)=>callback.call(this, e)); |
| 19852 |
this.j.e.fire(this, 'click', e); |
| 19853 |
} |
| 19854 |
constructor(jodit, state){ |
| 19855 |
super(jodit), /** |
| 19856 |
* Marker for buttons |
| 19857 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "isButton", true), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "state", UIButtonState()), /** |
| 19858 |
* DOM container for button |
| 19859 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "button", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "actionHandlers", []); |
| 19860 |
this.button = this.container; |
| 19861 |
this.updateSize(); |
| 19862 |
this.onChangeSize(); |
| 19863 |
this.onChangeStatus(); |
| 19864 |
if (state) { |
| 19865 |
this.hookStatus(jodit_core_component_statuses__WEBPACK_IMPORTED_MODULE_2__.STATUSES.ready, ()=>{ |
| 19866 |
this.setState(state); |
| 19867 |
}); |
| 19868 |
} |
| 19869 |
} |
| 19870 |
} |
| 19871 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 19872 |
jodit_core_decorators_cache_cache__WEBPACK_IMPORTED_MODULE_3__.cache |
| 19873 |
], UIButton.prototype, "text", null); |
| 19874 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 19875 |
jodit_core_decorators_cache_cache__WEBPACK_IMPORTED_MODULE_3__.cache |
| 19876 |
], UIButton.prototype, "icon", null); |
| 19877 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 19878 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__.watch)('state.size', { |
| 19879 |
immediately: false |
| 19880 |
}) |
| 19881 |
], UIButton.prototype, "onChangeSize", null); |
| 19882 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 19883 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__.watch)('state.type', { |
| 19884 |
immediately: false |
| 19885 |
}) |
| 19886 |
], UIButton.prototype, "onChangeType", null); |
| 19887 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 19888 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__.watch)('state.role', { |
| 19889 |
immediately: false |
| 19890 |
}) |
| 19891 |
], UIButton.prototype, "onChangeRole", null); |
| 19892 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 19893 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__.watch)('parentElement') |
| 19894 |
], UIButton.prototype, "updateSize", null); |
| 19895 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 19896 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__.watch)('state.variant', { |
| 19897 |
immediately: false |
| 19898 |
}) |
| 19899 |
], UIButton.prototype, "onChangeStatus", null); |
| 19900 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 19901 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__.watch)('state.text', { |
| 19902 |
immediately: false |
| 19903 |
}) |
| 19904 |
], UIButton.prototype, "onChangeText", null); |
| 19905 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 19906 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__.watch)('state.text', { |
| 19907 |
immediately: false |
| 19908 |
}) |
| 19909 |
], UIButton.prototype, "onChangeTextSetMode", null); |
| 19910 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 19911 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__.watch)('state.disabled') |
| 19912 |
], UIButton.prototype, "onChangeDisabled", null); |
| 19913 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 19914 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__.watch)('state.activated') |
| 19915 |
], UIButton.prototype, "onChangeActivated", null); |
| 19916 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 19917 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__.watch)('state.name', { |
| 19918 |
immediately: false |
| 19919 |
}) |
| 19920 |
], UIButton.prototype, "onChangeName", null); |
| 19921 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 19922 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__.watch)('state.tooltip', { |
| 19923 |
immediately: false |
| 19924 |
}) |
| 19925 |
], UIButton.prototype, "onChangeTooltip", null); |
| 19926 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 19927 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__.watch)('state.tabIndex', { |
| 19928 |
immediately: false |
| 19929 |
}) |
| 19930 |
], UIButton.prototype, "onChangeTabIndex", null); |
| 19931 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 19932 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__.watch)('state.icon', { |
| 19933 |
immediately: false |
| 19934 |
}) |
| 19935 |
], UIButton.prototype, "onChangeIcon", null); |
| 19936 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 19937 |
jodit_core_decorators_cache_cache__WEBPACK_IMPORTED_MODULE_3__.cacheHTML |
| 19938 |
], UIButton.prototype, "createContainer", null); |
| 19939 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 19940 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__.watch)('button:click') |
| 19941 |
], UIButton.prototype, "__onActionFire", null); |
| 19942 |
UIButton = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 19943 |
jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_4__.component |
| 19944 |
], UIButton); |
| 19945 |
function Button(jodit, stateOrText, text, variant) { |
| 19946 |
const button = new UIButton(jodit); |
| 19947 |
button.state.tabIndex = jodit.o.allowTabNavigation ? 0 : -1; |
| 19948 |
if ((0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_8__.isString)(stateOrText)) { |
| 19949 |
button.state.icon.name = stateOrText; |
| 19950 |
button.state.name = stateOrText; |
| 19951 |
if (variant) { |
| 19952 |
button.state.variant = variant; |
| 19953 |
} |
| 19954 |
if (text) { |
| 19955 |
button.state.text = text; |
| 19956 |
} |
| 19957 |
} else { |
| 19958 |
button.setState(stateOrText); |
| 19959 |
} |
| 19960 |
return button; |
| 19961 |
} |
| 19962 |
|
| 19963 |
|
| 19964 |
/***/ }), |
| 19965 |
|
| 19966 |
/***/ 53808: |
| 19967 |
/***/ (function(module) { |
| 19968 |
|
| 19969 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M512 1536h768v-384h-768v384zm896 0h128v-896q0-14-10-38.5t-20-34.5l-281-281q-10-10-34-20t-39-10v416q0 40-28 68t-68 28h-576q-40 0-68-28t-28-68v-416h-128v1280h128v-416q0-40 28-68t68-28h832q40 0 68 28t28 68v416zm-384-928v-320q0-13-9.5-22.5t-22.5-9.5h-192q-13 0-22.5 9.5t-9.5 22.5v320q0 13 9.5 22.5t22.5 9.5h192q13 0 22.5-9.5t9.5-22.5zm640 32v928q0 40-28 68t-68 28h-1344q-40 0-68-28t-28-68v-1344q0-40 28-68t68-28h928q40 0 88 20t76 48l280 280q28 28 48 76t20 88z\"/> </svg>" |
| 19970 |
|
| 19971 |
/***/ }), |
| 19972 |
|
| 19973 |
/***/ 53855: |
| 19974 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 19975 |
|
| 19976 |
"use strict"; |
| 19977 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 19978 |
/* harmony export */ History: function() { return /* binding */ History; } |
| 19979 |
/* harmony export */ }); |
| 19980 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 19981 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 19982 |
/* harmony import */ var jodit_core_component_view_component__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(59609); |
| 19983 |
/* harmony import */ var jodit_core_decorators_debounce_debounce__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(55184); |
| 19984 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(5266); |
| 19985 |
/* harmony import */ var _command__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(8838); |
| 19986 |
/* harmony import */ var _snapshot__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(46363); |
| 19987 |
/* harmony import */ var _stack__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(33511); |
| 19988 |
/*! |
| 19989 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 19990 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 19991 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 19992 |
*/ /** |
| 19993 |
* [[include:modules/history/README.md]] |
| 19994 |
* @packageDocumentation |
| 19995 |
* @module modules/history |
| 19996 |
*/ |
| 19997 |
|
| 19998 |
|
| 19999 |
|
| 20000 |
|
| 20001 |
|
| 20002 |
|
| 20003 |
|
| 20004 |
jodit_config__WEBPACK_IMPORTED_MODULE_4__.Config.prototype.history = { |
| 20005 |
enable: true, |
| 20006 |
maxHistoryLength: Infinity, |
| 20007 |
timeout: 1000 |
| 20008 |
}; |
| 20009 |
/** |
| 20010 |
* The module monitors the status of the editor and creates / deletes the required number of Undo / Redo shots . |
| 20011 |
*/ class History extends jodit_core_component_view_component__WEBPACK_IMPORTED_MODULE_2__.ViewComponent { |
| 20012 |
/** @override */ className() { |
| 20013 |
return 'History'; |
| 20014 |
} |
| 20015 |
/** |
| 20016 |
* Return state of the WYSIWYG editor to step back |
| 20017 |
*/ redo() { |
| 20018 |
if (this.__stack.redo()) { |
| 20019 |
this.startValue = this.snapshot.make(); |
| 20020 |
this.fireChangeStack(); |
| 20021 |
} |
| 20022 |
} |
| 20023 |
canRedo() { |
| 20024 |
return this.__stack.canRedo(); |
| 20025 |
} |
| 20026 |
/** |
| 20027 |
* Return the state of the WYSIWYG editor to step forward |
| 20028 |
*/ undo() { |
| 20029 |
if (this.__stack.undo()) { |
| 20030 |
this.startValue = this.snapshot.make(); |
| 20031 |
this.fireChangeStack(); |
| 20032 |
} |
| 20033 |
} |
| 20034 |
canUndo() { |
| 20035 |
return this.__stack.canUndo(); |
| 20036 |
} |
| 20037 |
clear() { |
| 20038 |
this.startValue = this.snapshot.make(); |
| 20039 |
this.__stack.clear(); |
| 20040 |
this.fireChangeStack(); |
| 20041 |
} |
| 20042 |
get length() { |
| 20043 |
return this.__stack.length; |
| 20044 |
} |
| 20045 |
get startValue() { |
| 20046 |
return this.__startValue; |
| 20047 |
} |
| 20048 |
set startValue(value) { |
| 20049 |
this.__startValue = value; |
| 20050 |
} |
| 20051 |
/** |
| 20052 |
* Update change counter |
| 20053 |
* @internal |
| 20054 |
*/ __upTick() { |
| 20055 |
this.updateTick += 1; |
| 20056 |
} |
| 20057 |
/** |
| 20058 |
* Push new command in stack on some changes |
| 20059 |
*/ onChange() { |
| 20060 |
this.__processChanges(); |
| 20061 |
} |
| 20062 |
/** |
| 20063 |
* @internal |
| 20064 |
*/ __processChanges() { |
| 20065 |
if (this.snapshot.isBlocked || !this.j.o.history.enable) { |
| 20066 |
return; |
| 20067 |
} |
| 20068 |
this.updateStack(); |
| 20069 |
} |
| 20070 |
/** |
| 20071 |
* Update history stack |
| 20072 |
*/ updateStack(replace = false) { |
| 20073 |
const newValue = this.snapshot.make(); |
| 20074 |
if (!_snapshot__WEBPACK_IMPORTED_MODULE_6__.Snapshot.equal(newValue, this.startValue)) { |
| 20075 |
const newCommand = new _command__WEBPACK_IMPORTED_MODULE_5__.Command(this.startValue, newValue, this, this.updateTick); |
| 20076 |
if (replace) { |
| 20077 |
const command = this.__stack.current(); |
| 20078 |
if (command && this.updateTick === command.tick) { |
| 20079 |
this.__stack.replace(newCommand); |
| 20080 |
} |
| 20081 |
} else { |
| 20082 |
this.__stack.push(newCommand); |
| 20083 |
} |
| 20084 |
this.startValue = newValue; |
| 20085 |
this.fireChangeStack(); |
| 20086 |
} |
| 20087 |
} |
| 20088 |
fireChangeStack() { |
| 20089 |
var _this_j_events; |
| 20090 |
this.j && !this.j.isInDestruct && ((_this_j_events = this.j.events) === null || _this_j_events === void 0 ? void 0 : _this_j_events.fire('changeStack')); |
| 20091 |
} |
| 20092 |
destruct() { |
| 20093 |
if (this.isInDestruct) { |
| 20094 |
return; |
| 20095 |
} |
| 20096 |
if (this.j.events) { |
| 20097 |
this.j.e.off('.history'); |
| 20098 |
} |
| 20099 |
this.snapshot.destruct(); |
| 20100 |
super.destruct(); |
| 20101 |
} |
| 20102 |
constructor(editor, stack = new _stack__WEBPACK_IMPORTED_MODULE_7__.Stack(editor.o.history.maxHistoryLength), snapshot = new _snapshot__WEBPACK_IMPORTED_MODULE_6__.Snapshot(editor)){ |
| 20103 |
super(editor), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__startValue", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__stack", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "snapshot", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "updateTick", 0); |
| 20104 |
this.__stack = stack; |
| 20105 |
this.snapshot = snapshot; |
| 20106 |
if (editor.o.history.enable) { |
| 20107 |
editor.e.on('afterAddPlace.history', ()=>{ |
| 20108 |
if (this.isInDestruct) { |
| 20109 |
return; |
| 20110 |
} |
| 20111 |
this.startValue = this.snapshot.make(); |
| 20112 |
editor.events// save selection |
| 20113 |
.on('internalChange internalUpdate', ()=>{ |
| 20114 |
this.startValue = this.snapshot.make(); |
| 20115 |
}).on(editor.editor, [ |
| 20116 |
'changeSelection', |
| 20117 |
'selectionstart', |
| 20118 |
'selectionchange', |
| 20119 |
'mousedown', |
| 20120 |
'mouseup', |
| 20121 |
'keydown', |
| 20122 |
'keyup' |
| 20123 |
].map((f)=>f + '.history').join(' '), ()=>{ |
| 20124 |
if (this.startValue.html === this.j.getNativeEditorValue()) { |
| 20125 |
this.startValue = this.snapshot.make(); |
| 20126 |
} |
| 20127 |
}).on(this, 'change.history', this.onChange); |
| 20128 |
}); |
| 20129 |
} |
| 20130 |
} |
| 20131 |
} |
| 20132 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 20133 |
(0,jodit_core_decorators_debounce_debounce__WEBPACK_IMPORTED_MODULE_3__.debounce)() |
| 20134 |
], History.prototype, "onChange", null); |
| 20135 |
|
| 20136 |
|
| 20137 |
/***/ }), |
| 20138 |
|
| 20139 |
/***/ 54053: |
| 20140 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 20141 |
|
| 20142 |
"use strict"; |
| 20143 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 20144 |
/* harmony export */ getHash: function() { return /* reexport safe */ _get_hash__WEBPACK_IMPORTED_MODULE_0__.getHash; }, |
| 20145 |
/* harmony export */ removeFormatForCollapsedSelection: function() { return /* reexport safe */ _remove_format_remove_format_for_collapsed_selection__WEBPACK_IMPORTED_MODULE_1__.removeFormatForCollapsedSelection; }, |
| 20146 |
/* harmony export */ removeFormatForSelection: function() { return /* reexport safe */ _remove_format_remove_format_for_selection__WEBPACK_IMPORTED_MODULE_2__.removeFormatForSelection; }, |
| 20147 |
/* harmony export */ visitNodeWalker: function() { return /* reexport safe */ _visitor_visit_node_walker__WEBPACK_IMPORTED_MODULE_3__.visitNodeWalker; } |
| 20148 |
/* harmony export */ }); |
| 20149 |
/* harmony import */ var _get_hash__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5650); |
| 20150 |
/* harmony import */ var _remove_format_remove_format_for_collapsed_selection__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(37431); |
| 20151 |
/* harmony import */ var _remove_format_remove_format_for_selection__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(70195); |
| 20152 |
/* harmony import */ var _visitor_visit_node_walker__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(45219); |
| 20153 |
/*! |
| 20154 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 20155 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 20156 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 20157 |
*/ /** |
| 20158 |
* @module plugins/clean-html |
| 20159 |
*/ |
| 20160 |
|
| 20161 |
|
| 20162 |
|
| 20163 |
|
| 20164 |
|
| 20165 |
/***/ }), |
| 20166 |
|
| 20167 |
/***/ 54055: |
| 20168 |
/***/ (function(module) { |
| 20169 |
|
| 20170 |
/*! |
| 20171 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 20172 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 20173 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 20174 |
*/ module.exports = { |
| 20175 |
symbols: 'caractère' |
| 20176 |
}; |
| 20177 |
|
| 20178 |
|
| 20179 |
/***/ }), |
| 20180 |
|
| 20181 |
/***/ 54308: |
| 20182 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 20183 |
|
| 20184 |
"use strict"; |
| 20185 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 20186 |
/* harmony export */ askInsertTypeDialog: function() { return /* binding */ askInsertTypeDialog; }, |
| 20187 |
/* harmony export */ getAllTypes: function() { return /* binding */ getAllTypes; }, |
| 20188 |
/* harmony export */ pasteInsertHtml: function() { return /* binding */ pasteInsertHtml; } |
| 20189 |
/* harmony export */ }); |
| 20190 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 20191 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(23211); |
| 20192 |
/* harmony import */ var jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(28686); |
| 20193 |
/* harmony import */ var jodit_core_ui_button_button_button__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(53681); |
| 20194 |
/*! |
| 20195 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 20196 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 20197 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 20198 |
*/ /** |
| 20199 |
* @module plugins/paste |
| 20200 |
*/ |
| 20201 |
|
| 20202 |
|
| 20203 |
|
| 20204 |
/** |
| 20205 |
* Remove special HTML comments |
| 20206 |
* @private |
| 20207 |
*/ function removeExtraFragments(html) { |
| 20208 |
html = html.replace(/<meta[^>]+?>/g, ''); |
| 20209 |
const start = html.search(/<!--StartFragment-->/i); |
| 20210 |
if (start !== -1) { |
| 20211 |
html = html.substring(start + 20); |
| 20212 |
} |
| 20213 |
const end = html.search(/<!--EndFragment-->/i); |
| 20214 |
if (end !== -1) { |
| 20215 |
html = html.substring(0, end); |
| 20216 |
} |
| 20217 |
return html; |
| 20218 |
} |
| 20219 |
/** |
| 20220 |
* @private |
| 20221 |
*/ function isDragEvent(e) { |
| 20222 |
return Boolean(e && e.type === 'drop'); |
| 20223 |
} |
| 20224 |
/** |
| 20225 |
* One insert point for clipboard plugins |
| 20226 |
* @private |
| 20227 |
*/ function pasteInsertHtml(e, editor, html) { |
| 20228 |
if (editor.isInDestruct) { |
| 20229 |
return; |
| 20230 |
} |
| 20231 |
if (isDragEvent(e)) { |
| 20232 |
editor.s.insertCursorAtPoint(e.clientX, e.clientY); |
| 20233 |
} |
| 20234 |
const result = editor.e.fire('beforePasteInsert', html); |
| 20235 |
if (!(0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_2__.isVoid)(result) && ((0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_2__.isString)(result) || (0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_2__.isNumber)(result) || jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isNode(result))) { |
| 20236 |
html = result; |
| 20237 |
} |
| 20238 |
if ((0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_2__.isString)(html)) { |
| 20239 |
html = removeExtraFragments(html); |
| 20240 |
} |
| 20241 |
editor.s.insertHTML(html); |
| 20242 |
} |
| 20243 |
/** |
| 20244 |
* Return all available data types in event |
| 20245 |
* @private |
| 20246 |
*/ function getAllTypes(dt) { |
| 20247 |
const types = dt.types; |
| 20248 |
let types_str = ''; |
| 20249 |
if ((0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_2__.isArray)(types) || ({}).toString.call(types) === '[object DOMStringList]') { |
| 20250 |
for(let i = 0; i < types.length; i += 1){ |
| 20251 |
types_str += types[i] + ';'; |
| 20252 |
} |
| 20253 |
} else { |
| 20254 |
types_str = (types || jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.TEXT_PLAIN).toString() + ';'; |
| 20255 |
} |
| 20256 |
return types_str; |
| 20257 |
} |
| 20258 |
/** |
| 20259 |
* Make command dialog |
| 20260 |
* @private |
| 20261 |
*/ function askInsertTypeDialog(jodit, msg, title, callback, buttonList) { |
| 20262 |
if (jodit.e.fire('beforeOpenPasteDialog', msg, title, callback, buttonList) === false) { |
| 20263 |
return; |
| 20264 |
} |
| 20265 |
const dialog = jodit.confirm(`<div style="word-break: normal; white-space: normal">${jodit.i18n(msg)}</div>`, jodit.i18n(title)); |
| 20266 |
const buttons = buttonList.map(({ text, value })=>(0,jodit_core_ui_button_button_button__WEBPACK_IMPORTED_MODULE_3__.Button)(jodit, { |
| 20267 |
text, |
| 20268 |
name: text.toLowerCase(), |
| 20269 |
tabIndex: 0 |
| 20270 |
}).onAction(()=>{ |
| 20271 |
dialog.close(); |
| 20272 |
callback(value); |
| 20273 |
})); |
| 20274 |
dialog.e.one(dialog, 'afterClose', ()=>{ |
| 20275 |
if (!jodit.s.isFocused()) { |
| 20276 |
jodit.s.focus(); |
| 20277 |
} |
| 20278 |
}); |
| 20279 |
const cancel = (0,jodit_core_ui_button_button_button__WEBPACK_IMPORTED_MODULE_3__.Button)(jodit, { |
| 20280 |
text: 'Cancel', |
| 20281 |
tabIndex: 0 |
| 20282 |
}).onAction(()=>{ |
| 20283 |
dialog.close(); |
| 20284 |
}); |
| 20285 |
dialog.setFooter([ |
| 20286 |
...buttons, |
| 20287 |
cancel |
| 20288 |
]); |
| 20289 |
buttons[0].focus(); |
| 20290 |
buttons[0].state.variant = 'primary'; |
| 20291 |
jodit.e.fire('afterOpenPasteDialog', dialog, msg, title, callback, buttonList); |
| 20292 |
return dialog; |
| 20293 |
} |
| 20294 |
|
| 20295 |
|
| 20296 |
/***/ }), |
| 20297 |
|
| 20298 |
/***/ 54447: |
| 20299 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 20300 |
|
| 20301 |
"use strict"; |
| 20302 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 20303 |
/* harmony export */ getContentWidth: function() { return /* binding */ getContentWidth; } |
| 20304 |
/* harmony export */ }); |
| 20305 |
/*! |
| 20306 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 20307 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 20308 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 20309 |
*/ /** |
| 20310 |
* @module helpers/size |
| 20311 |
*/ const getContentWidth = (element, win)=>{ |
| 20312 |
const pi = (value)=>parseInt(value, 10), style = win.getComputedStyle(element), width = element.offsetWidth, paddingLeft = pi(style.getPropertyValue('padding-left') || '0'), paddingRight = pi(style.getPropertyValue('padding-right') || '0'); |
| 20313 |
return width - paddingLeft - paddingRight; |
| 20314 |
}; |
| 20315 |
|
| 20316 |
|
| 20317 |
/***/ }), |
| 20318 |
|
| 20319 |
/***/ 54500: |
| 20320 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 20321 |
|
| 20322 |
"use strict"; |
| 20323 |
/* harmony import */ var jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(29434); |
| 20324 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(5266); |
| 20325 |
/* harmony import */ var _icons_crop_svg__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(928); |
| 20326 |
/* harmony import */ var _icons_crop_svg__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_icons_crop_svg__WEBPACK_IMPORTED_MODULE_2__); |
| 20327 |
/* harmony import */ var _icons_resize_svg__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(31230); |
| 20328 |
/* harmony import */ var _icons_resize_svg__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_icons_resize_svg__WEBPACK_IMPORTED_MODULE_3__); |
| 20329 |
/*! |
| 20330 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 20331 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 20332 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 20333 |
*/ /** |
| 20334 |
* @module modules/image-editor |
| 20335 |
*/ |
| 20336 |
|
| 20337 |
|
| 20338 |
|
| 20339 |
jodit_config__WEBPACK_IMPORTED_MODULE_1__.Config.prototype.imageeditor = { |
| 20340 |
min_width: 20, |
| 20341 |
min_height: 20, |
| 20342 |
closeAfterSave: false, |
| 20343 |
width: '85%', |
| 20344 |
height: '85%', |
| 20345 |
crop: true, |
| 20346 |
resize: true, |
| 20347 |
resizeUseRatio: true, |
| 20348 |
resizeMinWidth: 20, |
| 20349 |
resizeMinHeight: 20, |
| 20350 |
cropUseRatio: true, |
| 20351 |
cropDefaultWidth: '70%', |
| 20352 |
cropDefaultHeight: '70%' |
| 20353 |
}; |
| 20354 |
jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_0__.Icon.set('crop', (_icons_crop_svg__WEBPACK_IMPORTED_MODULE_2___default())).set('resize', (_icons_resize_svg__WEBPACK_IMPORTED_MODULE_3___default())); |
| 20355 |
|
| 20356 |
|
| 20357 |
/***/ }), |
| 20358 |
|
| 20359 |
/***/ 54522: |
| 20360 |
/***/ (function(module) { |
| 20361 |
|
| 20362 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' x=\"0px\" y=\"0px\" viewBox=\"0 0 459 459\"> <g> <path d=\"M229.5,0C102,0,0,102,0,229.5S102,459,229.5,459c20.4,0,38.25-17.85,38.25-38.25c0-10.2-2.55-17.85-10.2-25.5 c-5.1-7.65-10.2-15.3-10.2-25.5c0-20.4,17.851-38.25,38.25-38.25h45.9c71.4,0,127.5-56.1,127.5-127.5C459,91.8,357,0,229.5,0z M89.25,229.5c-20.4,0-38.25-17.85-38.25-38.25S68.85,153,89.25,153s38.25,17.85,38.25,38.25S109.65,229.5,89.25,229.5z M165.75,127.5c-20.4,0-38.25-17.85-38.25-38.25S145.35,51,165.75,51S204,68.85,204,89.25S186.15,127.5,165.75,127.5z M293.25,127.5c-20.4,0-38.25-17.85-38.25-38.25S272.85,51,293.25,51s38.25,17.85,38.25,38.25S313.65,127.5,293.25,127.5z M369.75,229.5c-20.4,0-38.25-17.85-38.25-38.25S349.35,153,369.75,153S408,170.85,408,191.25S390.15,229.5,369.75,229.5z\" /> </g> </svg>" |
| 20363 |
|
| 20364 |
/***/ }), |
| 20365 |
|
| 20366 |
/***/ 54794: |
| 20367 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 20368 |
|
| 20369 |
"use strict"; |
| 20370 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 20371 |
/* harmony export */ fastClone: function() { return /* binding */ fastClone; }, |
| 20372 |
/* harmony export */ isAtom: function() { return /* binding */ isAtom; }, |
| 20373 |
/* harmony export */ markAsAtomic: function() { return /* binding */ markAsAtomic; } |
| 20374 |
/* harmony export */ }); |
| 20375 |
/* harmony import */ var jodit_core_helpers_string_stringify__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(3347); |
| 20376 |
/*! |
| 20377 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 20378 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 20379 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 20380 |
*/ /** |
| 20381 |
* @module helpers/utils |
| 20382 |
*/ |
| 20383 |
function isAtom(obj) { |
| 20384 |
return obj && obj.isAtom; |
| 20385 |
} |
| 20386 |
function markAsAtomic(obj) { |
| 20387 |
Object.defineProperty(obj, 'isAtom', { |
| 20388 |
enumerable: false, |
| 20389 |
value: true, |
| 20390 |
configurable: false |
| 20391 |
}); |
| 20392 |
return obj; |
| 20393 |
} |
| 20394 |
function fastClone(object) { |
| 20395 |
return JSON.parse((0,jodit_core_helpers_string_stringify__WEBPACK_IMPORTED_MODULE_0__.stringify)(object)); |
| 20396 |
} |
| 20397 |
|
| 20398 |
|
| 20399 |
/***/ }), |
| 20400 |
|
| 20401 |
/***/ 55184: |
| 20402 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 20403 |
|
| 20404 |
"use strict"; |
| 20405 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 20406 |
/* harmony export */ debounce: function() { return /* binding */ debounce; }, |
| 20407 |
/* harmony export */ throttle: function() { return /* binding */ throttle; } |
| 20408 |
/* harmony export */ }); |
| 20409 |
/* harmony import */ var jodit_core_component__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(16964); |
| 20410 |
/* harmony import */ var jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(28686); |
| 20411 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(28712); |
| 20412 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_2__); |
| 20413 |
/* harmony import */ var jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(33201); |
| 20414 |
/*! |
| 20415 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 20416 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 20417 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 20418 |
*/ /** |
| 20419 |
* [[include:core/decorators/debounce/README.md]] |
| 20420 |
* @packageDocumentation |
| 20421 |
* @module decorators/debounce |
| 20422 |
*/ |
| 20423 |
|
| 20424 |
|
| 20425 |
|
| 20426 |
function debounce(timeout, firstCallImmediately = false, method = 'debounce') { |
| 20427 |
return (target, propertyKey)=>{ |
| 20428 |
const fn = target[propertyKey]; |
| 20429 |
if (!(0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_1__.isFunction)(fn)) { |
| 20430 |
throw (0,jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_3__.error)('Handler must be a Function'); |
| 20431 |
} |
| 20432 |
target.hookStatus(jodit_core_component__WEBPACK_IMPORTED_MODULE_0__.STATUSES.ready, (component)=>{ |
| 20433 |
const { async } = component; |
| 20434 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_2__.assert)(async != null, `Component ${component.componentName || component.constructor.name} should have "async:IAsync" field`); |
| 20435 |
const propTimeout = (0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_1__.isFunction)(timeout) ? timeout(component) : timeout; |
| 20436 |
const realTimout = (0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_1__.isNumber)(propTimeout) || (0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_1__.isPlainObject)(propTimeout) ? propTimeout : component.defaultTimeout; |
| 20437 |
Object.defineProperty(component, propertyKey, { |
| 20438 |
configurable: true, |
| 20439 |
value: async[method](component[propertyKey].bind(component), realTimout, firstCallImmediately) |
| 20440 |
}); |
| 20441 |
}); |
| 20442 |
return { |
| 20443 |
configurable: true, |
| 20444 |
get () { |
| 20445 |
return fn.bind(this); |
| 20446 |
} |
| 20447 |
}; |
| 20448 |
}; |
| 20449 |
} |
| 20450 |
/** |
| 20451 |
* Wrap function in throttle wrapper |
| 20452 |
*/ function throttle(timeout, firstCallImmediately = false) { |
| 20453 |
return debounce(timeout, firstCallImmediately, 'throttle'); |
| 20454 |
} |
| 20455 |
|
| 20456 |
|
| 20457 |
/***/ }), |
| 20458 |
|
| 20459 |
/***/ 55376: |
| 20460 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 20461 |
|
| 20462 |
"use strict"; |
| 20463 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 20464 |
/* harmony export */ FileBrowserTree: function() { return /* binding */ FileBrowserTree; } |
| 20465 |
/* harmony export */ }); |
| 20466 |
/* harmony import */ var jodit_core_ui__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(4099); |
| 20467 |
/*! |
| 20468 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 20469 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 20470 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 20471 |
*/ |
| 20472 |
|
| 20473 |
class FileBrowserTree extends jodit_core_ui__WEBPACK_IMPORTED_MODULE_0__.UIGroup { |
| 20474 |
className() { |
| 20475 |
return 'FileBrowserTree'; |
| 20476 |
} |
| 20477 |
} |
| 20478 |
|
| 20479 |
|
| 20480 |
/***/ }), |
| 20481 |
|
| 20482 |
/***/ 55810: |
| 20483 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 20484 |
|
| 20485 |
"use strict"; |
| 20486 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 20487 |
/* harmony export */ init: function() { return /* binding */ init; } |
| 20488 |
/* harmony export */ }); |
| 20489 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 20490 |
/* harmony import */ var jodit_core_helpers_checker_is_imp_interface__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(52433); |
| 20491 |
/* harmony import */ var _load__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(3050); |
| 20492 |
/*! |
| 20493 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 20494 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 20495 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 20496 |
*/ /** |
| 20497 |
* @module plugin |
| 20498 |
*/ |
| 20499 |
|
| 20500 |
|
| 20501 |
/** |
| 20502 |
* Init plugin if it has no dependencies, in another case wait requires plugins will be init |
| 20503 |
* @private |
| 20504 |
*/ function init(jodit, pluginName, plugin, instance, doneList, waitingList, getContainer) { |
| 20505 |
if ((0,jodit_core_helpers_checker_is_imp_interface__WEBPACK_IMPORTED_MODULE_1__.isInitable)(instance)) { |
| 20506 |
try { |
| 20507 |
instance.init(jodit); |
| 20508 |
} catch (e) { |
| 20509 |
console.error(e); |
| 20510 |
if (!jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.IS_PROD) { |
| 20511 |
throw e; |
| 20512 |
} |
| 20513 |
} |
| 20514 |
} |
| 20515 |
doneList.set(pluginName, instance); |
| 20516 |
waitingList.delete(pluginName); |
| 20517 |
if (instance.hasStyle) { |
| 20518 |
(0,_load__WEBPACK_IMPORTED_MODULE_2__.loadStyle)(jodit, pluginName).catch((e)=>{ |
| 20519 |
!jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.IS_PROD && console.error(e); |
| 20520 |
}); |
| 20521 |
} |
| 20522 |
if (instance.styles) { |
| 20523 |
const style = getContainer(jodit, pluginName, 'style'); |
| 20524 |
style.innerHTML = instance.styles; |
| 20525 |
} |
| 20526 |
} |
| 20527 |
|
| 20528 |
|
| 20529 |
/***/ }), |
| 20530 |
|
| 20531 |
/***/ 56014: |
| 20532 |
/***/ (function(module) { |
| 20533 |
|
| 20534 |
module.exports["default"] = ["Napiš něco","O Jodit","Editor Jodit","Jodit Uživatelská příručka","obsahuje detailní nápovědu","Pro informace o licenci, prosím, přejděte na naši stránku:","Koupit plnou verzi","Copyright © XDSoft.net - Chupurnov Valeriy. Všechna práva vyhrazena.","Anchor","Otevřít v nové záložce","Otevřít v celoobrazovkovém režimu","Vyčistit formátování","Barva výplně a písma","Vpřed","Zpět","Tučné","Kurzíva","Odrážky","Číslovaný seznam","Zarovnat na střed","Zarovnat do bloku","Zarovnat vlevo","Zarovnat vpravo","Vložit horizontální linku","Vložit obrázek","Vložit soubor","Vložit video (YT/Vimeo)","Vložit odkaz","Velikost písma","Typ písma","Formátovat blok","Normální text","Nadpis 1","Nadpis 2","Nadpis 3","Nadpis 4","Citát","Kód","Vložit","Vložit tabulku","Zmenšit odsazení","Zvětšit odsazení","Vybrat speciální symbol","Vložit speciální symbol","Použít formát","Změnit mód","Okraje","horní","pravý","spodní","levý","Styly","Třídy","Zarovnání","Vpravo","Na střed","Vlevo","--nenastaveno--","src","Titulek","Alternativní text (alt)","Link","Otevřít link v nové záložce","Obrázek","soubor","Rozšířené","Vlastnosti obrázku","Zpět","Ok","Prohlížeč souborů","Chyba při načítání seznamu souborů","Chyba při načítání složek","Jste si jistý(á)?","Název složky","Vytvořit složku","název","Přetáhněte sem obrázek","Přetáhněte sem soubor","nebo klikněte","Alternativní text","Nahrát","Server","Pozadí","Text","Nahoru","Na střed","Dolu","Vložit sloupec před","Vložit sloupec za","Vložit řádek nad","Vložit řádek pod","Vymazat tabulku","Vymazat řádku","Vymazat sloupec","Vyčistit buňku","Znaky: %d","Slova: %d","Přeškrtnuto","Podtrženo","Horní index","Dolní index","Vyjmout označené","Označit vše","Zalomení","Najdi","Nahradit za","Vyměňte","Vložit","Vyber obsah pro vložení","HTML","tučně","kurzíva","štětec","odkaz","zpět","vpřed","tabulka","obrázek","guma","odstavec","velikost písma","video","písmo","о editoru","tisk","podtrženo","přeškrtnuto","zvětšit odsazení","zmenšit odsazení","celoobrazovkový režim","smrsknout","Linka","Odrážka","Číslovaný seznam","Vyjmout","Označit vše","Kód","Otevřít odkaz","Upravit odkaz","Atribut no-follow","Odstranit odkaz","Aktualizovat","Chcete-li upravit","Zobrazit","URL","Editovat","Horizontální zarovnání","Filtr","Dle poslední změny","Dle názvu","Dle velikosti","Přidat složku","Reset","Uložit","Uložit jako...","Změnit rozměr","Ořezat","Šířka","Výška","Ponechat poměr","Ano","Ne","Vyjmout","Označit","Označit %s","Vertikální zarovnání","Rozdělit","Spojit","Přidat sloupec","Přidat řádek","Licence: %s","Vymazat","Rozdělit vertikálně","Rozdělit horizontálně","Okraj","Váš text se podobá HTML. Vložit ho jako HTML?","Vložit jako HTML","Ponechat originál","Vložit jako TEXT","Vložit pouze TEXT","Můžete upravovat pouze své obrázky. Načíst obrázek?","Obrázek byl úspěšně nahrán!","paleta","V tomto adresáři nejsou žádné soubory.","přejmenovat","Zadejte nový název","náhled","Stažení","Vložit ze schránky","Váš prohlížeč nepodporuje přímý přístup do schránky.","Kopírovat výběr","kopírování","Border radius","Zobrazit všechny","Platí","Prosím, vyplňte toto pole","Prosím, zadejte webovou adresu","Výchozí","Kruh","Dot","Quadrate","Najít","Najít Předchozí","Najít Další","Obsah, který vkládáte, je pravděpodobně z Microsoft Word / Excel. Chcete ponechat formát nebo vložit pouze text?","Detekován fragment z Wordu nebo Excelu","Vyčistit","Vložte název třídy","Stiskněte Alt pro vlastní změnu velikosti",null,null,null,"Vše"] |
| 20535 |
|
| 20536 |
/***/ }), |
| 20537 |
|
| 20538 |
/***/ 56490: |
| 20539 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 20540 |
|
| 20541 |
"use strict"; |
| 20542 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 20543 |
/* harmony export */ Popup: function() { return /* reexport safe */ _popup__WEBPACK_IMPORTED_MODULE_0__.Popup; } |
| 20544 |
/* harmony export */ }); |
| 20545 |
/* harmony import */ var _popup__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(51116); |
| 20546 |
/*! |
| 20547 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 20548 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 20549 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 20550 |
*/ /** |
| 20551 |
* @module ui/popup |
| 20552 |
*/ |
| 20553 |
|
| 20554 |
|
| 20555 |
/***/ }), |
| 20556 |
|
| 20557 |
/***/ 57075: |
| 20558 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 20559 |
|
| 20560 |
"use strict"; |
| 20561 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 20562 |
/* harmony export */ previewBox: function() { return /* binding */ previewBox; } |
| 20563 |
/* harmony export */ }); |
| 20564 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 20565 |
/* harmony import */ var jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(85932); |
| 20566 |
/* harmony import */ var _attr__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(7909); |
| 20567 |
/* harmony import */ var _css__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(80991); |
| 20568 |
/* harmony import */ var _selector__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(28723); |
| 20569 |
/*! |
| 20570 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 20571 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 20572 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 20573 |
*/ /** |
| 20574 |
* @module helpers/utils |
| 20575 |
*/ |
| 20576 |
|
| 20577 |
|
| 20578 |
|
| 20579 |
|
| 20580 |
/** |
| 20581 |
* Fixes image sizes and sets absolute paths to images |
| 20582 |
*/ function fixedAssetsSizeAndAbsoluteLinks(editor, points) { |
| 20583 |
const restoreAttributes = []; |
| 20584 |
try { |
| 20585 |
(0,_selector__WEBPACK_IMPORTED_MODULE_4__.$$)('img', editor.editor).forEach((item)=>{ |
| 20586 |
const previousAttrs = [ |
| 20587 |
(0,_attr__WEBPACK_IMPORTED_MODULE_2__.attr)(item, 'width'), |
| 20588 |
(0,_attr__WEBPACK_IMPORTED_MODULE_2__.attr)(item, 'height'), |
| 20589 |
item.src |
| 20590 |
]; |
| 20591 |
(0,_attr__WEBPACK_IMPORTED_MODULE_2__.attr)(item, { |
| 20592 |
width: item.offsetWidth + points, |
| 20593 |
height: item.offsetHeight + points |
| 20594 |
}); |
| 20595 |
const a = editor.createInside.a(); |
| 20596 |
editor.ed.body.appendChild(a); |
| 20597 |
a.href = item.src; |
| 20598 |
item.src = a.href; |
| 20599 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(a); |
| 20600 |
restoreAttributes.push(()=>{ |
| 20601 |
var _previousAttrs_; |
| 20602 |
item.src = (_previousAttrs_ = previousAttrs[2]) !== null && _previousAttrs_ !== void 0 ? _previousAttrs_ : ''; |
| 20603 |
(0,_attr__WEBPACK_IMPORTED_MODULE_2__.attr)(item, { |
| 20604 |
width: previousAttrs[0] || null, |
| 20605 |
height: previousAttrs[1] || null |
| 20606 |
}); |
| 20607 |
}); |
| 20608 |
}); |
| 20609 |
} catch (e) { |
| 20610 |
restoreAttributes.forEach((c)=>c()); |
| 20611 |
restoreAttributes.length = 0; |
| 20612 |
throw e; |
| 20613 |
} |
| 20614 |
return restoreAttributes; |
| 20615 |
} |
| 20616 |
/** |
| 20617 |
* Generates a copy of an HTML document, resizes images, executes JS |
| 20618 |
* |
| 20619 |
* @event beforePreviewBox(string | undefined, 'pt' | 'px' | '') |
| 20620 |
* @event afterPreviewBox(HTMLElement) |
| 20621 |
*/ function previewBox(editor, defaultValue, points = 'px', container = null) { |
| 20622 |
const onDestruct = []; |
| 20623 |
const restoreAttributes = fixedAssetsSizeAndAbsoluteLinks(editor, points); |
| 20624 |
try { |
| 20625 |
const res = editor.e.fire('beforePreviewBox', defaultValue, points); |
| 20626 |
if (res != null) { |
| 20627 |
return res; |
| 20628 |
} |
| 20629 |
let div = editor.c.div('jodit__preview-box jodit-context'); |
| 20630 |
if (container) { |
| 20631 |
container.appendChild(div); |
| 20632 |
} |
| 20633 |
(0,_css__WEBPACK_IMPORTED_MODULE_3__.css)(div, { |
| 20634 |
position: 'relative', |
| 20635 |
padding: 16 |
| 20636 |
}); |
| 20637 |
const value = editor.value || `<div style='position: absolute;left:50%;top:50%;transform: translateX(-50%) translateY(-50%);color:#ccc;'>${editor.i18n('Empty')}</div>`; |
| 20638 |
if (editor.iframe) { |
| 20639 |
const iframe = editor.create.element('iframe'); |
| 20640 |
(0,_css__WEBPACK_IMPORTED_MODULE_3__.css)(iframe, { |
| 20641 |
minWidth: 800, |
| 20642 |
minHeight: 600, |
| 20643 |
border: 0 |
| 20644 |
}); |
| 20645 |
div.appendChild(iframe); |
| 20646 |
const myWindow = iframe.contentWindow; |
| 20647 |
if (myWindow) { |
| 20648 |
editor.e.fire('generateDocumentStructure.iframe', myWindow.document, editor); |
| 20649 |
div = myWindow.document.body; |
| 20650 |
if (typeof ResizeObserver === 'function') { |
| 20651 |
let destructed = false; |
| 20652 |
const elm = myWindow.document.body; |
| 20653 |
const resizeObserver = new ResizeObserver(editor.async.debounce(()=>{ |
| 20654 |
resizeObserver.unobserve(elm); |
| 20655 |
iframe.style.height = `${elm.offsetHeight + 20}px`; |
| 20656 |
editor.async.requestAnimationFrame(()=>{ |
| 20657 |
!destructed && resizeObserver.observe(elm); |
| 20658 |
}); |
| 20659 |
}, 100)); |
| 20660 |
const beforeDestruct = ()=>{ |
| 20661 |
destructed = true; |
| 20662 |
resizeObserver.unobserve(elm); |
| 20663 |
resizeObserver.disconnect(); |
| 20664 |
editor.e.off('beforeDestruct', beforeDestruct); |
| 20665 |
}; |
| 20666 |
onDestruct.push(beforeDestruct); |
| 20667 |
editor.e.on('beforeDestruct', beforeDestruct); |
| 20668 |
} |
| 20669 |
} |
| 20670 |
} else { |
| 20671 |
(0,_css__WEBPACK_IMPORTED_MODULE_3__.css)(div, { |
| 20672 |
minWidth: 1024, |
| 20673 |
minHeight: 600, |
| 20674 |
border: 0 |
| 20675 |
}); |
| 20676 |
} |
| 20677 |
const setHTML = (box, value)=>{ |
| 20678 |
const dv = (0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_1__.isString)(value) ? editor.c.div() : value; |
| 20679 |
if ((0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_1__.isString)(value)) { |
| 20680 |
dv.innerHTML = value; |
| 20681 |
} |
| 20682 |
for(let i = 0; i < dv.childNodes.length; i += 1){ |
| 20683 |
const c = dv.childNodes[i]; |
| 20684 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isElement(c)) { |
| 20685 |
const newNode = box.ownerDocument.createElement(c.nodeName); |
| 20686 |
for(let j = 0; j < c.attributes.length; j += 1){ |
| 20687 |
(0,_attr__WEBPACK_IMPORTED_MODULE_2__.attr)(newNode, c.attributes[j].nodeName, c.attributes[j].nodeValue); |
| 20688 |
} |
| 20689 |
if (c.childNodes.length === 0 || jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(c, 'table')) { |
| 20690 |
switch(c.nodeName){ |
| 20691 |
case 'SCRIPT': |
| 20692 |
if (c.textContent) { |
| 20693 |
newNode.textContent = c.textContent; |
| 20694 |
} |
| 20695 |
break; |
| 20696 |
default: |
| 20697 |
if (c.innerHTML) { |
| 20698 |
newNode.innerHTML = c.innerHTML; |
| 20699 |
} |
| 20700 |
break; |
| 20701 |
} |
| 20702 |
} else { |
| 20703 |
setHTML(newNode, c); |
| 20704 |
} |
| 20705 |
try { |
| 20706 |
box.appendChild(newNode); |
| 20707 |
} catch (unused) {} |
| 20708 |
} else { |
| 20709 |
try { |
| 20710 |
box.appendChild(c.cloneNode(true)); |
| 20711 |
} catch (unused) {} |
| 20712 |
} |
| 20713 |
} |
| 20714 |
}; |
| 20715 |
setHTML(div, value); |
| 20716 |
editor.e.fire('afterPreviewBox', div); |
| 20717 |
return [ |
| 20718 |
div, |
| 20719 |
()=>{ |
| 20720 |
onDestruct.forEach((cb)=>cb()); |
| 20721 |
} |
| 20722 |
]; |
| 20723 |
} finally{ |
| 20724 |
restoreAttributes.forEach((clb)=>clb()); |
| 20725 |
} |
| 20726 |
} |
| 20727 |
|
| 20728 |
|
| 20729 |
/***/ }), |
| 20730 |
|
| 20731 |
/***/ 57339: |
| 20732 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 20733 |
|
| 20734 |
"use strict"; |
| 20735 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 20736 |
/* harmony export */ readSizes: function() { return /* binding */ readSizes; } |
| 20737 |
/* harmony export */ }); |
| 20738 |
/* harmony import */ var _swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(49376); |
| 20739 |
/* harmony import */ var jodit_core_helpers_checker_is_numeric__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(70222); |
| 20740 |
/* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(7909); |
| 20741 |
/* harmony import */ var jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(80991); |
| 20742 |
/* harmony import */ var _utils_utils__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(10808); |
| 20743 |
|
| 20744 |
/*! |
| 20745 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 20746 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 20747 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 20748 |
*/ /** |
| 20749 |
* @module plugins/image-properties |
| 20750 |
*/ |
| 20751 |
|
| 20752 |
|
| 20753 |
|
| 20754 |
/** @private */ function readSizes(image, values, state) { |
| 20755 |
return (0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 20756 |
try { |
| 20757 |
yield image.decode(); |
| 20758 |
} catch (e) { |
| 20759 |
console.error(e); |
| 20760 |
} |
| 20761 |
const width = (0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_3__.css)(image, 'width', true) || (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_2__.attr)(image, 'width') || false; |
| 20762 |
const height = (0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_3__.css)(image, 'height', true) || (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_2__.attr)(image, 'height') || false; |
| 20763 |
values.imageWidth = width !== false ? (0,_utils_utils__WEBPACK_IMPORTED_MODULE_4__.normalSizeFromString)(width) : image.offsetWidth || image.naturalWidth; |
| 20764 |
if ((0,jodit_core_helpers_checker_is_numeric__WEBPACK_IMPORTED_MODULE_1__.isNumeric)(values.imageWidth)) { |
| 20765 |
values.imageHeight = height !== false ? (0,_utils_utils__WEBPACK_IMPORTED_MODULE_4__.normalSizeFromString)(height) : image.offsetHeight || image.naturalHeight; |
| 20766 |
} else { |
| 20767 |
values.imageHeight = height || ''; |
| 20768 |
} |
| 20769 |
const { imageWidth, imageHeight } = values; |
| 20770 |
const w = parseFloat(imageWidth.toString()); |
| 20771 |
if (!(0,jodit_core_helpers_checker_is_numeric__WEBPACK_IMPORTED_MODULE_1__.isNumeric)(imageWidth) || !(0,jodit_core_helpers_checker_is_numeric__WEBPACK_IMPORTED_MODULE_1__.isNumeric)(imageHeight)) { |
| 20772 |
state.sizeIsLocked = false; |
| 20773 |
return; |
| 20774 |
} |
| 20775 |
if (height === false) { |
| 20776 |
values.imageHeight = Math.round(w / state.ratio); |
| 20777 |
state.sizeIsLocked = true; |
| 20778 |
return; |
| 20779 |
} |
| 20780 |
const h = parseFloat(imageHeight.toString()); |
| 20781 |
state.sizeIsLocked = Math.abs(w - h * state.ratio) < 1; |
| 20782 |
})(); |
| 20783 |
} |
| 20784 |
|
| 20785 |
|
| 20786 |
/***/ }), |
| 20787 |
|
| 20788 |
/***/ 57456: |
| 20789 |
/***/ (function(module) { |
| 20790 |
|
| 20791 |
module.exports["default"] = ["Напишіть щось","Про Jodit","Редактор Jodit","Jodit інструкція користувача","містить детальну інформацію щодо користування","Щоб дізнатись більше про ліцензію , будь ласка, перейдіть на наш сайт:","Купити повну версію","Авторські права © XDSoft.net - Чупурнов Валерій. Всі права захищені.","Анкор","Відкрити у новій вкладці","Відкрити редактор в повному розмірі","Очистити форматування","Колір заливки або колір текста","Повторити","Відмінити","Жирний","Курсів","Вставити невпорядкований список","Вставити нумерованний список","Вирівняти по центру","Вирівняти по ширині","Вирівняти по лівому краю","Вирівняти по правому краю","Вставити горизонтальну лінію","Вставити зображення","Вставити файл","Вставити відео","Вставити посилання","Розмір шрифту","Шрифт","Вставити блочний елемент","Нормальний текст","Заголовок 1","Заголовок 2","Заголовок 3","Заголовок 4","Цитата","Код","Вставити","Вставити таблицю","Збільшити відступ","Зменшити відступ","Оберіть спеціальный символ","Вставити спеціальный символ","Формат краски","Джерело","Відступи","зверху","справа","знизу","зліва","Стилі","Класи","Вирівнювання","По правому краю","По центру","По лівому краю","--не встановлено--","src","Заголовок","Альтернативний текст (alt)","Посилання","Відкрити посилання в новій вкладці",null,"Файл","Розширені","Властивості зображення","Відміна","Ок","Браузер файлів","Помилка при завантаженні списку зображень","Помилка при завантаженні списку папок","Ви впевнені?","Введіть назву папки","Створити папку","введіть назву","Перетягніть зображення сюди","Перетягніть файл сюди","або клікніть","Альтернативный текст","Завантаження","Сервер","Фон","Текст"," Вгору","По центру","Донизу","Вставити стовпець до","Вставити стовпець після","Вставити рядок вище","Вставити рядок нижче","Видалити таблицю","Видалити рядок","Видалити стовпчик","Очистити кліинку","Символів: %d","Слів: %d","Закреслений","Підкреслений","верхній індекс","індекс","Обрізати вибране","Вибрати все","Межа","Шукати","Замінити на","Замінити","Вставити","Обрати контент для вставки","HTML","жирний","курсів","заливка","посилання","відмінити","повторити","таблиця","зображення","видалення","параграф","розмір шрифту","відео","шрифт","про редактор","друк","підкреслений","закреслений","відступ","заступ","на весь екран","звичайний розмір","лінія","Список","Нумерований список","Вирізати","Виділити все","Код","Відкрити посилання","Редагувати посилання","Атрибут nofollow","Видалити посилання","Оновити","Редагування","Перегляд","URL","Редагувати","Горизонтальне вирівнювання","Фільтр","Сортувати за зміною","Сортувати за ім'ям","Сортувати за розміром","Додати папку","Відновити","Зберегти","Зберегти як","Змінити розмір","Обрізати розмір","Ширина","Висота","Зберегти пропорції","Так","Ні","Видалити","Вибрати","Вибрати: %s","Вертикальне вирівнювання","Розділити","Об'єднати в одну","Додати стовпчик","Додати рядок","Ліцензія: %s","Видалити","Розділити по вертикалі","Розділити по горизонталі","Рамка","Текст, який Ви намагаєтесь вставити схожий на HTML. Вставити його як HTML?","Вставити його як HTML","Зберегти оригінал","Вставити як текст","Вставити тільки текст","Ви можете редагувати лише власні зображення. Завантажити зображення на ваш сервер?","Зображення успішно завантажено на сервер!","палітра","Файли відсутні","Змінити назву","Введіть нове імя'","Попередній перегляд","Завантажити","Вставити з буфера обміну","Ваш браузер не підтримує доступ до буфера обміну.","Копіювати виділене","копія","Радіус рамки","Показати все","Застосувати","Будь ласка, заповніть це поле","Будь ласка, введіть веб-адресу","За замовченням","Коло","Крапка","Квадрат","Знайти","Знайти попередні","Знайти наступні","Ви вставляєте контент з документа Microsoft Word або Excel. Бажаєте зберегти форматування?","Можливо це фрагмент Word або Excel","Почистити","Вставити клас","Натисніть Alt для зміни розміру",null,null,null,"Вибрати все"] |
| 20792 |
|
| 20793 |
/***/ }), |
| 20794 |
|
| 20795 |
/***/ 57626: |
| 20796 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 20797 |
|
| 20798 |
"use strict"; |
| 20799 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 20800 |
/* harmony export */ fuzzySearchIndex: function() { return /* binding */ fuzzySearchIndex; } |
| 20801 |
/* harmony export */ }); |
| 20802 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 20803 |
/*! |
| 20804 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 20805 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 20806 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 20807 |
*/ /** |
| 20808 |
* @module helpers/string |
| 20809 |
*/ |
| 20810 |
/** |
| 20811 |
* Finds the position of the substring in the string, if any, and returns the length of the found subsequence. |
| 20812 |
* Unlike `indexOf` ignores INVISIBLE_SPACE and may fail at `maxDistance` characters |
| 20813 |
*/ function fuzzySearchIndex(needle, haystack, offset = 0, maxDistance = 1) { |
| 20814 |
let i = 0, j = 0, startIndex = -1, len = 0, errorDistance = 0; |
| 20815 |
for(j = offset; i < needle.length && j < haystack.length;){ |
| 20816 |
if (needle[i].toLowerCase() === haystack[j].toLowerCase()) { |
| 20817 |
i++; |
| 20818 |
len++; |
| 20819 |
errorDistance = 0; |
| 20820 |
if (startIndex === -1) { |
| 20821 |
startIndex = j; |
| 20822 |
} |
| 20823 |
} else if (i > 0) { |
| 20824 |
if (errorDistance >= maxDistance && haystack[j] !== jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE) { |
| 20825 |
i = 0; |
| 20826 |
startIndex = -1; |
| 20827 |
len = 0; |
| 20828 |
errorDistance = 0; |
| 20829 |
j--; |
| 20830 |
} else { |
| 20831 |
errorDistance++; |
| 20832 |
len++; |
| 20833 |
} |
| 20834 |
} |
| 20835 |
j++; |
| 20836 |
} |
| 20837 |
return i === needle.length ? [ |
| 20838 |
startIndex, |
| 20839 |
len |
| 20840 |
] : [ |
| 20841 |
-1, |
| 20842 |
0 |
| 20843 |
]; |
| 20844 |
} |
| 20845 |
|
| 20846 |
|
| 20847 |
/***/ }), |
| 20848 |
|
| 20849 |
/***/ 57629: |
| 20850 |
/***/ (function(module) { |
| 20851 |
|
| 20852 |
/*! |
| 20853 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 20854 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 20855 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 20856 |
*/ module.exports = { |
| 20857 |
symbols: '符號' |
| 20858 |
}; |
| 20859 |
|
| 20860 |
|
| 20861 |
/***/ }), |
| 20862 |
|
| 20863 |
/***/ 57821: |
| 20864 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 20865 |
|
| 20866 |
"use strict"; |
| 20867 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 20868 |
/* harmony export */ camelCase: function() { return /* binding */ camelCase; } |
| 20869 |
/* harmony export */ }); |
| 20870 |
/*! |
| 20871 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 20872 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 20873 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 20874 |
*/ /** |
| 20875 |
* @module helpers/string |
| 20876 |
*/ /** |
| 20877 |
* Convert (kebab-case or snake_case) to camelCase |
| 20878 |
*/ const camelCase = (key)=>{ |
| 20879 |
return key.replace(/([-_])(.)/g, (m, code, letter)=>{ |
| 20880 |
return letter.toUpperCase(); |
| 20881 |
}); |
| 20882 |
}; |
| 20883 |
|
| 20884 |
|
| 20885 |
/***/ }), |
| 20886 |
|
| 20887 |
/***/ 58067: |
| 20888 |
/***/ (function(module) { |
| 20889 |
|
| 20890 |
/*! |
| 20891 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 20892 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 20893 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 20894 |
*/ module.exports = { |
| 20895 |
'copy-format': 'opmaak kopiëren' |
| 20896 |
}; |
| 20897 |
|
| 20898 |
|
| 20899 |
/***/ }), |
| 20900 |
|
| 20901 |
/***/ 58250: |
| 20902 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 20903 |
|
| 20904 |
"use strict"; |
| 20905 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 20906 |
/* harmony export */ ConnectionError: function() { return /* binding */ ConnectionError; } |
| 20907 |
/* harmony export */ }); |
| 20908 |
/*! |
| 20909 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 20910 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 20911 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 20912 |
*/ /** |
| 20913 |
* @module helpers/utils |
| 20914 |
*/ class ConnectionError extends Error { |
| 20915 |
constructor(m){ |
| 20916 |
super(m); |
| 20917 |
Object.setPrototypeOf(this, ConnectionError.prototype); |
| 20918 |
} |
| 20919 |
} |
| 20920 |
|
| 20921 |
|
| 20922 |
/***/ }), |
| 20923 |
|
| 20924 |
/***/ 58446: |
| 20925 |
/***/ (function(module) { |
| 20926 |
|
| 20927 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M1395 1184q0 13-10 23l-50 50q-10 10-23 10t-23-10l-393-393-393 393q-10 10-23 10t-23-10l-50-50q-10-10-10-23t10-23l466-466q10-10 23-10t23 10l466 466q10 10 10 23z\"/> </svg>" |
| 20928 |
|
| 20929 |
/***/ }), |
| 20930 |
|
| 20931 |
/***/ 58585: |
| 20932 |
/***/ (function(module) { |
| 20933 |
|
| 20934 |
/*! |
| 20935 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 20936 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 20937 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 20938 |
*/ module.exports = { |
| 20939 |
symbols: '符号' |
| 20940 |
}; |
| 20941 |
|
| 20942 |
|
| 20943 |
/***/ }), |
| 20944 |
|
| 20945 |
/***/ 58664: |
| 20946 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 20947 |
|
| 20948 |
"use strict"; |
| 20949 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 20950 |
/* harmony export */ FileBrowserItem: function() { return /* binding */ FileBrowserItem; } |
| 20951 |
/* harmony export */ }); |
| 20952 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 20953 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(65946); |
| 20954 |
/*! |
| 20955 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 20956 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 20957 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 20958 |
*/ /** |
| 20959 |
* @module modules/file-browser |
| 20960 |
*/ |
| 20961 |
|
| 20962 |
class FileBrowserItem { |
| 20963 |
static create(data) { |
| 20964 |
if (data instanceof FileBrowserItem) { |
| 20965 |
return data; |
| 20966 |
} |
| 20967 |
return new FileBrowserItem(data); |
| 20968 |
} |
| 20969 |
get path() { |
| 20970 |
return (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__.normalizePath)(this.data.source.path ? this.data.source.path + '/' : '/'); |
| 20971 |
} |
| 20972 |
get imageURL() { |
| 20973 |
const timestamp = this.time || new Date().getTime().toString(), { thumbIsAbsolute, source, thumb, file } = this.data, path = thumb || file; |
| 20974 |
return thumbIsAbsolute && path ? path : (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__.normalizeUrl)(source.baseurl, source.path, path || '') + '?_tmst=' + encodeURIComponent(timestamp); |
| 20975 |
} |
| 20976 |
get fileURL() { |
| 20977 |
let { name } = this.data; |
| 20978 |
const { file, fileIsAbsolute, source } = this.data; |
| 20979 |
if (file !== undefined) { |
| 20980 |
name = file; |
| 20981 |
} |
| 20982 |
return fileIsAbsolute && name ? name : (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__.normalizeUrl)(source.baseurl, source.path, name || ''); |
| 20983 |
} |
| 20984 |
get time() { |
| 20985 |
const { changed } = this.data; |
| 20986 |
return changed && (typeof changed === 'number' ? new Date(changed).toLocaleString() : changed) || ''; |
| 20987 |
} |
| 20988 |
get uniqueHashKey() { |
| 20989 |
const data = this.data; |
| 20990 |
let key = [ |
| 20991 |
data.sourceName, |
| 20992 |
data.name, |
| 20993 |
data.file, |
| 20994 |
this.time, |
| 20995 |
data.thumb |
| 20996 |
].join('_'); |
| 20997 |
key = key.toLowerCase().replace(/[^0-9a-z\-.]/g, '-'); |
| 20998 |
return key; |
| 20999 |
} |
| 21000 |
toJSON() { |
| 21001 |
return this.data; |
| 21002 |
} |
| 21003 |
constructor(data){ |
| 21004 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "data", void 0); |
| 21005 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "source", void 0); |
| 21006 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "sourceName", void 0); |
| 21007 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "type", void 0); |
| 21008 |
this.data = data; |
| 21009 |
// TODO Check with Object.assign |
| 21010 |
Object.keys(data).forEach((key)=>{ |
| 21011 |
this[key] = data[key]; |
| 21012 |
}); |
| 21013 |
} |
| 21014 |
} |
| 21015 |
|
| 21016 |
|
| 21017 |
/***/ }), |
| 21018 |
|
| 21019 |
/***/ 58881: |
| 21020 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 21021 |
|
| 21022 |
"use strict"; |
| 21023 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 21024 |
/* harmony export */ checkRemoveChar: function() { return /* binding */ checkRemoveChar; } |
| 21025 |
/* harmony export */ }); |
| 21026 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 21027 |
/* harmony import */ var jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(27795); |
| 21028 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(65946); |
| 21029 |
/* harmony import */ var jodit_plugins_backspace_helpers__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(15200); |
| 21030 |
/*! |
| 21031 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 21032 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 21033 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 21034 |
*/ /** |
| 21035 |
* @module plugins/backspace |
| 21036 |
*/ |
| 21037 |
|
| 21038 |
|
| 21039 |
|
| 21040 |
/** |
| 21041 |
* Check possibility the char can be removed |
| 21042 |
* |
| 21043 |
* @example |
| 21044 |
* ```html |
| 21045 |
* te|st |
| 21046 |
* ``` |
| 21047 |
* result |
| 21048 |
* ```html |
| 21049 |
* t|st |
| 21050 |
* ``` |
| 21051 |
* @private |
| 21052 |
*/ // eslint-disable-next-line complexity |
| 21053 |
function checkRemoveChar(jodit, fakeNode, backspace, mode) { |
| 21054 |
const step = backspace ? -1 : 1; |
| 21055 |
const anotherSibling = jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.sibling(fakeNode, !backspace); |
| 21056 |
let sibling = jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.sibling(fakeNode, backspace); |
| 21057 |
let removeNeighbor = null; |
| 21058 |
let charRemoved = false; |
| 21059 |
let removed; |
| 21060 |
if (!sibling) { |
| 21061 |
sibling = getNextInlineSibling(fakeNode, backspace, jodit.editor); |
| 21062 |
} |
| 21063 |
while(sibling && (jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isText(sibling) || jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isInlineBlock(sibling))){ |
| 21064 |
var _sibling_nodeValue, _sibling_nodeValue1; |
| 21065 |
while(jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isInlineBlock(sibling)){ |
| 21066 |
sibling = backspace ? sibling === null || sibling === void 0 ? void 0 : sibling.lastChild : sibling === null || sibling === void 0 ? void 0 : sibling.firstChild; |
| 21067 |
} |
| 21068 |
if (!sibling) { |
| 21069 |
break; |
| 21070 |
} |
| 21071 |
if ((_sibling_nodeValue = sibling.nodeValue) === null || _sibling_nodeValue === void 0 ? void 0 : _sibling_nodeValue.length) { |
| 21072 |
removed = tryRemoveChar(sibling, backspace, step, anotherSibling); |
| 21073 |
if (!sibling.nodeValue.length && jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isInlineBlock(sibling.parentNode)) { |
| 21074 |
sibling.nodeValue = jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE; |
| 21075 |
} |
| 21076 |
} |
| 21077 |
if (!((_sibling_nodeValue1 = sibling.nodeValue) === null || _sibling_nodeValue1 === void 0 ? void 0 : _sibling_nodeValue1.length)) { |
| 21078 |
removeNeighbor = sibling; |
| 21079 |
} |
| 21080 |
if (!(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_2__.isVoid)(removed) && removed !== jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE) { |
| 21081 |
checkRepeatRemoveCharAction(backspace, sibling, fakeNode, mode, removed, jodit); |
| 21082 |
charRemoved = true; |
| 21083 |
break; |
| 21084 |
} |
| 21085 |
const nextSibling = getNextInlineSibling(sibling, backspace, jodit.editor); |
| 21086 |
if (removeNeighbor) { |
| 21087 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.safeRemove(removeNeighbor); |
| 21088 |
removeNeighbor = null; |
| 21089 |
} |
| 21090 |
sibling = nextSibling; |
| 21091 |
} |
| 21092 |
if (removeNeighbor) { |
| 21093 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.safeRemove(removeNeighbor); |
| 21094 |
removeNeighbor = null; |
| 21095 |
} |
| 21096 |
if (charRemoved) { |
| 21097 |
removeEmptyForParent(fakeNode, 'a'); |
| 21098 |
addBRInsideEmptyBlock(jodit, fakeNode); |
| 21099 |
jodit.s.setCursorBefore(fakeNode); |
| 21100 |
if (jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isTag(fakeNode.previousSibling, 'br') && !jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.findNotEmptySibling(fakeNode, false)) { |
| 21101 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.after(fakeNode, jodit.createInside.element('br')); |
| 21102 |
} |
| 21103 |
} |
| 21104 |
return charRemoved; |
| 21105 |
} |
| 21106 |
function getNextInlineSibling(sibling, backspace, root) { |
| 21107 |
let nextSibling = jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.sibling(sibling, backspace); |
| 21108 |
if (!nextSibling && sibling.parentNode && sibling.parentNode !== root) { |
| 21109 |
nextSibling = (0,jodit_plugins_backspace_helpers__WEBPACK_IMPORTED_MODULE_3__.findMostNestedNeighbor)(sibling, !backspace, root, true); |
| 21110 |
} |
| 21111 |
return nextSibling; |
| 21112 |
} |
| 21113 |
/** |
| 21114 |
* Helper removes all empty inline parents |
| 21115 |
*/ function removeEmptyForParent(node, tags) { |
| 21116 |
let parent = node.parentElement; |
| 21117 |
while(parent && jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isInlineBlock(parent) && jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isTag(parent, tags)){ |
| 21118 |
const p = parent.parentElement; |
| 21119 |
if (jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isEmpty(parent)) { |
| 21120 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.after(parent, node); |
| 21121 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.safeRemove(parent); |
| 21122 |
} |
| 21123 |
parent = p; |
| 21124 |
} |
| 21125 |
} |
| 21126 |
/** |
| 21127 |
* Helper add BR element inside empty block element |
| 21128 |
*/ function addBRInsideEmptyBlock(jodit, node) { |
| 21129 |
if (node.parentElement !== jodit.editor && jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isBlock(node.parentElement) && jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.each(node.parentElement, jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isEmptyTextNode)) { |
| 21130 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.after(node, jodit.createInside.element('br')); |
| 21131 |
} |
| 21132 |
} |
| 21133 |
function tryRemoveChar(sibling, backspace, step, anotherSibling) { |
| 21134 |
// For Unicode escapes |
| 21135 |
let value = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_2__.toArray)(sibling.nodeValue); |
| 21136 |
const length = value.length; |
| 21137 |
let index = backspace ? length - 1 : 0; |
| 21138 |
if (value[index] === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE) { |
| 21139 |
while(value[index] === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE){ |
| 21140 |
index += step; |
| 21141 |
} |
| 21142 |
} |
| 21143 |
const removed = value[index]; |
| 21144 |
if (value[index + step] === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE) { |
| 21145 |
index += step; |
| 21146 |
while(value[index] === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE){ |
| 21147 |
index += step; |
| 21148 |
} |
| 21149 |
index += backspace ? 1 : -1; |
| 21150 |
} |
| 21151 |
if (backspace && index < 0) { |
| 21152 |
value = []; |
| 21153 |
} else { |
| 21154 |
value = value.slice(backspace ? 0 : index + 1, backspace ? index : length); |
| 21155 |
} |
| 21156 |
replaceSpaceOnNBSP(anotherSibling, backspace, value); |
| 21157 |
sibling.nodeValue = value.join(''); |
| 21158 |
return removed; |
| 21159 |
} |
| 21160 |
function replaceSpaceOnNBSP(anotherSibling, backspace, value) { |
| 21161 |
var _anotherSibling_nodeValue; |
| 21162 |
if (!anotherSibling || !jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isText(anotherSibling) || (!backspace ? / $/ : /^ /).test((_anotherSibling_nodeValue = anotherSibling.nodeValue) !== null && _anotherSibling_nodeValue !== void 0 ? _anotherSibling_nodeValue : '') || !(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_2__.trimInv)(anotherSibling.nodeValue || '').length) { |
| 21163 |
for(let i = backspace ? value.length - 1 : 0; backspace ? i >= 0 : i < value.length; i += backspace ? -1 : 1){ |
| 21164 |
if (value[i] === ' ') { |
| 21165 |
value[i] = jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.NBSP_SPACE; |
| 21166 |
} else { |
| 21167 |
break; |
| 21168 |
} |
| 21169 |
} |
| 21170 |
} |
| 21171 |
} |
| 21172 |
function checkRepeatRemoveCharAction(backspace, sibling, fakeNode, mode, removed, jodit) { |
| 21173 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_2__.call)(backspace ? jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.after : jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.before, sibling, fakeNode); |
| 21174 |
if (mode === 'sentence' || mode === 'word' && removed !== ' ' && removed !== jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.NBSP_SPACE) { |
| 21175 |
checkRemoveChar(jodit, fakeNode, backspace, mode); |
| 21176 |
} |
| 21177 |
} |
| 21178 |
|
| 21179 |
|
| 21180 |
/***/ }), |
| 21181 |
|
| 21182 |
/***/ 59399: |
| 21183 |
/***/ (function(__unused_webpack_module, __webpack_exports__) { |
| 21184 |
|
| 21185 |
"use strict"; |
| 21186 |
/*! |
| 21187 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 21188 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 21189 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 21190 |
*/ /** |
| 21191 |
* @module plugins/inline-popup |
| 21192 |
*/ /* harmony default export */ __webpack_exports__["default"] = ([ |
| 21193 |
'bold', |
| 21194 |
'italic', |
| 21195 |
'|', |
| 21196 |
'ul', |
| 21197 |
'ol', |
| 21198 |
'eraser', |
| 21199 |
'|', |
| 21200 |
'fontsize', |
| 21201 |
'brush', |
| 21202 |
'paragraph', |
| 21203 |
'---', |
| 21204 |
'image', |
| 21205 |
'table', |
| 21206 |
'\n', |
| 21207 |
'link', |
| 21208 |
'|', |
| 21209 |
'align', |
| 21210 |
'|', |
| 21211 |
'undo', |
| 21212 |
'redo', |
| 21213 |
'|', |
| 21214 |
'copyformat', |
| 21215 |
'fullsize', |
| 21216 |
'---', |
| 21217 |
'dots' |
| 21218 |
]); |
| 21219 |
|
| 21220 |
|
| 21221 |
/***/ }), |
| 21222 |
|
| 21223 |
/***/ 59400: |
| 21224 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 21225 |
|
| 21226 |
"use strict"; |
| 21227 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 21228 |
/* harmony export */ Button: function() { return /* reexport safe */ _button_button__WEBPACK_IMPORTED_MODULE_0__.Button; }, |
| 21229 |
/* harmony export */ UIButton: function() { return /* reexport safe */ _button_button__WEBPACK_IMPORTED_MODULE_0__.UIButton; }, |
| 21230 |
/* harmony export */ UIButtonGroup: function() { return /* reexport safe */ _group_group__WEBPACK_IMPORTED_MODULE_1__.UIButtonGroup; }, |
| 21231 |
/* harmony export */ UIButtonState: function() { return /* reexport safe */ _button_button__WEBPACK_IMPORTED_MODULE_0__.UIButtonState; }, |
| 21232 |
/* harmony export */ UITooltip: function() { return /* reexport safe */ _tooltip_tooltip__WEBPACK_IMPORTED_MODULE_2__.UITooltip; } |
| 21233 |
/* harmony export */ }); |
| 21234 |
/* harmony import */ var _button_button__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(53681); |
| 21235 |
/* harmony import */ var _group_group__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(15367); |
| 21236 |
/* harmony import */ var _tooltip_tooltip__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(95399); |
| 21237 |
/*! |
| 21238 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 21239 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 21240 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 21241 |
*/ /** |
| 21242 |
* [[include:core/ui/button/README.md]] |
| 21243 |
* @packageDocumentation |
| 21244 |
* @module ui/button |
| 21245 |
*/ |
| 21246 |
|
| 21247 |
|
| 21248 |
|
| 21249 |
|
| 21250 |
/***/ }), |
| 21251 |
|
| 21252 |
/***/ 59488: |
| 21253 |
/***/ (function(module) { |
| 21254 |
|
| 21255 |
/*! |
| 21256 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 21257 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 21258 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 21259 |
*/ module.exports = { |
| 21260 |
symbols: 'Symbol' |
| 21261 |
}; |
| 21262 |
|
| 21263 |
|
| 21264 |
/***/ }), |
| 21265 |
|
| 21266 |
/***/ 59609: |
| 21267 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 21268 |
|
| 21269 |
"use strict"; |
| 21270 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 21271 |
/* harmony export */ ViewComponent: function() { return /* binding */ ViewComponent; } |
| 21272 |
/* harmony export */ }); |
| 21273 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 21274 |
/* harmony import */ var _component__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(80251); |
| 21275 |
/*! |
| 21276 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 21277 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 21278 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 21279 |
*/ /** |
| 21280 |
* @module component |
| 21281 |
*/ |
| 21282 |
|
| 21283 |
class ViewComponent extends _component__WEBPACK_IMPORTED_MODULE_1__.Component { |
| 21284 |
/** |
| 21285 |
* Shortcut for `this.jodit` |
| 21286 |
*/ get j() { |
| 21287 |
return this.jodit; |
| 21288 |
} |
| 21289 |
get defaultTimeout() { |
| 21290 |
return this.j.defaultTimeout; |
| 21291 |
} |
| 21292 |
i18n(text, ...params) { |
| 21293 |
return this.j.i18n(text, ...params); |
| 21294 |
} |
| 21295 |
/** |
| 21296 |
* Attach component to View |
| 21297 |
*/ setParentView(jodit) { |
| 21298 |
this.jodit = jodit; |
| 21299 |
jodit.components.add(this); |
| 21300 |
return this; |
| 21301 |
} |
| 21302 |
/** @override */ destruct() { |
| 21303 |
this.j.components.delete(this); |
| 21304 |
return super.destruct(); |
| 21305 |
} |
| 21306 |
constructor(jodit){ |
| 21307 |
super(), /** |
| 21308 |
* Parent View element |
| 21309 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "jodit", void 0); |
| 21310 |
this.setParentView(jodit); |
| 21311 |
} |
| 21312 |
} |
| 21313 |
|
| 21314 |
|
| 21315 |
/***/ }), |
| 21316 |
|
| 21317 |
/***/ 59758: |
| 21318 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 21319 |
|
| 21320 |
"use strict"; |
| 21321 |
/* unused harmony export redoUndo */ |
| 21322 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 21323 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(81937); |
| 21324 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(28077); |
| 21325 |
/* harmony import */ var jodit_core_plugin_plugin__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(18855); |
| 21326 |
/* harmony import */ var jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(29434); |
| 21327 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(5266); |
| 21328 |
/* harmony import */ var _icons_redo_svg__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(34045); |
| 21329 |
/* harmony import */ var _icons_redo_svg__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(_icons_redo_svg__WEBPACK_IMPORTED_MODULE_6__); |
| 21330 |
/* harmony import */ var _icons_undo_svg__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(39199); |
| 21331 |
/* harmony import */ var _icons_undo_svg__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(_icons_undo_svg__WEBPACK_IMPORTED_MODULE_7__); |
| 21332 |
/*! |
| 21333 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 21334 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 21335 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 21336 |
*/ /** |
| 21337 |
* [[include:plugins/redo-undo/README.md]] |
| 21338 |
* @packageDocumentation |
| 21339 |
* @module plugins/redo-undo |
| 21340 |
*/ |
| 21341 |
|
| 21342 |
|
| 21343 |
|
| 21344 |
|
| 21345 |
|
| 21346 |
|
| 21347 |
|
| 21348 |
jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_4__.Icon.set('redo', (_icons_redo_svg__WEBPACK_IMPORTED_MODULE_6___default())).set('undo', (_icons_undo_svg__WEBPACK_IMPORTED_MODULE_7___default())); |
| 21349 |
jodit_config__WEBPACK_IMPORTED_MODULE_5__.Config.prototype.controls.redo = { |
| 21350 |
mode: jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.MODE_SPLIT, |
| 21351 |
isDisabled: (editor)=>!editor.history.canRedo(), |
| 21352 |
tooltip: 'Redo' |
| 21353 |
}; |
| 21354 |
jodit_config__WEBPACK_IMPORTED_MODULE_5__.Config.prototype.controls.undo = { |
| 21355 |
mode: jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.MODE_SPLIT, |
| 21356 |
isDisabled: (editor)=>!editor.history.canUndo(), |
| 21357 |
tooltip: 'Undo' |
| 21358 |
}; |
| 21359 |
/** |
| 21360 |
* Custom process Redo and Undo functionality |
| 21361 |
*/ class redoUndo extends jodit_core_plugin_plugin__WEBPACK_IMPORTED_MODULE_3__.Plugin { |
| 21362 |
beforeDestruct() { |
| 21363 |
// do nothing |
| 21364 |
} |
| 21365 |
afterInit(editor) { |
| 21366 |
const callback = (command)=>{ |
| 21367 |
editor.history[command](); |
| 21368 |
return false; |
| 21369 |
}; |
| 21370 |
editor.registerCommand('redo', { |
| 21371 |
exec: callback, |
| 21372 |
hotkeys: [ |
| 21373 |
'ctrl+y', |
| 21374 |
'ctrl+shift+z', |
| 21375 |
'cmd+y', |
| 21376 |
'cmd+shift+z' |
| 21377 |
] |
| 21378 |
}); |
| 21379 |
editor.registerCommand('undo', { |
| 21380 |
exec: callback, |
| 21381 |
hotkeys: [ |
| 21382 |
'ctrl+z', |
| 21383 |
'cmd+z' |
| 21384 |
] |
| 21385 |
}); |
| 21386 |
} |
| 21387 |
constructor(...args){ |
| 21388 |
super(...args), /** @override */ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "buttons", [ |
| 21389 |
{ |
| 21390 |
name: 'undo', |
| 21391 |
group: 'history' |
| 21392 |
}, |
| 21393 |
{ |
| 21394 |
name: 'redo', |
| 21395 |
group: 'history' |
| 21396 |
} |
| 21397 |
]); |
| 21398 |
} |
| 21399 |
} |
| 21400 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_2__.pluginSystem.add('redoUndo', redoUndo); |
| 21401 |
|
| 21402 |
|
| 21403 |
/***/ }), |
| 21404 |
|
| 21405 |
/***/ 59807: |
| 21406 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 21407 |
|
| 21408 |
"use strict"; |
| 21409 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 21410 |
/* harmony export */ LocalStorageProvider: function() { return /* binding */ LocalStorageProvider; }, |
| 21411 |
/* harmony export */ canUsePersistentStorage: function() { return /* binding */ canUsePersistentStorage; } |
| 21412 |
/* harmony export */ }); |
| 21413 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 21414 |
/*! |
| 21415 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 21416 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 21417 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 21418 |
*/ /** |
| 21419 |
* @module storage |
| 21420 |
*/ |
| 21421 |
/** |
| 21422 |
* Check if user disable local storages/cookie etc. |
| 21423 |
*/ const canUsePersistentStorage = (strategy = 'localStorage')=>{ |
| 21424 |
const cache = new Map(); |
| 21425 |
return (()=>{ |
| 21426 |
if (cache.has(strategy)) { |
| 21427 |
return cache.get(strategy); |
| 21428 |
} |
| 21429 |
const tmpKey = '___Jodit___' + Math.random().toString(); |
| 21430 |
const storage = strategy === 'sessionStorage' ? sessionStorage : localStorage; |
| 21431 |
try { |
| 21432 |
storage.setItem(tmpKey, '1'); |
| 21433 |
const result = storage.getItem(tmpKey) === '1'; |
| 21434 |
storage.removeItem(tmpKey); |
| 21435 |
cache.set(strategy, result); |
| 21436 |
return result; |
| 21437 |
} catch (unused) {} |
| 21438 |
cache.set(strategy, false); |
| 21439 |
return false; |
| 21440 |
})(); |
| 21441 |
}; |
| 21442 |
/** |
| 21443 |
* Persistent storage in localStorage or sessionStorage |
| 21444 |
*/ class LocalStorageProvider { |
| 21445 |
get storage() { |
| 21446 |
return this.strategy === 'sessionStorage' ? sessionStorage : localStorage; |
| 21447 |
} |
| 21448 |
set(key, value) { |
| 21449 |
try { |
| 21450 |
const buffer = this.storage.getItem(this.rootKey); |
| 21451 |
const json = buffer ? JSON.parse(buffer) : {}; |
| 21452 |
json[key] = value; |
| 21453 |
this.storage.setItem(this.rootKey, JSON.stringify(json)); |
| 21454 |
} catch (unused) {} |
| 21455 |
return this; |
| 21456 |
} |
| 21457 |
delete(key) { |
| 21458 |
try { |
| 21459 |
this.storage.removeItem(this.rootKey); |
| 21460 |
} catch (unused) {} |
| 21461 |
return this; |
| 21462 |
} |
| 21463 |
get(key) { |
| 21464 |
try { |
| 21465 |
const buffer = this.storage.getItem(this.rootKey); |
| 21466 |
const json = buffer ? JSON.parse(buffer) : {}; |
| 21467 |
return json[key] !== undefined ? json[key] : undefined; |
| 21468 |
} catch (unused) {} |
| 21469 |
} |
| 21470 |
exists(key) { |
| 21471 |
return this.get(key) != null; |
| 21472 |
} |
| 21473 |
clear() { |
| 21474 |
try { |
| 21475 |
this.storage.removeItem(this.rootKey); |
| 21476 |
} catch (unused) {} |
| 21477 |
return this; |
| 21478 |
} |
| 21479 |
constructor(rootKey, strategy = 'localStorage'){ |
| 21480 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "rootKey", void 0); |
| 21481 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "strategy", void 0); |
| 21482 |
this.rootKey = rootKey; |
| 21483 |
this.strategy = strategy; |
| 21484 |
} |
| 21485 |
} |
| 21486 |
|
| 21487 |
|
| 21488 |
/***/ }), |
| 21489 |
|
| 21490 |
/***/ 59841: |
| 21491 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 21492 |
|
| 21493 |
"use strict"; |
| 21494 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 21495 |
/* harmony export */ CommitStyle: function() { return /* reexport safe */ _style_commit_style__WEBPACK_IMPORTED_MODULE_1__.CommitStyle; }, |
| 21496 |
/* harmony export */ Selection: function() { return /* reexport safe */ _selection__WEBPACK_IMPORTED_MODULE_0__.Selection; } |
| 21497 |
/* harmony export */ }); |
| 21498 |
/* harmony import */ var _selection__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(98595); |
| 21499 |
/* harmony import */ var _style_commit_style__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(84578); |
| 21500 |
/*! |
| 21501 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 21502 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 21503 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 21504 |
*/ /** |
| 21505 |
* @module selection |
| 21506 |
*/ |
| 21507 |
|
| 21508 |
|
| 21509 |
|
| 21510 |
|
| 21511 |
/***/ }), |
| 21512 |
|
| 21513 |
/***/ 60162: |
| 21514 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 21515 |
|
| 21516 |
"use strict"; |
| 21517 |
/* harmony import */ var jodit_core_helpers_utils_data_bind__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(36400); |
| 21518 |
/* harmony import */ var jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(29434); |
| 21519 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5266); |
| 21520 |
/* harmony import */ var _icons_ol_svg__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(40037); |
| 21521 |
/* harmony import */ var _icons_ol_svg__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_icons_ol_svg__WEBPACK_IMPORTED_MODULE_3__); |
| 21522 |
/* harmony import */ var _icons_ul_svg__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(83207); |
| 21523 |
/* harmony import */ var _icons_ul_svg__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_icons_ul_svg__WEBPACK_IMPORTED_MODULE_4__); |
| 21524 |
/*! |
| 21525 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 21526 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 21527 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 21528 |
*/ /** |
| 21529 |
* @module plugins/ordered-list |
| 21530 |
*/ |
| 21531 |
|
| 21532 |
|
| 21533 |
|
| 21534 |
|
| 21535 |
const memoExec = (jodit, _, { control })=>{ |
| 21536 |
var _ref; |
| 21537 |
const key = `button${control.command}`; |
| 21538 |
const value = (_ref = control.args && control.args[0]) !== null && _ref !== void 0 ? _ref : (0,jodit_core_helpers_utils_data_bind__WEBPACK_IMPORTED_MODULE_0__.dataBind)(jodit, key); |
| 21539 |
(0,jodit_core_helpers_utils_data_bind__WEBPACK_IMPORTED_MODULE_0__.dataBind)(jodit, key, value); |
| 21540 |
jodit.execCommand(control.command, false, value === 'default' ? null : value); |
| 21541 |
}; |
| 21542 |
jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_1__.Icon.set('ol', (_icons_ol_svg__WEBPACK_IMPORTED_MODULE_3___default())).set('ul', (_icons_ul_svg__WEBPACK_IMPORTED_MODULE_4___default())); |
| 21543 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.controls.ul = { |
| 21544 |
command: 'insertUnorderedList', |
| 21545 |
tags: [ |
| 21546 |
'ul' |
| 21547 |
], |
| 21548 |
tooltip: 'Insert Unordered List', |
| 21549 |
list: { |
| 21550 |
default: 'Default', |
| 21551 |
circle: 'Circle', |
| 21552 |
disc: 'Dot', |
| 21553 |
square: 'Quadrate' |
| 21554 |
}, |
| 21555 |
exec: memoExec |
| 21556 |
}; |
| 21557 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.controls.ol = { |
| 21558 |
command: 'insertOrderedList', |
| 21559 |
tags: [ |
| 21560 |
'ol' |
| 21561 |
], |
| 21562 |
tooltip: 'Insert Ordered List', |
| 21563 |
list: { |
| 21564 |
default: 'Default', |
| 21565 |
'lower-alpha': 'Lower Alpha', |
| 21566 |
'lower-greek': 'Lower Greek', |
| 21567 |
'lower-roman': 'Lower Roman', |
| 21568 |
'upper-alpha': 'Upper Alpha', |
| 21569 |
'upper-roman': 'Upper Roman' |
| 21570 |
}, |
| 21571 |
exec: memoExec |
| 21572 |
}; |
| 21573 |
|
| 21574 |
|
| 21575 |
/***/ }), |
| 21576 |
|
| 21577 |
/***/ 60216: |
| 21578 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 21579 |
|
| 21580 |
"use strict"; |
| 21581 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 21582 |
/* harmony export */ Eventify: function() { return /* binding */ Eventify; } |
| 21583 |
/* harmony export */ }); |
| 21584 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 21585 |
/*! |
| 21586 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 21587 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 21588 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 21589 |
*/ /** |
| 21590 |
* @module event-emitter |
| 21591 |
*/ |
| 21592 |
/** |
| 21593 |
* Class for adding event handling capability |
| 21594 |
* |
| 21595 |
* ```ts |
| 21596 |
* class SomeClass extends Eventify<{ start: (node: Node) => boolean; }> { |
| 21597 |
* constructor() { |
| 21598 |
* super(); |
| 21599 |
* setTimeout(() => { |
| 21600 |
* if (this.emit('start', document.body)) { |
| 21601 |
* console.log('yes'); |
| 21602 |
* }; |
| 21603 |
* }, 100); |
| 21604 |
* } |
| 21605 |
* } |
| 21606 |
* |
| 21607 |
* const sm = new SomeClass(); |
| 21608 |
* sm.on('start', (node) => { |
| 21609 |
* console.log(node); |
| 21610 |
* return true; |
| 21611 |
* }) |
| 21612 |
* ``` |
| 21613 |
*/ class Eventify { |
| 21614 |
on(name, func) { |
| 21615 |
var _this___map_get; |
| 21616 |
if (!this.__map.has(name)) { |
| 21617 |
this.__map.set(name, new Set()); |
| 21618 |
} |
| 21619 |
(_this___map_get = this.__map.get(name)) === null || _this___map_get === void 0 ? void 0 : _this___map_get.add(func); |
| 21620 |
return this; |
| 21621 |
} |
| 21622 |
off(name, func) { |
| 21623 |
if (this.__map.has(name)) { |
| 21624 |
var _this___map_get; |
| 21625 |
(_this___map_get = this.__map.get(name)) === null || _this___map_get === void 0 ? void 0 : _this___map_get.delete(func); |
| 21626 |
} |
| 21627 |
return this; |
| 21628 |
} |
| 21629 |
destruct() { |
| 21630 |
this.__map.clear(); |
| 21631 |
} |
| 21632 |
emit(name, ...args) { |
| 21633 |
let result; |
| 21634 |
if (this.__map.has(name)) { |
| 21635 |
var _this___map_get; |
| 21636 |
(_this___map_get = this.__map.get(name)) === null || _this___map_get === void 0 ? void 0 : _this___map_get.forEach((cb)=>{ |
| 21637 |
result = cb(...args); |
| 21638 |
}); |
| 21639 |
} |
| 21640 |
return result; |
| 21641 |
} |
| 21642 |
constructor(){ |
| 21643 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__map", new Map()); |
| 21644 |
} |
| 21645 |
} |
| 21646 |
|
| 21647 |
|
| 21648 |
/***/ }), |
| 21649 |
|
| 21650 |
/***/ 60636: |
| 21651 |
/***/ (function(module) { |
| 21652 |
|
| 21653 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M1792 1344v128q0 26-19 45t-45 19h-1664q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1664q26 0 45 19t19 45zm-384-384v128q0 26-19 45t-45 19h-896q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h896q26 0 45 19t19 45zm256-384v128q0 26-19 45t-45 19h-1408q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1408q26 0 45 19t19 45zm-384-384v128q0 26-19 45t-45 19h-640q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h640q26 0 45 19t19 45z\"/> </svg>" |
| 21654 |
|
| 21655 |
/***/ }), |
| 21656 |
|
| 21657 |
/***/ 60898: |
| 21658 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 21659 |
|
| 21660 |
"use strict"; |
| 21661 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 21662 |
/* harmony export */ inView: function() { return /* binding */ inView; }, |
| 21663 |
/* harmony export */ scrollIntoViewIfNeeded: function() { return /* binding */ scrollIntoViewIfNeeded; } |
| 21664 |
/* harmony export */ }); |
| 21665 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 21666 |
/*! |
| 21667 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 21668 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 21669 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 21670 |
*/ /** |
| 21671 |
* @module helpers/utils |
| 21672 |
*/ |
| 21673 |
/** |
| 21674 |
* @module helpers/utils |
| 21675 |
*/ /** |
| 21676 |
* Check if element is in view |
| 21677 |
*/ function inView(elm, root, doc) { |
| 21678 |
let rect = elm.getBoundingClientRect(), el = elm; |
| 21679 |
const top = rect.top, height = rect.height; |
| 21680 |
while(el && el !== root && el.parentNode){ |
| 21681 |
el = el.parentNode; |
| 21682 |
rect = el.getBoundingClientRect(); |
| 21683 |
if (!(top <= rect.bottom)) { |
| 21684 |
return false; |
| 21685 |
} |
| 21686 |
// Check if the element is out of view due to a container scrolling |
| 21687 |
if (top + height <= rect.top) { |
| 21688 |
return false; |
| 21689 |
} |
| 21690 |
} |
| 21691 |
// Check it's within the document viewport |
| 21692 |
return top <= (doc.documentElement && doc.documentElement.clientHeight || 0); |
| 21693 |
} |
| 21694 |
/** |
| 21695 |
* Scroll element into view if it is not in view |
| 21696 |
*/ function scrollIntoViewIfNeeded(elm, root, doc) { |
| 21697 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isHTMLElement(elm) && !inView(elm, root, doc)) { |
| 21698 |
if (root.clientHeight !== root.scrollHeight) { |
| 21699 |
root.scrollTop = elm.offsetTop; |
| 21700 |
} |
| 21701 |
if (!inView(elm, root, doc)) { |
| 21702 |
elm.scrollIntoView(); |
| 21703 |
} |
| 21704 |
} |
| 21705 |
} |
| 21706 |
|
| 21707 |
|
| 21708 |
/***/ }), |
| 21709 |
|
| 21710 |
/***/ 60936: |
| 21711 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 21712 |
|
| 21713 |
"use strict"; |
| 21714 |
__webpack_require__.r(__webpack_exports__); |
| 21715 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 21716 |
/* harmony export */ Ajax: function() { return /* reexport safe */ jodit_core_request__WEBPACK_IMPORTED_MODULE_10__.Ajax; }, |
| 21717 |
/* harmony export */ Alert: function() { return /* reexport safe */ _dialog___WEBPACK_IMPORTED_MODULE_3__.Alert; }, |
| 21718 |
/* harmony export */ Async: function() { return /* reexport safe */ jodit_core_async__WEBPACK_IMPORTED_MODULE_5__.Async; }, |
| 21719 |
/* harmony export */ AsyncStorage: function() { return /* reexport safe */ jodit_core_storage__WEBPACK_IMPORTED_MODULE_26__.AsyncStorage; }, |
| 21720 |
/* harmony export */ Button: function() { return /* reexport safe */ jodit_core_ui__WEBPACK_IMPORTED_MODULE_11__.Button; }, |
| 21721 |
/* harmony export */ CommitStyle: function() { return /* reexport safe */ jodit_core_selection__WEBPACK_IMPORTED_MODULE_25__.CommitStyle; }, |
| 21722 |
/* harmony export */ Component: function() { return /* reexport safe */ jodit_core_component__WEBPACK_IMPORTED_MODULE_0__.Component; }, |
| 21723 |
/* harmony export */ Confirm: function() { return /* reexport safe */ _dialog___WEBPACK_IMPORTED_MODULE_3__.Confirm; }, |
| 21724 |
/* harmony export */ ContextMenu: function() { return /* reexport safe */ _context_menu_context_menu__WEBPACK_IMPORTED_MODULE_2__.ContextMenu; }, |
| 21725 |
/* harmony export */ Create: function() { return /* reexport safe */ jodit_core_create__WEBPACK_IMPORTED_MODULE_6__.Create; }, |
| 21726 |
/* harmony export */ Dialog: function() { return /* reexport safe */ _dialog___WEBPACK_IMPORTED_MODULE_3__.Dialog; }, |
| 21727 |
/* harmony export */ Dom: function() { return /* reexport safe */ jodit_core_dom__WEBPACK_IMPORTED_MODULE_7__.Dom; }, |
| 21728 |
/* harmony export */ EventEmitter: function() { return /* reexport safe */ jodit_core_event_emitter__WEBPACK_IMPORTED_MODULE_8__.EventEmitter; }, |
| 21729 |
/* harmony export */ EventHandlersStore: function() { return /* reexport safe */ jodit_core_event_emitter__WEBPACK_IMPORTED_MODULE_8__.EventHandlersStore; }, |
| 21730 |
/* harmony export */ Eventify: function() { return /* reexport safe */ jodit_core_event_emitter__WEBPACK_IMPORTED_MODULE_8__.Eventify; }, |
| 21731 |
/* harmony export */ FileBrowser: function() { return /* reexport safe */ _file_browser__WEBPACK_IMPORTED_MODULE_4__.FileBrowser; }, |
| 21732 |
/* harmony export */ Helpers: function() { return /* reexport module object */ jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__; }, |
| 21733 |
/* harmony export */ History: function() { return /* reexport safe */ _history_history__WEBPACK_IMPORTED_MODULE_14__.History; }, |
| 21734 |
/* harmony export */ Icon: function() { return /* reexport safe */ jodit_core_ui__WEBPACK_IMPORTED_MODULE_11__.Icon; }, |
| 21735 |
/* harmony export */ ImageEditor: function() { return /* reexport safe */ _image_editor_image_editor__WEBPACK_IMPORTED_MODULE_16__.ImageEditor; }, |
| 21736 |
/* harmony export */ IndexedDBProvider: function() { return /* reexport safe */ jodit_core_storage__WEBPACK_IMPORTED_MODULE_26__.IndexedDBProvider; }, |
| 21737 |
/* harmony export */ LazyWalker: function() { return /* reexport safe */ jodit_core_dom__WEBPACK_IMPORTED_MODULE_7__.LazyWalker; }, |
| 21738 |
/* harmony export */ LocalStorageProvider: function() { return /* reexport safe */ jodit_core_storage__WEBPACK_IMPORTED_MODULE_26__.LocalStorageProvider; }, |
| 21739 |
/* harmony export */ MemoryStorageProvider: function() { return /* reexport safe */ jodit_core_storage__WEBPACK_IMPORTED_MODULE_26__.MemoryStorageProvider; }, |
| 21740 |
/* harmony export */ Plugin: function() { return /* reexport safe */ jodit_core_plugin__WEBPACK_IMPORTED_MODULE_9__.Plugin; }, |
| 21741 |
/* harmony export */ PluginSystem: function() { return /* reexport safe */ jodit_core_plugin_plugin_system__WEBPACK_IMPORTED_MODULE_24__.PluginSystem; }, |
| 21742 |
/* harmony export */ Popup: function() { return /* reexport safe */ jodit_core_ui__WEBPACK_IMPORTED_MODULE_11__.Popup; }, |
| 21743 |
/* harmony export */ ProgressBar: function() { return /* reexport safe */ jodit_core_ui__WEBPACK_IMPORTED_MODULE_11__.ProgressBar; }, |
| 21744 |
/* harmony export */ Prompt: function() { return /* reexport safe */ _dialog___WEBPACK_IMPORTED_MODULE_3__.Prompt; }, |
| 21745 |
/* harmony export */ Response: function() { return /* reexport safe */ jodit_core_request__WEBPACK_IMPORTED_MODULE_10__.Response; }, |
| 21746 |
/* harmony export */ STATUSES: function() { return /* reexport safe */ jodit_core_component__WEBPACK_IMPORTED_MODULE_0__.STATUSES; }, |
| 21747 |
/* harmony export */ Selection: function() { return /* reexport safe */ jodit_core_selection__WEBPACK_IMPORTED_MODULE_25__.Selection; }, |
| 21748 |
/* harmony export */ Snapshot: function() { return /* reexport safe */ _history_snapshot__WEBPACK_IMPORTED_MODULE_15__.Snapshot; }, |
| 21749 |
/* harmony export */ StatusBar: function() { return /* reexport safe */ _status_bar_status_bar__WEBPACK_IMPORTED_MODULE_18__.StatusBar; }, |
| 21750 |
/* harmony export */ Storage: function() { return /* reexport safe */ jodit_core_storage__WEBPACK_IMPORTED_MODULE_26__.Storage; }, |
| 21751 |
/* harmony export */ StorageKey: function() { return /* reexport safe */ jodit_core_storage__WEBPACK_IMPORTED_MODULE_26__.StorageKey; }, |
| 21752 |
/* harmony export */ Table: function() { return /* reexport safe */ _table_table__WEBPACK_IMPORTED_MODULE_19__.Table; }, |
| 21753 |
/* harmony export */ ToolbarButton: function() { return /* reexport safe */ _toolbar_button__WEBPACK_IMPORTED_MODULE_20__.ToolbarButton; }, |
| 21754 |
/* harmony export */ ToolbarCollection: function() { return /* reexport safe */ _toolbar_collection_collection__WEBPACK_IMPORTED_MODULE_21__.ToolbarCollection; }, |
| 21755 |
/* harmony export */ ToolbarContent: function() { return /* reexport safe */ _toolbar_button__WEBPACK_IMPORTED_MODULE_20__.ToolbarContent; }, |
| 21756 |
/* harmony export */ ToolbarEditorCollection: function() { return /* reexport safe */ _toolbar_collection_editor_collection__WEBPACK_IMPORTED_MODULE_22__.ToolbarEditorCollection; }, |
| 21757 |
/* harmony export */ ToolbarSelect: function() { return /* reexport safe */ _toolbar_button__WEBPACK_IMPORTED_MODULE_20__.ToolbarSelect; }, |
| 21758 |
/* harmony export */ UIBlock: function() { return /* reexport safe */ jodit_core_ui__WEBPACK_IMPORTED_MODULE_11__.UIBlock; }, |
| 21759 |
/* harmony export */ UIButton: function() { return /* reexport safe */ jodit_core_ui__WEBPACK_IMPORTED_MODULE_11__.UIButton; }, |
| 21760 |
/* harmony export */ UIButtonGroup: function() { return /* reexport safe */ jodit_core_ui__WEBPACK_IMPORTED_MODULE_11__.UIButtonGroup; }, |
| 21761 |
/* harmony export */ UIButtonState: function() { return /* reexport safe */ jodit_core_ui__WEBPACK_IMPORTED_MODULE_11__.UIButtonState; }, |
| 21762 |
/* harmony export */ UICheckbox: function() { return /* reexport safe */ jodit_core_ui__WEBPACK_IMPORTED_MODULE_11__.UICheckbox; }, |
| 21763 |
/* harmony export */ UIElement: function() { return /* reexport safe */ jodit_core_ui__WEBPACK_IMPORTED_MODULE_11__.UIElement; }, |
| 21764 |
/* harmony export */ UIFileInput: function() { return /* reexport safe */ jodit_core_ui__WEBPACK_IMPORTED_MODULE_11__.UIFileInput; }, |
| 21765 |
/* harmony export */ UIForm: function() { return /* reexport safe */ jodit_core_ui__WEBPACK_IMPORTED_MODULE_11__.UIForm; }, |
| 21766 |
/* harmony export */ UIGroup: function() { return /* reexport safe */ jodit_core_ui__WEBPACK_IMPORTED_MODULE_11__.UIGroup; }, |
| 21767 |
/* harmony export */ UIInput: function() { return /* reexport safe */ jodit_core_ui__WEBPACK_IMPORTED_MODULE_11__.UIInput; }, |
| 21768 |
/* harmony export */ UIList: function() { return /* reexport safe */ jodit_core_ui__WEBPACK_IMPORTED_MODULE_11__.UIList; }, |
| 21769 |
/* harmony export */ UIMessages: function() { return /* reexport safe */ _messages_messages__WEBPACK_IMPORTED_MODULE_17__.UIMessages; }, |
| 21770 |
/* harmony export */ UISelect: function() { return /* reexport safe */ jodit_core_ui__WEBPACK_IMPORTED_MODULE_11__.UISelect; }, |
| 21771 |
/* harmony export */ UISeparator: function() { return /* reexport safe */ jodit_core_ui__WEBPACK_IMPORTED_MODULE_11__.UISeparator; }, |
| 21772 |
/* harmony export */ UISpacer: function() { return /* reexport safe */ jodit_core_ui__WEBPACK_IMPORTED_MODULE_11__.UISpacer; }, |
| 21773 |
/* harmony export */ UITextArea: function() { return /* reexport safe */ jodit_core_ui__WEBPACK_IMPORTED_MODULE_11__.UITextArea; }, |
| 21774 |
/* harmony export */ UITooltip: function() { return /* reexport safe */ jodit_core_ui__WEBPACK_IMPORTED_MODULE_11__.UITooltip; }, |
| 21775 |
/* harmony export */ Uploader: function() { return /* reexport safe */ _uploader_uploader__WEBPACK_IMPORTED_MODULE_23__.Uploader; }, |
| 21776 |
/* harmony export */ View: function() { return /* reexport safe */ jodit_core_view_view__WEBPACK_IMPORTED_MODULE_12__.View; }, |
| 21777 |
/* harmony export */ ViewComponent: function() { return /* reexport safe */ jodit_core_component__WEBPACK_IMPORTED_MODULE_0__.ViewComponent; }, |
| 21778 |
/* harmony export */ ViewWithToolbar: function() { return /* reexport safe */ jodit_core_view_view_with_toolbar__WEBPACK_IMPORTED_MODULE_13__.ViewWithToolbar; }, |
| 21779 |
/* harmony export */ canUseIndexedDB: function() { return /* reexport safe */ jodit_core_storage__WEBPACK_IMPORTED_MODULE_26__.canUseIndexedDB; }, |
| 21780 |
/* harmony export */ canUsePersistentStorage: function() { return /* reexport safe */ jodit_core_storage__WEBPACK_IMPORTED_MODULE_26__.canUsePersistentStorage; }, |
| 21781 |
/* harmony export */ clearUseIndexedDBCache: function() { return /* reexport safe */ jodit_core_storage__WEBPACK_IMPORTED_MODULE_26__.clearUseIndexedDBCache; }, |
| 21782 |
/* harmony export */ defaultNameSpace: function() { return /* reexport safe */ jodit_core_event_emitter__WEBPACK_IMPORTED_MODULE_8__.defaultNameSpace; }, |
| 21783 |
/* harmony export */ observable: function() { return /* reexport safe */ jodit_core_event_emitter__WEBPACK_IMPORTED_MODULE_8__.observable; } |
| 21784 |
/* harmony export */ }); |
| 21785 |
/* harmony import */ var jodit_core_component__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(16964); |
| 21786 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(65946); |
| 21787 |
/* harmony import */ var _context_menu_context_menu__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(67399); |
| 21788 |
/* harmony import */ var _dialog___WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(37333); |
| 21789 |
/* harmony import */ var _file_browser__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(17610); |
| 21790 |
/* harmony import */ var jodit_core_async__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(91231); |
| 21791 |
/* harmony import */ var jodit_core_create__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(79821); |
| 21792 |
/* harmony import */ var jodit_core_dom__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(27795); |
| 21793 |
/* harmony import */ var jodit_core_event_emitter__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(1496); |
| 21794 |
/* harmony import */ var jodit_core_plugin__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(91206); |
| 21795 |
/* harmony import */ var jodit_core_request__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(73714); |
| 21796 |
/* harmony import */ var jodit_core_ui__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(4099); |
| 21797 |
/* harmony import */ var jodit_core_view_view__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(35099); |
| 21798 |
/* harmony import */ var jodit_core_view_view_with_toolbar__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(2222); |
| 21799 |
/* harmony import */ var _history_history__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(53855); |
| 21800 |
/* harmony import */ var _history_snapshot__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(46363); |
| 21801 |
/* harmony import */ var _image_editor_image_editor__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(43271); |
| 21802 |
/* harmony import */ var _messages_messages__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(10081); |
| 21803 |
/* harmony import */ var _status_bar_status_bar__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(29433); |
| 21804 |
/* harmony import */ var _table_table__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(98803); |
| 21805 |
/* harmony import */ var _toolbar_button__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(39709); |
| 21806 |
/* harmony import */ var _toolbar_collection_collection__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(42573); |
| 21807 |
/* harmony import */ var _toolbar_collection_editor_collection__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(6209); |
| 21808 |
/* harmony import */ var _uploader_uploader__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__(94925); |
| 21809 |
/* harmony import */ var jodit_core_plugin_plugin_system__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__(85305); |
| 21810 |
/* harmony import */ var jodit_core_selection__WEBPACK_IMPORTED_MODULE_25__ = __webpack_require__(59841); |
| 21811 |
/* harmony import */ var jodit_core_storage__WEBPACK_IMPORTED_MODULE_26__ = __webpack_require__(25222); |
| 21812 |
/*! |
| 21813 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 21814 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 21815 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 21816 |
*/ /** |
| 21817 |
* [[include:modules/README.md]] |
| 21818 |
* @packageDocumentation |
| 21819 |
* @module modules |
| 21820 |
*/ |
| 21821 |
|
| 21822 |
|
| 21823 |
|
| 21824 |
|
| 21825 |
|
| 21826 |
|
| 21827 |
|
| 21828 |
|
| 21829 |
|
| 21830 |
|
| 21831 |
|
| 21832 |
|
| 21833 |
|
| 21834 |
|
| 21835 |
|
| 21836 |
|
| 21837 |
|
| 21838 |
|
| 21839 |
|
| 21840 |
|
| 21841 |
|
| 21842 |
|
| 21843 |
|
| 21844 |
|
| 21845 |
|
| 21846 |
|
| 21847 |
|
| 21848 |
|
| 21849 |
|
| 21850 |
|
| 21851 |
/***/ }), |
| 21852 |
|
| 21853 |
/***/ 61077: |
| 21854 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 21855 |
|
| 21856 |
"use strict"; |
| 21857 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 21858 |
/* harmony export */ clearTimeout: function() { return /* reexport safe */ _set_timeout__WEBPACK_IMPORTED_MODULE_0__.clearTimeout; }, |
| 21859 |
/* harmony export */ setTimeout: function() { return /* reexport safe */ _set_timeout__WEBPACK_IMPORTED_MODULE_0__.setTimeout; } |
| 21860 |
/* harmony export */ }); |
| 21861 |
/* harmony import */ var _set_timeout__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(79947); |
| 21862 |
/*! |
| 21863 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 21864 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 21865 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 21866 |
*/ /** |
| 21867 |
* @module helpers/async |
| 21868 |
*/ |
| 21869 |
|
| 21870 |
|
| 21871 |
/***/ }), |
| 21872 |
|
| 21873 |
/***/ 61334: |
| 21874 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 21875 |
|
| 21876 |
"use strict"; |
| 21877 |
/* harmony import */ var _swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(49376); |
| 21878 |
/* harmony import */ var jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(27795); |
| 21879 |
/* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(7909); |
| 21880 |
/* harmony import */ var jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(33201); |
| 21881 |
/* harmony import */ var jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(29434); |
| 21882 |
/* harmony import */ var jodit_modules_file_browser_builders_elements_map__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(31125); |
| 21883 |
/* harmony import */ var jodit_modules_file_browser_builders_utils__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(66206); |
| 21884 |
/* harmony import */ var jodit_modules_file_browser_factories__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(18272); |
| 21885 |
/* harmony import */ var jodit_modules_file_browser_fetch_delete_file__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(1305); |
| 21886 |
/* harmony import */ var jodit_modules_file_browser_fetch_load_tree__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(53202); |
| 21887 |
/* harmony import */ var jodit_modules_image_editor_image_editor__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(43271); |
| 21888 |
/*! |
| 21889 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 21890 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 21891 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 21892 |
*/ /** |
| 21893 |
* @module modules/file-browser |
| 21894 |
*/ |
| 21895 |
|
| 21896 |
|
| 21897 |
|
| 21898 |
|
| 21899 |
|
| 21900 |
|
| 21901 |
|
| 21902 |
|
| 21903 |
|
| 21904 |
|
| 21905 |
const CLASS_PREVIEW = 'jodit-file-browser-preview', preview_tpl_next = (next = 'next', right = 'right')=>`<div class="${CLASS_PREVIEW}__navigation ${CLASS_PREVIEW}__navigation_arrow_${next}">` + '' + jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_4__.Icon.get('angle-' + right) + '</a>'; |
| 21906 |
/* harmony default export */ __webpack_exports__["default"] = ((self)=>{ |
| 21907 |
if (!self.o.contextMenu) { |
| 21908 |
return ()=>{}; |
| 21909 |
} |
| 21910 |
const contextmenu = (0,jodit_modules_file_browser_factories__WEBPACK_IMPORTED_MODULE_7__.makeContextMenu)(self); |
| 21911 |
return (e)=>{ |
| 21912 |
const a = (0,jodit_modules_file_browser_builders_utils__WEBPACK_IMPORTED_MODULE_6__.getItem)(e.target, self.container); |
| 21913 |
if (!a) { |
| 21914 |
return; |
| 21915 |
} |
| 21916 |
let item = a; |
| 21917 |
const opt = self.options, ga = (key)=>(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_2__.attr)(item, key) || ''; |
| 21918 |
self.async.setTimeout(()=>{ |
| 21919 |
const selectedItem = (0,jodit_modules_file_browser_builders_utils__WEBPACK_IMPORTED_MODULE_6__.elementToItem)(a, (0,jodit_modules_file_browser_builders_elements_map__WEBPACK_IMPORTED_MODULE_5__.elementsMap)(self)); |
| 21920 |
if (!selectedItem) { |
| 21921 |
return; |
| 21922 |
} |
| 21923 |
self.state.activeElements = [ |
| 21924 |
selectedItem |
| 21925 |
]; |
| 21926 |
contextmenu.show(e.clientX, e.clientY, [ |
| 21927 |
ga('data-is-file') !== '1' && opt.editImage && (self.dataProvider.canI('ImageResize') || self.dataProvider.canI('ImageCrop')) ? { |
| 21928 |
icon: 'pencil', |
| 21929 |
title: 'Edit', |
| 21930 |
exec: ()=>jodit_modules_image_editor_image_editor__WEBPACK_IMPORTED_MODULE_10__.openImageEditor.call(self, ga('href'), ga('data-name'), ga('data-path'), ga('data-source')) |
| 21931 |
} : false, |
| 21932 |
self.dataProvider.canI('FileRename') ? { |
| 21933 |
icon: 'italic', |
| 21934 |
title: 'Rename', |
| 21935 |
exec: ()=>{ |
| 21936 |
self.e.fire('fileRename.filebrowser', ga('data-name'), ga('data-path'), ga('data-source')); |
| 21937 |
} |
| 21938 |
} : false, |
| 21939 |
self.dataProvider.canI('FileRemove') ? { |
| 21940 |
icon: 'bin', |
| 21941 |
title: 'Delete', |
| 21942 |
exec: ()=>(0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 21943 |
try { |
| 21944 |
yield (0,jodit_modules_file_browser_fetch_delete_file__WEBPACK_IMPORTED_MODULE_8__.deleteFile)(self, ga('data-name'), ga('data-source')); |
| 21945 |
} catch (e) { |
| 21946 |
return self.status(e); |
| 21947 |
} |
| 21948 |
self.state.activeElements = []; |
| 21949 |
return (0,jodit_modules_file_browser_fetch_load_tree__WEBPACK_IMPORTED_MODULE_9__.loadTree)(self).catch(self.status); |
| 21950 |
})() |
| 21951 |
} : false, |
| 21952 |
opt.preview ? { |
| 21953 |
icon: 'eye', |
| 21954 |
title: 'Preview', |
| 21955 |
exec: ()=>{ |
| 21956 |
const preview = self.dlg({ |
| 21957 |
buttons: [ |
| 21958 |
'fullsize', |
| 21959 |
'dialog.close' |
| 21960 |
] |
| 21961 |
}), temp_content = self.c.div(CLASS_PREVIEW, '<div class="jodit-icon_loader"></div>'), preview_box = self.c.div(CLASS_PREVIEW + '__box'), next = self.c.fromHTML(preview_tpl_next()), prev = self.c.fromHTML(preview_tpl_next('prev', 'left')), addLoadHandler = (src)=>{ |
| 21962 |
const image = self.c.element('img'); |
| 21963 |
image.setAttribute('src', src); |
| 21964 |
const onload = ()=>{ |
| 21965 |
var _self_events; |
| 21966 |
if (self.isInDestruct) { |
| 21967 |
return; |
| 21968 |
} |
| 21969 |
self.e.off(image, 'load'); |
| 21970 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.detach(temp_content); |
| 21971 |
if (opt.showPreviewNavigation) { |
| 21972 |
if (jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.prevWithClass(item, self.files.getFullElName('item'))) { |
| 21973 |
temp_content.appendChild(prev); |
| 21974 |
} |
| 21975 |
if (jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.nextWithClass(item, self.files.getFullElName('item'))) { |
| 21976 |
temp_content.appendChild(next); |
| 21977 |
} |
| 21978 |
} |
| 21979 |
temp_content.appendChild(preview_box); |
| 21980 |
preview_box.appendChild(image); |
| 21981 |
preview.setPosition(); |
| 21982 |
self === null || self === void 0 ? void 0 : (_self_events = self.events) === null || _self_events === void 0 ? void 0 : _self_events.fire('previewOpenedAndLoaded'); |
| 21983 |
}; |
| 21984 |
self.e.on(image, 'load', onload); |
| 21985 |
if (image.complete) { |
| 21986 |
onload(); |
| 21987 |
} |
| 21988 |
}; |
| 21989 |
self.e.on([ |
| 21990 |
next, |
| 21991 |
prev |
| 21992 |
], 'click', function() { |
| 21993 |
if (this === next) { |
| 21994 |
item = jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.nextWithClass(item, self.files.getFullElName('item')); |
| 21995 |
} else { |
| 21996 |
item = jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.prevWithClass(item, self.files.getFullElName('item')); |
| 21997 |
} |
| 21998 |
if (!item) { |
| 21999 |
throw (0,jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_3__.error)('Need element'); |
| 22000 |
} |
| 22001 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.detach(temp_content); |
| 22002 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.detach(preview_box); |
| 22003 |
temp_content.innerHTML = '<div class="jodit-icon_loader"></div>'; |
| 22004 |
addLoadHandler(ga('href')); |
| 22005 |
}); |
| 22006 |
self.e.on('beforeDestruct', ()=>{ |
| 22007 |
preview.destruct(); |
| 22008 |
}); |
| 22009 |
preview.container.classList.add(CLASS_PREVIEW + '__dialog'); |
| 22010 |
preview.setContent(temp_content); |
| 22011 |
preview.setPosition(); |
| 22012 |
preview.open(); |
| 22013 |
addLoadHandler(ga('href')); |
| 22014 |
self.events.on('beforeDestruct', ()=>{ |
| 22015 |
preview.destruct(); |
| 22016 |
}).fire('previewOpened'); |
| 22017 |
} |
| 22018 |
} : false, |
| 22019 |
{ |
| 22020 |
icon: 'upload', |
| 22021 |
title: 'Download', |
| 22022 |
exec: ()=>{ |
| 22023 |
const url = ga('href'); |
| 22024 |
if (url) { |
| 22025 |
self.ow.open(url); |
| 22026 |
} |
| 22027 |
} |
| 22028 |
} |
| 22029 |
]); |
| 22030 |
}, self.defaultTimeout); |
| 22031 |
self.e.on('beforeClose', ()=>{ |
| 22032 |
contextmenu.close(); |
| 22033 |
}).on('beforeDestruct', ()=>contextmenu.destruct()); |
| 22034 |
e.stopPropagation(); |
| 22035 |
e.preventDefault(); |
| 22036 |
return false; |
| 22037 |
}; |
| 22038 |
}); |
| 22039 |
|
| 22040 |
|
| 22041 |
/***/ }), |
| 22042 |
|
| 22043 |
/***/ 61466: |
| 22044 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 22045 |
|
| 22046 |
"use strict"; |
| 22047 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 22048 |
/* harmony export */ UIMessage: function() { return /* binding */ UIMessage; } |
| 22049 |
/* harmony export */ }); |
| 22050 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(31635); |
| 22051 |
/* harmony import */ var jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(91672); |
| 22052 |
/* harmony import */ var jodit_core_ui__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(4099); |
| 22053 |
/*! |
| 22054 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 22055 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 22056 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 22057 |
*/ /** |
| 22058 |
* @module modules/messages |
| 22059 |
*/ |
| 22060 |
|
| 22061 |
|
| 22062 |
class UIMessage extends jodit_core_ui__WEBPACK_IMPORTED_MODULE_2__.UIElement { |
| 22063 |
className() { |
| 22064 |
return 'UIMessage'; |
| 22065 |
} |
| 22066 |
constructor(jodit, options){ |
| 22067 |
super(jodit); |
| 22068 |
this.setMod('active', true); |
| 22069 |
this.setMod('variant', options.variant); |
| 22070 |
this.container.textContent = options.text; |
| 22071 |
} |
| 22072 |
} |
| 22073 |
UIMessage = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_0__.__decorate)([ |
| 22074 |
jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_1__.component |
| 22075 |
], UIMessage); |
| 22076 |
|
| 22077 |
|
| 22078 |
/***/ }), |
| 22079 |
|
| 22080 |
/***/ 61764: |
| 22081 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 22082 |
|
| 22083 |
"use strict"; |
| 22084 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 22085 |
/* harmony export */ ToolbarSelect: function() { return /* binding */ ToolbarSelect; } |
| 22086 |
/* harmony export */ }); |
| 22087 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(31635); |
| 22088 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(84839); |
| 22089 |
/* harmony import */ var jodit_core_helpers_checker_is_plain_object__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(62101); |
| 22090 |
/* harmony import */ var jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(85932); |
| 22091 |
/* harmony import */ var _button__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(22533); |
| 22092 |
/*! |
| 22093 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 22094 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 22095 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 22096 |
*/ /** |
| 22097 |
* @module modules/toolbar/button |
| 22098 |
*/ |
| 22099 |
|
| 22100 |
|
| 22101 |
|
| 22102 |
|
| 22103 |
|
| 22104 |
class ToolbarSelect extends _button__WEBPACK_IMPORTED_MODULE_4__.ToolbarButton { |
| 22105 |
className() { |
| 22106 |
return 'ToolbarSelect'; |
| 22107 |
} |
| 22108 |
update() { |
| 22109 |
super.update(); |
| 22110 |
this.state.icon.name = ''; |
| 22111 |
const { list, data } = this.control; |
| 22112 |
if (list) { |
| 22113 |
var _ref; |
| 22114 |
var _this_control_textTemplate, _this_control; |
| 22115 |
let key = this.state.value || (data && (0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_3__.isString)(data.currentValue) ? data.currentValue : undefined); |
| 22116 |
if (!key) { |
| 22117 |
const keys = Object.keys(list); |
| 22118 |
key = keys[0]; |
| 22119 |
} |
| 22120 |
const text = ((0,jodit_core_helpers_checker_is_plain_object__WEBPACK_IMPORTED_MODULE_2__.isPlainObject)(list) ? list[key.toString()] || key : key).toString(); |
| 22121 |
this.state.text = (_ref = (_this_control_textTemplate = (_this_control = this.control).textTemplate) === null || _this_control_textTemplate === void 0 ? void 0 : _this_control_textTemplate.call(_this_control, this.jodit, text)) !== null && _ref !== void 0 ? _ref : text; |
| 22122 |
} |
| 22123 |
} |
| 22124 |
} |
| 22125 |
ToolbarSelect = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_0__.__decorate)([ |
| 22126 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_1__.component |
| 22127 |
], ToolbarSelect); |
| 22128 |
|
| 22129 |
|
| 22130 |
/***/ }), |
| 22131 |
|
| 22132 |
/***/ 62101: |
| 22133 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 22134 |
|
| 22135 |
"use strict"; |
| 22136 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 22137 |
/* harmony export */ isPlainObject: function() { return /* binding */ isPlainObject; } |
| 22138 |
/* harmony export */ }); |
| 22139 |
/* harmony import */ var _is_window__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(3513); |
| 22140 |
/*! |
| 22141 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 22142 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 22143 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 22144 |
*/ /** |
| 22145 |
* @module helpers/checker |
| 22146 |
*/ |
| 22147 |
/** |
| 22148 |
* Check if element is simple plaint object |
| 22149 |
*/ function isPlainObject(obj) { |
| 22150 |
if (!obj || typeof obj !== 'object' || obj.nodeType || (0,_is_window__WEBPACK_IMPORTED_MODULE_0__.isWindow)(obj)) { |
| 22151 |
return false; |
| 22152 |
} |
| 22153 |
return !(obj.constructor && !({}).hasOwnProperty.call(obj.constructor.prototype, 'isPrototypeOf')); |
| 22154 |
} |
| 22155 |
|
| 22156 |
|
| 22157 |
/***/ }), |
| 22158 |
|
| 22159 |
/***/ 62623: |
| 22160 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 22161 |
|
| 22162 |
"use strict"; |
| 22163 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 22164 |
/* harmony export */ FileBrowser: function() { return /* binding */ FileBrowser; } |
| 22165 |
/* harmony export */ }); |
| 22166 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 22167 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 22168 |
/* harmony import */ var jodit_core_component__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(16964); |
| 22169 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(81937); |
| 22170 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(84839); |
| 22171 |
/* harmony import */ var jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(68616); |
| 22172 |
/* harmony import */ var jodit_core_event_emitter__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(1496); |
| 22173 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(65946); |
| 22174 |
/* harmony import */ var jodit_core_storage__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(25222); |
| 22175 |
/* harmony import */ var jodit_core_traits_dlgs__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(80512); |
| 22176 |
/* harmony import */ var jodit_core_view_view_with_toolbar__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(2222); |
| 22177 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(5266); |
| 22178 |
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(68502); |
| 22179 |
/* harmony import */ var _fetch_load_items__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(1488); |
| 22180 |
/* harmony import */ var _fetch_load_tree__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(53202); |
| 22181 |
/* harmony import */ var _listeners_native_listeners__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(34269); |
| 22182 |
/* harmony import */ var _listeners_self_listeners__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(36664); |
| 22183 |
/* harmony import */ var _listeners_state_listeners__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(74833); |
| 22184 |
/* harmony import */ var _data_provider__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(17780); |
| 22185 |
/* harmony import */ var _factories__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(18272); |
| 22186 |
/* harmony import */ var _ui__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(63425); |
| 22187 |
/*! |
| 22188 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 22189 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 22190 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 22191 |
*/ /** |
| 22192 |
* @module modules/file-browser |
| 22193 |
*/ |
| 22194 |
|
| 22195 |
|
| 22196 |
|
| 22197 |
|
| 22198 |
|
| 22199 |
|
| 22200 |
|
| 22201 |
|
| 22202 |
|
| 22203 |
|
| 22204 |
|
| 22205 |
|
| 22206 |
|
| 22207 |
|
| 22208 |
|
| 22209 |
|
| 22210 |
|
| 22211 |
|
| 22212 |
|
| 22213 |
|
| 22214 |
|
| 22215 |
|
| 22216 |
class FileBrowser extends jodit_core_view_view_with_toolbar__WEBPACK_IMPORTED_MODULE_10__.ViewWithToolbar { |
| 22217 |
/** @override */ className() { |
| 22218 |
return 'FileBrowser'; |
| 22219 |
} |
| 22220 |
get dataProvider() { |
| 22221 |
return (0,_factories__WEBPACK_IMPORTED_MODULE_19__.makeDataProvider)(this, this.options); |
| 22222 |
} |
| 22223 |
onSelect(callback) { |
| 22224 |
return ()=>{ |
| 22225 |
if (this.state.activeElements.length) { |
| 22226 |
const files = []; |
| 22227 |
const isImages = []; |
| 22228 |
this.state.activeElements.forEach((elm)=>{ |
| 22229 |
const url = elm.fileURL; |
| 22230 |
if (url) { |
| 22231 |
files.push(url); |
| 22232 |
isImages.push(elm.isImage || false); |
| 22233 |
} |
| 22234 |
}); |
| 22235 |
this.close(); |
| 22236 |
const data = { |
| 22237 |
baseurl: '', |
| 22238 |
files, |
| 22239 |
isImages |
| 22240 |
}; |
| 22241 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_7__.isFunction)(callback)) { |
| 22242 |
callback(data); |
| 22243 |
} |
| 22244 |
this.close(); |
| 22245 |
} |
| 22246 |
return false; |
| 22247 |
}; |
| 22248 |
} |
| 22249 |
get _dialog() { |
| 22250 |
var _this_o_headerButtons; |
| 22251 |
const dialog = this.dlg({ |
| 22252 |
minWidth: Math.min(700, screen.width), |
| 22253 |
minHeight: 300, |
| 22254 |
buttons: (_this_o_headerButtons = this.o.headerButtons) !== null && _this_o_headerButtons !== void 0 ? _this_o_headerButtons : [ |
| 22255 |
'fullsize', |
| 22256 |
'dialog.close' |
| 22257 |
] |
| 22258 |
}); |
| 22259 |
[ |
| 22260 |
'beforeClose', |
| 22261 |
'afterClose', |
| 22262 |
'beforeOpen' |
| 22263 |
].forEach((proxyEvent)=>dialog.events.on(dialog, proxyEvent, ()=>this.e.fire(proxyEvent))); |
| 22264 |
dialog.setSize(this.o.width, this.o.height); |
| 22265 |
return dialog; |
| 22266 |
} |
| 22267 |
/** |
| 22268 |
* Container for set/get value |
| 22269 |
*/ get storage() { |
| 22270 |
return jodit_core_storage__WEBPACK_IMPORTED_MODULE_8__.Storage.makeStorage(Boolean(this.o.saveStateInStorage), this.componentName); |
| 22271 |
} |
| 22272 |
get isOpened() { |
| 22273 |
return this._dialog.isOpened && this.browser.style.display !== 'none'; |
| 22274 |
} |
| 22275 |
/** |
| 22276 |
* It displays a message in the status bar of filebrowser |
| 22277 |
* |
| 22278 |
* @param message - The message that will be displayed |
| 22279 |
* @param success - true It will be shown a message light . If no option is specified , |
| 22280 |
* ßan error will be shown the red |
| 22281 |
* @example |
| 22282 |
* ```javascript |
| 22283 |
* parent.filebrowser.status('There was an error uploading file', false); |
| 22284 |
* ``` |
| 22285 |
*/ status(message, success) { |
| 22286 |
if (!message || (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_7__.isAbortError)(message)) { |
| 22287 |
return; |
| 22288 |
} |
| 22289 |
if (!(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_7__.isString)(message)) { |
| 22290 |
message = message.message; |
| 22291 |
} |
| 22292 |
if (!(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_7__.isString)(message) || !(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_7__.trim)(message).length) { |
| 22293 |
return; |
| 22294 |
} |
| 22295 |
this.message.message(message, success ? 'success' : 'error', this.o.howLongShowMsg); |
| 22296 |
} |
| 22297 |
/** |
| 22298 |
* It opens a web browser window |
| 22299 |
* |
| 22300 |
* @param callback - The function that will be called after the file selection in the browser |
| 22301 |
* @param onlyImages - Show only images |
| 22302 |
* @example |
| 22303 |
* ```javascript |
| 22304 |
* var fb = new Jodit.modules.FileBrowser(parent); |
| 22305 |
* fb.open(function (data) { |
| 22306 |
* var i; |
| 22307 |
* for (i = 0;i < data.files.length; i += 1) { |
| 22308 |
* parent.s.insertImage(data.baseurl + data.files[i]); |
| 22309 |
* } |
| 22310 |
* }); |
| 22311 |
* ``` |
| 22312 |
*/ open(callback = this.o.defaultCallback, onlyImages = false) { |
| 22313 |
this.state.onlyImages = onlyImages; |
| 22314 |
return this.async.promise((resolve, reject)=>{ |
| 22315 |
var _this_toolbar; |
| 22316 |
if (!this.o.items || !this.o.items.url) { |
| 22317 |
throw (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_7__.error)('Need set options.filebrowser.ajax.url'); |
| 22318 |
} |
| 22319 |
let localTimeout = 0; |
| 22320 |
this.e.off(this.files.container, 'dblclick').on(this.files.container, 'dblclick', this.onSelect(callback)).on(this.files.container, 'touchstart', ()=>{ |
| 22321 |
const now = new Date().getTime(); |
| 22322 |
if (now - localTimeout < jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.EMULATE_DBLCLICK_TIMEOUT) { |
| 22323 |
this.onSelect(callback)(); |
| 22324 |
} |
| 22325 |
localTimeout = now; |
| 22326 |
}).off('select.filebrowser').on('select.filebrowser', this.onSelect(callback)); |
| 22327 |
const header = this.c.div(); |
| 22328 |
(_this_toolbar = this.toolbar) === null || _this_toolbar === void 0 ? void 0 : _this_toolbar.appendTo(header); |
| 22329 |
this.__updateToolbarButtons(); |
| 22330 |
this._dialog.open(this.browser, header); |
| 22331 |
this.e.fire('sort.filebrowser', this.state.sortBy); |
| 22332 |
(0,_fetch_load_tree__WEBPACK_IMPORTED_MODULE_14__.loadTree)(this).then(resolve, reject).finally(()=>{ |
| 22333 |
var _this_e, _this; |
| 22334 |
if (this.isInDestruct) { |
| 22335 |
return; |
| 22336 |
} |
| 22337 |
(_this = this) === null || _this === void 0 ? void 0 : (_this_e = _this.e) === null || _this_e === void 0 ? void 0 : _this_e.fire('fileBrowserReady.filebrowser'); |
| 22338 |
}); |
| 22339 |
}).catch((e)=>{ |
| 22340 |
if (!(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_7__.isAbortError)(e) && !jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.IS_PROD) { |
| 22341 |
throw e; |
| 22342 |
} |
| 22343 |
}); |
| 22344 |
} |
| 22345 |
__getButtons() { |
| 22346 |
var _this_o_buttons; |
| 22347 |
const options = (_this_o_buttons = this.o.buttons) !== null && _this_o_buttons !== void 0 ? _this_o_buttons : []; |
| 22348 |
return options.filter((btn)=>{ |
| 22349 |
if (!(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_7__.isString)(btn)) { |
| 22350 |
return true; |
| 22351 |
} |
| 22352 |
switch(btn){ |
| 22353 |
case 'filebrowser.upload': |
| 22354 |
return this.dataProvider.canI('FileUpload'); |
| 22355 |
case 'filebrowser.edit': |
| 22356 |
return this.dataProvider.canI('ImageResize') || this.dataProvider.canI('ImageCrop'); |
| 22357 |
case 'filebrowser.remove': |
| 22358 |
return this.dataProvider.canI('FileRemove'); |
| 22359 |
} |
| 22360 |
return true; |
| 22361 |
}); |
| 22362 |
} |
| 22363 |
initUploader(editor) { |
| 22364 |
var _editor_options; |
| 22365 |
const self = this, options = editor === null || editor === void 0 ? void 0 : (_editor_options = editor.options) === null || _editor_options === void 0 ? void 0 : _editor_options.uploader, uploaderOptions = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_7__.ConfigProto)(options || {}, jodit_config__WEBPACK_IMPORTED_MODULE_11__.Config.defaultOptions.uploader); |
| 22366 |
const uploadHandler = ()=>(0,_fetch_load_items__WEBPACK_IMPORTED_MODULE_13__.loadItems)(this); |
| 22367 |
self.uploader = self.getInstance('Uploader', uploaderOptions); |
| 22368 |
self.uploader.setPath(self.state.currentPath).setSource(self.state.currentSource).bind(self.browser, uploadHandler, self.errorHandler); |
| 22369 |
this.state.on([ |
| 22370 |
'change.currentPath', |
| 22371 |
'change.currentSource' |
| 22372 |
], ()=>{ |
| 22373 |
this.uploader.setPath(this.state.currentPath).setSource(this.state.currentSource); |
| 22374 |
}); |
| 22375 |
self.e.on('bindUploader.filebrowser', (button)=>{ |
| 22376 |
self.uploader.bind(button, uploadHandler, self.errorHandler); |
| 22377 |
}); |
| 22378 |
} |
| 22379 |
destruct() { |
| 22380 |
var _cached; |
| 22381 |
if (this.isInDestruct) { |
| 22382 |
return; |
| 22383 |
} |
| 22384 |
(_cached = (0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__.cached)(this, '_dialog')) === null || _cached === void 0 ? void 0 : _cached.destruct(); |
| 22385 |
super.destruct(); |
| 22386 |
this.events && this.e.off('.filebrowser'); |
| 22387 |
this.uploader && this.uploader.destruct(); |
| 22388 |
} |
| 22389 |
__updateToolbarButtons() { |
| 22390 |
var _this_toolbar; |
| 22391 |
const buttons = this.__getButtons(); |
| 22392 |
if (isEqualButtonList(this.__prevButtons, buttons)) { |
| 22393 |
return; |
| 22394 |
} |
| 22395 |
this.__prevButtons = buttons; |
| 22396 |
(_this_toolbar = this.toolbar) === null || _this_toolbar === void 0 ? void 0 : _this_toolbar.build(buttons); |
| 22397 |
} |
| 22398 |
constructor(options){ |
| 22399 |
super(options), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "browser", this.c.div(this.componentName)), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "status_line", this.c.div(this.getFullElName('status'))), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "tree", new _ui__WEBPACK_IMPORTED_MODULE_20__.FileBrowserTree(this)), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "files", new _ui__WEBPACK_IMPORTED_MODULE_20__.FileBrowserFiles(this)), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "state", (0,jodit_core_event_emitter__WEBPACK_IMPORTED_MODULE_6__.observable)({ |
| 22400 |
currentPath: '', |
| 22401 |
currentSource: _data_provider__WEBPACK_IMPORTED_MODULE_18__.DEFAULT_SOURCE_NAME, |
| 22402 |
currentBaseUrl: '', |
| 22403 |
activeElements: [], |
| 22404 |
elements: [], |
| 22405 |
sources: [], |
| 22406 |
view: 'tiles', |
| 22407 |
sortBy: 'changed-desc', |
| 22408 |
filterWord: '', |
| 22409 |
onlyImages: false |
| 22410 |
})), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "errorHandler", (resp)=>{ |
| 22411 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_7__.isAbortError)(resp)) { |
| 22412 |
return; |
| 22413 |
} |
| 22414 |
if (resp instanceof Error) { |
| 22415 |
this.status(this.i18n(resp.message)); |
| 22416 |
} else { |
| 22417 |
this.status(this.dataProvider.getMessage(resp)); |
| 22418 |
} |
| 22419 |
}), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "uploader", void 0), /** |
| 22420 |
* Close dialog |
| 22421 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "close", ()=>{ |
| 22422 |
this._dialog.close(); |
| 22423 |
}), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__prevButtons", []); |
| 22424 |
this.attachEvents(options); |
| 22425 |
const self = this; |
| 22426 |
self.options = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_7__.ConfigProto)(options || {}, jodit_config__WEBPACK_IMPORTED_MODULE_11__.Config.defaultOptions.filebrowser); |
| 22427 |
self.browser.component = this; |
| 22428 |
self.container = self.browser; |
| 22429 |
if (self.o.showFoldersPanel) { |
| 22430 |
self.browser.appendChild(self.tree.container); |
| 22431 |
} |
| 22432 |
self.browser.appendChild(self.files.container); |
| 22433 |
self.browser.appendChild(self.status_line); |
| 22434 |
_listeners_self_listeners__WEBPACK_IMPORTED_MODULE_16__.selfListeners.call(self); |
| 22435 |
_listeners_native_listeners__WEBPACK_IMPORTED_MODULE_15__.nativeListeners.call(self); |
| 22436 |
_listeners_state_listeners__WEBPACK_IMPORTED_MODULE_17__.stateListeners.call(self); |
| 22437 |
const keys = [ |
| 22438 |
'getLocalFileByUrl', |
| 22439 |
'crop', |
| 22440 |
'resize', |
| 22441 |
'create', |
| 22442 |
'fileMove', |
| 22443 |
'folderMove', |
| 22444 |
'fileRename', |
| 22445 |
'folderRename', |
| 22446 |
'fileRemove', |
| 22447 |
'folderRemove', |
| 22448 |
'folder', |
| 22449 |
'items', |
| 22450 |
'permissions' |
| 22451 |
]; |
| 22452 |
keys.forEach((key)=>{ |
| 22453 |
if (this.options[key] != null) { |
| 22454 |
this.options[key] = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_7__.ConfigProto)(this.options[key], this.o.ajax); |
| 22455 |
} |
| 22456 |
}); |
| 22457 |
const { storeView, storeSortBy, storeLastOpenedFolder } = this.o.saveStateInStorage || { |
| 22458 |
storeLastOpenedFolder: false, |
| 22459 |
storeView: false, |
| 22460 |
storeSortBy: false |
| 22461 |
}; |
| 22462 |
const view = storeView && this.storage.get('view'); |
| 22463 |
if (view && this.o.view == null) { |
| 22464 |
self.state.view = view === 'list' ? 'list' : 'tiles'; |
| 22465 |
} else { |
| 22466 |
self.state.view = self.o.view === 'list' ? 'list' : 'tiles'; |
| 22467 |
} |
| 22468 |
self.files.setMod('view', self.state.view); |
| 22469 |
const sortBy = storeSortBy && self.storage.get('sortBy'); |
| 22470 |
if (sortBy) { |
| 22471 |
const parts = sortBy.split('-'); |
| 22472 |
self.state.sortBy = [ |
| 22473 |
'changed', |
| 22474 |
'name', |
| 22475 |
'size' |
| 22476 |
].includes(parts[0]) ? sortBy : 'changed-desc'; |
| 22477 |
} else { |
| 22478 |
self.state.sortBy = self.o.sortBy || 'changed-desc'; |
| 22479 |
} |
| 22480 |
if (storeLastOpenedFolder) { |
| 22481 |
const currentPath = self.storage.get('currentPath'), currentSource = self.storage.get('currentSource'); |
| 22482 |
self.state.currentPath = currentPath !== null && currentPath !== void 0 ? currentPath : ''; |
| 22483 |
self.state.currentSource = currentSource !== null && currentSource !== void 0 ? currentSource : ''; |
| 22484 |
} |
| 22485 |
self.initUploader(self); |
| 22486 |
self.setStatus(jodit_core_component__WEBPACK_IMPORTED_MODULE_2__.STATUSES.ready); |
| 22487 |
} |
| 22488 |
} |
| 22489 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 22490 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__.cache |
| 22491 |
], FileBrowser.prototype, "dataProvider", null); |
| 22492 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 22493 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__.cache |
| 22494 |
], FileBrowser.prototype, "_dialog", null); |
| 22495 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 22496 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__.cache |
| 22497 |
], FileBrowser.prototype, "storage", null); |
| 22498 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 22499 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__.autobind |
| 22500 |
], FileBrowser.prototype, "status", null); |
| 22501 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 22502 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__.autobind |
| 22503 |
], FileBrowser.prototype, "open", null); |
| 22504 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 22505 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__.watch)('dataProvider:changePermissions') |
| 22506 |
], FileBrowser.prototype, "__updateToolbarButtons", null); |
| 22507 |
FileBrowser = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 22508 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__.derive)(jodit_core_traits_dlgs__WEBPACK_IMPORTED_MODULE_9__.Dlgs) |
| 22509 |
], FileBrowser); |
| 22510 |
function isEqualButtonList(prevButtons, buttons) { |
| 22511 |
if (prevButtons.length !== buttons.length) { |
| 22512 |
return false; |
| 22513 |
} |
| 22514 |
for(let i = 0; i < prevButtons.length; i++){ |
| 22515 |
if (prevButtons[i] !== buttons[i]) { |
| 22516 |
return false; |
| 22517 |
} |
| 22518 |
} |
| 22519 |
return true; |
| 22520 |
} |
| 22521 |
|
| 22522 |
|
| 22523 |
/***/ }), |
| 22524 |
|
| 22525 |
/***/ 63425: |
| 22526 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 22527 |
|
| 22528 |
"use strict"; |
| 22529 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 22530 |
/* harmony export */ FileBrowserFiles: function() { return /* reexport safe */ _files_files__WEBPACK_IMPORTED_MODULE_0__.FileBrowserFiles; }, |
| 22531 |
/* harmony export */ FileBrowserTree: function() { return /* reexport safe */ _tree_tree__WEBPACK_IMPORTED_MODULE_1__.FileBrowserTree; } |
| 22532 |
/* harmony export */ }); |
| 22533 |
/* harmony import */ var _files_files__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(86122); |
| 22534 |
/* harmony import */ var _tree_tree__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(55376); |
| 22535 |
/*! |
| 22536 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 22537 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 22538 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 22539 |
*/ /** |
| 22540 |
* @module modules/file-browser |
| 22541 |
*/ |
| 22542 |
|
| 22543 |
|
| 22544 |
|
| 22545 |
/***/ }), |
| 22546 |
|
| 22547 |
/***/ 63468: |
| 22548 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 22549 |
|
| 22550 |
"use strict"; |
| 22551 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 22552 |
/* harmony export */ UIGroup: function() { return /* binding */ UIGroup; } |
| 22553 |
/* harmony export */ }); |
| 22554 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 22555 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 22556 |
/* harmony import */ var jodit_core_component_component__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(80251); |
| 22557 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(84839); |
| 22558 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(23211); |
| 22559 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(65946); |
| 22560 |
/* harmony import */ var jodit_core_ui_element__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(96007); |
| 22561 |
/*! |
| 22562 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 22563 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 22564 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 22565 |
*/ /** |
| 22566 |
* [[include:core/ui/group/README.md]] |
| 22567 |
* @packageDocumentation |
| 22568 |
* @module ui/group |
| 22569 |
*/ |
| 22570 |
|
| 22571 |
|
| 22572 |
|
| 22573 |
|
| 22574 |
|
| 22575 |
|
| 22576 |
|
| 22577 |
class UIGroup extends jodit_core_ui_element__WEBPACK_IMPORTED_MODULE_6__.UIElement { |
| 22578 |
className() { |
| 22579 |
return 'UIGroup'; |
| 22580 |
} |
| 22581 |
getRole() { |
| 22582 |
var _this_options; |
| 22583 |
return ((_this_options = this.options) === null || _this_options === void 0 ? void 0 : _this_options.role) || 'list'; |
| 22584 |
} |
| 22585 |
/** |
| 22586 |
* All group children |
| 22587 |
*/ get allChildren() { |
| 22588 |
const result = []; |
| 22589 |
const stack = [ |
| 22590 |
...this.elements |
| 22591 |
]; |
| 22592 |
while(stack.length){ |
| 22593 |
const elm = stack.shift(); |
| 22594 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.isArray)(elm)) { |
| 22595 |
stack.push(...elm); |
| 22596 |
} else if (jodit_core_component_component__WEBPACK_IMPORTED_MODULE_2__.Component.isInstanceOf(elm, UIGroup)) { |
| 22597 |
stack.push(...elm.elements); |
| 22598 |
} else { |
| 22599 |
elm && result.push(elm); |
| 22600 |
} |
| 22601 |
} |
| 22602 |
return result; |
| 22603 |
} |
| 22604 |
/** |
| 22605 |
* Update all children |
| 22606 |
*/ update() { |
| 22607 |
this.elements.forEach((elm)=>elm.update()); |
| 22608 |
this.setMod('size', this.buttonSize); |
| 22609 |
} |
| 22610 |
append(elms, distElementOrIndex) { |
| 22611 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.isArray)(elms)) { |
| 22612 |
if (typeof distElementOrIndex === 'number') { |
| 22613 |
throw new Error('You can not use index when append array of elements'); |
| 22614 |
} |
| 22615 |
elms.forEach((item)=>this.append(item, distElementOrIndex)); |
| 22616 |
return this; |
| 22617 |
} |
| 22618 |
const elm = elms; |
| 22619 |
let index = undefined; |
| 22620 |
if (typeof distElementOrIndex === 'number') { |
| 22621 |
index = Math.min(Math.max(0, distElementOrIndex), this.elements.length); |
| 22622 |
this.elements.splice(index, 0, elm); |
| 22623 |
} else { |
| 22624 |
this.elements.push(elm); |
| 22625 |
} |
| 22626 |
if (elm.name) { |
| 22627 |
elm.container.classList.add(this.getFullElName(elm.name)); |
| 22628 |
} |
| 22629 |
if (distElementOrIndex && typeof distElementOrIndex === 'string') { |
| 22630 |
const distElm = this.getElm(distElementOrIndex); |
| 22631 |
if (distElm == null) { |
| 22632 |
throw new Error('Element does not exist'); |
| 22633 |
} |
| 22634 |
distElm.appendChild(elm.container); |
| 22635 |
} else { |
| 22636 |
this.appendChildToContainer(elm.container, index); |
| 22637 |
} |
| 22638 |
elm.parentElement = this; |
| 22639 |
return this; |
| 22640 |
} |
| 22641 |
/** @override */ afterSetMod(name, value) { |
| 22642 |
if (this.syncMod) { |
| 22643 |
this.elements.forEach((elm)=>elm.setMod(name, value)); |
| 22644 |
} |
| 22645 |
} |
| 22646 |
/** |
| 22647 |
* Allow set another container for the box of all children |
| 22648 |
*/ appendChildToContainer(childContainer, index) { |
| 22649 |
if (index === undefined || index < 0 || index > this.elements.length - 1 || this.container.children[index] == null) { |
| 22650 |
this.container.appendChild(childContainer); |
| 22651 |
} else { |
| 22652 |
this.container.insertBefore(childContainer, this.container.children[index]); |
| 22653 |
} |
| 22654 |
} |
| 22655 |
/** |
| 22656 |
* Remove element from group |
| 22657 |
*/ remove(elm) { |
| 22658 |
const index = this.elements.indexOf(elm); |
| 22659 |
if (index !== -1) { |
| 22660 |
this.elements.splice(index, 1); |
| 22661 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeRemove(elm.container); |
| 22662 |
elm.parentElement = null; |
| 22663 |
} |
| 22664 |
return this; |
| 22665 |
} |
| 22666 |
/** |
| 22667 |
* Clear group |
| 22668 |
*/ clear() { |
| 22669 |
this.elements.forEach((elm)=>elm.destruct()); |
| 22670 |
this.elements.length = 0; |
| 22671 |
return this; |
| 22672 |
} |
| 22673 |
setParentView(view) { |
| 22674 |
var _this_elements; |
| 22675 |
(_this_elements = this.elements) === null || _this_elements === void 0 ? void 0 : _this_elements.forEach((elm)=>elm.setParentView(view)); |
| 22676 |
return super.setParentView(view); |
| 22677 |
} |
| 22678 |
/** @override */ destruct() { |
| 22679 |
this.clear(); |
| 22680 |
return super.destruct(); |
| 22681 |
} |
| 22682 |
/** |
| 22683 |
* @param elements - Items of group |
| 22684 |
*/ constructor(jodit, elements, options){ |
| 22685 |
super(jodit, options), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "options", void 0), /** |
| 22686 |
* Synchronize mods to all children |
| 22687 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "syncMod", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "elements", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "buttonSize", void 0), this.options = options, this.syncMod = false, this.elements = [], this.buttonSize = 'middle'; |
| 22688 |
elements === null || elements === void 0 ? void 0 : elements.forEach((elm)=>elm && this.append(elm)); |
| 22689 |
if (options === null || options === void 0 ? void 0 : options.name) { |
| 22690 |
this.name = options.name; |
| 22691 |
} |
| 22692 |
} |
| 22693 |
} |
| 22694 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 22695 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.watch)('buttonSize') |
| 22696 |
], UIGroup.prototype, "update", null); |
| 22697 |
UIGroup = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 22698 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.component |
| 22699 |
], UIGroup); |
| 22700 |
|
| 22701 |
|
| 22702 |
/***/ }), |
| 22703 |
|
| 22704 |
/***/ 63837: |
| 22705 |
/***/ (function(module) { |
| 22706 |
|
| 22707 |
module.exports["default"] = {"Type something":"Start writing...","pencil":"Edit","Quadrate":"Square"} |
| 22708 |
|
| 22709 |
/***/ }), |
| 22710 |
|
| 22711 |
/***/ 64094: |
| 22712 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 22713 |
|
| 22714 |
"use strict"; |
| 22715 |
/* unused harmony export justify */ |
| 22716 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 22717 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(28077); |
| 22718 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(65946); |
| 22719 |
/* harmony import */ var jodit_core_helpers_utils_align__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(16849); |
| 22720 |
/* harmony import */ var jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(80991); |
| 22721 |
/* harmony import */ var jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(29434); |
| 22722 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(5266); |
| 22723 |
/* harmony import */ var _justify_svg__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(80515); |
| 22724 |
/* harmony import */ var _justify_svg__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(_justify_svg__WEBPACK_IMPORTED_MODULE_7__); |
| 22725 |
/*! |
| 22726 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 22727 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 22728 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 22729 |
*/ /** |
| 22730 |
* [[include:plugins/justify/README.md]] |
| 22731 |
* @packageDocumentation |
| 22732 |
* @module plugins/justify |
| 22733 |
*/ |
| 22734 |
|
| 22735 |
|
| 22736 |
|
| 22737 |
|
| 22738 |
|
| 22739 |
|
| 22740 |
|
| 22741 |
jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_5__.Icon.set('justify', (_justify_svg__WEBPACK_IMPORTED_MODULE_7___default())); |
| 22742 |
jodit_config__WEBPACK_IMPORTED_MODULE_6__.Config.prototype.controls.align = { |
| 22743 |
name: 'left', |
| 22744 |
tooltip: 'Align', |
| 22745 |
update (editor, button) { |
| 22746 |
const control = button.control, current = editor.s.current(); |
| 22747 |
if (current) { |
| 22748 |
const currentBox = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(current, jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isBlock, editor.editor) || editor.editor; |
| 22749 |
let currentValue = (0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_4__.css)(currentBox, 'text-align').toString(); |
| 22750 |
if (control.defaultValue && control.defaultValue.indexOf(currentValue) !== -1) { |
| 22751 |
currentValue = 'left'; |
| 22752 |
} |
| 22753 |
const { list, data } = control; |
| 22754 |
if (data && data.currentValue !== currentValue && list && ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_2__.isPlainObject)(list) ? list[currentValue] : list.includes(currentValue))) { |
| 22755 |
if (editor.o.textIcons || control.component === 'select') { |
| 22756 |
button.state.text = currentValue; |
| 22757 |
} else { |
| 22758 |
button.state.icon.name = currentValue; |
| 22759 |
} |
| 22760 |
data.currentValue = currentValue; |
| 22761 |
} |
| 22762 |
} |
| 22763 |
}, |
| 22764 |
isActive: (editor, btn)=>{ |
| 22765 |
const current = editor.s.current(); |
| 22766 |
if (!current || !btn.control.defaultValue) { |
| 22767 |
return false; |
| 22768 |
} |
| 22769 |
const currentBox = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(current, jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isBlock, editor.editor) || editor.editor; |
| 22770 |
return btn.control.defaultValue.indexOf((0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_4__.css)(currentBox, 'text-align').toString()) === -1; |
| 22771 |
}, |
| 22772 |
defaultValue: [ |
| 22773 |
'left', |
| 22774 |
'start', |
| 22775 |
'inherit' |
| 22776 |
], |
| 22777 |
data: { |
| 22778 |
currentValue: 'left' |
| 22779 |
}, |
| 22780 |
list: [ |
| 22781 |
'center', |
| 22782 |
'left', |
| 22783 |
'right', |
| 22784 |
'justify' |
| 22785 |
] |
| 22786 |
}; |
| 22787 |
jodit_config__WEBPACK_IMPORTED_MODULE_6__.Config.prototype.controls.center = { |
| 22788 |
command: 'justifyCenter', |
| 22789 |
css: { |
| 22790 |
'text-align': 'center' |
| 22791 |
}, |
| 22792 |
tooltip: 'Align Center' |
| 22793 |
}; |
| 22794 |
jodit_config__WEBPACK_IMPORTED_MODULE_6__.Config.prototype.controls.justify = { |
| 22795 |
command: 'justifyFull', |
| 22796 |
css: { |
| 22797 |
'text-align': 'justify' |
| 22798 |
}, |
| 22799 |
tooltip: 'Align Justify' |
| 22800 |
}; |
| 22801 |
jodit_config__WEBPACK_IMPORTED_MODULE_6__.Config.prototype.controls.left = { |
| 22802 |
command: 'justifyLeft', |
| 22803 |
css: { |
| 22804 |
'text-align': 'left' |
| 22805 |
}, |
| 22806 |
tooltip: 'Align Left' |
| 22807 |
}; |
| 22808 |
jodit_config__WEBPACK_IMPORTED_MODULE_6__.Config.prototype.controls.right = { |
| 22809 |
command: 'justifyRight', |
| 22810 |
css: { |
| 22811 |
'text-align': 'right' |
| 22812 |
}, |
| 22813 |
tooltip: 'Align Right' |
| 22814 |
}; |
| 22815 |
/** |
| 22816 |
* Process commands: `justifyfull`, `justifyleft`, `justifyright`, `justifycenter` |
| 22817 |
*/ function justify(editor) { |
| 22818 |
editor.registerButton({ |
| 22819 |
name: 'align', |
| 22820 |
group: 'indent' |
| 22821 |
}); |
| 22822 |
const callback = (command)=>{ |
| 22823 |
editor.s.focus(); |
| 22824 |
editor.s.eachSelection((current)=>{ |
| 22825 |
if (!current) { |
| 22826 |
return; |
| 22827 |
} |
| 22828 |
let currentBox = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.up(current, jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isBlock, editor.editor); |
| 22829 |
if (!currentBox) { |
| 22830 |
currentBox = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.wrapInline(current, editor.o.enterBlock, editor); |
| 22831 |
} |
| 22832 |
(0,jodit_core_helpers_utils_align__WEBPACK_IMPORTED_MODULE_3__.alignElement)(command, currentBox); |
| 22833 |
}); |
| 22834 |
return false; |
| 22835 |
}; |
| 22836 |
editor.registerCommand('justifyfull', callback); |
| 22837 |
editor.registerCommand('justifyright', callback); |
| 22838 |
editor.registerCommand('justifyleft', callback); |
| 22839 |
editor.registerCommand('justifycenter', callback); |
| 22840 |
} |
| 22841 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_1__.pluginSystem.add('justify', justify); |
| 22842 |
|
| 22843 |
|
| 22844 |
/***/ }), |
| 22845 |
|
| 22846 |
/***/ 64637: |
| 22847 |
/***/ (function(module) { |
| 22848 |
|
| 22849 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 432 432\"> <g> <polygon points=\"203.688,96 0,96 0,144 155.688,144 \"/> <polygon points=\"155.719,288 0,288 0,336 203.719,336 \"/> <path d=\"M97.844,230.125c-3.701-3.703-5.856-8.906-5.856-14.141s2.154-10.438,5.856-14.141l9.844-9.844H0v48h107.719 L97.844,230.125z\"/> <polygon points=\"232,176 232,96 112,216 232,336 232,256 432,256 432,176\"/> </g> </svg>" |
| 22850 |
|
| 22851 |
/***/ }), |
| 22852 |
|
| 22853 |
/***/ 64831: |
| 22854 |
/***/ (function(module) { |
| 22855 |
|
| 22856 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M576 576q0 80-56 136t-136 56-136-56-56-136 56-136 136-56 136 56 56 136zm1024 384v448h-1408v-192l320-320 160 160 512-512zm96-704h-1600q-13 0-22.5 9.5t-9.5 22.5v1216q0 13 9.5 22.5t22.5 9.5h1600q13 0 22.5-9.5t9.5-22.5v-1216q0-13-9.5-22.5t-22.5-9.5zm160 32v1216q0 66-47 113t-113 47h-1600q-66 0-113-47t-47-113v-1216q0-66 47-113t113-47h1600q66 0 113 47t47 113z\"/> </svg>" |
| 22857 |
|
| 22858 |
/***/ }), |
| 22859 |
|
| 22860 |
/***/ 64847: |
| 22861 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 22862 |
|
| 22863 |
"use strict"; |
| 22864 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 22865 |
/* harmony export */ UIGroup: function() { return /* reexport safe */ _group__WEBPACK_IMPORTED_MODULE_0__.UIGroup; }, |
| 22866 |
/* harmony export */ UIList: function() { return /* reexport safe */ _list__WEBPACK_IMPORTED_MODULE_1__.UIList; }, |
| 22867 |
/* harmony export */ UISeparator: function() { return /* reexport safe */ _separator__WEBPACK_IMPORTED_MODULE_2__.UISeparator; }, |
| 22868 |
/* harmony export */ UISpacer: function() { return /* reexport safe */ _spacer__WEBPACK_IMPORTED_MODULE_3__.UISpacer; } |
| 22869 |
/* harmony export */ }); |
| 22870 |
/* harmony import */ var _group__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(63468); |
| 22871 |
/* harmony import */ var _list__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(97959); |
| 22872 |
/* harmony import */ var _separator__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(35676); |
| 22873 |
/* harmony import */ var _spacer__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(27987); |
| 22874 |
/*! |
| 22875 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 22876 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 22877 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 22878 |
*/ /** |
| 22879 |
* @module ui/group |
| 22880 |
*/ |
| 22881 |
|
| 22882 |
|
| 22883 |
|
| 22884 |
|
| 22885 |
|
| 22886 |
/***/ }), |
| 22887 |
|
| 22888 |
/***/ 65015: |
| 22889 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 22890 |
|
| 22891 |
"use strict"; |
| 22892 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 22893 |
/* harmony export */ sanitizeAttributes: function() { return /* binding */ sanitizeAttributes; } |
| 22894 |
/* harmony export */ }); |
| 22895 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 22896 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(65946); |
| 22897 |
/*! |
| 22898 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 22899 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 22900 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 22901 |
*/ /** |
| 22902 |
* @module plugins/clean-html |
| 22903 |
*/ |
| 22904 |
|
| 22905 |
/** |
| 22906 |
* @private |
| 22907 |
*/ function sanitizeAttributes(jodit, nodeElm, hadEffect) { |
| 22908 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isElement(nodeElm) && (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__.sanitizeHTMLElement)(nodeElm, { |
| 22909 |
safeJavaScriptLink: jodit.options.cleanHTML.safeJavaScriptLink, |
| 22910 |
removeOnError: jodit.options.cleanHTML.removeOnError |
| 22911 |
})) { |
| 22912 |
return true; |
| 22913 |
} |
| 22914 |
return hadEffect; |
| 22915 |
} |
| 22916 |
|
| 22917 |
|
| 22918 |
/***/ }), |
| 22919 |
|
| 22920 |
/***/ 65230: |
| 22921 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 22922 |
|
| 22923 |
"use strict"; |
| 22924 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 22925 |
/* harmony import */ var jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(29434); |
| 22926 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5266); |
| 22927 |
/* harmony import */ var _icons_link_svg__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(95032); |
| 22928 |
/* harmony import */ var _icons_link_svg__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_icons_link_svg__WEBPACK_IMPORTED_MODULE_3__); |
| 22929 |
/* harmony import */ var _icons_unlink_svg__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(73533); |
| 22930 |
/* harmony import */ var _icons_unlink_svg__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_icons_unlink_svg__WEBPACK_IMPORTED_MODULE_4__); |
| 22931 |
/* harmony import */ var jodit_plugins_link_template__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(45778); |
| 22932 |
/*! |
| 22933 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 22934 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 22935 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 22936 |
*/ /** |
| 22937 |
* @module plugins/link |
| 22938 |
*/ |
| 22939 |
|
| 22940 |
|
| 22941 |
|
| 22942 |
|
| 22943 |
|
| 22944 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.link = { |
| 22945 |
formTemplate: jodit_plugins_link_template__WEBPACK_IMPORTED_MODULE_5__.formTemplate, |
| 22946 |
followOnDblClick: false, |
| 22947 |
processVideoLink: true, |
| 22948 |
processPastedLink: true, |
| 22949 |
noFollowCheckbox: true, |
| 22950 |
openInNewTabCheckbox: true, |
| 22951 |
modeClassName: 'input', |
| 22952 |
selectMultipleClassName: true, |
| 22953 |
preventReadOnlyNavigation: true, |
| 22954 |
selectSizeClassName: 3, |
| 22955 |
selectOptionsClassName: [], |
| 22956 |
hotkeys: [ |
| 22957 |
'ctrl+k', |
| 22958 |
'cmd+k' |
| 22959 |
] |
| 22960 |
}; |
| 22961 |
jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_1__.Icon.set('link', (_icons_link_svg__WEBPACK_IMPORTED_MODULE_3___default())).set('unlink', (_icons_unlink_svg__WEBPACK_IMPORTED_MODULE_4___default())); |
| 22962 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.controls.unlink = { |
| 22963 |
exec: (editor, current)=>{ |
| 22964 |
const anchor = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(current, 'a', editor.editor); |
| 22965 |
if (anchor) { |
| 22966 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.unwrap(anchor); |
| 22967 |
} |
| 22968 |
editor.synchronizeValues(); |
| 22969 |
editor.e.fire('hidePopup'); |
| 22970 |
}, |
| 22971 |
tooltip: 'Unlink' |
| 22972 |
}; |
| 22973 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.controls.link = { |
| 22974 |
isActive: (editor)=>{ |
| 22975 |
const current = editor.s.current(); |
| 22976 |
return Boolean(current && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(current, 'a', editor.editor)); |
| 22977 |
}, |
| 22978 |
popup: (editor, current, close)=>{ |
| 22979 |
return editor.e.fire('generateLinkForm.link', current, close); |
| 22980 |
}, |
| 22981 |
tags: [ |
| 22982 |
'a' |
| 22983 |
], |
| 22984 |
tooltip: 'Insert link' |
| 22985 |
}; |
| 22986 |
|
| 22987 |
|
| 22988 |
/***/ }), |
| 22989 |
|
| 22990 |
/***/ 65273: |
| 22991 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 22992 |
|
| 22993 |
"use strict"; |
| 22994 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 22995 |
/* harmony export */ UIInput: function() { return /* binding */ UIInput; } |
| 22996 |
/* harmony export */ }); |
| 22997 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 22998 |
/* harmony import */ var _swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(41411); |
| 22999 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(31635); |
| 23000 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(84839); |
| 23001 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(23211); |
| 23002 |
/* harmony import */ var jodit_core_helpers_array_to_array__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(88475); |
| 23003 |
/* harmony import */ var jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(93640); |
| 23004 |
/* harmony import */ var jodit_core_ui_element__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(96007); |
| 23005 |
/* harmony import */ var jodit_core_ui_form_validators__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(81488); |
| 23006 |
/* harmony import */ var jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(29434); |
| 23007 |
/*! |
| 23008 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 23009 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 23010 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 23011 |
*/ /** |
| 23012 |
* @module ui/form |
| 23013 |
*/ |
| 23014 |
|
| 23015 |
|
| 23016 |
|
| 23017 |
|
| 23018 |
|
| 23019 |
|
| 23020 |
|
| 23021 |
|
| 23022 |
|
| 23023 |
|
| 23024 |
class UIInput extends jodit_core_ui_element__WEBPACK_IMPORTED_MODULE_7__.UIElement { |
| 23025 |
/** @override */ className() { |
| 23026 |
return 'UIInput'; |
| 23027 |
} |
| 23028 |
onChangeClear() { |
| 23029 |
if (this.state.clearButton) { |
| 23030 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.after(this.nativeInput, this.clearButton); |
| 23031 |
} else { |
| 23032 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeRemove(this.clearButton); |
| 23033 |
} |
| 23034 |
} |
| 23035 |
onChangeClassName(ignore, oldClassName) { |
| 23036 |
oldClassName && this.container.classList.remove(oldClassName); |
| 23037 |
this.state.className && this.container.classList.add(this.state.className); |
| 23038 |
} |
| 23039 |
onChangeState() { |
| 23040 |
this.name = this.state.name; |
| 23041 |
const input = this.nativeInput, { name, icon, type, ref, required, placeholder, autocomplete, label } = this.state; |
| 23042 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_6__.attr)(input, 'name', name); |
| 23043 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_6__.attr)(input, 'type', type); |
| 23044 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_6__.attr)(input, 'data-ref', ref || name); |
| 23045 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_6__.attr)(input, 'ref', ref || name); |
| 23046 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_6__.attr)(input, 'required', required || null); |
| 23047 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_6__.attr)(input, 'autocomplete', !autocomplete ? 'off' : null); |
| 23048 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_6__.attr)(input, 'placeholder', placeholder ? this.j.i18n(placeholder) : ''); |
| 23049 |
if (icon && jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_9__.Icon.exists(icon)) { |
| 23050 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.before(input, this.icon); |
| 23051 |
this.icon.innerHTML = jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_9__.Icon.get(icon); |
| 23052 |
} else { |
| 23053 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeRemove(this.icon); |
| 23054 |
} |
| 23055 |
if (label) { |
| 23056 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.before(this.wrapper, this.label); |
| 23057 |
this.label.innerText = this.j.i18n(label); |
| 23058 |
} else { |
| 23059 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeRemove(this.label); |
| 23060 |
} |
| 23061 |
this.updateValidators(); |
| 23062 |
} |
| 23063 |
updateValidators() { |
| 23064 |
var _this_state_validators; |
| 23065 |
this.validators.clear(); |
| 23066 |
if (this.state.required) { |
| 23067 |
this.validators.add(jodit_core_ui_form_validators__WEBPACK_IMPORTED_MODULE_8__.inputValidators.required); |
| 23068 |
} |
| 23069 |
(_this_state_validators = this.state.validators) === null || _this_state_validators === void 0 ? void 0 : _this_state_validators.forEach((name)=>{ |
| 23070 |
const validator = jodit_core_ui_form_validators__WEBPACK_IMPORTED_MODULE_8__.inputValidators[name]; |
| 23071 |
validator && this.validators.add(validator); |
| 23072 |
}); |
| 23073 |
} |
| 23074 |
set error(value) { |
| 23075 |
this.setMod('has-error', Boolean(value)); |
| 23076 |
if (!value) { |
| 23077 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeRemove(this.__errorBox); |
| 23078 |
} else { |
| 23079 |
this.__errorBox.innerText = this.j.i18n(value, this.j.i18n(this.state.label || '')); |
| 23080 |
this.container.appendChild(this.__errorBox); |
| 23081 |
} |
| 23082 |
} |
| 23083 |
get value() { |
| 23084 |
return this.nativeInput.value; |
| 23085 |
} |
| 23086 |
set value(value) { |
| 23087 |
if (this.value !== value) { |
| 23088 |
this.nativeInput.value = value; |
| 23089 |
this.onChangeValue(); |
| 23090 |
} |
| 23091 |
} |
| 23092 |
/** |
| 23093 |
* Call on every state value changed |
| 23094 |
*/ onChangeStateValue() { |
| 23095 |
const value = this.state.value.toString(); |
| 23096 |
if (value !== this.value) { |
| 23097 |
this.value = value; |
| 23098 |
} |
| 23099 |
} |
| 23100 |
/** |
| 23101 |
* Call on every native value changed |
| 23102 |
*/ onChangeValue() { |
| 23103 |
const { value } = this; |
| 23104 |
if (this.state.value !== value) { |
| 23105 |
var _this_state_onChange, _this_state; |
| 23106 |
this.state.value = value; |
| 23107 |
this.j.e.fire(this, 'change', value); |
| 23108 |
(_this_state_onChange = (_this_state = this.state).onChange) === null || _this_state_onChange === void 0 ? void 0 : _this_state_onChange.call(_this_state, value); |
| 23109 |
} |
| 23110 |
} |
| 23111 |
validate() { |
| 23112 |
this.error = ''; |
| 23113 |
const validate = (0,jodit_core_helpers_array_to_array__WEBPACK_IMPORTED_MODULE_5__.toArray)(this.validators).every((validator)=>validator(this)); |
| 23114 |
this.__markInputInvalid(); |
| 23115 |
return validate; |
| 23116 |
} |
| 23117 |
__markInputInvalid() { |
| 23118 |
if (this.error) { |
| 23119 |
var _this_nativeInput_setCustomValidity, _this_nativeInput; |
| 23120 |
this.nativeInput.setAttribute('aria-invalid', 'true'); |
| 23121 |
(_this_nativeInput_setCustomValidity = (_this_nativeInput = this.nativeInput).setCustomValidity) === null || _this_nativeInput_setCustomValidity === void 0 ? void 0 : _this_nativeInput_setCustomValidity.call(_this_nativeInput, this.error); |
| 23122 |
} else { |
| 23123 |
var _this_nativeInput_setCustomValidity1, _this_nativeInput1; |
| 23124 |
this.nativeInput.removeAttribute('aria-invalid'); |
| 23125 |
(_this_nativeInput_setCustomValidity1 = (_this_nativeInput1 = this.nativeInput).setCustomValidity) === null || _this_nativeInput_setCustomValidity1 === void 0 ? void 0 : _this_nativeInput_setCustomValidity1.call(_this_nativeInput1, ''); |
| 23126 |
} |
| 23127 |
} |
| 23128 |
/** @override **/ createContainer(options) { |
| 23129 |
const container = super.createContainer(); |
| 23130 |
this.wrapper = this.j.c.div(this.getFullElName('wrapper')); |
| 23131 |
if (!this.nativeInput) { |
| 23132 |
this.nativeInput = this.createNativeInput(); |
| 23133 |
} |
| 23134 |
const { nativeInput } = this; |
| 23135 |
nativeInput.classList.add(this.getFullElName('input')); |
| 23136 |
this.wrapper.appendChild(nativeInput); |
| 23137 |
container.appendChild(this.wrapper); |
| 23138 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_6__.attr)(nativeInput, 'dir', this.j.o.direction || 'auto'); |
| 23139 |
return container; |
| 23140 |
} |
| 23141 |
/** |
| 23142 |
* Create native input element |
| 23143 |
*/ createNativeInput(options) { |
| 23144 |
return this.j.create.element('input'); |
| 23145 |
} |
| 23146 |
focus() { |
| 23147 |
this.nativeInput.focus(); |
| 23148 |
} |
| 23149 |
get isFocused() { |
| 23150 |
return this.nativeInput === this.j.od.activeElement; |
| 23151 |
} |
| 23152 |
/** |
| 23153 |
* Set `focused` mod on change focus |
| 23154 |
*/ onChangeFocus() { |
| 23155 |
this.setMod('focused', this.isFocused); |
| 23156 |
} |
| 23157 |
/** @override **/ constructor(jodit, options){ |
| 23158 |
super(jodit, options), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "label", this.j.c.span(this.getFullElName('label'))), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "icon", this.j.c.span(this.getFullElName('icon'))), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "clearButton", this.j.c.span(this.getFullElName('clear'), jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_9__.Icon.get('cancel'))), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "state", (0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_1__._)({}, UIInput.defaultState)), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__errorBox", this.j.c.span(this.getFullElName('error'))), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "validators", new Set([])); |
| 23159 |
if ((options === null || options === void 0 ? void 0 : options.value) !== undefined) { |
| 23160 |
options.value = options.value.toString(); |
| 23161 |
} |
| 23162 |
Object.assign(this.state, options); |
| 23163 |
if (this.state.clearButton !== undefined) { |
| 23164 |
this.j.e.on(this.clearButton, 'click', (e)=>{ |
| 23165 |
e.preventDefault(); |
| 23166 |
this.nativeInput.value = ''; |
| 23167 |
this.j.e.fire(this.nativeInput, 'input'); |
| 23168 |
this.focus(); |
| 23169 |
}).on(this.nativeInput, 'input', ()=>{ |
| 23170 |
this.state.clearButton = Boolean(this.value.length); |
| 23171 |
}); |
| 23172 |
this.state.clearButton = Boolean(this.value.length); |
| 23173 |
} |
| 23174 |
this.j.e.on(this.nativeInput, 'focus blur', ()=>{ |
| 23175 |
this.onChangeFocus(); |
| 23176 |
}).on(this.nativeInput, 'input change', this.onChangeValue); |
| 23177 |
this.onChangeState(); |
| 23178 |
this.onChangeClassName(); |
| 23179 |
this.onChangeStateValue(); |
| 23180 |
} |
| 23181 |
} |
| 23182 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(UIInput, "defaultState", { |
| 23183 |
className: '', |
| 23184 |
autocomplete: true, |
| 23185 |
name: '', |
| 23186 |
value: '', |
| 23187 |
icon: '', |
| 23188 |
label: '', |
| 23189 |
ref: '', |
| 23190 |
type: 'text', |
| 23191 |
placeholder: '', |
| 23192 |
required: false, |
| 23193 |
validators: [] |
| 23194 |
}); |
| 23195 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 23196 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.watch)('state.clearButton') |
| 23197 |
], UIInput.prototype, "onChangeClear", null); |
| 23198 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 23199 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.watch)('state.className') |
| 23200 |
], UIInput.prototype, "onChangeClassName", null); |
| 23201 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 23202 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.watch)([ |
| 23203 |
'state.name', |
| 23204 |
'state.type', |
| 23205 |
'state.label', |
| 23206 |
'state.placeholder', |
| 23207 |
'state.autocomplete', |
| 23208 |
'state.icon' |
| 23209 |
], { |
| 23210 |
immediately: false |
| 23211 |
}), |
| 23212 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.debounce)() |
| 23213 |
], UIInput.prototype, "onChangeState", null); |
| 23214 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 23215 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.watch)('state.value') |
| 23216 |
], UIInput.prototype, "onChangeStateValue", null); |
| 23217 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 23218 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 23219 |
], UIInput.prototype, "onChangeValue", null); |
| 23220 |
UIInput = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 23221 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.component |
| 23222 |
], UIInput); |
| 23223 |
|
| 23224 |
|
| 23225 |
/***/ }), |
| 23226 |
|
| 23227 |
/***/ 65710: |
| 23228 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 23229 |
|
| 23230 |
"use strict"; |
| 23231 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 23232 |
/* harmony export */ insertParagraph: function() { return /* binding */ insertParagraph; } |
| 23233 |
/* harmony export */ }); |
| 23234 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 23235 |
/* harmony import */ var jodit_core_helpers_utils_scroll_into_view__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(60898); |
| 23236 |
/*! |
| 23237 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 23238 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 23239 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 23240 |
*/ /** |
| 23241 |
* @module plugins/enter |
| 23242 |
*/ |
| 23243 |
|
| 23244 |
/** |
| 23245 |
* Insert default paragraph |
| 23246 |
* @private |
| 23247 |
*/ function insertParagraph(fake, editor, wrapperTag, style) { |
| 23248 |
const isBR = wrapperTag.toLowerCase() === 'br', { createInside } = editor, p = createInside.element(wrapperTag), br = createInside.element('br'); |
| 23249 |
if (!isBR) { |
| 23250 |
p.appendChild(br); |
| 23251 |
} |
| 23252 |
if (style && style.cssText) { |
| 23253 |
p.setAttribute('style', style.cssText); |
| 23254 |
} |
| 23255 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.after(fake, p); |
| 23256 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.before(isBR ? p : br, fake); |
| 23257 |
(0,jodit_core_helpers_utils_scroll_into_view__WEBPACK_IMPORTED_MODULE_1__.scrollIntoViewIfNeeded)(p, editor.editor, editor.ed); |
| 23258 |
return p; |
| 23259 |
} |
| 23260 |
|
| 23261 |
|
| 23262 |
/***/ }), |
| 23263 |
|
| 23264 |
/***/ 65946: |
| 23265 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 23266 |
|
| 23267 |
"use strict"; |
| 23268 |
__webpack_require__.r(__webpack_exports__); |
| 23269 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 23270 |
/* harmony export */ CamelCaseToKebabCase: function() { return /* reexport safe */ _string__WEBPACK_IMPORTED_MODULE_7__.CamelCaseToKebabCase; }, |
| 23271 |
/* harmony export */ NUMBER_FIELDS_REG: function() { return /* reexport safe */ _normalize__WEBPACK_IMPORTED_MODULE_5__.NUMBER_FIELDS_REG; }, |
| 23272 |
/* harmony export */ applyStyles: function() { return /* reexport safe */ _html__WEBPACK_IMPORTED_MODULE_4__.applyStyles; }, |
| 23273 |
/* harmony export */ asArray: function() { return /* reexport safe */ _array__WEBPACK_IMPORTED_MODULE_0__.asArray; }, |
| 23274 |
/* harmony export */ camelCase: function() { return /* reexport safe */ _string__WEBPACK_IMPORTED_MODULE_7__.camelCase; }, |
| 23275 |
/* harmony export */ cleanFromWord: function() { return /* reexport safe */ _html__WEBPACK_IMPORTED_MODULE_4__.cleanFromWord; }, |
| 23276 |
/* harmony export */ clearTimeout: function() { return /* reexport safe */ _async__WEBPACK_IMPORTED_MODULE_1__.clearTimeout; }, |
| 23277 |
/* harmony export */ colorToHex: function() { return /* reexport safe */ _color__WEBPACK_IMPORTED_MODULE_3__.colorToHex; }, |
| 23278 |
/* harmony export */ fuzzySearchIndex: function() { return /* reexport safe */ _string__WEBPACK_IMPORTED_MODULE_7__.fuzzySearchIndex; }, |
| 23279 |
/* harmony export */ getContentWidth: function() { return /* reexport safe */ _size__WEBPACK_IMPORTED_MODULE_6__.getContentWidth; }, |
| 23280 |
/* harmony export */ getScrollParent: function() { return /* reexport safe */ _size__WEBPACK_IMPORTED_MODULE_6__.getScrollParent; }, |
| 23281 |
/* harmony export */ hasBrowserColorPicker: function() { return /* reexport safe */ _checker__WEBPACK_IMPORTED_MODULE_2__.hasBrowserColorPicker; }, |
| 23282 |
/* harmony export */ hasContainer: function() { return /* reexport safe */ _checker__WEBPACK_IMPORTED_MODULE_2__.hasContainer; }, |
| 23283 |
/* harmony export */ htmlspecialchars: function() { return /* reexport safe */ _html__WEBPACK_IMPORTED_MODULE_4__.htmlspecialchars; }, |
| 23284 |
/* harmony export */ i18n: function() { return /* reexport safe */ _string__WEBPACK_IMPORTED_MODULE_7__.i18n; }, |
| 23285 |
/* harmony export */ innerWidth: function() { return /* reexport safe */ _size__WEBPACK_IMPORTED_MODULE_6__.innerWidth; }, |
| 23286 |
/* harmony export */ isAbortError: function() { return /* reexport safe */ _checker__WEBPACK_IMPORTED_MODULE_2__.isAbortError; }, |
| 23287 |
/* harmony export */ isArray: function() { return /* reexport safe */ _checker__WEBPACK_IMPORTED_MODULE_2__.isArray; }, |
| 23288 |
/* harmony export */ isBoolean: function() { return /* reexport safe */ _checker__WEBPACK_IMPORTED_MODULE_2__.isBoolean; }, |
| 23289 |
/* harmony export */ isDestructable: function() { return /* reexport safe */ _checker__WEBPACK_IMPORTED_MODULE_2__.isDestructable; }, |
| 23290 |
/* harmony export */ isEqual: function() { return /* reexport safe */ _checker__WEBPACK_IMPORTED_MODULE_2__.isEqual; }, |
| 23291 |
/* harmony export */ isFastEqual: function() { return /* reexport safe */ _checker__WEBPACK_IMPORTED_MODULE_2__.isFastEqual; }, |
| 23292 |
/* harmony export */ isFunction: function() { return /* reexport safe */ _checker__WEBPACK_IMPORTED_MODULE_2__.isFunction; }, |
| 23293 |
/* harmony export */ isHTML: function() { return /* reexport safe */ _checker__WEBPACK_IMPORTED_MODULE_2__.isHTML; }, |
| 23294 |
/* harmony export */ isHtmlFromWord: function() { return /* reexport safe */ _checker__WEBPACK_IMPORTED_MODULE_2__.isHtmlFromWord; }, |
| 23295 |
/* harmony export */ isInitable: function() { return /* reexport safe */ _checker__WEBPACK_IMPORTED_MODULE_2__.isInitable; }, |
| 23296 |
/* harmony export */ isInt: function() { return /* reexport safe */ _checker__WEBPACK_IMPORTED_MODULE_2__.isInt; }, |
| 23297 |
/* harmony export */ isJoditObject: function() { return /* reexport safe */ _checker__WEBPACK_IMPORTED_MODULE_2__.isJoditObject; }, |
| 23298 |
/* harmony export */ isLicense: function() { return /* reexport safe */ _checker__WEBPACK_IMPORTED_MODULE_2__.isLicense; }, |
| 23299 |
/* harmony export */ isMarker: function() { return /* reexport safe */ _checker__WEBPACK_IMPORTED_MODULE_2__.isMarker; }, |
| 23300 |
/* harmony export */ isNativeFunction: function() { return /* reexport safe */ _checker__WEBPACK_IMPORTED_MODULE_2__.isNativeFunction; }, |
| 23301 |
/* harmony export */ isNumber: function() { return /* reexport safe */ _checker__WEBPACK_IMPORTED_MODULE_2__.isNumber; }, |
| 23302 |
/* harmony export */ isNumeric: function() { return /* reexport safe */ _checker__WEBPACK_IMPORTED_MODULE_2__.isNumeric; }, |
| 23303 |
/* harmony export */ isPlainObject: function() { return /* reexport safe */ _checker__WEBPACK_IMPORTED_MODULE_2__.isPlainObject; }, |
| 23304 |
/* harmony export */ isPromise: function() { return /* reexport safe */ _checker__WEBPACK_IMPORTED_MODULE_2__.isPromise; }, |
| 23305 |
/* harmony export */ isSet: function() { return /* reexport safe */ _checker__WEBPACK_IMPORTED_MODULE_2__.isSet; }, |
| 23306 |
/* harmony export */ isString: function() { return /* reexport safe */ _checker__WEBPACK_IMPORTED_MODULE_2__.isString; }, |
| 23307 |
/* harmony export */ isStringArray: function() { return /* reexport safe */ _checker__WEBPACK_IMPORTED_MODULE_2__.isStringArray; }, |
| 23308 |
/* harmony export */ isURL: function() { return /* reexport safe */ _checker__WEBPACK_IMPORTED_MODULE_2__.isURL; }, |
| 23309 |
/* harmony export */ isValidName: function() { return /* reexport safe */ _checker__WEBPACK_IMPORTED_MODULE_2__.isValidName; }, |
| 23310 |
/* harmony export */ isViewObject: function() { return /* reexport safe */ _checker__WEBPACK_IMPORTED_MODULE_2__.isViewObject; }, |
| 23311 |
/* harmony export */ isVoid: function() { return /* reexport safe */ _checker__WEBPACK_IMPORTED_MODULE_2__.isVoid; }, |
| 23312 |
/* harmony export */ isWindow: function() { return /* reexport safe */ _checker__WEBPACK_IMPORTED_MODULE_2__.isWindow; }, |
| 23313 |
/* harmony export */ kebabCase: function() { return /* reexport safe */ _string__WEBPACK_IMPORTED_MODULE_7__.kebabCase; }, |
| 23314 |
/* harmony export */ nl2br: function() { return /* reexport safe */ _html__WEBPACK_IMPORTED_MODULE_4__.nl2br; }, |
| 23315 |
/* harmony export */ normalizeColor: function() { return /* reexport safe */ _normalize__WEBPACK_IMPORTED_MODULE_5__.normalizeColor; }, |
| 23316 |
/* harmony export */ normalizeCssNumericValue: function() { return /* reexport safe */ _normalize__WEBPACK_IMPORTED_MODULE_5__.normalizeCssNumericValue; }, |
| 23317 |
/* harmony export */ normalizeCssValue: function() { return /* reexport safe */ _normalize__WEBPACK_IMPORTED_MODULE_5__.normalizeCssValue; }, |
| 23318 |
/* harmony export */ normalizeKeyAliases: function() { return /* reexport safe */ _normalize__WEBPACK_IMPORTED_MODULE_5__.normalizeKeyAliases; }, |
| 23319 |
/* harmony export */ normalizeLicense: function() { return /* reexport safe */ _normalize__WEBPACK_IMPORTED_MODULE_5__.normalizeLicense; }, |
| 23320 |
/* harmony export */ normalizePath: function() { return /* reexport safe */ _normalize__WEBPACK_IMPORTED_MODULE_5__.normalizePath; }, |
| 23321 |
/* harmony export */ normalizeRelativePath: function() { return /* reexport safe */ _normalize__WEBPACK_IMPORTED_MODULE_5__.normalizeRelativePath; }, |
| 23322 |
/* harmony export */ normalizeSize: function() { return /* reexport safe */ _normalize__WEBPACK_IMPORTED_MODULE_5__.normalizeSize; }, |
| 23323 |
/* harmony export */ normalizeUrl: function() { return /* reexport safe */ _normalize__WEBPACK_IMPORTED_MODULE_5__.normalizeUrl; }, |
| 23324 |
/* harmony export */ offset: function() { return /* reexport safe */ _size__WEBPACK_IMPORTED_MODULE_6__.offset; }, |
| 23325 |
/* harmony export */ position: function() { return /* reexport safe */ _size__WEBPACK_IMPORTED_MODULE_6__.position; }, |
| 23326 |
/* harmony export */ safeHTML: function() { return /* reexport safe */ _html__WEBPACK_IMPORTED_MODULE_4__.safeHTML; }, |
| 23327 |
/* harmony export */ sanitizeHTMLElement: function() { return /* reexport safe */ _html__WEBPACK_IMPORTED_MODULE_4__.sanitizeHTMLElement; }, |
| 23328 |
/* harmony export */ setTimeout: function() { return /* reexport safe */ _async__WEBPACK_IMPORTED_MODULE_1__.setTimeout; }, |
| 23329 |
/* harmony export */ size: function() { return /* reexport safe */ _size__WEBPACK_IMPORTED_MODULE_6__.size; }, |
| 23330 |
/* harmony export */ splitArray: function() { return /* reexport safe */ _array__WEBPACK_IMPORTED_MODULE_0__.splitArray; }, |
| 23331 |
/* harmony export */ sprintf: function() { return /* reexport safe */ _string__WEBPACK_IMPORTED_MODULE_7__.sprintf; }, |
| 23332 |
/* harmony export */ stringify: function() { return /* reexport safe */ _string__WEBPACK_IMPORTED_MODULE_7__.stringify; }, |
| 23333 |
/* harmony export */ stripTags: function() { return /* reexport safe */ _html__WEBPACK_IMPORTED_MODULE_4__.stripTags; }, |
| 23334 |
/* harmony export */ toArray: function() { return /* reexport safe */ _array__WEBPACK_IMPORTED_MODULE_0__.toArray; }, |
| 23335 |
/* harmony export */ trim: function() { return /* reexport safe */ _string__WEBPACK_IMPORTED_MODULE_7__.trim; }, |
| 23336 |
/* harmony export */ trimChars: function() { return /* reexport safe */ _string__WEBPACK_IMPORTED_MODULE_7__.trimChars; }, |
| 23337 |
/* harmony export */ trimInv: function() { return /* reexport safe */ _string__WEBPACK_IMPORTED_MODULE_7__.trimInv; }, |
| 23338 |
/* harmony export */ ucfirst: function() { return /* reexport safe */ _string__WEBPACK_IMPORTED_MODULE_7__.ucfirst; } |
| 23339 |
/* harmony export */ }); |
| 23340 |
/* harmony import */ var _array__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(45664); |
| 23341 |
/* harmony import */ var _async__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(61077); |
| 23342 |
/* harmony import */ var _checker__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(28686); |
| 23343 |
/* harmony import */ var _color__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(7018); |
| 23344 |
/* harmony import */ var _html__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(82658); |
| 23345 |
/* harmony import */ var _normalize__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(97022); |
| 23346 |
/* harmony import */ var _size__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(86878); |
| 23347 |
/* harmony import */ var _string__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(97642); |
| 23348 |
/* harmony import */ var _utils__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(93640); |
| 23349 |
/* harmony reexport (unknown) */ var __WEBPACK_REEXPORT_OBJECT__ = {}; |
| 23350 |
/* harmony reexport (unknown) */ for(var __WEBPACK_IMPORT_KEY__ in _utils__WEBPACK_IMPORTED_MODULE_8__) if(["default","asArray","splitArray","toArray","clearTimeout","setTimeout","hasBrowserColorPicker","hasContainer","isAbortError","isArray","isBoolean","isDestructable","isEqual","isFastEqual","isFunction","isHTML","isHtmlFromWord","isInitable","isInt","isJoditObject","isLicense","isMarker","isNativeFunction","isNumber","isNumeric","isPlainObject","isPromise","isSet","isString","isStringArray","isURL","isValidName","isViewObject","isVoid","isWindow","colorToHex","applyStyles","cleanFromWord","htmlspecialchars","nl2br","safeHTML","sanitizeHTMLElement","stripTags","NUMBER_FIELDS_REG","normalizeColor","normalizeCssNumericValue","normalizeCssValue","normalizeKeyAliases","normalizeLicense","normalizePath","normalizeRelativePath","normalizeSize","normalizeUrl","getContentWidth","getScrollParent","innerWidth","offset","position","size","CamelCaseToKebabCase","camelCase","fuzzySearchIndex","i18n","kebabCase","sprintf","stringify","trim","trimChars","trimInv","ucfirst"].indexOf(__WEBPACK_IMPORT_KEY__) < 0) __WEBPACK_REEXPORT_OBJECT__[__WEBPACK_IMPORT_KEY__] = function(key) { return _utils__WEBPACK_IMPORTED_MODULE_8__[key]; }.bind(0, __WEBPACK_IMPORT_KEY__) |
| 23351 |
/* harmony reexport (unknown) */ __webpack_require__.d(__webpack_exports__, __WEBPACK_REEXPORT_OBJECT__); |
| 23352 |
/*! |
| 23353 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 23354 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 23355 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 23356 |
*/ /** |
| 23357 |
* [[include:core/helpers/README.md]] |
| 23358 |
* @packageDocumentation |
| 23359 |
* @module helpers |
| 23360 |
*/ |
| 23361 |
|
| 23362 |
|
| 23363 |
|
| 23364 |
|
| 23365 |
|
| 23366 |
|
| 23367 |
|
| 23368 |
|
| 23369 |
|
| 23370 |
|
| 23371 |
/***/ }), |
| 23372 |
|
| 23373 |
/***/ 66206: |
| 23374 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 23375 |
|
| 23376 |
"use strict"; |
| 23377 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 23378 |
/* harmony export */ elementToItem: function() { return /* binding */ elementToItem; }, |
| 23379 |
/* harmony export */ getItem: function() { return /* binding */ getItem; } |
| 23380 |
/* harmony export */ }); |
| 23381 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 23382 |
/*! |
| 23383 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 23384 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 23385 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 23386 |
*/ /** |
| 23387 |
* @module modules/file-browser |
| 23388 |
*/ |
| 23389 |
/** |
| 23390 |
* @private |
| 23391 |
*/ const getItem = (node, root, tag = 'a')=>jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(node, (elm)=>jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(elm, tag), root); |
| 23392 |
/** |
| 23393 |
* @private |
| 23394 |
*/ const elementToItem = (elm, elementsMap)=>{ |
| 23395 |
const { key } = elm.dataset, { item } = elementsMap[key || '']; |
| 23396 |
return item; |
| 23397 |
}; |
| 23398 |
|
| 23399 |
|
| 23400 |
/***/ }), |
| 23401 |
|
| 23402 |
/***/ 66547: |
| 23403 |
/***/ (function(module) { |
| 23404 |
|
| 23405 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M896 960v448q0 26-19 45t-45 19-45-19l-144-144-332 332q-10 10-23 10t-23-10l-114-114q-10-10-10-23t10-23l332-332-144-144q-19-19-19-45t19-45 45-19h448q26 0 45 19t19 45zm755-672q0 13-10 23l-332 332 144 144q19 19 19 45t-19 45-45 19h-448q-26 0-45-19t-19-45v-448q0-26 19-45t45-19 45 19l144 144 332-332q10-10 23-10t23 10l114 114q10 10 10 23z\"/> </svg>" |
| 23406 |
|
| 23407 |
/***/ }), |
| 23408 |
|
| 23409 |
/***/ 66568: |
| 23410 |
/***/ (function(module) { |
| 23411 |
|
| 23412 |
/*! |
| 23413 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 23414 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 23415 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 23416 |
*/ module.exports = { |
| 23417 |
'copy-format': 'Copia il formato' |
| 23418 |
}; |
| 23419 |
|
| 23420 |
|
| 23421 |
/***/ }), |
| 23422 |
|
| 23423 |
/***/ 66862: |
| 23424 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 23425 |
|
| 23426 |
"use strict"; |
| 23427 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 23428 |
/* harmony export */ hasPreviousBlock: function() { return /* binding */ hasPreviousBlock; } |
| 23429 |
/* harmony export */ }); |
| 23430 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 23431 |
/*! |
| 23432 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 23433 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 23434 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 23435 |
*/ /** |
| 23436 |
* @module plugins/enter |
| 23437 |
*/ |
| 23438 |
/** |
| 23439 |
* @private |
| 23440 |
*/ function hasPreviousBlock(fake, jodit) { |
| 23441 |
return Boolean(jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.prev(fake, (elm)=>jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isBlock(elm) || jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isImage(elm), jodit.editor)); |
| 23442 |
} |
| 23443 |
|
| 23444 |
|
| 23445 |
/***/ }), |
| 23446 |
|
| 23447 |
/***/ 67176: |
| 23448 |
/***/ (function(module) { |
| 23449 |
|
| 23450 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M352 832q0 14-9 23l-288 288q-9 9-23 9-13 0-22.5-9.5t-9.5-22.5v-576q0-13 9.5-22.5t22.5-9.5q14 0 23 9l288 288q9 9 9 23zm1440 480v192q0 13-9.5 22.5t-22.5 9.5h-1728q-13 0-22.5-9.5t-9.5-22.5v-192q0-13 9.5-22.5t22.5-9.5h1728q13 0 22.5 9.5t9.5 22.5zm0-384v192q0 13-9.5 22.5t-22.5 9.5h-1088q-13 0-22.5-9.5t-9.5-22.5v-192q0-13 9.5-22.5t22.5-9.5h1088q13 0 22.5 9.5t9.5 22.5zm0-384v192q0 13-9.5 22.5t-22.5 9.5h-1088q-13 0-22.5-9.5t-9.5-22.5v-192q0-13 9.5-22.5t22.5-9.5h1088q13 0 22.5 9.5t9.5 22.5zm0-384v192q0 13-9.5 22.5t-22.5 9.5h-1728q-13 0-22.5-9.5t-9.5-22.5v-192q0-13 9.5-22.5t22.5-9.5h1728q13 0 22.5 9.5t9.5 22.5z\"/> </svg>" |
| 23451 |
|
| 23452 |
/***/ }), |
| 23453 |
|
| 23454 |
/***/ 67399: |
| 23455 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 23456 |
|
| 23457 |
"use strict"; |
| 23458 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 23459 |
/* harmony export */ ContextMenu: function() { return /* binding */ ContextMenu; } |
| 23460 |
/* harmony export */ }); |
| 23461 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(31635); |
| 23462 |
/* harmony import */ var jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(91672); |
| 23463 |
/* harmony import */ var jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(17312); |
| 23464 |
/* harmony import */ var jodit_core_ui_button_button_button__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(53681); |
| 23465 |
/* harmony import */ var jodit_core_ui_popup_popup__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(51116); |
| 23466 |
/*! |
| 23467 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 23468 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 23469 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 23470 |
*/ /** |
| 23471 |
* [[include:modules/context-menu/README.md]] |
| 23472 |
* @packageDocumentation |
| 23473 |
* @module modules/context-menu |
| 23474 |
*/ |
| 23475 |
|
| 23476 |
|
| 23477 |
|
| 23478 |
|
| 23479 |
|
| 23480 |
class ContextMenu extends jodit_core_ui_popup_popup__WEBPACK_IMPORTED_MODULE_4__.Popup { |
| 23481 |
/** @override */ className() { |
| 23482 |
return 'ContextMenu'; |
| 23483 |
} |
| 23484 |
/** |
| 23485 |
* Generate and show context menu |
| 23486 |
* |
| 23487 |
* @param x - Global coordinate by X |
| 23488 |
* @param y - Global coordinate by Y |
| 23489 |
* @param actions - Array with plain objects `{icon: 'bin', title: 'Delete', exec: function () {}}` |
| 23490 |
* @example |
| 23491 |
* ```javascript |
| 23492 |
* parent.show(e.clientX, e.clientY, [{icon: 'bin', title: 'Delete', exec: function () { alert(1) }}]); |
| 23493 |
* ``` |
| 23494 |
*/ show(x, y, actions) { |
| 23495 |
const self = this; |
| 23496 |
self.clear(); |
| 23497 |
if (!(0,jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_2__.isArray)(actions)) { |
| 23498 |
return; |
| 23499 |
} |
| 23500 |
actions.forEach((item)=>{ |
| 23501 |
if (!item) { |
| 23502 |
return; |
| 23503 |
} |
| 23504 |
const action = (0,jodit_core_ui_button_button_button__WEBPACK_IMPORTED_MODULE_3__.Button)(this.jodit, item.icon || 'empty', item.title); |
| 23505 |
this.jodit && action.setParentView(this.jodit); |
| 23506 |
action.setMod('context', 'menu'); |
| 23507 |
action.onAction((e)=>{ |
| 23508 |
var _item_exec; |
| 23509 |
(_item_exec = item.exec) === null || _item_exec === void 0 ? void 0 : _item_exec.call(self, e); |
| 23510 |
self.clear(); |
| 23511 |
self.close(); |
| 23512 |
return false; |
| 23513 |
}); |
| 23514 |
this.append(action); |
| 23515 |
}); |
| 23516 |
this.open(()=>({ |
| 23517 |
left: x, |
| 23518 |
top: y, |
| 23519 |
width: 0, |
| 23520 |
height: 0 |
| 23521 |
}), true); |
| 23522 |
} |
| 23523 |
} |
| 23524 |
ContextMenu = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_0__.__decorate)([ |
| 23525 |
jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_1__.component |
| 23526 |
], ContextMenu); |
| 23527 |
|
| 23528 |
|
| 23529 |
/***/ }), |
| 23530 |
|
| 23531 |
/***/ 67447: |
| 23532 |
/***/ (function(module) { |
| 23533 |
|
| 23534 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M576 1376v-192q0-14-9-23t-23-9h-320q-14 0-23 9t-9 23v192q0 14 9 23t23 9h320q14 0 23-9t9-23zm0-384v-192q0-14-9-23t-23-9h-320q-14 0-23 9t-9 23v192q0 14 9 23t23 9h320q14 0 23-9t9-23zm512 384v-192q0-14-9-23t-23-9h-320q-14 0-23 9t-9 23v192q0 14 9 23t23 9h320q14 0 23-9t9-23zm-512-768v-192q0-14-9-23t-23-9h-320q-14 0-23 9t-9 23v192q0 14 9 23t23 9h320q14 0 23-9t9-23zm512 384v-192q0-14-9-23t-23-9h-320q-14 0-23 9t-9 23v192q0 14 9 23t23 9h320q14 0 23-9t9-23zm512 384v-192q0-14-9-23t-23-9h-320q-14 0-23 9t-9 23v192q0 14 9 23t23 9h320q14 0 23-9t9-23zm-512-768v-192q0-14-9-23t-23-9h-320q-14 0-23 9t-9 23v192q0 14 9 23t23 9h320q14 0 23-9t9-23zm512 384v-192q0-14-9-23t-23-9h-320q-14 0-23 9t-9 23v192q0 14 9 23t23 9h320q14 0 23-9t9-23zm0-384v-192q0-14-9-23t-23-9h-320q-14 0-23 9t-9 23v192q0 14 9 23t23 9h320q14 0 23-9t9-23zm128-320v1088q0 66-47 113t-113 47h-1344q-66 0-113-47t-47-113v-1088q0-66 47-113t113-47h1344q66 0 113 47t47 113z\"/> </svg>" |
| 23535 |
|
| 23536 |
/***/ }), |
| 23537 |
|
| 23538 |
/***/ 68294: |
| 23539 |
/***/ (function(module) { |
| 23540 |
|
| 23541 |
/*! |
| 23542 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 23543 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 23544 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 23545 |
*/ module.exports = { |
| 23546 |
symbols: 'Simbolo' |
| 23547 |
}; |
| 23548 |
|
| 23549 |
|
| 23550 |
/***/ }), |
| 23551 |
|
| 23552 |
/***/ 68368: |
| 23553 |
/***/ (function(module) { |
| 23554 |
|
| 23555 |
module.exports["default"] = ["Bir şeyler yaz","Jodit Hakkında","Jodit Editor","Jodit Kullanım Kılavuzu","kullanım için detaylı bilgiler içerir","Lisans hakkında bilgi için lütfen web sitemize gidin:","Tam versiyonunu satın al","Copyright © XDSoft.net - Chupurnov Valeriy. Tüm hakları saklıdır.","Bağlantı","Yeni sekmede aç","Editörü tam ekranda aç","Stili temizle","Renk doldur veya yazı rengi seç","Yinele","Geri Al","Kalın","İtalik","Sırasız Liste Ekle","Sıralı Liste Ekle","Ortala","Kenarlara Yasla","Sola Yasla","Sağa Yasla","Yatay Çizgi Ekle","Resim Ekle","Dosya Ekle","Youtube/Vimeo Videosu Ekle","Bağlantı Ekle","Font Boyutu","Font Ailesi","Blok Ekle","Normal","Başlık 1","Başlık 2","Başlık 3","Başlık 4","Alıntı","Kod","Ekle","Tablo Ekle","Girintiyi Azalt","Girintiyi Arttır","Özel Karakter Seç","Özel Karakter Ekle","Resim Biçimi","Mod Değiştir","Boşluklar","Üst","Sağ","Alt","Sol","CSS Stilleri","CSS Sınıfları","Hizalama","Sağ","Ortalı","Sol","Belirsiz","Kaynak","Başlık","Alternatif Yazı","Link","Bağlantıyı yeni sekmede aç","Resim","Dosya","Gelişmiş","Resim özellikleri","İptal","Tamam","Dosya Listeleyici","Liste yüklenirken hata oluştu","Klasörler yüklenirken hata oluştur","Emin misiniz?","Dizin yolu giriniz","Dizin oluştur","İsim yaz","Resim bırak","Dosya bırak","veya tıkla","Alternatif yazı","Yükle","Gözat","Arka plan","Yazı","Üst","Orta","Aşağı","Öncesine kolon ekle","Sonrasına kolon ekle","Üstüne satır ekle","Altına satır ekle","Tabloyu sil","Satırı sil","Kolonu sil","Hücreyi temizle","Harfler: %d","Kelimeler: %d","Üstü çizili","Alt çizgi","Üst yazı","Alt yazı","Seçilimi kes","Tümünü seç","Satır sonu","Ara","Şununla değiştir","Değiştir","Yapıştır","Yapıştırılacak içerik seç","Kaynak","Kalın","italik","Fırça","Bağlantı","Geri al","Yinele","Tablo","Resim","Silgi","Paragraf","Font boyutu","Video","Font","Hakkında","Yazdır","Alt çizgi","Üstü çizili","Girinti","Çıkıntı","Tam ekran","Küçült","Ayraç","Sırasız liste","Sıralı liste","Kes","Tümünü seç","Kod ekle","Bağlantıyı aç","Bağlantıyı düzenle","Nofollow özelliği","Bağlantıyı kaldır","Güncelle","Düzenlemek için","Yorumu","URL","Düzenle","Yatay hizala","Filtre","Değişime göre sırala","İsme göre sırala","Boyuta göre sırala","Klasör ekle","Sıfırla","Kaydet","Farklı kaydet","Boyutlandır","Kırp","Genişlik","Yükseklik","En boy oranını koru","Evet","Hayır","Sil","Seç","Seç: %s","Dikey hizala","Ayır","Birleştir","Kolon ekle","Satır ekle","Lisans: %s","Sil","Dikey ayır","Yatay ayır","Kenarlık","Kodunuz HTML koduna benziyor. HTML olarak devam etmek ister misiniz?","HTML olarak yapıştır","Sakla","Yazı olarak ekle","Sadece yazıyı ekle","Sadece kendi resimlerinizi düzenleyebilirsiniz. Bu görseli kendi hostunuza indirmek ister misiniz?","Görsel başarıyla hostunuza yüklendi","Palet","Bu dizinde dosya yok","Yeniden isimlendir","Yeni isim girin","Ön izleme","İndir","Panodan yapıştır ","Tarayıcınız panoya doğrudan erişimi desteklemiyor.","Seçimi kopyala","Kopyala","Sınır yarıçapı","Tümünü Göster","Uygula","Lütfen bu alanı doldurun","Lütfen bir web adresi girin","Varsayılan","Daire","Nokta","Kare","Bul","Öncekini Bul","Sonrakini Bul","Der Inhalt, den Sie einfügen, stammt aus einem Microsoft Word / Excel-Dokument. Möchten Sie das Format erhalten oder löschen?","Word biçiminde yapıştırma algılandı","Temizle","Sınıf adı girin","Özel yeniden boyutlandırma için Alt tuşuna basın",null,null,null,"Tümü"] |
| 23556 |
|
| 23557 |
/***/ }), |
| 23558 |
|
| 23559 |
/***/ 68502: |
| 23560 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 23561 |
|
| 23562 |
"use strict"; |
| 23563 |
/* harmony import */ var _swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(41411); |
| 23564 |
/* harmony import */ var _swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(15366); |
| 23565 |
/* harmony import */ var jodit_core_request_config__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(37102); |
| 23566 |
/* harmony import */ var jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(28686); |
| 23567 |
/* harmony import */ var jodit_core_helpers_utils_human_size_to_bytes__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(37427); |
| 23568 |
/* harmony import */ var jodit_core_ui_form_inputs_file_file__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(75587); |
| 23569 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(5266); |
| 23570 |
/*! |
| 23571 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 23572 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 23573 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 23574 |
*/ /** |
| 23575 |
* @module modules/file-browser |
| 23576 |
*/ |
| 23577 |
|
| 23578 |
|
| 23579 |
|
| 23580 |
|
| 23581 |
|
| 23582 |
|
| 23583 |
jodit_config__WEBPACK_IMPORTED_MODULE_6__.Config.prototype.filebrowser = { |
| 23584 |
namespace: '', |
| 23585 |
cache: true, |
| 23586 |
extraButtons: [], |
| 23587 |
filter (item, search) { |
| 23588 |
search = search.toLowerCase(); |
| 23589 |
if ((0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_3__.isString)(item)) { |
| 23590 |
return item.toLowerCase().indexOf(search) !== -1; |
| 23591 |
} |
| 23592 |
if ((0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_3__.isString)(item.name)) { |
| 23593 |
return item.name.toLowerCase().indexOf(search) !== -1; |
| 23594 |
} |
| 23595 |
if ((0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_3__.isString)(item.file)) { |
| 23596 |
return item.file.toLowerCase().indexOf(search) !== -1; |
| 23597 |
} |
| 23598 |
return true; |
| 23599 |
}, |
| 23600 |
sortBy: 'changed-desc', |
| 23601 |
sort (a, b, sortBy) { |
| 23602 |
const [sortAttr, arrow] = sortBy.toLowerCase().split('-'), asc = arrow === 'asc'; |
| 23603 |
const compareStr = (f, s)=>{ |
| 23604 |
if (f < s) { |
| 23605 |
return asc ? -1 : 1; |
| 23606 |
} |
| 23607 |
if (f > s) { |
| 23608 |
return asc ? 1 : -1; |
| 23609 |
} |
| 23610 |
return 0; |
| 23611 |
}; |
| 23612 |
if ((0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_3__.isString)(a)) { |
| 23613 |
return compareStr(a.toLowerCase(), b.toLowerCase()); |
| 23614 |
} |
| 23615 |
if (a[sortAttr] === undefined || sortAttr === 'name') { |
| 23616 |
if ((0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_3__.isString)(a.name)) { |
| 23617 |
return compareStr(a.name.toLowerCase(), b.name.toLowerCase()); |
| 23618 |
} |
| 23619 |
if ((0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_3__.isString)(a.file)) { |
| 23620 |
return compareStr(a.file.toLowerCase(), b.file.toLowerCase()); |
| 23621 |
} |
| 23622 |
return 0; |
| 23623 |
} |
| 23624 |
switch(sortAttr){ |
| 23625 |
case 'changed': |
| 23626 |
{ |
| 23627 |
const f = new Date(a.changed).getTime(), s = new Date(b.changed).getTime(); |
| 23628 |
return asc ? f - s : s - f; |
| 23629 |
} |
| 23630 |
case 'size': |
| 23631 |
{ |
| 23632 |
const f = (0,jodit_core_helpers_utils_human_size_to_bytes__WEBPACK_IMPORTED_MODULE_4__.humanSizeToBytes)(a.size), s = (0,jodit_core_helpers_utils_human_size_to_bytes__WEBPACK_IMPORTED_MODULE_4__.humanSizeToBytes)(b.size); |
| 23633 |
return asc ? f - s : s - f; |
| 23634 |
} |
| 23635 |
} |
| 23636 |
return 0; |
| 23637 |
}, |
| 23638 |
editImage: true, |
| 23639 |
preview: true, |
| 23640 |
showPreviewNavigation: true, |
| 23641 |
showSelectButtonInPreview: true, |
| 23642 |
contextMenu: true, |
| 23643 |
howLongShowMsg: 3000, |
| 23644 |
createNewFolder: true, |
| 23645 |
deleteFolder: true, |
| 23646 |
renameFolder: true, |
| 23647 |
moveFolder: true, |
| 23648 |
moveFile: true, |
| 23649 |
permissionsPresets: { |
| 23650 |
allowFileDownload: undefined, |
| 23651 |
allowFileMove: undefined, |
| 23652 |
allowFileRemove: undefined, |
| 23653 |
allowFileRename: undefined, |
| 23654 |
allowFileUpload: undefined, |
| 23655 |
allowFileUploadRemote: undefined, |
| 23656 |
allowFiles: undefined, |
| 23657 |
allowFolderCreate: undefined, |
| 23658 |
allowFolderMove: undefined, |
| 23659 |
allowFolderRemove: undefined, |
| 23660 |
allowFolderRename: undefined, |
| 23661 |
allowFolderTree: undefined, |
| 23662 |
allowFolders: undefined, |
| 23663 |
allowGeneratePdf: undefined, |
| 23664 |
allowImageCrop: undefined, |
| 23665 |
allowImageResize: undefined |
| 23666 |
}, |
| 23667 |
showFoldersPanel: true, |
| 23668 |
storeLastOpenedFolder: true, |
| 23669 |
width: 859, |
| 23670 |
height: 400, |
| 23671 |
buttons: [ |
| 23672 |
'filebrowser.upload', |
| 23673 |
'filebrowser.remove', |
| 23674 |
'filebrowser.update', |
| 23675 |
'filebrowser.select', |
| 23676 |
'filebrowser.edit', |
| 23677 |
'|', |
| 23678 |
'filebrowser.tiles', |
| 23679 |
'filebrowser.list', |
| 23680 |
'|', |
| 23681 |
'filebrowser.filter', |
| 23682 |
'|', |
| 23683 |
'filebrowser.sort' |
| 23684 |
], |
| 23685 |
removeButtons: [], |
| 23686 |
fullsize: false, |
| 23687 |
showTooltip: true, |
| 23688 |
view: null, |
| 23689 |
isSuccess (resp) { |
| 23690 |
return resp.success; |
| 23691 |
}, |
| 23692 |
getMessage (resp) { |
| 23693 |
return resp.data.messages !== undefined && (0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_3__.isArray)(resp.data.messages) ? resp.data.messages.join(' ') : ''; |
| 23694 |
}, |
| 23695 |
showFileName: true, |
| 23696 |
showFileSize: true, |
| 23697 |
showFileChangeTime: true, |
| 23698 |
saveStateInStorage: { |
| 23699 |
storeLastOpenedFolder: true, |
| 23700 |
storeView: true, |
| 23701 |
storeSortBy: true |
| 23702 |
}, |
| 23703 |
pixelOffsetLoadNewChunk: 200, |
| 23704 |
getThumbTemplate (item, source, source_name) { |
| 23705 |
const opt = this.options, IC = this.files.getFullElName('item'), showName = opt.showFileName, showSize = opt.showFileSize && item.size, showTime = opt.showFileChangeTime && item.time; |
| 23706 |
let name = ''; |
| 23707 |
if (item.file !== undefined) { |
| 23708 |
name = item.file; |
| 23709 |
} |
| 23710 |
const info = `<div class="${IC}-info">${showName ? `<span class="${IC}-info-filename">${name}</span>` : ''}${showSize ? `<span class="${IC}-info-filesize">${item.size}</span>` : ''}${showTime ? `<span class="${IC}-info-filechanged">${showTime}</span>` : ''}</div>`; |
| 23711 |
return `<a |
| 23712 |
data-jodit-file-browser-item="true" |
| 23713 |
data-is-file="${item.isImage ? 0 : 1}" |
| 23714 |
draggable="true" |
| 23715 |
class="${IC}" |
| 23716 |
href="${item.fileURL}" |
| 23717 |
data-source="${source_name}" |
| 23718 |
data-path="${item.path}" |
| 23719 |
data-name="${name}" |
| 23720 |
title="${name}" |
| 23721 |
data-url="${item.fileURL}"> |
| 23722 |
<img |
| 23723 |
data-is-file="${item.isImage ? 0 : 1}" |
| 23724 |
data-src="${item.fileURL}" |
| 23725 |
src="${item.imageURL}" |
| 23726 |
alt="${name}" |
| 23727 |
loading="lazy" |
| 23728 |
/> |
| 23729 |
${showName || showSize || showTime ? info : ''} |
| 23730 |
</a>`; |
| 23731 |
}, |
| 23732 |
ajax: (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_1__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__._)({}, jodit_config__WEBPACK_IMPORTED_MODULE_6__.Config.prototype.defaultAjaxOptions), { |
| 23733 |
url: '', |
| 23734 |
data: {}, |
| 23735 |
cache: true, |
| 23736 |
contentType: 'application/x-www-form-urlencoded; charset=UTF-8', |
| 23737 |
method: 'POST', |
| 23738 |
processData: true, |
| 23739 |
headers: {}, |
| 23740 |
prepareData (data) { |
| 23741 |
return data; |
| 23742 |
}, |
| 23743 |
process (resp) { |
| 23744 |
return resp; |
| 23745 |
} |
| 23746 |
}), |
| 23747 |
create: { |
| 23748 |
data: { |
| 23749 |
action: 'folderCreate' |
| 23750 |
} |
| 23751 |
}, |
| 23752 |
getLocalFileByUrl: { |
| 23753 |
data: { |
| 23754 |
action: 'getLocalFileByUrl' |
| 23755 |
} |
| 23756 |
}, |
| 23757 |
resize: { |
| 23758 |
data: { |
| 23759 |
action: 'imageResize' |
| 23760 |
} |
| 23761 |
}, |
| 23762 |
crop: { |
| 23763 |
data: { |
| 23764 |
action: 'imageCrop' |
| 23765 |
} |
| 23766 |
}, |
| 23767 |
fileMove: { |
| 23768 |
data: { |
| 23769 |
action: 'fileMove' |
| 23770 |
} |
| 23771 |
}, |
| 23772 |
folderMove: { |
| 23773 |
data: { |
| 23774 |
action: 'folderMove' |
| 23775 |
} |
| 23776 |
}, |
| 23777 |
fileRename: { |
| 23778 |
data: { |
| 23779 |
action: 'fileRename' |
| 23780 |
} |
| 23781 |
}, |
| 23782 |
folderRename: { |
| 23783 |
data: { |
| 23784 |
action: 'folderRename' |
| 23785 |
} |
| 23786 |
}, |
| 23787 |
fileRemove: { |
| 23788 |
data: { |
| 23789 |
action: 'fileRemove' |
| 23790 |
} |
| 23791 |
}, |
| 23792 |
folderRemove: { |
| 23793 |
data: { |
| 23794 |
action: 'folderRemove' |
| 23795 |
} |
| 23796 |
}, |
| 23797 |
items: { |
| 23798 |
data: { |
| 23799 |
action: 'files' |
| 23800 |
} |
| 23801 |
}, |
| 23802 |
folder: { |
| 23803 |
data: { |
| 23804 |
action: 'folders' |
| 23805 |
} |
| 23806 |
}, |
| 23807 |
permissions: { |
| 23808 |
data: { |
| 23809 |
action: 'permissions' |
| 23810 |
} |
| 23811 |
} |
| 23812 |
}; |
| 23813 |
jodit_config__WEBPACK_IMPORTED_MODULE_6__.Config.prototype.controls.filebrowser = { |
| 23814 |
upload: { |
| 23815 |
icon: 'plus', |
| 23816 |
tooltip: 'Upload file', |
| 23817 |
isInput: true, |
| 23818 |
isDisabled: (browser)=>!browser.dataProvider.canI('FileUpload'), |
| 23819 |
getContent: (filebrowser, btnInt)=>{ |
| 23820 |
const btn = new jodit_core_ui_form_inputs_file_file__WEBPACK_IMPORTED_MODULE_5__.UIFileInput(filebrowser, { |
| 23821 |
tooltip: btnInt.control.tooltip, |
| 23822 |
onlyImages: filebrowser.state.onlyImages |
| 23823 |
}); |
| 23824 |
filebrowser.e.fire('bindUploader.filebrowser', btn.container); |
| 23825 |
return btn.container; |
| 23826 |
} |
| 23827 |
}, |
| 23828 |
remove: { |
| 23829 |
icon: 'bin', |
| 23830 |
tooltip: 'Remove file', |
| 23831 |
isDisabled: (browser)=>{ |
| 23832 |
return !browser.state.activeElements.length || !browser.dataProvider.canI('FileRemove'); |
| 23833 |
}, |
| 23834 |
exec: (editor)=>{ |
| 23835 |
editor.e.fire('fileRemove.filebrowser'); |
| 23836 |
} |
| 23837 |
}, |
| 23838 |
update: { |
| 23839 |
tooltip: 'Update file list', |
| 23840 |
exec: (editor)=>{ |
| 23841 |
editor.e.fire('update.filebrowser'); |
| 23842 |
} |
| 23843 |
}, |
| 23844 |
select: { |
| 23845 |
tooltip: 'Select file', |
| 23846 |
icon: 'check', |
| 23847 |
isDisabled: (browser)=>!browser.state.activeElements.length, |
| 23848 |
exec: (editor)=>{ |
| 23849 |
editor.e.fire('select.filebrowser'); |
| 23850 |
} |
| 23851 |
}, |
| 23852 |
edit: { |
| 23853 |
tooltip: 'Edit image', |
| 23854 |
icon: 'pencil', |
| 23855 |
isDisabled: (browser)=>{ |
| 23856 |
const selected = browser.state.activeElements; |
| 23857 |
return selected.length !== 1 || !selected[0].isImage || !(browser.dataProvider.canI('ImageCrop') || browser.dataProvider.canI('ImageResize')); |
| 23858 |
}, |
| 23859 |
exec: (editor)=>{ |
| 23860 |
editor.e.fire('edit.filebrowser'); |
| 23861 |
} |
| 23862 |
}, |
| 23863 |
tiles: { |
| 23864 |
tooltip: 'Tiles view', |
| 23865 |
icon: 'th', |
| 23866 |
isActive: (filebrowser)=>filebrowser.state.view === 'tiles', |
| 23867 |
exec: (filebrowser)=>{ |
| 23868 |
filebrowser.e.fire('view.filebrowser', 'tiles'); |
| 23869 |
} |
| 23870 |
}, |
| 23871 |
list: { |
| 23872 |
tooltip: 'List view', |
| 23873 |
icon: 'th-list', |
| 23874 |
isActive: (filebrowser)=>filebrowser.state.view === 'list', |
| 23875 |
exec: (filebrowser)=>{ |
| 23876 |
filebrowser.e.fire('view.filebrowser', 'list'); |
| 23877 |
} |
| 23878 |
}, |
| 23879 |
filter: { |
| 23880 |
isInput: true, |
| 23881 |
getContent: (filebrowser, b)=>{ |
| 23882 |
const oldInput = b.container.querySelector('.jodit-input'); |
| 23883 |
if (oldInput) { |
| 23884 |
return oldInput; |
| 23885 |
} |
| 23886 |
const input = filebrowser.c.element('input', { |
| 23887 |
class: 'jodit-input', |
| 23888 |
placeholder: filebrowser.i18n('Filter') |
| 23889 |
}); |
| 23890 |
input.value = filebrowser.state.filterWord; |
| 23891 |
filebrowser.e.on(input, 'keydown mousedown', filebrowser.async.debounce(()=>{ |
| 23892 |
filebrowser.e.fire('filter.filebrowser', input.value); |
| 23893 |
}, filebrowser.defaultTimeout)); |
| 23894 |
return input; |
| 23895 |
} |
| 23896 |
}, |
| 23897 |
sort: { |
| 23898 |
isInput: true, |
| 23899 |
getContent: (fb)=>{ |
| 23900 |
const select = fb.c.fromHTML('<select class="jodit-input jodit-select">' + `<option value="changed-asc">${fb.i18n('Sort by changed')} (⬆)</option>` + `<option value="changed-desc">${fb.i18n('Sort by changed')} (⬇)</option>` + `<option value="name-asc">${fb.i18n('Sort by name')} (⬆)</option>` + `<option value="name-desc">${fb.i18n('Sort by name')} (⬇)</option>` + `<option value="size-asc">${fb.i18n('Sort by size')} (⬆)</option>` + `<option value="size-desc">${fb.i18n('Sort by size')} (⬇)</option>` + '</select>'); |
| 23901 |
select.value = fb.state.sortBy; |
| 23902 |
fb.e.on('sort.filebrowser', (value)=>{ |
| 23903 |
if (select.value !== value) { |
| 23904 |
select.value = value; |
| 23905 |
} |
| 23906 |
}).on(select, 'change', ()=>{ |
| 23907 |
fb.e.fire('sort.filebrowser', select.value); |
| 23908 |
}); |
| 23909 |
return select; |
| 23910 |
} |
| 23911 |
} |
| 23912 |
}; |
| 23913 |
|
| 23914 |
|
| 23915 |
/***/ }), |
| 23916 |
|
| 23917 |
/***/ 68616: |
| 23918 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 23919 |
|
| 23920 |
"use strict"; |
| 23921 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 23922 |
/* harmony export */ watch: function() { return /* binding */ watch; } |
| 23923 |
/* harmony export */ }); |
| 23924 |
/* harmony import */ var jodit_core_component_statuses__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(69364); |
| 23925 |
/* harmony import */ var jodit_core_event_emitter_observable__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(70535); |
| 23926 |
/* harmony import */ var jodit_core_helpers_array_split_array__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(32328); |
| 23927 |
/* harmony import */ var jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(91565); |
| 23928 |
/* harmony import */ var jodit_core_helpers_checker_is_plain_object__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(62101); |
| 23929 |
/* harmony import */ var jodit_core_helpers_checker_is_view_object__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(31534); |
| 23930 |
/* harmony import */ var jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(33201); |
| 23931 |
/* harmony import */ var jodit_core_helpers_utils_utils__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(71125); |
| 23932 |
/*! |
| 23933 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 23934 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 23935 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 23936 |
*/ /** |
| 23937 |
* [[include:core/decorators/watch/README.md]] |
| 23938 |
* @packageDocumentation |
| 23939 |
* @module decorators/watch |
| 23940 |
*/ |
| 23941 |
|
| 23942 |
|
| 23943 |
|
| 23944 |
|
| 23945 |
|
| 23946 |
|
| 23947 |
|
| 23948 |
/** |
| 23949 |
* Watch decorator. Added observer for some change in field value |
| 23950 |
*/ function watch(observeFields, opts) { |
| 23951 |
return (target, propertyKey)=>{ |
| 23952 |
var _ref; |
| 23953 |
if (!(0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_3__.isFunction)(target[propertyKey])) { |
| 23954 |
throw (0,jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_6__.error)('Handler must be a Function'); |
| 23955 |
} |
| 23956 |
const immediately = (_ref = opts === null || opts === void 0 ? void 0 : opts.immediately) !== null && _ref !== void 0 ? _ref : true; |
| 23957 |
const context = opts === null || opts === void 0 ? void 0 : opts.context; |
| 23958 |
const process = (component)=>{ |
| 23959 |
const view = (0,jodit_core_helpers_checker_is_view_object__WEBPACK_IMPORTED_MODULE_5__.isViewObject)(component) ? component : component.jodit; |
| 23960 |
let callback = (key, ...args)=>{ |
| 23961 |
if (component.isInDestruct) { |
| 23962 |
return; |
| 23963 |
} |
| 23964 |
return component[propertyKey](key, ...args); |
| 23965 |
}; |
| 23966 |
if (!immediately) { |
| 23967 |
callback = component.async.microDebounce(callback, true); |
| 23968 |
} |
| 23969 |
(0,jodit_core_helpers_array_split_array__WEBPACK_IMPORTED_MODULE_2__.splitArray)(observeFields).forEach((field)=>{ |
| 23970 |
if (/:/.test(field)) { |
| 23971 |
const [objectPath, eventName] = field.split(':'); |
| 23972 |
let ctx = context; |
| 23973 |
if (objectPath.length) { |
| 23974 |
ctx = component.get(objectPath); |
| 23975 |
} |
| 23976 |
if ((0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_3__.isFunction)(ctx)) { |
| 23977 |
ctx = ctx(component); |
| 23978 |
} |
| 23979 |
view.events.on(ctx || component, eventName, callback); |
| 23980 |
if (!ctx) { |
| 23981 |
view.events.on(eventName, callback); |
| 23982 |
} |
| 23983 |
component.hookStatus('beforeDestruct', ()=>{ |
| 23984 |
view.events.off(ctx || component, eventName, callback).off(eventName, callback); |
| 23985 |
}); |
| 23986 |
return; |
| 23987 |
} |
| 23988 |
const parts = field.split('.'), [key] = parts, teil = parts.slice(1); |
| 23989 |
let value = component[key]; |
| 23990 |
if ((0,jodit_core_helpers_checker_is_plain_object__WEBPACK_IMPORTED_MODULE_4__.isPlainObject)(value)) { |
| 23991 |
const observableValue = (0,jodit_core_event_emitter_observable__WEBPACK_IMPORTED_MODULE_1__.observable)(value); |
| 23992 |
observableValue.on(`change.${teil.join('.')}`, callback); |
| 23993 |
} |
| 23994 |
const descriptor = (0,jodit_core_helpers_utils_utils__WEBPACK_IMPORTED_MODULE_7__.getPropertyDescriptor)(target, key); |
| 23995 |
Object.defineProperty(component, key, { |
| 23996 |
configurable: true, |
| 23997 |
set (v) { |
| 23998 |
const oldValue = value; |
| 23999 |
if (oldValue === v) { |
| 24000 |
return; |
| 24001 |
} |
| 24002 |
value = v; |
| 24003 |
if (descriptor && descriptor.set) { |
| 24004 |
descriptor.set.call(component, v); |
| 24005 |
} |
| 24006 |
if ((0,jodit_core_helpers_checker_is_plain_object__WEBPACK_IMPORTED_MODULE_4__.isPlainObject)(value)) { |
| 24007 |
value = (0,jodit_core_event_emitter_observable__WEBPACK_IMPORTED_MODULE_1__.observable)(value); |
| 24008 |
value.on(`change.${teil.join('.')}`, callback); |
| 24009 |
} |
| 24010 |
callback(key, oldValue, value); |
| 24011 |
}, |
| 24012 |
get () { |
| 24013 |
if (descriptor && descriptor.get) { |
| 24014 |
return descriptor.get.call(component); |
| 24015 |
} |
| 24016 |
return value; |
| 24017 |
} |
| 24018 |
}); |
| 24019 |
}); |
| 24020 |
}; |
| 24021 |
if ((0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_3__.isFunction)(target.hookStatus)) { |
| 24022 |
target.hookStatus(jodit_core_component_statuses__WEBPACK_IMPORTED_MODULE_0__.STATUSES.ready, process); |
| 24023 |
} else { |
| 24024 |
process(target); |
| 24025 |
} |
| 24026 |
}; |
| 24027 |
} |
| 24028 |
|
| 24029 |
|
| 24030 |
/***/ }), |
| 24031 |
|
| 24032 |
/***/ 68624: |
| 24033 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 24034 |
|
| 24035 |
"use strict"; |
| 24036 |
/* unused harmony export link */ |
| 24037 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 24038 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 24039 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(84839); |
| 24040 |
/* harmony import */ var jodit_core_dom__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(27795); |
| 24041 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(28077); |
| 24042 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(65946); |
| 24043 |
/* harmony import */ var jodit_core_plugin__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(91206); |
| 24044 |
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(65230); |
| 24045 |
/*! |
| 24046 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 24047 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 24048 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 24049 |
*/ /** |
| 24050 |
* [[include:plugins/link/README.md]] |
| 24051 |
* @packageDocumentation |
| 24052 |
* @module plugins/link |
| 24053 |
*/ |
| 24054 |
|
| 24055 |
|
| 24056 |
|
| 24057 |
|
| 24058 |
|
| 24059 |
|
| 24060 |
|
| 24061 |
/** |
| 24062 |
* Process link. Insert, dblclick or remove format |
| 24063 |
*/ class link extends jodit_core_plugin__WEBPACK_IMPORTED_MODULE_6__.Plugin { |
| 24064 |
/** @override */ afterInit(jodit) { |
| 24065 |
if (jodit.o.link.followOnDblClick) { |
| 24066 |
jodit.e.on('dblclick.link', this.__onDblClickOnLink); |
| 24067 |
} |
| 24068 |
jodit.e.on(jodit.editor, 'click.link', this.__onClickReadOnlyLink); |
| 24069 |
if (jodit.o.link.processPastedLink) { |
| 24070 |
jodit.e.on('processPaste.link', this.onProcessPasteLink); |
| 24071 |
} |
| 24072 |
jodit.e.on('generateLinkForm.link', this.__generateForm); |
| 24073 |
jodit.registerCommand('openLinkDialog', { |
| 24074 |
exec: ()=>{ |
| 24075 |
const dialog = jodit.dlg({ |
| 24076 |
resizable: false |
| 24077 |
}); |
| 24078 |
const htmlForm = this.__generateForm(jodit.s.current(), ()=>{ |
| 24079 |
dialog.close(); |
| 24080 |
}); |
| 24081 |
htmlForm.container.classList.add('jodit-dialog_alert'); |
| 24082 |
dialog.setContent(htmlForm); |
| 24083 |
dialog.open(); |
| 24084 |
jodit.async.requestIdleCallback(()=>{ |
| 24085 |
const { url_input } = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.refs)(htmlForm.container); |
| 24086 |
url_input === null || url_input === void 0 ? void 0 : url_input.focus(); |
| 24087 |
}); |
| 24088 |
}, |
| 24089 |
hotkeys: jodit.o.link.hotkeys |
| 24090 |
}); |
| 24091 |
} |
| 24092 |
__onDblClickOnLink(e) { |
| 24093 |
if (!jodit_core_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.isTag(e.target, 'a')) { |
| 24094 |
return; |
| 24095 |
} |
| 24096 |
const href = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.attr)(e.target, 'href'); |
| 24097 |
if (href) { |
| 24098 |
location.href = href; |
| 24099 |
e.preventDefault(); |
| 24100 |
} |
| 24101 |
} |
| 24102 |
onProcessPasteLink(ignore, html) { |
| 24103 |
const { jodit } = this; |
| 24104 |
if (!(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.isURL)(html) || !jodit.o.link.processPastedLink) { |
| 24105 |
return; |
| 24106 |
} |
| 24107 |
jodit.e.stopPropagation('processPaste'); |
| 24108 |
if (jodit.o.link.processVideoLink) { |
| 24109 |
var _ref; |
| 24110 |
var _jodit_o_video, _jodit_o_video1, _jodit_o_video2; |
| 24111 |
const embed = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.call)((_ref = (_jodit_o_video = jodit.o.video) === null || _jodit_o_video === void 0 ? void 0 : _jodit_o_video.parseUrlToVideoEmbed) !== null && _ref !== void 0 ? _ref : jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.convertMediaUrlToVideoEmbed, html, { |
| 24112 |
width: (_jodit_o_video1 = jodit.o.video) === null || _jodit_o_video1 === void 0 ? void 0 : _jodit_o_video1.defaultWidth, |
| 24113 |
height: (_jodit_o_video2 = jodit.o.video) === null || _jodit_o_video2 === void 0 ? void 0 : _jodit_o_video2.defaultHeight |
| 24114 |
}); |
| 24115 |
if (embed !== html) { |
| 24116 |
return jodit.createInside.fromHTML(embed); |
| 24117 |
} |
| 24118 |
} |
| 24119 |
if (jodit.s.isCollapsed()) { |
| 24120 |
const a = jodit.createInside.element('a'); |
| 24121 |
a.setAttribute('href', html); |
| 24122 |
a.textContent = html; |
| 24123 |
jodit.e.fire('applyLink', jodit, a, null); |
| 24124 |
return a; |
| 24125 |
} |
| 24126 |
jodit.s.commitStyle({ |
| 24127 |
element: 'a', |
| 24128 |
attributes: { |
| 24129 |
href: html |
| 24130 |
} |
| 24131 |
}); |
| 24132 |
return true; |
| 24133 |
} |
| 24134 |
__generateForm(current, close) { |
| 24135 |
const { jodit } = this; |
| 24136 |
const i18n = jodit.i18n.bind(jodit), { openInNewTabCheckbox, noFollowCheckbox, formTemplate, formClassName, modeClassName } = jodit.o.link; |
| 24137 |
const html = formTemplate(jodit); |
| 24138 |
const form = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.isString)(html) ? jodit.c.fromHTML(html, { |
| 24139 |
target_checkbox_box: openInNewTabCheckbox, |
| 24140 |
nofollow_checkbox_box: noFollowCheckbox |
| 24141 |
}) : html; |
| 24142 |
const htmlForm = jodit_core_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.isElement(form) ? form : form.container; |
| 24143 |
const elements = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.refs)(htmlForm); |
| 24144 |
const { insert, unlink, content_input_box } = elements; |
| 24145 |
const { target_checkbox, nofollow_checkbox, url_input } = elements; |
| 24146 |
const currentElement = current; |
| 24147 |
const isImageContent = jodit_core_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.isImage(currentElement); |
| 24148 |
let { content_input } = elements; |
| 24149 |
const { className_input } = elements, { className_select } = elements; |
| 24150 |
if (!content_input) { |
| 24151 |
content_input = jodit.c.element('input', { |
| 24152 |
type: 'hidden', |
| 24153 |
ref: 'content_input' |
| 24154 |
}); |
| 24155 |
} |
| 24156 |
if (formClassName) { |
| 24157 |
htmlForm.classList.add(formClassName); |
| 24158 |
} |
| 24159 |
if (isImageContent) { |
| 24160 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.hide(content_input_box); |
| 24161 |
} |
| 24162 |
let link; |
| 24163 |
const getSelectionText = ()=>link ? link.innerText : (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.stripTags)(jodit.s.range.cloneContents(), jodit.ed); |
| 24164 |
if (current && jodit_core_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.closest(current, 'a', jodit.editor)) { |
| 24165 |
link = jodit_core_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.closest(current, 'a', jodit.editor); |
| 24166 |
} else { |
| 24167 |
link = false; |
| 24168 |
} |
| 24169 |
if (!isImageContent && current) { |
| 24170 |
content_input.value = getSelectionText(); |
| 24171 |
} |
| 24172 |
if (link) { |
| 24173 |
url_input.value = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.attr)(link, 'href') || ''; |
| 24174 |
if (modeClassName) { |
| 24175 |
readClassnames(modeClassName, className_input, link, className_select); |
| 24176 |
} |
| 24177 |
if (openInNewTabCheckbox && target_checkbox) { |
| 24178 |
target_checkbox.checked = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.attr)(link, 'target') === '_blank'; |
| 24179 |
} |
| 24180 |
if (noFollowCheckbox && nofollow_checkbox) { |
| 24181 |
nofollow_checkbox.checked = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.attr)(link, 'rel') === 'nofollow'; |
| 24182 |
} |
| 24183 |
insert.textContent = i18n('Update'); |
| 24184 |
} else { |
| 24185 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.hide(unlink); |
| 24186 |
} |
| 24187 |
jodit.editor.normalize(); |
| 24188 |
const snapshot = jodit.history.snapshot.make(); |
| 24189 |
if (unlink) { |
| 24190 |
jodit.e.on(unlink, 'click', (e)=>{ |
| 24191 |
jodit.s.restore(); |
| 24192 |
jodit.history.snapshot.restore(snapshot); |
| 24193 |
if (link) { |
| 24194 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.unwrap(link); |
| 24195 |
} |
| 24196 |
jodit.synchronizeValues(); |
| 24197 |
close(); |
| 24198 |
e.preventDefault(); |
| 24199 |
}); |
| 24200 |
} |
| 24201 |
const onSubmit = ()=>{ |
| 24202 |
if (!url_input.value.trim().length) { |
| 24203 |
url_input.focus(); |
| 24204 |
url_input.classList.add('jodit_error'); |
| 24205 |
return false; |
| 24206 |
} |
| 24207 |
let links; |
| 24208 |
jodit.s.restore(); |
| 24209 |
jodit.s.removeMarkers(); |
| 24210 |
jodit.editor.normalize(); |
| 24211 |
jodit.history.snapshot.restore(snapshot); |
| 24212 |
const textWasChanged = getSelectionText() !== content_input.value.trim(); |
| 24213 |
const ci = jodit.createInside; |
| 24214 |
if (!link || !jodit_core_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.isOrContains(jodit.editor, link)) { |
| 24215 |
if (!jodit.s.isCollapsed()) { |
| 24216 |
const node = jodit.s.current(); |
| 24217 |
if (jodit_core_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.isTag(node, 'img')) { |
| 24218 |
links = [ |
| 24219 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.wrap(node, 'a', ci) |
| 24220 |
]; |
| 24221 |
} else { |
| 24222 |
links = jodit.s.wrapInTag('a'); |
| 24223 |
} |
| 24224 |
} else { |
| 24225 |
const a = ci.element('a'); |
| 24226 |
jodit.s.insertNode(a, false, false); |
| 24227 |
links = [ |
| 24228 |
a |
| 24229 |
]; |
| 24230 |
} |
| 24231 |
links.forEach((link)=>jodit.s.select(link)); |
| 24232 |
} else { |
| 24233 |
links = [ |
| 24234 |
link |
| 24235 |
]; |
| 24236 |
} |
| 24237 |
links.forEach((a)=>{ |
| 24238 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.attr)(a, 'href', url_input.value); |
| 24239 |
writeClasses(modeClassName, className_input, className_select, a); |
| 24240 |
if (!isImageContent) { |
| 24241 |
writeImage(a, content_input, textWasChanged, url_input); |
| 24242 |
} |
| 24243 |
if (openInNewTabCheckbox && target_checkbox) { |
| 24244 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.attr)(a, 'target', target_checkbox.checked ? '_blank' : null); |
| 24245 |
} |
| 24246 |
if (noFollowCheckbox && nofollow_checkbox) { |
| 24247 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.attr)(a, 'rel', nofollow_checkbox.checked ? 'nofollow' : null); |
| 24248 |
} |
| 24249 |
jodit.e.fire('applyLink', jodit, a, form); |
| 24250 |
}); |
| 24251 |
jodit.synchronizeValues(); |
| 24252 |
close(); |
| 24253 |
return false; |
| 24254 |
}; |
| 24255 |
if (jodit_core_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.isElement(form)) { |
| 24256 |
jodit.e.on(form, 'submit', (event)=>{ |
| 24257 |
event.preventDefault(); |
| 24258 |
event.stopImmediatePropagation(); |
| 24259 |
onSubmit(); |
| 24260 |
return false; |
| 24261 |
}); |
| 24262 |
} else { |
| 24263 |
form.onSubmit(onSubmit); |
| 24264 |
} |
| 24265 |
return form; |
| 24266 |
} |
| 24267 |
/** @override */ beforeDestruct(jodit) { |
| 24268 |
jodit.e.off('generateLinkForm.link', this.__generateForm).off('dblclick.link', this.__onDblClickOnLink).off(jodit.editor, 'click.link', this.__onClickReadOnlyLink).off('processPaste.link', this.onProcessPasteLink); |
| 24269 |
} |
| 24270 |
__onClickReadOnlyLink(e) { |
| 24271 |
const { jodit } = this; |
| 24272 |
if (jodit.o.readonly && jodit.o.link.preventReadOnlyNavigation && jodit_core_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.isTag(e.target, 'a')) { |
| 24273 |
e.preventDefault(); |
| 24274 |
} |
| 24275 |
} |
| 24276 |
constructor(...args){ |
| 24277 |
super(...args), /** @override */ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "buttons", [ |
| 24278 |
{ |
| 24279 |
name: 'link', |
| 24280 |
group: 'insert' |
| 24281 |
} |
| 24282 |
]); |
| 24283 |
} |
| 24284 |
} |
| 24285 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 24286 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.autobind |
| 24287 |
], link.prototype, "__onDblClickOnLink", null); |
| 24288 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 24289 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.autobind |
| 24290 |
], link.prototype, "onProcessPasteLink", null); |
| 24291 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 24292 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.autobind |
| 24293 |
], link.prototype, "__generateForm", null); |
| 24294 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 24295 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.autobind |
| 24296 |
], link.prototype, "__onClickReadOnlyLink", null); |
| 24297 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_4__.pluginSystem.add('link', link); |
| 24298 |
function writeClasses(modeClassName, className_input, className_select, a) { |
| 24299 |
if (modeClassName && (className_input !== null && className_input !== void 0 ? className_input : className_select)) { |
| 24300 |
if (modeClassName === 'input') { |
| 24301 |
if (className_input.value === '' && a.hasAttribute('class')) { |
| 24302 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.attr)(a, 'class', null); |
| 24303 |
} |
| 24304 |
if (className_input.value !== '') { |
| 24305 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.attr)(a, 'class', className_input.value); |
| 24306 |
} |
| 24307 |
} else if (modeClassName === 'select') { |
| 24308 |
if (a.hasAttribute('class')) { |
| 24309 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.attr)(a, 'class', null); |
| 24310 |
} |
| 24311 |
for(let i = 0; i < className_select.selectedOptions.length; i++){ |
| 24312 |
var _className_select_selectedOptions_item; |
| 24313 |
const className = (_className_select_selectedOptions_item = className_select.selectedOptions.item(i)) === null || _className_select_selectedOptions_item === void 0 ? void 0 : _className_select_selectedOptions_item.value; |
| 24314 |
if (className) { |
| 24315 |
className.split(/\s+/).filter((cn)=>cn.trim().length > 0).forEach((cn)=>{ |
| 24316 |
a.classList.add(cn); |
| 24317 |
}); |
| 24318 |
} |
| 24319 |
} |
| 24320 |
} |
| 24321 |
} |
| 24322 |
} |
| 24323 |
function readClassnames(modeClassName, className_input, link, className_select) { |
| 24324 |
switch(modeClassName){ |
| 24325 |
case 'input': |
| 24326 |
if (className_input) { |
| 24327 |
className_input.value = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.attr)(link, 'class') || ''; |
| 24328 |
} |
| 24329 |
break; |
| 24330 |
case 'select': |
| 24331 |
if (className_select) { |
| 24332 |
for(let i = 0; i < className_select.selectedOptions.length; i++){ |
| 24333 |
const option = className_select.options.item(i); |
| 24334 |
if (option) { |
| 24335 |
option.selected = false; |
| 24336 |
} |
| 24337 |
} |
| 24338 |
const classNames = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.attr)(link, 'class') || ''; |
| 24339 |
classNames.split(/\s+/).filter((cn)=>cn.trim().length > 0).forEach((className)=>{ |
| 24340 |
if (className) { |
| 24341 |
for(let i = 0; i < className_select.options.length; i++){ |
| 24342 |
const option = className_select.options.item(i); |
| 24343 |
if ((option === null || option === void 0 ? void 0 : option.value) && option.value.split(/\s+/).map((cn)=>cn.trim()).includes(className)) { |
| 24344 |
option.selected = true; |
| 24345 |
} |
| 24346 |
} |
| 24347 |
} |
| 24348 |
}); |
| 24349 |
} |
| 24350 |
break; |
| 24351 |
} |
| 24352 |
} |
| 24353 |
function writeImage(a, content_input, textWasChanged, url_input) { |
| 24354 |
let newContent = a.textContent; |
| 24355 |
if (content_input.value.trim().length) { |
| 24356 |
if (textWasChanged) { |
| 24357 |
newContent = content_input.value; |
| 24358 |
} |
| 24359 |
} else { |
| 24360 |
newContent = url_input.value; |
| 24361 |
} |
| 24362 |
const content = a.textContent; |
| 24363 |
if (newContent !== content) { |
| 24364 |
a.textContent = newContent; |
| 24365 |
} |
| 24366 |
} |
| 24367 |
|
| 24368 |
|
| 24369 |
/***/ }), |
| 24370 |
|
| 24371 |
/***/ 68709: |
| 24372 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 24373 |
|
| 24374 |
"use strict"; |
| 24375 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 24376 |
/* harmony export */ checkRemoveContentNotEditable: function() { return /* binding */ checkRemoveContentNotEditable; } |
| 24377 |
/* harmony export */ }); |
| 24378 |
/* harmony import */ var jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(27795); |
| 24379 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(65946); |
| 24380 |
/* harmony import */ var jodit_core_selection_helpers__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(42259); |
| 24381 |
/*! |
| 24382 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 24383 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 24384 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 24385 |
*/ /** |
| 24386 |
* @module plugins/backspace |
| 24387 |
*/ |
| 24388 |
|
| 24389 |
|
| 24390 |
/** |
| 24391 |
* Checks if a non-editable element can be deleted |
| 24392 |
* @private |
| 24393 |
*/ function checkRemoveContentNotEditable(jodit, fakeNode, backspace) { |
| 24394 |
let neighbor = jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.findSibling(fakeNode, backspace); |
| 24395 |
if (!neighbor && fakeNode.parentElement && fakeNode.parentElement !== jodit.editor) { |
| 24396 |
neighbor = jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.findSibling(fakeNode.parentElement, backspace); |
| 24397 |
} |
| 24398 |
if (jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isElement(neighbor) && !jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isContentEditable(neighbor, jodit.editor)) { |
| 24399 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__.call)(backspace ? jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.before : jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.after, neighbor, fakeNode); |
| 24400 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(neighbor); |
| 24401 |
(0,jodit_core_selection_helpers__WEBPACK_IMPORTED_MODULE_2__.moveNodeInsideStart)(jodit, fakeNode, backspace); |
| 24402 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__.call)(backspace ? jodit.s.setCursorBefore : jodit.s.setCursorAfter, fakeNode); |
| 24403 |
return true; |
| 24404 |
} |
| 24405 |
return false; |
| 24406 |
} |
| 24407 |
|
| 24408 |
|
| 24409 |
/***/ }), |
| 24410 |
|
| 24411 |
/***/ 69023: |
| 24412 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 24413 |
|
| 24414 |
"use strict"; |
| 24415 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5266); |
| 24416 |
/*! |
| 24417 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 24418 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 24419 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 24420 |
*/ /** |
| 24421 |
* @module plugins/tab |
| 24422 |
*/ |
| 24423 |
jodit_config__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.tab = { |
| 24424 |
tabInsideLiInsertNewList: true |
| 24425 |
}; |
| 24426 |
|
| 24427 |
|
| 24428 |
/***/ }), |
| 24429 |
|
| 24430 |
/***/ 69070: |
| 24431 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 24432 |
|
| 24433 |
"use strict"; |
| 24434 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5266); |
| 24435 |
/*! |
| 24436 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 24437 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 24438 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 24439 |
*/ /** |
| 24440 |
* @module plugins/select-cells |
| 24441 |
*/ |
| 24442 |
jodit_config__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.tableAllowCellSelection = true; |
| 24443 |
|
| 24444 |
|
| 24445 |
/***/ }), |
| 24446 |
|
| 24447 |
/***/ 69143: |
| 24448 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 24449 |
|
| 24450 |
"use strict"; |
| 24451 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 24452 |
/* harmony export */ offset: function() { return /* binding */ offset; } |
| 24453 |
/* harmony export */ }); |
| 24454 |
/*! |
| 24455 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 24456 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 24457 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 24458 |
*/ /** |
| 24459 |
* @module helpers/size |
| 24460 |
*/ /** |
| 24461 |
* Calc relative offset by start editor field |
| 24462 |
* @returns returns an object containing the properties top and left. |
| 24463 |
*/ const offset = (elm, jodit, doc, recurse = false)=>{ |
| 24464 |
let rect; |
| 24465 |
try { |
| 24466 |
rect = elm.getBoundingClientRect(); |
| 24467 |
} catch (e) { |
| 24468 |
rect = { |
| 24469 |
top: 0, |
| 24470 |
bottom: 0, |
| 24471 |
left: 0, |
| 24472 |
right: 0, |
| 24473 |
width: 0, |
| 24474 |
height: 0 |
| 24475 |
}; |
| 24476 |
} |
| 24477 |
const body = doc.body, docElem = doc.documentElement || { |
| 24478 |
clientTop: 0, |
| 24479 |
clientLeft: 0, |
| 24480 |
scrollTop: 0, |
| 24481 |
scrollLeft: 0 |
| 24482 |
}, win = doc.defaultView || doc.parentWindow, scrollTop = win.pageYOffset || docElem.scrollTop || body.scrollTop, scrollLeft = win.pageXOffset || docElem.scrollLeft || body.scrollLeft, clientTop = docElem.clientTop || body.clientTop || 0, clientLeft = docElem.clientLeft || body.clientLeft || 0; |
| 24483 |
let topValue, leftValue; |
| 24484 |
const iframe = jodit.iframe; |
| 24485 |
if (!recurse && jodit && jodit.options && jodit.o.iframe && iframe) { |
| 24486 |
const { top, left } = offset(iframe, jodit, jodit.od, true); |
| 24487 |
topValue = rect.top + top; |
| 24488 |
leftValue = rect.left + left; |
| 24489 |
} else { |
| 24490 |
topValue = rect.top + scrollTop - clientTop; |
| 24491 |
leftValue = rect.left + scrollLeft - clientLeft; |
| 24492 |
} |
| 24493 |
return { |
| 24494 |
top: Math.round(topValue), |
| 24495 |
left: Math.round(leftValue), |
| 24496 |
width: rect.width, |
| 24497 |
height: rect.height |
| 24498 |
}; |
| 24499 |
}; |
| 24500 |
|
| 24501 |
|
| 24502 |
/***/ }), |
| 24503 |
|
| 24504 |
/***/ 69364: |
| 24505 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 24506 |
|
| 24507 |
"use strict"; |
| 24508 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 24509 |
/* harmony export */ STATUSES: function() { return /* binding */ STATUSES; } |
| 24510 |
/* harmony export */ }); |
| 24511 |
/*! |
| 24512 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 24513 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 24514 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 24515 |
*/ /** |
| 24516 |
* @module component |
| 24517 |
*/ const STATUSES = { |
| 24518 |
beforeInit: 'beforeInit', |
| 24519 |
ready: 'ready', |
| 24520 |
beforeDestruct: 'beforeDestruct', |
| 24521 |
destructed: 'destructed' |
| 24522 |
}; |
| 24523 |
|
| 24524 |
|
| 24525 |
/***/ }), |
| 24526 |
|
| 24527 |
/***/ 69696: |
| 24528 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 24529 |
|
| 24530 |
"use strict"; |
| 24531 |
/* unused harmony export fullsize */ |
| 24532 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(28077); |
| 24533 |
/* harmony import */ var jodit_core_helpers_checker_is_jodit_object__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(24497); |
| 24534 |
/* harmony import */ var jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(80991); |
| 24535 |
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(80538); |
| 24536 |
/*! |
| 24537 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 24538 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 24539 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 24540 |
*/ /** |
| 24541 |
* [[include:plugins/fullsize/README.md]] |
| 24542 |
* @packageDocumentation |
| 24543 |
* @module plugins/fullsize |
| 24544 |
*/ |
| 24545 |
|
| 24546 |
|
| 24547 |
|
| 24548 |
|
| 24549 |
const fullsizeStack = new Set(); |
| 24550 |
/** |
| 24551 |
* Process `toggleFullSize` event, and behavior - set/unset fullsize mode |
| 24552 |
*/ function fullsize(editor) { |
| 24553 |
editor.registerButton({ |
| 24554 |
name: 'fullsize' |
| 24555 |
}); |
| 24556 |
let isEnabled = false, oldHeight = 0, oldWidth = 0, wasToggled = false; |
| 24557 |
const resize = ()=>{ |
| 24558 |
const { container, events } = editor; |
| 24559 |
if (!events) { |
| 24560 |
return; |
| 24561 |
} |
| 24562 |
if (isEnabled) { |
| 24563 |
oldHeight = (0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_2__.css)(container, 'height', true); |
| 24564 |
oldWidth = (0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_2__.css)(container, 'width', true); |
| 24565 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_2__.css)(container, { |
| 24566 |
height: editor.ow.innerHeight, |
| 24567 |
width: editor.ow.innerWidth |
| 24568 |
}); |
| 24569 |
wasToggled = true; |
| 24570 |
} else if (wasToggled) { |
| 24571 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_2__.css)(container, { |
| 24572 |
height: oldHeight || 'auto', |
| 24573 |
width: oldWidth || 'auto' |
| 24574 |
}); |
| 24575 |
} |
| 24576 |
}, /** |
| 24577 |
* Change editor's state between FullSize and normal |
| 24578 |
*/ toggle = (enable)=>{ |
| 24579 |
const { container, events } = editor; |
| 24580 |
if (!container) { |
| 24581 |
return; |
| 24582 |
} |
| 24583 |
if (enable === undefined) { |
| 24584 |
enable = !container.classList.contains('jodit_fullsize'); |
| 24585 |
} |
| 24586 |
editor.setMod('fullsize', enable); |
| 24587 |
editor.o.fullsize = enable; |
| 24588 |
isEnabled = enable; |
| 24589 |
container.classList.toggle('jodit_fullsize', enable); |
| 24590 |
if (editor.toolbar) { |
| 24591 |
var _editor_toolbarContainer; |
| 24592 |
(0,jodit_core_helpers_checker_is_jodit_object__WEBPACK_IMPORTED_MODULE_1__.isJoditObject)(editor) && ((_editor_toolbarContainer = editor.toolbarContainer) === null || _editor_toolbarContainer === void 0 ? void 0 : _editor_toolbarContainer.appendChild(editor.toolbar.container)); |
| 24593 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_2__.css)(editor.toolbar.container, 'width', 'auto'); |
| 24594 |
} |
| 24595 |
enable ? fullsizeStack.add(container) : fullsizeStack.delete(container); |
| 24596 |
const shouldToggleGlobalFullsize = editor.o.globalFullSize && (fullsizeStack.size === 1 && enable || fullsizeStack.size === 0 && !enable); |
| 24597 |
if (shouldToggleGlobalFullsize) { |
| 24598 |
let node = container.parentNode; |
| 24599 |
while(node && node.nodeType !== Node.DOCUMENT_NODE && node.nodeType !== Node.DOCUMENT_FRAGMENT_NODE){ |
| 24600 |
node.classList.toggle('jodit_fullsize-box_true', enable); |
| 24601 |
node = node.parentNode; |
| 24602 |
} |
| 24603 |
resize(); |
| 24604 |
} |
| 24605 |
events.fire('afterResize'); |
| 24606 |
}; |
| 24607 |
if (editor.o.globalFullSize) { |
| 24608 |
editor.e.on(editor.ow, 'resize', resize); |
| 24609 |
} |
| 24610 |
editor.e.on('afterInit afterOpen', ()=>{ |
| 24611 |
var _editor_options; |
| 24612 |
editor.toggleFullSize(editor === null || editor === void 0 ? void 0 : (_editor_options = editor.options) === null || _editor_options === void 0 ? void 0 : _editor_options.fullsize); |
| 24613 |
}).on('toggleFullSize', toggle).on('beforeDestruct', ()=>{ |
| 24614 |
isEnabled && toggle(false); |
| 24615 |
}).on('beforeDestruct', ()=>{ |
| 24616 |
editor.events && editor.e.off(editor.ow, 'resize', resize); |
| 24617 |
}); |
| 24618 |
} |
| 24619 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_0__.pluginSystem.add('fullsize', fullsize); |
| 24620 |
|
| 24621 |
|
| 24622 |
/***/ }), |
| 24623 |
|
| 24624 |
/***/ 70195: |
| 24625 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 24626 |
|
| 24627 |
"use strict"; |
| 24628 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 24629 |
/* harmony export */ removeFormatForSelection: function() { return /* binding */ removeFormatForSelection; } |
| 24630 |
/* harmony export */ }); |
| 24631 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 24632 |
/* harmony import */ var jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(93640); |
| 24633 |
/* harmony import */ var _remove_format_for_collapsed_selection__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(37431); |
| 24634 |
/*! |
| 24635 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 24636 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 24637 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 24638 |
*/ /** |
| 24639 |
* @module plugins/clean-html |
| 24640 |
*/ |
| 24641 |
|
| 24642 |
|
| 24643 |
/** |
| 24644 |
* Remove formatting for all selected elements |
| 24645 |
* @private |
| 24646 |
*/ function removeFormatForSelection(jodit) { |
| 24647 |
const { s, editor, createInside } = jodit, { range } = s, left = range.cloneRange(), right = range.cloneRange(), fakeLeft = createInside.fake(), fakeRight = createInside.fake(); |
| 24648 |
left.collapse(true); |
| 24649 |
right.collapse(false); |
| 24650 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.safeInsertNode(left, fakeLeft); |
| 24651 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.safeInsertNode(right, fakeRight); |
| 24652 |
range.setStartBefore(fakeLeft); |
| 24653 |
range.collapse(true); |
| 24654 |
s.selectRange(range); |
| 24655 |
(0,_remove_format_for_collapsed_selection__WEBPACK_IMPORTED_MODULE_2__.removeFormatForCollapsedSelection)(jodit, fakeLeft); |
| 24656 |
range.setEndAfter(fakeRight); |
| 24657 |
range.collapse(false); |
| 24658 |
s.selectRange(range); |
| 24659 |
(0,_remove_format_for_collapsed_selection__WEBPACK_IMPORTED_MODULE_2__.removeFormatForCollapsedSelection)(jodit, fakeRight); |
| 24660 |
const shouldUnwrap = []; |
| 24661 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.between(fakeLeft, fakeRight, (node)=>{ |
| 24662 |
if ((0,_remove_format_for_collapsed_selection__WEBPACK_IMPORTED_MODULE_2__.isInlineBlock)(node) && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(node, 'a')) { |
| 24663 |
shouldUnwrap.push(node); |
| 24664 |
} |
| 24665 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isElement(node) && (0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__.attr)(node, 'style')) { |
| 24666 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__.attr)(node, 'style', null); |
| 24667 |
} |
| 24668 |
}); |
| 24669 |
shouldUnwrap.forEach((node)=>jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.unwrap(node)); |
| 24670 |
const clearParent = (node, left)=>{ |
| 24671 |
if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.findNotEmptySibling(node, left)) { |
| 24672 |
const pn = node.parentNode; |
| 24673 |
if (pn && pn !== editor && (0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__.attr)(pn, 'style')) { |
| 24674 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__.attr)(pn, 'style', null); |
| 24675 |
clearParent(pn, left); |
| 24676 |
return true; |
| 24677 |
} |
| 24678 |
} |
| 24679 |
}; |
| 24680 |
clearParent(fakeLeft, true) && clearParent(fakeRight, false); |
| 24681 |
range.setStartAfter(fakeLeft); |
| 24682 |
range.setEndBefore(fakeRight); |
| 24683 |
s.selectRange(range); |
| 24684 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(fakeLeft); |
| 24685 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(fakeRight); |
| 24686 |
} |
| 24687 |
|
| 24688 |
|
| 24689 |
/***/ }), |
| 24690 |
|
| 24691 |
/***/ 70222: |
| 24692 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 24693 |
|
| 24694 |
"use strict"; |
| 24695 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 24696 |
/* harmony export */ isNumeric: function() { return /* binding */ isNumeric; } |
| 24697 |
/* harmony export */ }); |
| 24698 |
/* harmony import */ var _is_string__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(85932); |
| 24699 |
/*! |
| 24700 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 24701 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 24702 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 24703 |
*/ /** |
| 24704 |
* @module helpers/checker |
| 24705 |
*/ |
| 24706 |
/** |
| 24707 |
* Check value has numeric format |
| 24708 |
*/ function isNumeric(value) { |
| 24709 |
if ((0,_is_string__WEBPACK_IMPORTED_MODULE_0__.isString)(value)) { |
| 24710 |
if (!value.match(/^([+-])?[0-9]+(\.?)([0-9]+)?(e[0-9]+)?$/)) { |
| 24711 |
return false; |
| 24712 |
} |
| 24713 |
value = parseFloat(value); |
| 24714 |
} |
| 24715 |
return typeof value === 'number' && !isNaN(value) && isFinite(value); |
| 24716 |
} |
| 24717 |
|
| 24718 |
|
| 24719 |
/***/ }), |
| 24720 |
|
| 24721 |
/***/ 70235: |
| 24722 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 24723 |
|
| 24724 |
"use strict"; |
| 24725 |
/* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7909); |
| 24726 |
/*! |
| 24727 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 24728 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 24729 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 24730 |
*/ /** |
| 24731 |
* @module plugins/inline-popup |
| 24732 |
*/ |
| 24733 |
/* harmony default export */ __webpack_exports__["default"] = ([ |
| 24734 |
{ |
| 24735 |
name: 'eye', |
| 24736 |
tooltip: 'Open link', |
| 24737 |
exec: (editor, current)=>{ |
| 24738 |
const href = (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_0__.attr)(current, 'href'); |
| 24739 |
if (current && href) { |
| 24740 |
editor.ow.open(href); |
| 24741 |
} |
| 24742 |
} |
| 24743 |
}, |
| 24744 |
{ |
| 24745 |
name: 'link', |
| 24746 |
tooltip: 'Edit link', |
| 24747 |
icon: 'pencil' |
| 24748 |
}, |
| 24749 |
'unlink', |
| 24750 |
'brush', |
| 24751 |
'file' |
| 24752 |
]); |
| 24753 |
|
| 24754 |
|
| 24755 |
/***/ }), |
| 24756 |
|
| 24757 |
/***/ 70535: |
| 24758 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 24759 |
|
| 24760 |
"use strict"; |
| 24761 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 24762 |
/* harmony export */ observable: function() { return /* binding */ observable; } |
| 24763 |
/* harmony export */ }); |
| 24764 |
/* harmony import */ var jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(17312); |
| 24765 |
/* harmony import */ var jodit_core_helpers_checker_is_equal__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(94013); |
| 24766 |
/* harmony import */ var jodit_core_helpers_checker_is_plain_object__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(62101); |
| 24767 |
/* harmony import */ var jodit_core_helpers_utils_utils__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(71125); |
| 24768 |
/*! |
| 24769 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 24770 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 24771 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 24772 |
*/ /** |
| 24773 |
* @module event-emitter |
| 24774 |
*/ |
| 24775 |
|
| 24776 |
|
| 24777 |
|
| 24778 |
const OBSERVABLE_OBJECT = Symbol('observable-object'); |
| 24779 |
function isObservableObject(obj) { |
| 24780 |
return obj[OBSERVABLE_OBJECT] !== undefined; |
| 24781 |
} |
| 24782 |
/** |
| 24783 |
* Makes any object an observable object |
| 24784 |
* @example |
| 24785 |
* ```js |
| 24786 |
* const obj = { |
| 24787 |
* a: 1, |
| 24788 |
* b: { |
| 24789 |
* c: 5 |
| 24790 |
* } |
| 24791 |
* } |
| 24792 |
* |
| 24793 |
* const obsObj = Jodit.modules.observable(obj); |
| 24794 |
* console.log(obj === obsObj); // true |
| 24795 |
* obsObj.on('change', () => { |
| 24796 |
* console.log('Object changed'); |
| 24797 |
* }); |
| 24798 |
* obsObj.on('change.a', () => { |
| 24799 |
* console.log('Key a changed'); |
| 24800 |
* }); |
| 24801 |
* obsObj.on('change.b.c', () => { |
| 24802 |
* console.log('Key b.c changed'); |
| 24803 |
* }); |
| 24804 |
* |
| 24805 |
* obj.a = 6; |
| 24806 |
* // Object changed |
| 24807 |
* // Key a changed |
| 24808 |
* |
| 24809 |
* obj.b = {c: 6} |
| 24810 |
* // Object changed |
| 24811 |
* |
| 24812 |
* obj.b.c = 8 |
| 24813 |
* // Object changed |
| 24814 |
* // Key b.c changed |
| 24815 |
* ``` |
| 24816 |
*/ function observable(obj) { |
| 24817 |
if (isObservableObject(obj)) { |
| 24818 |
return obj; |
| 24819 |
} |
| 24820 |
const __lockEvent = {}; |
| 24821 |
const __onEvents = {}; |
| 24822 |
const on = (event, callback)=>{ |
| 24823 |
if ((0,jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_0__.isArray)(event)) { |
| 24824 |
event.map((e)=>on(e, callback)); |
| 24825 |
return obj; |
| 24826 |
} |
| 24827 |
if (!__onEvents[event]) { |
| 24828 |
__onEvents[event] = []; |
| 24829 |
} |
| 24830 |
__onEvents[event].push(callback); |
| 24831 |
return obj; |
| 24832 |
}; |
| 24833 |
const fire = (event, ...attr)=>{ |
| 24834 |
if ((0,jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_0__.isArray)(event)) { |
| 24835 |
event.map((e)=>fire(e, ...attr)); |
| 24836 |
return; |
| 24837 |
} |
| 24838 |
try { |
| 24839 |
if (!__lockEvent[event] && __onEvents[event]) { |
| 24840 |
__lockEvent[event] = true; |
| 24841 |
__onEvents[event].forEach((clb)=>clb.call(obj, ...attr)); |
| 24842 |
} |
| 24843 |
} finally{ |
| 24844 |
__lockEvent[event] = false; |
| 24845 |
} |
| 24846 |
}; |
| 24847 |
const initAccessors = (dict, prefixes = [])=>{ |
| 24848 |
const store = {}; |
| 24849 |
if (isObservableObject(dict)) { |
| 24850 |
return; |
| 24851 |
} |
| 24852 |
Object.defineProperty(dict, OBSERVABLE_OBJECT, { |
| 24853 |
enumerable: false, |
| 24854 |
value: true |
| 24855 |
}); |
| 24856 |
Object.keys(dict).forEach((_key)=>{ |
| 24857 |
const key = _key; |
| 24858 |
const prefix = prefixes.concat(key).filter((a)=>a.length); |
| 24859 |
store[key] = dict[key]; |
| 24860 |
const descriptor = (0,jodit_core_helpers_utils_utils__WEBPACK_IMPORTED_MODULE_3__.getPropertyDescriptor)(dict, key); |
| 24861 |
Object.defineProperty(dict, key, { |
| 24862 |
set: (value)=>{ |
| 24863 |
const oldValue = store[key]; |
| 24864 |
if (!(0,jodit_core_helpers_checker_is_equal__WEBPACK_IMPORTED_MODULE_1__.isFastEqual)(store[key], value)) { |
| 24865 |
fire([ |
| 24866 |
'beforeChange', |
| 24867 |
`beforeChange.${prefix.join('.')}` |
| 24868 |
], key, value); |
| 24869 |
if ((0,jodit_core_helpers_checker_is_plain_object__WEBPACK_IMPORTED_MODULE_2__.isPlainObject)(value)) { |
| 24870 |
initAccessors(value, prefix); |
| 24871 |
} |
| 24872 |
if (descriptor && descriptor.set) { |
| 24873 |
descriptor.set.call(obj, value); |
| 24874 |
} else { |
| 24875 |
store[key] = value; |
| 24876 |
} |
| 24877 |
const sum = []; |
| 24878 |
fire([ |
| 24879 |
'change', |
| 24880 |
...prefix.reduce((rs, p)=>{ |
| 24881 |
sum.push(p); |
| 24882 |
rs.push(`change.${sum.join('.')}`); |
| 24883 |
return rs; |
| 24884 |
}, []) |
| 24885 |
], prefix.join('.'), oldValue, (value === null || value === void 0 ? void 0 : value.valueOf) ? value.valueOf() : value); |
| 24886 |
} |
| 24887 |
}, |
| 24888 |
get: ()=>{ |
| 24889 |
if (descriptor && descriptor.get) { |
| 24890 |
return descriptor.get.call(obj); |
| 24891 |
} |
| 24892 |
return store[key]; |
| 24893 |
}, |
| 24894 |
enumerable: true, |
| 24895 |
configurable: true |
| 24896 |
}); |
| 24897 |
if ((0,jodit_core_helpers_checker_is_plain_object__WEBPACK_IMPORTED_MODULE_2__.isPlainObject)(store[key])) { |
| 24898 |
initAccessors(store[key], prefix); |
| 24899 |
} |
| 24900 |
}); |
| 24901 |
Object.defineProperty(obj, 'on', { |
| 24902 |
value: on |
| 24903 |
}); |
| 24904 |
}; |
| 24905 |
initAccessors(obj); |
| 24906 |
return obj; |
| 24907 |
} |
| 24908 |
|
| 24909 |
|
| 24910 |
/***/ }), |
| 24911 |
|
| 24912 |
/***/ 70577: |
| 24913 |
/***/ (function(module) { |
| 24914 |
|
| 24915 |
/*! |
| 24916 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 24917 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 24918 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 24919 |
*/ module.exports = { |
| 24920 |
'copy-format': 'Copiar formato' |
| 24921 |
}; |
| 24922 |
|
| 24923 |
|
| 24924 |
/***/ }), |
| 24925 |
|
| 24926 |
/***/ 70697: |
| 24927 |
/***/ (function(module) { |
| 24928 |
|
| 24929 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M1152 512v-472q22 14 36 28l408 408q14 14 28 36h-472zm-128 32q0 40 28 68t68 28h544v1056q0 40-28 68t-68 28h-1344q-40 0-68-28t-28-68v-1600q0-40 28-68t68-28h800v544z\"/> </svg>" |
| 24930 |
|
| 24931 |
/***/ }), |
| 24932 |
|
| 24933 |
/***/ 70881: |
| 24934 |
/***/ (function(module) { |
| 24935 |
|
| 24936 |
module.exports = "<svg viewBox=\"0 0 14 14\" xmlns=\"http://www.w3.org/2000/svg\"> <g stroke=\"none\" stroke-width=\"1\"> <path d=\"M14,1.4 L12.6,0 L7,5.6 L1.4,0 L0,1.4 L5.6,7 L0,12.6 L1.4,14 L7,8.4 L12.6,14 L14,12.6 L8.4,7 L14,1.4 Z\"/> </g> </svg>" |
| 24937 |
|
| 24938 |
/***/ }), |
| 24939 |
|
| 24940 |
/***/ 70999: |
| 24941 |
/***/ (function(module) { |
| 24942 |
|
| 24943 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M1728 576v256q0 26-19 45t-45 19h-64q-26 0-45-19t-19-45v-256q0-106-75-181t-181-75-181 75-75 181v192h96q40 0 68 28t28 68v576q0 40-28 68t-68 28h-960q-40 0-68-28t-28-68v-576q0-40 28-68t68-28h672v-192q0-185 131.5-316.5t316.5-131.5 316.5 131.5 131.5 316.5z\"/> </svg>" |
| 24944 |
|
| 24945 |
/***/ }), |
| 24946 |
|
| 24947 |
/***/ 71125: |
| 24948 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 24949 |
|
| 24950 |
"use strict"; |
| 24951 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 24952 |
/* harmony export */ call: function() { return /* binding */ call; }, |
| 24953 |
/* harmony export */ callPromise: function() { return /* binding */ callPromise; }, |
| 24954 |
/* harmony export */ callThis: function() { return /* binding */ callThis; }, |
| 24955 |
/* harmony export */ getDataTransfer: function() { return /* binding */ getDataTransfer; }, |
| 24956 |
/* harmony export */ getPropertyDescriptor: function() { return /* binding */ getPropertyDescriptor; }, |
| 24957 |
/* harmony export */ keys: function() { return /* binding */ keys; }, |
| 24958 |
/* harmony export */ loadImage: function() { return /* binding */ loadImage; }, |
| 24959 |
/* harmony export */ markOwner: function() { return /* binding */ markOwner; }, |
| 24960 |
/* harmony export */ memorizeExec: function() { return /* binding */ memorizeExec; } |
| 24961 |
/* harmony export */ }); |
| 24962 |
/* harmony import */ var jodit_core_helpers_checker_is_promise__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(52100); |
| 24963 |
/* harmony import */ var jodit_core_helpers_checker_is_void__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(18303); |
| 24964 |
/* harmony import */ var _attr__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(7909); |
| 24965 |
/* harmony import */ var _data_bind__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(36400); |
| 24966 |
/*! |
| 24967 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 24968 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 24969 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 24970 |
*/ /** |
| 24971 |
* @module helpers/utils |
| 24972 |
*/ |
| 24973 |
|
| 24974 |
|
| 24975 |
|
| 24976 |
/** |
| 24977 |
* Call function with parameters |
| 24978 |
* |
| 24979 |
* @example |
| 24980 |
* ```js |
| 24981 |
* const f = Math.random(); |
| 24982 |
* Jodit.modules.Helpers.call(f > 0.5 ? Math.ceil : Math.floor, f); |
| 24983 |
* ``` |
| 24984 |
*/ function call(func, ...args) { |
| 24985 |
return func(...args); |
| 24986 |
} |
| 24987 |
/** |
| 24988 |
* Call function with parameters |
| 24989 |
* |
| 24990 |
* @example |
| 24991 |
* ```js |
| 24992 |
* const f = Math.random(); |
| 24993 |
* Jodit.modules.Helpers.call(f > 0.5 ? Math.ceil : Math.floor, f); |
| 24994 |
* ``` |
| 24995 |
*/ function callThis(func, thisArg, ...args) { |
| 24996 |
return func.apply(thisArg, args); |
| 24997 |
} |
| 24998 |
/** |
| 24999 |
* Mark element for debugging |
| 25000 |
*/ function markOwner(jodit, elm) { |
| 25001 |
(0,_attr__WEBPACK_IMPORTED_MODULE_2__.attr)(elm, 'data-editor_id', jodit.id); |
| 25002 |
!elm.component && Object.defineProperty(elm, 'jodit', { |
| 25003 |
value: jodit |
| 25004 |
}); |
| 25005 |
} |
| 25006 |
function callPromise(condition, callback) { |
| 25007 |
if ((0,jodit_core_helpers_checker_is_promise__WEBPACK_IMPORTED_MODULE_0__.isPromise)(condition)) { |
| 25008 |
return condition.then((resp)=>resp, ()=>null).finally(callback); |
| 25009 |
} |
| 25010 |
return callback === null || callback === void 0 ? void 0 : callback(); |
| 25011 |
} |
| 25012 |
/** |
| 25013 |
* Allow load image in promise |
| 25014 |
*/ const loadImage = (src, jodit)=>jodit.async.promise((res, rej)=>{ |
| 25015 |
const image = new Image(), onError = ()=>{ |
| 25016 |
jodit.e.off(image); |
| 25017 |
rej === null || rej === void 0 ? void 0 : rej(); |
| 25018 |
}, onSuccess = ()=>{ |
| 25019 |
jodit.e.off(image); |
| 25020 |
res(image); |
| 25021 |
}; |
| 25022 |
jodit.e.one(image, 'load', onSuccess).one(image, 'error', onError).one(image, 'abort', onError); |
| 25023 |
image.src = src; |
| 25024 |
if (image.complete) { |
| 25025 |
onSuccess(); |
| 25026 |
} |
| 25027 |
}); |
| 25028 |
const keys = (obj, own = true)=>{ |
| 25029 |
if (own) { |
| 25030 |
return Object.keys(obj); |
| 25031 |
} |
| 25032 |
const props = []; |
| 25033 |
for(const key in obj){ |
| 25034 |
props.push(key); |
| 25035 |
} |
| 25036 |
return props; |
| 25037 |
}; |
| 25038 |
/** |
| 25039 |
* Memorize last user chose |
| 25040 |
*/ const memorizeExec = (editor, _, { control }, preProcessValue)=>{ |
| 25041 |
var _ref; |
| 25042 |
const key = `button${control.command}`; |
| 25043 |
let value = (_ref = control.args && control.args[0]) !== null && _ref !== void 0 ? _ref : (0,_data_bind__WEBPACK_IMPORTED_MODULE_3__.dataBind)(editor, key); |
| 25044 |
if ((0,jodit_core_helpers_checker_is_void__WEBPACK_IMPORTED_MODULE_1__.isVoid)(value)) { |
| 25045 |
return false; |
| 25046 |
} |
| 25047 |
(0,_data_bind__WEBPACK_IMPORTED_MODULE_3__.dataBind)(editor, key, value); |
| 25048 |
if (preProcessValue) { |
| 25049 |
value = preProcessValue(value); |
| 25050 |
} |
| 25051 |
editor.execCommand(control.command, false, value !== null && value !== void 0 ? value : undefined); |
| 25052 |
}; |
| 25053 |
/** |
| 25054 |
* Get DataTransfer from different event types |
| 25055 |
*/ const getDataTransfer = (event)=>{ |
| 25056 |
if (event.clipboardData) { |
| 25057 |
return event.clipboardData; |
| 25058 |
} |
| 25059 |
try { |
| 25060 |
return event.dataTransfer || new DataTransfer(); |
| 25061 |
} catch (unused) { |
| 25062 |
return null; |
| 25063 |
} |
| 25064 |
}; |
| 25065 |
function getPropertyDescriptor(obj, prop) { |
| 25066 |
let desc; |
| 25067 |
do { |
| 25068 |
desc = Object.getOwnPropertyDescriptor(obj, prop); |
| 25069 |
obj = Object.getPrototypeOf(obj); |
| 25070 |
}while (!desc && obj) |
| 25071 |
return desc; |
| 25072 |
} |
| 25073 |
|
| 25074 |
|
| 25075 |
/***/ }), |
| 25076 |
|
| 25077 |
/***/ 71552: |
| 25078 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 25079 |
|
| 25080 |
"use strict"; |
| 25081 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 25082 |
/* harmony export */ applyValuesToImage: function() { return /* binding */ applyValuesToImage; } |
| 25083 |
/* harmony export */ }); |
| 25084 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 25085 |
/* harmony import */ var jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(93640); |
| 25086 |
/* harmony import */ var _link__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(49422); |
| 25087 |
/* harmony import */ var _margin__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(21132); |
| 25088 |
/* harmony import */ var _size__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(49147); |
| 25089 |
/*! |
| 25090 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 25091 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 25092 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 25093 |
*/ /** |
| 25094 |
* @module plugins/image-properties |
| 25095 |
*/ |
| 25096 |
|
| 25097 |
|
| 25098 |
|
| 25099 |
|
| 25100 |
/** |
| 25101 |
* Apply form's values to image |
| 25102 |
* @private |
| 25103 |
*/ function applyValuesToImage(j, state, image) { |
| 25104 |
const { style, imageSrc, borderRadius, imageTitle, imageAlt, imageLink, imageWidth, imageHeight, marginTop, marginRight, marginBottom, marginLeft, imageLinkOpenInNewTab, align, classes, id } = state.values; |
| 25105 |
const opt = j.o; |
| 25106 |
// styles |
| 25107 |
if (opt.image.editStyle) { |
| 25108 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__.attr)(image, 'style', style || null); |
| 25109 |
} |
| 25110 |
// Src |
| 25111 |
if (imageSrc) { |
| 25112 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__.attr)(image, 'src', imageSrc); |
| 25113 |
} else { |
| 25114 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(image); |
| 25115 |
return; |
| 25116 |
} |
| 25117 |
// Border radius |
| 25118 |
image.style.borderRadius = borderRadius ? borderRadius + 'px' : ''; |
| 25119 |
// Title |
| 25120 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__.attr)(image, 'title', imageTitle || null); |
| 25121 |
// Alt |
| 25122 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__.attr)(image, 'alt', imageAlt || null); |
| 25123 |
// Link |
| 25124 |
(0,_link__WEBPACK_IMPORTED_MODULE_2__.applyLink)(j, image, imageLink, imageLinkOpenInNewTab); |
| 25125 |
// Size |
| 25126 |
(0,_size__WEBPACK_IMPORTED_MODULE_4__.applySize)(image, imageWidth, imageHeight, state.sizeIsLocked); |
| 25127 |
// Margin |
| 25128 |
if (j.o.image.editMargins) { |
| 25129 |
(0,_margin__WEBPACK_IMPORTED_MODULE_3__.applyMargin)(j, marginTop, marginRight, marginBottom, marginLeft, image, state.marginIsLocked); |
| 25130 |
} |
| 25131 |
if (opt.image.editClass) { |
| 25132 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__.attr)(image, 'class', classes || null); |
| 25133 |
} |
| 25134 |
if (opt.image.editId) { |
| 25135 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__.attr)(image, 'id', id || null); |
| 25136 |
} |
| 25137 |
if (opt.image.editAlign) { |
| 25138 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__.hAlignElement)(image, align); |
| 25139 |
} |
| 25140 |
} |
| 25141 |
|
| 25142 |
|
| 25143 |
/***/ }), |
| 25144 |
|
| 25145 |
/***/ 71940: |
| 25146 |
/***/ (function(module) { |
| 25147 |
|
| 25148 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 48 48\"> <path d=\"M6 18h4v-4h-4v4zm0-8h4v-4h-4v4zm8 32h4v-4h-4v4zm0-16h4v-4h-4v4zm-8 0h4v-4h-4v4zm0 16h4v-4h-4v4zm0-8h4v-4h-4v4zm8-24h4v-4h-4v4zm24 24h4v-4h-4v4zm-16 8h4v-36h-4v36zm16 0h4v-4h-4v4zm0-16h4v-4h-4v4zm0-20v4h4v-4h-4zm0 12h4v-4h-4v4zm-8-8h4v-4h-4v4zm0 32h4v-4h-4v4zm0-16h4v-4h-4v4z\"/> <path d=\"M0 0h48v48h-48z\" fill=\"none\"/> </svg>" |
| 25149 |
|
| 25150 |
/***/ }), |
| 25151 |
|
| 25152 |
/***/ 71948: |
| 25153 |
/***/ (function(module) { |
| 25154 |
|
| 25155 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M832 1408l336-384h-768l-336 384h768zm1013-1077q15 34 9.5 71.5t-30.5 65.5l-896 1024q-38 44-96 44h-768q-38 0-69.5-20.5t-47.5-54.5q-15-34-9.5-71.5t30.5-65.5l896-1024q38-44 96-44h768q38 0 69.5 20.5t47.5 54.5z\"/> </svg>" |
| 25156 |
|
| 25157 |
/***/ }), |
| 25158 |
|
| 25159 |
/***/ 72068: |
| 25160 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 25161 |
|
| 25162 |
"use strict"; |
| 25163 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 25164 |
/* harmony export */ isAbortError: function() { return /* binding */ isAbortError; } |
| 25165 |
/* harmony export */ }); |
| 25166 |
/*! |
| 25167 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 25168 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 25169 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 25170 |
*/ /** |
| 25171 |
* @module helpers/checker |
| 25172 |
*/ function isAbortError(error) { |
| 25173 |
return Boolean(error) && error instanceof DOMException && error.name === 'AbortError'; |
| 25174 |
} |
| 25175 |
|
| 25176 |
|
| 25177 |
/***/ }), |
| 25178 |
|
| 25179 |
/***/ 72348: |
| 25180 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 25181 |
|
| 25182 |
"use strict"; |
| 25183 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 25184 |
/* harmony export */ ColorPickerWidget: function() { return /* binding */ ColorPickerWidget; } |
| 25185 |
/* harmony export */ }); |
| 25186 |
/* harmony import */ var jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(27795); |
| 25187 |
/* harmony import */ var jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(65946); |
| 25188 |
/* harmony import */ var jodit_core_ui__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(4099); |
| 25189 |
/* harmony import */ var _palette_svg__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(54522); |
| 25190 |
/* harmony import */ var _palette_svg__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_palette_svg__WEBPACK_IMPORTED_MODULE_3__); |
| 25191 |
/*! |
| 25192 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 25193 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 25194 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 25195 |
*/ /** |
| 25196 |
* [[include:modules/widget/color-picker/README.md]] |
| 25197 |
* @packageDocumentation |
| 25198 |
* @module modules/widget/color-picker |
| 25199 |
*/ |
| 25200 |
|
| 25201 |
|
| 25202 |
|
| 25203 |
|
| 25204 |
jodit_core_ui__WEBPACK_IMPORTED_MODULE_2__.Icon.set('palette', (_palette_svg__WEBPACK_IMPORTED_MODULE_3___default())); |
| 25205 |
/** |
| 25206 |
* Build color picker |
| 25207 |
* |
| 25208 |
* @param callback - Callback 'function (color) \{\}' |
| 25209 |
* @param coldColor - Color value ex. #fff or rgb(123, 123, 123) or rgba(123, 123, 123, 1) |
| 25210 |
* @example |
| 25211 |
* ```javascript |
| 25212 |
* const tabs = TabsWidget(editor, { |
| 25213 |
* 'Text': ColorPickerWidget(editor, function (color) { |
| 25214 |
* box.style.color = color; |
| 25215 |
* }, box.style.color), |
| 25216 |
* 'Background': ColorPickerWidget(editor, function (color) { |
| 25217 |
* box.style.backgroundColor = color; |
| 25218 |
* }, box.style.backgroundColor), |
| 25219 |
* }); |
| 25220 |
* ``` |
| 25221 |
*/ const ColorPickerWidget = (editor, callback, coldColor)=>{ |
| 25222 |
const cn = 'jodit-color-picker', valueHex = (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.normalizeColor)(coldColor), form = editor.c.div(cn), iconPalette = editor.o.textIcons ? `<span>${editor.i18n('palette')}</span>` : jodit_core_ui__WEBPACK_IMPORTED_MODULE_2__.Icon.get('palette'), eachColor = (colors)=>{ |
| 25223 |
const stack = []; |
| 25224 |
if ((0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.isPlainObject)(colors)) { |
| 25225 |
Object.keys(colors).forEach((key)=>{ |
| 25226 |
stack.push(`<div class="${cn}__group ${cn}__group-${key}">`); |
| 25227 |
stack.push(eachColor(colors[key])); |
| 25228 |
stack.push('</div>'); |
| 25229 |
}); |
| 25230 |
} else if ((0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.isArray)(colors)) { |
| 25231 |
colors.forEach((color)=>{ |
| 25232 |
stack.push(`<span class='${cn}__color-item ${valueHex === color ? cn + '__color-item_active_true' : ''}' title="${color}" style="background-color:${color}" data-color="${color}"></span>`); |
| 25233 |
}); |
| 25234 |
} |
| 25235 |
return stack.join(''); |
| 25236 |
}; |
| 25237 |
form.appendChild(editor.c.fromHTML(`<div class="${cn}__groups">${eachColor(editor.o.colors)}</div>`)); |
| 25238 |
form.appendChild(editor.c.fromHTML(`<div data-ref="extra" class="${cn}__extra"></div>`)); |
| 25239 |
const { extra } = (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.refs)(form); |
| 25240 |
if (editor.o.showBrowserColorPicker && (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.hasBrowserColorPicker)()) { |
| 25241 |
extra.appendChild(editor.c.fromHTML(`<div class="${cn}__native">${iconPalette}<input type="color" value="#ffffff"/></div>`)); |
| 25242 |
editor.e.on(form, 'change', (e)=>{ |
| 25243 |
e.stopPropagation(); |
| 25244 |
const target = e.target; |
| 25245 |
if (!target || !target.tagName || !jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(target, 'input')) { |
| 25246 |
return; |
| 25247 |
} |
| 25248 |
const color = target.value || ''; |
| 25249 |
if ((0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.isFunction)(callback)) { |
| 25250 |
callback(color); |
| 25251 |
} |
| 25252 |
e.preventDefault(); |
| 25253 |
}); |
| 25254 |
} |
| 25255 |
editor.e.on(form, 'mousedown touchend', (e)=>{ |
| 25256 |
e.stopPropagation(); |
| 25257 |
e.preventDefault(); |
| 25258 |
let target = e.target; |
| 25259 |
if ((!target || !target.tagName || jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(target, 'svg') || jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(target, 'path')) && target.parentNode) { |
| 25260 |
target = jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(target.parentNode, 'span', editor.editor); |
| 25261 |
} |
| 25262 |
if (!jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(target, 'span') || !target.classList.contains(cn + '__color-item')) { |
| 25263 |
return; |
| 25264 |
} |
| 25265 |
const color = (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.attr)(target, '-color') || ''; |
| 25266 |
if (callback && (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.isFunction)(callback)) { |
| 25267 |
callback(color); |
| 25268 |
} |
| 25269 |
}); |
| 25270 |
editor.e.fire('afterGenerateColorPicker', form, extra, callback, valueHex); |
| 25271 |
return form; |
| 25272 |
}; |
| 25273 |
|
| 25274 |
|
| 25275 |
/***/ }), |
| 25276 |
|
| 25277 |
/***/ 72412: |
| 25278 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 25279 |
|
| 25280 |
"use strict"; |
| 25281 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 25282 |
/* harmony export */ isNumber: function() { return /* binding */ isNumber; } |
| 25283 |
/* harmony export */ }); |
| 25284 |
/*! |
| 25285 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 25286 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 25287 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 25288 |
*/ /** |
| 25289 |
* @module helpers/checker |
| 25290 |
*/ /** |
| 25291 |
* Check value is a number |
| 25292 |
*/ function isNumber(value) { |
| 25293 |
return typeof value === 'number' && !isNaN(value) && isFinite(value); |
| 25294 |
} |
| 25295 |
|
| 25296 |
|
| 25297 |
/***/ }), |
| 25298 |
|
| 25299 |
/***/ 73019: |
| 25300 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 25301 |
|
| 25302 |
"use strict"; |
| 25303 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 25304 |
/* harmony export */ isSameStyleChild: function() { return /* binding */ isSameStyleChild; }, |
| 25305 |
/* harmony export */ isSuitElement: function() { return /* binding */ isSuitElement; }, |
| 25306 |
/* harmony export */ suitableClosest: function() { return /* binding */ suitableClosest; } |
| 25307 |
/* harmony export */ }); |
| 25308 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 25309 |
/* harmony import */ var _has_same_style__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(9703); |
| 25310 |
/* harmony import */ var _is_normal_node__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(83653); |
| 25311 |
/*! |
| 25312 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 25313 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 25314 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 25315 |
*/ |
| 25316 |
|
| 25317 |
|
| 25318 |
/** |
| 25319 |
* Checks if an item is suitable for applying a commit. The element suits us if it |
| 25320 |
* - has the same styles as in the commit (commitStyle.options.style) |
| 25321 |
* - has the same tag as in the commit (commitStyle.options.element) |
| 25322 |
* |
| 25323 |
* @param commitStyle - style commit |
| 25324 |
* @param elm - checked item |
| 25325 |
* @param strict - strict mode - false - the default tag is suitable for us if it is also in the commit |
| 25326 |
* @param strictStyle - strict style mode - true - the element has the same style keys as in the commit, but not their values |
| 25327 |
* @private |
| 25328 |
*/ function isSuitElement(commitStyle, elm, strict, strictStyle = true) { |
| 25329 |
var _options_attributes; |
| 25330 |
if (!elm || !(0,_is_normal_node__WEBPACK_IMPORTED_MODULE_2__.isNormalNode)(elm)) { |
| 25331 |
return false; |
| 25332 |
} |
| 25333 |
const { element, elementIsDefault, options } = commitStyle; |
| 25334 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isList(elm) && commitStyle.elementIsList) { |
| 25335 |
return true; |
| 25336 |
} |
| 25337 |
const elmIsSame = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(elm, element); |
| 25338 |
if (elmIsSame && !(elementIsDefault && strict)) { |
| 25339 |
return true; |
| 25340 |
} |
| 25341 |
const elmHasSameStyle = Boolean(((_options_attributes = options.attributes) === null || _options_attributes === void 0 ? void 0 : _options_attributes.style) && (strictStyle ? (0,_has_same_style__WEBPACK_IMPORTED_MODULE_1__.hasSameStyle)(elm, options.attributes.style) : (0,_has_same_style__WEBPACK_IMPORTED_MODULE_1__.hasSameStyleKeys)(elm, options.attributes.style))); |
| 25342 |
if (elmHasSameStyle && !commitStyle.elementIsList) { |
| 25343 |
return true; |
| 25344 |
} |
| 25345 |
return !elmIsSame && !strict && elementIsDefault && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isInlineBlock(elm); |
| 25346 |
} |
| 25347 |
/** |
| 25348 |
* @private |
| 25349 |
*/ function suitableClosest(commitStyle, element, root) { |
| 25350 |
return jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(element, (node)=>isSuitElement(commitStyle, node, true, false), root); |
| 25351 |
} |
| 25352 |
/** |
| 25353 |
* Inside the parent element there is a block with the same styles |
| 25354 |
* @example |
| 25355 |
* For selection: |
| 25356 |
* ```html |
| 25357 |
* <p>|test<strong>test</strong>|</p> |
| 25358 |
* ``` |
| 25359 |
* Apply `{element:'strong'}` |
| 25360 |
* @private |
| 25361 |
*/ function isSameStyleChild(commitStyle, elm) { |
| 25362 |
var _options_attributes, _options_attributes1; |
| 25363 |
const { element, options } = commitStyle; |
| 25364 |
if (!elm || !(0,_is_normal_node__WEBPACK_IMPORTED_MODULE_2__.isNormalNode)(elm)) { |
| 25365 |
return false; |
| 25366 |
} |
| 25367 |
const elmIsSame = elm.nodeName.toLowerCase() === element; |
| 25368 |
const elmHasSameStyle = Boolean(((_options_attributes = options.attributes) === null || _options_attributes === void 0 ? void 0 : _options_attributes.style) && (0,_has_same_style__WEBPACK_IMPORTED_MODULE_1__.hasSameStyleKeys)(elm, (_options_attributes1 = options.attributes) === null || _options_attributes1 === void 0 ? void 0 : _options_attributes1.style)); |
| 25369 |
return elmIsSame && elmHasSameStyle; |
| 25370 |
} |
| 25371 |
|
| 25372 |
|
| 25373 |
/***/ }), |
| 25374 |
|
| 25375 |
/***/ 73154: |
| 25376 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 25377 |
|
| 25378 |
"use strict"; |
| 25379 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 25380 |
/* harmony export */ wrap: function() { return /* binding */ wrap; } |
| 25381 |
/* harmony export */ }); |
| 25382 |
/* harmony import */ var jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(27795); |
| 25383 |
/* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(7909); |
| 25384 |
/* harmony import */ var _list_wrap_list__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(97110); |
| 25385 |
/* harmony import */ var _wrap_unwrapped_text__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(83335); |
| 25386 |
/*! |
| 25387 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 25388 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 25389 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 25390 |
*/ |
| 25391 |
|
| 25392 |
|
| 25393 |
|
| 25394 |
/** |
| 25395 |
* Replaces the parent tag with the applicable one, or wraps the text and also replaces the tag |
| 25396 |
* @private |
| 25397 |
*/ function wrap(commitStyle, font, jodit) { |
| 25398 |
const wrapper = findOrCreateWrapper(commitStyle, font, jodit); |
| 25399 |
return commitStyle.elementIsList ? (0,_list_wrap_list__WEBPACK_IMPORTED_MODULE_2__.wrapList)(commitStyle, wrapper, jodit) : jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.replace(wrapper, commitStyle.element, jodit.createInside, true); |
| 25400 |
} |
| 25401 |
const WRAP_NODES = new Set([ |
| 25402 |
'td', |
| 25403 |
'th', |
| 25404 |
'tr', |
| 25405 |
'tbody', |
| 25406 |
'table', |
| 25407 |
'li', |
| 25408 |
'ul', |
| 25409 |
'ol' |
| 25410 |
]); |
| 25411 |
/** |
| 25412 |
* If we apply a block element, then it finds the closest block parent (exclude table cell etc.), |
| 25413 |
* otherwise it wraps free text in an element. |
| 25414 |
*/ function findOrCreateWrapper(commitStyle, font, jodit) { |
| 25415 |
if (commitStyle.elementIsBlock) { |
| 25416 |
const box = jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.up(font, (node)=>jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isBlock(node) && !jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(node, WRAP_NODES), jodit.editor); |
| 25417 |
if (box) { |
| 25418 |
return box; |
| 25419 |
} |
| 25420 |
return (0,_wrap_unwrapped_text__WEBPACK_IMPORTED_MODULE_3__.wrapUnwrappedText)(commitStyle, font, jodit); |
| 25421 |
} |
| 25422 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(font, 'size', null); |
| 25423 |
return font; |
| 25424 |
} |
| 25425 |
|
| 25426 |
|
| 25427 |
/***/ }), |
| 25428 |
|
| 25429 |
/***/ 73302: |
| 25430 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 25431 |
|
| 25432 |
"use strict"; |
| 25433 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 25434 |
/* harmony export */ Jodit: function() { return /* binding */ Jodit; } |
| 25435 |
/* harmony export */ }); |
| 25436 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 25437 |
/* harmony import */ var _swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(41411); |
| 25438 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(31635); |
| 25439 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(81937); |
| 25440 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(84839); |
| 25441 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(28077); |
| 25442 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(65946); |
| 25443 |
/* harmony import */ var jodit_core_request__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(73714); |
| 25444 |
/* harmony import */ var jodit_core_traits_dlgs__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(80512); |
| 25445 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(5266); |
| 25446 |
/* harmony import */ var jodit_modules__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(60936); |
| 25447 |
/*! |
| 25448 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 25449 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 25450 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 25451 |
*/ /** |
| 25452 |
* [[include:README.md]] |
| 25453 |
* @packageDocumentation |
| 25454 |
* @module jodit |
| 25455 |
*/ |
| 25456 |
|
| 25457 |
|
| 25458 |
|
| 25459 |
|
| 25460 |
|
| 25461 |
|
| 25462 |
|
| 25463 |
|
| 25464 |
|
| 25465 |
|
| 25466 |
|
| 25467 |
const __defaultStyleDisplayKey = 'data-jodit-default-style-display'; |
| 25468 |
const __defaultClassesKey = 'data-jodit-default-classes'; |
| 25469 |
const NOEDIT = { |
| 25470 |
contenteditable: false |
| 25471 |
}; |
| 25472 |
class Jodit extends jodit_modules__WEBPACK_IMPORTED_MODULE_10__.ViewWithToolbar { |
| 25473 |
/** @override */ className() { |
| 25474 |
return 'Jodit'; |
| 25475 |
} |
| 25476 |
/** |
| 25477 |
* Return promise for ready actions |
| 25478 |
* @example |
| 25479 |
* ```js |
| 25480 |
* const jodit = Jodit.make('#editor'); |
| 25481 |
* await jodit.waitForReady(); |
| 25482 |
* jodit.e.fire('someAsyncLoadedPluginEvent', (test) => { |
| 25483 |
* alert(test); |
| 25484 |
* }); |
| 25485 |
* ``` |
| 25486 |
*/ waitForReady() { |
| 25487 |
if (this.isReady) { |
| 25488 |
return Promise.resolve(this); |
| 25489 |
} |
| 25490 |
return this.async.promise((resolve)=>{ |
| 25491 |
this.hookStatus('ready', ()=>resolve(this)); |
| 25492 |
}); |
| 25493 |
} |
| 25494 |
/** |
| 25495 |
* @deprecated I don't know why I wrote itp |
| 25496 |
*/ static get ready() { |
| 25497 |
return new Promise((resolve)=>{ |
| 25498 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_5__.eventEmitter.on('joditready', resolve); |
| 25499 |
}); |
| 25500 |
} |
| 25501 |
/** |
| 25502 |
* Plain text editor's value |
| 25503 |
*/ get text() { |
| 25504 |
if (this.editor) { |
| 25505 |
return this.editor.innerText || ''; |
| 25506 |
} |
| 25507 |
const div = this.createInside.div(); |
| 25508 |
div.innerHTML = this.getElementValue(); |
| 25509 |
return div.innerText || ''; |
| 25510 |
} |
| 25511 |
/** |
| 25512 |
* Return a default timeout period in milliseconds for some debounce or throttle functions. |
| 25513 |
* By default, `{history.timeout}` options |
| 25514 |
*/ get defaultTimeout() { |
| 25515 |
return (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.isNumber)(this.o.defaultTimeout) ? this.o.defaultTimeout : jodit_config__WEBPACK_IMPORTED_MODULE_9__.Config.defaultOptions.defaultTimeout; |
| 25516 |
} |
| 25517 |
/** |
| 25518 |
* Method wrap usual object in Object helper for prevent deep object merging in options* |
| 25519 |
* ```js |
| 25520 |
* const editor = Jodit.make('#editor', { |
| 25521 |
* controls: { |
| 25522 |
* fontsize: { |
| 25523 |
* list: Jodit.atom([8, 9, 10]) |
| 25524 |
* } |
| 25525 |
* } |
| 25526 |
* }); |
| 25527 |
* ``` |
| 25528 |
* In this case, the array [8, 9, 10] will not be combined with other arrays, but will replace them |
| 25529 |
*/ static atom(object) { |
| 25530 |
return (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.markAsAtomic)(object); |
| 25531 |
} |
| 25532 |
/** |
| 25533 |
* Factory for creating Jodit instance |
| 25534 |
*/ static make(element, options) { |
| 25535 |
return new this(element, options); |
| 25536 |
} |
| 25537 |
/** |
| 25538 |
* Checks if the element has already been initialized when for Jodit |
| 25539 |
*/ static isJoditAssigned(element) { |
| 25540 |
return element && (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.isJoditObject)(element.component) && !element.component.isInDestruct; |
| 25541 |
} |
| 25542 |
/** |
| 25543 |
* Default settings |
| 25544 |
*/ static get defaultOptions() { |
| 25545 |
return jodit_config__WEBPACK_IMPORTED_MODULE_9__.Config.defaultOptions; |
| 25546 |
} |
| 25547 |
get createInside() { |
| 25548 |
return new jodit_modules__WEBPACK_IMPORTED_MODULE_10__.Create(()=>this.ed, this.o.createAttributes); |
| 25549 |
} |
| 25550 |
__setPlaceField(field, value) { |
| 25551 |
if (!this.currentPlace) { |
| 25552 |
this.currentPlace = {}; |
| 25553 |
this.places = [ |
| 25554 |
this.currentPlace |
| 25555 |
]; |
| 25556 |
} |
| 25557 |
this.currentPlace[field] = value; |
| 25558 |
} |
| 25559 |
/** |
| 25560 |
* element It contains source element |
| 25561 |
*/ get element() { |
| 25562 |
return this.currentPlace.element; |
| 25563 |
} |
| 25564 |
/** |
| 25565 |
* editor It contains the root element editor |
| 25566 |
*/ get editor() { |
| 25567 |
return this.currentPlace.editor; |
| 25568 |
} |
| 25569 |
set editor(editor) { |
| 25570 |
this.__setPlaceField('editor', editor); |
| 25571 |
} |
| 25572 |
/** |
| 25573 |
* Container for all staff |
| 25574 |
*/ get container() { |
| 25575 |
return this.currentPlace.container; |
| 25576 |
} |
| 25577 |
set container(container) { |
| 25578 |
this.__setPlaceField('container', container); |
| 25579 |
} |
| 25580 |
/** |
| 25581 |
* workplace It contains source and wysiwyg editors |
| 25582 |
*/ get workplace() { |
| 25583 |
return this.currentPlace.workplace; |
| 25584 |
} |
| 25585 |
get message() { |
| 25586 |
return this.getMessageModule(this.workplace); |
| 25587 |
} |
| 25588 |
/** |
| 25589 |
* Statusbar module |
| 25590 |
*/ get statusbar() { |
| 25591 |
return this.currentPlace.statusbar; |
| 25592 |
} |
| 25593 |
/** |
| 25594 |
* iframe Iframe for iframe mode |
| 25595 |
*/ get iframe() { |
| 25596 |
return this.currentPlace.iframe; |
| 25597 |
} |
| 25598 |
set iframe(iframe) { |
| 25599 |
this.__setPlaceField('iframe', iframe); |
| 25600 |
} |
| 25601 |
get history() { |
| 25602 |
return this.currentPlace.history; |
| 25603 |
} |
| 25604 |
/** |
| 25605 |
* In iframe mode editor's window can be different by owner |
| 25606 |
*/ get editorWindow() { |
| 25607 |
return this.currentPlace.editorWindow; |
| 25608 |
} |
| 25609 |
set editorWindow(win) { |
| 25610 |
this.__setPlaceField('editorWindow', win); |
| 25611 |
} |
| 25612 |
/** |
| 25613 |
* Alias for this.ew |
| 25614 |
*/ get ew() { |
| 25615 |
return this.editorWindow; |
| 25616 |
} |
| 25617 |
/** |
| 25618 |
* In iframe mode editor's window can be different by owner |
| 25619 |
*/ get editorDocument() { |
| 25620 |
return this.currentPlace.editorWindow.document; |
| 25621 |
} |
| 25622 |
/** |
| 25623 |
* Alias for this.ew |
| 25624 |
*/ get ed() { |
| 25625 |
return this.editorDocument; |
| 25626 |
} |
| 25627 |
/** |
| 25628 |
* options All Jodit settings default + second arguments of constructor |
| 25629 |
*/ get options() { |
| 25630 |
return this.currentPlace.options; |
| 25631 |
} |
| 25632 |
set options(opt) { |
| 25633 |
this.__options = opt; |
| 25634 |
this.__setPlaceField('options', opt); |
| 25635 |
} |
| 25636 |
/** |
| 25637 |
* Alias for this.selection |
| 25638 |
*/ get s() { |
| 25639 |
return this.selection; |
| 25640 |
} |
| 25641 |
get uploader() { |
| 25642 |
return this.getInstance('Uploader', this.o.uploader); |
| 25643 |
} |
| 25644 |
get filebrowser() { |
| 25645 |
const jodit = this; |
| 25646 |
const options = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.ConfigProto)({ |
| 25647 |
defaultTimeout: jodit.defaultTimeout, |
| 25648 |
uploader: jodit.o.uploader, |
| 25649 |
language: jodit.o.language, |
| 25650 |
license: jodit.o.license, |
| 25651 |
theme: jodit.o.theme, |
| 25652 |
shadowRoot: jodit.o.shadowRoot, |
| 25653 |
defaultCallback (data) { |
| 25654 |
if (data.files && data.files.length) { |
| 25655 |
data.files.forEach((file, i)=>{ |
| 25656 |
const url = data.baseurl + file; |
| 25657 |
const isImage = data.isImages ? data.isImages[i] : false; |
| 25658 |
if (isImage) { |
| 25659 |
jodit.s.insertImage(url, null, jodit.o.imageDefaultWidth); |
| 25660 |
} else { |
| 25661 |
jodit.s.insertNode(jodit.createInside.fromHTML(`<a href='${url}' title='${url}'>${url}</a>`)); |
| 25662 |
} |
| 25663 |
}); |
| 25664 |
} |
| 25665 |
} |
| 25666 |
}, this.o.filebrowser); |
| 25667 |
return jodit.getInstance('FileBrowser', options); |
| 25668 |
} |
| 25669 |
/** |
| 25670 |
* Editor's mode |
| 25671 |
*/ get mode() { |
| 25672 |
return this.__mode; |
| 25673 |
} |
| 25674 |
set mode(mode) { |
| 25675 |
this.setMode(mode); |
| 25676 |
} |
| 25677 |
/** |
| 25678 |
* Return real HTML value from WYSIWYG editor. |
| 25679 |
* @internal |
| 25680 |
*/ getNativeEditorValue() { |
| 25681 |
const value = this.e.fire('beforeGetNativeEditorValue'); |
| 25682 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.isString)(value)) { |
| 25683 |
return value; |
| 25684 |
} |
| 25685 |
if (this.editor) { |
| 25686 |
return this.editor.innerHTML; |
| 25687 |
} |
| 25688 |
return this.getElementValue(); |
| 25689 |
} |
| 25690 |
/** |
| 25691 |
* Set value to native editor |
| 25692 |
*/ setNativeEditorValue(value) { |
| 25693 |
const data = { |
| 25694 |
value |
| 25695 |
}; |
| 25696 |
if (this.e.fire('beforeSetNativeEditorValue', data)) { |
| 25697 |
return; |
| 25698 |
} |
| 25699 |
if (this.editor) { |
| 25700 |
this.editor.innerHTML = data.value; |
| 25701 |
} |
| 25702 |
} |
| 25703 |
/** |
| 25704 |
* HTML value |
| 25705 |
*/ get value() { |
| 25706 |
return this.getEditorValue(); |
| 25707 |
} |
| 25708 |
set value(html) { |
| 25709 |
this.setEditorValue(html); |
| 25710 |
// @ts-ignore Internal method |
| 25711 |
this.history.__processChanges(); |
| 25712 |
} |
| 25713 |
synchronizeValues() { |
| 25714 |
this.__imdSynchronizeValues(); |
| 25715 |
} |
| 25716 |
/** |
| 25717 |
* This is an internal method, do not use it in your applications. |
| 25718 |
* @private |
| 25719 |
* @internal |
| 25720 |
*/ __imdSynchronizeValues() { |
| 25721 |
this.setEditorValue(); |
| 25722 |
} |
| 25723 |
/** |
| 25724 |
* Return editor value |
| 25725 |
*/ getEditorValue(removeSelectionMarkers = true, consumer) { |
| 25726 |
/** |
| 25727 |
* Triggered before getEditorValue executed. |
| 25728 |
* If returned not undefined, getEditorValue will return this value |
| 25729 |
* @example |
| 25730 |
* ```javascript |
| 25731 |
* var editor = Jodit.make("#redactor"); |
| 25732 |
* editor.e.on('beforeGetValueFromEditor', function () { |
| 25733 |
* return editor.editor.innerHTML.replace(/a/g, 'b'); |
| 25734 |
* }); |
| 25735 |
* ``` |
| 25736 |
*/ let value; |
| 25737 |
value = this.e.fire('beforeGetValueFromEditor', consumer); |
| 25738 |
if (value !== undefined) { |
| 25739 |
return value; |
| 25740 |
} |
| 25741 |
value = this.getNativeEditorValue().replace(jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.INVISIBLE_SPACE_REG_EXP(), ''); |
| 25742 |
if (removeSelectionMarkers) { |
| 25743 |
value = value.replace(/<span[^>]+id="jodit-selection_marker_[^>]+><\/span>/g, ''); |
| 25744 |
} |
| 25745 |
if (value === '<br>') { |
| 25746 |
value = ''; |
| 25747 |
} |
| 25748 |
/** |
| 25749 |
* Triggered after getEditorValue got value from wysiwyg. |
| 25750 |
* It can change new_value.value |
| 25751 |
* |
| 25752 |
* @example |
| 25753 |
* ```javascript |
| 25754 |
* var editor = Jodit.make("#redactor"); |
| 25755 |
* editor.e.on('afterGetValueFromEditor', function (new_value) { |
| 25756 |
* new_value.value = new_value.value.replace('a', 'b'); |
| 25757 |
* }); |
| 25758 |
* ``` |
| 25759 |
*/ const new_value = { |
| 25760 |
value |
| 25761 |
}; |
| 25762 |
this.e.fire('afterGetValueFromEditor', new_value, consumer); |
| 25763 |
return new_value.value; |
| 25764 |
} |
| 25765 |
/** |
| 25766 |
* Set editor html value and if set sync fill source element value |
| 25767 |
* When method was called without arguments - it is a simple way to synchronize editor to element |
| 25768 |
*/ setEditorValue(value) { |
| 25769 |
/** |
| 25770 |
* Triggered before getEditorValue set value to wysiwyg. |
| 25771 |
* @example |
| 25772 |
* ```javascript |
| 25773 |
* var editor = Jodit.make("#redactor"); |
| 25774 |
* editor.e.on('beforeSetValueToEditor', function (old_value) { |
| 25775 |
* return old_value.value.replace('a', 'b'); |
| 25776 |
* }); |
| 25777 |
* editor.e.on('beforeSetValueToEditor', function () { |
| 25778 |
* return false; // disable setEditorValue method |
| 25779 |
* }); |
| 25780 |
* ``` |
| 25781 |
*/ const newValue = this.e.fire('beforeSetValueToEditor', value); |
| 25782 |
if (newValue === false) { |
| 25783 |
return; |
| 25784 |
} |
| 25785 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.isString)(newValue)) { |
| 25786 |
value = newValue; |
| 25787 |
} |
| 25788 |
if (!this.editor) { |
| 25789 |
if (value !== undefined) { |
| 25790 |
this.__setElementValue(value); |
| 25791 |
} |
| 25792 |
return; // try change value before init or after destruct |
| 25793 |
} |
| 25794 |
if (!(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.isString)(value) && !(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.isVoid)(value)) { |
| 25795 |
throw (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.error)('value must be string'); |
| 25796 |
} |
| 25797 |
if (!(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.isVoid)(value) && this.getNativeEditorValue() !== value) { |
| 25798 |
this.setNativeEditorValue(value); |
| 25799 |
} |
| 25800 |
this.e.fire('postProcessSetEditorValue'); |
| 25801 |
const old_value = this.getElementValue(), new_value = this.getEditorValue(); |
| 25802 |
if (!this.__isSilentChange && old_value !== new_value && this.__callChangeCount < jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.SAFE_COUNT_CHANGE_CALL) { |
| 25803 |
this.__setElementValue(new_value); |
| 25804 |
this.__callChangeCount += 1; |
| 25805 |
if (!jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.IS_PROD && this.__callChangeCount > 4) { |
| 25806 |
console.warn('Too many recursive changes', new_value, old_value); |
| 25807 |
} |
| 25808 |
try { |
| 25809 |
// @ts-ignore Internal method |
| 25810 |
this.history.__upTick(); |
| 25811 |
this.e.fire('change', new_value, old_value); |
| 25812 |
this.e.fire(this.history, 'change', new_value, old_value); |
| 25813 |
} finally{ |
| 25814 |
this.__callChangeCount = 0; |
| 25815 |
} |
| 25816 |
} |
| 25817 |
} |
| 25818 |
/** |
| 25819 |
* If some plugin changes the DOM directly, then you need to update the content of the original element |
| 25820 |
*/ updateElementValue() { |
| 25821 |
this.__setElementValue(this.getEditorValue()); |
| 25822 |
} |
| 25823 |
/** |
| 25824 |
* Return source element value |
| 25825 |
*/ getElementValue() { |
| 25826 |
return this.element.value !== undefined ? this.element.value : this.element.innerHTML; |
| 25827 |
} |
| 25828 |
__setElementValue(value) { |
| 25829 |
if (!(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.isString)(value)) { |
| 25830 |
throw (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.error)('value must be string'); |
| 25831 |
} |
| 25832 |
if (this.element !== this.container && value !== this.getElementValue()) { |
| 25833 |
const data = { |
| 25834 |
value |
| 25835 |
}; |
| 25836 |
const res = this.e.fire('beforeSetElementValue', data); |
| 25837 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.callPromise)(res, ()=>{ |
| 25838 |
if (this.element.value !== undefined) { |
| 25839 |
this.element.value = data.value; |
| 25840 |
} else { |
| 25841 |
this.element.innerHTML = data.value; |
| 25842 |
} |
| 25843 |
this.e.fire('afterSetElementValue', data); |
| 25844 |
}); |
| 25845 |
} |
| 25846 |
} |
| 25847 |
/** |
| 25848 |
* Register custom handler for command |
| 25849 |
* |
| 25850 |
* @example |
| 25851 |
* ```javascript |
| 25852 |
* var jodit = Jodit.make('#editor); |
| 25853 |
* |
| 25854 |
* jodit.setEditorValue('test test test'); |
| 25855 |
* |
| 25856 |
* jodit.registerCommand('replaceString', function (command, needle, replace) { |
| 25857 |
* var value = this.getEditorValue(); |
| 25858 |
* this.setEditorValue(value.replace(needle, replace)); |
| 25859 |
* return false; // stop execute native command |
| 25860 |
* }); |
| 25861 |
* |
| 25862 |
* jodit.execCommand('replaceString', 'test', 'stop'); |
| 25863 |
* |
| 25864 |
* console.log(jodit.value); // stop test |
| 25865 |
* |
| 25866 |
* // and you can add hotkeys for command |
| 25867 |
* jodit.registerCommand('replaceString', { |
| 25868 |
* hotkeys: 'ctrl+r', |
| 25869 |
* exec: function (command, needle, replace) { |
| 25870 |
* var value = this.getEditorValue(); |
| 25871 |
* this.setEditorValue(value.replace(needle, replace)); |
| 25872 |
* } |
| 25873 |
* }); |
| 25874 |
* |
| 25875 |
* ``` |
| 25876 |
*/ registerCommand(commandNameOriginal, command, options) { |
| 25877 |
const commandName = commandNameOriginal.toLowerCase(); |
| 25878 |
let commands = this.commands.get(commandName); |
| 25879 |
if (commands === undefined) { |
| 25880 |
commands = []; |
| 25881 |
this.commands.set(commandName, commands); |
| 25882 |
} |
| 25883 |
commands.push(command); |
| 25884 |
if (!(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.isFunction)(command)) { |
| 25885 |
const hotkeys = this.o.commandToHotkeys[commandName] || this.o.commandToHotkeys[commandNameOriginal] || command.hotkeys; |
| 25886 |
if (hotkeys) { |
| 25887 |
this.registerHotkeyToCommand(hotkeys, commandName, options === null || options === void 0 ? void 0 : options.stopPropagation); |
| 25888 |
} |
| 25889 |
} |
| 25890 |
return this; |
| 25891 |
} |
| 25892 |
/** |
| 25893 |
* Register hotkey for command |
| 25894 |
*/ registerHotkeyToCommand(hotkeys, commandName, shouldStop = true) { |
| 25895 |
const shortcuts = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.asArray)(hotkeys).map(jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.normalizeKeyAliases).map((hotkey)=>hotkey + '.hotkey').join(' '); |
| 25896 |
this.e.off(shortcuts).on(shortcuts, (type, stop)=>{ |
| 25897 |
if (stop) { |
| 25898 |
stop.shouldStop = shouldStop !== null && shouldStop !== void 0 ? shouldStop : true; |
| 25899 |
} |
| 25900 |
return this.execCommand(commandName); // because need `beforeCommand` |
| 25901 |
}); |
| 25902 |
} |
| 25903 |
/** |
| 25904 |
* Execute command editor |
| 25905 |
* |
| 25906 |
* @param command - command. It supports all the |
| 25907 |
* @see https://developer.mozilla.org/ru/docs/Web/API/Document/execCommand#commands and a number of its own |
| 25908 |
* for example applyStyleProperty. Comand fontSize receives the second parameter px, |
| 25909 |
* formatBlock and can take several options |
| 25910 |
* @example |
| 25911 |
* ```javascript |
| 25912 |
* this.execCommand('fontSize', 12); // sets the size of 12 px |
| 25913 |
* this.execCommand('underline'); |
| 25914 |
* this.execCommand('formatBlock', 'p'); // will be inserted paragraph |
| 25915 |
* ``` |
| 25916 |
*/ execCommand(command, showUI, value, ...args) { |
| 25917 |
if (!this.s.isFocused()) { |
| 25918 |
this.s.focus(); |
| 25919 |
} |
| 25920 |
if (this.o.readonly && !this.o.allowCommandsInReadOnly.includes(command)) { |
| 25921 |
return; |
| 25922 |
} |
| 25923 |
let result; |
| 25924 |
command = command.toLowerCase(); |
| 25925 |
/** |
| 25926 |
* Called before any command |
| 25927 |
* @param command - Command name in lowercase |
| 25928 |
* @param second - The second parameter for the command |
| 25929 |
* @param third - The third option is for the team |
| 25930 |
* @example |
| 25931 |
* ```javascript |
| 25932 |
* parent.e.on('beforeCommand', function (command) { |
| 25933 |
* if (command === 'justifyCenter') { |
| 25934 |
* var p = parent.c.element('p') |
| 25935 |
* parent.s.insertNode(p) |
| 25936 |
* parent.s.setCursorIn(p); |
| 25937 |
* p.style.textAlign = 'justyfy'; |
| 25938 |
* return false; // break executes native command |
| 25939 |
* } |
| 25940 |
* }) |
| 25941 |
* ``` |
| 25942 |
*/ result = this.e.fire(`beforeCommand${(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.ucfirst)(command)}`, showUI, value, ...args); |
| 25943 |
if (result !== false) { |
| 25944 |
result = this.e.fire('beforeCommand', command, showUI, value, ...args); |
| 25945 |
} |
| 25946 |
if (result !== false) { |
| 25947 |
result = this.__execCustomCommands(command, showUI, value, ...args); |
| 25948 |
} |
| 25949 |
if (result !== false) { |
| 25950 |
this.s.focus(); |
| 25951 |
try { |
| 25952 |
result = this.nativeExecCommand(command, showUI, value); |
| 25953 |
} catch (e) { |
| 25954 |
if (!jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.IS_PROD) { |
| 25955 |
throw e; |
| 25956 |
} |
| 25957 |
} |
| 25958 |
} |
| 25959 |
/** |
| 25960 |
* It called after any command |
| 25961 |
* @param command - name command |
| 25962 |
* @param second - The second parameter for the command |
| 25963 |
* @param third - The third option is for the team |
| 25964 |
*/ this.e.fire('afterCommand', command, showUI, value); |
| 25965 |
this.__imdSynchronizeValues(); // synchrony |
| 25966 |
return result; |
| 25967 |
} |
| 25968 |
/** |
| 25969 |
* Exec native command |
| 25970 |
*/ nativeExecCommand(command, showUI, value) { |
| 25971 |
this.__isSilentChange = true; |
| 25972 |
try { |
| 25973 |
return this.ed.execCommand(command, showUI, value); |
| 25974 |
} finally{ |
| 25975 |
this.__isSilentChange = false; |
| 25976 |
} |
| 25977 |
} |
| 25978 |
__execCustomCommands(commandName, second, third, ...args) { |
| 25979 |
commandName = commandName.toLowerCase(); |
| 25980 |
const commands = this.commands.get(commandName); |
| 25981 |
if (commands !== undefined) { |
| 25982 |
let result; |
| 25983 |
commands.forEach((command)=>{ |
| 25984 |
let callback; |
| 25985 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.isFunction)(command)) { |
| 25986 |
callback = command; |
| 25987 |
} else { |
| 25988 |
callback = command.exec; |
| 25989 |
} |
| 25990 |
const resultCurrent = callback.call(this, commandName, second, third, ...args); |
| 25991 |
if (resultCurrent !== undefined) { |
| 25992 |
result = resultCurrent; |
| 25993 |
} |
| 25994 |
}); |
| 25995 |
return result; |
| 25996 |
} |
| 25997 |
} |
| 25998 |
/** |
| 25999 |
* Disable selecting |
| 26000 |
*/ lock(name = 'any') { |
| 26001 |
if (super.lock(name)) { |
| 26002 |
this.__selectionLocked = this.s.save(); |
| 26003 |
this.s.clear(); |
| 26004 |
this.container.classList.add('jodit_lock'); |
| 26005 |
this.e.fire('lock', true); |
| 26006 |
return true; |
| 26007 |
} |
| 26008 |
return false; |
| 26009 |
} |
| 26010 |
/** |
| 26011 |
* Enable selecting |
| 26012 |
*/ unlock() { |
| 26013 |
if (super.unlock()) { |
| 26014 |
this.container.classList.remove('jodit_lock'); |
| 26015 |
if (this.__selectionLocked) { |
| 26016 |
this.s.restore(); |
| 26017 |
} |
| 26018 |
this.e.fire('lock', false); |
| 26019 |
return true; |
| 26020 |
} |
| 26021 |
return false; |
| 26022 |
} |
| 26023 |
/** |
| 26024 |
* Return current editor mode: Jodit.MODE_WYSIWYG, Jodit.MODE_SOURCE or Jodit.MODE_SPLIT |
| 26025 |
*/ getMode() { |
| 26026 |
return this.mode; |
| 26027 |
} |
| 26028 |
isEditorMode() { |
| 26029 |
return this.getRealMode() === jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.MODE_WYSIWYG; |
| 26030 |
} |
| 26031 |
/** |
| 26032 |
* Return current real work mode. When editor in MODE_SOURCE or MODE_WYSIWYG it will |
| 26033 |
* return them, but then editor in MODE_SPLIT it will return MODE_SOURCE if |
| 26034 |
* Textarea(CodeMirror) focused or MODE_WYSIWYG otherwise |
| 26035 |
* |
| 26036 |
* @example |
| 26037 |
* ```javascript |
| 26038 |
* var editor = Jodit.make('#editor'); |
| 26039 |
* console.log(editor.getRealMode()); |
| 26040 |
* ``` |
| 26041 |
*/ getRealMode() { |
| 26042 |
if (this.getMode() !== jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.MODE_SPLIT) { |
| 26043 |
return this.getMode(); |
| 26044 |
} |
| 26045 |
const active = this.od.activeElement; |
| 26046 |
if (active && (active === this.iframe || jodit_modules__WEBPACK_IMPORTED_MODULE_10__.Dom.isOrContains(this.editor, active) || jodit_modules__WEBPACK_IMPORTED_MODULE_10__.Dom.isOrContains(this.toolbar.container, active))) { |
| 26047 |
return jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.MODE_WYSIWYG; |
| 26048 |
} |
| 26049 |
return jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.MODE_SOURCE; |
| 26050 |
} |
| 26051 |
/** |
| 26052 |
* Set current mode |
| 26053 |
*/ setMode(mode) { |
| 26054 |
const oldMode = this.getMode(); |
| 26055 |
const data = { |
| 26056 |
mode: parseInt(mode.toString(), 10) |
| 26057 |
}, modeClasses = [ |
| 26058 |
'jodit-wysiwyg_mode', |
| 26059 |
'jodit-source__mode', |
| 26060 |
'jodit_split_mode' |
| 26061 |
]; |
| 26062 |
/** |
| 26063 |
* Triggered before setMode executed. If returned false method stopped |
| 26064 |
* @param data - PlainObject `{mode: {string}}` In handler you can change data.mode |
| 26065 |
* @example |
| 26066 |
* ```javascript |
| 26067 |
* var editor = Jodit.make("#redactor"); |
| 26068 |
* editor.e.on('beforeSetMode', function (data) { |
| 26069 |
* data.mode = Jodit.MODE_SOURCE; // not respond to the mode change. Always make the source code mode |
| 26070 |
* }); |
| 26071 |
* ``` |
| 26072 |
*/ if (this.e.fire('beforeSetMode', data) === false) { |
| 26073 |
return; |
| 26074 |
} |
| 26075 |
this.__mode = [ |
| 26076 |
jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.MODE_SOURCE, |
| 26077 |
jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.MODE_WYSIWYG, |
| 26078 |
jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.MODE_SPLIT |
| 26079 |
].includes(data.mode) ? data.mode : jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.MODE_WYSIWYG; |
| 26080 |
if (this.o.saveModeInStorage) { |
| 26081 |
this.storage.set('jodit_default_mode', this.mode); |
| 26082 |
} |
| 26083 |
modeClasses.forEach((className)=>{ |
| 26084 |
this.container.classList.remove(className); |
| 26085 |
}); |
| 26086 |
this.container.classList.add(modeClasses[this.mode - 1]); |
| 26087 |
/** |
| 26088 |
* Triggered after setMode executed |
| 26089 |
* @example |
| 26090 |
* ```javascript |
| 26091 |
* var editor = Jodit.make("#redactor"); |
| 26092 |
* editor.e.on('afterSetMode', function () { |
| 26093 |
* editor.setEditorValue(''); // clear editor's value after change mode |
| 26094 |
* }); |
| 26095 |
* ``` |
| 26096 |
*/ if (oldMode !== this.getMode()) { |
| 26097 |
this.e.fire('afterSetMode'); |
| 26098 |
} |
| 26099 |
} |
| 26100 |
/** |
| 26101 |
* Toggle editor mode WYSIWYG to TEXTAREA(CodeMirror) to SPLIT(WYSIWYG and TEXTAREA) to again WYSIWYG |
| 26102 |
* |
| 26103 |
* @example |
| 26104 |
* ```javascript |
| 26105 |
* var editor = Jodit.make('#editor'); |
| 26106 |
* editor.toggleMode(); |
| 26107 |
* ``` |
| 26108 |
*/ toggleMode() { |
| 26109 |
let mode = this.getMode(); |
| 26110 |
if ([ |
| 26111 |
jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.MODE_SOURCE, |
| 26112 |
jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.MODE_WYSIWYG, |
| 26113 |
this.o.useSplitMode ? jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.MODE_SPLIT : 9 |
| 26114 |
].includes(mode + 1)) { |
| 26115 |
mode += 1; |
| 26116 |
} else { |
| 26117 |
mode = jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.MODE_WYSIWYG; |
| 26118 |
} |
| 26119 |
this.setMode(mode); |
| 26120 |
} |
| 26121 |
/** |
| 26122 |
* Switch on/off the editor into the disabled state. |
| 26123 |
* When disabled, the user is not able to change the editor content |
| 26124 |
* This function firing the `disabled` event. |
| 26125 |
*/ setDisabled(isDisabled) { |
| 26126 |
this.o.disabled = isDisabled; |
| 26127 |
const readOnly = this.__wasReadOnly; |
| 26128 |
this.setReadOnly(isDisabled || readOnly); |
| 26129 |
this.__wasReadOnly = readOnly; |
| 26130 |
if (this.editor) { |
| 26131 |
this.editor.setAttribute('aria-disabled', isDisabled.toString()); |
| 26132 |
this.container.classList.toggle('jodit_disabled', isDisabled); |
| 26133 |
this.e.fire('disabled', isDisabled); |
| 26134 |
} |
| 26135 |
} |
| 26136 |
/** |
| 26137 |
* Return true if editor in disabled mode |
| 26138 |
*/ getDisabled() { |
| 26139 |
return this.o.disabled; |
| 26140 |
} |
| 26141 |
/** |
| 26142 |
* Switch on/off the editor into the read-only state. |
| 26143 |
* When in readonly, the user is not able to change the editor content, but can still |
| 26144 |
* use some editor functions (show source code, print content, or seach). |
| 26145 |
* This function firing the `readonly` event. |
| 26146 |
*/ setReadOnly(isReadOnly) { |
| 26147 |
if (this.__wasReadOnly === isReadOnly) { |
| 26148 |
return; |
| 26149 |
} |
| 26150 |
this.__wasReadOnly = isReadOnly; |
| 26151 |
this.o.readonly = isReadOnly; |
| 26152 |
if (isReadOnly) { |
| 26153 |
this.editor && this.editor.removeAttribute('contenteditable'); |
| 26154 |
} else { |
| 26155 |
this.editor && this.editor.setAttribute('contenteditable', 'true'); |
| 26156 |
} |
| 26157 |
this.e && this.e.fire('readonly', isReadOnly); |
| 26158 |
} |
| 26159 |
/** |
| 26160 |
* Return true if editor in read-only mode |
| 26161 |
*/ getReadOnly() { |
| 26162 |
return this.o.readonly; |
| 26163 |
} |
| 26164 |
focus() { |
| 26165 |
if (this.getMode() !== jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.MODE_SOURCE) { |
| 26166 |
this.s.focus(); |
| 26167 |
} |
| 26168 |
} |
| 26169 |
get isFocused() { |
| 26170 |
return this.s.isFocused(); |
| 26171 |
} |
| 26172 |
/** |
| 26173 |
* Hook before init |
| 26174 |
*/ beforeInitHook() { |
| 26175 |
// do nothing |
| 26176 |
} |
| 26177 |
/** |
| 26178 |
* Hook after init |
| 26179 |
*/ afterInitHook() { |
| 26180 |
// do nothing |
| 26181 |
} |
| 26182 |
/** @override **/ initOptions(options) { |
| 26183 |
this.options = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.ConfigProto)(options || {}, jodit_config__WEBPACK_IMPORTED_MODULE_9__.Config.defaultOptions); |
| 26184 |
} |
| 26185 |
/** @override **/ initOwners() { |
| 26186 |
// in iframe, it can be changed |
| 26187 |
this.editorWindow = this.o.ownerWindow; |
| 26188 |
this.ownerWindow = this.o.ownerWindow; |
| 26189 |
} |
| 26190 |
/** |
| 26191 |
* Create and init current editable place |
| 26192 |
*/ addPlace(source, options) { |
| 26193 |
const element = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.resolveElement)(source, this.o.shadowRoot || this.od); |
| 26194 |
this.attachEvents(options); |
| 26195 |
if (element.attributes) { |
| 26196 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.toArray)(element.attributes).forEach((attr)=>{ |
| 26197 |
const name = attr.name; |
| 26198 |
let value = attr.value; |
| 26199 |
if (jodit_config__WEBPACK_IMPORTED_MODULE_9__.Config.defaultOptions[name] !== undefined && (!options || options[name] === undefined)) { |
| 26200 |
if ([ |
| 26201 |
'readonly', |
| 26202 |
'disabled' |
| 26203 |
].indexOf(name) !== -1) { |
| 26204 |
value = value === '' || value === 'true'; |
| 26205 |
} |
| 26206 |
if (/^[0-9]+(\.)?([0-9]+)?$/.test(value.toString())) { |
| 26207 |
value = Number(value); |
| 26208 |
} |
| 26209 |
this.options[name] = value; |
| 26210 |
} |
| 26211 |
}); |
| 26212 |
} |
| 26213 |
let container = this.c.div('jodit-container'); |
| 26214 |
container.classList.add('jodit'); |
| 26215 |
container.classList.add('jodit-container'); |
| 26216 |
container.classList.add(`jodit_theme_${this.o.theme || 'default'}`); |
| 26217 |
addClassNames(this.o.className, container); |
| 26218 |
if (this.o.containerStyle) { |
| 26219 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.css)(container, this.o.containerStyle); |
| 26220 |
} |
| 26221 |
const { styleValues } = this.o; |
| 26222 |
Object.keys(styleValues).forEach((key)=>{ |
| 26223 |
const property = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.kebabCase)(key); |
| 26224 |
container.style.setProperty(`--jd-${property}`, styleValues[key]); |
| 26225 |
}); |
| 26226 |
container.setAttribute('contenteditable', 'false'); |
| 26227 |
let buffer = null; |
| 26228 |
if (this.o.inline) { |
| 26229 |
if ([ |
| 26230 |
'TEXTAREA', |
| 26231 |
'INPUT' |
| 26232 |
].indexOf(element.nodeName) === -1) { |
| 26233 |
container = element; |
| 26234 |
element.setAttribute(__defaultClassesKey, element.className.toString()); |
| 26235 |
buffer = container.innerHTML; |
| 26236 |
container.innerHTML = ''; |
| 26237 |
} |
| 26238 |
container.classList.add('jodit_inline'); |
| 26239 |
container.classList.add('jodit-container'); |
| 26240 |
} |
| 26241 |
// actual for inline mode |
| 26242 |
if (element !== container) { |
| 26243 |
// hide source element |
| 26244 |
if (element.style.display) { |
| 26245 |
element.setAttribute(__defaultStyleDisplayKey, element.style.display); |
| 26246 |
} |
| 26247 |
element.style.display = 'none'; |
| 26248 |
} |
| 26249 |
const SLOT = 'workplace-slot'; |
| 26250 |
const topSlot = this.c.div(this.getFullElName(SLOT, 'top'), NOEDIT); |
| 26251 |
container.appendChild(topSlot); |
| 26252 |
const centerSlot = this.c.div(this.getFullElName(SLOT, 'center'), NOEDIT); |
| 26253 |
const workplace = this.c.div('jodit-workplace', NOEDIT); |
| 26254 |
const leftSlot = this.c.div(this.getFullElName(SLOT, 'left'), NOEDIT); |
| 26255 |
const rightSlot = this.c.div(this.getFullElName(SLOT, 'right'), NOEDIT); |
| 26256 |
centerSlot.appendChild(leftSlot); |
| 26257 |
centerSlot.appendChild(workplace); |
| 26258 |
centerSlot.appendChild(rightSlot); |
| 26259 |
container.appendChild(centerSlot); |
| 26260 |
const bottomPanel = this.c.div(this.getFullElName(SLOT, 'bottom'), NOEDIT); |
| 26261 |
container.appendChild(bottomPanel); |
| 26262 |
if (element.parentNode && element !== container) { |
| 26263 |
element.parentNode.insertBefore(container, element); |
| 26264 |
} |
| 26265 |
Object.defineProperty(element, 'component', { |
| 26266 |
enumerable: false, |
| 26267 |
configurable: true, |
| 26268 |
value: this |
| 26269 |
}); |
| 26270 |
const editor = this.c.div('jodit-wysiwyg', { |
| 26271 |
contenteditable: true, |
| 26272 |
'aria-disabled': false, |
| 26273 |
tabindex: this.o.tabIndex |
| 26274 |
}); |
| 26275 |
workplace.appendChild(editor); |
| 26276 |
const currentPlace = { |
| 26277 |
editor, |
| 26278 |
element, |
| 26279 |
container, |
| 26280 |
workplace, |
| 26281 |
slots: { |
| 26282 |
top: topSlot, |
| 26283 |
bottom: bottomPanel, |
| 26284 |
center: centerSlot, |
| 26285 |
left: leftSlot, |
| 26286 |
right: rightSlot |
| 26287 |
}, |
| 26288 |
statusbar: new jodit_modules__WEBPACK_IMPORTED_MODULE_10__.StatusBar(this, container), |
| 26289 |
options: this.isReady ? (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.ConfigProto)(options || {}, jodit_config__WEBPACK_IMPORTED_MODULE_9__.Config.defaultOptions) : this.options, |
| 26290 |
history: new jodit_modules__WEBPACK_IMPORTED_MODULE_10__.History(this), |
| 26291 |
editorWindow: this.ow |
| 26292 |
}; |
| 26293 |
this.__elementToPlace.set(editor, currentPlace); |
| 26294 |
this.setCurrentPlace(currentPlace); |
| 26295 |
this.places.push(currentPlace); |
| 26296 |
this.setNativeEditorValue(this.getElementValue()); // Init value |
| 26297 |
const initResult = this.__initEditor(buffer); |
| 26298 |
const opt = this.options; |
| 26299 |
const init = ()=>{ |
| 26300 |
if (opt.enableDragAndDropFileToEditor && opt.uploader && (opt.uploader.url || opt.uploader.insertImageAsBase64URI)) { |
| 26301 |
this.uploader.bind(this.editor); |
| 26302 |
} |
| 26303 |
// in initEditor - the editor could change |
| 26304 |
if (!this.__elementToPlace.get(this.editor)) { |
| 26305 |
this.__elementToPlace.set(this.editor, currentPlace); |
| 26306 |
} |
| 26307 |
this.e.fire('afterAddPlace', currentPlace); |
| 26308 |
}; |
| 26309 |
return (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.callPromise)(initResult, init); |
| 26310 |
} |
| 26311 |
addDisclaimer(elm) { |
| 26312 |
this.workplace.appendChild(elm); |
| 26313 |
} |
| 26314 |
/** |
| 26315 |
* Set current place object |
| 26316 |
*/ setCurrentPlace(place) { |
| 26317 |
if (this.currentPlace === place) { |
| 26318 |
return; |
| 26319 |
} |
| 26320 |
if (!this.isEditorMode()) { |
| 26321 |
this.setMode(jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.MODE_WYSIWYG); |
| 26322 |
} |
| 26323 |
this.currentPlace = place; |
| 26324 |
this.buildToolbar(); |
| 26325 |
if (this.isReady) { |
| 26326 |
this.e.fire('changePlace', place); |
| 26327 |
} |
| 26328 |
} |
| 26329 |
__initEditor(buffer) { |
| 26330 |
const result = this.__createEditor(); |
| 26331 |
return (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.callPromise)(result, ()=>{ |
| 26332 |
if (this.isInDestruct) { |
| 26333 |
return; |
| 26334 |
} |
| 26335 |
// syncro |
| 26336 |
if (this.element !== this.container) { |
| 26337 |
const value = this.getElementValue(); |
| 26338 |
if (value !== this.getEditorValue()) { |
| 26339 |
this.setEditorValue(value); |
| 26340 |
} |
| 26341 |
} else { |
| 26342 |
buffer != null && this.setEditorValue(buffer); // inline mode |
| 26343 |
} |
| 26344 |
let mode = this.o.defaultMode; |
| 26345 |
if (this.o.saveModeInStorage) { |
| 26346 |
const localMode = this.storage.get('jodit_default_mode'); |
| 26347 |
if (typeof localMode === 'string') { |
| 26348 |
mode = parseInt(localMode, 10); |
| 26349 |
} |
| 26350 |
} |
| 26351 |
this.setMode(mode); |
| 26352 |
if (this.o.readonly) { |
| 26353 |
this.__wasReadOnly = false; |
| 26354 |
this.setReadOnly(true); |
| 26355 |
} |
| 26356 |
if (this.o.disabled) { |
| 26357 |
this.setDisabled(true); |
| 26358 |
} |
| 26359 |
// if enter plugin isn't installed |
| 26360 |
try { |
| 26361 |
this.ed.execCommand('defaultParagraphSeparator', false, this.o.enter.toLowerCase()); |
| 26362 |
} catch (unused) {} |
| 26363 |
}); |
| 26364 |
} |
| 26365 |
/** |
| 26366 |
* Create main DIV element and replace source textarea |
| 26367 |
*/ __createEditor() { |
| 26368 |
const defaultEditorArea = this.editor; |
| 26369 |
const stayDefault = this.e.fire('createEditor', this); |
| 26370 |
return (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.callPromise)(stayDefault, ()=>{ |
| 26371 |
if (this.isInDestruct) { |
| 26372 |
return; |
| 26373 |
} |
| 26374 |
if (stayDefault === false || (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.isPromise)(stayDefault)) { |
| 26375 |
jodit_modules__WEBPACK_IMPORTED_MODULE_10__.Dom.safeRemove(defaultEditorArea); |
| 26376 |
} |
| 26377 |
addClassNames(this.o.editorClassName, this.editor); |
| 26378 |
if (this.o.style) { |
| 26379 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.css)(this.editor, this.o.style); |
| 26380 |
} |
| 26381 |
this.e.on('synchro', ()=>{ |
| 26382 |
this.setEditorValue(); |
| 26383 |
}).on('focus', ()=>{ |
| 26384 |
this.editorIsActive = true; |
| 26385 |
}).on('blur', ()=>this.editorIsActive = false); |
| 26386 |
this.__prepareWYSIWYGEditor(); |
| 26387 |
if (this.o.triggerChangeEvent) { |
| 26388 |
this.e.on('change', this.async.debounce(()=>{ |
| 26389 |
this.e && this.e.fire(this.element, 'change'); |
| 26390 |
}, this.defaultTimeout)); |
| 26391 |
} |
| 26392 |
}); |
| 26393 |
} |
| 26394 |
/** |
| 26395 |
* Attach some native event listeners |
| 26396 |
*/ __prepareWYSIWYGEditor() { |
| 26397 |
const { editor } = this; |
| 26398 |
// direction |
| 26399 |
if (this.o.direction) { |
| 26400 |
const direction = this.o.direction.toLowerCase() === 'rtl' ? 'rtl' : 'ltr'; |
| 26401 |
this.editor.style.direction = direction; |
| 26402 |
this.editor.setAttribute('dir', direction); |
| 26403 |
this.container.style.direction = direction; |
| 26404 |
this.container.setAttribute('dir', direction); |
| 26405 |
this.toolbar.setDirection(direction); |
| 26406 |
} |
| 26407 |
// proxy events |
| 26408 |
this.e.on(editor, 'mousedown touchstart focus', ()=>{ |
| 26409 |
const place = this.__elementToPlace.get(editor); |
| 26410 |
if (place) { |
| 26411 |
this.setCurrentPlace(place); |
| 26412 |
} |
| 26413 |
}).on(editor, 'compositionend', this.synchronizeValues).on(editor, 'selectionchange selectionstart keydown keyup input keypress dblclick mousedown mouseup ' + 'click copy cut dragstart drop dragover paste resize touchstart touchend focus blur', (event)=>{ |
| 26414 |
if (this.o.readonly || this.__isSilentChange) { |
| 26415 |
return; |
| 26416 |
} |
| 26417 |
const w = this.ew; |
| 26418 |
if (event instanceof w.KeyboardEvent && event.isComposing) { |
| 26419 |
return; |
| 26420 |
} |
| 26421 |
if (this.e && this.e.fire) { |
| 26422 |
if (this.e.fire(event.type, event) === false) { |
| 26423 |
return false; |
| 26424 |
} |
| 26425 |
this.synchronizeValues(); |
| 26426 |
} |
| 26427 |
}); |
| 26428 |
} |
| 26429 |
fetch(url, options) { |
| 26430 |
const ajax = new jodit_core_request__WEBPACK_IMPORTED_MODULE_7__.Ajax((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_1__._)({ |
| 26431 |
url |
| 26432 |
}, options), this.o.defaultAjaxOptions); |
| 26433 |
const destroy = ()=>{ |
| 26434 |
this.e.off('beforeDestruct', destroy); |
| 26435 |
this.progressbar.progress(100).hide(); |
| 26436 |
ajax.destruct(); |
| 26437 |
}; |
| 26438 |
this.e.one('beforeDestruct', destroy); |
| 26439 |
this.progressbar.show().progress(30); |
| 26440 |
const promise = ajax.send(); |
| 26441 |
promise.finally(destroy).catch(()=>null); |
| 26442 |
return promise; |
| 26443 |
} |
| 26444 |
/** |
| 26445 |
* Jodit's Destructor. Remove editor, and return source input |
| 26446 |
*/ destruct() { |
| 26447 |
var _cached, _cached1; |
| 26448 |
if (this.isInDestruct) { |
| 26449 |
return; |
| 26450 |
} |
| 26451 |
this.setStatus(jodit_modules__WEBPACK_IMPORTED_MODULE_10__.STATUSES.beforeDestruct); |
| 26452 |
this.__elementToPlace.clear(); |
| 26453 |
(_cached = (0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__.cached)(this, 'storage')) === null || _cached === void 0 ? void 0 : _cached.clear(); |
| 26454 |
(_cached1 = (0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__.cached)(this, 'buffer')) === null || _cached1 === void 0 ? void 0 : _cached1.clear(); |
| 26455 |
this.commands.clear(); |
| 26456 |
this.__selectionLocked = null; |
| 26457 |
this.e.off(this.ow, 'resize'); |
| 26458 |
this.e.off(this.ow); |
| 26459 |
this.e.off(this.od); |
| 26460 |
this.e.off(this.od.body); |
| 26461 |
const tmpValue = this.editor ? this.getEditorValue() : ''; |
| 26462 |
this.places.forEach(({ container, workplace, statusbar, element, iframe, editor, history })=>{ |
| 26463 |
if (!element) { |
| 26464 |
return; |
| 26465 |
} |
| 26466 |
if (element !== container) { |
| 26467 |
if (element.hasAttribute(__defaultStyleDisplayKey)) { |
| 26468 |
const display = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.attr)(element, __defaultStyleDisplayKey); |
| 26469 |
if (display) { |
| 26470 |
element.style.display = display; |
| 26471 |
element.removeAttribute(__defaultStyleDisplayKey); |
| 26472 |
} |
| 26473 |
} else { |
| 26474 |
element.style.display = ''; |
| 26475 |
} |
| 26476 |
} else { |
| 26477 |
if (element.hasAttribute(__defaultClassesKey)) { |
| 26478 |
element.className = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.attr)(element, __defaultClassesKey) || ''; |
| 26479 |
element.removeAttribute(__defaultClassesKey); |
| 26480 |
} |
| 26481 |
} |
| 26482 |
if (element.hasAttribute('style') && !(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.attr)(element, 'style')) { |
| 26483 |
element.removeAttribute('style'); |
| 26484 |
} |
| 26485 |
statusbar.destruct(); |
| 26486 |
this.e.off(container); |
| 26487 |
this.e.off(element); |
| 26488 |
this.e.off(editor); |
| 26489 |
jodit_modules__WEBPACK_IMPORTED_MODULE_10__.Dom.safeRemove(workplace); |
| 26490 |
jodit_modules__WEBPACK_IMPORTED_MODULE_10__.Dom.safeRemove(editor); |
| 26491 |
if (container !== element) { |
| 26492 |
jodit_modules__WEBPACK_IMPORTED_MODULE_10__.Dom.safeRemove(container); |
| 26493 |
} |
| 26494 |
Object.defineProperty(element, 'component', { |
| 26495 |
enumerable: false, |
| 26496 |
configurable: true, |
| 26497 |
value: null |
| 26498 |
}); |
| 26499 |
jodit_modules__WEBPACK_IMPORTED_MODULE_10__.Dom.safeRemove(iframe); |
| 26500 |
// inline mode |
| 26501 |
if (container === element) { |
| 26502 |
element.innerHTML = tmpValue; |
| 26503 |
} |
| 26504 |
history.destruct(); |
| 26505 |
}); |
| 26506 |
this.places.length = 0; |
| 26507 |
this.currentPlace = {}; |
| 26508 |
delete jodit_core_global__WEBPACK_IMPORTED_MODULE_5__.instances[this.id]; |
| 26509 |
super.destruct(); |
| 26510 |
} |
| 26511 |
/** |
| 26512 |
* Create instance of Jodit |
| 26513 |
* |
| 26514 |
* @param element - Selector or HTMLElement |
| 26515 |
* @param options - Editor's options |
| 26516 |
*/ constructor(element, options){ |
| 26517 |
super(options, true), /** |
| 26518 |
* Define if object is Jodit |
| 26519 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "isJodit", true), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "commands", new Map()), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__selectionLocked", null), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__wasReadOnly", false), /** |
| 26520 |
* Editor has focus in this time |
| 26521 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "editorIsActive", false), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "selection", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__mode", jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.MODE_WYSIWYG), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__callChangeCount", 0), /** |
| 26522 |
* Don't raise a change event |
| 26523 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__isSilentChange", false), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "currentPlace", { |
| 26524 |
options: this.__options, |
| 26525 |
container: this.__container |
| 26526 |
}), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "places", []), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__elementToPlace", new Map()); |
| 26527 |
try { |
| 26528 |
const elementSource = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.resolveElement)(element, this.options.shadowRoot || this.od); |
| 26529 |
if (Jodit.isJoditAssigned(elementSource)) { |
| 26530 |
// @ts-ignore |
| 26531 |
return elementSource.component; |
| 26532 |
} |
| 26533 |
} catch (e) { |
| 26534 |
if (!jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.IS_PROD) { |
| 26535 |
throw e; |
| 26536 |
} |
| 26537 |
this.destruct(); |
| 26538 |
throw e; |
| 26539 |
} |
| 26540 |
this.setStatus(jodit_modules__WEBPACK_IMPORTED_MODULE_10__.STATUSES.beforeInit); |
| 26541 |
this.id = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.attr)((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.resolveElement)(element, this.o.shadowRoot || this.od), 'id') || new Date().getTime().toString(); |
| 26542 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_5__.instances[this.id] = this; |
| 26543 |
this.attachEvents(options); |
| 26544 |
this.e.on(this.ow, 'resize', ()=>{ |
| 26545 |
if (this.e) { |
| 26546 |
this.e.fire('resize'); |
| 26547 |
} |
| 26548 |
}); |
| 26549 |
this.e.on('prepareWYSIWYGEditor', this.__prepareWYSIWYGEditor); |
| 26550 |
this.selection = new jodit_modules__WEBPACK_IMPORTED_MODULE_10__.Selection(this); |
| 26551 |
const beforeInitHookResult = this.beforeInitHook(); |
| 26552 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.callPromise)(beforeInitHookResult, ()=>{ |
| 26553 |
if (this.isInDestruct) { |
| 26554 |
return; |
| 26555 |
} |
| 26556 |
this.e.fire('beforeInit', this); |
| 26557 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_5__.pluginSystem.__init(this); |
| 26558 |
this.e.fire('afterPluginSystemInit', this); |
| 26559 |
this.e.on('changePlace', ()=>{ |
| 26560 |
this.setReadOnly(this.o.readonly); |
| 26561 |
this.setDisabled(this.o.disabled); |
| 26562 |
}); |
| 26563 |
this.places.length = 0; |
| 26564 |
const addPlaceResult = this.addPlace(element, options); |
| 26565 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_5__.instances[this.id] = this; |
| 26566 |
const init = ()=>{ |
| 26567 |
if (this.isInDestruct) { |
| 26568 |
return; |
| 26569 |
} |
| 26570 |
if (this.e) { |
| 26571 |
this.e.fire('afterInit', this); |
| 26572 |
} |
| 26573 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.callPromise)(this.afterInitHook()); |
| 26574 |
this.setStatus(jodit_modules__WEBPACK_IMPORTED_MODULE_10__.STATUSES.ready); |
| 26575 |
this.e.fire('afterConstructor', this); |
| 26576 |
}; |
| 26577 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.callPromise)(addPlaceResult, init); |
| 26578 |
}); |
| 26579 |
} |
| 26580 |
} |
| 26581 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(Jodit, "fatMode", jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.FAT_MODE); |
| 26582 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(Jodit, "plugins", jodit_core_global__WEBPACK_IMPORTED_MODULE_5__.pluginSystem); |
| 26583 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(Jodit, "modules", jodit_core_global__WEBPACK_IMPORTED_MODULE_5__.modules); |
| 26584 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(Jodit, "ns", jodit_core_global__WEBPACK_IMPORTED_MODULE_5__.modules); |
| 26585 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(Jodit, "decorators", {}); |
| 26586 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(Jodit, "constants", jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__); |
| 26587 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(Jodit, "instances", jodit_core_global__WEBPACK_IMPORTED_MODULE_5__.instances); |
| 26588 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(Jodit, "lang", jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.lang); |
| 26589 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(Jodit, "core", { |
| 26590 |
Plugin: jodit_modules__WEBPACK_IMPORTED_MODULE_10__.Plugin |
| 26591 |
}); |
| 26592 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 26593 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__.cache |
| 26594 |
], Jodit.prototype, "createInside", null); |
| 26595 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 26596 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__.cache |
| 26597 |
], Jodit.prototype, "message", null); |
| 26598 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 26599 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__.cache |
| 26600 |
], Jodit.prototype, "s", null); |
| 26601 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 26602 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__.cache |
| 26603 |
], Jodit.prototype, "uploader", null); |
| 26604 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 26605 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__.cache |
| 26606 |
], Jodit.prototype, "filebrowser", null); |
| 26607 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 26608 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__.throttle)() |
| 26609 |
], Jodit.prototype, "synchronizeValues", null); |
| 26610 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 26611 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__.watch)(':internalChange') |
| 26612 |
], Jodit.prototype, "updateElementValue", null); |
| 26613 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 26614 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__.autobind |
| 26615 |
], Jodit.prototype, "__prepareWYSIWYGEditor", null); |
| 26616 |
Jodit = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 26617 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__.derive)(jodit_core_traits_dlgs__WEBPACK_IMPORTED_MODULE_8__.Dlgs) |
| 26618 |
], Jodit); |
| 26619 |
function addClassNames(className, elm) { |
| 26620 |
if (className) { |
| 26621 |
className.split(/\s+/).forEach((cn)=>elm.classList.add(cn)); |
| 26622 |
} |
| 26623 |
} |
| 26624 |
|
| 26625 |
|
| 26626 |
/***/ }), |
| 26627 |
|
| 26628 |
/***/ 73533: |
| 26629 |
/***/ (function(module) { |
| 26630 |
|
| 26631 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M503 1271l-256 256q-10 9-23 9-12 0-23-9-9-10-9-23t9-23l256-256q10-9 23-9t23 9q9 10 9 23t-9 23zm169 41v320q0 14-9 23t-23 9-23-9-9-23v-320q0-14 9-23t23-9 23 9 9 23zm-224-224q0 14-9 23t-23 9h-320q-14 0-23-9t-9-23 9-23 23-9h320q14 0 23 9t9 23zm1264 128q0 120-85 203l-147 146q-83 83-203 83-121 0-204-85l-334-335q-21-21-42-56l239-18 273 274q27 27 68 27.5t68-26.5l147-146q28-28 28-67 0-40-28-68l-274-275 18-239q35 21 56 42l336 336q84 86 84 204zm-617-724l-239 18-273-274q-28-28-68-28-39 0-68 27l-147 146q-28 28-28 67 0 40 28 68l274 274-18 240q-35-21-56-42l-336-336q-84-86-84-204 0-120 85-203l147-146q83-83 203-83 121 0 204 85l334 335q21 21 42 56zm633 84q0 14-9 23t-23 9h-320q-14 0-23-9t-9-23 9-23 23-9h320q14 0 23 9t9 23zm-544-544v320q0 14-9 23t-23 9-23-9-9-23v-320q0-14 9-23t23-9 23 9 9 23zm407 151l-256 256q-11 9-23 9t-23-9q-9-10-9-23t9-23l256-256q10-9 23-9t23 9q9 10 9 23t-9 23z\"/> </svg>" |
| 26632 |
|
| 26633 |
/***/ }), |
| 26634 |
|
| 26635 |
/***/ 73714: |
| 26636 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 26637 |
|
| 26638 |
"use strict"; |
| 26639 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 26640 |
/* harmony export */ Ajax: function() { return /* reexport safe */ _ajax__WEBPACK_IMPORTED_MODULE_0__.Ajax; }, |
| 26641 |
/* harmony export */ Response: function() { return /* reexport safe */ _response__WEBPACK_IMPORTED_MODULE_1__.Response; } |
| 26642 |
/* harmony export */ }); |
| 26643 |
/* harmony import */ var _ajax__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(17338); |
| 26644 |
/* harmony import */ var _response__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(32855); |
| 26645 |
/*! |
| 26646 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 26647 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 26648 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 26649 |
*/ /** |
| 26650 |
* @module request |
| 26651 |
*/ |
| 26652 |
|
| 26653 |
|
| 26654 |
|
| 26655 |
/***/ }), |
| 26656 |
|
| 26657 |
/***/ 74103: |
| 26658 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 26659 |
|
| 26660 |
"use strict"; |
| 26661 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 26662 |
/* harmony export */ Prompt: function() { return /* binding */ Prompt; } |
| 26663 |
/* harmony export */ }); |
| 26664 |
/* harmony import */ var jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(91565); |
| 26665 |
/* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(7909); |
| 26666 |
/* harmony import */ var jodit_core_ui_button_button_button__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(53681); |
| 26667 |
/* harmony import */ var _dialog__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(76841); |
| 26668 |
/*! |
| 26669 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 26670 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 26671 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 26672 |
*/ /** |
| 26673 |
* @module modules/dialog |
| 26674 |
*/ |
| 26675 |
|
| 26676 |
|
| 26677 |
|
| 26678 |
/** |
| 26679 |
* Show `Prompt` dialog. Work without Jodit object |
| 26680 |
* |
| 26681 |
* @param msg - Dialog content |
| 26682 |
* @param title - Title or callback |
| 26683 |
* @param callback - callback. The first argument is the value entered |
| 26684 |
* @param placeholder - Placeholder for input |
| 26685 |
* @example |
| 26686 |
* ```javascript |
| 26687 |
* Jodit.Prompt("Enter your name", "Prompt Dialog", function (name) { |
| 26688 |
* if (name.length < 3) { |
| 26689 |
* Jodit.Alert("The name must be at least 3 letters"); |
| 26690 |
* return false; |
| 26691 |
* } |
| 26692 |
* // do something |
| 26693 |
* }); |
| 26694 |
* ``` |
| 26695 |
*/ function Prompt(msg, title, callback, placeholder, defaultValue) { |
| 26696 |
const dialog = this instanceof _dialog__WEBPACK_IMPORTED_MODULE_3__.Dialog ? this : new _dialog__WEBPACK_IMPORTED_MODULE_3__.Dialog({ |
| 26697 |
closeOnClickOverlay: true |
| 26698 |
}), cancelButton = (0,jodit_core_ui_button_button_button__WEBPACK_IMPORTED_MODULE_2__.Button)(dialog, 'cancel', 'Cancel'), okButton = (0,jodit_core_ui_button_button_button__WEBPACK_IMPORTED_MODULE_2__.Button)(dialog, 'ok', 'Ok'), form = dialog.c.element('form', { |
| 26699 |
class: 'jodit-dialog_prompt' |
| 26700 |
}), inputElement = dialog.c.element('input', { |
| 26701 |
autofocus: true, |
| 26702 |
class: 'jodit-input' |
| 26703 |
}), labelElement = dialog.c.element('label'); |
| 26704 |
if ((0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_0__.isFunction)(title)) { |
| 26705 |
callback = title; |
| 26706 |
title = undefined; |
| 26707 |
} |
| 26708 |
if (placeholder) { |
| 26709 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(inputElement, 'placeholder', placeholder); |
| 26710 |
} |
| 26711 |
labelElement.appendChild(dialog.c.text(msg)); |
| 26712 |
form.appendChild(labelElement); |
| 26713 |
form.appendChild(inputElement); |
| 26714 |
cancelButton.onAction(dialog.close); |
| 26715 |
const onclick = ()=>{ |
| 26716 |
if (!callback || !(0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_0__.isFunction)(callback) || callback(inputElement.value) !== false) { |
| 26717 |
dialog.close(); |
| 26718 |
} |
| 26719 |
}; |
| 26720 |
okButton.onAction(onclick); |
| 26721 |
dialog.e.on(form, 'submit', ()=>{ |
| 26722 |
onclick(); |
| 26723 |
return false; |
| 26724 |
}); |
| 26725 |
dialog.setFooter([ |
| 26726 |
okButton, |
| 26727 |
cancelButton |
| 26728 |
]); |
| 26729 |
dialog.open(form, title || ' ', true, true); |
| 26730 |
inputElement.focus(); |
| 26731 |
if (defaultValue !== undefined && defaultValue.length) { |
| 26732 |
inputElement.value = defaultValue; |
| 26733 |
inputElement.select(); |
| 26734 |
} |
| 26735 |
return dialog; |
| 26736 |
} |
| 26737 |
|
| 26738 |
|
| 26739 |
/***/ }), |
| 26740 |
|
| 26741 |
/***/ 74240: |
| 26742 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 26743 |
|
| 26744 |
"use strict"; |
| 26745 |
/* unused harmony export mobile */ |
| 26746 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(28077); |
| 26747 |
/* harmony import */ var jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(65946); |
| 26748 |
/* harmony import */ var jodit_core_ui_helpers_buttons__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2496); |
| 26749 |
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(3244); |
| 26750 |
/*! |
| 26751 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 26752 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 26753 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 26754 |
*/ /** |
| 26755 |
* [[include:plugins/mobile/README.md]] |
| 26756 |
* @packageDocumentation |
| 26757 |
* @module plugins/mobile |
| 26758 |
*/ |
| 26759 |
|
| 26760 |
|
| 26761 |
|
| 26762 |
/** |
| 26763 |
* Rebuild toolbar in depends on editor's width |
| 26764 |
*/ function mobile(editor) { |
| 26765 |
let timeout = 0, store = (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.splitArray)(editor.o.buttons); |
| 26766 |
if (editor.o.mobileTapTimeout) { |
| 26767 |
// Emulate double tap |
| 26768 |
editor.e.on('touchend', (e)=>{ |
| 26769 |
if (e.changedTouches && e.changedTouches.length) { |
| 26770 |
const now = new Date().getTime(), diff = now - timeout; |
| 26771 |
if (diff > editor.o.mobileTapTimeout) { |
| 26772 |
timeout = now; |
| 26773 |
if (diff < editor.o.mobileTapTimeout * 1.5) { |
| 26774 |
editor.s.insertCursorAtPoint(e.clientX, e.clientY); |
| 26775 |
} |
| 26776 |
} |
| 26777 |
} |
| 26778 |
}); |
| 26779 |
} |
| 26780 |
editor.e.on('getDiffButtons.mobile', (toolbar)=>{ |
| 26781 |
if (toolbar === editor.toolbar) { |
| 26782 |
const buttons = (0,jodit_core_ui_helpers_buttons__WEBPACK_IMPORTED_MODULE_2__.flatButtonsSet)((0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.splitArray)(editor.o.buttons), editor), flatStore = (0,jodit_core_ui_helpers_buttons__WEBPACK_IMPORTED_MODULE_2__.flatButtonsSet)(store, editor); |
| 26783 |
return (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.toArray)(buttons).reduce((acc, item)=>{ |
| 26784 |
if (!flatStore.has(item)) { |
| 26785 |
acc.push(item); |
| 26786 |
} |
| 26787 |
return acc; |
| 26788 |
}, []); |
| 26789 |
} |
| 26790 |
}); |
| 26791 |
if (editor.o.toolbarAdaptive) { |
| 26792 |
editor.e.on('resize afterInit recalcAdaptive changePlace afterAddPlace', ()=>{ |
| 26793 |
var _editor_container_parentElement; |
| 26794 |
if (!editor.o.toolbar) { |
| 26795 |
return; |
| 26796 |
} |
| 26797 |
const width = ((_editor_container_parentElement = editor.container.parentElement) !== null && _editor_container_parentElement !== void 0 ? _editor_container_parentElement : editor.container).offsetWidth; |
| 26798 |
const newStore = (()=>{ |
| 26799 |
if (editor.isFullSize || width >= editor.o.sizeLG) { |
| 26800 |
return (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.splitArray)(editor.o.buttons); |
| 26801 |
} |
| 26802 |
if (width >= editor.o.sizeMD) { |
| 26803 |
return (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.splitArray)(editor.o.buttonsMD); |
| 26804 |
} |
| 26805 |
if (width >= editor.o.sizeSM) { |
| 26806 |
return (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.splitArray)(editor.o.buttonsSM); |
| 26807 |
} |
| 26808 |
return (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_1__.splitArray)(editor.o.buttonsXS); |
| 26809 |
})(); |
| 26810 |
if (newStore.toString() !== store.toString()) { |
| 26811 |
var _editor_toolbar; |
| 26812 |
store = newStore; |
| 26813 |
editor.e.fire('closeAllPopups'); |
| 26814 |
(_editor_toolbar = editor.toolbar) === null || _editor_toolbar === void 0 ? void 0 : _editor_toolbar.setRemoveButtons(editor.o.removeButtons).build(store.concat(editor.o.extraButtons)); |
| 26815 |
} |
| 26816 |
}).on(editor.ow, 'load resize', ()=>editor.e.fire('recalcAdaptive')); |
| 26817 |
} |
| 26818 |
} |
| 26819 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_0__.pluginSystem.add('mobile', mobile); |
| 26820 |
|
| 26821 |
|
| 26822 |
/***/ }), |
| 26823 |
|
| 26824 |
/***/ 74264: |
| 26825 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 26826 |
|
| 26827 |
"use strict"; |
| 26828 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 26829 |
/* harmony export */ CamelCaseToKebabCase: function() { return /* binding */ CamelCaseToKebabCase; }, |
| 26830 |
/* harmony export */ kebabCase: function() { return /* binding */ kebabCase; } |
| 26831 |
/* harmony export */ }); |
| 26832 |
/*! |
| 26833 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 26834 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 26835 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 26836 |
*/ /** |
| 26837 |
* @module helpers/string |
| 26838 |
*/ const kebabCase = (key)=>{ |
| 26839 |
return key.replace(/([A-Z])([A-Z])([a-z])/g, '$1-$2$3').replace(/([a-z])([A-Z])/g, '$1-$2').replace(/[\s_]+/g, '-').toLowerCase(); |
| 26840 |
}; |
| 26841 |
const CamelCaseToKebabCase = (key)=>{ |
| 26842 |
return key.replace(/([A-Z])([A-Z])([a-z])/g, '$1-$2$3').replace(/([a-z])([A-Z])/g, '$1-$2').toLowerCase(); |
| 26843 |
}; |
| 26844 |
|
| 26845 |
|
| 26846 |
/***/ }), |
| 26847 |
|
| 26848 |
/***/ 74522: |
| 26849 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 26850 |
|
| 26851 |
"use strict"; |
| 26852 |
/* unused harmony export resizer */ |
| 26853 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 26854 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 26855 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(81937); |
| 26856 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(84839); |
| 26857 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(23211); |
| 26858 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(28077); |
| 26859 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(65946); |
| 26860 |
/* harmony import */ var jodit_core_plugin_plugin__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(18855); |
| 26861 |
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(96608); |
| 26862 |
/*! |
| 26863 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 26864 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 26865 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 26866 |
*/ /** |
| 26867 |
* [[include:plugins/resizer/README.md]] |
| 26868 |
* @packageDocumentation |
| 26869 |
* @module plugins/resizer |
| 26870 |
*/ |
| 26871 |
|
| 26872 |
|
| 26873 |
|
| 26874 |
|
| 26875 |
|
| 26876 |
|
| 26877 |
|
| 26878 |
|
| 26879 |
|
| 26880 |
|
| 26881 |
const keyBInd = '__jodit-resizer_binded'; |
| 26882 |
/** |
| 26883 |
* The module creates a supporting frame for resizing of the elements img and table |
| 26884 |
*/ class resizer extends jodit_core_plugin_plugin__WEBPACK_IMPORTED_MODULE_7__.Plugin { |
| 26885 |
/** @override */ afterInit(editor) { |
| 26886 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.$$)('div', this.rect).forEach((resizeHandle)=>{ |
| 26887 |
editor.e.on(resizeHandle, 'mousedown.resizer touchstart.resizer', this.onStartResizing.bind(this, resizeHandle)); |
| 26888 |
}); |
| 26889 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_5__.eventEmitter.on('hideHelpers', this.hide); |
| 26890 |
editor.e.on('readonly', (isReadOnly)=>{ |
| 26891 |
if (isReadOnly) { |
| 26892 |
this.hide(); |
| 26893 |
} |
| 26894 |
}).on('afterInit changePlace', this.addEventListeners.bind(this)).on('afterGetValueFromEditor.resizer', (data)=>{ |
| 26895 |
const rgx = /<jodit[^>]+data-jodit_iframe_wrapper[^>]+>(.*?<iframe[^>]*>.*?<\/iframe>.*?)<\/jodit>/gi; |
| 26896 |
if (rgx.test(data.value)) { |
| 26897 |
data.value = data.value.replace(rgx, '$1'); |
| 26898 |
} |
| 26899 |
}); |
| 26900 |
this.addEventListeners(); |
| 26901 |
this.__onChangeEditor(); |
| 26902 |
} |
| 26903 |
/** |
| 26904 |
* Click in the editor area |
| 26905 |
*/ onEditorClick(e) { |
| 26906 |
let node = e.target; |
| 26907 |
const { editor, options: { allowResizeTags } } = this.j; |
| 26908 |
while(node && node !== editor){ |
| 26909 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isTag(node, allowResizeTags)) { |
| 26910 |
this.__bind(node); |
| 26911 |
this.onClickElement(node); |
| 26912 |
return; |
| 26913 |
} |
| 26914 |
node = node.parentNode; |
| 26915 |
} |
| 26916 |
} |
| 26917 |
__afterInsertImage(image) { |
| 26918 |
if (this.j.o.resizer.forImageChangeAttributes) { |
| 26919 |
return; |
| 26920 |
} |
| 26921 |
const width = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.attr)(image, 'width'); |
| 26922 |
if (width && !(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.css)(image, 'width', true)) { |
| 26923 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.css)(image, 'width', width); |
| 26924 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.attr)(image, 'width', null); |
| 26925 |
} |
| 26926 |
} |
| 26927 |
addEventListeners() { |
| 26928 |
const editor = this.j; |
| 26929 |
editor.e.off(editor.editor, '.resizer').off(editor.ow, '.resizer').on(editor.editor, 'keydown.resizer', (e)=>{ |
| 26930 |
if (this.isShown && e.key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.KEY_DELETE && this.element && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isTag(this.element, 'table')) { |
| 26931 |
this.onDelete(e); |
| 26932 |
} |
| 26933 |
}).on(editor.ow, 'resize.resizer', this.updateSize).on('resize.resizer', this.updateSize).on([ |
| 26934 |
editor.ow, |
| 26935 |
editor.editor |
| 26936 |
], 'scroll.resizer', ()=>{ |
| 26937 |
if (this.isShown && !this.isResizeMode) { |
| 26938 |
this.hide(); |
| 26939 |
} |
| 26940 |
}).on(editor.ow, 'keydown.resizer', this.onKeyDown).on(editor.ow, 'keyup.resizer', this.onKeyUp).on(editor.ow, 'mouseup.resizer touchend.resizer', this.onClickOutside); |
| 26941 |
} |
| 26942 |
onStartResizing(resizeHandle, e) { |
| 26943 |
if (!this.element || !this.element.parentNode) { |
| 26944 |
this.hide(); |
| 26945 |
return false; |
| 26946 |
} |
| 26947 |
this.handle = resizeHandle; |
| 26948 |
if (e.cancelable) { |
| 26949 |
e.preventDefault(); |
| 26950 |
} |
| 26951 |
e.stopImmediatePropagation(); |
| 26952 |
this.width = this.element.offsetWidth; |
| 26953 |
this.height = this.element.offsetHeight; |
| 26954 |
this.ratio = this.width / this.height; |
| 26955 |
this.isResizeMode = true; |
| 26956 |
this.startX = e.clientX; |
| 26957 |
this.startY = e.clientY; |
| 26958 |
this.pointerX = e.clientX; |
| 26959 |
this.pointerY = e.clientY; |
| 26960 |
const { j } = this; |
| 26961 |
j.e.fire('hidePopup'); |
| 26962 |
j.lock(this.LOCK_KEY); |
| 26963 |
j.e.on(j.ow, 'mousemove.resizer touchmove.resizer', this.onResize); |
| 26964 |
} |
| 26965 |
onEndResizing() { |
| 26966 |
const { j } = this; |
| 26967 |
j.unlock(); |
| 26968 |
this.isResizeMode = false; |
| 26969 |
this.isAltMode = false; |
| 26970 |
j.synchronizeValues(); |
| 26971 |
j.e.off(j.ow, 'mousemove.resizer touchmove.resizer', this.onResize); |
| 26972 |
} |
| 26973 |
onResize(e) { |
| 26974 |
if (this.isResizeMode) { |
| 26975 |
if (!this.element) { |
| 26976 |
return; |
| 26977 |
} |
| 26978 |
this.pointerX = e.clientX; |
| 26979 |
this.pointerY = e.clientY; |
| 26980 |
let diff_x, diff_y; |
| 26981 |
if (this.j.options.iframe) { |
| 26982 |
const workplacePosition = this.getWorkplacePosition(); |
| 26983 |
diff_x = e.clientX + workplacePosition.left - this.startX; |
| 26984 |
diff_y = e.clientY + workplacePosition.top - this.startY; |
| 26985 |
} else { |
| 26986 |
diff_x = this.pointerX - this.startX; |
| 26987 |
diff_y = this.pointerY - this.startY; |
| 26988 |
} |
| 26989 |
const className = this.handle.className; |
| 26990 |
let new_w = 0, new_h = 0; |
| 26991 |
const uar = this.j.o.resizer.useAspectRatio; |
| 26992 |
if (!this.isAltMode && (uar === true || uar && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isTag(this.element, uar))) { |
| 26993 |
if (diff_x) { |
| 26994 |
new_w = this.width + (className.match(/left/) ? -1 : 1) * diff_x; |
| 26995 |
new_h = Math.round(new_w / this.ratio); |
| 26996 |
} else { |
| 26997 |
new_h = this.height + (className.match(/top/) ? -1 : 1) * diff_y; |
| 26998 |
new_w = Math.round(new_h * this.ratio); |
| 26999 |
} |
| 27000 |
if (new_w > (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.innerWidth)(this.j.editor, this.j.ow)) { |
| 27001 |
new_w = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.innerWidth)(this.j.editor, this.j.ow); |
| 27002 |
new_h = Math.round(new_w / this.ratio); |
| 27003 |
} |
| 27004 |
} else { |
| 27005 |
new_w = this.width + (className.match(/left/) ? -1 : 1) * diff_x; |
| 27006 |
new_h = this.height + (className.match(/top/) ? -1 : 1) * diff_y; |
| 27007 |
} |
| 27008 |
if (new_w > this.j.o.resizer.min_width) { |
| 27009 |
if (new_w < this.rect.parentNode.offsetWidth) { |
| 27010 |
this.applySize(this.element, 'width', new_w); |
| 27011 |
} else { |
| 27012 |
this.applySize(this.element, 'width', '100%'); |
| 27013 |
} |
| 27014 |
} |
| 27015 |
if (new_h > this.j.o.resizer.min_height) { |
| 27016 |
this.applySize(this.element, 'height', new_h); |
| 27017 |
} |
| 27018 |
this.updateSize(); |
| 27019 |
this.showSizeViewer(this.element.offsetWidth, this.element.offsetHeight); |
| 27020 |
e.stopImmediatePropagation(); |
| 27021 |
} |
| 27022 |
} |
| 27023 |
onKeyDown(e) { |
| 27024 |
this.isAltMode = e.key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.KEY_ALT; |
| 27025 |
if (!this.isAltMode && this.isResizeMode) { |
| 27026 |
this.onEndResizing(); |
| 27027 |
} |
| 27028 |
} |
| 27029 |
onKeyUp() { |
| 27030 |
if (this.isAltMode && this.isResizeMode && this.element) { |
| 27031 |
this.width = this.element.offsetWidth; |
| 27032 |
this.height = this.element.offsetHeight; |
| 27033 |
this.ratio = this.width / this.height; |
| 27034 |
this.startX = this.pointerX; |
| 27035 |
this.startY = this.pointerY; |
| 27036 |
} |
| 27037 |
this.isAltMode = false; |
| 27038 |
} |
| 27039 |
onClickOutside(e) { |
| 27040 |
if (!this.isShown) { |
| 27041 |
return; |
| 27042 |
} |
| 27043 |
if (!this.isResizeMode) { |
| 27044 |
return this.hide(); |
| 27045 |
} |
| 27046 |
e.stopImmediatePropagation(); |
| 27047 |
this.onEndResizing(); |
| 27048 |
} |
| 27049 |
getWorkplacePosition() { |
| 27050 |
return (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.offset)(this.rect.parentNode || this.j.od.documentElement, this.j, this.j.od, true); |
| 27051 |
} |
| 27052 |
applySize(element, key, value) { |
| 27053 |
const changeAttrs = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isImage(element) && this.j.o.resizer.forImageChangeAttributes; |
| 27054 |
if (changeAttrs) { |
| 27055 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.attr)(element, key, value); |
| 27056 |
} |
| 27057 |
if (!changeAttrs || element.style[key]) { |
| 27058 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.css)(element, key, value); |
| 27059 |
} |
| 27060 |
} |
| 27061 |
onDelete(e) { |
| 27062 |
if (!this.element) { |
| 27063 |
return; |
| 27064 |
} |
| 27065 |
if (this.element.tagName !== 'JODIT') { |
| 27066 |
this.j.s.select(this.element); |
| 27067 |
} else { |
| 27068 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeRemove(this.element); |
| 27069 |
this.hide(); |
| 27070 |
e.preventDefault(); |
| 27071 |
} |
| 27072 |
} |
| 27073 |
__onChangeEditor() { |
| 27074 |
if (this.isShown) { |
| 27075 |
if (!this.element || !this.element.parentNode) { |
| 27076 |
this.hide(); |
| 27077 |
} else { |
| 27078 |
this.updateSize(); |
| 27079 |
} |
| 27080 |
} |
| 27081 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.$$)('iframe', this.j.editor).forEach(this.__bind); |
| 27082 |
} |
| 27083 |
/** |
| 27084 |
* Bind an edit element to element |
| 27085 |
* @param element - The element that you want to add a function to resize |
| 27086 |
*/ __bind(element) { |
| 27087 |
if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isHTMLElement(element) || !this.j.o.allowResizeTags.has(element.tagName.toLowerCase()) || (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.dataBind)(element, keyBInd)) { |
| 27088 |
return; |
| 27089 |
} |
| 27090 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.dataBind)(element, keyBInd, true); |
| 27091 |
let wrapper; |
| 27092 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isTag(element, 'iframe')) { |
| 27093 |
const iframe = element; |
| 27094 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isHTMLElement(element.parentNode) && (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.attr)(element.parentNode, '-jodit_iframe_wrapper')) { |
| 27095 |
element = element.parentNode; |
| 27096 |
} else { |
| 27097 |
wrapper = this.j.createInside.element('jodit', { |
| 27098 |
'data-jodit-temp': 1, |
| 27099 |
contenteditable: false, |
| 27100 |
draggable: true, |
| 27101 |
'data-jodit_iframe_wrapper': 1 |
| 27102 |
}); |
| 27103 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.attr)(wrapper, 'style', (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.attr)(element, 'style')); |
| 27104 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.css)(wrapper, { |
| 27105 |
display: element.style.display === 'inline-block' ? 'inline-block' : 'block', |
| 27106 |
width: element.offsetWidth, |
| 27107 |
height: element.offsetHeight |
| 27108 |
}); |
| 27109 |
if (element.parentNode) { |
| 27110 |
element.parentNode.insertBefore(wrapper, element); |
| 27111 |
} |
| 27112 |
wrapper.appendChild(element); |
| 27113 |
this.j.e.on(wrapper, 'click', ()=>{ |
| 27114 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.attr)(wrapper, 'data-jodit-wrapper_active', true); |
| 27115 |
}); |
| 27116 |
element = wrapper; |
| 27117 |
} |
| 27118 |
this.j.e.off(element, 'mousedown.select touchstart.select').on(element, 'mousedown.select touchstart.select', ()=>{ |
| 27119 |
this.j.s.select(element); |
| 27120 |
}).off(element, 'changesize').on(element, 'changesize', ()=>{ |
| 27121 |
iframe.setAttribute('width', element.offsetWidth + 'px'); |
| 27122 |
iframe.setAttribute('height', element.offsetHeight + 'px'); |
| 27123 |
}); |
| 27124 |
} |
| 27125 |
this.j.e.on(element, 'dragstart', this.hide); |
| 27126 |
if (!jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.IS_ES_NEXT && jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.IS_IE) { |
| 27127 |
// for IE don't show native resizer |
| 27128 |
this.j.e.on(element, 'mousedown', (event)=>{ |
| 27129 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isTag(element, 'img')) { |
| 27130 |
event.preventDefault(); |
| 27131 |
} |
| 27132 |
}); |
| 27133 |
} |
| 27134 |
} |
| 27135 |
showSizeViewer(w, h) { |
| 27136 |
if (!this.j.o.resizer.showSize) { |
| 27137 |
return; |
| 27138 |
} |
| 27139 |
if (w < this.sizeViewer.offsetWidth || h < this.sizeViewer.offsetHeight) { |
| 27140 |
this.hideSizeViewer(); |
| 27141 |
return; |
| 27142 |
} |
| 27143 |
this.sizeViewer.style.opacity = '1'; |
| 27144 |
this.sizeViewer.textContent = `${w} x ${h}`; |
| 27145 |
this.j.async.setTimeout(this.hideSizeViewer, { |
| 27146 |
timeout: this.j.o.resizer.hideSizeTimeout, |
| 27147 |
label: 'hideSizeViewer' |
| 27148 |
}); |
| 27149 |
} |
| 27150 |
/** |
| 27151 |
* Show resizer |
| 27152 |
*/ show() { |
| 27153 |
if (this.j.o.readonly || this.isShown) { |
| 27154 |
return; |
| 27155 |
} |
| 27156 |
this.isShown = true; |
| 27157 |
if (!this.rect.parentNode) { |
| 27158 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.markOwner)(this.j, this.rect); |
| 27159 |
this.j.workplace.appendChild(this.rect); |
| 27160 |
} |
| 27161 |
if (this.j.isFullSize) { |
| 27162 |
this.rect.style.zIndex = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.css)(this.j.container, 'zIndex').toString(); |
| 27163 |
} |
| 27164 |
this.updateSize(); |
| 27165 |
} |
| 27166 |
/** |
| 27167 |
* Hide resizer |
| 27168 |
*/ hide() { |
| 27169 |
if (!this.isResizeMode) { |
| 27170 |
this.isResizeMode = false; |
| 27171 |
this.isShown = false; |
| 27172 |
this.element = null; |
| 27173 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeRemove(this.rect); |
| 27174 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.$$)("[data-jodit-wrapper_active='true']", this.j.editor).forEach((elm)=>(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.attr)(elm, 'data-jodit-wrapper_active', false)); |
| 27175 |
} |
| 27176 |
} |
| 27177 |
beforeDestruct(jodit) { |
| 27178 |
this.hide(); |
| 27179 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_5__.eventEmitter.off('hideHelpers', this.hide); |
| 27180 |
jodit.e.off(this.j.ow, '.resizer').off('.resizer'); |
| 27181 |
} |
| 27182 |
constructor(...args){ |
| 27183 |
super(...args), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "LOCK_KEY", 'resizer'), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "handle", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "element", null), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "isResizeMode", false), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "isShown", false), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "startX", 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "startY", 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "width", 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "height", 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "ratio", 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "rect", this.j.c.fromHTML(`<div title="${this.j.i18n('Press Alt for custom resizing')}" class="jodit-resizer"> |
| 27184 |
<div class="jodit-resizer__top-left"></div> |
| 27185 |
<div class="jodit-resizer__top-right"></div> |
| 27186 |
<div class="jodit-resizer__bottom-right"></div> |
| 27187 |
<div class="jodit-resizer__bottom-left"></div> |
| 27188 |
<span>100x100</span> |
| 27189 |
</div>`)), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "sizeViewer", this.rect.getElementsByTagName('span')[0]), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "pointerX", 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "pointerY", 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "isAltMode", false), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "onClickElement", (element)=>{ |
| 27190 |
if (this.isResizeMode) { |
| 27191 |
return; |
| 27192 |
} |
| 27193 |
if (this.element !== element || !this.isShown) { |
| 27194 |
this.element = element; |
| 27195 |
this.show(); |
| 27196 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isTag(this.element, 'img') && !this.element.complete) { |
| 27197 |
this.j.e.one(this.element, 'load', this.updateSize); |
| 27198 |
} |
| 27199 |
} |
| 27200 |
}), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "updateSize", ()=>{ |
| 27201 |
if (this.isInDestruct || !this.isShown) { |
| 27202 |
return; |
| 27203 |
} |
| 27204 |
if (this.element && this.rect) { |
| 27205 |
const workplacePosition = this.getWorkplacePosition(); |
| 27206 |
const pos = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.offset)(this.element, this.j, this.j.ed), left = parseInt(this.rect.style.left || '0', 10), top = parseInt(this.rect.style.top || '0', 10), w = this.rect.offsetWidth, h = this.rect.offsetHeight; |
| 27207 |
const newTop = pos.top - workplacePosition.top, newLeft = pos.left - workplacePosition.left; |
| 27208 |
if (top !== newTop || left !== newLeft || w !== this.element.offsetWidth || h !== this.element.offsetHeight) { |
| 27209 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.css)(this.rect, { |
| 27210 |
top: newTop, |
| 27211 |
left: newLeft, |
| 27212 |
width: this.element.offsetWidth, |
| 27213 |
height: this.element.offsetHeight |
| 27214 |
}); |
| 27215 |
if (this.j.events) { |
| 27216 |
this.j.e.fire(this.element, 'changesize'); |
| 27217 |
// check for first init. Ex. inlinePopup hides when it was fired |
| 27218 |
if (!isNaN(left)) { |
| 27219 |
this.j.e.fire('resize'); |
| 27220 |
} |
| 27221 |
} |
| 27222 |
} |
| 27223 |
} |
| 27224 |
}), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "hideSizeViewer", ()=>{ |
| 27225 |
this.sizeViewer.style.opacity = '0'; |
| 27226 |
}); |
| 27227 |
} |
| 27228 |
} |
| 27229 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 27230 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.watch)(':click') |
| 27231 |
], resizer.prototype, "onEditorClick", null); |
| 27232 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 27233 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.watch)(':afterInsertImage') |
| 27234 |
], resizer.prototype, "__afterInsertImage", null); |
| 27235 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 27236 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 27237 |
], resizer.prototype, "onStartResizing", null); |
| 27238 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 27239 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 27240 |
], resizer.prototype, "onEndResizing", null); |
| 27241 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 27242 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 27243 |
], resizer.prototype, "onResize", null); |
| 27244 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 27245 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 27246 |
], resizer.prototype, "onKeyDown", null); |
| 27247 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 27248 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 27249 |
], resizer.prototype, "onKeyUp", null); |
| 27250 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 27251 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 27252 |
], resizer.prototype, "onClickOutside", null); |
| 27253 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 27254 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.watch)(':change') |
| 27255 |
], resizer.prototype, "__onChangeEditor", null); |
| 27256 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 27257 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 27258 |
], resizer.prototype, "__bind", null); |
| 27259 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 27260 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind, |
| 27261 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.watch)(':hideResizer') |
| 27262 |
], resizer.prototype, "hide", null); |
| 27263 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_5__.pluginSystem.add('resizer', resizer); |
| 27264 |
|
| 27265 |
|
| 27266 |
/***/ }), |
| 27267 |
|
| 27268 |
/***/ 74833: |
| 27269 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 27270 |
|
| 27271 |
"use strict"; |
| 27272 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 27273 |
/* harmony export */ stateListeners: function() { return /* binding */ stateListeners; } |
| 27274 |
/* harmony export */ }); |
| 27275 |
/* harmony import */ var jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(27795); |
| 27276 |
/* harmony import */ var jodit_core_helpers_normalize__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(97022); |
| 27277 |
/* harmony import */ var jodit_core_ui_button_button_button__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(53681); |
| 27278 |
/* harmony import */ var jodit_modules_file_browser_builders_elements_map__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(31125); |
| 27279 |
/* harmony import */ var jodit_modules_file_browser_fetch_load_tree__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(53202); |
| 27280 |
/*! |
| 27281 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 27282 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 27283 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 27284 |
*/ /** |
| 27285 |
* @module modules/file-browser |
| 27286 |
*/ |
| 27287 |
|
| 27288 |
|
| 27289 |
|
| 27290 |
|
| 27291 |
const DEFAULT_SOURCE_NAME = 'default'; |
| 27292 |
/** |
| 27293 |
* Convert state to view |
| 27294 |
* @private |
| 27295 |
*/ function stateListeners() { |
| 27296 |
const elmMap = (0,jodit_modules_file_browser_builders_elements_map__WEBPACK_IMPORTED_MODULE_3__.elementsMap)(this); |
| 27297 |
const { state, files, create, options } = this, getDomElement = (item)=>{ |
| 27298 |
const key = item.uniqueHashKey; |
| 27299 |
if (elmMap[key]) { |
| 27300 |
return elmMap[key].elm; |
| 27301 |
} |
| 27302 |
const elm = create.fromHTML(options.getThumbTemplate.call(this, item, item.source, item.sourceName.toString())); |
| 27303 |
elm.dataset.key = key; |
| 27304 |
elmMap[key] = { |
| 27305 |
item, |
| 27306 |
elm |
| 27307 |
}; |
| 27308 |
return elmMap[key].elm; |
| 27309 |
}; |
| 27310 |
state.on([ |
| 27311 |
'change.currentPath', |
| 27312 |
'change.currentSource' |
| 27313 |
], this.async.debounce(()=>{ |
| 27314 |
if (this.o.saveStateInStorage && this.o.saveStateInStorage.storeLastOpenedFolder) { |
| 27315 |
this.storage.set('currentPath', this.state.currentPath).set('currentSource', this.state.currentSource); |
| 27316 |
} |
| 27317 |
(0,jodit_modules_file_browser_fetch_load_tree__WEBPACK_IMPORTED_MODULE_4__.loadTree)(this).catch(this.status); |
| 27318 |
}, this.defaultTimeout)).on('beforeChange.activeElements', ()=>{ |
| 27319 |
state.activeElements.forEach((item)=>{ |
| 27320 |
const key = item.uniqueHashKey, { elm } = elmMap[key]; |
| 27321 |
elm && elm.classList.remove(files.getFullElName('item', 'active', true)); |
| 27322 |
}); |
| 27323 |
}).on('change.activeElements', ()=>{ |
| 27324 |
this.e.fire('changeSelection'); |
| 27325 |
state.activeElements.forEach((item)=>{ |
| 27326 |
const key = item.uniqueHashKey, { elm } = elmMap[key]; |
| 27327 |
elm && elm.classList.add(files.getFullElName('item', 'active', true)); |
| 27328 |
}); |
| 27329 |
}).on('change.view', ()=>{ |
| 27330 |
files.setMod('view', state.view); |
| 27331 |
if (this.o.saveStateInStorage && this.o.saveStateInStorage.storeView) { |
| 27332 |
this.storage.set('view', state.view); |
| 27333 |
} |
| 27334 |
}).on('change.sortBy', ()=>{ |
| 27335 |
if (this.o.saveStateInStorage && this.o.saveStateInStorage.storeSortBy) { |
| 27336 |
this.storage.set('sortBy', state.sortBy); |
| 27337 |
} |
| 27338 |
}).on('change.elements', this.async.debounce(()=>{ |
| 27339 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.detach(files.container); |
| 27340 |
if (state.elements.length) { |
| 27341 |
state.elements.forEach((item)=>{ |
| 27342 |
this.files.container.appendChild(getDomElement(item)); |
| 27343 |
}); |
| 27344 |
} else { |
| 27345 |
files.container.appendChild(create.div(this.componentName + '_no-files_true', this.i18n('There are no files'))); |
| 27346 |
} |
| 27347 |
}, this.defaultTimeout)).on('change.sources', this.async.debounce(()=>{ |
| 27348 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.detach(this.tree.container); |
| 27349 |
state.sources.forEach((source)=>{ |
| 27350 |
const sourceName = source.name; |
| 27351 |
if (sourceName && sourceName !== DEFAULT_SOURCE_NAME) { |
| 27352 |
this.tree.container.appendChild(create.div(this.tree.getFullElName('source-title'), sourceName)); |
| 27353 |
} |
| 27354 |
source.folders.forEach((name)=>{ |
| 27355 |
const folderElm = create.a(this.tree.getFullElName('item'), { |
| 27356 |
draggable: 'draggable', |
| 27357 |
href: '#', |
| 27358 |
'data-path': (0,jodit_core_helpers_normalize__WEBPACK_IMPORTED_MODULE_1__.normalizePath)(source.path, name + '/'), |
| 27359 |
'data-name': name, |
| 27360 |
'data-source': sourceName, |
| 27361 |
'data-source-path': source.path |
| 27362 |
}, create.span(this.tree.getFullElName('item-title'), name)); |
| 27363 |
const action = (actionName)=>(e)=>{ |
| 27364 |
this.e.fire(`${actionName}.filebrowser`, { |
| 27365 |
name, |
| 27366 |
path: (0,jodit_core_helpers_normalize__WEBPACK_IMPORTED_MODULE_1__.normalizePath)(source.path + '/'), |
| 27367 |
source: sourceName |
| 27368 |
}); |
| 27369 |
e.stopPropagation(); |
| 27370 |
e.preventDefault(); |
| 27371 |
}; |
| 27372 |
this.e.on(folderElm, 'click', action('openFolder')); |
| 27373 |
this.tree.container.appendChild(folderElm); |
| 27374 |
if (name === '..' || name === '.') { |
| 27375 |
return; |
| 27376 |
} |
| 27377 |
if (options.renameFolder && this.dataProvider.canI('FolderRename')) { |
| 27378 |
const btn = (0,jodit_core_ui_button_button_button__WEBPACK_IMPORTED_MODULE_2__.Button)(this, { |
| 27379 |
icon: { |
| 27380 |
name: 'pencil' |
| 27381 |
}, |
| 27382 |
name: 'rename', |
| 27383 |
tooltip: 'Rename', |
| 27384 |
size: 'tiny' |
| 27385 |
}); |
| 27386 |
btn.onAction(action('renameFolder')); |
| 27387 |
folderElm.appendChild(btn.container); |
| 27388 |
} |
| 27389 |
if (options.deleteFolder && this.dataProvider.canI('FolderRemove')) { |
| 27390 |
const btn = (0,jodit_core_ui_button_button_button__WEBPACK_IMPORTED_MODULE_2__.Button)(this, { |
| 27391 |
icon: { |
| 27392 |
name: 'cancel' |
| 27393 |
}, |
| 27394 |
name: 'remove', |
| 27395 |
tooltip: 'Delete', |
| 27396 |
size: 'tiny' |
| 27397 |
}); |
| 27398 |
btn.onAction(action('removeFolder')); |
| 27399 |
folderElm.appendChild(btn.container); |
| 27400 |
} |
| 27401 |
}); |
| 27402 |
if (options.createNewFolder && this.dataProvider.canI('FolderCreate')) { |
| 27403 |
const button = (0,jodit_core_ui_button_button_button__WEBPACK_IMPORTED_MODULE_2__.Button)(this, 'plus', 'Add folder', 'secondary'); |
| 27404 |
button.onAction(()=>{ |
| 27405 |
this.e.fire('addFolder', { |
| 27406 |
path: (0,jodit_core_helpers_normalize__WEBPACK_IMPORTED_MODULE_1__.normalizePath)(source.path + '/'), |
| 27407 |
source: sourceName |
| 27408 |
}); |
| 27409 |
}); |
| 27410 |
this.tree.append(button); |
| 27411 |
} |
| 27412 |
}); |
| 27413 |
}, this.defaultTimeout)); |
| 27414 |
} |
| 27415 |
|
| 27416 |
|
| 27417 |
/***/ }), |
| 27418 |
|
| 27419 |
/***/ 75587: |
| 27420 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 27421 |
|
| 27422 |
"use strict"; |
| 27423 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 27424 |
/* harmony export */ UIFileInput: function() { return /* binding */ UIFileInput; } |
| 27425 |
/* harmony export */ }); |
| 27426 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 27427 |
/* harmony import */ var _swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(41411); |
| 27428 |
/* harmony import */ var _swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(15366); |
| 27429 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(31635); |
| 27430 |
/* harmony import */ var jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(91672); |
| 27431 |
/* harmony import */ var jodit_core_ui_button_button_button__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(53681); |
| 27432 |
/* harmony import */ var jodit_core_ui_form_inputs_input_input__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(65273); |
| 27433 |
/*! |
| 27434 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 27435 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 27436 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 27437 |
*/ /** |
| 27438 |
* @module ui/form |
| 27439 |
*/ |
| 27440 |
|
| 27441 |
|
| 27442 |
|
| 27443 |
|
| 27444 |
|
| 27445 |
|
| 27446 |
|
| 27447 |
class UIFileInput extends jodit_core_ui_form_inputs_input_input__WEBPACK_IMPORTED_MODULE_6__.UIInput { |
| 27448 |
/** @override */ className() { |
| 27449 |
return 'UIFileInput'; |
| 27450 |
} |
| 27451 |
createContainer(options) { |
| 27452 |
this.button = new jodit_core_ui_button_button_button__WEBPACK_IMPORTED_MODULE_5__.UIButton(this.j, { |
| 27453 |
tooltip: options.tooltip, |
| 27454 |
icon: { |
| 27455 |
name: 'plus' |
| 27456 |
} |
| 27457 |
}); |
| 27458 |
const { container } = this.button; |
| 27459 |
if (!this.nativeInput) { |
| 27460 |
this.nativeInput = this.createNativeInput(options); |
| 27461 |
} |
| 27462 |
const { nativeInput } = this; |
| 27463 |
nativeInput.classList.add(this.getFullElName('input')); |
| 27464 |
container.classList.add(this.componentName); |
| 27465 |
container.appendChild(nativeInput); |
| 27466 |
return container; |
| 27467 |
} |
| 27468 |
createNativeInput(options) { |
| 27469 |
return this.j.create.fromHTML(`<input |
| 27470 |
type="file" |
| 27471 |
accept="${options.onlyImages ? 'image/*' : '*'}" |
| 27472 |
tabindex="-1" |
| 27473 |
dir="auto" |
| 27474 |
multiple="" |
| 27475 |
/>`); |
| 27476 |
} |
| 27477 |
constructor(jodit, options){ |
| 27478 |
super(jodit, (0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_1__._)({ |
| 27479 |
type: 'file' |
| 27480 |
}, options)), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "state", (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_2__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_1__._)({}, jodit_core_ui_form_inputs_input_input__WEBPACK_IMPORTED_MODULE_6__.UIInput.defaultState), { |
| 27481 |
type: 'file', |
| 27482 |
onlyImages: true |
| 27483 |
})); |
| 27484 |
} |
| 27485 |
} |
| 27486 |
UIFileInput = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__.__decorate)([ |
| 27487 |
jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_4__.component |
| 27488 |
], UIFileInput); |
| 27489 |
|
| 27490 |
|
| 27491 |
/***/ }), |
| 27492 |
|
| 27493 |
/***/ 75711: |
| 27494 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 27495 |
|
| 27496 |
"use strict"; |
| 27497 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 27498 |
/* harmony export */ align: function() { return /* binding */ align; } |
| 27499 |
/* harmony export */ }); |
| 27500 |
/* harmony import */ var jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(27795); |
| 27501 |
/* harmony import */ var jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(85932); |
| 27502 |
/* harmony import */ var jodit_core_helpers_utils_align__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(16849); |
| 27503 |
/* harmony import */ var jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(80991); |
| 27504 |
/*! |
| 27505 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 27506 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 27507 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 27508 |
*/ /** |
| 27509 |
* @module plugins/inline-popup |
| 27510 |
*/ |
| 27511 |
|
| 27512 |
|
| 27513 |
|
| 27514 |
const align = { |
| 27515 |
name: 'left', |
| 27516 |
childTemplate: (_, __, value)=>value, |
| 27517 |
list: [ |
| 27518 |
'Left', |
| 27519 |
'Right', |
| 27520 |
'Center', |
| 27521 |
'Normal' |
| 27522 |
], |
| 27523 |
exec: (editor, elm, { control })=>{ |
| 27524 |
if (!jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(elm, new Set([ |
| 27525 |
'img', |
| 27526 |
'jodit', |
| 27527 |
'jodit-media' |
| 27528 |
]))) { |
| 27529 |
return; |
| 27530 |
} |
| 27531 |
const command = control.args && (0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_1__.isString)(control.args[0]) ? control.args[0].toLowerCase() : ''; |
| 27532 |
if (!command) { |
| 27533 |
return false; |
| 27534 |
} |
| 27535 |
(0,jodit_core_helpers_utils_align__WEBPACK_IMPORTED_MODULE_2__.hAlignElement)(elm, command); |
| 27536 |
if (jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(elm, new Set([ |
| 27537 |
'jodit', |
| 27538 |
'jodit-media' |
| 27539 |
])) && elm.firstElementChild) { |
| 27540 |
(0,jodit_core_helpers_utils_align__WEBPACK_IMPORTED_MODULE_2__.hAlignElement)(elm.firstElementChild, command); |
| 27541 |
} |
| 27542 |
editor.synchronizeValues(); |
| 27543 |
editor.e.fire('recalcPositionPopup'); |
| 27544 |
}, |
| 27545 |
tooltip: 'Horizontal align' |
| 27546 |
}; |
| 27547 |
/* harmony default export */ __webpack_exports__["default"] = ([ |
| 27548 |
{ |
| 27549 |
name: 'delete', |
| 27550 |
icon: 'bin', |
| 27551 |
tooltip: 'Delete', |
| 27552 |
exec: (editor, image)=>{ |
| 27553 |
image && editor.s.removeNode(image); |
| 27554 |
} |
| 27555 |
}, |
| 27556 |
{ |
| 27557 |
name: 'pencil', |
| 27558 |
exec (editor, current) { |
| 27559 |
const tagName = current.tagName.toLowerCase(); |
| 27560 |
if (tagName === 'img') { |
| 27561 |
editor.e.fire('openImageProperties', current); |
| 27562 |
} |
| 27563 |
}, |
| 27564 |
tooltip: 'Edit' |
| 27565 |
}, |
| 27566 |
{ |
| 27567 |
name: 'valign', |
| 27568 |
list: [ |
| 27569 |
'Top', |
| 27570 |
'Middle', |
| 27571 |
'Bottom', |
| 27572 |
'Normal' |
| 27573 |
], |
| 27574 |
tooltip: 'Vertical align', |
| 27575 |
exec: (editor, image, { control })=>{ |
| 27576 |
if (!jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(image, 'img')) { |
| 27577 |
return; |
| 27578 |
} |
| 27579 |
const command = control.args && (0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_1__.isString)(control.args[0]) ? control.args[0].toLowerCase() : ''; |
| 27580 |
if (!command) { |
| 27581 |
return false; |
| 27582 |
} |
| 27583 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_3__.css)(image, 'vertical-align', command === 'normal' ? '' : command); |
| 27584 |
editor.e.fire('recalcPositionPopup'); |
| 27585 |
} |
| 27586 |
}, |
| 27587 |
align |
| 27588 |
]); |
| 27589 |
|
| 27590 |
|
| 27591 |
/***/ }), |
| 27592 |
|
| 27593 |
/***/ 76517: |
| 27594 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 27595 |
|
| 27596 |
"use strict"; |
| 27597 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 27598 |
/* harmony export */ Create: function() { return /* binding */ Create; } |
| 27599 |
/* harmony export */ }); |
| 27600 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 27601 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(81937); |
| 27602 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(23211); |
| 27603 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(65946); |
| 27604 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(28712); |
| 27605 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_4__); |
| 27606 |
/*! |
| 27607 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 27608 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 27609 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 27610 |
*/ /** |
| 27611 |
* [[include:core/create/README.md]] |
| 27612 |
* @packageDocumentation |
| 27613 |
* @module create |
| 27614 |
*/ |
| 27615 |
|
| 27616 |
|
| 27617 |
|
| 27618 |
|
| 27619 |
class Create { |
| 27620 |
get doc() { |
| 27621 |
// @ts-ignore - TODO it's a function |
| 27622 |
return (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.isFunction)(this.document) ? this.document() : this.document; |
| 27623 |
} |
| 27624 |
element(tagName, childrenOrAttributes, children) { |
| 27625 |
const elm = this.doc.createElement(tagName.toLowerCase()); |
| 27626 |
this.applyCreateAttributes(elm); |
| 27627 |
if (childrenOrAttributes) { |
| 27628 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.isPlainObject)(childrenOrAttributes)) { |
| 27629 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.attr)(elm, childrenOrAttributes); |
| 27630 |
} else { |
| 27631 |
children = childrenOrAttributes; |
| 27632 |
} |
| 27633 |
} |
| 27634 |
if (children) { |
| 27635 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.asArray)(children).forEach((child)=>elm.appendChild((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.isString)(child) ? this.fromHTML(child) : child)); |
| 27636 |
} |
| 27637 |
return elm; |
| 27638 |
} |
| 27639 |
div(className, childrenOrAttributes, children) { |
| 27640 |
const div = this.element('div', childrenOrAttributes, children); |
| 27641 |
if (className) { |
| 27642 |
div.className = className; |
| 27643 |
} |
| 27644 |
return div; |
| 27645 |
} |
| 27646 |
sandbox() { |
| 27647 |
var _iframe_contentWindow; |
| 27648 |
const iframe = this.element('iframe', { |
| 27649 |
sandbox: 'allow-same-origin' |
| 27650 |
}); |
| 27651 |
this.doc.body.appendChild(iframe); |
| 27652 |
const doc = (_iframe_contentWindow = iframe.contentWindow) === null || _iframe_contentWindow === void 0 ? void 0 : _iframe_contentWindow.document; |
| 27653 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_4__.assert)(doc, 'iframe.contentWindow.document'); |
| 27654 |
if (!doc) { |
| 27655 |
throw Error('Iframe error'); |
| 27656 |
} |
| 27657 |
doc.open(); |
| 27658 |
doc.write('<!DOCTYPE html><html><head></head><body></body></html>'); |
| 27659 |
doc.close(); |
| 27660 |
return [ |
| 27661 |
doc.body, |
| 27662 |
iframe |
| 27663 |
]; |
| 27664 |
} |
| 27665 |
span(className, childrenOrAttributes, children) { |
| 27666 |
const span = this.element('span', childrenOrAttributes, children); |
| 27667 |
if (className) { |
| 27668 |
span.className = className; |
| 27669 |
} |
| 27670 |
return span; |
| 27671 |
} |
| 27672 |
a(className, childrenOrAttributes, children) { |
| 27673 |
const a = this.element('a', childrenOrAttributes, children); |
| 27674 |
if (className) { |
| 27675 |
a.className = className; |
| 27676 |
} |
| 27677 |
return a; |
| 27678 |
} |
| 27679 |
/** |
| 27680 |
* Create text node |
| 27681 |
*/ text(value) { |
| 27682 |
return this.doc.createTextNode(value); |
| 27683 |
} |
| 27684 |
/** |
| 27685 |
* Create invisible text node |
| 27686 |
*/ fake() { |
| 27687 |
return this.text(jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.INVISIBLE_SPACE); |
| 27688 |
} |
| 27689 |
/** |
| 27690 |
* Create HTML Document fragment element |
| 27691 |
*/ fragment() { |
| 27692 |
return this.doc.createDocumentFragment(); |
| 27693 |
} |
| 27694 |
/** |
| 27695 |
* Create a DOM element from HTML text |
| 27696 |
* |
| 27697 |
// eslint-disable-next-line tsdoc/syntax |
| 27698 |
* @param refsToggleElement - State dictionary in which you can set the visibility of some of the elements |
| 27699 |
* ```js |
| 27700 |
* const editor = Jodit.make('#editor'); |
| 27701 |
* editor.createInside.fromHTML(`<div> |
| 27702 |
* <input name="name" ref="name"/> |
| 27703 |
* <input name="email" ref="email"/> |
| 27704 |
* </div>`, { |
| 27705 |
* name: true, |
| 27706 |
* email: false |
| 27707 |
* }); |
| 27708 |
* ``` |
| 27709 |
*/ fromHTML(html, refsToggleElement) { |
| 27710 |
const div = this.div(); |
| 27711 |
div.innerHTML = html.toString(); |
| 27712 |
const child = div.firstChild !== div.lastChild || !div.firstChild ? div : div.firstChild; |
| 27713 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__.Dom.safeRemove(child); |
| 27714 |
if (refsToggleElement) { |
| 27715 |
const refElements = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.refs)(child); |
| 27716 |
Object.keys(refsToggleElement).forEach((key)=>{ |
| 27717 |
const elm = refElements[key]; |
| 27718 |
if (elm && refsToggleElement[key] === false) { |
| 27719 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__.Dom.hide(elm); |
| 27720 |
} |
| 27721 |
}); |
| 27722 |
} |
| 27723 |
return child; |
| 27724 |
} |
| 27725 |
/** |
| 27726 |
* Apply to element `createAttributes` options |
| 27727 |
*/ applyCreateAttributes(elm) { |
| 27728 |
if (this.createAttributes) { |
| 27729 |
const ca = this.createAttributes; |
| 27730 |
if (ca && ca[elm.tagName.toLowerCase()]) { |
| 27731 |
const attrsOpt = ca[elm.tagName.toLowerCase()]; |
| 27732 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.isFunction)(attrsOpt)) { |
| 27733 |
attrsOpt(elm); |
| 27734 |
} else if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.isPlainObject)(attrsOpt)) { |
| 27735 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.attr)(elm, attrsOpt); |
| 27736 |
} |
| 27737 |
} |
| 27738 |
} |
| 27739 |
} |
| 27740 |
constructor(document, createAttributes){ |
| 27741 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "document", void 0); |
| 27742 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "createAttributes", void 0); |
| 27743 |
this.document = document; |
| 27744 |
this.createAttributes = createAttributes; |
| 27745 |
} |
| 27746 |
} |
| 27747 |
|
| 27748 |
|
| 27749 |
/***/ }), |
| 27750 |
|
| 27751 |
/***/ 76841: |
| 27752 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 27753 |
|
| 27754 |
"use strict"; |
| 27755 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 27756 |
/* harmony export */ Dialog: function() { return /* binding */ Dialog; } |
| 27757 |
/* harmony export */ }); |
| 27758 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 27759 |
/* harmony import */ var _swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(41411); |
| 27760 |
/* harmony import */ var _swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(15366); |
| 27761 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(31635); |
| 27762 |
/* harmony import */ var jodit_core_component__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(16964); |
| 27763 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(81937); |
| 27764 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(84839); |
| 27765 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(23211); |
| 27766 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(28077); |
| 27767 |
/* harmony import */ var jodit_core_helpers_array__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(45664); |
| 27768 |
/* harmony import */ var jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(28686); |
| 27769 |
/* harmony import */ var jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(93640); |
| 27770 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(28712); |
| 27771 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_12___default = /*#__PURE__*/__webpack_require__.n(jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_12__); |
| 27772 |
/* harmony import */ var jodit_core_ui__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(4099); |
| 27773 |
/* harmony import */ var jodit_core_view_view__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(35099); |
| 27774 |
/* harmony import */ var jodit_core_view_view_with_toolbar__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(2222); |
| 27775 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(5266); |
| 27776 |
/*! |
| 27777 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 27778 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 27779 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 27780 |
*/ /** |
| 27781 |
* @module modules/dialog |
| 27782 |
*/ |
| 27783 |
|
| 27784 |
|
| 27785 |
|
| 27786 |
|
| 27787 |
|
| 27788 |
|
| 27789 |
|
| 27790 |
|
| 27791 |
|
| 27792 |
|
| 27793 |
|
| 27794 |
|
| 27795 |
|
| 27796 |
|
| 27797 |
|
| 27798 |
|
| 27799 |
|
| 27800 |
jodit_config__WEBPACK_IMPORTED_MODULE_16__.Config.prototype.dialog = { |
| 27801 |
namespace: '', |
| 27802 |
extraButtons: [], |
| 27803 |
/** |
| 27804 |
* This dialog can resize by trigger |
| 27805 |
*/ resizable: true, |
| 27806 |
/** |
| 27807 |
* This dialog can move by header |
| 27808 |
*/ draggable: true, |
| 27809 |
buttons: [ |
| 27810 |
'dialog.close' |
| 27811 |
], |
| 27812 |
removeButtons: [], |
| 27813 |
toolbarButtonSize: 'middle', |
| 27814 |
zIndex: 'inherit' |
| 27815 |
}; |
| 27816 |
jodit_config__WEBPACK_IMPORTED_MODULE_16__.Config.prototype.controls.dialog = { |
| 27817 |
close: { |
| 27818 |
icon: 'cancel', |
| 27819 |
exec: (dialog)=>{ |
| 27820 |
dialog.close(); |
| 27821 |
} |
| 27822 |
} |
| 27823 |
}; |
| 27824 |
class Dialog extends jodit_core_view_view_with_toolbar__WEBPACK_IMPORTED_MODULE_15__.ViewWithToolbar { |
| 27825 |
/** @override */ className() { |
| 27826 |
return 'Dialog'; |
| 27827 |
} |
| 27828 |
get destination() { |
| 27829 |
const { popupRoot, shadowRoot } = this.o; |
| 27830 |
if (popupRoot) { |
| 27831 |
return popupRoot; |
| 27832 |
} |
| 27833 |
if (shadowRoot) { |
| 27834 |
return shadowRoot; |
| 27835 |
} |
| 27836 |
return this.od.body; |
| 27837 |
} |
| 27838 |
setElements(root, elements) { |
| 27839 |
const elements_list = []; |
| 27840 |
(0,jodit_core_helpers_array__WEBPACK_IMPORTED_MODULE_9__.asArray)(elements).forEach((elm)=>{ |
| 27841 |
if ((0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_10__.isArray)(elm)) { |
| 27842 |
const div = this.c.div(this.getFullElName('column')); |
| 27843 |
elements_list.push(div); |
| 27844 |
root.appendChild(div); |
| 27845 |
return this.setElements(div, elm); |
| 27846 |
} |
| 27847 |
let element; |
| 27848 |
if ((0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_10__.isString)(elm)) { |
| 27849 |
element = this.c.fromHTML(elm); |
| 27850 |
} else { |
| 27851 |
element = (0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_10__.hasContainer)(elm) ? elm.container : elm; |
| 27852 |
} |
| 27853 |
elements_list.push(element); |
| 27854 |
if (element.parentNode !== root) { |
| 27855 |
root.appendChild(element); |
| 27856 |
} |
| 27857 |
}); |
| 27858 |
(0,jodit_core_helpers_array__WEBPACK_IMPORTED_MODULE_9__.toArray)(root.childNodes).forEach((elm)=>{ |
| 27859 |
if (elements_list.indexOf(elm) === -1) { |
| 27860 |
root.removeChild(elm); |
| 27861 |
} |
| 27862 |
}); |
| 27863 |
} |
| 27864 |
__onMouseUp() { |
| 27865 |
if (this.draggable || this.resizable) { |
| 27866 |
this.__removeGlobalResizeListeners(); |
| 27867 |
this.draggable = false; |
| 27868 |
this.resizable = false; |
| 27869 |
this.unlockSelect(); |
| 27870 |
if (this.e) { |
| 27871 |
this.__removeGlobalResizeListeners(); |
| 27872 |
/** |
| 27873 |
* Fired when the dialog box is finished to resizing |
| 27874 |
*/ this.e.fire(this, 'endResize endMove'); |
| 27875 |
} |
| 27876 |
} |
| 27877 |
} |
| 27878 |
/** |
| 27879 |
* |
| 27880 |
*/ __onHeaderMouseDown(e) { |
| 27881 |
const target = e.target; |
| 27882 |
if (!this.o.draggable || target && target.nodeName.match(/^(INPUT|SELECT)$/)) { |
| 27883 |
return; |
| 27884 |
} |
| 27885 |
this.draggable = true; |
| 27886 |
this.startX = e.clientX; |
| 27887 |
this.startY = e.clientY; |
| 27888 |
this.startPoint.x = (0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_11__.css)(this.dialog, 'left'); |
| 27889 |
this.startPoint.y = (0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_11__.css)(this.dialog, 'top'); |
| 27890 |
this.setMaxZIndex(); |
| 27891 |
if (e.cancelable) { |
| 27892 |
e.preventDefault(); |
| 27893 |
} |
| 27894 |
this.lockSelect(); |
| 27895 |
this.__addGlobalResizeListeners(); |
| 27896 |
if (this.e) { |
| 27897 |
/** |
| 27898 |
* Fired when dialog box is started moving |
| 27899 |
*/ this.e.fire(this, 'startMove'); |
| 27900 |
this.e.fire('closeAllPopups'); |
| 27901 |
} |
| 27902 |
} |
| 27903 |
__onMouseMove(e) { |
| 27904 |
if (this.draggable && this.o.draggable) { |
| 27905 |
this.setPosition(this.startPoint.x + e.clientX - this.startX, this.startPoint.y + e.clientY - this.startY); |
| 27906 |
if (this.e) { |
| 27907 |
/** |
| 27908 |
* Fired when dialog box is moved |
| 27909 |
*/ this.e.fire(this, 'move', e.clientX - this.startX, e.clientY - this.startY); |
| 27910 |
} |
| 27911 |
e.stopImmediatePropagation(); |
| 27912 |
} |
| 27913 |
if (this.resizable && this.o.resizable) { |
| 27914 |
this.setSize(this.startPoint.w + e.clientX - this.startX, this.startPoint.h + e.clientY - this.startY); |
| 27915 |
if (this.e) { |
| 27916 |
/** |
| 27917 |
* Fired when dialog box is resized |
| 27918 |
*/ this.e.fire(this, 'resizeDialog', e.clientX - this.startX, e.clientY - this.startY); |
| 27919 |
} |
| 27920 |
} |
| 27921 |
} |
| 27922 |
__onEsc(e) { |
| 27923 |
if (!this.o.closeOnEsc) { |
| 27924 |
return; |
| 27925 |
} |
| 27926 |
if (this.isOpened && e.key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_5__.KEY_ESC && this.getMod('static') !== true) { |
| 27927 |
const me = this.getMaxZIndexDialog(); |
| 27928 |
if (me) { |
| 27929 |
me.close(); |
| 27930 |
} else { |
| 27931 |
this.close(); |
| 27932 |
} |
| 27933 |
e.stopImmediatePropagation(); |
| 27934 |
} |
| 27935 |
} |
| 27936 |
__onResizerMouseDown(e) { |
| 27937 |
this.resizable = true; |
| 27938 |
this.startX = e.clientX; |
| 27939 |
this.startY = e.clientY; |
| 27940 |
this.startPoint.w = this.dialog.offsetWidth; |
| 27941 |
this.startPoint.h = this.dialog.offsetHeight; |
| 27942 |
this.lockSelect(); |
| 27943 |
this.__addGlobalResizeListeners(); |
| 27944 |
if (this.e) { |
| 27945 |
/** |
| 27946 |
* Fired when dialog box is started resizing |
| 27947 |
*/ this.e.fire(this, 'startResize'); |
| 27948 |
} |
| 27949 |
} |
| 27950 |
__addGlobalResizeListeners() { |
| 27951 |
const self1 = this; |
| 27952 |
self1.e.on(self1.ow, 'pointermove touchmove', self1.__onMouseMove).on(self1.ow, 'pointerup touchend', self1.__onMouseUp); |
| 27953 |
} |
| 27954 |
__removeGlobalResizeListeners() { |
| 27955 |
const self1 = this; |
| 27956 |
self1.e.off(self1.ow, 'mousemove pointermove', self1.__onMouseMove).off(self1.ow, 'mouseup pointerup', self1.__onMouseUp); |
| 27957 |
} |
| 27958 |
/** |
| 27959 |
* Specifies the size of the window |
| 27960 |
* |
| 27961 |
* @param w - The width of the window |
| 27962 |
* @param h - The height of the window |
| 27963 |
*/ setSize(w, h) { |
| 27964 |
if (w == null) { |
| 27965 |
w = this.dialog.offsetWidth; |
| 27966 |
} |
| 27967 |
if (h == null) { |
| 27968 |
h = this.dialog.offsetHeight; |
| 27969 |
} |
| 27970 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_11__.css)(this.dialog, { |
| 27971 |
width: w, |
| 27972 |
height: h |
| 27973 |
}); |
| 27974 |
return this; |
| 27975 |
} |
| 27976 |
/** |
| 27977 |
* Recalculate auto sizes |
| 27978 |
*/ calcAutoSize() { |
| 27979 |
this.setSize('auto', 'auto'); |
| 27980 |
this.setSize(); |
| 27981 |
return this; |
| 27982 |
} |
| 27983 |
/** |
| 27984 |
* Specifies the position of the upper left corner of the window . If x and y are specified, |
| 27985 |
* the window is centered on the center of the screen |
| 27986 |
* |
| 27987 |
* @param x - Position px Horizontal |
| 27988 |
* @param y - Position px Vertical |
| 27989 |
*/ setPosition(x, y) { |
| 27990 |
const w = this.ow.innerWidth, h = this.ow.innerHeight; |
| 27991 |
let left = w / 2 - this.dialog.offsetWidth / 2, top = h / 2 - this.dialog.offsetHeight / 2; |
| 27992 |
if (left < 0) { |
| 27993 |
left = 0; |
| 27994 |
} |
| 27995 |
if (top < 0) { |
| 27996 |
top = 0; |
| 27997 |
} |
| 27998 |
if (x !== undefined && y !== undefined) { |
| 27999 |
this.offsetX = x; |
| 28000 |
this.offsetY = y; |
| 28001 |
this.moved = Math.abs(x - left) > 100 || Math.abs(y - top) > 100; |
| 28002 |
} |
| 28003 |
this.dialog.style.left = (x || left) + 'px'; |
| 28004 |
this.dialog.style.top = (y || top) + 'px'; |
| 28005 |
return this; |
| 28006 |
} |
| 28007 |
/** |
| 28008 |
* Specifies the dialog box title . It can take a string and an array of objects |
| 28009 |
* |
| 28010 |
* @param content - A string or an HTML element , |
| 28011 |
* or an array of strings and elements |
| 28012 |
* @example |
| 28013 |
* ```javascript |
| 28014 |
* var dialog = new Jodi.modules.Dialog(parent); |
| 28015 |
* dialog.setHeader('Hello world'); |
| 28016 |
* dialog.setHeader(['Hello world', '<button>OK</button>', $('<div>some</div>')]); |
| 28017 |
* dialog.open(); |
| 28018 |
* ``` |
| 28019 |
*/ setHeader(content) { |
| 28020 |
this.setElements(this.dialogbox_header, content); |
| 28021 |
return this; |
| 28022 |
} |
| 28023 |
/** |
| 28024 |
* It specifies the contents of the dialog box. It can take a string and an array of objects |
| 28025 |
* |
| 28026 |
* @param content - A string or an HTML element , |
| 28027 |
* or an array of strings and elements |
| 28028 |
* @example |
| 28029 |
* ```javascript |
| 28030 |
* var dialog = new Jodi.modules.Dialog(parent); |
| 28031 |
* dialog.setHeader('Hello world'); |
| 28032 |
* dialog.setContent('<form onsubmit="alert(1);"><input type="text" /></form>'); |
| 28033 |
* dialog.open(); |
| 28034 |
* ``` |
| 28035 |
*/ setContent(content) { |
| 28036 |
this.setElements(this.dialogbox_content, content); |
| 28037 |
return this; |
| 28038 |
} |
| 28039 |
/** |
| 28040 |
* Sets the bottom of the dialog. It can take a string and an array of objects |
| 28041 |
* |
| 28042 |
* @param content - A string or an HTML element , |
| 28043 |
* or an array of strings and elements |
| 28044 |
* @example |
| 28045 |
* ```javascript |
| 28046 |
* var dialog = new Jodi.modules.Dialog(parent); |
| 28047 |
* dialog.setHeader('Hello world'); |
| 28048 |
* dialog.setContent('<form><input id="someText" type="text" /></form>'); |
| 28049 |
* dialog.setFooter([ |
| 28050 |
* $('<a class="jodit-button">OK</a>').click(function () { |
| 28051 |
* alert($('someText').val()) |
| 28052 |
* dialog.close(); |
| 28053 |
* }) |
| 28054 |
* ]); |
| 28055 |
* dialog.open(); |
| 28056 |
* ``` |
| 28057 |
*/ setFooter(content) { |
| 28058 |
this.setElements(this.dialogbox_footer, content); |
| 28059 |
this.setMod('footer', Boolean(content)); |
| 28060 |
return this; |
| 28061 |
} |
| 28062 |
/** |
| 28063 |
* Get zIndex from dialog |
| 28064 |
*/ getZIndex() { |
| 28065 |
return parseInt((0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_11__.css)(this.container, 'zIndex'), 10) || 0; |
| 28066 |
} |
| 28067 |
/** |
| 28068 |
* Get dialog instance with maximum z-index displaying it on top of all the dialog boxes |
| 28069 |
*/ getMaxZIndexDialog() { |
| 28070 |
let maxZi = 0, dlg, zIndex, res = this; |
| 28071 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_11__.$$)('.jodit-dialog', this.destination).forEach((dialog)=>{ |
| 28072 |
dlg = dialog.component; |
| 28073 |
zIndex = parseInt((0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_11__.css)(dialog, 'zIndex'), 10); |
| 28074 |
if (dlg.isOpened && !isNaN(zIndex) && zIndex > maxZi) { |
| 28075 |
res = dlg; |
| 28076 |
maxZi = zIndex; |
| 28077 |
} |
| 28078 |
}); |
| 28079 |
return res; |
| 28080 |
} |
| 28081 |
/** |
| 28082 |
* Sets the maximum z-index dialog box, displaying it on top of all the dialog boxes |
| 28083 |
*/ setMaxZIndex() { |
| 28084 |
if (this.getMod('static')) return; |
| 28085 |
let maxZIndex = 20000004, zIndex = 0; |
| 28086 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_11__.$$)('.jodit-dialog', this.destination).forEach((dialog)=>{ |
| 28087 |
zIndex = parseInt((0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_11__.css)(dialog, 'zIndex'), 10); |
| 28088 |
maxZIndex = Math.max(isNaN(zIndex) ? 0 : zIndex, maxZIndex); |
| 28089 |
}); |
| 28090 |
this.container.style.zIndex = (maxZIndex + 1).toString(); |
| 28091 |
} |
| 28092 |
/** |
| 28093 |
* Expands the dialog on full browser window |
| 28094 |
*/ toggleFullSize(isFullSize) { |
| 28095 |
if ((0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_10__.isVoid)(isFullSize)) { |
| 28096 |
isFullSize = !this.getMod('fullsize'); |
| 28097 |
} |
| 28098 |
this.setMod('fullsize', isFullSize); |
| 28099 |
super.toggleFullSize(isFullSize); |
| 28100 |
} |
| 28101 |
/** |
| 28102 |
* It opens a dialog box to center it, and causes the two event. |
| 28103 |
* |
| 28104 |
* @param contentOrClose - specifies the contents of the dialog box. |
| 28105 |
* Can be false or undefined. see [[Dialog.setContent]] |
| 28106 |
* @param title - specifies the title of the dialog box, @see setHeader |
| 28107 |
* @param destroyAfterClose - true - After closing the window , the destructor will be called. |
| 28108 |
* @param modal - true window will be opened in modal mode |
| 28109 |
*/ open(contentOrClose, titleOrModal, destroyAfterClose, modal) { |
| 28110 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_8__.eventEmitter.fire('closeAllPopups hideHelpers'); |
| 28111 |
/** |
| 28112 |
* Called before the opening of the dialog box |
| 28113 |
*/ if (this.e.fire(this, 'beforeOpen') === false) { |
| 28114 |
return this; |
| 28115 |
} |
| 28116 |
if ((0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_10__.isBoolean)(contentOrClose)) { |
| 28117 |
destroyAfterClose = contentOrClose; |
| 28118 |
} |
| 28119 |
if ((0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_10__.isBoolean)(titleOrModal)) { |
| 28120 |
modal = titleOrModal; |
| 28121 |
} |
| 28122 |
this.destroyAfterClose = destroyAfterClose === true; |
| 28123 |
const content = (0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_10__.isBoolean)(contentOrClose) ? undefined : contentOrClose; |
| 28124 |
const title = (0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_10__.isBoolean)(titleOrModal) ? undefined : titleOrModal; |
| 28125 |
if (title !== undefined) { |
| 28126 |
this.setHeader(title); |
| 28127 |
} |
| 28128 |
if (content) { |
| 28129 |
this.setContent(content); |
| 28130 |
} |
| 28131 |
this.setMod('active', true); |
| 28132 |
this.isOpened = true; |
| 28133 |
this.setModal(modal); |
| 28134 |
this.destination.appendChild(this.container); |
| 28135 |
if (this.getMod('static') !== true) { |
| 28136 |
this.setPosition(this.offsetX, this.offsetY); |
| 28137 |
this.setMaxZIndex(); |
| 28138 |
} else { |
| 28139 |
this.container.style.removeProperty('z-index'); |
| 28140 |
} |
| 28141 |
if (this.o.fullsize) { |
| 28142 |
this.toggleFullSize(true); |
| 28143 |
} |
| 28144 |
/** |
| 28145 |
* Called after the opening of the dialog box |
| 28146 |
*/ this.e.fire('afterOpen', this); |
| 28147 |
return this; |
| 28148 |
} |
| 28149 |
/** |
| 28150 |
* Set modal mode |
| 28151 |
*/ setModal(modal) { |
| 28152 |
this.isModal = Boolean(modal); |
| 28153 |
this.setMod('modal', this.isModal); |
| 28154 |
return this; |
| 28155 |
} |
| 28156 |
/**** |
| 28157 |
* Closes the dialog box , if you want to call the method `destruct` |
| 28158 |
* |
| 28159 |
* @see destroy |
| 28160 |
* @example |
| 28161 |
* ```javascript |
| 28162 |
* //You can close dialog two ways |
| 28163 |
* var dialog = new Jodit.modules.Dialog(); |
| 28164 |
* dialog.open('Hello world!', 'Title'); |
| 28165 |
* var $close = dialog.create.fromHTML('<a href="#" style="float:left;" class="jodit-button"> |
| 28166 |
* <i class="icon icon-check"></i> ' + Jodit.prototype.i18n('Ok') + '</a>'); |
| 28167 |
* $close.addEventListener('click', function () { |
| 28168 |
* dialog.close(); |
| 28169 |
* }); |
| 28170 |
* dialog.setFooter($close); |
| 28171 |
* // and second way, you can close dialog from content |
| 28172 |
* dialog.open('<a onclick="var event = doc.createEvent('HTMLEvents'); event.initEvent('close_dialog', true, true); |
| 28173 |
* this.dispatchEvent(event)">Close</a>', 'Title'); |
| 28174 |
* ``` |
| 28175 |
*/ close() { |
| 28176 |
if (this.isDestructed || !this.isOpened || this.getMod('static') === true) { |
| 28177 |
return this; |
| 28178 |
} |
| 28179 |
const { e } = this; |
| 28180 |
/** |
| 28181 |
* Called up to close the window |
| 28182 |
*/ if (e.fire(this, 'beforeClose') === false || e.fire('beforeClose', this) === false) { |
| 28183 |
return this; |
| 28184 |
} |
| 28185 |
this.setMod('active', false); |
| 28186 |
this.isOpened = false; |
| 28187 |
if (this.isFullSize) { |
| 28188 |
this.toggleFullSize(false); |
| 28189 |
} |
| 28190 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_7__.Dom.safeRemove(this.container); |
| 28191 |
this.__removeGlobalResizeListeners(); |
| 28192 |
/** |
| 28193 |
* It called after the window is closed |
| 28194 |
*/ e.fire(this, 'afterClose'); |
| 28195 |
e.fire(this.ow, 'joditCloseDialog'); |
| 28196 |
if (this.destroyAfterClose) { |
| 28197 |
this.destruct(); |
| 28198 |
} |
| 28199 |
return this; |
| 28200 |
} |
| 28201 |
/** |
| 28202 |
* Build toolbar after ready |
| 28203 |
*/ buildToolbar() { |
| 28204 |
this.o.buttons && this.toolbar.build((0,jodit_core_helpers_array__WEBPACK_IMPORTED_MODULE_9__.splitArray)(this.o.buttons)).setMod('mode', 'header').appendTo(this.dialogbox_toolbar); |
| 28205 |
} |
| 28206 |
/** |
| 28207 |
* It destroys all objects created for the windows and also includes all the handlers for the window object |
| 28208 |
*/ destruct() { |
| 28209 |
if (this.isInDestruct) { |
| 28210 |
return; |
| 28211 |
} |
| 28212 |
this.setStatus(jodit_core_component__WEBPACK_IMPORTED_MODULE_4__.STATUSES.beforeDestruct); |
| 28213 |
if (this.isOpened) { |
| 28214 |
this.close(); |
| 28215 |
} |
| 28216 |
if (this.events) { |
| 28217 |
this.__removeGlobalResizeListeners(); |
| 28218 |
this.events.off(this.container, 'close_dialog', self.close).off(this.ow, 'keydown', this.__onEsc).off(this.ow, 'resize', this.__onResize); |
| 28219 |
} |
| 28220 |
super.destruct(); |
| 28221 |
} |
| 28222 |
constructor(options = {}){ |
| 28223 |
super(options), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "resizer", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "offsetX", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "offsetY", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "destroyAfterClose", false), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "moved", false), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "resizable", false), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "draggable", false), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "startX", 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "startY", 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "startPoint", { |
| 28224 |
x: 0, |
| 28225 |
y: 0, |
| 28226 |
w: 0, |
| 28227 |
h: 0 |
| 28228 |
}), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "lockSelect", ()=>{ |
| 28229 |
this.setMod('moved', true); |
| 28230 |
}), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "unlockSelect", ()=>{ |
| 28231 |
this.setMod('moved', false); |
| 28232 |
}), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__onResize", ()=>{ |
| 28233 |
if (this.options && this.o.resizable && !this.moved && this.isOpened && !this.offsetX && !this.offsetY) { |
| 28234 |
this.setPosition(); |
| 28235 |
} |
| 28236 |
}), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "dialog", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "workplace", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "dialogbox_header", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "dialogbox_content", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "dialogbox_footer", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "dialogbox_toolbar", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "isModal", false), /** |
| 28237 |
* True, if dialog was opened |
| 28238 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "isOpened", false); |
| 28239 |
const self1 = this; |
| 28240 |
self1.options = (0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_11__.ConfigProto)(options, (0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_11__.ConfigProto)(jodit_config__WEBPACK_IMPORTED_MODULE_16__.Config.prototype.dialog, Dialog.defaultOptions)); |
| 28241 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_7__.Dom.safeRemove(self1.container); |
| 28242 |
const n = this.getFullElName.bind(this); |
| 28243 |
self1.container = this.c.fromHTML(`<div class="jodit jodit-dialog ${this.componentName}"> |
| 28244 |
<div class="${n('overlay')}"></div> |
| 28245 |
<div class="${this.getFullElName('panel')}"> |
| 28246 |
<div class="${n('header')}"> |
| 28247 |
<div class="${n('header-title')}"></div> |
| 28248 |
<div class="${n('header-toolbar')}"></div> |
| 28249 |
</div> |
| 28250 |
<div class="${n('content')}"></div> |
| 28251 |
<div class="${n('footer')}"></div> |
| 28252 |
<div class="${n('resizer')}">${jodit_core_ui__WEBPACK_IMPORTED_MODULE_13__.Icon.get('resize_handler')}</div> |
| 28253 |
</div> |
| 28254 |
</div>`); |
| 28255 |
if (self1.options.direction === 'rtl') { |
| 28256 |
self1.container.style.direction = 'rtl'; |
| 28257 |
self1.container.setAttribute('dir', 'rtl'); |
| 28258 |
} |
| 28259 |
if (this.o.zIndex) { |
| 28260 |
this.container.style.zIndex = this.o.zIndex.toString(); |
| 28261 |
} |
| 28262 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_11__.attr)(self1.container, 'role', 'dialog'); |
| 28263 |
Object.defineProperty(self1.container, 'component', { |
| 28264 |
value: this |
| 28265 |
}); |
| 28266 |
self1.setMod('theme', self1.o.theme || 'default').setMod('resizable', Boolean(self1.o.resizable)); |
| 28267 |
const dialog = self1.getElm('panel'); |
| 28268 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_12__.assert)(dialog != null, 'Panel element does not exist'); |
| 28269 |
const resizer = self1.getElm('resizer'); |
| 28270 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_12__.assert)(resizer != null, 'Resizer element does not exist'); |
| 28271 |
const dialogbox_header = self1.getElm('header-title'); |
| 28272 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_12__.assert)(dialogbox_header != null, 'header-title element does not exist'); |
| 28273 |
const dialogbox_content = self1.getElm('content'); |
| 28274 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_12__.assert)(dialogbox_content != null, 'Content element does not exist'); |
| 28275 |
const dialogbox_footer = self1.getElm('footer'); |
| 28276 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_12__.assert)(dialogbox_footer != null, 'Footer element does not exist'); |
| 28277 |
const dialogbox_toolbar = self1.getElm('header-toolbar'); |
| 28278 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_12__.assert)(dialogbox_toolbar != null, 'header-toolbar element does not exist'); |
| 28279 |
this.dialog = dialog; |
| 28280 |
this.resizer = resizer; |
| 28281 |
this.dialogbox_header = dialogbox_header; |
| 28282 |
this.dialogbox_content = dialogbox_content; |
| 28283 |
this.dialogbox_footer = dialogbox_footer; |
| 28284 |
this.dialogbox_toolbar = dialogbox_toolbar; |
| 28285 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_11__.css)(self1.dialog, { |
| 28286 |
maxWidth: self1.options.maxWidth, |
| 28287 |
minHeight: self1.options.minHeight, |
| 28288 |
minWidth: self1.options.minWidth |
| 28289 |
}); |
| 28290 |
const headerBox = self1.getElm('header'); |
| 28291 |
headerBox && self1.e.on(headerBox, 'pointerdown touchstart', self1.__onHeaderMouseDown); |
| 28292 |
self1.e.on(self1.resizer, 'mousedown touchstart', self1.__onResizerMouseDown); |
| 28293 |
const fullSize = jodit_core_global__WEBPACK_IMPORTED_MODULE_8__.pluginSystem.get('fullsize'); |
| 28294 |
(0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_10__.isFunction)(fullSize) && fullSize(self1); |
| 28295 |
this.e.on(self1.container, 'close_dialog', self1.close).on(this.ow, 'keydown', this.__onEsc).on(this.ow, 'resize', this.__onResize); |
| 28296 |
if (this.o.closeOnClickOverlay) { |
| 28297 |
const overlay = self1.getElm('overlay'); |
| 28298 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_12__.assert)(overlay != null, 'Overlay element does not exist'); |
| 28299 |
this.e.on(overlay, 'click', self1.close); |
| 28300 |
} |
| 28301 |
} |
| 28302 |
} |
| 28303 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(Dialog, "defaultOptions", (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_2__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_1__._)({}, jodit_core_view_view__WEBPACK_IMPORTED_MODULE_14__.View.defaultOptions), { |
| 28304 |
closeOnClickOverlay: false, |
| 28305 |
closeOnEsc: true |
| 28306 |
})); |
| 28307 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__.__decorate)([ |
| 28308 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_6__.autobind |
| 28309 |
], Dialog.prototype, "__onMouseUp", null); |
| 28310 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__.__decorate)([ |
| 28311 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_6__.autobind |
| 28312 |
], Dialog.prototype, "__onHeaderMouseDown", null); |
| 28313 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__.__decorate)([ |
| 28314 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_6__.autobind |
| 28315 |
], Dialog.prototype, "__onMouseMove", null); |
| 28316 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__.__decorate)([ |
| 28317 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_6__.autobind |
| 28318 |
], Dialog.prototype, "__onEsc", null); |
| 28319 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__.__decorate)([ |
| 28320 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_6__.autobind |
| 28321 |
], Dialog.prototype, "__onResizerMouseDown", null); |
| 28322 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__.__decorate)([ |
| 28323 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_6__.autobind |
| 28324 |
], Dialog.prototype, "close", null); |
| 28325 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__.__decorate)([ |
| 28326 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_6__.hook)('ready') |
| 28327 |
], Dialog.prototype, "buildToolbar", null); |
| 28328 |
Dialog = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__.__decorate)([ |
| 28329 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_6__.component |
| 28330 |
], Dialog); |
| 28331 |
|
| 28332 |
|
| 28333 |
/***/ }), |
| 28334 |
|
| 28335 |
/***/ 77036: |
| 28336 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 28337 |
|
| 28338 |
"use strict"; |
| 28339 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 28340 |
/* harmony export */ persistent: function() { return /* binding */ persistent; } |
| 28341 |
/* harmony export */ }); |
| 28342 |
/* harmony import */ var jodit_core_component_statuses__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(69364); |
| 28343 |
/* harmony import */ var jodit_core_helpers_checker_is_view_object__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31534); |
| 28344 |
/*! |
| 28345 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 28346 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 28347 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 28348 |
*/ /** |
| 28349 |
* [[include:core/decorators/persistent/README.md]] |
| 28350 |
* @packageDocumentation |
| 28351 |
* @module decorators/persistent |
| 28352 |
*/ |
| 28353 |
|
| 28354 |
function persistent(target, propertyKey) { |
| 28355 |
target.hookStatus(jodit_core_component_statuses__WEBPACK_IMPORTED_MODULE_0__.STATUSES.ready, (component)=>{ |
| 28356 |
const jodit = (0,jodit_core_helpers_checker_is_view_object__WEBPACK_IMPORTED_MODULE_1__.isViewObject)(component) ? component : component.jodit, storageKey = `${jodit.options.namespace}${component.componentName}_prop_${propertyKey}`, initialValue = component[propertyKey]; |
| 28357 |
Object.defineProperty(component, propertyKey, { |
| 28358 |
get () { |
| 28359 |
var _jodit_storage_get; |
| 28360 |
return (_jodit_storage_get = jodit.storage.get(storageKey)) !== null && _jodit_storage_get !== void 0 ? _jodit_storage_get : initialValue; |
| 28361 |
}, |
| 28362 |
set (value) { |
| 28363 |
jodit.storage.set(storageKey, value); |
| 28364 |
} |
| 28365 |
}); |
| 28366 |
}); |
| 28367 |
} |
| 28368 |
|
| 28369 |
|
| 28370 |
/***/ }), |
| 28371 |
|
| 28372 |
/***/ 77213: |
| 28373 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 28374 |
|
| 28375 |
"use strict"; |
| 28376 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 28377 |
/* harmony export */ ctrlKey: function() { return /* binding */ ctrlKey; } |
| 28378 |
/* harmony export */ }); |
| 28379 |
/*! |
| 28380 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 28381 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 28382 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 28383 |
*/ /** |
| 28384 |
* @module helpers/utils |
| 28385 |
*/ /** |
| 28386 |
* CTRL pressed |
| 28387 |
* @returns true ctrl key was pressed |
| 28388 |
*/ const ctrlKey = (e)=>{ |
| 28389 |
if (typeof navigator !== 'undefined' && navigator.userAgent.indexOf('Mac OS X') !== -1) { |
| 28390 |
if (e.metaKey && !e.altKey) { |
| 28391 |
return true; |
| 28392 |
} |
| 28393 |
} else if (e.ctrlKey && !e.altKey) { |
| 28394 |
return true; |
| 28395 |
} |
| 28396 |
return false; |
| 28397 |
}; |
| 28398 |
|
| 28399 |
|
| 28400 |
/***/ }), |
| 28401 |
|
| 28402 |
/***/ 77367: |
| 28403 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 28404 |
|
| 28405 |
"use strict"; |
| 28406 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 28407 |
/* harmony export */ normalizeColor: function() { return /* binding */ normalizeColor; } |
| 28408 |
/* harmony export */ }); |
| 28409 |
/* harmony import */ var jodit_core_helpers_color_color_to_hex__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(93387); |
| 28410 |
/* harmony import */ var jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(4040); |
| 28411 |
/*! |
| 28412 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 28413 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 28414 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 28415 |
*/ /** |
| 28416 |
* @module helpers/normalize |
| 28417 |
*/ |
| 28418 |
|
| 28419 |
/** |
| 28420 |
* Convert rgba and short HEX color to Full text color. #fff to #FFFFFF |
| 28421 |
* |
| 28422 |
* @param colorInput - string like rgba(red, green, blue, alpha) or rgb(red, green, blue) or #fff or #ffffff |
| 28423 |
* @returns HEX color, false - for transparent color |
| 28424 |
*/ const normalizeColor = (colorInput)=>{ |
| 28425 |
const newcolor = [ |
| 28426 |
'#' |
| 28427 |
]; |
| 28428 |
let color = (0,jodit_core_helpers_color_color_to_hex__WEBPACK_IMPORTED_MODULE_0__.colorToHex)(colorInput); |
| 28429 |
if (!color) { |
| 28430 |
return false; |
| 28431 |
} |
| 28432 |
color = (0,jodit_core_helpers_string_trim__WEBPACK_IMPORTED_MODULE_1__.trim)(color.toUpperCase()); |
| 28433 |
color = color.substring(1); |
| 28434 |
if (color.length === 3) { |
| 28435 |
for(let i = 0; i < 3; i += 1){ |
| 28436 |
newcolor.push(color[i]); |
| 28437 |
newcolor.push(color[i]); |
| 28438 |
} |
| 28439 |
return newcolor.join(''); |
| 28440 |
} |
| 28441 |
if (color.length > 6) { |
| 28442 |
color = color.slice(0, 6); |
| 28443 |
} |
| 28444 |
return '#' + color; |
| 28445 |
}; |
| 28446 |
|
| 28447 |
|
| 28448 |
/***/ }), |
| 28449 |
|
| 28450 |
/***/ 77483: |
| 28451 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 28452 |
|
| 28453 |
"use strict"; |
| 28454 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 28455 |
/* harmony export */ ConfigDeepFlatten: function() { return /* binding */ ConfigDeepFlatten; }, |
| 28456 |
/* harmony export */ ConfigFlatten: function() { return /* binding */ ConfigFlatten; }, |
| 28457 |
/* harmony export */ ConfigProto: function() { return /* binding */ ConfigProto; } |
| 28458 |
/* harmony export */ }); |
| 28459 |
/* harmony import */ var jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(17312); |
| 28460 |
/* harmony import */ var jodit_core_helpers_checker_is_plain_object__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(62101); |
| 28461 |
/* harmony import */ var jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(85932); |
| 28462 |
/* harmony import */ var jodit_core_helpers_checker_is_void__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(18303); |
| 28463 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(5266); |
| 28464 |
/* harmony import */ var _extend__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(54794); |
| 28465 |
/* harmony import */ var _utils__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(71125); |
| 28466 |
/*! |
| 28467 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 28468 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 28469 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 28470 |
*/ /** |
| 28471 |
* @module helpers/utils |
| 28472 |
*/ |
| 28473 |
|
| 28474 |
|
| 28475 |
|
| 28476 |
|
| 28477 |
|
| 28478 |
|
| 28479 |
/** |
| 28480 |
* @example |
| 28481 |
* ```js |
| 28482 |
* const defaultConfig = { |
| 28483 |
* a: { |
| 28484 |
* b: { |
| 28485 |
* c: 2 |
| 28486 |
* }, |
| 28487 |
* e: 5 |
| 28488 |
* }, |
| 28489 |
* d: { |
| 28490 |
* g: 7 |
| 28491 |
* } |
| 28492 |
* }; |
| 28493 |
* |
| 28494 |
* const options = ConfigProto({a: { |
| 28495 |
* b: { |
| 28496 |
* c: 1 |
| 28497 |
* } |
| 28498 |
* }}, defaultConfig); |
| 28499 |
* |
| 28500 |
* console.log(options.a.b.c); // 1 |
| 28501 |
* console.log(options.a.e); // 5 |
| 28502 |
* console.log(options.d.g); // 7 |
| 28503 |
* |
| 28504 |
* defaultConfig.d.g = 8; |
| 28505 |
* console.log(options.d.g); // 8 |
| 28506 |
* |
| 28507 |
* ``` |
| 28508 |
*/ function ConfigProto(options, proto, deep = 0) { |
| 28509 |
// Already prototyped object should not be prototyped again |
| 28510 |
if (Object.getPrototypeOf(options) !== Object.prototype) { |
| 28511 |
return options; |
| 28512 |
} |
| 28513 |
const def = jodit_config__WEBPACK_IMPORTED_MODULE_4__.Config.defaultOptions; |
| 28514 |
if ((0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_2__.isString)(options.preset)) { |
| 28515 |
if (def.presets[options.preset] !== undefined) { |
| 28516 |
const preset = def.presets[options.preset]; |
| 28517 |
Object.keys(preset).forEach((subKey)=>{ |
| 28518 |
if ((0,jodit_core_helpers_checker_is_void__WEBPACK_IMPORTED_MODULE_3__.isVoid)(options[subKey])) { |
| 28519 |
options[subKey] = preset[subKey]; |
| 28520 |
} |
| 28521 |
}); |
| 28522 |
} |
| 28523 |
delete options.preset; |
| 28524 |
} |
| 28525 |
const newOpt = {}; |
| 28526 |
Object.keys(options).forEach((key)=>{ |
| 28527 |
const opt = options[key], protoKey = proto ? proto[key] : null; |
| 28528 |
if ((0,jodit_core_helpers_checker_is_plain_object__WEBPACK_IMPORTED_MODULE_1__.isPlainObject)(opt) && (0,jodit_core_helpers_checker_is_plain_object__WEBPACK_IMPORTED_MODULE_1__.isPlainObject)(protoKey) && !(0,_extend__WEBPACK_IMPORTED_MODULE_5__.isAtom)(opt)) { |
| 28529 |
newOpt[key] = ConfigProto(opt, protoKey, deep + 1); |
| 28530 |
return; |
| 28531 |
} |
| 28532 |
// On the first level all arrays are atomic |
| 28533 |
if (deep !== 0 && (0,jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_0__.isArray)(opt) && !(0,_extend__WEBPACK_IMPORTED_MODULE_5__.isAtom)(opt) && (0,jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_0__.isArray)(protoKey)) { |
| 28534 |
newOpt[key] = [ |
| 28535 |
...opt, |
| 28536 |
...protoKey.slice(opt.length) |
| 28537 |
]; |
| 28538 |
return; |
| 28539 |
} |
| 28540 |
newOpt[key] = opt; |
| 28541 |
}); |
| 28542 |
Object.setPrototypeOf(newOpt, proto); |
| 28543 |
return newOpt; |
| 28544 |
} |
| 28545 |
function ConfigFlatten(obj) { |
| 28546 |
return (0,_utils__WEBPACK_IMPORTED_MODULE_6__.keys)(obj, false).reduce((app, key)=>{ |
| 28547 |
app[key] = obj[key]; |
| 28548 |
return app; |
| 28549 |
}, {}); |
| 28550 |
} |
| 28551 |
/** |
| 28552 |
* Returns a plain object from a prototype-based object. |
| 28553 |
* ```typescript |
| 28554 |
* const editor = Jodit.make('#editor', { |
| 28555 |
* image: { |
| 28556 |
* dialogWidth: 500 |
| 28557 |
* } |
| 28558 |
* }); |
| 28559 |
* |
| 28560 |
* console.log(editor.o.image.openOnDblClick) // true |
| 28561 |
* // But you can't get all options in plain object |
| 28562 |
* console.log(JSON.stringify(editor.o.image)); // {"dialogWidth":500} |
| 28563 |
* |
| 28564 |
* const plain = Jodit.modules.Helpers.ConfigDeepFlatten(editor.o.image); |
| 28565 |
* console.log(JSON.stringify(plain)); // {"dialogWidth":500, "openOnDblClick": true, "editSrc": true, ...} |
| 28566 |
* ``` |
| 28567 |
*/ function ConfigDeepFlatten(obj) { |
| 28568 |
return (0,_utils__WEBPACK_IMPORTED_MODULE_6__.keys)(obj, false).reduce((app, key)=>{ |
| 28569 |
app[key] = (0,jodit_core_helpers_checker_is_plain_object__WEBPACK_IMPORTED_MODULE_1__.isPlainObject)(obj[key]) ? ConfigDeepFlatten(obj[key]) : obj[key]; |
| 28570 |
return app; |
| 28571 |
}, {}); |
| 28572 |
} |
| 28573 |
|
| 28574 |
|
| 28575 |
/***/ }), |
| 28576 |
|
| 28577 |
/***/ 77911: |
| 28578 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 28579 |
|
| 28580 |
"use strict"; |
| 28581 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 28582 |
/* harmony export */ ajaxInstances: function() { return /* binding */ ajaxInstances; }, |
| 28583 |
/* harmony export */ send: function() { return /* binding */ send; } |
| 28584 |
/* harmony export */ }); |
| 28585 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(65946); |
| 28586 |
/* harmony import */ var jodit_core_request__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(73714); |
| 28587 |
/* harmony import */ var jodit_modules_uploader_helpers_build_data__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(89446); |
| 28588 |
/*! |
| 28589 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 28590 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 28591 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 28592 |
*/ /** |
| 28593 |
* @module modules/uploader |
| 28594 |
*/ |
| 28595 |
|
| 28596 |
|
| 28597 |
const ajaxInstances = new WeakMap(); |
| 28598 |
function send(uploader, data) { |
| 28599 |
const requestData = (0,jodit_modules_uploader_helpers_build_data__WEBPACK_IMPORTED_MODULE_2__.buildData)(uploader, data); |
| 28600 |
const showProgress = (progress)=>{ |
| 28601 |
uploader.j.progressbar.show().progress(progress); |
| 28602 |
if (progress >= 100) { |
| 28603 |
uploader.j.progressbar.hide(); |
| 28604 |
} |
| 28605 |
}; |
| 28606 |
let sendData = (request, showProgress)=>{ |
| 28607 |
const ajax = new jodit_core_request__WEBPACK_IMPORTED_MODULE_1__.Ajax({ |
| 28608 |
xhr: ()=>{ |
| 28609 |
const xhr = new XMLHttpRequest(); |
| 28610 |
if (uploader.j.ow.FormData !== undefined && xhr.upload) { |
| 28611 |
showProgress(10); |
| 28612 |
xhr.upload.addEventListener('progress', (evt)=>{ |
| 28613 |
if (evt.lengthComputable) { |
| 28614 |
let percentComplete = evt.loaded / evt.total; |
| 28615 |
percentComplete *= 100; |
| 28616 |
showProgress(percentComplete); |
| 28617 |
} |
| 28618 |
}, false); |
| 28619 |
} else { |
| 28620 |
showProgress(100); |
| 28621 |
} |
| 28622 |
return xhr; |
| 28623 |
}, |
| 28624 |
method: uploader.o.method || 'POST', |
| 28625 |
data: request, |
| 28626 |
url: (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_0__.isFunction)(uploader.o.url) ? uploader.o.url(request) : uploader.o.url, |
| 28627 |
headers: uploader.o.headers, |
| 28628 |
queryBuild: uploader.o.queryBuild, |
| 28629 |
contentType: uploader.o.contentType.call(uploader, request), |
| 28630 |
withCredentials: uploader.o.withCredentials || false |
| 28631 |
}); |
| 28632 |
let instances = ajaxInstances.get(uploader); |
| 28633 |
if (!instances) { |
| 28634 |
instances = new Set(); |
| 28635 |
ajaxInstances.set(uploader, instances); |
| 28636 |
} |
| 28637 |
instances.add(ajax); |
| 28638 |
uploader.j.e.one('beforeDestruct', ajax.destruct); |
| 28639 |
return ajax.send().then((resp)=>resp.json()).catch((error)=>{ |
| 28640 |
return { |
| 28641 |
success: false, |
| 28642 |
data: { |
| 28643 |
messages: [ |
| 28644 |
error |
| 28645 |
] |
| 28646 |
} |
| 28647 |
}; |
| 28648 |
}).finally(()=>{ |
| 28649 |
ajax.destruct(); |
| 28650 |
instances === null || instances === void 0 ? void 0 : instances.delete(ajax); |
| 28651 |
}); |
| 28652 |
}; |
| 28653 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_0__.isFunction)(uploader.o.customUploadFunction)) { |
| 28654 |
sendData = uploader.o.customUploadFunction; |
| 28655 |
} |
| 28656 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_0__.isPromise)(requestData)) { |
| 28657 |
return requestData.then((data)=>sendData(data, showProgress)).catch((error)=>{ |
| 28658 |
uploader.o.error.call(uploader, error); |
| 28659 |
}); |
| 28660 |
} |
| 28661 |
return sendData(requestData, showProgress); |
| 28662 |
} |
| 28663 |
|
| 28664 |
|
| 28665 |
/***/ }), |
| 28666 |
|
| 28667 |
/***/ 78462: |
| 28668 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 28669 |
|
| 28670 |
"use strict"; |
| 28671 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 28672 |
/* harmony export */ states: function() { return /* binding */ states; }, |
| 28673 |
/* harmony export */ transactions: function() { return /* binding */ transactions; } |
| 28674 |
/* harmony export */ }); |
| 28675 |
/* harmony import */ var _swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(41411); |
| 28676 |
/* harmony import */ var _swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(15366); |
| 28677 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(81937); |
| 28678 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(23211); |
| 28679 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(28712); |
| 28680 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_4__); |
| 28681 |
/* harmony import */ var jodit_core_selection_style_api__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(51640); |
| 28682 |
/* harmony import */ var jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(98394); |
| 28683 |
/*! |
| 28684 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 28685 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 28686 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 28687 |
*/ /** |
| 28688 |
* @module selection |
| 28689 |
*/ |
| 28690 |
|
| 28691 |
|
| 28692 |
|
| 28693 |
|
| 28694 |
|
| 28695 |
|
| 28696 |
const states = { |
| 28697 |
START: 'START', |
| 28698 |
ELEMENT: 'ELEMENT', |
| 28699 |
UNWRAP: 'UNWRAP', |
| 28700 |
UNWRAP_CHILDREN: 'UNWRAP_CHILDREN', |
| 28701 |
CHANGE: 'CHANGE', |
| 28702 |
REPLACE_DEFAULT: 'REPLACE_DEFAULT', |
| 28703 |
LIST: 'LIST', |
| 28704 |
TOGGLE_LIST: 'TOGGLE_LIST', |
| 28705 |
WRAP: 'WRAP', |
| 28706 |
EXTRACT: 'EXTRACT', |
| 28707 |
END: 'END' |
| 28708 |
}; |
| 28709 |
const transactions = { |
| 28710 |
[states.START]: { |
| 28711 |
exec (value) { |
| 28712 |
const { element, jodit, style, mode, collapsed } = value; |
| 28713 |
if ((0,jodit_core_selection_style_api__WEBPACK_IMPORTED_MODULE_5__.isInsideInvisibleElement)(element, jodit.editor) || !collapsed && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.isEmptyContent(element)) { |
| 28714 |
return (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_1__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__._)({}, value), { |
| 28715 |
next: states.END |
| 28716 |
}); |
| 28717 |
} |
| 28718 |
const elm = (0,jodit_core_selection_style_api__WEBPACK_IMPORTED_MODULE_5__.getSuitParent)(style, element, jodit.editor) || (0,jodit_core_selection_style_api__WEBPACK_IMPORTED_MODULE_5__.getSuitChild)(style, element); |
| 28719 |
if (elm) { |
| 28720 |
return (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_1__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__._)({}, value), { |
| 28721 |
next: states.ELEMENT, |
| 28722 |
element: elm |
| 28723 |
}); |
| 28724 |
} |
| 28725 |
const suit = (0,jodit_core_selection_style_api__WEBPACK_IMPORTED_MODULE_5__.suitableClosest)(style, element, jodit.editor); |
| 28726 |
if (style.elementIsList && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.isList(suit)) { |
| 28727 |
return (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_1__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__._)({}, value), { |
| 28728 |
next: states.LIST |
| 28729 |
}); |
| 28730 |
} |
| 28731 |
if (suit) { |
| 28732 |
return (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_1__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__._)({}, value), { |
| 28733 |
next: states.EXTRACT |
| 28734 |
}); |
| 28735 |
} |
| 28736 |
return (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_1__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__._)({}, value), { |
| 28737 |
next: mode !== jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_6__.UNWRAP ? states.UNWRAP_CHILDREN : states.END |
| 28738 |
}); |
| 28739 |
} |
| 28740 |
}, |
| 28741 |
[states.LIST]: { |
| 28742 |
exec (value) { |
| 28743 |
const { element, jodit, mode } = value; |
| 28744 |
if (mode !== jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_6__.INITIAL && mode !== jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_6__.UNWRAP && mode !== jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_6__.REPLACE) { |
| 28745 |
return (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_1__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__._)({}, value), { |
| 28746 |
next: states.END |
| 28747 |
}); |
| 28748 |
} |
| 28749 |
const li = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.closest(element, 'li', jodit.editor); |
| 28750 |
if (!li) { |
| 28751 |
return (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_1__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__._)({}, value), { |
| 28752 |
next: states.END |
| 28753 |
}); |
| 28754 |
} |
| 28755 |
const list = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.closest(element, jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.LIST_TAGS, jodit.editor); |
| 28756 |
if (list) { |
| 28757 |
return (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_1__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__._)({}, value), { |
| 28758 |
element: li, |
| 28759 |
next: states.TOGGLE_LIST |
| 28760 |
}); |
| 28761 |
} |
| 28762 |
return (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_1__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__._)({}, value), { |
| 28763 |
next: states.END |
| 28764 |
}); |
| 28765 |
} |
| 28766 |
}, |
| 28767 |
[states.TOGGLE_LIST]: { |
| 28768 |
exec (value) { |
| 28769 |
return (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_1__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__._)({}, value), { |
| 28770 |
mode: (0,jodit_core_selection_style_api__WEBPACK_IMPORTED_MODULE_5__.toggleOrderedList)(value.style, value.element, value.jodit, value.mode), |
| 28771 |
next: states.END |
| 28772 |
}); |
| 28773 |
} |
| 28774 |
}, |
| 28775 |
[states.EXTRACT]: { |
| 28776 |
exec (value) { |
| 28777 |
var _style_options_attributes; |
| 28778 |
const { element, jodit, style } = value; |
| 28779 |
const suit = (0,jodit_core_selection_style_api__WEBPACK_IMPORTED_MODULE_5__.suitableClosest)(style, element, jodit.editor); |
| 28780 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_4__.assert)(suit, 'This place should have an element'); |
| 28781 |
// If we're applying inline styles to a block element, don't split the block |
| 28782 |
const isApplyingInlineStyle = !style.elementIsBlock && ((_style_options_attributes = style.options.attributes) === null || _style_options_attributes === void 0 ? void 0 : _style_options_attributes.style); |
| 28783 |
const shouldNotSplitBlock = isApplyingInlineStyle && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.isBlock(suit); |
| 28784 |
if (!shouldNotSplitBlock) { |
| 28785 |
if (!style.elementIsBlock) { |
| 28786 |
(0,jodit_core_selection_style_api__WEBPACK_IMPORTED_MODULE_5__.extractSelectedPart)(suit, element, jodit); |
| 28787 |
} |
| 28788 |
return (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_1__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__._)({}, value), { |
| 28789 |
element: suit, |
| 28790 |
next: states.ELEMENT |
| 28791 |
}); |
| 28792 |
} |
| 28793 |
// Create a new wrapper instead of splitting the block |
| 28794 |
return (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_1__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__._)({}, value), { |
| 28795 |
next: states.WRAP |
| 28796 |
}); |
| 28797 |
} |
| 28798 |
}, |
| 28799 |
[states.UNWRAP_CHILDREN]: { |
| 28800 |
exec (value) { |
| 28801 |
const { element, style } = value; |
| 28802 |
if (!(0,jodit_core_selection_style_api__WEBPACK_IMPORTED_MODULE_5__.unwrapChildren)(style, element)) { |
| 28803 |
return (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_1__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__._)({}, value), { |
| 28804 |
next: states.WRAP |
| 28805 |
}); |
| 28806 |
} |
| 28807 |
return (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_1__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__._)({}, value), { |
| 28808 |
mode: jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_6__.UNWRAP, |
| 28809 |
next: states.END |
| 28810 |
}); |
| 28811 |
} |
| 28812 |
}, |
| 28813 |
[states.WRAP]: { |
| 28814 |
exec (value) { |
| 28815 |
const { element, jodit, style } = value; |
| 28816 |
const wrapper = (0,jodit_core_selection_style_api__WEBPACK_IMPORTED_MODULE_5__.wrap)(style, element, jodit); |
| 28817 |
return (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_1__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__._)({}, value), { |
| 28818 |
next: style.elementIsList ? states.END : states.CHANGE, |
| 28819 |
mode: jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_6__.WRAP, |
| 28820 |
element: wrapper |
| 28821 |
}); |
| 28822 |
} |
| 28823 |
}, |
| 28824 |
[states.ELEMENT]: { |
| 28825 |
exec (value) { |
| 28826 |
const { style, element, jodit } = value; |
| 28827 |
if ((0,jodit_core_selection_style_api__WEBPACK_IMPORTED_MODULE_5__.toggleAttributes)(style, element, jodit, jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_6__.INITIAL, true) !== jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_6__.INITIAL) { |
| 28828 |
return (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_1__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__._)({}, value), { |
| 28829 |
next: states.CHANGE |
| 28830 |
}); |
| 28831 |
} |
| 28832 |
// Apply same color for anchor https://github.com/xdan/jodit/issues/936 |
| 28833 |
if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.isTag(element, style.element)) { |
| 28834 |
return (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_1__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__._)({}, value), { |
| 28835 |
next: states.END |
| 28836 |
}); |
| 28837 |
} |
| 28838 |
return (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_1__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__._)({}, value), { |
| 28839 |
next: states.UNWRAP |
| 28840 |
}); |
| 28841 |
} |
| 28842 |
}, |
| 28843 |
[states.CHANGE]: { |
| 28844 |
exec (value) { |
| 28845 |
const { style, element, jodit, mode } = value; |
| 28846 |
const newMode = (0,jodit_core_selection_style_api__WEBPACK_IMPORTED_MODULE_5__.toggleAttributes)(style, element, jodit, value.mode); |
| 28847 |
if (mode !== jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_6__.WRAP && newMode === jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_6__.UNSET && !element.attributes.length && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.isTag(element, style.element)) { |
| 28848 |
return (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_1__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__._)({}, value), { |
| 28849 |
next: states.UNWRAP |
| 28850 |
}); |
| 28851 |
} |
| 28852 |
return (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_1__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__._)({}, value), { |
| 28853 |
mode: newMode, |
| 28854 |
next: states.END |
| 28855 |
}); |
| 28856 |
} |
| 28857 |
}, |
| 28858 |
[states.UNWRAP]: { |
| 28859 |
exec (value) { |
| 28860 |
if (value.element.attributes.length && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.isTag(value.element, value.style.element)) { |
| 28861 |
return (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_1__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__._)({}, value), { |
| 28862 |
next: states.REPLACE_DEFAULT |
| 28863 |
}); |
| 28864 |
} |
| 28865 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.unwrap(value.element); |
| 28866 |
return (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_1__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__._)({}, value), { |
| 28867 |
mode: jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_6__.UNWRAP, |
| 28868 |
next: states.END |
| 28869 |
}); |
| 28870 |
} |
| 28871 |
}, |
| 28872 |
[states.REPLACE_DEFAULT]: { |
| 28873 |
exec (value) { |
| 28874 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.replace(value.element, value.style.defaultTag, value.jodit.createInside, true); |
| 28875 |
return (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_1__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__._)({}, value), { |
| 28876 |
mode: jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_6__.REPLACE, |
| 28877 |
next: states.END |
| 28878 |
}); |
| 28879 |
} |
| 28880 |
}, |
| 28881 |
[states.END]: { |
| 28882 |
exec (value) { |
| 28883 |
return value; |
| 28884 |
} |
| 28885 |
} |
| 28886 |
}; |
| 28887 |
|
| 28888 |
|
| 28889 |
/***/ }), |
| 28890 |
|
| 28891 |
/***/ 78982: |
| 28892 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 28893 |
|
| 28894 |
"use strict"; |
| 28895 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 28896 |
/* harmony export */ asArray: function() { return /* binding */ asArray; } |
| 28897 |
/* harmony export */ }); |
| 28898 |
/* harmony import */ var jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(17312); |
| 28899 |
/*! |
| 28900 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 28901 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 28902 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 28903 |
*/ /** |
| 28904 |
* @module helpers/array |
| 28905 |
*/ |
| 28906 |
/** |
| 28907 |
* Always return Array |
| 28908 |
* ```javascript |
| 28909 |
* Jodit.modules.Helpers.asArray('test') // ['test'] |
| 28910 |
* Jodit.modules.Helpers.asArray(['test']) // ['test'] |
| 28911 |
* Jodit.modules.Helpers.asArray(1) // [1] |
| 28912 |
* ``` |
| 28913 |
*/ const asArray = (a)=>(0,jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_0__.isArray)(a) ? a : [ |
| 28914 |
a |
| 28915 |
]; |
| 28916 |
|
| 28917 |
|
| 28918 |
/***/ }), |
| 28919 |
|
| 28920 |
/***/ 79310: |
| 28921 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 28922 |
|
| 28923 |
"use strict"; |
| 28924 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 28925 |
/* harmony export */ readLink: function() { return /* binding */ readLink; } |
| 28926 |
/* harmony export */ }); |
| 28927 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 28928 |
/* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(7909); |
| 28929 |
/*! |
| 28930 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 28931 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 28932 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 28933 |
*/ /** |
| 28934 |
* @module plugins/image-properties |
| 28935 |
*/ |
| 28936 |
|
| 28937 |
/** @private */ function readLink(state, j, values) { |
| 28938 |
const a = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(state.sourceImage, 'a', j.editor); |
| 28939 |
if (a) { |
| 28940 |
values.imageLink = (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(a, 'href') || ''; |
| 28941 |
values.imageLinkOpenInNewTab = (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_1__.attr)(a, 'target') === '_blank'; |
| 28942 |
} else { |
| 28943 |
values.imageLink = ''; |
| 28944 |
values.imageLinkOpenInNewTab = false; |
| 28945 |
} |
| 28946 |
} |
| 28947 |
|
| 28948 |
|
| 28949 |
/***/ }), |
| 28950 |
|
| 28951 |
/***/ 79821: |
| 28952 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 28953 |
|
| 28954 |
"use strict"; |
| 28955 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 28956 |
/* harmony export */ Create: function() { return /* reexport safe */ _create__WEBPACK_IMPORTED_MODULE_0__.Create; } |
| 28957 |
/* harmony export */ }); |
| 28958 |
/* harmony import */ var _create__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(76517); |
| 28959 |
/*! |
| 28960 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 28961 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 28962 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 28963 |
*/ /** |
| 28964 |
* @module create |
| 28965 |
*/ |
| 28966 |
|
| 28967 |
|
| 28968 |
/***/ }), |
| 28969 |
|
| 28970 |
/***/ 79947: |
| 28971 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 28972 |
|
| 28973 |
"use strict"; |
| 28974 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 28975 |
/* harmony export */ clearTimeout: function() { return /* binding */ clearTimeout; }, |
| 28976 |
/* harmony export */ setTimeout: function() { return /* binding */ setTimeout; } |
| 28977 |
/* harmony export */ }); |
| 28978 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 28979 |
/*! |
| 28980 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 28981 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 28982 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 28983 |
*/ /** |
| 28984 |
* @module helpers/async |
| 28985 |
*/ |
| 28986 |
/** |
| 28987 |
* Create async callback if set timeout value - else call function immediately |
| 28988 |
*/ function setTimeout(callback, timeout, ...args) { |
| 28989 |
if (!timeout) { |
| 28990 |
callback.call(null, ...args); |
| 28991 |
} else { |
| 28992 |
return jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.globalWindow.setTimeout(callback, timeout, ...args); |
| 28993 |
} |
| 28994 |
return 0; |
| 28995 |
} |
| 28996 |
/** |
| 28997 |
* Clear timeout |
| 28998 |
*/ function clearTimeout(timer) { |
| 28999 |
jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.globalWindow.clearTimeout(timer); |
| 29000 |
} |
| 29001 |
|
| 29002 |
|
| 29003 |
/***/ }), |
| 29004 |
|
| 29005 |
/***/ 80251: |
| 29006 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 29007 |
|
| 29008 |
"use strict"; |
| 29009 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 29010 |
/* harmony export */ Component: function() { return /* binding */ Component; } |
| 29011 |
/* harmony export */ }); |
| 29012 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 29013 |
/* harmony import */ var jodit_core_async__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(91231); |
| 29014 |
/* harmony import */ var jodit_core_component_statuses__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(69364); |
| 29015 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(28077); |
| 29016 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(65946); |
| 29017 |
/*! |
| 29018 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 29019 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 29020 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 29021 |
*/ /** |
| 29022 |
* [[include:core/component/README.md]] |
| 29023 |
* @packageDocumentation |
| 29024 |
* @module component |
| 29025 |
*/ |
| 29026 |
|
| 29027 |
|
| 29028 |
|
| 29029 |
|
| 29030 |
const StatusListHandlers = new Map(); |
| 29031 |
/** |
| 29032 |
* The base class of all Jodit UI components. Provides work with a life cycle. |
| 29033 |
*/ class Component { |
| 29034 |
get componentName() { |
| 29035 |
if (!this.__componentName) { |
| 29036 |
this.__componentName = 'jodit-' + (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.kebabCase)(((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.isFunction)(this.className) ? this.className() : '') || (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.getClassName)(this)); |
| 29037 |
} |
| 29038 |
return this.__componentName; |
| 29039 |
} |
| 29040 |
getFullElName(elementName, mod, modValue) { |
| 29041 |
const result = [ |
| 29042 |
this.componentName |
| 29043 |
]; |
| 29044 |
if (elementName) { |
| 29045 |
elementName = elementName.replace(/[^a-z0-9-]/gi, '-'); |
| 29046 |
result.push(`__${elementName}`); |
| 29047 |
} |
| 29048 |
if (mod) { |
| 29049 |
result.push('_', mod); |
| 29050 |
result.push('_', (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.isVoid)(modValue) ? 'true' : modValue.toString()); |
| 29051 |
} |
| 29052 |
return result.join(''); |
| 29053 |
} |
| 29054 |
/** |
| 29055 |
* The document in which jodit was created |
| 29056 |
*/ get ownerDocument() { |
| 29057 |
return this.ow.document; |
| 29058 |
} |
| 29059 |
/** |
| 29060 |
* Shortcut for `this.ownerDocument` |
| 29061 |
*/ get od() { |
| 29062 |
return this.ownerDocument; |
| 29063 |
} |
| 29064 |
get ow() { |
| 29065 |
return this.ownerWindow; |
| 29066 |
} |
| 29067 |
/** |
| 29068 |
* Safe get any field |
| 29069 |
* @example |
| 29070 |
* ```js |
| 29071 |
* private a = { |
| 29072 |
* b: { |
| 29073 |
* c: { |
| 29074 |
* e: { |
| 29075 |
* g: { |
| 29076 |
* color: 'red' |
| 29077 |
* } |
| 29078 |
* } |
| 29079 |
* } |
| 29080 |
* } |
| 29081 |
* } |
| 29082 |
* |
| 29083 |
* this.get('a.b.c.e.g.color'); // Safe access to color |
| 29084 |
* // instead using optionsl chaining |
| 29085 |
* this?.a?.b?.c?.e?.g?.color |
| 29086 |
* ``` |
| 29087 |
* |
| 29088 |
* @param chain - the path to be traversed in the obj object |
| 29089 |
* @param obj - the object in which the value is searched |
| 29090 |
*/ get(chain, obj) { |
| 29091 |
return (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.get)(chain, obj || this); |
| 29092 |
} |
| 29093 |
/** |
| 29094 |
* Component is ready for work |
| 29095 |
*/ get isReady() { |
| 29096 |
return this.componentStatus === jodit_core_component_statuses__WEBPACK_IMPORTED_MODULE_2__.STATUSES.ready; |
| 29097 |
} |
| 29098 |
/** |
| 29099 |
* Component was destructed |
| 29100 |
*/ get isDestructed() { |
| 29101 |
return this.componentStatus === jodit_core_component_statuses__WEBPACK_IMPORTED_MODULE_2__.STATUSES.destructed; |
| 29102 |
} |
| 29103 |
/** |
| 29104 |
* The component is currently undergoing destructuring or has already been destroyed. |
| 29105 |
* Those. you should not the app froze new events on him now or do anything else with him. |
| 29106 |
*/ get isInDestruct() { |
| 29107 |
return jodit_core_component_statuses__WEBPACK_IMPORTED_MODULE_2__.STATUSES.beforeDestruct === this.componentStatus || jodit_core_component_statuses__WEBPACK_IMPORTED_MODULE_2__.STATUSES.destructed === this.componentStatus; |
| 29108 |
} |
| 29109 |
/** |
| 29110 |
* Bind destructor to some View |
| 29111 |
*/ bindDestruct(component) { |
| 29112 |
component.hookStatus(jodit_core_component_statuses__WEBPACK_IMPORTED_MODULE_2__.STATUSES.beforeDestruct, ()=>!this.isInDestruct && this.destruct()); |
| 29113 |
return this; |
| 29114 |
} |
| 29115 |
/** |
| 29116 |
* Destruct component method |
| 29117 |
*/ destruct() { |
| 29118 |
this.setStatus(jodit_core_component_statuses__WEBPACK_IMPORTED_MODULE_2__.STATUSES.destructed); |
| 29119 |
if (this.async) { |
| 29120 |
this.async.destruct(); |
| 29121 |
// @ts-ignore |
| 29122 |
this.async = undefined; |
| 29123 |
} |
| 29124 |
if (StatusListHandlers.get(this)) { |
| 29125 |
StatusListHandlers.delete(this); |
| 29126 |
} |
| 29127 |
// @ts-ignore |
| 29128 |
this.ownerWindow = undefined; |
| 29129 |
} |
| 29130 |
/** |
| 29131 |
* Current component status |
| 29132 |
*/ get componentStatus() { |
| 29133 |
return this.__componentStatus; |
| 29134 |
} |
| 29135 |
/** |
| 29136 |
* Setter for current component status |
| 29137 |
*/ set componentStatus(componentStatus) { |
| 29138 |
this.setStatus(componentStatus); |
| 29139 |
} |
| 29140 |
/** |
| 29141 |
* Set component status |
| 29142 |
* @param componentStatus - component status |
| 29143 |
* @see ComponentStatus |
| 29144 |
*/ setStatus(componentStatus) { |
| 29145 |
return this.setStatusComponent(componentStatus, this); |
| 29146 |
} |
| 29147 |
/** |
| 29148 |
* Set status recursively on all parents |
| 29149 |
*/ setStatusComponent(componentStatus, component) { |
| 29150 |
if (componentStatus === this.__componentStatus) { |
| 29151 |
return; |
| 29152 |
} |
| 29153 |
if (component === this) { |
| 29154 |
this.__componentStatus = componentStatus; |
| 29155 |
} |
| 29156 |
const proto = Object.getPrototypeOf(this); |
| 29157 |
if (proto && (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.isFunction)(proto.setStatusComponent)) { |
| 29158 |
proto.setStatusComponent(componentStatus, component); |
| 29159 |
} |
| 29160 |
const statuses = StatusListHandlers.get(this), list = statuses === null || statuses === void 0 ? void 0 : statuses[componentStatus]; |
| 29161 |
if (list && list.length) { |
| 29162 |
list.forEach((cb)=>cb(component)); |
| 29163 |
} |
| 29164 |
} |
| 29165 |
/** |
| 29166 |
* Adds a handler for changing the component's status |
| 29167 |
* |
| 29168 |
* @param status - the status at which the callback is triggered |
| 29169 |
* @param callback - a function that will be called when the status is `status` |
| 29170 |
*/ hookStatus(status, callback) { |
| 29171 |
let list = StatusListHandlers.get(this); |
| 29172 |
if (!list) { |
| 29173 |
list = {}; |
| 29174 |
StatusListHandlers.set(this, list); |
| 29175 |
} |
| 29176 |
if (!list[status]) { |
| 29177 |
list[status] = []; |
| 29178 |
} |
| 29179 |
list[status].push(callback); |
| 29180 |
} |
| 29181 |
static isInstanceOf(c, constructorFunc) { |
| 29182 |
return c instanceof constructorFunc; |
| 29183 |
} |
| 29184 |
constructor(){ |
| 29185 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__componentName", void 0); |
| 29186 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "async", new jodit_core_async__WEBPACK_IMPORTED_MODULE_1__.Async()); |
| 29187 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "uid", void 0); |
| 29188 |
/** |
| 29189 |
* The window in which jodit was created |
| 29190 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "ownerWindow", window); |
| 29191 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__componentStatus", jodit_core_component_statuses__WEBPACK_IMPORTED_MODULE_2__.STATUSES.beforeInit); |
| 29192 |
this.uid = 'jodit-uid-' + (0,jodit_core_global__WEBPACK_IMPORTED_MODULE_3__.uniqueUid)(); |
| 29193 |
} |
| 29194 |
} |
| 29195 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(Component, "STATUSES", jodit_core_component_statuses__WEBPACK_IMPORTED_MODULE_2__.STATUSES); |
| 29196 |
|
| 29197 |
|
| 29198 |
/***/ }), |
| 29199 |
|
| 29200 |
/***/ 80347: |
| 29201 |
/***/ (function(module) { |
| 29202 |
|
| 29203 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 24 24\" > <circle cx=\"12\" cy=\"12\" r=\"2.2\"/> <circle cx=\"12\" cy=\"5\" r=\"2.2\"/> <circle cx=\"12\" cy=\"19\" r=\"2.2\"/> </svg>" |
| 29204 |
|
| 29205 |
/***/ }), |
| 29206 |
|
| 29207 |
/***/ 80512: |
| 29208 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 29209 |
|
| 29210 |
"use strict"; |
| 29211 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 29212 |
/* harmony export */ Dlgs: function() { return /* binding */ Dlgs; } |
| 29213 |
/* harmony export */ }); |
| 29214 |
/* harmony import */ var _swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(41411); |
| 29215 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(28077); |
| 29216 |
/* harmony import */ var jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(28686); |
| 29217 |
/* harmony import */ var jodit_core_helpers_utils_utils__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(71125); |
| 29218 |
/* harmony import */ var jodit_modules_dialog__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(37333); |
| 29219 |
/*! |
| 29220 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 29221 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 29222 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 29223 |
*/ /** |
| 29224 |
* @module traits |
| 29225 |
*/ |
| 29226 |
|
| 29227 |
|
| 29228 |
|
| 29229 |
|
| 29230 |
class Dlgs { |
| 29231 |
dlg(options) { |
| 29232 |
const popupRoot = (0,jodit_core_global__WEBPACK_IMPORTED_MODULE_1__.getPopupViewRoot)(this.o, this.container, this.od.body); |
| 29233 |
const dialog = new jodit_modules_dialog__WEBPACK_IMPORTED_MODULE_4__.Dialog((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__._)({ |
| 29234 |
language: this.o.language, |
| 29235 |
shadowRoot: this.o.shadowRoot, |
| 29236 |
popupRoot, |
| 29237 |
ownerWindow: this.o.ownerWindow, |
| 29238 |
defaultTimeout: this.o.defaultTimeout, |
| 29239 |
direction: this.o.direction, |
| 29240 |
theme: this.o.theme, |
| 29241 |
globalFullSize: this.o.globalFullSize |
| 29242 |
}, options)); |
| 29243 |
(0,jodit_core_helpers_utils_utils__WEBPACK_IMPORTED_MODULE_3__.markOwner)(this, dialog.container); |
| 29244 |
dialog.parent = this; |
| 29245 |
return dialog.bindDestruct(this); |
| 29246 |
} |
| 29247 |
confirm(msg, title, callback) { |
| 29248 |
msg = processTitle(msg, this); |
| 29249 |
title = processTitle(title, this); |
| 29250 |
return jodit_modules_dialog__WEBPACK_IMPORTED_MODULE_4__.Confirm.call(this.dlg({ |
| 29251 |
closeOnClickOverlay: true |
| 29252 |
}), msg, title, callback); |
| 29253 |
} |
| 29254 |
prompt(msg, title, callback, placeholder, defaultValue) { |
| 29255 |
msg = processTitle(msg, this); |
| 29256 |
title = processTitle(title, this); |
| 29257 |
placeholder = processTitle(placeholder, this); |
| 29258 |
return jodit_modules_dialog__WEBPACK_IMPORTED_MODULE_4__.Prompt.call(this.dlg({ |
| 29259 |
closeOnClickOverlay: true |
| 29260 |
}), msg, title, callback, placeholder, defaultValue); |
| 29261 |
} |
| 29262 |
alert(msg, title, callback, className) { |
| 29263 |
msg = processTitle(msg, this); |
| 29264 |
title = processTitle(title, this); |
| 29265 |
return jodit_modules_dialog__WEBPACK_IMPORTED_MODULE_4__.Alert.call(this.dlg({ |
| 29266 |
closeOnClickOverlay: true |
| 29267 |
}), msg, title, callback, className); |
| 29268 |
} |
| 29269 |
} |
| 29270 |
function processTitle(title, self) { |
| 29271 |
if ((0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_2__.isString)(title) && !(0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_2__.isHTML)(title)) { |
| 29272 |
title = self.i18n(title); |
| 29273 |
} |
| 29274 |
return title; |
| 29275 |
} |
| 29276 |
|
| 29277 |
|
| 29278 |
/***/ }), |
| 29279 |
|
| 29280 |
/***/ 80515: |
| 29281 |
/***/ (function(module) { |
| 29282 |
|
| 29283 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M1792 1344v128q0 26-19 45t-45 19h-1664q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1664q26 0 45 19t19 45zm0-384v128q0 26-19 45t-45 19h-1664q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1664q26 0 45 19t19 45zm0-384v128q0 26-19 45t-45 19h-1664q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1664q26 0 45 19t19 45zm0-384v128q0 26-19 45t-45 19h-1664q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1664q26 0 45 19t19 45z\"/> </svg>" |
| 29284 |
|
| 29285 |
/***/ }), |
| 29286 |
|
| 29287 |
/***/ 80538: |
| 29288 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 29289 |
|
| 29290 |
"use strict"; |
| 29291 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 29292 |
/* harmony import */ var jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(29434); |
| 29293 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5266); |
| 29294 |
/* harmony import */ var _icons_fullsize_svg__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(24772); |
| 29295 |
/* harmony import */ var _icons_fullsize_svg__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_icons_fullsize_svg__WEBPACK_IMPORTED_MODULE_3__); |
| 29296 |
/* harmony import */ var _icons_shrink_svg__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(66547); |
| 29297 |
/* harmony import */ var _icons_shrink_svg__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_icons_shrink_svg__WEBPACK_IMPORTED_MODULE_4__); |
| 29298 |
/*! |
| 29299 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 29300 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 29301 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 29302 |
*/ /** |
| 29303 |
* @module plugins/fullsize |
| 29304 |
*/ |
| 29305 |
|
| 29306 |
|
| 29307 |
|
| 29308 |
|
| 29309 |
|
| 29310 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.fullsize = false; |
| 29311 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.globalFullSize = true; |
| 29312 |
jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_1__.Icon.set('fullsize', (_icons_fullsize_svg__WEBPACK_IMPORTED_MODULE_3___default())).set('shrink', (_icons_shrink_svg__WEBPACK_IMPORTED_MODULE_4___default())); |
| 29313 |
jodit_config__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.controls.fullsize = { |
| 29314 |
exec: (editor)=>{ |
| 29315 |
editor.toggleFullSize(); |
| 29316 |
}, |
| 29317 |
update (editor, button) { |
| 29318 |
const mode = editor.isFullSize ? 'shrink' : 'fullsize'; |
| 29319 |
button.state.activated = editor.isFullSize; |
| 29320 |
if (editor.o.textIcons) { |
| 29321 |
button.state.text = mode; |
| 29322 |
} else { |
| 29323 |
button.state.icon.name = mode; |
| 29324 |
} |
| 29325 |
}, |
| 29326 |
tooltip: 'Open in fullsize', |
| 29327 |
mode: jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.MODE_SOURCE + jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.MODE_WYSIWYG |
| 29328 |
}; |
| 29329 |
|
| 29330 |
|
| 29331 |
/***/ }), |
| 29332 |
|
| 29333 |
/***/ 80840: |
| 29334 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 29335 |
|
| 29336 |
"use strict"; |
| 29337 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 29338 |
/* harmony export */ wait: function() { return /* binding */ wait; } |
| 29339 |
/* harmony export */ }); |
| 29340 |
/* harmony import */ var jodit_core_component_statuses__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(69364); |
| 29341 |
/* harmony import */ var jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(91565); |
| 29342 |
/* harmony import */ var jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(33201); |
| 29343 |
/*! |
| 29344 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 29345 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 29346 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 29347 |
*/ /** |
| 29348 |
* [[include:core/decorators/wait/README.md]] |
| 29349 |
* @packageDocumentation |
| 29350 |
* @module decorators/wait |
| 29351 |
*/ |
| 29352 |
|
| 29353 |
|
| 29354 |
function wait(condition) { |
| 29355 |
return (target, propertyKey)=>{ |
| 29356 |
const fn = target[propertyKey]; |
| 29357 |
if (!(0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_1__.isFunction)(fn)) { |
| 29358 |
throw (0,jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_2__.error)('Handler must be a Function'); |
| 29359 |
} |
| 29360 |
target.hookStatus(jodit_core_component_statuses__WEBPACK_IMPORTED_MODULE_0__.STATUSES.ready, (component)=>{ |
| 29361 |
const { async } = component; |
| 29362 |
const realMethod = component[propertyKey]; |
| 29363 |
let timeout = 0; |
| 29364 |
Object.defineProperty(component, propertyKey, { |
| 29365 |
configurable: true, |
| 29366 |
value: function callProxy(...args) { |
| 29367 |
async.clearTimeout(timeout); |
| 29368 |
if (condition(component)) { |
| 29369 |
realMethod.apply(component, args); |
| 29370 |
} else { |
| 29371 |
timeout = async.setTimeout(()=>callProxy(...args), 10); |
| 29372 |
} |
| 29373 |
} |
| 29374 |
}); |
| 29375 |
}); |
| 29376 |
}; |
| 29377 |
} |
| 29378 |
|
| 29379 |
|
| 29380 |
/***/ }), |
| 29381 |
|
| 29382 |
/***/ 80951: |
| 29383 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 29384 |
|
| 29385 |
"use strict"; |
| 29386 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 29387 |
/* harmony export */ checkJoinTwoLists: function() { return /* binding */ checkJoinTwoLists; } |
| 29388 |
/* harmony export */ }); |
| 29389 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 29390 |
/* harmony import */ var jodit_core_helpers_utils_utils__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(71125); |
| 29391 |
/* harmony import */ var jodit_plugins_backspace_helpers__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(15200); |
| 29392 |
/*! |
| 29393 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 29394 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 29395 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 29396 |
*/ /** |
| 29397 |
* @module plugins/backspace |
| 29398 |
*/ |
| 29399 |
|
| 29400 |
|
| 29401 |
/** |
| 29402 |
* Try join two UL elements |
| 29403 |
* |
| 29404 |
* @example |
| 29405 |
* ```html |
| 29406 |
* <ul><li>one</li></ul>|<ol><li>two</li></ol> |
| 29407 |
* ``` |
| 29408 |
* Result |
| 29409 |
* ```html |
| 29410 |
* <ul><li>one|</li><li>two</li></ul> |
| 29411 |
* ``` |
| 29412 |
* @private |
| 29413 |
*/ function checkJoinTwoLists(jodit, fakeNode, backspace) { |
| 29414 |
const next = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.findSibling(fakeNode, backspace), prev = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.findSibling(fakeNode, !backspace); |
| 29415 |
if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(fakeNode, jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isElement, jodit.editor) && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isList(next) && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isList(prev) && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(next.lastElementChild, 'li') && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(prev.firstElementChild, 'li')) { |
| 29416 |
const { setCursorBefore, setCursorAfter } = jodit.s; |
| 29417 |
const target = next.lastElementChild, second = prev.firstElementChild; |
| 29418 |
(0,jodit_core_helpers_utils_utils__WEBPACK_IMPORTED_MODULE_1__.call)(!backspace ? jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.append : jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.prepend, second, fakeNode); |
| 29419 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.moveContent(prev, next, !backspace, (0,jodit_plugins_backspace_helpers__WEBPACK_IMPORTED_MODULE_2__.getMoveFilter)(jodit)); |
| 29420 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(prev); |
| 29421 |
(0,jodit_core_helpers_utils_utils__WEBPACK_IMPORTED_MODULE_1__.call)(backspace ? jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.append : jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.prepend, target, fakeNode); |
| 29422 |
(0,jodit_core_helpers_utils_utils__WEBPACK_IMPORTED_MODULE_1__.call)(backspace ? setCursorBefore : setCursorAfter, fakeNode); |
| 29423 |
return true; |
| 29424 |
} |
| 29425 |
return false; |
| 29426 |
} |
| 29427 |
|
| 29428 |
|
| 29429 |
/***/ }), |
| 29430 |
|
| 29431 |
/***/ 80991: |
| 29432 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 29433 |
|
| 29434 |
"use strict"; |
| 29435 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 29436 |
/* harmony export */ clearCenterAlign: function() { return /* binding */ clearCenterAlign; }, |
| 29437 |
/* harmony export */ css: function() { return /* binding */ css; } |
| 29438 |
/* harmony export */ }); |
| 29439 |
/* harmony import */ var jodit_core_helpers_checker_is_boolean__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(22289); |
| 29440 |
/* harmony import */ var jodit_core_helpers_checker_is_plain_object__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(62101); |
| 29441 |
/* harmony import */ var jodit_core_helpers_normalize_normalize_css_value__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(19147); |
| 29442 |
/* harmony import */ var jodit_core_helpers_string_camel_case__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(57821); |
| 29443 |
/* harmony import */ var jodit_core_helpers_string_kebab_case__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(74264); |
| 29444 |
/*! |
| 29445 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 29446 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 29447 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 29448 |
*/ /** |
| 29449 |
* @module helpers/utils |
| 29450 |
*/ |
| 29451 |
|
| 29452 |
|
| 29453 |
|
| 29454 |
|
| 29455 |
/** |
| 29456 |
* Get the value of a computed style property for the first element in the set of matched elements or set one or |
| 29457 |
* more CSS properties for every matched element |
| 29458 |
* |
| 29459 |
* @param element - HTML element |
| 29460 |
* @param key - An object of property-value pairs to set. A CSS property name. |
| 29461 |
* @param value - A value to set for the property. |
| 29462 |
* @param onlyStyleMode - Get value from style attribute, without calculating |
| 29463 |
*/ function css(element, key, value, onlyStyleMode = false) { |
| 29464 |
if ((0,jodit_core_helpers_checker_is_boolean__WEBPACK_IMPORTED_MODULE_0__.isBoolean)(value)) { |
| 29465 |
onlyStyleMode = value; |
| 29466 |
value = undefined; |
| 29467 |
} |
| 29468 |
if ((0,jodit_core_helpers_checker_is_plain_object__WEBPACK_IMPORTED_MODULE_1__.isPlainObject)(key) || value !== undefined) { |
| 29469 |
const setValue = (elm, _key, _value)=>{ |
| 29470 |
_value = (0,jodit_core_helpers_normalize_normalize_css_value__WEBPACK_IMPORTED_MODULE_2__.normalizeCssNumericValue)(_key, _value); |
| 29471 |
if (_value !== undefined && (_value == null || css(elm, _key, true) !== (0,jodit_core_helpers_normalize_normalize_css_value__WEBPACK_IMPORTED_MODULE_2__.normalizeCssValue)(_key, _value))) { |
| 29472 |
elm.style[_key] = _value; |
| 29473 |
} |
| 29474 |
}; |
| 29475 |
if ((0,jodit_core_helpers_checker_is_plain_object__WEBPACK_IMPORTED_MODULE_1__.isPlainObject)(key)) { |
| 29476 |
const keys = Object.keys(key); |
| 29477 |
for(let j = 0; j < keys.length; j += 1){ |
| 29478 |
setValue(element, (0,jodit_core_helpers_string_camel_case__WEBPACK_IMPORTED_MODULE_3__.camelCase)(keys[j]), key[keys[j]]); |
| 29479 |
} |
| 29480 |
} else { |
| 29481 |
setValue(element, (0,jodit_core_helpers_string_camel_case__WEBPACK_IMPORTED_MODULE_3__.camelCase)(key), value); |
| 29482 |
} |
| 29483 |
return ''; |
| 29484 |
} |
| 29485 |
const key2 = (0,jodit_core_helpers_string_kebab_case__WEBPACK_IMPORTED_MODULE_4__.kebabCase)(key); |
| 29486 |
const doc = element.ownerDocument || document; |
| 29487 |
const win = doc ? doc.defaultView || doc.parentWindow : false; |
| 29488 |
const currentValue = element.style[key]; |
| 29489 |
let result = ''; |
| 29490 |
if (currentValue !== undefined && currentValue !== '') { |
| 29491 |
result = currentValue; |
| 29492 |
} else if (win && !onlyStyleMode) { |
| 29493 |
result = win.getComputedStyle(element).getPropertyValue(key2); |
| 29494 |
} |
| 29495 |
if (jodit_core_helpers_normalize_normalize_css_value__WEBPACK_IMPORTED_MODULE_2__.NUMBER_FIELDS_REG.test(key) && /^[-+]?[0-9.]+px$/.test(result.toString())) { |
| 29496 |
result = parseInt(result.toString(), 10); |
| 29497 |
} |
| 29498 |
return (0,jodit_core_helpers_normalize_normalize_css_value__WEBPACK_IMPORTED_MODULE_2__.normalizeCssValue)(key, result); |
| 29499 |
} |
| 29500 |
/** |
| 29501 |
* Clear center align |
| 29502 |
*/ const clearCenterAlign = (image)=>{ |
| 29503 |
if (css(image, 'display') === 'block') { |
| 29504 |
css(image, 'display', ''); |
| 29505 |
} |
| 29506 |
const { style } = image; |
| 29507 |
if (style.marginLeft === 'auto' && style.marginRight === 'auto') { |
| 29508 |
style.marginLeft = ''; |
| 29509 |
style.marginRight = ''; |
| 29510 |
} |
| 29511 |
}; |
| 29512 |
|
| 29513 |
|
| 29514 |
/***/ }), |
| 29515 |
|
| 29516 |
/***/ 81321: |
| 29517 |
/***/ (function(module) { |
| 29518 |
|
| 29519 |
module.exports["default"] = ["Írjon be valamit","Joditról","Jodit Editor","Jodit útmutató","további segítséget tartalmaz","További licence információkért látogassa meg a weboldalunkat:","Teljes verzió megvásárlása","Copyright © XDSoft.net - Chupurnov Valeriy. Minden jog fenntartva.","Horgony","Megnyitás új lapon","Megnyitás teljes méretben","Formázás törlése","Háttér/szöveg szín","Újra","Visszavon","Félkövér","Dőlt","Pontozott lista","Számozott lista","Középre zárt","Sorkizárt","Balra zárt","Jobbra zárt","Vízszintes vonal beszúrása","Kép beszúrás","Fájl beszúrás","Youtube videó beszúrása","Link beszúrás","Betűméret","Betűtípus","Formázott blokk beszúrása","Normál","Fejléc 1","Fejléc 2","Fejléc 3","Fejléc 4","Idézet","Kód","Beszúr","Táblázat beszúrása","Behúzás csökkentése","Behúzás növelése","Speciális karakter kiválasztása","Speciális karakter beszúrása","Kép formázása","Nézet váltása","Szegélyek","felső","jobb","alsó","bal","CSS stílusok","CSS osztályok","Igazítás","Jobbra","Középre","Balra","Nincs","Forrás","Cím","Helyettesítő szöveg","Link","Link megnyitása új lapon","Kép","Fájl","Haladó","Kép tulajdonságai","Mégsem","OK","Fájl tallózó","Hiba a lista betöltése közben","Hiba a mappák betöltése közben","Biztosan ezt szeretné?","Írjon be egy mappanevet","Mappa létrehozása","írjon be bevet","Húzza ide a képet","Húzza ide a fájlt","vagy kattintson","Helyettesítő szöveg","Feltölt","Tallóz","Háttér","Szöveg","Fent","Középen","Lent","Oszlop beszúrás elé","Oszlop beszúrás utána","Sor beszúrás fölé","Sor beszúrás alá","Táblázat törlése","Sor törlése","Oszlop törlése","Cella tartalmának törlése","Karakterek száma: %d","Szavak száma: %d","Áthúzott","Aláhúzott","Felső index","Alsó index","Kivágás","Összes kijelölése","Szünet","Keresés","Csere erre","Cserélje ki","Beillesztés","Válasszon tartalmat a beillesztéshez","HTML","Félkövér","Dőlt","Ecset","Link","Visszavon","Újra","Táblázat","Kép","Törlés","Paragráfus","Betűméret","Videó","Betű","Rólunk","Nyomtat","Aláhúzott","Áthúzott","Behúzás","Aussenseiter","Teljes méret","Összenyom","Egyenes vonal","Lista","Számozott lista","Kivág","Összes kijelölése","Beágyazott kód","Link megnyitása","Link szerkesztése","Nincs követés","Link leválasztása","Frissít","Szerkesztés","felülvizsgálat","URL","Szerkeszt","Vízszintes igazítás","Szűrő","Rendezés módosítás szerint","Rendezés név szerint","Rendezés méret szerint","Mappa hozzáadás","Visszaállít","Mentés","Mentés másként...","Átméretezés","Kivág","Szélesség","Magasság","Képarány megtartása","Igen","Nem","Eltávolít","Kijelöl","Kijelöl: %s","Függőleges igazítás","Felosztás","Összevonás","Oszlop hozzáadás","Sor hozzáadás","Licenc: %s","Törlés","Függőleges felosztás","Vízszintes felosztás","Szegély","A beillesztett szöveg HTML-nek tűnik. Megtartsuk HTML-ként?","Beszúrás HTML-ként","Megtartás","Beszúrás szövegként","Csak szöveg beillesztése","Csak a saját képeit tudja szerkeszteni. Letölti ezt a képet?","Kép sikeresen feltöltve!","Palette","Er zijn geen bestanden in deze map.","átnevezés","Adja meg az új nevet","előnézet","Letöltés","Illessze be a vágólap","A böngésző nem támogatja a közvetlen hozzáférést biztosít a vágólapra.","Másolás kiválasztása","másolás","Határ sugár","Összes","Alkalmazni","Kérjük, töltse ki ezt a mezőt,","Kérjük, írja be a webcímet","Alapértelmezett","Kör","Pont","Quadrate","Találni","Megtalálja Előző","Következő Keresése","A beillesztett tartalom Microsoft Word/Excel dokumentumból származik. Meg szeretné tartani a formátumát?","Word-ből másolt szöveg","Elvetés","Helyezze be az osztály nevét","Nyomja meg az Alt egyéni átméretezés",null,null,null,"Összes"] |
| 29520 |
|
| 29521 |
/***/ }), |
| 29522 |
|
| 29523 |
/***/ 81488: |
| 29524 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 29525 |
|
| 29526 |
"use strict"; |
| 29527 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 29528 |
/* harmony export */ inputValidators: function() { return /* reexport module object */ _input__WEBPACK_IMPORTED_MODULE_0__; }, |
| 29529 |
/* harmony export */ selectValidators: function() { return /* reexport module object */ _select__WEBPACK_IMPORTED_MODULE_1__; } |
| 29530 |
/* harmony export */ }); |
| 29531 |
/* harmony import */ var _input__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(48776); |
| 29532 |
/* harmony import */ var _select__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6490); |
| 29533 |
/*! |
| 29534 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 29535 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 29536 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 29537 |
*/ /** |
| 29538 |
* @module ui/form |
| 29539 |
*/ |
| 29540 |
|
| 29541 |
|
| 29542 |
|
| 29543 |
|
| 29544 |
|
| 29545 |
/***/ }), |
| 29546 |
|
| 29547 |
/***/ 81582: |
| 29548 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 29549 |
|
| 29550 |
"use strict"; |
| 29551 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(31635); |
| 29552 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(81937); |
| 29553 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(84839); |
| 29554 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(28077); |
| 29555 |
/* harmony import */ var jodit_core_plugin__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(91206); |
| 29556 |
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(69023); |
| 29557 |
/* harmony import */ var _cases__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(2923); |
| 29558 |
/*! |
| 29559 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 29560 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 29561 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 29562 |
*/ /** |
| 29563 |
* [[include:plugins/tab/README.md]] |
| 29564 |
* @packageDocumentation |
| 29565 |
* @module plugins/tab |
| 29566 |
*/ |
| 29567 |
|
| 29568 |
|
| 29569 |
|
| 29570 |
|
| 29571 |
|
| 29572 |
|
| 29573 |
class tab extends jodit_core_plugin__WEBPACK_IMPORTED_MODULE_4__.Plugin { |
| 29574 |
afterInit(jodit) {} |
| 29575 |
__onTab(event) { |
| 29576 |
if (event.key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.KEY_TAB && this.__onShift(event.shiftKey)) { |
| 29577 |
return false; |
| 29578 |
} |
| 29579 |
} |
| 29580 |
__onCommand(command) { |
| 29581 |
if ((command === 'indent' || command === 'outdent') && this.__onShift(command === 'outdent')) { |
| 29582 |
return false; |
| 29583 |
} |
| 29584 |
} |
| 29585 |
__onShift(shift) { |
| 29586 |
const res = (0,_cases__WEBPACK_IMPORTED_MODULE_6__.onTabInsideLi)(this.j, shift); |
| 29587 |
if (res) { |
| 29588 |
this.j.e.fire('afterTab', shift); |
| 29589 |
} |
| 29590 |
return res; |
| 29591 |
} |
| 29592 |
beforeDestruct(jodit) {} |
| 29593 |
} |
| 29594 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_0__.__decorate)([ |
| 29595 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.watch)(':keydown.tab') |
| 29596 |
], tab.prototype, "__onTab", null); |
| 29597 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_0__.__decorate)([ |
| 29598 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.watch)(':beforeCommand.tab') |
| 29599 |
], tab.prototype, "__onCommand", null); |
| 29600 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_3__.pluginSystem.add('tab', tab); |
| 29601 |
|
| 29602 |
|
| 29603 |
/***/ }), |
| 29604 |
|
| 29605 |
/***/ 81875: |
| 29606 |
/***/ (function(module) { |
| 29607 |
|
| 29608 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 270 270\"> <path d=\"m240.443652,220.45085l-47.410809,0l0,-10.342138c13.89973,-8.43655 25.752896,-19.844464 34.686646,-33.469923c11.445525,-17.455846 17.496072,-37.709239 17.496072,-58.570077c0,-59.589197 -49.208516,-108.068714 -109.693558,-108.068714s-109.69263,48.479517 -109.69263,108.069628c0,20.860839 6.050547,41.113316 17.497001,58.570077c8.93375,13.625459 20.787845,25.032458 34.686646,33.469008l0,10.342138l-47.412666,0c-10.256959,0 -18.571354,8.191376 -18.571354,18.296574c0,10.105198 8.314395,18.296574 18.571354,18.296574l65.98402,0c10.256959,0 18.571354,-8.191376 18.571354,-18.296574l0,-39.496814c0,-7.073455 -4.137698,-13.51202 -10.626529,-16.537358c-25.24497,-11.772016 -41.557118,-37.145704 -41.557118,-64.643625c0,-39.411735 32.545369,-71.476481 72.549922,-71.476481c40.004553,0 72.550851,32.064746 72.550851,71.476481c0,27.497006 -16.312149,52.87161 -41.557118,64.643625c-6.487902,3.026253 -10.6256,9.464818 -10.6256,16.537358l0,39.496814c0,10.105198 8.314395,18.296574 18.571354,18.296574l65.982163,0c10.256959,0 18.571354,-8.191376 18.571354,-18.296574c0,-10.105198 -8.314395,-18.296574 -18.571354,-18.296574z\"/> </svg>" |
| 29609 |
|
| 29610 |
/***/ }), |
| 29611 |
|
| 29612 |
/***/ 81937: |
| 29613 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 29614 |
|
| 29615 |
"use strict"; |
| 29616 |
__webpack_require__.r(__webpack_exports__); |
| 29617 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 29618 |
/* harmony export */ ACCURACY: function() { return /* binding */ ACCURACY; }, |
| 29619 |
/* harmony export */ APP_VERSION: function() { return /* binding */ APP_VERSION; }, |
| 29620 |
/* harmony export */ BASE_PATH: function() { return /* binding */ BASE_PATH; }, |
| 29621 |
/* harmony export */ BASE_PATH_IS_MIN: function() { return /* binding */ BASE_PATH_IS_MIN; }, |
| 29622 |
/* harmony export */ BR: function() { return /* binding */ BR; }, |
| 29623 |
/* harmony export */ CLIPBOARD_ID: function() { return /* binding */ CLIPBOARD_ID; }, |
| 29624 |
/* harmony export */ COMMAND_KEYS: function() { return /* binding */ COMMAND_KEYS; }, |
| 29625 |
/* harmony export */ EMULATE_DBLCLICK_TIMEOUT: function() { return /* binding */ EMULATE_DBLCLICK_TIMEOUT; }, |
| 29626 |
/* harmony export */ ES: function() { return /* binding */ ES; }, |
| 29627 |
/* harmony export */ FAT_MODE: function() { return /* binding */ FAT_MODE; }, |
| 29628 |
/* harmony export */ HOMEPAGE: function() { return /* binding */ HOMEPAGE; }, |
| 29629 |
/* harmony export */ INSEPARABLE_TAGS: function() { return /* binding */ INSEPARABLE_TAGS; }, |
| 29630 |
/* harmony export */ INSERT_AS_HTML: function() { return /* binding */ INSERT_AS_HTML; }, |
| 29631 |
/* harmony export */ INSERT_AS_TEXT: function() { return /* binding */ INSERT_AS_TEXT; }, |
| 29632 |
/* harmony export */ INSERT_CLEAR_HTML: function() { return /* binding */ INSERT_CLEAR_HTML; }, |
| 29633 |
/* harmony export */ INSERT_ONLY_TEXT: function() { return /* binding */ INSERT_ONLY_TEXT; }, |
| 29634 |
/* harmony export */ INVISIBLE_SPACE: function() { return /* binding */ INVISIBLE_SPACE; }, |
| 29635 |
/* harmony export */ INVISIBLE_SPACE_REG_EXP: function() { return /* binding */ INVISIBLE_SPACE_REG_EXP; }, |
| 29636 |
/* harmony export */ INVISIBLE_SPACE_REG_EXP_END: function() { return /* binding */ INVISIBLE_SPACE_REG_EXP_END; }, |
| 29637 |
/* harmony export */ INVISIBLE_SPACE_REG_EXP_START: function() { return /* binding */ INVISIBLE_SPACE_REG_EXP_START; }, |
| 29638 |
/* harmony export */ IS_BLOCK: function() { return /* binding */ IS_BLOCK; }, |
| 29639 |
/* harmony export */ IS_ES_MODERN: function() { return /* binding */ IS_ES_MODERN; }, |
| 29640 |
/* harmony export */ IS_ES_NEXT: function() { return /* binding */ IS_ES_NEXT; }, |
| 29641 |
/* harmony export */ IS_IE: function() { return /* binding */ IS_IE; }, |
| 29642 |
/* harmony export */ IS_INLINE: function() { return /* binding */ IS_INLINE; }, |
| 29643 |
/* harmony export */ IS_MAC: function() { return /* binding */ IS_MAC; }, |
| 29644 |
/* harmony export */ IS_PROD: function() { return /* binding */ IS_PROD; }, |
| 29645 |
/* harmony export */ IS_TEST: function() { return /* binding */ IS_TEST; }, |
| 29646 |
/* harmony export */ KEY_ALIASES: function() { return /* binding */ KEY_ALIASES; }, |
| 29647 |
/* harmony export */ KEY_ALT: function() { return /* binding */ KEY_ALT; }, |
| 29648 |
/* harmony export */ KEY_BACKSPACE: function() { return /* binding */ KEY_BACKSPACE; }, |
| 29649 |
/* harmony export */ KEY_DELETE: function() { return /* binding */ KEY_DELETE; }, |
| 29650 |
/* harmony export */ KEY_DOWN: function() { return /* binding */ KEY_DOWN; }, |
| 29651 |
/* harmony export */ KEY_ENTER: function() { return /* binding */ KEY_ENTER; }, |
| 29652 |
/* harmony export */ KEY_ESC: function() { return /* binding */ KEY_ESC; }, |
| 29653 |
/* harmony export */ KEY_F3: function() { return /* binding */ KEY_F3; }, |
| 29654 |
/* harmony export */ KEY_LEFT: function() { return /* binding */ KEY_LEFT; }, |
| 29655 |
/* harmony export */ KEY_META: function() { return /* binding */ KEY_META; }, |
| 29656 |
/* harmony export */ KEY_RIGHT: function() { return /* binding */ KEY_RIGHT; }, |
| 29657 |
/* harmony export */ KEY_SPACE: function() { return /* binding */ KEY_SPACE; }, |
| 29658 |
/* harmony export */ KEY_TAB: function() { return /* binding */ KEY_TAB; }, |
| 29659 |
/* harmony export */ KEY_UP: function() { return /* binding */ KEY_UP; }, |
| 29660 |
/* harmony export */ LIST_TAGS: function() { return /* binding */ LIST_TAGS; }, |
| 29661 |
/* harmony export */ MARKER_CLASS: function() { return /* binding */ MARKER_CLASS; }, |
| 29662 |
/* harmony export */ MODE_SOURCE: function() { return /* binding */ MODE_SOURCE; }, |
| 29663 |
/* harmony export */ MODE_SPLIT: function() { return /* binding */ MODE_SPLIT; }, |
| 29664 |
/* harmony export */ MODE_WYSIWYG: function() { return /* binding */ MODE_WYSIWYG; }, |
| 29665 |
/* harmony export */ NBSP_SPACE: function() { return /* binding */ NBSP_SPACE; }, |
| 29666 |
/* harmony export */ NEARBY: function() { return /* binding */ NEARBY; }, |
| 29667 |
/* harmony export */ NO_EMPTY_TAGS: function() { return /* binding */ NO_EMPTY_TAGS; }, |
| 29668 |
/* harmony export */ PARAGRAPH: function() { return /* binding */ PARAGRAPH; }, |
| 29669 |
/* harmony export */ PASSIVE_EVENTS: function() { return /* binding */ PASSIVE_EVENTS; }, |
| 29670 |
/* harmony export */ SAFE_COUNT_CHANGE_CALL: function() { return /* binding */ SAFE_COUNT_CHANGE_CALL; }, |
| 29671 |
/* harmony export */ SET_TEST: function() { return /* binding */ SET_TEST; }, |
| 29672 |
/* harmony export */ SOURCE_CONSUMER: function() { return /* binding */ SOURCE_CONSUMER; }, |
| 29673 |
/* harmony export */ SPACE_REG_EXP: function() { return /* binding */ SPACE_REG_EXP; }, |
| 29674 |
/* harmony export */ SPACE_REG_EXP_END: function() { return /* binding */ SPACE_REG_EXP_END; }, |
| 29675 |
/* harmony export */ SPACE_REG_EXP_START: function() { return /* binding */ SPACE_REG_EXP_START; }, |
| 29676 |
/* harmony export */ TEMP_ATTR: function() { return /* binding */ TEMP_ATTR; }, |
| 29677 |
/* harmony export */ TEXT_HTML: function() { return /* binding */ TEXT_HTML; }, |
| 29678 |
/* harmony export */ TEXT_PLAIN: function() { return /* binding */ TEXT_PLAIN; }, |
| 29679 |
/* harmony export */ TEXT_RTF: function() { return /* binding */ TEXT_RTF; }, |
| 29680 |
/* harmony export */ TOKENS: function() { return /* binding */ TOKENS; }, |
| 29681 |
/* harmony export */ globalDocument: function() { return /* binding */ globalDocument; }, |
| 29682 |
/* harmony export */ globalWindow: function() { return /* binding */ globalWindow; }, |
| 29683 |
/* harmony export */ lang: function() { return /* binding */ lang; } |
| 29684 |
/* harmony export */ }); |
| 29685 |
/*! |
| 29686 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 29687 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 29688 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 29689 |
*/ /** |
| 29690 |
* You can use Jodit constants in your code |
| 29691 |
* ```javascript |
| 29692 |
* import { Jodit } from 'jodit'; |
| 29693 |
* console.log(Jodit.constants.IS_IE); |
| 29694 |
* console.log(Jodit.constants.APP_VERSION); |
| 29695 |
* ``` |
| 29696 |
* @packageDocumentation |
| 29697 |
* @module constants |
| 29698 |
*/ const APP_VERSION = "4.9.14"; |
| 29699 |
// prettier-ignore |
| 29700 |
const ES = "es2015"; |
| 29701 |
const IS_ES_MODERN = true; |
| 29702 |
const IS_ES_NEXT = false; |
| 29703 |
const IS_PROD = true; |
| 29704 |
let IS_TEST = false; |
| 29705 |
const FAT_MODE = false; |
| 29706 |
const HOMEPAGE = "https://xdsoft.net/jodit/"; |
| 29707 |
const SET_TEST = ()=>IS_TEST = true; |
| 29708 |
const TOKENS = {}; |
| 29709 |
const INVISIBLE_SPACE = '\uFEFF'; |
| 29710 |
const NBSP_SPACE = '\u00A0'; |
| 29711 |
const INVISIBLE_SPACE_REG_EXP = ()=>/[\uFEFF]/g; |
| 29712 |
const INVISIBLE_SPACE_REG_EXP_END = ()=>/[\uFEFF]+$/g; |
| 29713 |
const INVISIBLE_SPACE_REG_EXP_START = ()=>/^[\uFEFF]+/g; |
| 29714 |
const SPACE_REG_EXP = ()=>/[\s\n\t\r\uFEFF\u200b]+/g; |
| 29715 |
const SPACE_REG_EXP_START = ()=>/^[\s\n\t\r\uFEFF\u200b]+/g; |
| 29716 |
const SPACE_REG_EXP_END = ()=>/[\s\n\t\r\uFEFF\u200b]+$/g; |
| 29717 |
const globalWindow = typeof window !== 'undefined' ? window : undefined; |
| 29718 |
const globalDocument = typeof document !== 'undefined' ? document : undefined; |
| 29719 |
const IS_BLOCK = /^(ADDRESS|ARTICLE|ASIDE|BLOCKQUOTE|CANVAS|DD|DFN|DIV|DL|DT|FIELDSET|FIGCAPTION|FIGURE|FOOTER|FORM|H[1-6]|HEADER|HGROUP|HR|LI|MAIN|NAV|NOSCRIPT|OUTPUT|P|PRE|RUBY|SCRIPT|STYLE|OBJECT|OL|SECTION|IFRAME|JODIT|JODIT-MEDIA|UL|TR|TD|TH|TBODY|THEAD|TFOOT|TABLE|BODY|HTML|VIDEO)$/i; |
| 29720 |
const IS_INLINE = /^(STRONG|SPAN|I|EM|B|SUP|SUB|A|U)$/i; |
| 29721 |
const LIST_TAGS = new Set([ |
| 29722 |
'ul', |
| 29723 |
'ol' |
| 29724 |
]); |
| 29725 |
const __UNSEPARABLE_TAGS = [ |
| 29726 |
'img', |
| 29727 |
'video', |
| 29728 |
'svg', |
| 29729 |
'iframe', |
| 29730 |
'script', |
| 29731 |
'input', |
| 29732 |
'textarea', |
| 29733 |
'link', |
| 29734 |
'jodit', |
| 29735 |
'jodit-media' |
| 29736 |
]; |
| 29737 |
const INSEPARABLE_TAGS = new Set([ |
| 29738 |
...__UNSEPARABLE_TAGS, |
| 29739 |
'br', |
| 29740 |
'hr' |
| 29741 |
]); |
| 29742 |
const NO_EMPTY_TAGS = new Set(__UNSEPARABLE_TAGS); |
| 29743 |
const KEY_META = 'Meta'; |
| 29744 |
const KEY_BACKSPACE = 'Backspace'; |
| 29745 |
const KEY_TAB = 'Tab'; |
| 29746 |
const KEY_ENTER = 'Enter'; |
| 29747 |
const KEY_ESC = 'Escape'; |
| 29748 |
const KEY_ALT = 'Alt'; |
| 29749 |
const KEY_LEFT = 'ArrowLeft'; |
| 29750 |
const KEY_UP = 'ArrowUp'; |
| 29751 |
const KEY_RIGHT = 'ArrowRight'; |
| 29752 |
const KEY_DOWN = 'ArrowDown'; |
| 29753 |
const KEY_SPACE = 'Space'; |
| 29754 |
const KEY_DELETE = 'Delete'; |
| 29755 |
const KEY_F3 = 'F3'; |
| 29756 |
const NEARBY = 5; |
| 29757 |
const ACCURACY = 10; |
| 29758 |
const COMMAND_KEYS = [ |
| 29759 |
KEY_META, |
| 29760 |
KEY_BACKSPACE, |
| 29761 |
KEY_DELETE, |
| 29762 |
KEY_UP, |
| 29763 |
KEY_DOWN, |
| 29764 |
KEY_RIGHT, |
| 29765 |
KEY_LEFT, |
| 29766 |
KEY_ENTER, |
| 29767 |
KEY_ESC, |
| 29768 |
KEY_F3, |
| 29769 |
KEY_TAB |
| 29770 |
]; |
| 29771 |
const BR = 'br'; |
| 29772 |
const PARAGRAPH = 'p'; |
| 29773 |
/** |
| 29774 |
* WYSIWYG editor mode |
| 29775 |
*/ const MODE_WYSIWYG = 1; |
| 29776 |
/** |
| 29777 |
* html editor mode |
| 29778 |
*/ const MODE_SOURCE = 2; |
| 29779 |
/** |
| 29780 |
* Source code editor and HTML editor both like |
| 29781 |
* @see http://getuikit.com/docs/htmleditor.html|this |
| 29782 |
*/ const MODE_SPLIT = 3; |
| 29783 |
/** |
| 29784 |
* Is Internet Explorer |
| 29785 |
*/ const IS_IE = typeof navigator !== 'undefined' && (navigator.userAgent.indexOf('MSIE') !== -1 || /rv:11.0/i.test(navigator.userAgent)); |
| 29786 |
/** |
| 29787 |
* For IE11 it will be 'text'. Need for dataTransfer.setData |
| 29788 |
*/ const TEXT_PLAIN = IS_IE ? 'text' : 'text/plain'; |
| 29789 |
const TEXT_HTML = IS_IE ? 'html' : 'text/html'; |
| 29790 |
const TEXT_RTF = IS_IE ? 'rtf' : 'text/rtf'; |
| 29791 |
const MARKER_CLASS = 'jodit-selection_marker'; |
| 29792 |
const EMULATE_DBLCLICK_TIMEOUT = 300; |
| 29793 |
/** |
| 29794 |
* Paste the copied text as HTML, all content will be pasted exactly as it was on the clipboard. |
| 29795 |
* So how would you copy its code directly into the source document. |
| 29796 |
* ``` |
| 29797 |
* <h1 style="color:red">test</h1> |
| 29798 |
* ``` |
| 29799 |
* Will be inserted into the document as |
| 29800 |
* ``` |
| 29801 |
* <h1 style="color:red">test</h1> |
| 29802 |
* ``` |
| 29803 |
*/ const INSERT_AS_HTML = 'insert_as_html'; |
| 29804 |
/** |
| 29805 |
* Same as [[INSERT_AS_HTML]], but content will be stripped of extra styles and empty tags |
| 29806 |
* ```html |
| 29807 |
* <h1 style="color:red">test</h1> |
| 29808 |
* ``` |
| 29809 |
* Will be inserted into the document as |
| 29810 |
* ```html |
| 29811 |
* <h1>test</h1> |
| 29812 |
* ``` |
| 29813 |
*/ const INSERT_CLEAR_HTML = 'insert_clear_html'; |
| 29814 |
/** |
| 29815 |
* The contents of the clipboard will be pasted into the document as plain text, i.e. all tags will be displayed as text. |
| 29816 |
* ```html |
| 29817 |
* <h1>test</h1> |
| 29818 |
* ``` |
| 29819 |
* Will be inserted into the document as |
| 29820 |
* ```html |
| 29821 |
* ><h1>test</h1> |
| 29822 |
* ``` |
| 29823 |
*/ const INSERT_AS_TEXT = 'insert_as_text'; |
| 29824 |
/** |
| 29825 |
* All tags will be stripped: |
| 29826 |
* ```html |
| 29827 |
* <h1>test</h1> |
| 29828 |
* ``` |
| 29829 |
* Will be inserted into the document as |
| 29830 |
* ```html |
| 29831 |
* test |
| 29832 |
* ``` |
| 29833 |
*/ const INSERT_ONLY_TEXT = 'insert_only_text'; |
| 29834 |
const SAFE_COUNT_CHANGE_CALL = 10; |
| 29835 |
const IS_MAC = typeof globalWindow !== 'undefined' && /Mac|iPod|iPhone|iPad/.test(globalWindow.navigator.platform); |
| 29836 |
const KEY_ALIASES = { |
| 29837 |
add: '+', |
| 29838 |
break: 'pause', |
| 29839 |
cmd: 'meta', |
| 29840 |
command: 'meta', |
| 29841 |
ctl: 'control', |
| 29842 |
ctrl: 'control', |
| 29843 |
del: 'delete', |
| 29844 |
down: 'arrowdown', |
| 29845 |
esc: 'escape', |
| 29846 |
ins: 'insert', |
| 29847 |
left: 'arrowleft', |
| 29848 |
mod: IS_MAC ? 'meta' : 'control', |
| 29849 |
opt: 'alt', |
| 29850 |
option: 'alt', |
| 29851 |
return: 'enter', |
| 29852 |
right: 'arrowright', |
| 29853 |
space: 'space', |
| 29854 |
spacebar: 'space', |
| 29855 |
up: 'arrowup', |
| 29856 |
win: 'meta', |
| 29857 |
windows: 'meta' |
| 29858 |
}; |
| 29859 |
const removeScriptName = (src)=>{ |
| 29860 |
const parts = src.split('/'); |
| 29861 |
const isMin = true ? false : 0; |
| 29862 |
if (/\.js/.test(parts[parts.length - 1])) { |
| 29863 |
return { |
| 29864 |
basePath: parts.slice(0, parts.length - 1).join('/') + '/', |
| 29865 |
isMin |
| 29866 |
}; |
| 29867 |
} |
| 29868 |
return { |
| 29869 |
basePath: src, |
| 29870 |
isMin |
| 29871 |
}; |
| 29872 |
}; |
| 29873 |
const { basePath, isMin } = (()=>{ |
| 29874 |
if (typeof document === 'undefined') { |
| 29875 |
return { |
| 29876 |
basePath: '', |
| 29877 |
isMin: Boolean(false) |
| 29878 |
}; |
| 29879 |
} |
| 29880 |
const script = globalDocument.currentScript; |
| 29881 |
if (script) { |
| 29882 |
return removeScriptName(script.src); |
| 29883 |
} |
| 29884 |
const scripts = globalDocument.querySelectorAll('script[src]'); |
| 29885 |
if (scripts && scripts.length) { |
| 29886 |
return removeScriptName(scripts[scripts.length - 1].src); |
| 29887 |
} |
| 29888 |
return removeScriptName(globalWindow.location.href); |
| 29889 |
})(); |
| 29890 |
/** |
| 29891 |
* Path to the current script |
| 29892 |
*/ const BASE_PATH = basePath; |
| 29893 |
/** |
| 29894 |
* Current script is minified |
| 29895 |
*/ const BASE_PATH_IS_MIN = isMin; |
| 29896 |
const TEMP_ATTR = 'data-jodit-temp'; |
| 29897 |
const lang = {}; |
| 29898 |
const CLIPBOARD_ID = 'clipboard'; |
| 29899 |
const SOURCE_CONSUMER = 'source-consumer'; |
| 29900 |
const PASSIVE_EVENTS = new Set([ |
| 29901 |
'touchstart', |
| 29902 |
'touchend', |
| 29903 |
'scroll', |
| 29904 |
'mousewheel', |
| 29905 |
'mousemove', |
| 29906 |
'touchmove' |
| 29907 |
]); |
| 29908 |
|
| 29909 |
|
| 29910 |
/***/ }), |
| 29911 |
|
| 29912 |
/***/ 81987: |
| 29913 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 29914 |
|
| 29915 |
"use strict"; |
| 29916 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 29917 |
/* harmony export */ Mods: function() { return /* binding */ Mods; } |
| 29918 |
/* harmony export */ }); |
| 29919 |
/* harmony import */ var jodit_core_helpers_checker_is_void__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(18303); |
| 29920 |
/*! |
| 29921 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 29922 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 29923 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 29924 |
*/ /** |
| 29925 |
* @module traits |
| 29926 |
*/ |
| 29927 |
class Mods { |
| 29928 |
afterSetMod(name, value) {} |
| 29929 |
/** |
| 29930 |
* Set/remove BEM class modification |
| 29931 |
* |
| 29932 |
* @param value - if null, mod will be removed |
| 29933 |
*/ setMod(name, value, container) { |
| 29934 |
name = name.toLowerCase(); |
| 29935 |
const oldValue = this.mods[name]; |
| 29936 |
if (oldValue === value) { |
| 29937 |
return this; |
| 29938 |
} |
| 29939 |
const mod = `${this.componentName}_${name}_`, cl = (container || this.container).classList; |
| 29940 |
if (oldValue != null) { |
| 29941 |
cl.remove(`${mod}${oldValue.toString().toLowerCase()}`); |
| 29942 |
} |
| 29943 |
!(0,jodit_core_helpers_checker_is_void__WEBPACK_IMPORTED_MODULE_0__.isVoid)(value) && value !== '' && cl.add(`${mod}${value.toString().toLowerCase()}`); |
| 29944 |
this.mods[name] = value; |
| 29945 |
this.afterSetMod(name, value); |
| 29946 |
return this; |
| 29947 |
} |
| 29948 |
/** |
| 29949 |
* Get BEM class modification value |
| 29950 |
*/ getMod(name) { |
| 29951 |
var _this_mods_name; |
| 29952 |
return (_this_mods_name = this.mods[name]) !== null && _this_mods_name !== void 0 ? _this_mods_name : null; |
| 29953 |
} |
| 29954 |
} |
| 29955 |
|
| 29956 |
|
| 29957 |
/***/ }), |
| 29958 |
|
| 29959 |
/***/ 82166: |
| 29960 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 29961 |
|
| 29962 |
"use strict"; |
| 29963 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 29964 |
/* harmony export */ isHtmlFromWord: function() { return /* binding */ isHtmlFromWord; } |
| 29965 |
/* harmony export */ }); |
| 29966 |
/*! |
| 29967 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 29968 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 29969 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 29970 |
*/ /** |
| 29971 |
* @module helpers/checker |
| 29972 |
*/ /** |
| 29973 |
* Detect if string is HTML from MS Word or Excel |
| 29974 |
*/ function isHtmlFromWord(data) { |
| 29975 |
return data.search(/<meta.*?Microsoft Excel\s[\d].*?>/) !== -1 || data.search(/<meta.*?Microsoft Word\s[\d].*?>/) !== -1 || data.search(/style="[^"]*mso-/) !== -1 && data.search(/<font/) !== -1; |
| 29976 |
} |
| 29977 |
|
| 29978 |
|
| 29979 |
/***/ }), |
| 29980 |
|
| 29981 |
/***/ 82495: |
| 29982 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 29983 |
|
| 29984 |
"use strict"; |
| 29985 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 29986 |
/* harmony export */ createSourceEditor: function() { return /* binding */ createSourceEditor; } |
| 29987 |
/* harmony export */ }); |
| 29988 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(65946); |
| 29989 |
/* harmony import */ var _engines__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(8105); |
| 29990 |
/*! |
| 29991 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 29992 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 29993 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 29994 |
*/ /** |
| 29995 |
* @module plugins/source |
| 29996 |
*/ |
| 29997 |
|
| 29998 |
function createSourceEditor(type, editor, container, toWYSIWYG, fromWYSIWYG) { |
| 29999 |
let sourceEditor; |
| 30000 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_0__.isFunction)(type)) { |
| 30001 |
sourceEditor = type(editor); |
| 30002 |
} else { |
| 30003 |
switch(type){ |
| 30004 |
case 'ace': |
| 30005 |
if (!editor.o.shadowRoot) { |
| 30006 |
sourceEditor = new _engines__WEBPACK_IMPORTED_MODULE_1__.AceEditor(editor, container, toWYSIWYG, fromWYSIWYG); |
| 30007 |
break; |
| 30008 |
} |
| 30009 |
default: |
| 30010 |
sourceEditor = new _engines__WEBPACK_IMPORTED_MODULE_1__.TextAreaEditor(editor, container, toWYSIWYG, fromWYSIWYG); |
| 30011 |
} |
| 30012 |
} |
| 30013 |
sourceEditor.init(editor); |
| 30014 |
sourceEditor.onReadyAlways(()=>{ |
| 30015 |
sourceEditor.setReadOnly(editor.o.readonly); |
| 30016 |
}); |
| 30017 |
return sourceEditor; |
| 30018 |
} |
| 30019 |
|
| 30020 |
|
| 30021 |
/***/ }), |
| 30022 |
|
| 30023 |
/***/ 82658: |
| 30024 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 30025 |
|
| 30026 |
"use strict"; |
| 30027 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 30028 |
/* harmony export */ applyStyles: function() { return /* reexport safe */ _apply_styles__WEBPACK_IMPORTED_MODULE_0__.applyStyles; }, |
| 30029 |
/* harmony export */ cleanFromWord: function() { return /* reexport safe */ _clean_from_word__WEBPACK_IMPORTED_MODULE_1__.cleanFromWord; }, |
| 30030 |
/* harmony export */ htmlspecialchars: function() { return /* reexport safe */ _htmlspecialchars__WEBPACK_IMPORTED_MODULE_2__.htmlspecialchars; }, |
| 30031 |
/* harmony export */ nl2br: function() { return /* reexport safe */ _nl2br__WEBPACK_IMPORTED_MODULE_3__.nl2br; }, |
| 30032 |
/* harmony export */ safeHTML: function() { return /* reexport safe */ _safe_html__WEBPACK_IMPORTED_MODULE_4__.safeHTML; }, |
| 30033 |
/* harmony export */ sanitizeHTMLElement: function() { return /* reexport safe */ _safe_html__WEBPACK_IMPORTED_MODULE_4__.sanitizeHTMLElement; }, |
| 30034 |
/* harmony export */ stripTags: function() { return /* reexport safe */ _strip_tags__WEBPACK_IMPORTED_MODULE_5__.stripTags; } |
| 30035 |
/* harmony export */ }); |
| 30036 |
/* harmony import */ var _apply_styles__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(30893); |
| 30037 |
/* harmony import */ var _clean_from_word__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(1277); |
| 30038 |
/* harmony import */ var _htmlspecialchars__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6609); |
| 30039 |
/* harmony import */ var _nl2br__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(48838); |
| 30040 |
/* harmony import */ var _safe_html__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(48155); |
| 30041 |
/* harmony import */ var _strip_tags__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(22852); |
| 30042 |
/*! |
| 30043 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 30044 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 30045 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 30046 |
*/ /** |
| 30047 |
* @module helpers/html |
| 30048 |
*/ |
| 30049 |
|
| 30050 |
|
| 30051 |
|
| 30052 |
|
| 30053 |
|
| 30054 |
|
| 30055 |
|
| 30056 |
/***/ }), |
| 30057 |
|
| 30058 |
/***/ 82794: |
| 30059 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 30060 |
|
| 30061 |
"use strict"; |
| 30062 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 30063 |
/* harmony export */ toggleAttributes: function() { return /* binding */ toggleAttributes; } |
| 30064 |
/* harmony export */ }); |
| 30065 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 30066 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(23211); |
| 30067 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(28077); |
| 30068 |
/* harmony import */ var jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(28686); |
| 30069 |
/* harmony import */ var jodit_core_helpers_normalize_normalize_css_value__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(19147); |
| 30070 |
/* harmony import */ var jodit_core_helpers_size_object_size__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(18073); |
| 30071 |
/* harmony import */ var jodit_core_helpers_string_kebab_case__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(74264); |
| 30072 |
/* harmony import */ var jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(93640); |
| 30073 |
/* harmony import */ var jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(80991); |
| 30074 |
/* harmony import */ var jodit_core_helpers_utils_data_bind__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(36400); |
| 30075 |
/* harmony import */ var jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(98394); |
| 30076 |
/*! |
| 30077 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 30078 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 30079 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 30080 |
*/ |
| 30081 |
|
| 30082 |
|
| 30083 |
|
| 30084 |
|
| 30085 |
|
| 30086 |
|
| 30087 |
|
| 30088 |
|
| 30089 |
|
| 30090 |
|
| 30091 |
const tak = 'toggleAttributes'; |
| 30092 |
/** |
| 30093 |
* Toggles attributes |
| 30094 |
* @private |
| 30095 |
*/ function toggleAttributes(commitStyle, elm, jodit, mode, dry = false) { |
| 30096 |
if (!dry && commitStyle.isApplied(elm, tak)) { |
| 30097 |
return mode; |
| 30098 |
} |
| 30099 |
!dry && commitStyle.setApplied(elm, tak); |
| 30100 |
const { attributes } = commitStyle.options; |
| 30101 |
if (attributes && (0,jodit_core_helpers_size_object_size__WEBPACK_IMPORTED_MODULE_5__.size)(attributes) > 0) { |
| 30102 |
Object.keys(attributes).forEach((key)=>{ |
| 30103 |
const value = attributes[key]; |
| 30104 |
switch(key){ |
| 30105 |
case 'style': |
| 30106 |
{ |
| 30107 |
mode = toggleStyle(commitStyle, jodit, value, elm, dry, mode); |
| 30108 |
break; |
| 30109 |
} |
| 30110 |
case 'className': |
| 30111 |
case 'class': |
| 30112 |
mode = toggleClass(jodit, value, elm, mode, dry); |
| 30113 |
break; |
| 30114 |
default: |
| 30115 |
mode = toggleAttribute(jodit, value, elm, key, dry, mode); |
| 30116 |
} |
| 30117 |
}); |
| 30118 |
} |
| 30119 |
return mode; |
| 30120 |
} |
| 30121 |
function toggleStyle(commitStyle, jodit, style, elm, dry, mode) { |
| 30122 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_7__.assert)((0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_3__.isPlainObject)(style) && (0,jodit_core_helpers_size_object_size__WEBPACK_IMPORTED_MODULE_5__.size)(style), 'Style must be an object'); |
| 30123 |
Object.keys(style).forEach((rule)=>{ |
| 30124 |
const inlineValue = elm.style.getPropertyValue((0,jodit_core_helpers_string_kebab_case__WEBPACK_IMPORTED_MODULE_6__.kebabCase)(rule)); |
| 30125 |
const newValue = style[rule]; |
| 30126 |
if (inlineValue === '' && newValue == null) { |
| 30127 |
return; |
| 30128 |
} |
| 30129 |
if (getNativeCSSValue(jodit, elm, rule) === (0,jodit_core_helpers_normalize_normalize_css_value__WEBPACK_IMPORTED_MODULE_4__.normalizeCssValue)(rule, newValue)) { |
| 30130 |
if (!inlineValue) { |
| 30131 |
return; |
| 30132 |
} |
| 30133 |
!dry && (0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_8__.css)(elm, rule, null); |
| 30134 |
mode = jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_10__.UNSET; |
| 30135 |
mode = removeExtraStyleAttribute(commitStyle, elm, mode); |
| 30136 |
return; |
| 30137 |
} |
| 30138 |
mode = jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_10__.CHANGE; |
| 30139 |
if (!dry) { |
| 30140 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_8__.css)(elm, rule, newValue); |
| 30141 |
mode = removeExtraStyleAttribute(commitStyle, elm, mode); |
| 30142 |
} |
| 30143 |
}); |
| 30144 |
return mode; |
| 30145 |
} |
| 30146 |
function toggleClass(jodit, value, elm, mode, dry) { |
| 30147 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_7__.assert)((0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_3__.isString)(value), 'Class name must be a string'); |
| 30148 |
const hook = jodit.e.fire.bind(jodit.e, `${jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_10__._PREFIX}AfterToggleAttribute`); |
| 30149 |
if (elm.classList.contains(value.toString())) { |
| 30150 |
mode = jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_10__.UNSET; |
| 30151 |
if (!dry) { |
| 30152 |
elm.classList.remove(value); |
| 30153 |
if (elm.classList.length === 0) { |
| 30154 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_7__.attr)(elm, 'class', null); |
| 30155 |
hook(mode, elm, 'class', null); |
| 30156 |
} |
| 30157 |
} |
| 30158 |
} else { |
| 30159 |
mode = jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_10__.CHANGE; |
| 30160 |
if (!dry) { |
| 30161 |
elm.classList.add(value); |
| 30162 |
hook(mode, elm, 'class', value); |
| 30163 |
} |
| 30164 |
} |
| 30165 |
return mode; |
| 30166 |
} |
| 30167 |
function toggleAttribute(jodit, value, elm, key, dry, mode) { |
| 30168 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_7__.assert)((0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_3__.isString)(value) || (0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_3__.isNumber)(value) || (0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_3__.isBoolean)(value) || value == null, 'Attribute value must be a string or number or boolean or null'); |
| 30169 |
const hook = jodit.e.fire.bind(jodit.e, `${jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_10__._PREFIX}AfterToggleAttribute`); |
| 30170 |
if ((0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_7__.attr)(elm, key) === value) { |
| 30171 |
!dry && (0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_7__.attr)(elm, key, null); |
| 30172 |
mode = jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_10__.UNSET; |
| 30173 |
!dry && hook(mode, elm, key, value); |
| 30174 |
return mode; |
| 30175 |
} |
| 30176 |
mode = jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_10__.CHANGE; |
| 30177 |
if (!dry) { |
| 30178 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_7__.attr)(elm, key, value); |
| 30179 |
hook(mode, elm, key, value); |
| 30180 |
} |
| 30181 |
return mode; |
| 30182 |
} |
| 30183 |
/** |
| 30184 |
* If the element has an empty style attribute, it removes the attribute, |
| 30185 |
* and if it is default, it removes the element itself |
| 30186 |
*/ function removeExtraStyleAttribute(commitStyle, elm, mode) { |
| 30187 |
if (!(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_7__.attr)(elm, 'style')) { |
| 30188 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_7__.attr)(elm, 'style', null); |
| 30189 |
if (elm.tagName.toLowerCase() === commitStyle.defaultTag) { |
| 30190 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.unwrap(elm); |
| 30191 |
mode = jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_10__.UNWRAP; |
| 30192 |
} |
| 30193 |
} |
| 30194 |
return mode; |
| 30195 |
} |
| 30196 |
/** |
| 30197 |
* Creates an iframe into which elements will be inserted to test their default styles in the browser |
| 30198 |
*/ function getShadowRoot(jodit) { |
| 30199 |
var _iframe_contentWindow; |
| 30200 |
if ((0,jodit_core_helpers_utils_data_bind__WEBPACK_IMPORTED_MODULE_9__.dataBind)(jodit, 'shadowRoot') !== undefined) { |
| 30201 |
return (0,jodit_core_helpers_utils_data_bind__WEBPACK_IMPORTED_MODULE_9__.dataBind)(jodit, 'shadowRoot'); |
| 30202 |
} |
| 30203 |
const container = (0,jodit_core_global__WEBPACK_IMPORTED_MODULE_2__.getContainer)(jodit); |
| 30204 |
const iframe = jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.globalDocument.createElement('iframe'); |
| 30205 |
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_8__.css)(iframe, { |
| 30206 |
width: 0, |
| 30207 |
height: 0, |
| 30208 |
position: 'absolute', |
| 30209 |
border: 0 |
| 30210 |
}); |
| 30211 |
iframe.src = 'about:blank'; |
| 30212 |
container.appendChild(iframe); |
| 30213 |
const doc = (_iframe_contentWindow = iframe.contentWindow) === null || _iframe_contentWindow === void 0 ? void 0 : _iframe_contentWindow.document; |
| 30214 |
const shadowRoot = !doc ? jodit.od.body : doc.body; |
| 30215 |
(0,jodit_core_helpers_utils_data_bind__WEBPACK_IMPORTED_MODULE_9__.dataBind)(jodit, 'shadowRoot', shadowRoot); |
| 30216 |
return shadowRoot; |
| 30217 |
} |
| 30218 |
/** |
| 30219 |
* `strong -> fontWeight 700` |
| 30220 |
*/ function getNativeCSSValue(jodit, elm, key) { |
| 30221 |
const newElm = jodit.create.element(elm.tagName.toLowerCase()); |
| 30222 |
newElm.style.cssText = elm.style.cssText; |
| 30223 |
const root = getShadowRoot(jodit); |
| 30224 |
root.appendChild(newElm); |
| 30225 |
const result = (0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_8__.css)(newElm, key); |
| 30226 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.safeRemove(newElm); |
| 30227 |
return result; |
| 30228 |
} |
| 30229 |
|
| 30230 |
|
| 30231 |
/***/ }), |
| 30232 |
|
| 30233 |
/***/ 83207: |
| 30234 |
/***/ (function(module) { |
| 30235 |
|
| 30236 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path stroke-width=\"0\" d=\"M384 1408q0 80-56 136t-136 56-136-56-56-136 56-136 136-56 136 56 56 136zm0-512q0 80-56 136t-136 56-136-56-56-136 56-136 136-56 136 56 56 136zm1408 416v192q0 13-9.5 22.5t-22.5 9.5h-1216q-13 0-22.5-9.5t-9.5-22.5v-192q0-13 9.5-22.5t22.5-9.5h1216q13 0 22.5 9.5t9.5 22.5zm-1408-928q0 80-56 136t-136 56-136-56-56-136 56-136 136-56 136 56 56 136zm1408 416v192q0 13-9.5 22.5t-22.5 9.5h-1216q-13 0-22.5-9.5t-9.5-22.5v-192q0-13 9.5-22.5t22.5-9.5h1216q13 0 22.5 9.5t9.5 22.5zm0-512v192q0 13-9.5 22.5t-22.5 9.5h-1216q-13 0-22.5-9.5t-9.5-22.5v-192q0-13 9.5-22.5t22.5-9.5h1216q13 0 22.5 9.5t9.5 22.5z\"/> </svg>" |
| 30237 |
|
| 30238 |
/***/ }), |
| 30239 |
|
| 30240 |
/***/ 83215: |
| 30241 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 30242 |
|
| 30243 |
"use strict"; |
| 30244 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 30245 |
/* harmony export */ innerWidth: function() { return /* binding */ innerWidth; } |
| 30246 |
/* harmony export */ }); |
| 30247 |
/*! |
| 30248 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 30249 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 30250 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 30251 |
*/ /** |
| 30252 |
* @module helpers/size |
| 30253 |
*/ const innerWidth = (element, win)=>{ |
| 30254 |
const computedStyle = win.getComputedStyle(element); |
| 30255 |
let elementWidth = element.clientWidth; // width with padding |
| 30256 |
elementWidth -= parseFloat(computedStyle.paddingLeft || '0') + parseFloat(computedStyle.paddingRight || '0'); |
| 30257 |
return elementWidth; |
| 30258 |
}; |
| 30259 |
|
| 30260 |
|
| 30261 |
/***/ }), |
| 30262 |
|
| 30263 |
/***/ 83335: |
| 30264 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 30265 |
|
| 30266 |
"use strict"; |
| 30267 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 30268 |
/* harmony export */ wrapUnwrappedText: function() { return /* binding */ wrapUnwrappedText; } |
| 30269 |
/* harmony export */ }); |
| 30270 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 30271 |
/* harmony import */ var jodit_core_helpers_checker_is_marker__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(23175); |
| 30272 |
/*! |
| 30273 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 30274 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 30275 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 30276 |
*/ |
| 30277 |
|
| 30278 |
/** |
| 30279 |
* Wrap text or inline elements inside Block element |
| 30280 |
* @private |
| 30281 |
*/ function wrapUnwrappedText(style, elm, jodit) { |
| 30282 |
const root = jodit.editor, ci = jodit.createInside, edge = (n, key = 'previousSibling')=>{ |
| 30283 |
let edgeNode = n, node = n; |
| 30284 |
while(node && !(0,jodit_core_helpers_checker_is_marker__WEBPACK_IMPORTED_MODULE_1__.isMarker)(node)){ |
| 30285 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(node, jodit.o.enter)) { |
| 30286 |
break; |
| 30287 |
} |
| 30288 |
edgeNode = node; |
| 30289 |
if (node[key]) { |
| 30290 |
node = node[key]; |
| 30291 |
} else { |
| 30292 |
node = node.parentNode && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isBlock(node.parentNode) && node.parentNode !== root ? node.parentNode : null; |
| 30293 |
} |
| 30294 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isBlock(node)) { |
| 30295 |
break; |
| 30296 |
} |
| 30297 |
} |
| 30298 |
return edgeNode; |
| 30299 |
}; |
| 30300 |
const start = edge(elm), end = edge(elm, 'nextSibling'); |
| 30301 |
const range = jodit.s.createRange(); |
| 30302 |
range.setStartBefore(start); |
| 30303 |
range.setEndAfter(end); |
| 30304 |
const fragment = range.extractContents(); |
| 30305 |
const wrapper = ci.element(style.element); |
| 30306 |
wrapper.appendChild(fragment); |
| 30307 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.safeInsertNode(range, wrapper); |
| 30308 |
if (style.elementIsBlock) { |
| 30309 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isEmpty(wrapper) && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(wrapper.firstElementChild, 'br')) { |
| 30310 |
wrapper.appendChild(ci.element('br')); |
| 30311 |
} |
| 30312 |
} |
| 30313 |
return wrapper; |
| 30314 |
} |
| 30315 |
|
| 30316 |
|
| 30317 |
/***/ }), |
| 30318 |
|
| 30319 |
/***/ 83376: |
| 30320 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 30321 |
|
| 30322 |
"use strict"; |
| 30323 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 30324 |
/* harmony export */ getBlockWrapper: function() { return /* binding */ getBlockWrapper; } |
| 30325 |
/* harmony export */ }); |
| 30326 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 30327 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(23211); |
| 30328 |
/*! |
| 30329 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 30330 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 30331 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 30332 |
*/ /** |
| 30333 |
* @module plugins/enter |
| 30334 |
*/ |
| 30335 |
|
| 30336 |
/** |
| 30337 |
* Finds a suitable parent block container |
| 30338 |
* @private |
| 30339 |
*/ function getBlockWrapper(fake, jodit, tagReg = jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.IS_BLOCK) { |
| 30340 |
let node = fake; |
| 30341 |
const root = jodit.editor; |
| 30342 |
do { |
| 30343 |
if (!node || node === root) { |
| 30344 |
break; |
| 30345 |
} |
| 30346 |
if (tagReg.test(node.nodeName)) { |
| 30347 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isLeaf(node)) { |
| 30348 |
return node; |
| 30349 |
} |
| 30350 |
return getBlockWrapper(node.parentNode, jodit, /^li$/i) || node; |
| 30351 |
} |
| 30352 |
node = node.parentNode; |
| 30353 |
}while (node && node !== root) |
| 30354 |
return null; |
| 30355 |
} |
| 30356 |
|
| 30357 |
|
| 30358 |
/***/ }), |
| 30359 |
|
| 30360 |
/***/ 83389: |
| 30361 |
/***/ (function(module) { |
| 30362 |
|
| 30363 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M176 223q-37-2-45-4l-3-88q13-1 40-1 60 0 112 4 132 7 166 7 86 0 168-3 116-4 146-5 56 0 86-2l-1 14 2 64v9q-60 9-124 9-60 0-79 25-13 14-13 132 0 13 .5 32.5t.5 25.5l1 229 14 280q6 124 51 202 35 59 96 92 88 47 177 47 104 0 191-28 56-18 99-51 48-36 65-64 36-56 53-114 21-73 21-229 0-79-3.5-128t-11-122.5-13.5-159.5l-4-59q-5-67-24-88-34-35-77-34l-100 2-14-3 2-86h84l205 10q76 3 196-10l18 2q6 38 6 51 0 7-4 31-45 12-84 13-73 11-79 17-15 15-15 41 0 7 1.5 27t1.5 31q8 19 22 396 6 195-15 304-15 76-41 122-38 65-112 123-75 57-182 89-109 33-255 33-167 0-284-46-119-47-179-122-61-76-83-195-16-80-16-237v-333q0-188-17-213-25-36-147-39zm1488 1409v-64q0-14-9-23t-23-9h-1472q-14 0-23 9t-9 23v64q0 14 9 23t23 9h1472q14 0 23-9t9-23z\"/> </svg>" |
| 30364 |
|
| 30365 |
/***/ }), |
| 30366 |
|
| 30367 |
/***/ 83653: |
| 30368 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 30369 |
|
| 30370 |
"use strict"; |
| 30371 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 30372 |
/* harmony export */ isNormalNode: function() { return /* binding */ isNormalNode; } |
| 30373 |
/* harmony export */ }); |
| 30374 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 30375 |
/* harmony import */ var jodit_core_helpers_checker_is_marker__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(23175); |
| 30376 |
/*! |
| 30377 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 30378 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 30379 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 30380 |
*/ |
| 30381 |
|
| 30382 |
/** |
| 30383 |
* Is normal usual element |
| 30384 |
* @private |
| 30385 |
*/ function isNormalNode(elm) { |
| 30386 |
return Boolean(elm && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isEmptyTextNode(elm) && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTemporary(elm) && !(0,jodit_core_helpers_checker_is_marker__WEBPACK_IMPORTED_MODULE_1__.isMarker)(elm)); |
| 30387 |
} |
| 30388 |
|
| 30389 |
|
| 30390 |
/***/ }), |
| 30391 |
|
| 30392 |
/***/ 83708: |
| 30393 |
/***/ (function(module) { |
| 30394 |
|
| 30395 |
/*! |
| 30396 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 30397 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 30398 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 30399 |
*/ module.exports = { |
| 30400 |
'copy-format': 'copyformat' |
| 30401 |
}; |
| 30402 |
|
| 30403 |
|
| 30404 |
/***/ }), |
| 30405 |
|
| 30406 |
/***/ 83778: |
| 30407 |
/***/ (function(module) { |
| 30408 |
|
| 30409 |
/*! |
| 30410 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 30411 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 30412 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 30413 |
*/ module.exports = { |
| 30414 |
'copy-format': 'Format kopierenт' |
| 30415 |
}; |
| 30416 |
|
| 30417 |
|
| 30418 |
/***/ }), |
| 30419 |
|
| 30420 |
/***/ 84578: |
| 30421 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 30422 |
|
| 30423 |
"use strict"; |
| 30424 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 30425 |
/* harmony export */ CommitStyle: function() { return /* binding */ CommitStyle; } |
| 30426 |
/* harmony export */ }); |
| 30427 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 30428 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(81937); |
| 30429 |
/* harmony import */ var jodit_core_helpers_string_camel_case__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(57821); |
| 30430 |
/* harmony import */ var jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(98394); |
| 30431 |
/* harmony import */ var _apply_style__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(96127); |
| 30432 |
/*! |
| 30433 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 30434 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 30435 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 30436 |
*/ /** |
| 30437 |
* @module selection |
| 30438 |
*/ |
| 30439 |
|
| 30440 |
|
| 30441 |
|
| 30442 |
|
| 30443 |
class CommitStyle { |
| 30444 |
isApplied(elm, key) { |
| 30445 |
const data = this.__applyMap.get(elm); |
| 30446 |
if (!data) { |
| 30447 |
return false; |
| 30448 |
} |
| 30449 |
return data[key]; |
| 30450 |
} |
| 30451 |
setApplied(elm, key) { |
| 30452 |
var _this___applyMap_get; |
| 30453 |
const data = (_this___applyMap_get = this.__applyMap.get(elm)) !== null && _this___applyMap_get !== void 0 ? _this___applyMap_get : {}; |
| 30454 |
data[key] = true; |
| 30455 |
this.__applyMap.set(elm, data); |
| 30456 |
} |
| 30457 |
get elementIsList() { |
| 30458 |
return Boolean(this.options.element && jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.LIST_TAGS.has(this.options.element)); |
| 30459 |
} |
| 30460 |
get element() { |
| 30461 |
return this.options.element || this.defaultTag; |
| 30462 |
} |
| 30463 |
/** |
| 30464 |
* New element is blocked |
| 30465 |
*/ get elementIsBlock() { |
| 30466 |
return Boolean(this.options.element && jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.IS_BLOCK.test(this.options.element)); |
| 30467 |
} |
| 30468 |
/** |
| 30469 |
* The commit applies the tag change |
| 30470 |
*/ get isElementCommit() { |
| 30471 |
return Boolean(this.options.element && this.options.element !== this.options.defaultTag); |
| 30472 |
} |
| 30473 |
get defaultTag() { |
| 30474 |
if (this.options.defaultTag) { |
| 30475 |
return this.options.defaultTag; |
| 30476 |
} |
| 30477 |
return this.elementIsBlock ? 'p' : 'span'; |
| 30478 |
} |
| 30479 |
get elementIsDefault() { |
| 30480 |
return this.element === this.defaultTag; |
| 30481 |
} |
| 30482 |
apply(jodit) { |
| 30483 |
const { hooks } = this.options; |
| 30484 |
const keys = hooks ? Object.keys(hooks) : []; |
| 30485 |
try { |
| 30486 |
keys.forEach((key)=>{ |
| 30487 |
jodit.e.on((0,jodit_core_helpers_string_camel_case__WEBPACK_IMPORTED_MODULE_2__.camelCase)(jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_3__._PREFIX + '_' + key), hooks[key]); |
| 30488 |
}); |
| 30489 |
(0,_apply_style__WEBPACK_IMPORTED_MODULE_4__.ApplyStyle)(jodit, this); |
| 30490 |
} finally{ |
| 30491 |
keys.forEach((key)=>{ |
| 30492 |
jodit.e.off((0,jodit_core_helpers_string_camel_case__WEBPACK_IMPORTED_MODULE_2__.camelCase)(jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_3__._PREFIX + '_' + key), hooks[key]); |
| 30493 |
}); |
| 30494 |
this.__applyMap = new WeakMap(); |
| 30495 |
} |
| 30496 |
jodit.synchronizeValues(); |
| 30497 |
jodit.e.fire('afterCommitStyle', this); |
| 30498 |
} |
| 30499 |
constructor(options){ |
| 30500 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "options", void 0); |
| 30501 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__applyMap", void 0); |
| 30502 |
this.options = options; |
| 30503 |
this.__applyMap = new WeakMap(); |
| 30504 |
} |
| 30505 |
} |
| 30506 |
|
| 30507 |
|
| 30508 |
/***/ }), |
| 30509 |
|
| 30510 |
/***/ 84839: |
| 30511 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 30512 |
|
| 30513 |
"use strict"; |
| 30514 |
__webpack_require__.r(__webpack_exports__); |
| 30515 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 30516 |
/* harmony export */ autobind: function() { return /* reexport safe */ _autobind_autobind__WEBPACK_IMPORTED_MODULE_0__.autobind; }, |
| 30517 |
/* harmony export */ cache: function() { return /* reexport safe */ _cache_cache__WEBPACK_IMPORTED_MODULE_1__.cache; }, |
| 30518 |
/* harmony export */ cacheHTML: function() { return /* reexport safe */ _cache_cache__WEBPACK_IMPORTED_MODULE_1__.cacheHTML; }, |
| 30519 |
/* harmony export */ cached: function() { return /* reexport safe */ _cache_cache__WEBPACK_IMPORTED_MODULE_1__.cached; }, |
| 30520 |
/* harmony export */ component: function() { return /* reexport safe */ _component_component__WEBPACK_IMPORTED_MODULE_2__.component; }, |
| 30521 |
/* harmony export */ debounce: function() { return /* reexport safe */ _debounce_debounce__WEBPACK_IMPORTED_MODULE_3__.debounce; }, |
| 30522 |
/* harmony export */ derive: function() { return /* reexport safe */ _derive_derive__WEBPACK_IMPORTED_MODULE_4__.derive; }, |
| 30523 |
/* harmony export */ getComponentClass: function() { return /* reexport safe */ _component_component__WEBPACK_IMPORTED_MODULE_2__.getComponentClass; }, |
| 30524 |
/* harmony export */ hook: function() { return /* reexport safe */ _hook_hook__WEBPACK_IMPORTED_MODULE_5__.hook; }, |
| 30525 |
/* harmony export */ idle: function() { return /* reexport safe */ _idle_idle__WEBPACK_IMPORTED_MODULE_6__.idle; }, |
| 30526 |
/* harmony export */ nonenumerable: function() { return /* reexport safe */ _nonenumerable_nonenumerable__WEBPACK_IMPORTED_MODULE_7__.nonenumerable; }, |
| 30527 |
/* harmony export */ persistent: function() { return /* reexport safe */ _persistent_persistent__WEBPACK_IMPORTED_MODULE_8__.persistent; }, |
| 30528 |
/* harmony export */ throttle: function() { return /* reexport safe */ _debounce_debounce__WEBPACK_IMPORTED_MODULE_3__.throttle; }, |
| 30529 |
/* harmony export */ wait: function() { return /* reexport safe */ _wait_wait__WEBPACK_IMPORTED_MODULE_9__.wait; }, |
| 30530 |
/* harmony export */ watch: function() { return /* reexport safe */ _watch_watch__WEBPACK_IMPORTED_MODULE_10__.watch; } |
| 30531 |
/* harmony export */ }); |
| 30532 |
/* harmony import */ var _autobind_autobind__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(49574); |
| 30533 |
/* harmony import */ var _cache_cache__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(51676); |
| 30534 |
/* harmony import */ var _component_component__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(91672); |
| 30535 |
/* harmony import */ var _debounce_debounce__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(55184); |
| 30536 |
/* harmony import */ var _derive_derive__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(24968); |
| 30537 |
/* harmony import */ var _hook_hook__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(29200); |
| 30538 |
/* harmony import */ var _idle_idle__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(35718); |
| 30539 |
/* harmony import */ var _nonenumerable_nonenumerable__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(41360); |
| 30540 |
/* harmony import */ var _persistent_persistent__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(77036); |
| 30541 |
/* harmony import */ var _wait_wait__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(80840); |
| 30542 |
/* harmony import */ var _watch_watch__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(68616); |
| 30543 |
/*! |
| 30544 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 30545 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 30546 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 30547 |
*/ /** |
| 30548 |
* [[include:core/decorators/README.md]] |
| 30549 |
* @packageDocumentation |
| 30550 |
* @module decorators |
| 30551 |
*/ |
| 30552 |
|
| 30553 |
|
| 30554 |
|
| 30555 |
|
| 30556 |
|
| 30557 |
|
| 30558 |
|
| 30559 |
|
| 30560 |
|
| 30561 |
|
| 30562 |
|
| 30563 |
|
| 30564 |
/***/ }), |
| 30565 |
|
| 30566 |
/***/ 85305: |
| 30567 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 30568 |
|
| 30569 |
"use strict"; |
| 30570 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 30571 |
/* harmony export */ PluginSystem: function() { return /* binding */ PluginSystem; } |
| 30572 |
/* harmony export */ }); |
| 30573 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 30574 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(81937); |
| 30575 |
/* harmony import */ var jodit_core_event_emitter_global__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(42689); |
| 30576 |
/* harmony import */ var jodit_core_helpers_array_split_array__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(32328); |
| 30577 |
/* harmony import */ var jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(17312); |
| 30578 |
/* harmony import */ var jodit_core_helpers_checker_is_imp_interface__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(52433); |
| 30579 |
/* harmony import */ var jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(85932); |
| 30580 |
/* harmony import */ var jodit_core_plugin_helpers_init_instance__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(55810); |
| 30581 |
/* harmony import */ var jodit_core_plugin_helpers_load__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(3050); |
| 30582 |
/* harmony import */ var jodit_core_plugin_helpers_make_instance__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(25974); |
| 30583 |
/* harmony import */ var jodit_core_plugin_helpers_utils__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(86189); |
| 30584 |
/*! |
| 30585 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 30586 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 30587 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 30588 |
*/ /** |
| 30589 |
* @module plugin |
| 30590 |
*/ |
| 30591 |
|
| 30592 |
|
| 30593 |
|
| 30594 |
|
| 30595 |
|
| 30596 |
|
| 30597 |
|
| 30598 |
|
| 30599 |
|
| 30600 |
|
| 30601 |
|
| 30602 |
/** |
| 30603 |
* Jodit plugin system |
| 30604 |
* @example |
| 30605 |
* ```js |
| 30606 |
* Jodit.plugins.add('emoji2', { |
| 30607 |
* init() { |
| 30608 |
* alert('emoji Inited2') |
| 30609 |
* }, |
| 30610 |
* destruct() {} |
| 30611 |
* }); |
| 30612 |
* ``` |
| 30613 |
*/ class PluginSystem { |
| 30614 |
get size() { |
| 30615 |
return this.__items.size; |
| 30616 |
} |
| 30617 |
/** |
| 30618 |
* Add plugin in store |
| 30619 |
*/ add(name, plugin) { |
| 30620 |
this.__items.set((0,jodit_core_plugin_helpers_utils__WEBPACK_IMPORTED_MODULE_10__.normalizeName)(name), plugin); |
| 30621 |
jodit_core_event_emitter_global__WEBPACK_IMPORTED_MODULE_2__.eventEmitter.fire(`plugin:${name}:ready`); |
| 30622 |
} |
| 30623 |
/** |
| 30624 |
* Get plugin from store |
| 30625 |
*/ get(name) { |
| 30626 |
return this.__items.get((0,jodit_core_plugin_helpers_utils__WEBPACK_IMPORTED_MODULE_10__.normalizeName)(name)); |
| 30627 |
} |
| 30628 |
/** |
| 30629 |
* Remove plugin from store |
| 30630 |
*/ remove(name) { |
| 30631 |
this.__items.delete((0,jodit_core_plugin_helpers_utils__WEBPACK_IMPORTED_MODULE_10__.normalizeName)(name)); |
| 30632 |
} |
| 30633 |
__getFullPluginsList(filter) { |
| 30634 |
const results = []; |
| 30635 |
this.__items.forEach((plugin, name)=>{ |
| 30636 |
if (!filter || filter.has(name)) { |
| 30637 |
results.push([ |
| 30638 |
name, |
| 30639 |
plugin |
| 30640 |
]); |
| 30641 |
} |
| 30642 |
}); |
| 30643 |
return results; |
| 30644 |
} |
| 30645 |
/** |
| 30646 |
* Public method for async init all plugins |
| 30647 |
*/ __init(jodit) { |
| 30648 |
const { extraList, disableList, filter } = getSpecialLists(jodit); |
| 30649 |
const doneList = new Map(); |
| 30650 |
const pluginsMap = {}; |
| 30651 |
const waitingList = new Set(); |
| 30652 |
jodit.__plugins = pluginsMap; |
| 30653 |
const initPlugins = ()=>{ |
| 30654 |
if (jodit.isInDestruct) { |
| 30655 |
return; |
| 30656 |
} |
| 30657 |
let commit = false; |
| 30658 |
this.__getFullPluginsList(filter).forEach(([name, plugin])=>{ |
| 30659 |
if (disableList.has(name) || doneList.has(name)) { |
| 30660 |
return; |
| 30661 |
} |
| 30662 |
const requires = plugin === null || plugin === void 0 ? void 0 : plugin.requires; |
| 30663 |
if (requires && (0,jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_4__.isArray)(requires) && requires.length) { |
| 30664 |
if (requires.some((req)=>disableList.has(req))) { |
| 30665 |
return; |
| 30666 |
} |
| 30667 |
if (!requires.every((name)=>doneList.has(name))) { |
| 30668 |
waitingList.add(name); |
| 30669 |
return; |
| 30670 |
} |
| 30671 |
} |
| 30672 |
commit = true; |
| 30673 |
const instance = (0,jodit_core_plugin_helpers_make_instance__WEBPACK_IMPORTED_MODULE_9__.makeInstance)(jodit, plugin); |
| 30674 |
if (!instance) { |
| 30675 |
doneList.set(name, null); |
| 30676 |
waitingList.delete(name); |
| 30677 |
return; |
| 30678 |
} |
| 30679 |
(0,jodit_core_plugin_helpers_init_instance__WEBPACK_IMPORTED_MODULE_7__.init)(jodit, name, plugin, instance, doneList, waitingList, this.opts.getContainer); |
| 30680 |
pluginsMap[name] = instance; |
| 30681 |
}); |
| 30682 |
if (commit) { |
| 30683 |
jodit.e.fire('updatePlugins'); |
| 30684 |
initPlugins(); |
| 30685 |
} |
| 30686 |
}; |
| 30687 |
if (extraList && extraList.length) { |
| 30688 |
(0,jodit_core_plugin_helpers_load__WEBPACK_IMPORTED_MODULE_8__.loadExtras)(this.__items, jodit, extraList, initPlugins); |
| 30689 |
} |
| 30690 |
initPlugins(); |
| 30691 |
bindOnBeforeDestruct(jodit, pluginsMap); |
| 30692 |
if (!jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.IS_PROD && waitingList.size) { |
| 30693 |
console.warn('After init plugin waiting list is not clean:', waitingList); |
| 30694 |
} |
| 30695 |
} |
| 30696 |
/** |
| 30697 |
* Returns the promise to wait for the plugin to load. |
| 30698 |
*/ wait(name) { |
| 30699 |
return new Promise((resolve)=>{ |
| 30700 |
if (this.get(name)) { |
| 30701 |
return resolve(); |
| 30702 |
} |
| 30703 |
const onReady = ()=>{ |
| 30704 |
resolve(); |
| 30705 |
jodit_core_event_emitter_global__WEBPACK_IMPORTED_MODULE_2__.eventEmitter.off(`plugin:${name}:ready`, onReady); |
| 30706 |
}; |
| 30707 |
jodit_core_event_emitter_global__WEBPACK_IMPORTED_MODULE_2__.eventEmitter.on(`plugin:${name}:ready`, onReady); |
| 30708 |
}); |
| 30709 |
} |
| 30710 |
constructor(opts){ |
| 30711 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "opts", void 0); |
| 30712 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__items", void 0); |
| 30713 |
this.opts = opts; |
| 30714 |
this.__items = new Map(); |
| 30715 |
} |
| 30716 |
} |
| 30717 |
/** |
| 30718 |
* Destroy all plugins before - Jodit will be destroyed |
| 30719 |
*/ function bindOnBeforeDestruct(jodit, plugins) { |
| 30720 |
jodit.e.on('beforeDestruct', ()=>{ |
| 30721 |
Object.keys(plugins).forEach((name)=>{ |
| 30722 |
const instance = plugins[name]; |
| 30723 |
if ((0,jodit_core_helpers_checker_is_imp_interface__WEBPACK_IMPORTED_MODULE_5__.isDestructable)(instance)) { |
| 30724 |
instance.destruct(jodit); |
| 30725 |
} |
| 30726 |
delete plugins[name]; |
| 30727 |
}); |
| 30728 |
delete jodit.__plugins; |
| 30729 |
}); |
| 30730 |
} |
| 30731 |
function getSpecialLists(jodit) { |
| 30732 |
const extraList = jodit.o.extraPlugins.map((s)=>(0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_6__.isString)(s) ? { |
| 30733 |
name: s |
| 30734 |
} : s); |
| 30735 |
const disableList = new Set((0,jodit_core_helpers_array_split_array__WEBPACK_IMPORTED_MODULE_3__.splitArray)(jodit.o.disablePlugins).map(jodit_core_plugin_helpers_utils__WEBPACK_IMPORTED_MODULE_10__.normalizeName)); |
| 30736 |
const filter = jodit.o.safeMode ? new Set(jodit.o.safePluginsList) : null; |
| 30737 |
return { |
| 30738 |
extraList, |
| 30739 |
disableList, |
| 30740 |
filter |
| 30741 |
}; |
| 30742 |
} |
| 30743 |
|
| 30744 |
|
| 30745 |
/***/ }), |
| 30746 |
|
| 30747 |
/***/ 85932: |
| 30748 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 30749 |
|
| 30750 |
"use strict"; |
| 30751 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 30752 |
/* harmony export */ isString: function() { return /* binding */ isString; }, |
| 30753 |
/* harmony export */ isStringArray: function() { return /* binding */ isStringArray; } |
| 30754 |
/* harmony export */ }); |
| 30755 |
/* harmony import */ var jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(17312); |
| 30756 |
/*! |
| 30757 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 30758 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 30759 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 30760 |
*/ /** |
| 30761 |
* @module helpers/checker |
| 30762 |
*/ |
| 30763 |
/** |
| 30764 |
* Check value is String |
| 30765 |
*/ function isString(value) { |
| 30766 |
return typeof value === 'string'; |
| 30767 |
} |
| 30768 |
/** |
| 30769 |
* Check value is Array of String |
| 30770 |
*/ function isStringArray(value) { |
| 30771 |
return (0,jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_0__.isArray)(value) && isString(value[0]); |
| 30772 |
} |
| 30773 |
|
| 30774 |
|
| 30775 |
/***/ }), |
| 30776 |
|
| 30777 |
/***/ 86122: |
| 30778 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 30779 |
|
| 30780 |
"use strict"; |
| 30781 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 30782 |
/* harmony export */ FileBrowserFiles: function() { return /* binding */ FileBrowserFiles; } |
| 30783 |
/* harmony export */ }); |
| 30784 |
/* harmony import */ var jodit_core_ui__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(4099); |
| 30785 |
/*! |
| 30786 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 30787 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 30788 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 30789 |
*/ |
| 30790 |
|
| 30791 |
class FileBrowserFiles extends jodit_core_ui__WEBPACK_IMPORTED_MODULE_0__.UIGroup { |
| 30792 |
className() { |
| 30793 |
return 'FileBrowserFiles'; |
| 30794 |
} |
| 30795 |
} |
| 30796 |
|
| 30797 |
|
| 30798 |
/***/ }), |
| 30799 |
|
| 30800 |
/***/ 86189: |
| 30801 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 30802 |
|
| 30803 |
"use strict"; |
| 30804 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 30805 |
/* harmony export */ normalizeName: function() { return /* binding */ normalizeName; } |
| 30806 |
/* harmony export */ }); |
| 30807 |
/* harmony import */ var jodit_core_helpers_string_kebab_case__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(74264); |
| 30808 |
/*! |
| 30809 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 30810 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 30811 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 30812 |
*/ /** |
| 30813 |
* @module plugin |
| 30814 |
*/ |
| 30815 |
/** |
| 30816 |
* @private |
| 30817 |
*/ function normalizeName(name) { |
| 30818 |
return (0,jodit_core_helpers_string_kebab_case__WEBPACK_IMPORTED_MODULE_0__.kebabCase)(name).toLowerCase(); |
| 30819 |
} |
| 30820 |
|
| 30821 |
|
| 30822 |
/***/ }), |
| 30823 |
|
| 30824 |
/***/ 86433: |
| 30825 |
/***/ (function(module) { |
| 30826 |
|
| 30827 |
module.exports["default"] = ["Escreva algo...","Sobre o Jodit","Editor Jodit","Guia de usuário Jodit","contém ajuda detalhada para o uso.","Para informação sobre a licença, por favor visite nosso site:","Compre a versão completa","Copyright © XDSoft.net - Chupurnov Valeriy. Todos os direitos reservados.","Link","Abrir em nova aba","Abrir editor em tela cheia","Limpar formatação","Cor de preenchimento ou cor do texto","Refazer","Desfazer","Negrito","Itálico","Inserir lista não ordenada","Inserir lista ordenada","Centralizar","Justificar","Alinhar à Esquerda","Alinhar à Direita","Inserir linha horizontal","Inserir imagem","Inserir arquivo","Inserir vídeo do Youtube/vimeo","Inserir link","Tamanho da letra","Fonte","Inserir bloco","Normal","Cabeçalho 1","Cabeçalho 2","Cabeçalho 3","Cabeçalho 4","Citação","Código","Inserir","Inserir tabela","Diminuir recuo","Aumentar recuo","Selecionar caractere especial","Inserir caractere especial","Copiar formato","Mudar modo","Margens","cima","direta","baixo","esquerda","Estilos CSS","Classes CSS","Alinhamento","Direita","Centro","Esquerda","--Não Estabelecido--","Fonte","Título","Texto Alternativo","Link","Abrir link em nova aba","Imagem","Arquivo","Avançado","Propriedades da imagem","Cancelar","Ok","Procurar arquivo","Erro ao carregar a lista","Erro ao carregar as pastas","Você tem certeza?","Escreva o nome da pasta","Criar pasta","Escreva seu nome","Soltar imagem","Soltar arquivo","ou clique","Texto alternativo","Upload","Explorar","Fundo","Texto","Cima","Meio","Baixo","Inserir coluna antes","Inserir coluna depois","Inserir linha acima","Inserir linha abaixo","Excluir tabela","Excluir linha","Excluir coluna","Limpar célula","Caracteres: %d","Palavras: %d","Tachado","Sublinhar","sobrescrito","subscrito","Cortar seleção","Selecionar tudo","Pausa","Procurar por","Substituir com","Substituir","Colar","Escolher conteúdo para colar","HTML","negrito","itálico","pincel","link","desfazer","refazer","tabela","imagem","apagar","parágrafo","tamanho da letra","vídeo","fonte","Sobre de","Imprimir","sublinhar","tachado","recuar","diminuir recuo","Tamanho completo","diminuir","linha horizontal","lista não ordenada","lista ordenada","Cortar","Selecionar tudo","Incluir código","Abrir link","Editar link","Não siga","Remover link","Atualizar","Editar","Visualizar","URL","Editar","Alinhamento horizontal","filtrar","Ordenar por modificação","Ordenar por nome","Ordenar por tamanho","Adicionar pasta","Resetar","Salvar","Salvar como...","Redimensionar","Recortar","Largura","Altura","Manter a proporção","Sim","Não","Remover","Selecionar","Selecionar: %s","Alinhamento vertical","Dividir","Mesclar","Adicionar coluna","Adicionar linha","Licença: %s","Excluir","Dividir vertical","Dividir horizontal","Borda","Seu código é similar ao HTML. Manter como HTML?","Colar como HTML?","Manter","Inserir como Texto","Inserir somente o Texto","Você só pode editar suas próprias imagens. Baixar essa imagem pro servidor?","A imagem foi enviada com sucesso para o servidor!","Palette","Não há arquivos nesse diretório.","Húngara","Digite um novo nome","preview","Baixar","Colar da área de transferência","O seu navegador não oferece suporte a acesso direto para a área de transferência.","Selecção de cópia","cópia","Border radius","Mostrar todos os","Aplicar","Por favor, preencha este campo","Por favor introduza um endereço web","Padrão","Círculo","Ponto","Quadro","Encontrar","Encontrar Anteriores","Localizar Próxima","O conteúdo colado veio de um documento Microsoft Word/Excel. Você deseja manter o formato ou limpa-lo?","Colado do Word Detectado","Limpar","Insira o nome da classe","Pressione Alt para redimensionamento personalizado",null,null,null,"Tudo"] |
| 30828 |
|
| 30829 |
/***/ }), |
| 30830 |
|
| 30831 |
/***/ 86581: |
| 30832 |
/***/ (function(module) { |
| 30833 |
|
| 30834 |
/*! |
| 30835 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 30836 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 30837 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 30838 |
*/ module.exports = { |
| 30839 |
symbols: 'Sembol' |
| 30840 |
}; |
| 30841 |
|
| 30842 |
|
| 30843 |
/***/ }), |
| 30844 |
|
| 30845 |
/***/ 86634: |
| 30846 |
/***/ (function(module) { |
| 30847 |
|
| 30848 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 128 128\" xml:space=\"preserve\"> <polygon points=\"112.4560547,23.3203125 112.4560547,75.8154297 31.4853516,75.8154297 31.4853516,61.953125 16.0131836,72.6357422 0.5410156,83.3164063 16.0131836,93.9990234 31.4853516,104.6796875 31.4853516,90.8183594 112.4560547,90.8183594 112.4560547,90.8339844 127.4589844,90.8339844 127.4589844,23.3203125\"/> </svg>" |
| 30849 |
|
| 30850 |
/***/ }), |
| 30851 |
|
| 30852 |
/***/ 86878: |
| 30853 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 30854 |
|
| 30855 |
"use strict"; |
| 30856 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 30857 |
/* harmony export */ getContentWidth: function() { return /* reexport safe */ _get_content_width__WEBPACK_IMPORTED_MODULE_0__.getContentWidth; }, |
| 30858 |
/* harmony export */ getScrollParent: function() { return /* reexport safe */ _get_scroll_parent__WEBPACK_IMPORTED_MODULE_1__.getScrollParent; }, |
| 30859 |
/* harmony export */ innerWidth: function() { return /* reexport safe */ _inner_width__WEBPACK_IMPORTED_MODULE_2__.innerWidth; }, |
| 30860 |
/* harmony export */ offset: function() { return /* reexport safe */ _offset__WEBPACK_IMPORTED_MODULE_4__.offset; }, |
| 30861 |
/* harmony export */ position: function() { return /* reexport safe */ _position__WEBPACK_IMPORTED_MODULE_5__.position; }, |
| 30862 |
/* harmony export */ size: function() { return /* reexport safe */ _object_size__WEBPACK_IMPORTED_MODULE_3__.size; } |
| 30863 |
/* harmony export */ }); |
| 30864 |
/* harmony import */ var _get_content_width__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(54447); |
| 30865 |
/* harmony import */ var _get_scroll_parent__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(34027); |
| 30866 |
/* harmony import */ var _inner_width__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(83215); |
| 30867 |
/* harmony import */ var _object_size__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(18073); |
| 30868 |
/* harmony import */ var _offset__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(69143); |
| 30869 |
/* harmony import */ var _position__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(23599); |
| 30870 |
/*! |
| 30871 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 30872 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 30873 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 30874 |
*/ /** |
| 30875 |
* @module helpers/size |
| 30876 |
*/ |
| 30877 |
|
| 30878 |
|
| 30879 |
|
| 30880 |
|
| 30881 |
|
| 30882 |
|
| 30883 |
|
| 30884 |
/***/ }), |
| 30885 |
|
| 30886 |
/***/ 87141: |
| 30887 |
/***/ (function(module) { |
| 30888 |
|
| 30889 |
/*! |
| 30890 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 30891 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 30892 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 30893 |
*/ module.exports = { |
| 30894 |
symbols: 'symbool' |
| 30895 |
}; |
| 30896 |
|
| 30897 |
|
| 30898 |
/***/ }), |
| 30899 |
|
| 30900 |
/***/ 87329: |
| 30901 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 30902 |
|
| 30903 |
"use strict"; |
| 30904 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 30905 |
/* harmony export */ UITextArea: function() { return /* binding */ UITextArea; } |
| 30906 |
/* harmony export */ }); |
| 30907 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 30908 |
/* harmony import */ var _swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(41411); |
| 30909 |
/* harmony import */ var _swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(15366); |
| 30910 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(31635); |
| 30911 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(84839); |
| 30912 |
/* harmony import */ var jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(91672); |
| 30913 |
/* harmony import */ var jodit_core_ui_form_inputs_input_input__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(65273); |
| 30914 |
/*! |
| 30915 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 30916 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 30917 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 30918 |
*/ /** |
| 30919 |
* @module ui/form |
| 30920 |
*/ |
| 30921 |
|
| 30922 |
|
| 30923 |
|
| 30924 |
|
| 30925 |
|
| 30926 |
|
| 30927 |
|
| 30928 |
class UITextArea extends jodit_core_ui_form_inputs_input_input__WEBPACK_IMPORTED_MODULE_6__.UIInput { |
| 30929 |
/** @override */ className() { |
| 30930 |
return 'UITextArea'; |
| 30931 |
} |
| 30932 |
createNativeInput(options) { |
| 30933 |
return this.j.create.element('textarea'); |
| 30934 |
} |
| 30935 |
onChangeStateSize() { |
| 30936 |
const { size, resizable } = this.state; |
| 30937 |
this.nativeInput.style.resize = resizable ? 'auto' : 'none'; |
| 30938 |
this.nativeInput.rows = size !== null && size !== void 0 ? size : 5; |
| 30939 |
} |
| 30940 |
constructor(jodit, state){ |
| 30941 |
super(jodit, state), /** @override */ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "state", (0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_1__._)({}, UITextArea.defaultState)); |
| 30942 |
Object.assign(this.state, state); |
| 30943 |
if (this.state.resizable === false) { |
| 30944 |
this.nativeInput.style.resize = 'none'; |
| 30945 |
} |
| 30946 |
} |
| 30947 |
} |
| 30948 |
/** @override */ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(UITextArea, "defaultState", (0,_swc_helpers_object_spread_props__WEBPACK_IMPORTED_MODULE_2__._)((0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_1__._)({}, jodit_core_ui_form_inputs_input_input__WEBPACK_IMPORTED_MODULE_6__.UIInput.defaultState), { |
| 30949 |
size: 5, |
| 30950 |
resizable: true |
| 30951 |
})); |
| 30952 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__.__decorate)([ |
| 30953 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__.watch)([ |
| 30954 |
'state.size', |
| 30955 |
'state.resizable' |
| 30956 |
]) |
| 30957 |
], UITextArea.prototype, "onChangeStateSize", null); |
| 30958 |
UITextArea = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_3__.__decorate)([ |
| 30959 |
jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_5__.component |
| 30960 |
], UITextArea); |
| 30961 |
|
| 30962 |
|
| 30963 |
/***/ }), |
| 30964 |
|
| 30965 |
/***/ 88329: |
| 30966 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 30967 |
|
| 30968 |
"use strict"; |
| 30969 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 30970 |
/* harmony export */ Confirm: function() { return /* binding */ Confirm; } |
| 30971 |
/* harmony export */ }); |
| 30972 |
/* harmony import */ var jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(91565); |
| 30973 |
/* harmony import */ var jodit_core_ui_button_button_button__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(53681); |
| 30974 |
/* harmony import */ var jodit_modules_dialog_dialog__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(76841); |
| 30975 |
/*! |
| 30976 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 30977 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 30978 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 30979 |
*/ /** |
| 30980 |
* @module modules/dialog |
| 30981 |
*/ |
| 30982 |
|
| 30983 |
|
| 30984 |
/** |
| 30985 |
* Show `confirm` dialog. Work without Jodit object |
| 30986 |
* |
| 30987 |
* @param title - Title or callback |
| 30988 |
* @param callback - callback. The first argument is the value entered |
| 30989 |
* @example |
| 30990 |
* ```javascript |
| 30991 |
* Jodit.Confirm("Are you sure?", "Confirm Dialog", function (yes) { |
| 30992 |
* if (yes) { |
| 30993 |
* // do something |
| 30994 |
* } |
| 30995 |
* }); |
| 30996 |
* ``` |
| 30997 |
*/ function Confirm(msg, title, callback) { |
| 30998 |
const dialog = this instanceof jodit_modules_dialog_dialog__WEBPACK_IMPORTED_MODULE_2__.Dialog ? this : new jodit_modules_dialog_dialog__WEBPACK_IMPORTED_MODULE_2__.Dialog({ |
| 30999 |
closeOnClickOverlay: true |
| 31000 |
}), $div = dialog.c.fromHTML('<form class="jodit-dialog_prompt"></form>'), $label = dialog.c.element('label'); |
| 31001 |
if ((0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_0__.isFunction)(title)) { |
| 31002 |
callback = title; |
| 31003 |
title = undefined; |
| 31004 |
} |
| 31005 |
$label.appendChild(dialog.c.fromHTML(msg)); |
| 31006 |
$div.appendChild($label); |
| 31007 |
const action = (yes)=>()=>{ |
| 31008 |
if (!callback || callback(yes) !== false) { |
| 31009 |
dialog.close(); |
| 31010 |
} |
| 31011 |
}; |
| 31012 |
const $cancel = (0,jodit_core_ui_button_button_button__WEBPACK_IMPORTED_MODULE_1__.Button)(dialog, 'cancel', 'Cancel'); |
| 31013 |
const $ok = (0,jodit_core_ui_button_button_button__WEBPACK_IMPORTED_MODULE_1__.Button)(dialog, 'ok', 'Yes'); |
| 31014 |
$cancel.onAction(action(false)); |
| 31015 |
$ok.onAction(action(true)); |
| 31016 |
dialog.e.on($div, 'submit', ()=>{ |
| 31017 |
action(true)(); |
| 31018 |
return false; |
| 31019 |
}); |
| 31020 |
dialog.setFooter([ |
| 31021 |
$ok, |
| 31022 |
$cancel |
| 31023 |
]); |
| 31024 |
dialog.open($div, title || ' ', true, true); |
| 31025 |
$ok.focus(); |
| 31026 |
return dialog; |
| 31027 |
} |
| 31028 |
|
| 31029 |
|
| 31030 |
/***/ }), |
| 31031 |
|
| 31032 |
/***/ 88475: |
| 31033 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 31034 |
|
| 31035 |
"use strict"; |
| 31036 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 31037 |
/* harmony export */ toArray: function() { return /* binding */ toArray; } |
| 31038 |
/* harmony export */ }); |
| 31039 |
/* harmony import */ var jodit_core_helpers_checker_is_native_function__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23283); |
| 31040 |
/* harmony import */ var jodit_core_helpers_utils_reset__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(43379); |
| 31041 |
/*! |
| 31042 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 31043 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 31044 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 31045 |
*/ /** |
| 31046 |
* @module helpers/array |
| 31047 |
*/ |
| 31048 |
|
| 31049 |
/** |
| 31050 |
* Always return Array. It's a safe polyfill for [Array.from](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/from) method |
| 31051 |
* In certain scenarios (such as with Joomla Mootools), Array.from may be substituted with a less optimal implementation |
| 31052 |
* ```javascript |
| 31053 |
* Jodit.modules.Helpers.toArray('123') // ['1', '2', '3'] |
| 31054 |
* Jodit.modules.Helpers.toArray(['test']) // ['test'] |
| 31055 |
* Jodit.modules.Helpers.toArray(1) // [] |
| 31056 |
* ``` |
| 31057 |
*/ const toArray = function toArray(...args) { |
| 31058 |
var _reset; |
| 31059 |
const func = (0,jodit_core_helpers_checker_is_native_function__WEBPACK_IMPORTED_MODULE_0__.isNativeFunction)(Array.from) ? Array.from : (_reset = (0,jodit_core_helpers_utils_reset__WEBPACK_IMPORTED_MODULE_1__.reset)('Array.from')) !== null && _reset !== void 0 ? _reset : Array.from; |
| 31060 |
return func.apply(Array, args); |
| 31061 |
}; |
| 31062 |
|
| 31063 |
|
| 31064 |
/***/ }), |
| 31065 |
|
| 31066 |
/***/ 88497: |
| 31067 |
/***/ (function(module) { |
| 31068 |
|
| 31069 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M1395 736q0 13-10 23l-466 466q-10 10-23 10t-23-10l-466-466q-10-10-10-23t10-23l50-50q10-10 23-10t23 10l393 393 393-393q10-10 23-10t23 10l50 50q10 10 10 23z\"/> </svg>" |
| 31070 |
|
| 31071 |
/***/ }), |
| 31072 |
|
| 31073 |
/***/ 88952: |
| 31074 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 31075 |
|
| 31076 |
"use strict"; |
| 31077 |
/* unused harmony export inlinePopup */ |
| 31078 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 31079 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 31080 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(84839); |
| 31081 |
/* harmony import */ var jodit_core_dom__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(27795); |
| 31082 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(28077); |
| 31083 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(65946); |
| 31084 |
/* harmony import */ var jodit_core_plugin__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(91206); |
| 31085 |
/* harmony import */ var jodit_core_ui__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(4099); |
| 31086 |
/* harmony import */ var jodit_core_ui_popup__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(56490); |
| 31087 |
/* harmony import */ var jodit_modules_toolbar_factory__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(4274); |
| 31088 |
/* harmony import */ var _config_config__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(89873); |
| 31089 |
/*! |
| 31090 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 31091 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 31092 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 31093 |
*/ /** |
| 31094 |
* [[include:plugins/inline-popup/README.md]] |
| 31095 |
* @packageDocumentation |
| 31096 |
* @module plugins/inline-popup |
| 31097 |
*/ |
| 31098 |
|
| 31099 |
|
| 31100 |
|
| 31101 |
|
| 31102 |
|
| 31103 |
|
| 31104 |
|
| 31105 |
|
| 31106 |
|
| 31107 |
|
| 31108 |
|
| 31109 |
/** |
| 31110 |
* Plugin for show inline popup dialog |
| 31111 |
*/ class inlinePopup extends jodit_core_plugin__WEBPACK_IMPORTED_MODULE_6__.Plugin { |
| 31112 |
get popup() { |
| 31113 |
return new jodit_core_ui_popup__WEBPACK_IMPORTED_MODULE_8__.Popup(this.jodit, false); |
| 31114 |
} |
| 31115 |
get toolbar() { |
| 31116 |
return (0,jodit_modules_toolbar_factory__WEBPACK_IMPORTED_MODULE_9__.makeCollection)(this.jodit, this.popup); |
| 31117 |
} |
| 31118 |
onClick(node) { |
| 31119 |
const elements = this.elmsList, target = jodit_core_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.isTag(node, 'img') ? node : jodit_core_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.closest(node, elements, this.j.editor); |
| 31120 |
if (target && this.canShowPopupForType(target.nodeName.toLowerCase())) { |
| 31121 |
this.showPopup(()=>(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.position)(target, this.j), target.nodeName.toLowerCase(), target); |
| 31122 |
return false; |
| 31123 |
} |
| 31124 |
} |
| 31125 |
/** |
| 31126 |
* Show inline popup with some toolbar |
| 31127 |
* |
| 31128 |
* @param type - selection, img, a etc. |
| 31129 |
*/ showPopup(rect, type, target) { |
| 31130 |
type = type.toLowerCase(); |
| 31131 |
if (!this.canShowPopupForType(type)) { |
| 31132 |
return false; |
| 31133 |
} |
| 31134 |
if (this.type !== type || target !== this.previousTarget) { |
| 31135 |
this.previousTarget = target; |
| 31136 |
const data = this.j.o.popup[type]; |
| 31137 |
let content; |
| 31138 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.isFunction)(data)) { |
| 31139 |
content = data(this.j, target, this.popup.close); |
| 31140 |
} else { |
| 31141 |
content = data; |
| 31142 |
} |
| 31143 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.isArray)(content)) { |
| 31144 |
this.toolbar.build(content, target); |
| 31145 |
this.toolbar.buttonSize = this.j.o.toolbarButtonSize; |
| 31146 |
content = this.toolbar.container; |
| 31147 |
} |
| 31148 |
this.popup.setContent(content); |
| 31149 |
this.type = type; |
| 31150 |
} |
| 31151 |
this.popup.open(rect); |
| 31152 |
return true; |
| 31153 |
} |
| 31154 |
/** |
| 31155 |
* Hide opened popup |
| 31156 |
*/ hidePopup(type) { |
| 31157 |
if (this.popup.isOpened && (!(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.isString)(type) || type === this.type)) { |
| 31158 |
this.popup.close(); |
| 31159 |
} |
| 31160 |
} |
| 31161 |
onOutsideClick() { |
| 31162 |
this.popup.close(); |
| 31163 |
} |
| 31164 |
/** |
| 31165 |
* Can show popup for this type |
| 31166 |
*/ canShowPopupForType(type) { |
| 31167 |
const data = this.j.o.popup[type.toLowerCase()]; |
| 31168 |
if (this.j.o.readonly || !this.j.o.toolbarInline || !data) { |
| 31169 |
return false; |
| 31170 |
} |
| 31171 |
return !this.isExcludedTarget(type); |
| 31172 |
} |
| 31173 |
/** |
| 31174 |
* For some elements do not show popup |
| 31175 |
*/ isExcludedTarget(type) { |
| 31176 |
return (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.splitArray)(this.j.o.toolbarInlineDisableFor).map((a)=>a.toLowerCase()).includes(type.toLowerCase()); |
| 31177 |
} |
| 31178 |
/** @override **/ afterInit(jodit) { |
| 31179 |
this.j.e.on('getDiffButtons.mobile', (toolbar)=>{ |
| 31180 |
if (this.toolbar === toolbar) { |
| 31181 |
const names = this.toolbar.getButtonsNames(); |
| 31182 |
return (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.toArray)(jodit.registeredButtons).filter((btn)=>!this.j.o.toolbarInlineDisabledButtons.includes(btn.name)).filter((item)=>{ |
| 31183 |
const name = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.isString)(item) ? item : item.name; |
| 31184 |
return name && name !== '|' && name !== '\n' && !names.includes(name); |
| 31185 |
}); |
| 31186 |
} |
| 31187 |
}).on('hidePopup', this.hidePopup).on('showInlineToolbar', this.showInlineToolbar).on('showPopup', (elm, rect, type)=>{ |
| 31188 |
this.showPopup(rect, type || ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.isString)(elm) ? elm : elm.nodeName), (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.isString)(elm) ? undefined : elm); |
| 31189 |
}).on('mousedown keydown', this.onSelectionStart).on('change', ()=>{ |
| 31190 |
if (this.popup.isOpened && this.previousTarget && !this.previousTarget.parentNode) { |
| 31191 |
this.hidePopup(); |
| 31192 |
this.previousTarget = undefined; |
| 31193 |
} |
| 31194 |
}).on([ |
| 31195 |
this.j.ew, |
| 31196 |
this.j.ow |
| 31197 |
], 'mouseup keyup', this.onSelectionEnd); |
| 31198 |
this.addListenersForElements(); |
| 31199 |
} |
| 31200 |
onSelectionStart() { |
| 31201 |
this.snapRange = this.j.s.range.cloneRange(); |
| 31202 |
} |
| 31203 |
onSelectionEnd(e) { |
| 31204 |
if (e && e.target && jodit_core_ui__WEBPACK_IMPORTED_MODULE_7__.UIElement.closestElement(e.target, jodit_core_ui_popup__WEBPACK_IMPORTED_MODULE_8__.Popup)) { |
| 31205 |
return; |
| 31206 |
} |
| 31207 |
const { snapRange } = this, { range } = this.j.s; |
| 31208 |
if (!snapRange || range.collapsed || range.startContainer !== snapRange.startContainer || range.startOffset !== snapRange.startOffset || range.endContainer !== snapRange.endContainer || range.endOffset !== snapRange.endOffset) { |
| 31209 |
this.onSelectionChange(); |
| 31210 |
} |
| 31211 |
} |
| 31212 |
/** |
| 31213 |
* Selection change handler |
| 31214 |
*/ onSelectionChange() { |
| 31215 |
if (!this.j.o.toolbarInlineForSelection) { |
| 31216 |
return; |
| 31217 |
} |
| 31218 |
const type = 'selection'; |
| 31219 |
const sel = this.j.s.sel; |
| 31220 |
const range = this.j.s.range; |
| 31221 |
if ((sel === null || sel === void 0 ? void 0 : sel.isCollapsed) || this.isSelectedTarget(range)) { |
| 31222 |
if (this.type === type && this.popup.isOpened) { |
| 31223 |
this.hidePopup(); |
| 31224 |
} |
| 31225 |
return; |
| 31226 |
} |
| 31227 |
const node = this.j.s.current(); |
| 31228 |
if (!node) { |
| 31229 |
return; |
| 31230 |
} |
| 31231 |
this.showPopup(()=>range.getBoundingClientRect(), type); |
| 31232 |
} |
| 31233 |
/** |
| 31234 |
* In not collapsed selection - only one image |
| 31235 |
*/ isSelectedTarget(r) { |
| 31236 |
const sc = r.startContainer; |
| 31237 |
return jodit_core_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.isElement(sc) && sc === r.endContainer && jodit_core_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.isTag(sc.childNodes[r.startOffset], new Set((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.keys)(this.j.o.popup, false))) && r.startOffset === r.endOffset - 1; |
| 31238 |
} |
| 31239 |
/** |
| 31240 |
* Shortcut for Table module |
| 31241 |
*/ // private get tableModule(): Table { |
| 31242 |
// return this.j.getInstance<Table>('Table', this.j.o); |
| 31243 |
// } |
| 31244 |
/** @override **/ beforeDestruct(jodit) { |
| 31245 |
jodit.e.off('showPopup').off([ |
| 31246 |
this.j.ew, |
| 31247 |
this.j.ow |
| 31248 |
], 'mouseup keyup', this.onSelectionEnd); |
| 31249 |
this.removeListenersForElements(); |
| 31250 |
} |
| 31251 |
_eventsList() { |
| 31252 |
const el = this.elmsList; |
| 31253 |
return el.map((e)=>(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.camelCase)(`click_${e}`)).concat(el.map((e)=>(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.camelCase)(`touchstart_${e}`))).join(' '); |
| 31254 |
} |
| 31255 |
addListenersForElements() { |
| 31256 |
this.j.e.on(this._eventsList(), this.onClick); |
| 31257 |
} |
| 31258 |
removeListenersForElements() { |
| 31259 |
this.j.e.off(this._eventsList(), this.onClick); |
| 31260 |
} |
| 31261 |
/** |
| 31262 |
* Show the inline WYSIWYG toolbar editor. |
| 31263 |
*/ showInlineToolbar(bound) { |
| 31264 |
this.showPopup(()=>{ |
| 31265 |
if (bound) { |
| 31266 |
return bound; |
| 31267 |
} |
| 31268 |
const { range } = this.j.s; |
| 31269 |
return range.getBoundingClientRect(); |
| 31270 |
}, 'toolbar'); |
| 31271 |
} |
| 31272 |
constructor(...args){ |
| 31273 |
super(...args), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "type", null), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "previousTarget", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "snapRange", null), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "elmsList", (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.keys)(this.j.o.popup, false).filter((s)=>!this.isExcludedTarget(s))); |
| 31274 |
} |
| 31275 |
} |
| 31276 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(inlinePopup, "requires", [ |
| 31277 |
'select' |
| 31278 |
]); |
| 31279 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 31280 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.cache |
| 31281 |
], inlinePopup.prototype, "popup", null); |
| 31282 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 31283 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.cache |
| 31284 |
], inlinePopup.prototype, "toolbar", null); |
| 31285 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 31286 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.autobind |
| 31287 |
], inlinePopup.prototype, "onClick", null); |
| 31288 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 31289 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.wait)((ctx)=>!ctx.j.isLocked) |
| 31290 |
], inlinePopup.prototype, "showPopup", null); |
| 31291 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 31292 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.watch)([ |
| 31293 |
':clickEditor', |
| 31294 |
':beforeCommandDelete', |
| 31295 |
':backSpaceAfterDelete' |
| 31296 |
]), |
| 31297 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.autobind |
| 31298 |
], inlinePopup.prototype, "hidePopup", null); |
| 31299 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 31300 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.watch)(':outsideClick') |
| 31301 |
], inlinePopup.prototype, "onOutsideClick", null); |
| 31302 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 31303 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.autobind |
| 31304 |
], inlinePopup.prototype, "onSelectionStart", null); |
| 31305 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 31306 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.autobind |
| 31307 |
], inlinePopup.prototype, "onSelectionEnd", null); |
| 31308 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 31309 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.debounce)((ctx)=>ctx.defaultTimeout) |
| 31310 |
], inlinePopup.prototype, "onSelectionChange", null); |
| 31311 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 31312 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.autobind |
| 31313 |
], inlinePopup.prototype, "showInlineToolbar", null); |
| 31314 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_4__.pluginSystem.add('inlinePopup', inlinePopup); |
| 31315 |
|
| 31316 |
|
| 31317 |
/***/ }), |
| 31318 |
|
| 31319 |
/***/ 89081: |
| 31320 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 31321 |
|
| 31322 |
"use strict"; |
| 31323 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 31324 |
/* harmony export */ unwrapChildren: function() { return /* binding */ unwrapChildren; } |
| 31325 |
/* harmony export */ }); |
| 31326 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 31327 |
/* harmony import */ var jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(93640); |
| 31328 |
/* harmony import */ var jodit_core_selection_style_api_has_same_style__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(9703); |
| 31329 |
/* harmony import */ var _is_suit_element__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(73019); |
| 31330 |
/*! |
| 31331 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 31332 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 31333 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 31334 |
*/ |
| 31335 |
|
| 31336 |
|
| 31337 |
|
| 31338 |
/** |
| 31339 |
* Unwrap all suit elements inside |
| 31340 |
* @private |
| 31341 |
*/ function unwrapChildren(style, font) { |
| 31342 |
var _style_options_attributes; |
| 31343 |
const needUnwrap = []; |
| 31344 |
const needChangeStyle = []; |
| 31345 |
let firstElementSuit; |
| 31346 |
const cssStyle = (_style_options_attributes = style.options.attributes) === null || _style_options_attributes === void 0 ? void 0 : _style_options_attributes.style; |
| 31347 |
if (font.firstChild) { |
| 31348 |
const gen = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.eachGen(font); |
| 31349 |
let item = gen.next(); |
| 31350 |
while(!item.done){ |
| 31351 |
const elm = item.value; |
| 31352 |
if ((0,_is_suit_element__WEBPACK_IMPORTED_MODULE_3__.isSuitElement)(style, elm, true) && (!cssStyle || (0,jodit_core_selection_style_api_has_same_style__WEBPACK_IMPORTED_MODULE_2__.hasSameStyleKeys)(elm, cssStyle))) { |
| 31353 |
if (firstElementSuit === undefined) { |
| 31354 |
firstElementSuit = true; |
| 31355 |
} |
| 31356 |
needUnwrap.push(elm); |
| 31357 |
} else if (cssStyle && (0,_is_suit_element__WEBPACK_IMPORTED_MODULE_3__.isSameStyleChild)(style, elm)) { |
| 31358 |
if (firstElementSuit === undefined) { |
| 31359 |
firstElementSuit = false; |
| 31360 |
} |
| 31361 |
needChangeStyle.push(()=>{ |
| 31362 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__.css)(elm, Object.keys(cssStyle).reduce((acc, key)=>{ |
| 31363 |
acc[key] = null; |
| 31364 |
return acc; |
| 31365 |
}, {})); |
| 31366 |
if (!(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__.attr)(elm, 'style')) { |
| 31367 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__.attr)(elm, 'style', null); |
| 31368 |
} |
| 31369 |
if (!(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__.attr)(elm, 'style') && elm.nodeName.toLowerCase() === style.element) { |
| 31370 |
needUnwrap.push(elm); |
| 31371 |
} |
| 31372 |
}); |
| 31373 |
} else if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isEmptyTextNode(elm)) { |
| 31374 |
if (firstElementSuit === undefined) { |
| 31375 |
firstElementSuit = false; |
| 31376 |
} |
| 31377 |
} |
| 31378 |
item = gen.next(); |
| 31379 |
} |
| 31380 |
} |
| 31381 |
needChangeStyle.forEach((clb)=>clb()); |
| 31382 |
needUnwrap.forEach(jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.unwrap); |
| 31383 |
return Boolean(firstElementSuit); |
| 31384 |
} |
| 31385 |
|
| 31386 |
|
| 31387 |
/***/ }), |
| 31388 |
|
| 31389 |
/***/ 89097: |
| 31390 |
/***/ (function(module) { |
| 31391 |
|
| 31392 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M1600 736v192q0 40-28 68t-68 28h-1216q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h1216q40 0 68 28t28 68z\"/> </svg>" |
| 31393 |
|
| 31394 |
/***/ }), |
| 31395 |
|
| 31396 |
/***/ 89308: |
| 31397 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 31398 |
|
| 31399 |
"use strict"; |
| 31400 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 31401 |
/* harmony export */ get: function() { return /* binding */ get; } |
| 31402 |
/* harmony export */ }); |
| 31403 |
/* harmony import */ var jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(85932); |
| 31404 |
/* harmony import */ var jodit_core_helpers_checker_is_void__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(18303); |
| 31405 |
/*! |
| 31406 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 31407 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 31408 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 31409 |
*/ /** |
| 31410 |
* @module helpers/utils |
| 31411 |
*/ |
| 31412 |
|
| 31413 |
/** |
| 31414 |
* Safe access in tree object |
| 31415 |
* |
| 31416 |
* @example |
| 31417 |
* ```js |
| 31418 |
* const obj = { |
| 31419 |
* a: { |
| 31420 |
* b: { |
| 31421 |
* c: { |
| 31422 |
* e: false |
| 31423 |
* } |
| 31424 |
* } |
| 31425 |
* } |
| 31426 |
* }; |
| 31427 |
* |
| 31428 |
* console.log(Jodit.modules.Helpers.get('a.b.c.d.e', obj) === false); // true |
| 31429 |
* console.log(Jodit.modules.Helpers.get('a.b.a.d.e', obj) === null); // false |
| 31430 |
* ``` |
| 31431 |
*/ function get(chain, obj) { |
| 31432 |
if (!(0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_0__.isString)(chain) || !chain.length) { |
| 31433 |
return null; |
| 31434 |
} |
| 31435 |
const parts = chain.split('.'); |
| 31436 |
let result = obj; |
| 31437 |
try { |
| 31438 |
for (const part of parts){ |
| 31439 |
if ((0,jodit_core_helpers_checker_is_void__WEBPACK_IMPORTED_MODULE_1__.isVoid)(result[part])) { |
| 31440 |
return null; |
| 31441 |
} |
| 31442 |
result = result[part]; |
| 31443 |
} |
| 31444 |
} catch (unused) { |
| 31445 |
return null; // permission denied ore another access exception |
| 31446 |
} |
| 31447 |
if ((0,jodit_core_helpers_checker_is_void__WEBPACK_IMPORTED_MODULE_1__.isVoid)(result)) { |
| 31448 |
return null; |
| 31449 |
} |
| 31450 |
return result; |
| 31451 |
} |
| 31452 |
|
| 31453 |
|
| 31454 |
/***/ }), |
| 31455 |
|
| 31456 |
/***/ 89317: |
| 31457 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 31458 |
|
| 31459 |
"use strict"; |
| 31460 |
/* harmony import */ var jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(17312); |
| 31461 |
/* harmony import */ var jodit_langs_ar__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(41324); |
| 31462 |
/* harmony import */ var jodit_langs_ar__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(jodit_langs_ar__WEBPACK_IMPORTED_MODULE_1__); |
| 31463 |
/* harmony import */ var jodit_langs_cs_cz__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(56014); |
| 31464 |
/* harmony import */ var jodit_langs_de__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(95461); |
| 31465 |
/* harmony import */ var jodit_langs_en__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(63837); |
| 31466 |
/* harmony import */ var jodit_langs_es__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(39386); |
| 31467 |
/* harmony import */ var jodit_langs_fr__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(25090); |
| 31468 |
/* harmony import */ var jodit_langs_hu__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(81321); |
| 31469 |
/* harmony import */ var jodit_langs_it__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(31927); |
| 31470 |
/* harmony import */ var jodit_langs_ja__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(21195); |
| 31471 |
/* harmony import */ var jodit_langs_keys__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(53414); |
| 31472 |
/* harmony import */ var jodit_langs_nl__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(3268); |
| 31473 |
/* harmony import */ var jodit_langs_pl__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(97834); |
| 31474 |
/* harmony import */ var jodit_langs_pt_br__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(86433); |
| 31475 |
/* harmony import */ var jodit_langs_tr__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(68368); |
| 31476 |
/* harmony import */ var jodit_langs_ua__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(57456); |
| 31477 |
/* harmony import */ var jodit_langs_zh_cn__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(25182); |
| 31478 |
/* harmony import */ var jodit_langs_zh_tw__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(44906); |
| 31479 |
/*! |
| 31480 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 31481 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 31482 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 31483 |
*/ /** |
| 31484 |
* [[include:langs/README.md]] |
| 31485 |
* @packageDocumentation |
| 31486 |
* @module langs |
| 31487 |
*/ // @ts-nocheck |
| 31488 |
|
| 31489 |
|
| 31490 |
|
| 31491 |
|
| 31492 |
|
| 31493 |
|
| 31494 |
|
| 31495 |
|
| 31496 |
|
| 31497 |
|
| 31498 |
|
| 31499 |
|
| 31500 |
|
| 31501 |
|
| 31502 |
|
| 31503 |
|
| 31504 |
|
| 31505 |
|
| 31506 |
|
| 31507 |
|
| 31508 |
|
| 31509 |
|
| 31510 |
|
| 31511 |
|
| 31512 |
|
| 31513 |
let exp = {}; |
| 31514 |
exp = { |
| 31515 |
ar: (jodit_langs_ar__WEBPACK_IMPORTED_MODULE_1___default()), |
| 31516 |
cs_cz: jodit_langs_cs_cz__WEBPACK_IMPORTED_MODULE_2__, |
| 31517 |
de: jodit_langs_de__WEBPACK_IMPORTED_MODULE_3__, |
| 31518 |
en: jodit_langs_en__WEBPACK_IMPORTED_MODULE_4__, |
| 31519 |
es: jodit_langs_es__WEBPACK_IMPORTED_MODULE_5__, |
| 31520 |
fi: (jodit_langs_ar__WEBPACK_IMPORTED_MODULE_1___default()), |
| 31521 |
fr: jodit_langs_fr__WEBPACK_IMPORTED_MODULE_6__, |
| 31522 |
he: (jodit_langs_ar__WEBPACK_IMPORTED_MODULE_1___default()), |
| 31523 |
hu: jodit_langs_hu__WEBPACK_IMPORTED_MODULE_7__, |
| 31524 |
id: (jodit_langs_ar__WEBPACK_IMPORTED_MODULE_1___default()), |
| 31525 |
it: jodit_langs_it__WEBPACK_IMPORTED_MODULE_8__, |
| 31526 |
ja: jodit_langs_ja__WEBPACK_IMPORTED_MODULE_9__, |
| 31527 |
ko: (jodit_langs_ar__WEBPACK_IMPORTED_MODULE_1___default()), |
| 31528 |
mn: (jodit_langs_ar__WEBPACK_IMPORTED_MODULE_1___default()), |
| 31529 |
nl: jodit_langs_nl__WEBPACK_IMPORTED_MODULE_11__, |
| 31530 |
no: (jodit_langs_ar__WEBPACK_IMPORTED_MODULE_1___default()), |
| 31531 |
pl: jodit_langs_pl__WEBPACK_IMPORTED_MODULE_12__, |
| 31532 |
pt_br: jodit_langs_pt_br__WEBPACK_IMPORTED_MODULE_13__, |
| 31533 |
ru: (jodit_langs_ar__WEBPACK_IMPORTED_MODULE_1___default()), |
| 31534 |
tr: jodit_langs_tr__WEBPACK_IMPORTED_MODULE_14__, |
| 31535 |
ua: jodit_langs_ua__WEBPACK_IMPORTED_MODULE_15__, |
| 31536 |
zh_cn: jodit_langs_zh_cn__WEBPACK_IMPORTED_MODULE_16__, |
| 31537 |
zh_tw: jodit_langs_zh_tw__WEBPACK_IMPORTED_MODULE_17__ |
| 31538 |
}; |
| 31539 |
/* Unpack array to hash */ const get = (value)=>value ? value.default || value : {}, hashLang = {}; |
| 31540 |
if ((0,jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_0__.isArray)(get(jodit_langs_keys__WEBPACK_IMPORTED_MODULE_10__))) { |
| 31541 |
get(jodit_langs_keys__WEBPACK_IMPORTED_MODULE_10__).forEach((key, index)=>{ |
| 31542 |
hashLang[index] = key; |
| 31543 |
}); |
| 31544 |
} |
| 31545 |
Object.keys(exp).forEach((lang)=>{ |
| 31546 |
const list = get(exp[lang]); |
| 31547 |
if ((0,jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_0__.isArray)(list)) { |
| 31548 |
exp[lang] = {}; |
| 31549 |
list.forEach((value, index)=>{ |
| 31550 |
exp[lang][hashLang[index]] = value; |
| 31551 |
}); |
| 31552 |
} else { |
| 31553 |
exp[lang] = list; |
| 31554 |
} |
| 31555 |
}); |
| 31556 |
/* harmony default export */ __webpack_exports__["default"] = (exp); |
| 31557 |
|
| 31558 |
|
| 31559 |
/***/ }), |
| 31560 |
|
| 31561 |
/***/ 89446: |
| 31562 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 31563 |
|
| 31564 |
"use strict"; |
| 31565 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 31566 |
/* harmony export */ buildData: function() { return /* binding */ buildData; } |
| 31567 |
/* harmony export */ }); |
| 31568 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(65946); |
| 31569 |
/*! |
| 31570 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 31571 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 31572 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 31573 |
*/ /** |
| 31574 |
* @module modules/uploader |
| 31575 |
*/ |
| 31576 |
function buildData(uploader, data) { |
| 31577 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_0__.isFunction)(uploader.o.buildData)) { |
| 31578 |
return uploader.o.buildData.call(uploader, data); |
| 31579 |
} |
| 31580 |
const FD = uploader.ow.FormData; |
| 31581 |
if (FD !== undefined) { |
| 31582 |
if (data instanceof FD) { |
| 31583 |
return data; |
| 31584 |
} |
| 31585 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_0__.isString)(data)) { |
| 31586 |
return data; |
| 31587 |
} |
| 31588 |
const newData = new FD(); |
| 31589 |
const dict = data; |
| 31590 |
Object.keys(dict).forEach((key)=>{ |
| 31591 |
newData.append(key, dict[key]); |
| 31592 |
}); |
| 31593 |
return newData; |
| 31594 |
} |
| 31595 |
return data; |
| 31596 |
} |
| 31597 |
|
| 31598 |
|
| 31599 |
/***/ }), |
| 31600 |
|
| 31601 |
/***/ 89636: |
| 31602 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 31603 |
|
| 31604 |
"use strict"; |
| 31605 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 31606 |
/* harmony export */ TabsWidget: function() { return /* binding */ TabsWidget; } |
| 31607 |
/* harmony export */ }); |
| 31608 |
/* harmony import */ var jodit_core_component__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(16964); |
| 31609 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(23211); |
| 31610 |
/* harmony import */ var jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(91565); |
| 31611 |
/* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(7909); |
| 31612 |
/* harmony import */ var jodit_core_ui__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(4099); |
| 31613 |
/*! |
| 31614 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 31615 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 31616 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 31617 |
*/ /** |
| 31618 |
* [[include:modules/widget/tabs/README.md]] |
| 31619 |
* @packageDocumentation |
| 31620 |
* @module modules/widget/tabs |
| 31621 |
*/ |
| 31622 |
|
| 31623 |
|
| 31624 |
|
| 31625 |
|
| 31626 |
|
| 31627 |
/** |
| 31628 |
* Build tabs system |
| 31629 |
* |
| 31630 |
* @param tabs - PlainObject where 'key' will be tab's Title and `value` is tab's content |
| 31631 |
* @param state - You can use for this param any HTML element for remembering active tab |
| 31632 |
* |
| 31633 |
* @example |
| 31634 |
* ```javascript |
| 31635 |
* const editor = Jodit.make('#editor'); |
| 31636 |
* const tabs = Jodit.modules.TabsWidget(editor, [ |
| 31637 |
* { name: 'Images', content: '<div>Images</div>' }, |
| 31638 |
* { |
| 31639 |
* name: 'Title 2', |
| 31640 |
* content: editor.c.fromHTML('<div>Some content</div>') |
| 31641 |
* }, |
| 31642 |
* { |
| 31643 |
* name: 'Color Picker', |
| 31644 |
* content: ColorPickerWidget( |
| 31645 |
* editor, |
| 31646 |
* function (color) { |
| 31647 |
* box.style.color = color; |
| 31648 |
* }, |
| 31649 |
* box.style.color |
| 31650 |
* ) |
| 31651 |
* } |
| 31652 |
* ]); |
| 31653 |
* ``` |
| 31654 |
*/ const TabsWidget = (jodit, tabs, state)=>{ |
| 31655 |
const box = jodit.c.div('jodit-tabs'); |
| 31656 |
const tabBox = jodit.c.div('jodit-tabs__wrapper'); |
| 31657 |
const buttons = jodit.c.div('jodit-tabs__buttons'); |
| 31658 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_3__.attr)(buttons, { |
| 31659 |
role: 'tablist', |
| 31660 |
'aria-orientation': 'horizontal' |
| 31661 |
}); |
| 31662 |
const nameToTab = {}; |
| 31663 |
const buttonList = []; |
| 31664 |
let firstTab = ''; |
| 31665 |
box.appendChild(buttons); |
| 31666 |
box.appendChild(tabBox); |
| 31667 |
const setActive = (tab)=>{ |
| 31668 |
if (!nameToTab[tab]) { |
| 31669 |
return; |
| 31670 |
} |
| 31671 |
buttonList.forEach((b)=>{ |
| 31672 |
b.state.activated = false; |
| 31673 |
}); |
| 31674 |
Object.values(nameToTab).forEach(({ tab })=>tab.classList.remove('jodit-tab_active')); |
| 31675 |
nameToTab[tab].button.state.activated = true; |
| 31676 |
nameToTab[tab].tab.classList.add('jodit-tab_active'); |
| 31677 |
}; |
| 31678 |
tabs.forEach(({ icon, name, content })=>{ |
| 31679 |
const tab = jodit.c.div('jodit-tab'); |
| 31680 |
(0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_3__.attr)(tab, { |
| 31681 |
role: 'tabpanel' |
| 31682 |
}); |
| 31683 |
const button = (0,jodit_core_ui__WEBPACK_IMPORTED_MODULE_4__.Button)(jodit, icon || name, name); |
| 31684 |
button.state.role = 'tab'; |
| 31685 |
// Stop lose the focus |
| 31686 |
jodit.e.on(button.container, 'pointerdown', (e)=>e.preventDefault()); |
| 31687 |
if (!firstTab) { |
| 31688 |
firstTab = name; |
| 31689 |
} |
| 31690 |
buttons.appendChild(button.container); |
| 31691 |
buttonList.push(button); |
| 31692 |
button.container.classList.add('jodit-tabs__button', 'jodit-tabs__button_columns_' + tabs.length); |
| 31693 |
if (!(0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_2__.isFunction)(content)) { |
| 31694 |
tab.appendChild(jodit_core_component__WEBPACK_IMPORTED_MODULE_0__.Component.isInstanceOf(content, jodit_core_ui__WEBPACK_IMPORTED_MODULE_4__.UIElement) ? content.container : content); |
| 31695 |
} else { |
| 31696 |
tab.appendChild(jodit.c.div('jodit-tab_empty')); |
| 31697 |
} |
| 31698 |
tabBox.appendChild(tab); |
| 31699 |
button.onAction(()=>{ |
| 31700 |
setActive(name); |
| 31701 |
if ((0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_2__.isFunction)(content) && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isElement(content)) { |
| 31702 |
content.call(jodit); |
| 31703 |
} |
| 31704 |
if (state) { |
| 31705 |
state.activeTab = name; |
| 31706 |
} |
| 31707 |
return false; |
| 31708 |
}); |
| 31709 |
nameToTab[name] = { |
| 31710 |
button, |
| 31711 |
tab |
| 31712 |
}; |
| 31713 |
}); |
| 31714 |
Object.values(nameToTab).forEach(({ button })=>{ |
| 31715 |
button.container.style.width = (100 / tabs.length).toFixed(10) + '%'; |
| 31716 |
}); |
| 31717 |
const tab = !state || !state.activeTab || !nameToTab[state.activeTab] ? firstTab : state.activeTab; |
| 31718 |
setActive(tab); |
| 31719 |
if (state) { |
| 31720 |
let activeTab = state.activeTab; |
| 31721 |
Object.defineProperty(state, 'activeTab', { |
| 31722 |
configurable: true, |
| 31723 |
enumerable: false, |
| 31724 |
get () { |
| 31725 |
return activeTab; |
| 31726 |
}, |
| 31727 |
set (value) { |
| 31728 |
activeTab = value; |
| 31729 |
setActive(value); |
| 31730 |
} |
| 31731 |
}); |
| 31732 |
} |
| 31733 |
return box; |
| 31734 |
}; |
| 31735 |
|
| 31736 |
|
| 31737 |
/***/ }), |
| 31738 |
|
| 31739 |
/***/ 89817: |
| 31740 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 31741 |
|
| 31742 |
"use strict"; |
| 31743 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 31744 |
/* harmony export */ moveNodeInsideStart: function() { return /* binding */ moveNodeInsideStart; } |
| 31745 |
/* harmony export */ }); |
| 31746 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 31747 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(23211); |
| 31748 |
/*! |
| 31749 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 31750 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 31751 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 31752 |
*/ /** |
| 31753 |
* @module selection |
| 31754 |
*/ |
| 31755 |
|
| 31756 |
/** |
| 31757 |
* Moves the fake node inside the adjacent element if it lies next to it but not inside. |
| 31758 |
* When the cursor is positioned in its place, it must be inside the element and not outside its border. |
| 31759 |
* @private |
| 31760 |
*/ function moveNodeInsideStart(j, node, start) { |
| 31761 |
let sibling = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.findSibling(node, start), anotherSibling = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.findSibling(node, !start); |
| 31762 |
while(jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isElement(sibling) && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isTag(sibling, jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INSEPARABLE_TAGS) && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isContentEditable(sibling, j.editor) && (!anotherSibling || !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.closest(node, jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isElement, j.editor))){ |
| 31763 |
if (start || !sibling.firstChild) { |
| 31764 |
sibling.appendChild(node); |
| 31765 |
} else { |
| 31766 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.before(sibling.firstChild, node); |
| 31767 |
} |
| 31768 |
sibling = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.sibling(node, start); |
| 31769 |
anotherSibling = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.sibling(node, !start); |
| 31770 |
} |
| 31771 |
} |
| 31772 |
|
| 31773 |
|
| 31774 |
/***/ }), |
| 31775 |
|
| 31776 |
/***/ 89827: |
| 31777 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 31778 |
|
| 31779 |
"use strict"; |
| 31780 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 31781 |
/* harmony export */ checkNotCollapsed: function() { return /* binding */ checkNotCollapsed; } |
| 31782 |
/* harmony export */ }); |
| 31783 |
/*! |
| 31784 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 31785 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 31786 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 31787 |
*/ /** |
| 31788 |
* @module plugins/backspace |
| 31789 |
*/ /** |
| 31790 |
* On Not collapsed selection - should only remove whole selected content |
| 31791 |
* |
| 31792 |
* @example |
| 31793 |
* ```html |
| 31794 |
* <p>first | stop</p><p>second | stop</p> |
| 31795 |
* ``` |
| 31796 |
* result |
| 31797 |
* ```html |
| 31798 |
* <p>first | stop</p> |
| 31799 |
* ``` |
| 31800 |
* @private |
| 31801 |
*/ function checkNotCollapsed(jodit) { |
| 31802 |
if (!jodit.s.isCollapsed()) { |
| 31803 |
jodit.execCommand('Delete'); |
| 31804 |
return true; |
| 31805 |
} |
| 31806 |
return false; |
| 31807 |
} |
| 31808 |
|
| 31809 |
|
| 31810 |
/***/ }), |
| 31811 |
|
| 31812 |
/***/ 89873: |
| 31813 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 31814 |
|
| 31815 |
"use strict"; |
| 31816 |
/* harmony import */ var jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(29434); |
| 31817 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(5266); |
| 31818 |
/* harmony import */ var _items_a__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(70235); |
| 31819 |
/* harmony import */ var _items_cells__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(17849); |
| 31820 |
/* harmony import */ var _items_iframe__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(466); |
| 31821 |
/* harmony import */ var _items_img__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(75711); |
| 31822 |
/* harmony import */ var _items_toolbar__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(59399); |
| 31823 |
/* harmony import */ var jodit_plugins_inline_popup_icons_addcolumn_svg__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(38681); |
| 31824 |
/* harmony import */ var jodit_plugins_inline_popup_icons_addcolumn_svg__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(jodit_plugins_inline_popup_icons_addcolumn_svg__WEBPACK_IMPORTED_MODULE_7__); |
| 31825 |
/* harmony import */ var jodit_plugins_inline_popup_icons_addrow_svg__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(64637); |
| 31826 |
/* harmony import */ var jodit_plugins_inline_popup_icons_addrow_svg__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(jodit_plugins_inline_popup_icons_addrow_svg__WEBPACK_IMPORTED_MODULE_8__); |
| 31827 |
/* harmony import */ var jodit_plugins_inline_popup_icons_merge_svg__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(94190); |
| 31828 |
/* harmony import */ var jodit_plugins_inline_popup_icons_merge_svg__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(jodit_plugins_inline_popup_icons_merge_svg__WEBPACK_IMPORTED_MODULE_9__); |
| 31829 |
/* harmony import */ var jodit_plugins_inline_popup_icons_splitg_svg__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(51957); |
| 31830 |
/* harmony import */ var jodit_plugins_inline_popup_icons_splitg_svg__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(jodit_plugins_inline_popup_icons_splitg_svg__WEBPACK_IMPORTED_MODULE_10__); |
| 31831 |
/* harmony import */ var jodit_plugins_inline_popup_icons_splitv_svg__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(71940); |
| 31832 |
/* harmony import */ var jodit_plugins_inline_popup_icons_splitv_svg__WEBPACK_IMPORTED_MODULE_11___default = /*#__PURE__*/__webpack_require__.n(jodit_plugins_inline_popup_icons_splitv_svg__WEBPACK_IMPORTED_MODULE_11__); |
| 31833 |
/* harmony import */ var jodit_plugins_inline_popup_icons_th_svg__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(43218); |
| 31834 |
/* harmony import */ var jodit_plugins_inline_popup_icons_th_svg__WEBPACK_IMPORTED_MODULE_12___default = /*#__PURE__*/__webpack_require__.n(jodit_plugins_inline_popup_icons_th_svg__WEBPACK_IMPORTED_MODULE_12__); |
| 31835 |
/* harmony import */ var jodit_plugins_inline_popup_icons_th_list_svg__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(48007); |
| 31836 |
/* harmony import */ var jodit_plugins_inline_popup_icons_th_list_svg__WEBPACK_IMPORTED_MODULE_13___default = /*#__PURE__*/__webpack_require__.n(jodit_plugins_inline_popup_icons_th_list_svg__WEBPACK_IMPORTED_MODULE_13__); |
| 31837 |
/*! |
| 31838 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 31839 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 31840 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 31841 |
*/ /** |
| 31842 |
* @module plugins/inline-popup |
| 31843 |
*/ |
| 31844 |
|
| 31845 |
|
| 31846 |
|
| 31847 |
|
| 31848 |
|
| 31849 |
|
| 31850 |
|
| 31851 |
|
| 31852 |
|
| 31853 |
|
| 31854 |
|
| 31855 |
|
| 31856 |
|
| 31857 |
jodit_config__WEBPACK_IMPORTED_MODULE_1__.Config.prototype.toolbarInline = true; |
| 31858 |
jodit_config__WEBPACK_IMPORTED_MODULE_1__.Config.prototype.toolbarInlineForSelection = false; |
| 31859 |
jodit_config__WEBPACK_IMPORTED_MODULE_1__.Config.prototype.toolbarInlineDisableFor = []; |
| 31860 |
jodit_config__WEBPACK_IMPORTED_MODULE_1__.Config.prototype.toolbarInlineDisabledButtons = [ |
| 31861 |
'source' |
| 31862 |
]; |
| 31863 |
jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_0__.Icon.set('addcolumn', (jodit_plugins_inline_popup_icons_addcolumn_svg__WEBPACK_IMPORTED_MODULE_7___default())).set('addrow', (jodit_plugins_inline_popup_icons_addrow_svg__WEBPACK_IMPORTED_MODULE_8___default())).set('merge', (jodit_plugins_inline_popup_icons_merge_svg__WEBPACK_IMPORTED_MODULE_9___default())).set('th', (jodit_plugins_inline_popup_icons_th_svg__WEBPACK_IMPORTED_MODULE_12___default())).set('splitg', (jodit_plugins_inline_popup_icons_splitg_svg__WEBPACK_IMPORTED_MODULE_10___default())).set('splitv', (jodit_plugins_inline_popup_icons_splitv_svg__WEBPACK_IMPORTED_MODULE_11___default())).set('th-list', (jodit_plugins_inline_popup_icons_th_list_svg__WEBPACK_IMPORTED_MODULE_13___default())); |
| 31864 |
jodit_config__WEBPACK_IMPORTED_MODULE_1__.Config.prototype.popup = { |
| 31865 |
a: _items_a__WEBPACK_IMPORTED_MODULE_2__["default"], |
| 31866 |
img: _items_img__WEBPACK_IMPORTED_MODULE_5__["default"], |
| 31867 |
cells: _items_cells__WEBPACK_IMPORTED_MODULE_3__["default"], |
| 31868 |
toolbar: _items_toolbar__WEBPACK_IMPORTED_MODULE_6__["default"], |
| 31869 |
jodit: _items_iframe__WEBPACK_IMPORTED_MODULE_4__["default"], |
| 31870 |
iframe: _items_iframe__WEBPACK_IMPORTED_MODULE_4__["default"], |
| 31871 |
'jodit-media': _items_iframe__WEBPACK_IMPORTED_MODULE_4__["default"], |
| 31872 |
selection: [ |
| 31873 |
'bold', |
| 31874 |
'underline', |
| 31875 |
'italic', |
| 31876 |
'ul', |
| 31877 |
'ol', |
| 31878 |
'\n', |
| 31879 |
'outdent', |
| 31880 |
'indent', |
| 31881 |
'fontsize', |
| 31882 |
'brush', |
| 31883 |
'cut', |
| 31884 |
'\n', |
| 31885 |
'paragraph', |
| 31886 |
'link', |
| 31887 |
'align', |
| 31888 |
'dots' |
| 31889 |
] |
| 31890 |
}; |
| 31891 |
|
| 31892 |
|
| 31893 |
/***/ }), |
| 31894 |
|
| 31895 |
/***/ 90826: |
| 31896 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 31897 |
|
| 31898 |
"use strict"; |
| 31899 |
/* unused harmony export image */ |
| 31900 |
/* harmony import */ var _swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(49376); |
| 31901 |
/* harmony import */ var jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(27795); |
| 31902 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(28077); |
| 31903 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(65946); |
| 31904 |
/* harmony import */ var jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(29434); |
| 31905 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(5266); |
| 31906 |
/* harmony import */ var jodit_modules_widget__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(15753); |
| 31907 |
/* harmony import */ var _image_svg__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(64831); |
| 31908 |
/* harmony import */ var _image_svg__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(_image_svg__WEBPACK_IMPORTED_MODULE_7__); |
| 31909 |
/*! |
| 31910 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 31911 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 31912 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 31913 |
*/ /** |
| 31914 |
* [[include:plugins/image/README.md]] |
| 31915 |
* @packageDocumentation |
| 31916 |
* @module plugins/image |
| 31917 |
*/ |
| 31918 |
|
| 31919 |
|
| 31920 |
|
| 31921 |
|
| 31922 |
|
| 31923 |
|
| 31924 |
|
| 31925 |
jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_4__.Icon.set('image', (_image_svg__WEBPACK_IMPORTED_MODULE_7___default())); |
| 31926 |
jodit_config__WEBPACK_IMPORTED_MODULE_5__.Config.prototype.controls.image = { |
| 31927 |
popup: (editor, current, close)=>{ |
| 31928 |
let sourceImage = null; |
| 31929 |
if (current && !jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isText(current) && jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isHTMLElement(current) && (jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isTag(current, 'img') || (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.$$)('img', current).length)) { |
| 31930 |
sourceImage = jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isTag(current, 'img') ? current : (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.$$)('img', current)[0]; |
| 31931 |
} |
| 31932 |
editor.s.save(); |
| 31933 |
return (0,jodit_modules_widget__WEBPACK_IMPORTED_MODULE_6__.FileSelectorWidget)(editor, { |
| 31934 |
filebrowser: (data)=>{ |
| 31935 |
editor.s.restore(); |
| 31936 |
data.files && data.files.forEach((file)=>editor.s.insertImage(data.baseurl + file, null, editor.o.imageDefaultWidth)); |
| 31937 |
close(); |
| 31938 |
}, |
| 31939 |
upload: true, |
| 31940 |
url: (url, text)=>(0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 31941 |
editor.s.restore(); |
| 31942 |
if (/^[a-z\d_-]+(\.[a-z\d_-]+)+/i.test(url)) { |
| 31943 |
url = '//' + url; |
| 31944 |
} |
| 31945 |
const image = sourceImage || editor.createInside.element('img'); |
| 31946 |
image.setAttribute('src', url); |
| 31947 |
image.setAttribute('alt', text); |
| 31948 |
if (!sourceImage) { |
| 31949 |
yield editor.s.insertImage(image, null, editor.o.imageDefaultWidth); |
| 31950 |
} |
| 31951 |
close(); |
| 31952 |
})() |
| 31953 |
}, sourceImage, close); |
| 31954 |
}, |
| 31955 |
tags: [ |
| 31956 |
'img' |
| 31957 |
], |
| 31958 |
tooltip: 'Insert Image' |
| 31959 |
}; |
| 31960 |
function image(editor) { |
| 31961 |
editor.registerButton({ |
| 31962 |
name: 'image', |
| 31963 |
group: 'media' |
| 31964 |
}); |
| 31965 |
} |
| 31966 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_2__.pluginSystem.add('image', image); |
| 31967 |
|
| 31968 |
|
| 31969 |
/***/ }), |
| 31970 |
|
| 31971 |
/***/ 90886: |
| 31972 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 31973 |
|
| 31974 |
"use strict"; |
| 31975 |
/* unused harmony export imageProperties */ |
| 31976 |
/* harmony import */ var _swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(49376); |
| 31977 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(25045); |
| 31978 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(31635); |
| 31979 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(84839); |
| 31980 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(23211); |
| 31981 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(28077); |
| 31982 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(65946); |
| 31983 |
/* harmony import */ var jodit_core_plugin_plugin__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(18855); |
| 31984 |
/* harmony import */ var jodit_core_ui_button__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(59400); |
| 31985 |
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(34689); |
| 31986 |
/* harmony import */ var _ui_ui_image_form__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(27137); |
| 31987 |
/* harmony import */ var _utils_open_image_editor__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(28771); |
| 31988 |
/* harmony import */ var _utils_open_image_popup__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(670); |
| 31989 |
/* harmony import */ var _readers__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(47744); |
| 31990 |
/* harmony import */ var _writers__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(71552); |
| 31991 |
/*! |
| 31992 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 31993 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 31994 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 31995 |
*/ /** |
| 31996 |
* [[include:plugins/image-properties/README.md]] |
| 31997 |
* @packageDocumentation |
| 31998 |
* @module plugins/image-properties |
| 31999 |
*/ |
| 32000 |
|
| 32001 |
|
| 32002 |
|
| 32003 |
|
| 32004 |
|
| 32005 |
|
| 32006 |
|
| 32007 |
|
| 32008 |
|
| 32009 |
|
| 32010 |
|
| 32011 |
|
| 32012 |
|
| 32013 |
|
| 32014 |
/** |
| 32015 |
* Plug-in for image editing window |
| 32016 |
* |
| 32017 |
* @example |
| 32018 |
* ```javascript |
| 32019 |
* const editor = Jodit.make('#editor', { |
| 32020 |
* image: { |
| 32021 |
* editSrc: false, |
| 32022 |
* editLink: false |
| 32023 |
* } |
| 32024 |
* }); |
| 32025 |
* ``` |
| 32026 |
*/ /** |
| 32027 |
* Show dialog with image's options |
| 32028 |
*/ class imageProperties extends jodit_core_plugin_plugin__WEBPACK_IMPORTED_MODULE_7__.Plugin { |
| 32029 |
get form() { |
| 32030 |
return new _ui_ui_image_form__WEBPACK_IMPORTED_MODULE_10__.UIImagePropertiesForm(this.j, this.state, this.activeTabState, { |
| 32031 |
openImageEditor: ()=>(0,_utils_open_image_editor__WEBPACK_IMPORTED_MODULE_11__.openImageEditorDialog)(this.j, this.state), |
| 32032 |
openImagePopup: (target)=>(0,_utils_open_image_popup__WEBPACK_IMPORTED_MODULE_12__.openImagePopup)(this.j, this.dialog, this.state, target) |
| 32033 |
}); |
| 32034 |
} |
| 32035 |
/** |
| 32036 |
* Dialog for form |
| 32037 |
*/ get dialog() { |
| 32038 |
const { j } = this; |
| 32039 |
const dialog = j.dlg({ |
| 32040 |
minWidth: Math.min(400, screen.width), |
| 32041 |
minHeight: 590, |
| 32042 |
buttons: [ |
| 32043 |
'fullsize', |
| 32044 |
'dialog.close' |
| 32045 |
] |
| 32046 |
}); |
| 32047 |
const buttons = this.__buttons; |
| 32048 |
buttons.check.onAction(()=>{ |
| 32049 |
(0,_writers__WEBPACK_IMPORTED_MODULE_14__.applyValuesToImage)(j, this.state, this.state.sourceImage); |
| 32050 |
j.synchronizeValues(); |
| 32051 |
dialog.close(); |
| 32052 |
}); |
| 32053 |
buttons.remove.onAction(()=>{ |
| 32054 |
j.s.removeNode(this.state.sourceImage); |
| 32055 |
dialog.close(); |
| 32056 |
}); |
| 32057 |
buttons.cancel.onAction(()=>{ |
| 32058 |
dialog.close(); |
| 32059 |
}); |
| 32060 |
dialog.setHeader(j.i18n('Image properties')); |
| 32061 |
dialog.setContent(this.form); |
| 32062 |
dialog.setFooter([ |
| 32063 |
[ |
| 32064 |
buttons.cancel, |
| 32065 |
buttons.remove |
| 32066 |
], |
| 32067 |
buttons.check |
| 32068 |
]); |
| 32069 |
j.e.on(dialog, 'afterClose', ()=>{ |
| 32070 |
if (this.state.image.parentNode && j.o.image.selectImageAfterClose) { |
| 32071 |
j.s.select(this.state.sourceImage); |
| 32072 |
} |
| 32073 |
}); |
| 32074 |
dialog.setSize(j.o.image.dialogWidth); |
| 32075 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.markOwner)(j, dialog.container); |
| 32076 |
return dialog; |
| 32077 |
} |
| 32078 |
get __buttons() { |
| 32079 |
const { j } = this; |
| 32080 |
return { |
| 32081 |
check: (0,jodit_core_ui_button__WEBPACK_IMPORTED_MODULE_8__.Button)(j, 'ok', 'Apply', 'primary'), |
| 32082 |
remove: (0,jodit_core_ui_button__WEBPACK_IMPORTED_MODULE_8__.Button)(j, 'bin', 'Delete'), |
| 32083 |
cancel: (0,jodit_core_ui_button__WEBPACK_IMPORTED_MODULE_8__.Button)(j, 'cancel', 'Cancel') |
| 32084 |
}; |
| 32085 |
} |
| 32086 |
/** |
| 32087 |
* Open dialog editing image properties |
| 32088 |
* |
| 32089 |
* @example |
| 32090 |
* ```javascript |
| 32091 |
* const editor = Jodit.makeJodit('#editor'); |
| 32092 |
* img = editor.createInside.element('img'); |
| 32093 |
* |
| 32094 |
* img.setAttribute('src', 'images/some-image.png'); |
| 32095 |
* editor.s.insertImage(img); |
| 32096 |
* // open the properties of the editing window |
| 32097 |
* editor.events.fire('openImageProperties', img); |
| 32098 |
* ``` |
| 32099 |
*/ open() { |
| 32100 |
this.activeTabState.activeTab = 'Image'; |
| 32101 |
this.__lock(); |
| 32102 |
this.dialog.open().setModal(true).setPosition(); |
| 32103 |
this.async.promise((resolve, reject)=>(0,_readers__WEBPACK_IMPORTED_MODULE_13__.readValuesFromImage)(this.j, this.state).then(resolve, reject)).catch((e)=>{ |
| 32104 |
if (!(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.isAbortError)(e)) { |
| 32105 |
this.dialog.message.error(e.message); |
| 32106 |
} |
| 32107 |
}).finally(()=>this.__unlock()); |
| 32108 |
return false; |
| 32109 |
} |
| 32110 |
__lock() { |
| 32111 |
this.dialog.lock(); |
| 32112 |
this.form.setMod('lock', true); |
| 32113 |
Object.values(this.__buttons).forEach((b)=>b.state.disabled = true); |
| 32114 |
} |
| 32115 |
__unlock() { |
| 32116 |
this.dialog.unlock(); |
| 32117 |
this.form.setMod('lock', false); |
| 32118 |
Object.values(this.__buttons).forEach((b)=>b.state.disabled = false); |
| 32119 |
} |
| 32120 |
/** @override **/ afterInit(editor) { |
| 32121 |
const self = this; |
| 32122 |
editor.e.on('afterConstructor changePlace', ()=>{ |
| 32123 |
editor.e.off(editor.editor, '.imageproperties').on(editor.editor, 'dblclick.imageproperties', (e)=>{ |
| 32124 |
const image = e.target; |
| 32125 |
if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isTag(image, 'img')) { |
| 32126 |
return; |
| 32127 |
} |
| 32128 |
if (editor.o.image.openOnDblClick) { |
| 32129 |
if (this.j.e.fire('openOnDblClick', image) === false) { |
| 32130 |
return; |
| 32131 |
} |
| 32132 |
self.state.sourceImage = image; |
| 32133 |
self.state.image = image.cloneNode(true); |
| 32134 |
if (!editor.o.readonly) { |
| 32135 |
e.stopImmediatePropagation(); |
| 32136 |
e.preventDefault(); |
| 32137 |
self.open(); |
| 32138 |
} |
| 32139 |
} else { |
| 32140 |
e.stopImmediatePropagation(); |
| 32141 |
editor.s.select(image); |
| 32142 |
} |
| 32143 |
}); |
| 32144 |
}).on('openImageProperties.imageproperties', (image)=>{ |
| 32145 |
self.state.sourceImage = image; |
| 32146 |
this.state.image = image.cloneNode(true); |
| 32147 |
this.open(); |
| 32148 |
}); |
| 32149 |
} |
| 32150 |
onStateValuesImageSrcChange() { |
| 32151 |
return (0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 32152 |
const { image, values } = this.state; |
| 32153 |
if (!image.src) { |
| 32154 |
return; |
| 32155 |
} |
| 32156 |
try { |
| 32157 |
this.__lock(); |
| 32158 |
try { |
| 32159 |
yield image.decode(); |
| 32160 |
} catch (e) { |
| 32161 |
console.error(e); |
| 32162 |
} |
| 32163 |
if (this.state.sizeIsLocked && (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_6__.isNumeric)(values.imageWidth)) { |
| 32164 |
const w = parseFloat(values.imageWidth.toString()); |
| 32165 |
values.imageHeight = Math.round(w / this.state.ratio); |
| 32166 |
} |
| 32167 |
this.j.e.fire('updateImageProperties.imageproperties', image); |
| 32168 |
} catch (e) { |
| 32169 |
this.j.alert(e.message); |
| 32170 |
} finally{ |
| 32171 |
this.__unlock(); |
| 32172 |
} |
| 32173 |
}).call(this); |
| 32174 |
} |
| 32175 |
/** @override */ beforeDestruct(editor) { |
| 32176 |
var _cached; |
| 32177 |
var _cached1, _cached2; |
| 32178 |
Object.values((_cached = (0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.cached)(this, '__buttons')) !== null && _cached !== void 0 ? _cached : {}).forEach((b)=>b.destruct()); |
| 32179 |
(_cached1 = (0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.cached)(this, 'dialog')) === null || _cached1 === void 0 ? void 0 : _cached1.destruct(); |
| 32180 |
(_cached2 = (0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.cached)(this, 'form')) === null || _cached2 === void 0 ? void 0 : _cached2.destruct(); |
| 32181 |
editor.e.off(editor.editor, '.imageproperties').off('.imageproperties'); |
| 32182 |
} |
| 32183 |
constructor(...args){ |
| 32184 |
super(...args), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(this, "state", { |
| 32185 |
image: new Image(), |
| 32186 |
sourceImage: new Image(), |
| 32187 |
get ratio () { |
| 32188 |
const { naturalWidth, naturalHeight } = this.image; |
| 32189 |
return naturalWidth / naturalHeight || 1; |
| 32190 |
}, |
| 32191 |
sizeIsLocked: true, |
| 32192 |
marginIsLocked: true, |
| 32193 |
values: { |
| 32194 |
style: '', |
| 32195 |
imageSrc: '', |
| 32196 |
borderRadius: 0, |
| 32197 |
imageTitle: '', |
| 32198 |
imageAlt: '', |
| 32199 |
imageLink: '', |
| 32200 |
imageLinkOpenInNewTab: false, |
| 32201 |
imageWidth: 0, |
| 32202 |
imageHeight: 0, |
| 32203 |
marginTop: 0, |
| 32204 |
marginRight: 0, |
| 32205 |
marginBottom: 0, |
| 32206 |
marginLeft: 0, |
| 32207 |
classes: '', |
| 32208 |
id: '', |
| 32209 |
align: '' |
| 32210 |
} |
| 32211 |
}), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(this, "activeTabState", { |
| 32212 |
activeTab: 'Image' |
| 32213 |
}); |
| 32214 |
} |
| 32215 |
} |
| 32216 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 32217 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.cache |
| 32218 |
], imageProperties.prototype, "form", null); |
| 32219 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 32220 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.cache |
| 32221 |
], imageProperties.prototype, "dialog", null); |
| 32222 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 32223 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.cache |
| 32224 |
], imageProperties.prototype, "__buttons", null); |
| 32225 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_2__.__decorate)([ |
| 32226 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.watch)('state.image') |
| 32227 |
], imageProperties.prototype, "onStateValuesImageSrcChange", null); |
| 32228 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_5__.pluginSystem.add('imageProperties', imageProperties); |
| 32229 |
|
| 32230 |
|
| 32231 |
/***/ }), |
| 32232 |
|
| 32233 |
/***/ 91017: |
| 32234 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 32235 |
|
| 32236 |
"use strict"; |
| 32237 |
__webpack_require__.r(__webpack_exports__); |
| 32238 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 32239 |
/* harmony export */ ar: function() { return /* reexport module object */ _ar_js__WEBPACK_IMPORTED_MODULE_0__; }, |
| 32240 |
/* harmony export */ cs_cz: function() { return /* reexport module object */ _cs_cz_js__WEBPACK_IMPORTED_MODULE_1__; }, |
| 32241 |
/* harmony export */ de: function() { return /* reexport module object */ _de_js__WEBPACK_IMPORTED_MODULE_2__; }, |
| 32242 |
/* harmony export */ es: function() { return /* reexport module object */ _es_js__WEBPACK_IMPORTED_MODULE_3__; }, |
| 32243 |
/* harmony export */ fa: function() { return /* reexport module object */ _ar_js__WEBPACK_IMPORTED_MODULE_0__; }, |
| 32244 |
/* harmony export */ fi: function() { return /* reexport module object */ _ar_js__WEBPACK_IMPORTED_MODULE_0__; }, |
| 32245 |
/* harmony export */ fr: function() { return /* reexport module object */ _fr_js__WEBPACK_IMPORTED_MODULE_4__; }, |
| 32246 |
/* harmony export */ he: function() { return /* reexport module object */ _ar_js__WEBPACK_IMPORTED_MODULE_0__; }, |
| 32247 |
/* harmony export */ hu: function() { return /* reexport module object */ _hu_js__WEBPACK_IMPORTED_MODULE_5__; }, |
| 32248 |
/* harmony export */ id: function() { return /* reexport module object */ _ar_js__WEBPACK_IMPORTED_MODULE_0__; }, |
| 32249 |
/* harmony export */ it: function() { return /* reexport module object */ _it_js__WEBPACK_IMPORTED_MODULE_6__; }, |
| 32250 |
/* harmony export */ ja: function() { return /* reexport module object */ _ja_js__WEBPACK_IMPORTED_MODULE_7__; }, |
| 32251 |
/* harmony export */ ko: function() { return /* reexport module object */ _ar_js__WEBPACK_IMPORTED_MODULE_0__; }, |
| 32252 |
/* harmony export */ mn: function() { return /* reexport module object */ _ar_js__WEBPACK_IMPORTED_MODULE_0__; }, |
| 32253 |
/* harmony export */ nl: function() { return /* reexport module object */ _nl_js__WEBPACK_IMPORTED_MODULE_8__; }, |
| 32254 |
/* harmony export */ pl: function() { return /* reexport module object */ _pl_js__WEBPACK_IMPORTED_MODULE_9__; }, |
| 32255 |
/* harmony export */ pt_br: function() { return /* reexport module object */ _pt_br_js__WEBPACK_IMPORTED_MODULE_10__; }, |
| 32256 |
/* harmony export */ ru: function() { return /* reexport module object */ _ar_js__WEBPACK_IMPORTED_MODULE_0__; }, |
| 32257 |
/* harmony export */ tr: function() { return /* reexport module object */ _tr_js__WEBPACK_IMPORTED_MODULE_11__; }, |
| 32258 |
/* harmony export */ ua: function() { return /* reexport module object */ _ua_js__WEBPACK_IMPORTED_MODULE_12__; }, |
| 32259 |
/* harmony export */ zh_cn: function() { return /* reexport module object */ _zh_cn_js__WEBPACK_IMPORTED_MODULE_13__; }, |
| 32260 |
/* harmony export */ zh_tw: function() { return /* reexport module object */ _zh_tw_js__WEBPACK_IMPORTED_MODULE_14__; } |
| 32261 |
/* harmony export */ }); |
| 32262 |
/* harmony import */ var _ar_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(41324); |
| 32263 |
/* harmony import */ var _ar_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_ar_js__WEBPACK_IMPORTED_MODULE_0__); |
| 32264 |
/* harmony import */ var _cs_cz_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(33433); |
| 32265 |
/* harmony import */ var _cs_cz_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_cs_cz_js__WEBPACK_IMPORTED_MODULE_1__); |
| 32266 |
/* harmony import */ var _de_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(59488); |
| 32267 |
/* harmony import */ var _de_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_de_js__WEBPACK_IMPORTED_MODULE_2__); |
| 32268 |
/* harmony import */ var _es_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(14099); |
| 32269 |
/* harmony import */ var _es_js__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_es_js__WEBPACK_IMPORTED_MODULE_3__); |
| 32270 |
/* harmony import */ var _fr_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(54055); |
| 32271 |
/* harmony import */ var _fr_js__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_fr_js__WEBPACK_IMPORTED_MODULE_4__); |
| 32272 |
/* harmony import */ var _hu_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(42412); |
| 32273 |
/* harmony import */ var _hu_js__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_hu_js__WEBPACK_IMPORTED_MODULE_5__); |
| 32274 |
/* harmony import */ var _it_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(68294); |
| 32275 |
/* harmony import */ var _it_js__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(_it_js__WEBPACK_IMPORTED_MODULE_6__); |
| 32276 |
/* harmony import */ var _ja_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(3294); |
| 32277 |
/* harmony import */ var _ja_js__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(_ja_js__WEBPACK_IMPORTED_MODULE_7__); |
| 32278 |
/* harmony import */ var _nl_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(87141); |
| 32279 |
/* harmony import */ var _nl_js__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(_nl_js__WEBPACK_IMPORTED_MODULE_8__); |
| 32280 |
/* harmony import */ var _pl_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(10099); |
| 32281 |
/* harmony import */ var _pl_js__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(_pl_js__WEBPACK_IMPORTED_MODULE_9__); |
| 32282 |
/* harmony import */ var _pt_br_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(442); |
| 32283 |
/* harmony import */ var _pt_br_js__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(_pt_br_js__WEBPACK_IMPORTED_MODULE_10__); |
| 32284 |
/* harmony import */ var _tr_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(86581); |
| 32285 |
/* harmony import */ var _tr_js__WEBPACK_IMPORTED_MODULE_11___default = /*#__PURE__*/__webpack_require__.n(_tr_js__WEBPACK_IMPORTED_MODULE_11__); |
| 32286 |
/* harmony import */ var _ua_js__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(97493); |
| 32287 |
/* harmony import */ var _ua_js__WEBPACK_IMPORTED_MODULE_12___default = /*#__PURE__*/__webpack_require__.n(_ua_js__WEBPACK_IMPORTED_MODULE_12__); |
| 32288 |
/* harmony import */ var _zh_cn_js__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(58585); |
| 32289 |
/* harmony import */ var _zh_cn_js__WEBPACK_IMPORTED_MODULE_13___default = /*#__PURE__*/__webpack_require__.n(_zh_cn_js__WEBPACK_IMPORTED_MODULE_13__); |
| 32290 |
/* harmony import */ var _zh_tw_js__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(57629); |
| 32291 |
/* harmony import */ var _zh_tw_js__WEBPACK_IMPORTED_MODULE_14___default = /*#__PURE__*/__webpack_require__.n(_zh_tw_js__WEBPACK_IMPORTED_MODULE_14__); |
| 32292 |
/*! |
| 32293 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 32294 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 32295 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 32296 |
*/ |
| 32297 |
|
| 32298 |
|
| 32299 |
|
| 32300 |
|
| 32301 |
|
| 32302 |
|
| 32303 |
|
| 32304 |
|
| 32305 |
|
| 32306 |
|
| 32307 |
|
| 32308 |
|
| 32309 |
|
| 32310 |
|
| 32311 |
|
| 32312 |
|
| 32313 |
|
| 32314 |
|
| 32315 |
|
| 32316 |
|
| 32317 |
|
| 32318 |
|
| 32319 |
|
| 32320 |
|
| 32321 |
/***/ }), |
| 32322 |
|
| 32323 |
/***/ 91162: |
| 32324 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 32325 |
|
| 32326 |
"use strict"; |
| 32327 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 32328 |
/* harmony export */ IndexedDBProvider: function() { return /* binding */ IndexedDBProvider; }, |
| 32329 |
/* harmony export */ canUseIndexedDB: function() { return /* binding */ canUseIndexedDB; }, |
| 32330 |
/* harmony export */ clearUseIndexedDBCache: function() { return /* binding */ clearUseIndexedDBCache; } |
| 32331 |
/* harmony export */ }); |
| 32332 |
/* harmony import */ var _swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(49376); |
| 32333 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(25045); |
| 32334 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(81937); |
| 32335 |
/*! |
| 32336 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 32337 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 32338 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 32339 |
*/ /** |
| 32340 |
* @module storage |
| 32341 |
*/ |
| 32342 |
|
| 32343 |
|
| 32344 |
/** |
| 32345 |
* Persistent storage using IndexedDB |
| 32346 |
*/ class IndexedDBProvider { |
| 32347 |
/** |
| 32348 |
* Initialize or get the database connection |
| 32349 |
*/ getDB() { |
| 32350 |
if (this.dbPromise) { |
| 32351 |
return this.dbPromise; |
| 32352 |
} |
| 32353 |
this.dbPromise = new Promise((resolve, reject)=>{ |
| 32354 |
const request = indexedDB.open(this.dbName, this.DB_VERSION); |
| 32355 |
request.onerror = ()=>{ |
| 32356 |
reject(request.error); |
| 32357 |
}; |
| 32358 |
request.onsuccess = ()=>{ |
| 32359 |
resolve(request.result); |
| 32360 |
}; |
| 32361 |
request.onupgradeneeded = (event)=>{ |
| 32362 |
const db = event.target.result; |
| 32363 |
if (!db.objectStoreNames.contains(this.storeName)) { |
| 32364 |
db.createObjectStore(this.storeName); |
| 32365 |
} |
| 32366 |
}; |
| 32367 |
}); |
| 32368 |
return this.dbPromise; |
| 32369 |
} |
| 32370 |
/** |
| 32371 |
* Perform a transaction on the store |
| 32372 |
*/ performTransaction(mode, callback) { |
| 32373 |
return (0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 32374 |
try { |
| 32375 |
const db = yield this.getDB(); |
| 32376 |
const transaction = db.transaction([ |
| 32377 |
this.storeName |
| 32378 |
], mode); |
| 32379 |
const store = transaction.objectStore(this.storeName); |
| 32380 |
const request = callback(store); |
| 32381 |
return new Promise((resolve, reject)=>{ |
| 32382 |
request.onsuccess = ()=>{ |
| 32383 |
resolve(request.result); |
| 32384 |
}; |
| 32385 |
request.onerror = ()=>{ |
| 32386 |
reject(request.error); |
| 32387 |
}; |
| 32388 |
}); |
| 32389 |
} catch (error) { |
| 32390 |
return Promise.reject(error); |
| 32391 |
} |
| 32392 |
}).call(this); |
| 32393 |
} |
| 32394 |
set(key, value) { |
| 32395 |
return (0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 32396 |
try { |
| 32397 |
yield this.performTransaction('readwrite', (store)=>store.put(value, key)); |
| 32398 |
} catch (e) { |
| 32399 |
if (!jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.IS_PROD) { |
| 32400 |
console.error(e); |
| 32401 |
} |
| 32402 |
} |
| 32403 |
return this; |
| 32404 |
}).call(this); |
| 32405 |
} |
| 32406 |
delete(key) { |
| 32407 |
return (0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 32408 |
try { |
| 32409 |
yield this.performTransaction('readwrite', (store)=>store.delete(key)); |
| 32410 |
} catch (unused) {} |
| 32411 |
return this; |
| 32412 |
}).call(this); |
| 32413 |
} |
| 32414 |
get(key) { |
| 32415 |
return (0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 32416 |
try { |
| 32417 |
return yield this.performTransaction('readonly', (store)=>store.get(key)); |
| 32418 |
} catch (unused) { |
| 32419 |
return undefined; |
| 32420 |
} |
| 32421 |
}).call(this); |
| 32422 |
} |
| 32423 |
exists(key) { |
| 32424 |
return (0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 32425 |
try { |
| 32426 |
const result = yield this.performTransaction('readonly', (store)=>store.get(key)); |
| 32427 |
return result !== undefined; |
| 32428 |
} catch (unused) { |
| 32429 |
return false; |
| 32430 |
} |
| 32431 |
}).call(this); |
| 32432 |
} |
| 32433 |
clear() { |
| 32434 |
return (0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 32435 |
try { |
| 32436 |
yield this.performTransaction('readwrite', (store)=>store.clear()); |
| 32437 |
} catch (unused) {} |
| 32438 |
return this; |
| 32439 |
}).call(this); |
| 32440 |
} |
| 32441 |
/** |
| 32442 |
* Close the database connection |
| 32443 |
*/ close() { |
| 32444 |
return (0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 32445 |
if (this.dbPromise) { |
| 32446 |
try { |
| 32447 |
const db = yield this.dbPromise; |
| 32448 |
db.close(); |
| 32449 |
} catch (unused) {} |
| 32450 |
this.dbPromise = null; |
| 32451 |
} |
| 32452 |
}).call(this); |
| 32453 |
} |
| 32454 |
/** |
| 32455 |
* Get all keys in the store |
| 32456 |
*/ keys() { |
| 32457 |
return (0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 32458 |
try { |
| 32459 |
let result = yield this.performTransaction('readonly', (store)=>store.getAllKeys()); |
| 32460 |
// Handle case where result might be a promise |
| 32461 |
if (result && typeof result === 'object' && 'then' in result) { |
| 32462 |
result = yield result; |
| 32463 |
} |
| 32464 |
return result.map((k)=>String(k)); |
| 32465 |
} catch (unused) { |
| 32466 |
return []; |
| 32467 |
} |
| 32468 |
}).call(this); |
| 32469 |
} |
| 32470 |
/** |
| 32471 |
* Get all values in the store |
| 32472 |
*/ values() { |
| 32473 |
return (0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 32474 |
try { |
| 32475 |
let result = yield this.performTransaction('readonly', (store)=>store.getAll()); |
| 32476 |
// Handle case where result might be a promise |
| 32477 |
if (result && typeof result === 'object' && 'then' in result) { |
| 32478 |
result = yield result; |
| 32479 |
} |
| 32480 |
return result; |
| 32481 |
} catch (unused) { |
| 32482 |
return []; |
| 32483 |
} |
| 32484 |
}).call(this); |
| 32485 |
} |
| 32486 |
/** |
| 32487 |
* Get all entries (key-value pairs) in the store |
| 32488 |
*/ entries() { |
| 32489 |
return (0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 32490 |
try { |
| 32491 |
const [keys, values] = yield Promise.all([ |
| 32492 |
this.keys(), |
| 32493 |
this.values() |
| 32494 |
]); |
| 32495 |
return keys.map((key, index)=>[ |
| 32496 |
key, |
| 32497 |
values[index] |
| 32498 |
]); |
| 32499 |
} catch (unused) { |
| 32500 |
return []; |
| 32501 |
} |
| 32502 |
}).call(this); |
| 32503 |
} |
| 32504 |
constructor(dbName = 'JoditDB', storeName = 'keyValueStore'){ |
| 32505 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(this, "dbName", void 0); |
| 32506 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(this, "dbPromise", void 0); |
| 32507 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(this, "DB_VERSION", void 0); |
| 32508 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(this, "storeName", void 0); |
| 32509 |
this.dbName = dbName; |
| 32510 |
this.dbPromise = null; |
| 32511 |
this.DB_VERSION = 1; |
| 32512 |
this.storeName = storeName; |
| 32513 |
} |
| 32514 |
} |
| 32515 |
let cachedResult = null; |
| 32516 |
function clearUseIndexedDBCache() { |
| 32517 |
cachedResult = null; |
| 32518 |
} |
| 32519 |
/** |
| 32520 |
* Check if IndexedDB is available |
| 32521 |
*/ function canUseIndexedDB() { |
| 32522 |
return (0,_swc_helpers_async_to_generator__WEBPACK_IMPORTED_MODULE_0__._)(function*() { |
| 32523 |
if (cachedResult != null) { |
| 32524 |
return cachedResult; |
| 32525 |
} |
| 32526 |
try { |
| 32527 |
if (typeof indexedDB === 'undefined') { |
| 32528 |
cachedResult = false; |
| 32529 |
return false; |
| 32530 |
} |
| 32531 |
const tmpKey = '___Jodit___' + Math.random().toString(); |
| 32532 |
const request = indexedDB.open(tmpKey); |
| 32533 |
cachedResult = yield new Promise((resolve)=>{ |
| 32534 |
request.onerror = ()=>{ |
| 32535 |
resolve(false); |
| 32536 |
}; |
| 32537 |
request.onsuccess = ()=>{ |
| 32538 |
indexedDB.deleteDatabase(tmpKey); |
| 32539 |
resolve(true); |
| 32540 |
}; |
| 32541 |
}); |
| 32542 |
return cachedResult; |
| 32543 |
} catch (unused) { |
| 32544 |
cachedResult = false; |
| 32545 |
return false; |
| 32546 |
} |
| 32547 |
})(); |
| 32548 |
} |
| 32549 |
|
| 32550 |
|
| 32551 |
/***/ }), |
| 32552 |
|
| 32553 |
/***/ 91206: |
| 32554 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 32555 |
|
| 32556 |
"use strict"; |
| 32557 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 32558 |
/* harmony export */ Plugin: function() { return /* reexport safe */ _plugin__WEBPACK_IMPORTED_MODULE_0__.Plugin; } |
| 32559 |
/* harmony export */ }); |
| 32560 |
/* harmony import */ var _plugin__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(18855); |
| 32561 |
/* harmony import */ var _plugin_system__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(85305); |
| 32562 |
/*! |
| 32563 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 32564 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 32565 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 32566 |
*/ /** |
| 32567 |
* @module plugin |
| 32568 |
*/ |
| 32569 |
|
| 32570 |
|
| 32571 |
|
| 32572 |
/***/ }), |
| 32573 |
|
| 32574 |
/***/ 91231: |
| 32575 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 32576 |
|
| 32577 |
"use strict"; |
| 32578 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 32579 |
/* harmony export */ Async: function() { return /* reexport safe */ _async__WEBPACK_IMPORTED_MODULE_0__.Async; } |
| 32580 |
/* harmony export */ }); |
| 32581 |
/* harmony import */ var _async__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(24735); |
| 32582 |
/*! |
| 32583 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 32584 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 32585 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 32586 |
*/ /** |
| 32587 |
* @module async |
| 32588 |
*/ |
| 32589 |
|
| 32590 |
|
| 32591 |
/***/ }), |
| 32592 |
|
| 32593 |
/***/ 91321: |
| 32594 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 32595 |
|
| 32596 |
"use strict"; |
| 32597 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 32598 |
/* harmony export */ completeUrl: function() { return /* binding */ completeUrl; } |
| 32599 |
/* harmony export */ }); |
| 32600 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 32601 |
/*! |
| 32602 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 32603 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 32604 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 32605 |
*/ /** |
| 32606 |
* @module helpers/utils |
| 32607 |
*/ |
| 32608 |
const completeUrl = (url)=>{ |
| 32609 |
if (jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.globalWindow.location.protocol === 'file:' && /^\/\//.test(url)) { |
| 32610 |
url = 'https:' + url; |
| 32611 |
} |
| 32612 |
return url; |
| 32613 |
}; |
| 32614 |
|
| 32615 |
|
| 32616 |
/***/ }), |
| 32617 |
|
| 32618 |
/***/ 91535: |
| 32619 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 32620 |
|
| 32621 |
"use strict"; |
| 32622 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 32623 |
/* harmony export */ Alert: function() { return /* binding */ Alert; } |
| 32624 |
/* harmony export */ }); |
| 32625 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 32626 |
/* harmony import */ var jodit_core_helpers_array_as_array__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(78982); |
| 32627 |
/* harmony import */ var jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(91565); |
| 32628 |
/* harmony import */ var jodit_core_ui_button_button_button__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(53681); |
| 32629 |
/* harmony import */ var _dialog__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(76841); |
| 32630 |
/*! |
| 32631 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 32632 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 32633 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 32634 |
*/ /** |
| 32635 |
* @module modules/dialog |
| 32636 |
*/ |
| 32637 |
|
| 32638 |
|
| 32639 |
|
| 32640 |
|
| 32641 |
/** |
| 32642 |
* Show `alert` dialog. Work without Jodit object |
| 32643 |
* @example |
| 32644 |
* ```javascript |
| 32645 |
* Jodit.Alert("File was uploaded"); |
| 32646 |
* Jodit.Alert("File was uploaded", "Message"); |
| 32647 |
* Jodit.Alert("File was uploaded", function() { |
| 32648 |
* $('form').hide(); |
| 32649 |
* }); |
| 32650 |
* Jodit.Alert("File wasn't uploaded", "Error", function() { |
| 32651 |
* $('form').hide(); |
| 32652 |
* }); |
| 32653 |
* ``` |
| 32654 |
*/ function Alert(msg, title, callback, className = 'jodit-dialog_alert') { |
| 32655 |
if ((0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_2__.isFunction)(title)) { |
| 32656 |
callback = title; |
| 32657 |
title = undefined; |
| 32658 |
} |
| 32659 |
const dialog = this instanceof _dialog__WEBPACK_IMPORTED_MODULE_4__.Dialog ? this : new _dialog__WEBPACK_IMPORTED_MODULE_4__.Dialog({ |
| 32660 |
closeOnClickOverlay: true |
| 32661 |
}), container = dialog.c.div(className), okButton = (0,jodit_core_ui_button_button_button__WEBPACK_IMPORTED_MODULE_3__.Button)(dialog, 'ok', 'Ok'); |
| 32662 |
(0,jodit_core_helpers_array_as_array__WEBPACK_IMPORTED_MODULE_1__.asArray)(msg).forEach((oneMessage)=>{ |
| 32663 |
container.appendChild(jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isNode(oneMessage) ? oneMessage : dialog.c.fromHTML(oneMessage)); |
| 32664 |
}); |
| 32665 |
okButton.onAction(()=>{ |
| 32666 |
if (!callback || !(0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_2__.isFunction)(callback) || callback(dialog) !== false) { |
| 32667 |
dialog.close(); |
| 32668 |
} |
| 32669 |
}); |
| 32670 |
dialog.setFooter([ |
| 32671 |
okButton |
| 32672 |
]); |
| 32673 |
dialog.open(container, title || ' ', true, true); |
| 32674 |
okButton.focus(); |
| 32675 |
return dialog; |
| 32676 |
} |
| 32677 |
|
| 32678 |
|
| 32679 |
/***/ }), |
| 32680 |
|
| 32681 |
/***/ 91560: |
| 32682 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 32683 |
|
| 32684 |
"use strict"; |
| 32685 |
__webpack_require__.r(__webpack_exports__); |
| 32686 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 32687 |
/* harmony export */ allowAttributes: function() { return /* reexport safe */ _allow_attributes__WEBPACK_IMPORTED_MODULE_0__.allowAttributes; }, |
| 32688 |
/* harmony export */ fillEmptyParagraph: function() { return /* reexport safe */ _fill_empty_paragraph__WEBPACK_IMPORTED_MODULE_1__.fillEmptyParagraph; }, |
| 32689 |
/* harmony export */ removeEmptyTextNode: function() { return /* reexport safe */ _remove_empty_text_node__WEBPACK_IMPORTED_MODULE_2__.removeEmptyTextNode; }, |
| 32690 |
/* harmony export */ removeInvTextNodes: function() { return /* reexport safe */ _remove_inv_text_nodes__WEBPACK_IMPORTED_MODULE_3__.removeInvTextNodes; }, |
| 32691 |
/* harmony export */ replaceOldTags: function() { return /* reexport safe */ _replace_old_tags__WEBPACK_IMPORTED_MODULE_4__.replaceOldTags; }, |
| 32692 |
/* harmony export */ sanitizeAttributes: function() { return /* reexport safe */ _sanitize_attributes__WEBPACK_IMPORTED_MODULE_5__.sanitizeAttributes; }, |
| 32693 |
/* harmony export */ tryRemoveNode: function() { return /* reexport safe */ _try_remove_node__WEBPACK_IMPORTED_MODULE_6__.tryRemoveNode; } |
| 32694 |
/* harmony export */ }); |
| 32695 |
/* harmony import */ var _allow_attributes__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(95559); |
| 32696 |
/* harmony import */ var _fill_empty_paragraph__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(39188); |
| 32697 |
/* harmony import */ var _remove_empty_text_node__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(94561); |
| 32698 |
/* harmony import */ var _remove_inv_text_nodes__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(53514); |
| 32699 |
/* harmony import */ var _replace_old_tags__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(35104); |
| 32700 |
/* harmony import */ var _sanitize_attributes__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(65015); |
| 32701 |
/* harmony import */ var _try_remove_node__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(27611); |
| 32702 |
/*! |
| 32703 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 32704 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 32705 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 32706 |
*/ /** |
| 32707 |
* @module plugins/clean-html |
| 32708 |
*/ /** |
| 32709 |
* @private |
| 32710 |
*/ |
| 32711 |
|
| 32712 |
|
| 32713 |
|
| 32714 |
|
| 32715 |
|
| 32716 |
|
| 32717 |
|
| 32718 |
|
| 32719 |
/***/ }), |
| 32720 |
|
| 32721 |
/***/ 91565: |
| 32722 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 32723 |
|
| 32724 |
"use strict"; |
| 32725 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 32726 |
/* harmony export */ isFunction: function() { return /* binding */ isFunction; } |
| 32727 |
/* harmony export */ }); |
| 32728 |
/*! |
| 32729 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 32730 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 32731 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 32732 |
*/ /** |
| 32733 |
* @module helpers/checker |
| 32734 |
*/ /** |
| 32735 |
* Check value is Function |
| 32736 |
*/ function isFunction(value) { |
| 32737 |
return typeof value === 'function'; |
| 32738 |
} |
| 32739 |
|
| 32740 |
|
| 32741 |
/***/ }), |
| 32742 |
|
| 32743 |
/***/ 91672: |
| 32744 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 32745 |
|
| 32746 |
"use strict"; |
| 32747 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 32748 |
/* harmony export */ component: function() { return /* binding */ component; }, |
| 32749 |
/* harmony export */ getComponentClass: function() { return /* binding */ getComponentClass; } |
| 32750 |
/* harmony export */ }); |
| 32751 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 32752 |
/* harmony import */ var jodit_core_helpers_utils_get_class_name__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(421); |
| 32753 |
/*! |
| 32754 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 32755 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 32756 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 32757 |
*/ /** |
| 32758 |
* [[include:core/decorators/component/README.md]] |
| 32759 |
* @packageDocumentation |
| 32760 |
* @module decorators/component |
| 32761 |
*/ |
| 32762 |
|
| 32763 |
const componentRegistry = new Map(); |
| 32764 |
/** |
| 32765 |
* Decorate components and set status isReady after constructor |
| 32766 |
* @param constructorFunction - Component constructor class |
| 32767 |
*/ function component(constructorFunction) { |
| 32768 |
class newConstructorFunction extends constructorFunction { |
| 32769 |
constructor(...args){ |
| 32770 |
super(...args); |
| 32771 |
const isRootConstructor = this.constructor === newConstructorFunction; |
| 32772 |
// We can add a decorator to multiple classes in a chain. |
| 32773 |
// Status should be set only as root |
| 32774 |
if (isRootConstructor) { |
| 32775 |
// In some es/minimizer builds, JS instantiates the original class rather than the new constructor |
| 32776 |
if (!(this instanceof newConstructorFunction)) { |
| 32777 |
Object.setPrototypeOf(this, newConstructorFunction.prototype); |
| 32778 |
} |
| 32779 |
this.setStatus('ready'); |
| 32780 |
} |
| 32781 |
} |
| 32782 |
} |
| 32783 |
const name = (0,jodit_core_helpers_utils_get_class_name__WEBPACK_IMPORTED_MODULE_1__.getClassName)(constructorFunction.prototype); |
| 32784 |
if (componentRegistry.has(name) && !jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.IS_PROD) { |
| 32785 |
throw new Error(`Component with name "${name}" is already registered`); |
| 32786 |
} |
| 32787 |
componentRegistry.set(name, newConstructorFunction); |
| 32788 |
return newConstructorFunction; |
| 32789 |
} |
| 32790 |
function getComponentClass(name) { |
| 32791 |
return componentRegistry.get(name); |
| 32792 |
} |
| 32793 |
|
| 32794 |
|
| 32795 |
/***/ }), |
| 32796 |
|
| 32797 |
/***/ 91678: |
| 32798 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 32799 |
|
| 32800 |
"use strict"; |
| 32801 |
/* unused harmony export bold */ |
| 32802 |
/* harmony import */ var _swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(41411); |
| 32803 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(28077); |
| 32804 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(65946); |
| 32805 |
/* harmony import */ var jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(29434); |
| 32806 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(5266); |
| 32807 |
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(40291); |
| 32808 |
/* harmony import */ var _icons_bold_svg__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(52450); |
| 32809 |
/* harmony import */ var _icons_bold_svg__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(_icons_bold_svg__WEBPACK_IMPORTED_MODULE_6__); |
| 32810 |
/* harmony import */ var _icons_italic_svg__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(41111); |
| 32811 |
/* harmony import */ var _icons_italic_svg__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(_icons_italic_svg__WEBPACK_IMPORTED_MODULE_7__); |
| 32812 |
/* harmony import */ var _icons_strikethrough_svg__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(49972); |
| 32813 |
/* harmony import */ var _icons_strikethrough_svg__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(_icons_strikethrough_svg__WEBPACK_IMPORTED_MODULE_8__); |
| 32814 |
/* harmony import */ var _icons_subscript_svg__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(45062); |
| 32815 |
/* harmony import */ var _icons_subscript_svg__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(_icons_subscript_svg__WEBPACK_IMPORTED_MODULE_9__); |
| 32816 |
/* harmony import */ var _icons_superscript_svg__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(18605); |
| 32817 |
/* harmony import */ var _icons_superscript_svg__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(_icons_superscript_svg__WEBPACK_IMPORTED_MODULE_10__); |
| 32818 |
/* harmony import */ var _icons_underline_svg__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(83389); |
| 32819 |
/* harmony import */ var _icons_underline_svg__WEBPACK_IMPORTED_MODULE_11___default = /*#__PURE__*/__webpack_require__.n(_icons_underline_svg__WEBPACK_IMPORTED_MODULE_11__); |
| 32820 |
/*! |
| 32821 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 32822 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 32823 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 32824 |
*/ /** |
| 32825 |
* [[include:plugins/bold/README.md]] |
| 32826 |
* @packageDocumentation |
| 32827 |
* @module plugins/bold |
| 32828 |
*/ |
| 32829 |
|
| 32830 |
|
| 32831 |
|
| 32832 |
|
| 32833 |
|
| 32834 |
|
| 32835 |
|
| 32836 |
|
| 32837 |
|
| 32838 |
|
| 32839 |
|
| 32840 |
|
| 32841 |
/** |
| 32842 |
* Adds `bold`,` strikethrough`, `underline` and` italic` buttons to Jodit |
| 32843 |
*/ function bold(editor) { |
| 32844 |
const callBack = (command)=>{ |
| 32845 |
const control = jodit_config__WEBPACK_IMPORTED_MODULE_4__.Config.defaultOptions.controls[command], cssOptions = (0,_swc_helpers_object_spread__WEBPACK_IMPORTED_MODULE_0__._)({}, control.css); |
| 32846 |
let cssRules; |
| 32847 |
Object.keys(cssOptions).forEach((key)=>{ |
| 32848 |
if (!cssRules) { |
| 32849 |
cssRules = {}; |
| 32850 |
} |
| 32851 |
cssRules[key] = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_2__.isArray)(cssOptions[key]) ? cssOptions[key][0] : cssOptions[key]; |
| 32852 |
}); |
| 32853 |
editor.s.commitStyle({ |
| 32854 |
element: control.tags ? control.tags[0] : undefined |
| 32855 |
}); |
| 32856 |
editor.synchronizeValues(); |
| 32857 |
return false; |
| 32858 |
}; |
| 32859 |
[ |
| 32860 |
'bold', |
| 32861 |
'italic', |
| 32862 |
'underline', |
| 32863 |
'strikethrough' |
| 32864 |
].forEach((name)=>{ |
| 32865 |
editor.registerButton({ |
| 32866 |
name, |
| 32867 |
group: 'font-style' |
| 32868 |
}); |
| 32869 |
}); |
| 32870 |
[ |
| 32871 |
'superscript', |
| 32872 |
'subscript' |
| 32873 |
].forEach((name)=>{ |
| 32874 |
editor.registerButton({ |
| 32875 |
name, |
| 32876 |
group: 'script' |
| 32877 |
}); |
| 32878 |
}); |
| 32879 |
editor.registerCommand('bold', { |
| 32880 |
exec: callBack, |
| 32881 |
hotkeys: [ |
| 32882 |
'ctrl+b', |
| 32883 |
'cmd+b' |
| 32884 |
] |
| 32885 |
}).registerCommand('italic', { |
| 32886 |
exec: callBack, |
| 32887 |
hotkeys: [ |
| 32888 |
'ctrl+i', |
| 32889 |
'cmd+i' |
| 32890 |
] |
| 32891 |
}).registerCommand('underline', { |
| 32892 |
exec: callBack, |
| 32893 |
hotkeys: [ |
| 32894 |
'ctrl+u', |
| 32895 |
'cmd+u' |
| 32896 |
] |
| 32897 |
}).registerCommand('strikethrough', { |
| 32898 |
exec: callBack |
| 32899 |
}).registerCommand('subscript', { |
| 32900 |
exec: callBack |
| 32901 |
}).registerCommand('superscript', { |
| 32902 |
exec: callBack |
| 32903 |
}); |
| 32904 |
} |
| 32905 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_1__.pluginSystem.add('bold', bold); |
| 32906 |
jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_3__.Icon.set('bold', (_icons_bold_svg__WEBPACK_IMPORTED_MODULE_6___default())).set('italic', (_icons_italic_svg__WEBPACK_IMPORTED_MODULE_7___default())).set('strikethrough', (_icons_strikethrough_svg__WEBPACK_IMPORTED_MODULE_8___default())).set('subscript', (_icons_subscript_svg__WEBPACK_IMPORTED_MODULE_9___default())).set('superscript', (_icons_superscript_svg__WEBPACK_IMPORTED_MODULE_10___default())).set('underline', (_icons_underline_svg__WEBPACK_IMPORTED_MODULE_11___default())); |
| 32907 |
|
| 32908 |
|
| 32909 |
/***/ }), |
| 32910 |
|
| 32911 |
/***/ 91764: |
| 32912 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 32913 |
|
| 32914 |
"use strict"; |
| 32915 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 32916 |
/* harmony export */ isURL: function() { return /* binding */ isURL; } |
| 32917 |
/* harmony export */ }); |
| 32918 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 32919 |
/*! |
| 32920 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 32921 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 32922 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 32923 |
*/ /** |
| 32924 |
* @module helpers/checker |
| 32925 |
*/ |
| 32926 |
/** |
| 32927 |
* Check if a string is an url |
| 32928 |
*/ function isURL(str) { |
| 32929 |
if (str.includes(' ')) { |
| 32930 |
return false; |
| 32931 |
} |
| 32932 |
if (typeof URL !== 'undefined') { |
| 32933 |
try { |
| 32934 |
const url = new URL(str); |
| 32935 |
return [ |
| 32936 |
'https:', |
| 32937 |
'http:', |
| 32938 |
'ftp:', |
| 32939 |
'file:', |
| 32940 |
'rtmp:' |
| 32941 |
].includes(url.protocol); |
| 32942 |
} catch (e) { |
| 32943 |
return false; |
| 32944 |
} |
| 32945 |
} |
| 32946 |
const a = jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.globalDocument.createElement('a'); |
| 32947 |
a.href = str; |
| 32948 |
return Boolean(a.hostname); |
| 32949 |
} |
| 32950 |
|
| 32951 |
|
| 32952 |
/***/ }), |
| 32953 |
|
| 32954 |
/***/ 91882: |
| 32955 |
/***/ (function(module) { |
| 32956 |
|
| 32957 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M1203 544q0 13-10 23l-393 393 393 393q10 10 10 23t-10 23l-50 50q-10 10-23 10t-23-10l-466-466q-10-10-10-23t10-23l466-466q10-10 23-10t23 10l50 50q10 10 10 23z\"/> </svg>" |
| 32958 |
|
| 32959 |
/***/ }), |
| 32960 |
|
| 32961 |
/***/ 93387: |
| 32962 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 32963 |
|
| 32964 |
"use strict"; |
| 32965 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 32966 |
/* harmony export */ colorToHex: function() { return /* binding */ colorToHex; } |
| 32967 |
/* harmony export */ }); |
| 32968 |
/*! |
| 32969 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 32970 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 32971 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 32972 |
*/ /** |
| 32973 |
* @module helpers/color |
| 32974 |
*/ /** |
| 32975 |
* Converts rgba text representation of color in hex |
| 32976 |
* |
| 32977 |
* @param color - string like rgba(red, green, blue, alpha) or rgb(red, green, blue) |
| 32978 |
* @returns hex color view, NaN - for transparent color |
| 32979 |
* @example |
| 32980 |
* ```javascript |
| 32981 |
* var p = document.createElement('p'); |
| 32982 |
* p.style.color = '#ffffff'; |
| 32983 |
* console.log(p.getAttribute('style')); // color: rgb(255, 255, 255); |
| 32984 |
* console.log(colorTohex(p.style.color)); // #ffffff |
| 32985 |
* ``` |
| 32986 |
*/ const colorToHex = (color)=>{ |
| 32987 |
if (color === 'rgba(0, 0, 0, 0)' || color === '') { |
| 32988 |
return false; |
| 32989 |
} |
| 32990 |
if (!color) { |
| 32991 |
return '#000000'; |
| 32992 |
} |
| 32993 |
if (color.substr(0, 1) === '#') { |
| 32994 |
return color; |
| 32995 |
} |
| 32996 |
const digits = /([\s\n\t\r]*?)rgb\((\d+), (\d+), (\d+)\)/.exec(color) || /([\s\n\t\r]*?)rgba\((\d+), (\d+), (\d+), ([\d.]+)\)/.exec(color); |
| 32997 |
if (!digits) { |
| 32998 |
return '#000000'; |
| 32999 |
} |
| 33000 |
const red = parseInt(digits[2], 10), green = parseInt(digits[3], 10), blue = parseInt(digits[4], 10), rgb = blue | green << 8 | red << 16; |
| 33001 |
let hex = rgb.toString(16).toUpperCase(); |
| 33002 |
while(hex.length < 6){ |
| 33003 |
hex = '0' + hex; |
| 33004 |
} |
| 33005 |
return digits[1] + '#' + hex; |
| 33006 |
}; |
| 33007 |
|
| 33008 |
|
| 33009 |
/***/ }), |
| 33010 |
|
| 33011 |
/***/ 93637: |
| 33012 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 33013 |
|
| 33014 |
"use strict"; |
| 33015 |
/* harmony import */ var jodit_plugins_about_about__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(41324); |
| 33016 |
/* harmony import */ var jodit_plugins_about_about__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jodit_plugins_about_about__WEBPACK_IMPORTED_MODULE_0__); |
| 33017 |
/* harmony import */ var jodit_plugins_add_new_line_add_new_line__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(42766); |
| 33018 |
/* harmony import */ var jodit_plugins_backspace_backspace__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(28286); |
| 33019 |
/* harmony import */ var jodit_plugins_bold_bold__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(91678); |
| 33020 |
/* harmony import */ var jodit_plugins_clean_html_clean_html__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(11018); |
| 33021 |
/* harmony import */ var jodit_plugins_color_color__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(42462); |
| 33022 |
/* harmony import */ var jodit_plugins_copy_format_copy_format__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(30062); |
| 33023 |
/* harmony import */ var jodit_plugins_enter_enter__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(3678); |
| 33024 |
/* harmony import */ var jodit_plugins_font_font__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(50294); |
| 33025 |
/* harmony import */ var jodit_plugins_format_block_format_block__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(53390); |
| 33026 |
/* harmony import */ var jodit_plugins_fullsize_fullsize__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(69696); |
| 33027 |
/* harmony import */ var jodit_plugins_hotkeys_hotkeys__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(50982); |
| 33028 |
/* harmony import */ var jodit_plugins_hr_hr__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(2952); |
| 33029 |
/* harmony import */ var jodit_plugins_image_image__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(90826); |
| 33030 |
/* harmony import */ var jodit_plugins_image_processor_image_processor__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(39978); |
| 33031 |
/* harmony import */ var jodit_plugins_image_properties_image_properties__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(90886); |
| 33032 |
/* harmony import */ var jodit_plugins_indent_indent__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(39000); |
| 33033 |
/* harmony import */ var jodit_plugins_inline_popup_inline_popup__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(88952); |
| 33034 |
/* harmony import */ var jodit_plugins_justify_justify__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(64094); |
| 33035 |
/* harmony import */ var jodit_plugins_link_link__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(68624); |
| 33036 |
/* harmony import */ var jodit_plugins_mobile_mobile__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(74240); |
| 33037 |
/* harmony import */ var jodit_plugins_ordered_list_ordered_list__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(98792); |
| 33038 |
/* harmony import */ var jodit_plugins_paste_paste__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(23422); |
| 33039 |
/* harmony import */ var jodit_plugins_redo_undo_redo_undo__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__(59758); |
| 33040 |
/* harmony import */ var jodit_plugins_resize_cells_resize_cells__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__(14248); |
| 33041 |
/* harmony import */ var jodit_plugins_resizer_resizer__WEBPACK_IMPORTED_MODULE_25__ = __webpack_require__(74522); |
| 33042 |
/* harmony import */ var jodit_plugins_select_select__WEBPACK_IMPORTED_MODULE_26__ = __webpack_require__(98988); |
| 33043 |
/* harmony import */ var jodit_plugins_select_cells_select_cells__WEBPACK_IMPORTED_MODULE_27__ = __webpack_require__(2756); |
| 33044 |
/* harmony import */ var jodit_plugins_source_source__WEBPACK_IMPORTED_MODULE_28__ = __webpack_require__(13810); |
| 33045 |
/* harmony import */ var jodit_plugins_symbols_symbols__WEBPACK_IMPORTED_MODULE_29__ = __webpack_require__(11774); |
| 33046 |
/* harmony import */ var jodit_plugins_tab_tab__WEBPACK_IMPORTED_MODULE_30__ = __webpack_require__(81582); |
| 33047 |
/* harmony import */ var jodit_plugins_table_table__WEBPACK_IMPORTED_MODULE_31__ = __webpack_require__(7994); |
| 33048 |
/* harmony import */ var jodit_plugins_table_keyboard_navigation_table_keyboard_navigation__WEBPACK_IMPORTED_MODULE_32__ = __webpack_require__(30110); |
| 33049 |
/* harmony import */ var jodit_plugins_video_video__WEBPACK_IMPORTED_MODULE_33__ = __webpack_require__(34142); |
| 33050 |
/*! |
| 33051 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 33052 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 33053 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 33054 |
*/ /** |
| 33055 |
* [[include:plugins/README.md]] |
| 33056 |
* @packageDocumentation |
| 33057 |
* @module plugins |
| 33058 |
*/ |
| 33059 |
|
| 33060 |
|
| 33061 |
// import 'jodit/plugins/debug/debug'; |
| 33062 |
|
| 33063 |
|
| 33064 |
|
| 33065 |
|
| 33066 |
|
| 33067 |
|
| 33068 |
|
| 33069 |
|
| 33070 |
|
| 33071 |
|
| 33072 |
|
| 33073 |
|
| 33074 |
|
| 33075 |
|
| 33076 |
|
| 33077 |
|
| 33078 |
|
| 33079 |
|
| 33080 |
|
| 33081 |
|
| 33082 |
|
| 33083 |
|
| 33084 |
|
| 33085 |
|
| 33086 |
|
| 33087 |
|
| 33088 |
|
| 33089 |
|
| 33090 |
|
| 33091 |
|
| 33092 |
|
| 33093 |
|
| 33094 |
|
| 33095 |
|
| 33096 |
|
| 33097 |
|
| 33098 |
|
| 33099 |
|
| 33100 |
|
| 33101 |
|
| 33102 |
|
| 33103 |
|
| 33104 |
|
| 33105 |
|
| 33106 |
|
| 33107 |
|
| 33108 |
|
| 33109 |
|
| 33110 |
|
| 33111 |
|
| 33112 |
|
| 33113 |
|
| 33114 |
|
| 33115 |
|
| 33116 |
|
| 33117 |
|
| 33118 |
|
| 33119 |
|
| 33120 |
|
| 33121 |
|
| 33122 |
|
| 33123 |
/***/ }), |
| 33124 |
|
| 33125 |
/***/ 93640: |
| 33126 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 33127 |
|
| 33128 |
"use strict"; |
| 33129 |
__webpack_require__.r(__webpack_exports__); |
| 33130 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 33131 |
/* harmony export */ $$: function() { return /* reexport safe */ _selector__WEBPACK_IMPORTED_MODULE_23__.$$; }, |
| 33132 |
/* harmony export */ ConfigDeepFlatten: function() { return /* reexport safe */ _config_proto__WEBPACK_IMPORTED_MODULE_7__.ConfigDeepFlatten; }, |
| 33133 |
/* harmony export */ ConfigFlatten: function() { return /* reexport safe */ _config_proto__WEBPACK_IMPORTED_MODULE_7__.ConfigFlatten; }, |
| 33134 |
/* harmony export */ ConfigProto: function() { return /* reexport safe */ _config_proto__WEBPACK_IMPORTED_MODULE_7__.ConfigProto; }, |
| 33135 |
/* harmony export */ ConnectionError: function() { return /* reexport safe */ _error__WEBPACK_IMPORTED_MODULE_13__.ConnectionError; }, |
| 33136 |
/* harmony export */ LimitedStack: function() { return /* reexport safe */ _stack__WEBPACK_IMPORTED_MODULE_25__.LimitedStack; }, |
| 33137 |
/* harmony export */ OptionsError: function() { return /* reexport safe */ _error__WEBPACK_IMPORTED_MODULE_13__.OptionsError; }, |
| 33138 |
/* harmony export */ abort: function() { return /* reexport safe */ _error__WEBPACK_IMPORTED_MODULE_13__.abort; }, |
| 33139 |
/* harmony export */ alignElement: function() { return /* reexport safe */ _align__WEBPACK_IMPORTED_MODULE_0__.alignElement; }, |
| 33140 |
/* harmony export */ alreadyLoadedList: function() { return /* reexport safe */ _append_script__WEBPACK_IMPORTED_MODULE_1__.alreadyLoadedList; }, |
| 33141 |
/* harmony export */ appendScriptAsync: function() { return /* reexport safe */ _append_script__WEBPACK_IMPORTED_MODULE_1__.appendScriptAsync; }, |
| 33142 |
/* harmony export */ appendStyleAsync: function() { return /* reexport safe */ _append_script__WEBPACK_IMPORTED_MODULE_1__.appendStyleAsync; }, |
| 33143 |
/* harmony export */ attr: function() { return /* reexport safe */ _attr__WEBPACK_IMPORTED_MODULE_3__.attr; }, |
| 33144 |
/* harmony export */ browser: function() { return /* reexport safe */ _browser__WEBPACK_IMPORTED_MODULE_4__.browser; }, |
| 33145 |
/* harmony export */ buildQuery: function() { return /* reexport safe */ _build_query__WEBPACK_IMPORTED_MODULE_5__.buildQuery; }, |
| 33146 |
/* harmony export */ call: function() { return /* reexport safe */ _utils__WEBPACK_IMPORTED_MODULE_26__.call; }, |
| 33147 |
/* harmony export */ callPromise: function() { return /* reexport safe */ _utils__WEBPACK_IMPORTED_MODULE_26__.callPromise; }, |
| 33148 |
/* harmony export */ callThis: function() { return /* reexport safe */ _utils__WEBPACK_IMPORTED_MODULE_26__.callThis; }, |
| 33149 |
/* harmony export */ clearAlign: function() { return /* reexport safe */ _align__WEBPACK_IMPORTED_MODULE_0__.clearAlign; }, |
| 33150 |
/* harmony export */ clearCenterAlign: function() { return /* reexport safe */ _css__WEBPACK_IMPORTED_MODULE_9__.clearCenterAlign; }, |
| 33151 |
/* harmony export */ cns: function() { return /* reexport safe */ _mark_deprecated__WEBPACK_IMPORTED_MODULE_18__.cns; }, |
| 33152 |
/* harmony export */ completeUrl: function() { return /* reexport safe */ _complete_url__WEBPACK_IMPORTED_MODULE_6__.completeUrl; }, |
| 33153 |
/* harmony export */ connection: function() { return /* reexport safe */ _error__WEBPACK_IMPORTED_MODULE_13__.connection; }, |
| 33154 |
/* harmony export */ convertMediaUrlToVideoEmbed: function() { return /* reexport safe */ _convert_media_url_to_video_embed__WEBPACK_IMPORTED_MODULE_8__.convertMediaUrlToVideoEmbed; }, |
| 33155 |
/* harmony export */ css: function() { return /* reexport safe */ _css__WEBPACK_IMPORTED_MODULE_9__.css; }, |
| 33156 |
/* harmony export */ cssPath: function() { return /* reexport safe */ _selector__WEBPACK_IMPORTED_MODULE_23__.cssPath; }, |
| 33157 |
/* harmony export */ ctrlKey: function() { return /* reexport safe */ _ctrl_key__WEBPACK_IMPORTED_MODULE_10__.ctrlKey; }, |
| 33158 |
/* harmony export */ dataBind: function() { return /* reexport safe */ _data_bind__WEBPACK_IMPORTED_MODULE_11__.dataBind; }, |
| 33159 |
/* harmony export */ defaultLanguage: function() { return /* reexport safe */ _default_language__WEBPACK_IMPORTED_MODULE_12__.defaultLanguage; }, |
| 33160 |
/* harmony export */ error: function() { return /* reexport safe */ _error__WEBPACK_IMPORTED_MODULE_13__.error; }, |
| 33161 |
/* harmony export */ fastClone: function() { return /* reexport safe */ _extend__WEBPACK_IMPORTED_MODULE_14__.fastClone; }, |
| 33162 |
/* harmony export */ get: function() { return /* reexport safe */ _get__WEBPACK_IMPORTED_MODULE_15__.get; }, |
| 33163 |
/* harmony export */ getClassName: function() { return /* reexport safe */ _get_class_name__WEBPACK_IMPORTED_MODULE_16__.getClassName; }, |
| 33164 |
/* harmony export */ getDataTransfer: function() { return /* reexport safe */ _utils__WEBPACK_IMPORTED_MODULE_26__.getDataTransfer; }, |
| 33165 |
/* harmony export */ getPropertyDescriptor: function() { return /* reexport safe */ _utils__WEBPACK_IMPORTED_MODULE_26__.getPropertyDescriptor; }, |
| 33166 |
/* harmony export */ getXPathByElement: function() { return /* reexport safe */ _selector__WEBPACK_IMPORTED_MODULE_23__.getXPathByElement; }, |
| 33167 |
/* harmony export */ hAlignElement: function() { return /* reexport safe */ _align__WEBPACK_IMPORTED_MODULE_0__.hAlignElement; }, |
| 33168 |
/* harmony export */ humanSizeToBytes: function() { return /* reexport safe */ _human_size_to_bytes__WEBPACK_IMPORTED_MODULE_17__.humanSizeToBytes; }, |
| 33169 |
/* harmony export */ inView: function() { return /* reexport safe */ _scroll_into_view__WEBPACK_IMPORTED_MODULE_22__.inView; }, |
| 33170 |
/* harmony export */ isAtom: function() { return /* reexport safe */ _extend__WEBPACK_IMPORTED_MODULE_14__.isAtom; }, |
| 33171 |
/* harmony export */ keepNames: function() { return /* reexport safe */ _get_class_name__WEBPACK_IMPORTED_MODULE_16__.keepNames; }, |
| 33172 |
/* harmony export */ keys: function() { return /* reexport safe */ _utils__WEBPACK_IMPORTED_MODULE_26__.keys; }, |
| 33173 |
/* harmony export */ loadImage: function() { return /* reexport safe */ _utils__WEBPACK_IMPORTED_MODULE_26__.loadImage; }, |
| 33174 |
/* harmony export */ loadNext: function() { return /* reexport safe */ _append_script__WEBPACK_IMPORTED_MODULE_1__.loadNext; }, |
| 33175 |
/* harmony export */ loadNextStyle: function() { return /* reexport safe */ _append_script__WEBPACK_IMPORTED_MODULE_1__.loadNextStyle; }, |
| 33176 |
/* harmony export */ markAsAtomic: function() { return /* reexport safe */ _extend__WEBPACK_IMPORTED_MODULE_14__.markAsAtomic; }, |
| 33177 |
/* harmony export */ markDeprecated: function() { return /* reexport safe */ _mark_deprecated__WEBPACK_IMPORTED_MODULE_18__.markDeprecated; }, |
| 33178 |
/* harmony export */ markOwner: function() { return /* reexport safe */ _utils__WEBPACK_IMPORTED_MODULE_26__.markOwner; }, |
| 33179 |
/* harmony export */ memorizeExec: function() { return /* reexport safe */ _utils__WEBPACK_IMPORTED_MODULE_26__.memorizeExec; }, |
| 33180 |
/* harmony export */ options: function() { return /* reexport safe */ _error__WEBPACK_IMPORTED_MODULE_13__.options; }, |
| 33181 |
/* harmony export */ parseQuery: function() { return /* reexport safe */ _parse_query__WEBPACK_IMPORTED_MODULE_19__.parseQuery; }, |
| 33182 |
/* harmony export */ previewBox: function() { return /* reexport safe */ _print__WEBPACK_IMPORTED_MODULE_20__.previewBox; }, |
| 33183 |
/* harmony export */ refs: function() { return /* reexport safe */ _selector__WEBPACK_IMPORTED_MODULE_23__.refs; }, |
| 33184 |
/* harmony export */ reset: function() { return /* reexport safe */ _reset__WEBPACK_IMPORTED_MODULE_21__.reset; }, |
| 33185 |
/* harmony export */ resolveElement: function() { return /* reexport safe */ _selector__WEBPACK_IMPORTED_MODULE_23__.resolveElement; }, |
| 33186 |
/* harmony export */ scrollIntoViewIfNeeded: function() { return /* reexport safe */ _scroll_into_view__WEBPACK_IMPORTED_MODULE_22__.scrollIntoViewIfNeeded; }, |
| 33187 |
/* harmony export */ set: function() { return /* reexport safe */ _set__WEBPACK_IMPORTED_MODULE_24__.set; } |
| 33188 |
/* harmony export */ }); |
| 33189 |
/* harmony import */ var _align__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(16849); |
| 33190 |
/* harmony import */ var _append_script__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(47760); |
| 33191 |
/* harmony import */ var _assert__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(28712); |
| 33192 |
/* harmony import */ var _assert__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_assert__WEBPACK_IMPORTED_MODULE_2__); |
| 33193 |
/* harmony reexport (unknown) */ var __WEBPACK_REEXPORT_OBJECT__ = {}; |
| 33194 |
/* harmony reexport (unknown) */ for(var __WEBPACK_IMPORT_KEY__ in _assert__WEBPACK_IMPORTED_MODULE_2__) if(["default","alignElement","clearAlign","hAlignElement","alreadyLoadedList","appendScriptAsync","appendStyleAsync","loadNext","loadNextStyle"].indexOf(__WEBPACK_IMPORT_KEY__) < 0) __WEBPACK_REEXPORT_OBJECT__[__WEBPACK_IMPORT_KEY__] = function(key) { return _assert__WEBPACK_IMPORTED_MODULE_2__[key]; }.bind(0, __WEBPACK_IMPORT_KEY__) |
| 33195 |
/* harmony reexport (unknown) */ __webpack_require__.d(__webpack_exports__, __WEBPACK_REEXPORT_OBJECT__); |
| 33196 |
/* harmony import */ var _attr__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(7909); |
| 33197 |
/* harmony import */ var _browser__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(26136); |
| 33198 |
/* harmony import */ var _build_query__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(36833); |
| 33199 |
/* harmony import */ var _complete_url__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(91321); |
| 33200 |
/* harmony import */ var _config_proto__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(77483); |
| 33201 |
/* harmony import */ var _convert_media_url_to_video_embed__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(3856); |
| 33202 |
/* harmony import */ var _css__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(80991); |
| 33203 |
/* harmony import */ var _ctrl_key__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(77213); |
| 33204 |
/* harmony import */ var _data_bind__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(36400); |
| 33205 |
/* harmony import */ var _default_language__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(97228); |
| 33206 |
/* harmony import */ var _error__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(33201); |
| 33207 |
/* harmony import */ var _extend__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(54794); |
| 33208 |
/* harmony import */ var _get__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(89308); |
| 33209 |
/* harmony import */ var _get_class_name__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(421); |
| 33210 |
/* harmony import */ var _human_size_to_bytes__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(37427); |
| 33211 |
/* harmony import */ var _mark_deprecated__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(49385); |
| 33212 |
/* harmony import */ var _parse_query__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(36310); |
| 33213 |
/* harmony import */ var _print__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(57075); |
| 33214 |
/* harmony import */ var _reset__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(43379); |
| 33215 |
/* harmony import */ var _scroll_into_view__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(60898); |
| 33216 |
/* harmony import */ var _selector__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__(28723); |
| 33217 |
/* harmony import */ var _set__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__(52144); |
| 33218 |
/* harmony import */ var _stack__WEBPACK_IMPORTED_MODULE_25__ = __webpack_require__(42820); |
| 33219 |
/* harmony import */ var _utils__WEBPACK_IMPORTED_MODULE_26__ = __webpack_require__(71125); |
| 33220 |
/*! |
| 33221 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 33222 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 33223 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 33224 |
*/ /** |
| 33225 |
* @module helpers/utils |
| 33226 |
*/ |
| 33227 |
|
| 33228 |
|
| 33229 |
|
| 33230 |
|
| 33231 |
|
| 33232 |
|
| 33233 |
|
| 33234 |
|
| 33235 |
|
| 33236 |
|
| 33237 |
|
| 33238 |
|
| 33239 |
|
| 33240 |
|
| 33241 |
|
| 33242 |
|
| 33243 |
|
| 33244 |
|
| 33245 |
|
| 33246 |
|
| 33247 |
|
| 33248 |
|
| 33249 |
|
| 33250 |
|
| 33251 |
|
| 33252 |
|
| 33253 |
|
| 33254 |
|
| 33255 |
/***/ }), |
| 33256 |
|
| 33257 |
/***/ 93747: |
| 33258 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 33259 |
|
| 33260 |
"use strict"; |
| 33261 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 33262 |
/* harmony export */ EventEmitter: function() { return /* binding */ EventEmitter; } |
| 33263 |
/* harmony export */ }); |
| 33264 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 33265 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(81937); |
| 33266 |
/* harmony import */ var jodit_core_helpers_array_split_array__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(32328); |
| 33267 |
/* harmony import */ var jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(17312); |
| 33268 |
/* harmony import */ var jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(91565); |
| 33269 |
/* harmony import */ var jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(85932); |
| 33270 |
/* harmony import */ var jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(33201); |
| 33271 |
/* harmony import */ var _store__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(18869); |
| 33272 |
/*! |
| 33273 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 33274 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 33275 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 33276 |
*/ /** |
| 33277 |
* [[include:core/event-emitter/README.md]] |
| 33278 |
* @packageDocumentation |
| 33279 |
* @module event-emitter |
| 33280 |
*/ |
| 33281 |
|
| 33282 |
|
| 33283 |
|
| 33284 |
|
| 33285 |
|
| 33286 |
|
| 33287 |
|
| 33288 |
/** |
| 33289 |
* The module editor's event manager |
| 33290 |
*/ class EventEmitter { |
| 33291 |
mute(event) { |
| 33292 |
this.__mutedEvents.add(event !== null && event !== void 0 ? event : '*'); |
| 33293 |
return this; |
| 33294 |
} |
| 33295 |
isMuted(event) { |
| 33296 |
if (event && this.__mutedEvents.has(event)) { |
| 33297 |
return true; |
| 33298 |
} |
| 33299 |
return this.__mutedEvents.has('*'); |
| 33300 |
} |
| 33301 |
unmute(event) { |
| 33302 |
this.__mutedEvents.delete(event !== null && event !== void 0 ? event : '*'); |
| 33303 |
return this; |
| 33304 |
} |
| 33305 |
__eachEvent(events, callback) { |
| 33306 |
const eventParts = (0,jodit_core_helpers_array_split_array__WEBPACK_IMPORTED_MODULE_2__.splitArray)(events).map((e)=>e.trim()); |
| 33307 |
eventParts.forEach((eventNameSpace)=>{ |
| 33308 |
const eventAndNameSpace = eventNameSpace.split('.'); |
| 33309 |
const namespace = eventAndNameSpace[1] || _store__WEBPACK_IMPORTED_MODULE_7__.defaultNameSpace; |
| 33310 |
callback.call(this, eventAndNameSpace[0], namespace); |
| 33311 |
}); |
| 33312 |
} |
| 33313 |
__getStore(subject) { |
| 33314 |
if (!subject) { |
| 33315 |
throw (0,jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_6__.error)('Need subject'); |
| 33316 |
} |
| 33317 |
if (subject[this.__key] === undefined) { |
| 33318 |
const store = new _store__WEBPACK_IMPORTED_MODULE_7__.EventHandlersStore(); |
| 33319 |
Object.defineProperty(subject, this.__key, { |
| 33320 |
enumerable: false, |
| 33321 |
configurable: true, |
| 33322 |
writable: true, |
| 33323 |
value: store |
| 33324 |
}); |
| 33325 |
} |
| 33326 |
return subject[this.__key]; |
| 33327 |
} |
| 33328 |
__removeStoreFromSubject(subject) { |
| 33329 |
if (subject[this.__key] !== undefined) { |
| 33330 |
Object.defineProperty(subject, this.__key, { |
| 33331 |
enumerable: false, |
| 33332 |
configurable: true, |
| 33333 |
writable: true, |
| 33334 |
value: undefined |
| 33335 |
}); |
| 33336 |
} |
| 33337 |
} |
| 33338 |
__triggerNativeEvent(element, event) { |
| 33339 |
const evt = this.__doc.createEvent('HTMLEvents'); |
| 33340 |
if ((0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_5__.isString)(event)) { |
| 33341 |
evt.initEvent(event, true, true); |
| 33342 |
} else { |
| 33343 |
evt.initEvent(event.type, event.bubbles, event.cancelable); |
| 33344 |
[ |
| 33345 |
'screenX', |
| 33346 |
'screenY', |
| 33347 |
'clientX', |
| 33348 |
'clientY', |
| 33349 |
'target', |
| 33350 |
'srcElement', |
| 33351 |
'currentTarget', |
| 33352 |
'timeStamp', |
| 33353 |
'which', |
| 33354 |
'keyCode' |
| 33355 |
].forEach((property)=>{ |
| 33356 |
Object.defineProperty(evt, property, { |
| 33357 |
value: event[property], |
| 33358 |
enumerable: true |
| 33359 |
}); |
| 33360 |
}); |
| 33361 |
Object.defineProperty(evt, 'originalEvent', { |
| 33362 |
value: event, |
| 33363 |
enumerable: true |
| 33364 |
}); |
| 33365 |
} |
| 33366 |
element.dispatchEvent(evt); |
| 33367 |
} |
| 33368 |
/** |
| 33369 |
* Get current event name |
| 33370 |
* |
| 33371 |
* @example |
| 33372 |
* ```javascript |
| 33373 |
* parent.e.on('openDialog closeDialog', function () { |
| 33374 |
* if (parent.e.current === 'closeDialog') { |
| 33375 |
* alert('Dialog was closed'); |
| 33376 |
* } else { |
| 33377 |
* alert('Dialog was opened'); |
| 33378 |
* } |
| 33379 |
* }); |
| 33380 |
* ``` |
| 33381 |
*/ get current() { |
| 33382 |
return this.currents[this.currents.length - 1]; |
| 33383 |
} |
| 33384 |
on(eventsOrSubjects, callbackOrEvents, optionsOrCallback, opts) { |
| 33385 |
let subjects; |
| 33386 |
let events; |
| 33387 |
let callback; |
| 33388 |
let options; |
| 33389 |
if ((0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_5__.isString)(eventsOrSubjects) || (0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_5__.isStringArray)(eventsOrSubjects)) { |
| 33390 |
subjects = this; |
| 33391 |
events = eventsOrSubjects; |
| 33392 |
callback = callbackOrEvents; |
| 33393 |
options = optionsOrCallback; |
| 33394 |
} else { |
| 33395 |
subjects = eventsOrSubjects; |
| 33396 |
events = callbackOrEvents; |
| 33397 |
callback = optionsOrCallback; |
| 33398 |
options = opts; |
| 33399 |
} |
| 33400 |
if (!((0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_5__.isString)(events) || (0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_5__.isStringArray)(events)) || events.length === 0) { |
| 33401 |
throw (0,jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_6__.error)('Need events names'); |
| 33402 |
} |
| 33403 |
if (!(0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_4__.isFunction)(callback)) { |
| 33404 |
throw (0,jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_6__.error)('Need event handler'); |
| 33405 |
} |
| 33406 |
if ((0,jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_3__.isArray)(subjects)) { |
| 33407 |
subjects.forEach((subj)=>{ |
| 33408 |
this.on(subj, events, callback, options); |
| 33409 |
}); |
| 33410 |
return this; |
| 33411 |
} |
| 33412 |
const subject = subjects; |
| 33413 |
const store = this.__getStore(subject); |
| 33414 |
const self = this; |
| 33415 |
let syntheticCallback = function(event, ...args) { |
| 33416 |
if (self.isMuted(event)) { |
| 33417 |
return; |
| 33418 |
} |
| 33419 |
return callback && callback.call(this, ...args); |
| 33420 |
}; |
| 33421 |
if (isDOMElement(subject)) { |
| 33422 |
syntheticCallback = function(event) { |
| 33423 |
if (self.isMuted(event.type)) { |
| 33424 |
return; |
| 33425 |
} |
| 33426 |
self.__prepareEvent(event); |
| 33427 |
if (callback && callback.call(this, event) === false) { |
| 33428 |
event.preventDefault(); |
| 33429 |
event.stopImmediatePropagation(); |
| 33430 |
return false; |
| 33431 |
} |
| 33432 |
return; |
| 33433 |
}; |
| 33434 |
} |
| 33435 |
this.__eachEvent(events, (event, namespace)=>{ |
| 33436 |
if (event.length === 0) { |
| 33437 |
throw (0,jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_6__.error)('Need event name'); |
| 33438 |
} |
| 33439 |
if (store.indexOf(event, namespace, callback) === false) { |
| 33440 |
const block = { |
| 33441 |
event, |
| 33442 |
originalCallback: callback, |
| 33443 |
syntheticCallback |
| 33444 |
}; |
| 33445 |
store.set(event, namespace, block, options === null || options === void 0 ? void 0 : options.top); |
| 33446 |
if (isDOMElement(subject)) { |
| 33447 |
var _ref, _ref1; |
| 33448 |
const eOpts = jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.PASSIVE_EVENTS.has(event) ? { |
| 33449 |
passive: true, |
| 33450 |
capture: (_ref = options === null || options === void 0 ? void 0 : options.capture) !== null && _ref !== void 0 ? _ref : false |
| 33451 |
} : (_ref1 = options === null || options === void 0 ? void 0 : options.capture) !== null && _ref1 !== void 0 ? _ref1 : false; |
| 33452 |
syntheticCallback.options = eOpts; |
| 33453 |
subject.addEventListener(event, syntheticCallback, eOpts); |
| 33454 |
this.__memoryDOMSubjectToHandler(subject, syntheticCallback); |
| 33455 |
} |
| 33456 |
} |
| 33457 |
}); |
| 33458 |
return this; |
| 33459 |
} |
| 33460 |
__memoryDOMSubjectToHandler(subject, syntheticCallback) { |
| 33461 |
const callbackStore = this.__domEventsMap.get(subject) || new Set(); |
| 33462 |
callbackStore.add(syntheticCallback); |
| 33463 |
this.__domEventsMap.set(subject, callbackStore); |
| 33464 |
} |
| 33465 |
__unmemoryDOMSubjectToHandler(subject, syntheticCallback) { |
| 33466 |
const m = this.__domEventsMap; |
| 33467 |
const callbackStore = m.get(subject) || new Set(); |
| 33468 |
callbackStore.delete(syntheticCallback); |
| 33469 |
if (callbackStore.size) { |
| 33470 |
m.set(subject, callbackStore); |
| 33471 |
} else { |
| 33472 |
m.delete(subject); |
| 33473 |
} |
| 33474 |
} |
| 33475 |
one(eventsOrSubjects, callbackOrEvents, optionsOrCallback, opts) { |
| 33476 |
let subjects; |
| 33477 |
let events; |
| 33478 |
let callback; |
| 33479 |
let options; |
| 33480 |
if ((0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_5__.isString)(eventsOrSubjects) || (0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_5__.isStringArray)(eventsOrSubjects)) { |
| 33481 |
subjects = this; |
| 33482 |
events = eventsOrSubjects; |
| 33483 |
callback = callbackOrEvents; |
| 33484 |
options = optionsOrCallback; |
| 33485 |
} else { |
| 33486 |
subjects = eventsOrSubjects; |
| 33487 |
events = callbackOrEvents; |
| 33488 |
callback = optionsOrCallback; |
| 33489 |
options = opts; |
| 33490 |
} |
| 33491 |
const newCallback = (...args)=>{ |
| 33492 |
this.off(subjects, events, newCallback); |
| 33493 |
return callback(...args); |
| 33494 |
}; |
| 33495 |
this.on(subjects, events, newCallback, options); |
| 33496 |
return this; |
| 33497 |
} |
| 33498 |
off(eventsOrSubjects, callbackOrEvents, handler) { |
| 33499 |
let subjects; |
| 33500 |
let events; |
| 33501 |
let callback; |
| 33502 |
if ((0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_5__.isString)(eventsOrSubjects) || (0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_5__.isStringArray)(eventsOrSubjects)) { |
| 33503 |
subjects = this; |
| 33504 |
events = eventsOrSubjects; |
| 33505 |
callback = callbackOrEvents; |
| 33506 |
} else { |
| 33507 |
subjects = eventsOrSubjects; |
| 33508 |
events = callbackOrEvents; |
| 33509 |
callback = handler; |
| 33510 |
} |
| 33511 |
if ((0,jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_3__.isArray)(subjects)) { |
| 33512 |
subjects.forEach((subj)=>{ |
| 33513 |
this.off(subj, events, callback); |
| 33514 |
}); |
| 33515 |
return this; |
| 33516 |
} |
| 33517 |
const subject = subjects; |
| 33518 |
const store = this.__getStore(subject); |
| 33519 |
if (!((0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_5__.isString)(events) || (0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_5__.isStringArray)(events)) || events.length === 0) { |
| 33520 |
store.namespaces().forEach((namespace)=>{ |
| 33521 |
this.off(subject, '.' + namespace); |
| 33522 |
}); |
| 33523 |
this.__removeStoreFromSubject(subject); |
| 33524 |
return this; |
| 33525 |
} |
| 33526 |
const removeEventListener = (block)=>{ |
| 33527 |
if (isDOMElement(subject)) { |
| 33528 |
var _block_syntheticCallback_options; |
| 33529 |
subject.removeEventListener(block.event, block.syntheticCallback, (_block_syntheticCallback_options = block.syntheticCallback.options) !== null && _block_syntheticCallback_options !== void 0 ? _block_syntheticCallback_options : false); |
| 33530 |
this.__unmemoryDOMSubjectToHandler(subject, block.syntheticCallback); |
| 33531 |
} |
| 33532 |
}, removeCallbackFromNameSpace = (event, namespace)=>{ |
| 33533 |
if (event === '') { |
| 33534 |
store.events(namespace).forEach((eventName)=>{ |
| 33535 |
if (eventName !== '') { |
| 33536 |
removeCallbackFromNameSpace(eventName, namespace); |
| 33537 |
} |
| 33538 |
}); |
| 33539 |
return; |
| 33540 |
} |
| 33541 |
const blocks = store.get(event, namespace); |
| 33542 |
if (!blocks || !blocks.length) { |
| 33543 |
return; |
| 33544 |
} |
| 33545 |
if (!(0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_4__.isFunction)(callback)) { |
| 33546 |
blocks.forEach(removeEventListener); |
| 33547 |
blocks.length = 0; |
| 33548 |
store.clearEvents(namespace, event); |
| 33549 |
} else { |
| 33550 |
const index = store.indexOf(event, namespace, callback); |
| 33551 |
if (index !== false) { |
| 33552 |
removeEventListener(blocks[index]); |
| 33553 |
blocks.splice(index, 1); |
| 33554 |
if (!blocks.length) { |
| 33555 |
store.clearEvents(namespace, event); |
| 33556 |
} |
| 33557 |
} |
| 33558 |
} |
| 33559 |
}; |
| 33560 |
this.__eachEvent(events, (event, namespace)=>{ |
| 33561 |
if (namespace === _store__WEBPACK_IMPORTED_MODULE_7__.defaultNameSpace) { |
| 33562 |
store.namespaces().forEach((namespace)=>{ |
| 33563 |
removeCallbackFromNameSpace(event, namespace); |
| 33564 |
}); |
| 33565 |
} else { |
| 33566 |
removeCallbackFromNameSpace(event, namespace); |
| 33567 |
} |
| 33568 |
}); |
| 33569 |
if (store.isEmpty()) { |
| 33570 |
this.__removeStoreFromSubject(subject); |
| 33571 |
} |
| 33572 |
return this; |
| 33573 |
} |
| 33574 |
stopPropagation(subjectOrEvents, eventsList) { |
| 33575 |
const subject = (0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_5__.isString)(subjectOrEvents) ? this : subjectOrEvents; |
| 33576 |
const events = (0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_5__.isString)(subjectOrEvents) ? subjectOrEvents : eventsList; |
| 33577 |
if (typeof events !== 'string') { |
| 33578 |
throw (0,jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_6__.error)('Need event names'); |
| 33579 |
} |
| 33580 |
const store = this.__getStore(subject); |
| 33581 |
this.__eachEvent(events, (event, namespace)=>{ |
| 33582 |
const blocks = store.get(event, namespace); |
| 33583 |
if (blocks) { |
| 33584 |
this.__stopped.push(blocks); |
| 33585 |
} |
| 33586 |
if (namespace === _store__WEBPACK_IMPORTED_MODULE_7__.defaultNameSpace) { |
| 33587 |
store.namespaces(true).forEach((ns)=>this.stopPropagation(subject, event + '.' + ns)); |
| 33588 |
} |
| 33589 |
}); |
| 33590 |
} |
| 33591 |
__removeStop(currentBlocks) { |
| 33592 |
if (currentBlocks) { |
| 33593 |
const index = this.__stopped.indexOf(currentBlocks); |
| 33594 |
index !== -1 && this.__stopped.splice(0, index + 1); |
| 33595 |
} |
| 33596 |
} |
| 33597 |
__isStopped(currentBlocks) { |
| 33598 |
return currentBlocks !== undefined && this.__stopped.indexOf(currentBlocks) !== -1; |
| 33599 |
} |
| 33600 |
fire(subjectOrEvents, eventsList, ...args) { |
| 33601 |
let result, result_value; |
| 33602 |
const subject = (0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_5__.isString)(subjectOrEvents) ? this : subjectOrEvents; |
| 33603 |
const events = (0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_5__.isString)(subjectOrEvents) ? subjectOrEvents : eventsList; |
| 33604 |
const argumentsList = (0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_5__.isString)(subjectOrEvents) ? [ |
| 33605 |
eventsList, |
| 33606 |
...args |
| 33607 |
] : args; |
| 33608 |
if (!isDOMElement(subject) && !(0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_5__.isString)(events)) { |
| 33609 |
throw (0,jodit_core_helpers_utils_error__WEBPACK_IMPORTED_MODULE_6__.error)('Need events names'); |
| 33610 |
} |
| 33611 |
const store = this.__getStore(subject); |
| 33612 |
if (!(0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_5__.isString)(events) && isDOMElement(subject)) { |
| 33613 |
this.__triggerNativeEvent(subject, eventsList); |
| 33614 |
} else { |
| 33615 |
this.__eachEvent(events, (event, namespace)=>{ |
| 33616 |
if (isDOMElement(subject)) { |
| 33617 |
this.__triggerNativeEvent(subject, event); |
| 33618 |
} else { |
| 33619 |
const blocks = store.get(event, namespace); |
| 33620 |
if (blocks) { |
| 33621 |
try { |
| 33622 |
[ |
| 33623 |
...blocks |
| 33624 |
].every((block)=>{ |
| 33625 |
if (this.__isStopped(blocks)) { |
| 33626 |
return false; |
| 33627 |
} |
| 33628 |
this.currents.push(event); |
| 33629 |
result_value = block.syntheticCallback.call(subject, event, ...argumentsList); |
| 33630 |
this.currents.pop(); |
| 33631 |
if (result_value !== undefined) { |
| 33632 |
result = result_value; |
| 33633 |
} |
| 33634 |
return true; |
| 33635 |
}); |
| 33636 |
} finally{ |
| 33637 |
this.__removeStop(blocks); |
| 33638 |
} |
| 33639 |
} |
| 33640 |
if (namespace === _store__WEBPACK_IMPORTED_MODULE_7__.defaultNameSpace && !isDOMElement(subject)) { |
| 33641 |
store.namespaces().filter((ns)=>ns !== namespace).forEach((ns)=>{ |
| 33642 |
const result_second = this.fire.apply(this, [ |
| 33643 |
subject, |
| 33644 |
event + '.' + ns, |
| 33645 |
...argumentsList |
| 33646 |
]); |
| 33647 |
if (result_second !== undefined) { |
| 33648 |
result = result_second; |
| 33649 |
} |
| 33650 |
}); |
| 33651 |
} |
| 33652 |
} |
| 33653 |
}); |
| 33654 |
} |
| 33655 |
return result; |
| 33656 |
} |
| 33657 |
destruct() { |
| 33658 |
if (this.__isDestructed) { |
| 33659 |
return; |
| 33660 |
} |
| 33661 |
this.__isDestructed = true; |
| 33662 |
this.__domEventsMap.forEach((set, elm)=>{ |
| 33663 |
this.off(elm); |
| 33664 |
}); |
| 33665 |
this.__domEventsMap.clear(); |
| 33666 |
this.__mutedEvents.clear(); |
| 33667 |
this.currents.length = 0; |
| 33668 |
this.__stopped.length = 0; |
| 33669 |
this.off(this); |
| 33670 |
this.__getStore(this).clear(); |
| 33671 |
this.__removeStoreFromSubject(this); |
| 33672 |
} |
| 33673 |
constructor(doc){ |
| 33674 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__domEventsMap", new Map()); |
| 33675 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__mutedEvents", new Set()); |
| 33676 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__key", '__JoditEventEmitterNamespaces'); |
| 33677 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__doc", jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.globalDocument); |
| 33678 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__prepareEvent", (e)=>{ |
| 33679 |
if (e.cancelBubble) { |
| 33680 |
return; |
| 33681 |
} |
| 33682 |
// for Shadow Dom |
| 33683 |
if (e.composed && (0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_4__.isFunction)(e.composedPath) && e.composedPath()[0]) { |
| 33684 |
Object.defineProperty(e, 'target', { |
| 33685 |
value: e.composedPath()[0], |
| 33686 |
configurable: true, |
| 33687 |
enumerable: true |
| 33688 |
}); |
| 33689 |
} |
| 33690 |
if (e.type.match(/^touch/) && e.changedTouches && e.changedTouches.length) { |
| 33691 |
[ |
| 33692 |
'clientX', |
| 33693 |
'clientY', |
| 33694 |
'pageX', |
| 33695 |
'pageY' |
| 33696 |
].forEach((key)=>{ |
| 33697 |
Object.defineProperty(e, key, { |
| 33698 |
value: e.changedTouches[0][key], |
| 33699 |
configurable: true, |
| 33700 |
enumerable: true |
| 33701 |
}); |
| 33702 |
}); |
| 33703 |
} |
| 33704 |
if (!e.originalEvent) { |
| 33705 |
e.originalEvent = e; |
| 33706 |
} |
| 33707 |
if (e.type === 'paste' && e.clipboardData === undefined && this.__doc.defaultView.clipboardData) { |
| 33708 |
Object.defineProperty(e, 'clipboardData', { |
| 33709 |
get: ()=>{ |
| 33710 |
return this.__doc.defaultView.clipboardData; |
| 33711 |
}, |
| 33712 |
configurable: true, |
| 33713 |
enumerable: true |
| 33714 |
}); |
| 33715 |
} |
| 33716 |
}); |
| 33717 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "currents", []); |
| 33718 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__stopped", []); |
| 33719 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__isDestructed", false); |
| 33720 |
if (doc) { |
| 33721 |
this.__doc = doc; |
| 33722 |
} |
| 33723 |
this.__key += new Date().getTime(); |
| 33724 |
} |
| 33725 |
} |
| 33726 |
function isDOMElement(subject) { |
| 33727 |
return (0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_4__.isFunction)(subject.addEventListener); |
| 33728 |
} |
| 33729 |
|
| 33730 |
|
| 33731 |
/***/ }), |
| 33732 |
|
| 33733 |
/***/ 93890: |
| 33734 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 33735 |
|
| 33736 |
"use strict"; |
| 33737 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 33738 |
/* harmony export */ checkRemoveUnbreakableElement: function() { return /* binding */ checkRemoveUnbreakableElement; } |
| 33739 |
/* harmony export */ }); |
| 33740 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 33741 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(23211); |
| 33742 |
/* harmony import */ var _check_remove_empty_parent__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2409); |
| 33743 |
/*! |
| 33744 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 33745 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 33746 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 33747 |
*/ /** |
| 33748 |
* @module plugins/backspace |
| 33749 |
*/ |
| 33750 |
|
| 33751 |
|
| 33752 |
/** |
| 33753 |
* Check possibility inseparable Element can be removed (img, hr etc.) |
| 33754 |
* |
| 33755 |
* @example |
| 33756 |
* ```html |
| 33757 |
* <p>first second <img>| stop</p> |
| 33758 |
* ``` |
| 33759 |
* result |
| 33760 |
* ```html |
| 33761 |
* <p>first second | stop</p> |
| 33762 |
* ``` |
| 33763 |
* |
| 33764 |
* @private |
| 33765 |
*/ function checkRemoveUnbreakableElement(jodit, fakeNode, backspace) { |
| 33766 |
const neighbor = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.findSibling(fakeNode, backspace); |
| 33767 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isElement(neighbor) && (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isTag(neighbor, jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INSEPARABLE_TAGS) || jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isEmpty(neighbor))) { |
| 33768 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.safeRemove(neighbor); |
| 33769 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isTag(neighbor, 'br') && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.findNotEmptySibling(fakeNode, false)) { |
| 33770 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.after(fakeNode, jodit.createInside.element('br')); |
| 33771 |
} |
| 33772 |
jodit.s.setCursorBefore(fakeNode); |
| 33773 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.isTag(neighbor, 'br')) { |
| 33774 |
(0,_check_remove_empty_parent__WEBPACK_IMPORTED_MODULE_2__.checkRemoveEmptyParent)(jodit, fakeNode, backspace); |
| 33775 |
} |
| 33776 |
return true; |
| 33777 |
} |
| 33778 |
return false; |
| 33779 |
} |
| 33780 |
|
| 33781 |
|
| 33782 |
/***/ }), |
| 33783 |
|
| 33784 |
/***/ 94013: |
| 33785 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 33786 |
|
| 33787 |
"use strict"; |
| 33788 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 33789 |
/* harmony export */ isEqual: function() { return /* binding */ isEqual; }, |
| 33790 |
/* harmony export */ isFastEqual: function() { return /* binding */ isFastEqual; } |
| 33791 |
/* harmony export */ }); |
| 33792 |
/* harmony import */ var jodit_core_helpers_string_stringify__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(3347); |
| 33793 |
/*! |
| 33794 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 33795 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 33796 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 33797 |
*/ /** |
| 33798 |
* @module helpers/checker |
| 33799 |
*/ |
| 33800 |
/** |
| 33801 |
* Check two element are equal |
| 33802 |
*/ function isEqual(a, b) { |
| 33803 |
return a === b || (0,jodit_core_helpers_string_stringify__WEBPACK_IMPORTED_MODULE_0__.stringify)(a) === (0,jodit_core_helpers_string_stringify__WEBPACK_IMPORTED_MODULE_0__.stringify)(b); |
| 33804 |
} |
| 33805 |
function isFastEqual(a, b) { |
| 33806 |
return a === b; |
| 33807 |
} |
| 33808 |
|
| 33809 |
|
| 33810 |
/***/ }), |
| 33811 |
|
| 33812 |
/***/ 94190: |
| 33813 |
/***/ (function(module) { |
| 33814 |
|
| 33815 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 312 312\"> <g transform=\"translate(0.000000,312.000000) scale(0.100000,-0.100000)\" stroke=\"none\"> <path d=\"M50 3109 c0 -7 -11 -22 -25 -35 l-25 -23 0 -961 0 -961 32 -29 32 -30 501 -2 500 -3 3 -502 2 -502 31 -30 31 -31 958 0 958 0 23 25 c13 13 30 25 37 25 9 0 12 199 12 960 0 686 -3 960 -11 960 -6 0 -24 12 -40 28 l-29 27 -503 5 -502 5 -5 502 -5 503 -28 29 c-15 16 -27 34 -27 40 0 8 -274 11 -960 11 -710 0 -960 -3 -960 -11z m1738 -698 l2 -453 -40 -40 c-22 -22 -40 -43 -40 -47 0 -4 36 -42 79 -85 88 -87 82 -87 141 -23 l26 27 455 -2 454 -3 0 -775 0 -775 -775 0 -775 0 -3 450 -2 449 47 48 47 48 -82 80 c-44 44 -84 80 -87 80 -3 0 -25 -18 -48 -40 l-41 -40 -456 2 -455 3 -3 765 c-1 421 0 771 3 778 3 10 164 12 777 10 l773 -3 3 -454z\"/> <path d=\"M607 2492 c-42 -42 -77 -82 -77 -87 0 -6 86 -96 190 -200 105 -104 190 -197 190 -205 0 -8 -41 -56 -92 -107 -65 -65 -87 -94 -77 -98 8 -3 138 -4 289 -3 l275 3 3 275 c1 151 0 281 -3 289 -4 10 -35 -14 -103 -82 -54 -53 -103 -97 -109 -97 -7 0 -99 88 -206 195 -107 107 -196 195 -198 195 -3 0 -39 -35 -82 -78z\"/> <path d=\"M1470 1639 c-47 -49 -87 -91 -89 -94 -5 -6 149 -165 160 -165 9 0 189 179 189 188 0 12 -154 162 -165 161 -6 0 -48 -41 -95 -90z\"/> <path d=\"M1797 1303 c-9 -8 -9 -568 0 -576 4 -4 50 36 103 88 54 52 101 95 106 95 5 0 95 -85 199 -190 104 -104 194 -190 200 -190 6 0 46 36 90 80 l79 79 -197 196 c-108 108 -197 199 -197 203 0 4 45 52 99 106 55 55 98 103 95 108 -6 10 -568 11 -577 1z\"/> </g> </svg>" |
| 33816 |
|
| 33817 |
/***/ }), |
| 33818 |
|
| 33819 |
/***/ 94193: |
| 33820 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 33821 |
|
| 33822 |
"use strict"; |
| 33823 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 33824 |
/* harmony export */ SourceEditor: function() { return /* binding */ SourceEditor; } |
| 33825 |
/* harmony export */ }); |
| 33826 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 33827 |
/*! |
| 33828 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 33829 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 33830 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 33831 |
*/ /** |
| 33832 |
* @module plugins/source |
| 33833 |
*/ |
| 33834 |
class SourceEditor { |
| 33835 |
/** |
| 33836 |
* Short alias for this.jodit |
| 33837 |
*/ get j() { |
| 33838 |
return this.jodit; |
| 33839 |
} |
| 33840 |
onReady() { |
| 33841 |
this.replaceUndoManager(); |
| 33842 |
this.isReady = true; |
| 33843 |
this.j.e.fire(this, 'ready'); |
| 33844 |
} |
| 33845 |
onReadyAlways(onReady) { |
| 33846 |
if (!this.isReady) { |
| 33847 |
var _this_j_events; |
| 33848 |
(_this_j_events = this.j.events) === null || _this_j_events === void 0 ? void 0 : _this_j_events.on(this, 'ready', onReady); |
| 33849 |
} else { |
| 33850 |
onReady(); |
| 33851 |
} |
| 33852 |
} |
| 33853 |
constructor(jodit, container, toWYSIWYG, fromWYSIWYG){ |
| 33854 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "jodit", void 0); |
| 33855 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "container", void 0); |
| 33856 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "toWYSIWYG", void 0); |
| 33857 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "fromWYSIWYG", void 0); |
| 33858 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "instance", void 0); |
| 33859 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "className", void 0); |
| 33860 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "isReady", void 0); |
| 33861 |
this.jodit = jodit; |
| 33862 |
this.container = container; |
| 33863 |
this.toWYSIWYG = toWYSIWYG; |
| 33864 |
this.fromWYSIWYG = fromWYSIWYG; |
| 33865 |
this.className = ''; |
| 33866 |
this.isReady = false; |
| 33867 |
} |
| 33868 |
} |
| 33869 |
|
| 33870 |
|
| 33871 |
/***/ }), |
| 33872 |
|
| 33873 |
/***/ 94561: |
| 33874 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 33875 |
|
| 33876 |
"use strict"; |
| 33877 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 33878 |
/* harmony export */ removeEmptyTextNode: function() { return /* binding */ removeEmptyTextNode; } |
| 33879 |
/* harmony export */ }); |
| 33880 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 33881 |
/*! |
| 33882 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 33883 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 33884 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 33885 |
*/ /** |
| 33886 |
* @module plugins/clean-html |
| 33887 |
*/ |
| 33888 |
/** |
| 33889 |
* @private |
| 33890 |
*/ function removeEmptyTextNode(jodit, node, hadEffect, arg, argi, currentNode) { |
| 33891 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isText(node) && !node.nodeValue) { |
| 33892 |
if (node === currentNode && jodit.s.isCollapsed()) { |
| 33893 |
jodit.s.setCursorAfter(node); |
| 33894 |
} |
| 33895 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(node); |
| 33896 |
return true; |
| 33897 |
} |
| 33898 |
return hadEffect; |
| 33899 |
} |
| 33900 |
|
| 33901 |
|
| 33902 |
/***/ }), |
| 33903 |
|
| 33904 |
/***/ 94806: |
| 33905 |
/***/ (function(module) { |
| 33906 |
|
| 33907 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"><path d=\"M640 768h512v-192q0-106-75-181t-181-75-181 75-75 181v192zm832 96v576q0 40-28 68t-68 28h-960q-40 0-68-28t-28-68v-576q0-40 28-68t68-28h32v-192q0-184 132-316t316-132 316 132 132 316v192h32q40 0 68 28t28 68z\"/></svg>" |
| 33908 |
|
| 33909 |
/***/ }), |
| 33910 |
|
| 33911 |
/***/ 94925: |
| 33912 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 33913 |
|
| 33914 |
"use strict"; |
| 33915 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 33916 |
/* harmony export */ Uploader: function() { return /* binding */ Uploader; } |
| 33917 |
/* harmony export */ }); |
| 33918 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 33919 |
/* harmony import */ var jodit_core_component___WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(16964); |
| 33920 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(81937); |
| 33921 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(65946); |
| 33922 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(5266); |
| 33923 |
/* harmony import */ var jodit_modules_uploader_helpers__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(11981); |
| 33924 |
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(40013); |
| 33925 |
/*! |
| 33926 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 33927 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 33928 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 33929 |
*/ /** |
| 33930 |
* [[include:modules/uploader/README.md]] |
| 33931 |
* @packageDocumentation |
| 33932 |
* @module modules/uploader |
| 33933 |
*/ |
| 33934 |
|
| 33935 |
|
| 33936 |
|
| 33937 |
|
| 33938 |
|
| 33939 |
|
| 33940 |
|
| 33941 |
class Uploader extends jodit_core_component___WEBPACK_IMPORTED_MODULE_1__.ViewComponent { |
| 33942 |
get j() { |
| 33943 |
return this.jodit; |
| 33944 |
} |
| 33945 |
/** @override */ className() { |
| 33946 |
return 'Uploader'; |
| 33947 |
} |
| 33948 |
get o() { |
| 33949 |
return this.options; |
| 33950 |
} |
| 33951 |
/** |
| 33952 |
* It sets the path for uploading files |
| 33953 |
*/ setPath(path) { |
| 33954 |
this.path = path; |
| 33955 |
return this; |
| 33956 |
} |
| 33957 |
/** |
| 33958 |
* It sets the source for connector |
| 33959 |
*/ setSource(source) { |
| 33960 |
this.source = source; |
| 33961 |
return this; |
| 33962 |
} |
| 33963 |
/** |
| 33964 |
* Set the handlers Drag and Drop to `$form` |
| 33965 |
* |
| 33966 |
* @param form - Form or any Node on which you can drag and drop the file. In addition will be processed |
| 33967 |
* <code><input type="file" ></code> |
| 33968 |
* @param handlerSuccess - The function be called when a successful uploading files |
| 33969 |
* to the server |
| 33970 |
* @param handlerError - The function that will be called during a failed download files a server |
| 33971 |
* @example |
| 33972 |
* ```javascript |
| 33973 |
* var $form = jQuery('<form><input type="text" typpe="file"></form>'); |
| 33974 |
* jQuery('body').append($form); |
| 33975 |
* Jodit.editors.someidfoeditor.uploader.bind($form[0], function (files) { |
| 33976 |
* var i; |
| 33977 |
* for (i = 0; i < data.files.length; i += 1) { |
| 33978 |
* parent.s.insertImage(data.files[i]) |
| 33979 |
* } |
| 33980 |
* }); |
| 33981 |
* ``` |
| 33982 |
*/ bind(form, handlerSuccess, handlerError) { |
| 33983 |
const onFinally = ()=>{ |
| 33984 |
form.classList.remove('jodit_drag_hover'); |
| 33985 |
}; |
| 33986 |
const self = this, onPaste = (e)=>{ |
| 33987 |
let i, file, extension; |
| 33988 |
const cData = e.clipboardData; |
| 33989 |
const processData = (formdata)=>{ |
| 33990 |
if (file) { |
| 33991 |
formdata.append('extension', extension); |
| 33992 |
formdata.append('mimetype', file.type); |
| 33993 |
} |
| 33994 |
}; |
| 33995 |
// send data on server |
| 33996 |
if (!jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.IS_IE && (0,jodit_modules_uploader_helpers__WEBPACK_IMPORTED_MODULE_5__.hasFiles)(cData)) { |
| 33997 |
(0,jodit_modules_uploader_helpers__WEBPACK_IMPORTED_MODULE_5__.sendFiles)(self, cData.files, handlerSuccess, handlerError).finally(onFinally); |
| 33998 |
return false; |
| 33999 |
} |
| 34000 |
if (jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.IS_IE && !jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.IS_ES_NEXT) { |
| 34001 |
return (0,jodit_modules_uploader_helpers__WEBPACK_IMPORTED_MODULE_5__.processOldBrowserDrag)(self, cData, handlerSuccess, handlerError, onFinally); |
| 34002 |
} |
| 34003 |
if ((0,jodit_modules_uploader_helpers__WEBPACK_IMPORTED_MODULE_5__.hasItems)(cData)) { |
| 34004 |
const { items } = cData; |
| 34005 |
for(i = 0; i < items.length; i += 1){ |
| 34006 |
if (items[i].kind === 'file' && items[i].type === 'image/png') { |
| 34007 |
file = items[i].getAsFile(); |
| 34008 |
if (file) { |
| 34009 |
const mime = file.type.match(/\/([a-z0-9]+)/i); |
| 34010 |
extension = mime[1] ? mime[1].toLowerCase() : ''; |
| 34011 |
(0,jodit_modules_uploader_helpers__WEBPACK_IMPORTED_MODULE_5__.sendFiles)(self, [ |
| 34012 |
file |
| 34013 |
], handlerSuccess, handlerError, processData).finally(onFinally); |
| 34014 |
} |
| 34015 |
e.preventDefault(); |
| 34016 |
break; |
| 34017 |
} |
| 34018 |
} |
| 34019 |
} |
| 34020 |
}; |
| 34021 |
if (self.j && self.j.editor !== form) { |
| 34022 |
self.j.e.on(form, 'paste', onPaste); |
| 34023 |
} else { |
| 34024 |
self.j.e.on('beforePaste', onPaste); |
| 34025 |
} |
| 34026 |
this.attachEvents(form, handlerSuccess, handlerError, onFinally); |
| 34027 |
} |
| 34028 |
attachEvents(form, handlerSuccess, handlerError, onFinally) { |
| 34029 |
const self = this; |
| 34030 |
self.j.e.on(form, 'dragend dragover dragenter dragleave drop', (e)=>{ |
| 34031 |
e.preventDefault(); |
| 34032 |
}).on(form, 'dragover', (event)=>{ |
| 34033 |
if ((0,jodit_modules_uploader_helpers__WEBPACK_IMPORTED_MODULE_5__.hasFiles)(event.dataTransfer) || (0,jodit_modules_uploader_helpers__WEBPACK_IMPORTED_MODULE_5__.hasItems)(event.dataTransfer)) { |
| 34034 |
form.classList.add('jodit_drag_hover'); |
| 34035 |
event.preventDefault(); |
| 34036 |
} |
| 34037 |
}).on(form, 'dragend dragleave', (event)=>{ |
| 34038 |
form.classList.remove('jodit_drag_hover'); |
| 34039 |
if ((0,jodit_modules_uploader_helpers__WEBPACK_IMPORTED_MODULE_5__.hasFiles)(event.dataTransfer)) { |
| 34040 |
event.preventDefault(); |
| 34041 |
} |
| 34042 |
}).on(form, 'drop', (event)=>{ |
| 34043 |
form.classList.remove('jodit_drag_hover'); |
| 34044 |
if ((0,jodit_modules_uploader_helpers__WEBPACK_IMPORTED_MODULE_5__.hasFiles)(event.dataTransfer)) { |
| 34045 |
event.preventDefault(); |
| 34046 |
event.stopImmediatePropagation(); |
| 34047 |
(0,jodit_modules_uploader_helpers__WEBPACK_IMPORTED_MODULE_5__.sendFiles)(self, event.dataTransfer.files, handlerSuccess, handlerError).finally(onFinally); |
| 34048 |
} |
| 34049 |
}); |
| 34050 |
const inputFile = form.querySelector('input[type=file]'); |
| 34051 |
if (inputFile) { |
| 34052 |
self.j.e.on(inputFile, 'change', ()=>{ |
| 34053 |
(0,jodit_modules_uploader_helpers__WEBPACK_IMPORTED_MODULE_5__.sendFiles)(self, inputFile.files, handlerSuccess, handlerError).then(()=>{ |
| 34054 |
inputFile.value = ''; |
| 34055 |
if (!/safari/i.test(navigator.userAgent)) { |
| 34056 |
inputFile.type = ''; |
| 34057 |
inputFile.type = 'file'; |
| 34058 |
} |
| 34059 |
}).finally(onFinally); |
| 34060 |
}); |
| 34061 |
} |
| 34062 |
} |
| 34063 |
/** |
| 34064 |
* Upload images to a server by its URL, making it through the connector server. |
| 34065 |
*/ uploadRemoteImage(url, handlerSuccess, handlerError) { |
| 34066 |
const uploader = this, { o } = uploader; |
| 34067 |
const handlerE = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.isFunction)(handlerError) ? handlerError : o.defaultHandlerError; |
| 34068 |
(0,jodit_modules_uploader_helpers__WEBPACK_IMPORTED_MODULE_5__.send)(uploader, { |
| 34069 |
action: 'fileUploadRemote', |
| 34070 |
url |
| 34071 |
}).then((resp)=>{ |
| 34072 |
if (o.isSuccess.call(uploader, resp)) { |
| 34073 |
const handler = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.isFunction)(handlerSuccess) ? handlerSuccess : o.defaultHandlerSuccess; |
| 34074 |
handler.call(uploader, o.process.call(uploader, resp)); |
| 34075 |
return; |
| 34076 |
} |
| 34077 |
handlerE.call(uploader, (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.error)(o.getMessage.call(uploader, resp))); |
| 34078 |
}).catch((e)=>handlerE.call(uploader, e)); |
| 34079 |
} |
| 34080 |
upload(files) { |
| 34081 |
return this.async.promise((resolve, reject)=>{ |
| 34082 |
(0,jodit_modules_uploader_helpers__WEBPACK_IMPORTED_MODULE_5__.sendFiles)(this, files, resolve, reject); |
| 34083 |
}); |
| 34084 |
} |
| 34085 |
destruct() { |
| 34086 |
this.setStatus(jodit_core_component___WEBPACK_IMPORTED_MODULE_1__.STATUSES.beforeDestruct); |
| 34087 |
const instances = jodit_modules_uploader_helpers__WEBPACK_IMPORTED_MODULE_5__.ajaxInstances.get(this); |
| 34088 |
if (instances) { |
| 34089 |
instances.forEach((ajax)=>{ |
| 34090 |
try { |
| 34091 |
ajax.destruct(); |
| 34092 |
} catch (unused) {} |
| 34093 |
}); |
| 34094 |
instances.clear(); |
| 34095 |
} |
| 34096 |
super.destruct(); |
| 34097 |
} |
| 34098 |
constructor(editor, options){ |
| 34099 |
super(editor), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "path", ''), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "source", 'default'), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "options", void 0); |
| 34100 |
this.options = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.ConfigProto)(options || {}, (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.ConfigProto)(jodit_config__WEBPACK_IMPORTED_MODULE_4__.Config.defaultOptions.uploader, (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.isJoditObject)(editor) ? editor.o.uploader : {})); |
| 34101 |
} |
| 34102 |
} |
| 34103 |
|
| 34104 |
|
| 34105 |
/***/ }), |
| 34106 |
|
| 34107 |
/***/ 94978: |
| 34108 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 34109 |
|
| 34110 |
"use strict"; |
| 34111 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 34112 |
/* harmony export */ AceEditor: function() { return /* binding */ AceEditor; } |
| 34113 |
/* harmony export */ }); |
| 34114 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 34115 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(81937); |
| 34116 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(65946); |
| 34117 |
/* harmony import */ var jodit_plugins_source_editor_sourceEditor__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(94193); |
| 34118 |
/*! |
| 34119 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 34120 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 34121 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 34122 |
*/ /** |
| 34123 |
* @module plugins/source |
| 34124 |
*/ |
| 34125 |
|
| 34126 |
|
| 34127 |
|
| 34128 |
class AceEditor extends jodit_plugins_source_editor_sourceEditor__WEBPACK_IMPORTED_MODULE_3__.SourceEditor { |
| 34129 |
aceExists() { |
| 34130 |
return this.j.ow.ace !== undefined; |
| 34131 |
} |
| 34132 |
getLastColumnIndex(row) { |
| 34133 |
return this.instance.session.getLine(row).length; |
| 34134 |
} |
| 34135 |
getLastColumnIndices() { |
| 34136 |
const rows = this.instance.session.getLength(); |
| 34137 |
const lastColumnIndices = []; |
| 34138 |
let lastColIndex = 0; |
| 34139 |
for(let i = 0; i < rows; i++){ |
| 34140 |
lastColIndex += this.getLastColumnIndex(i); |
| 34141 |
if (i > 0) { |
| 34142 |
lastColIndex += 1; |
| 34143 |
} |
| 34144 |
lastColumnIndices[i] = lastColIndex; |
| 34145 |
} |
| 34146 |
return lastColumnIndices; |
| 34147 |
} |
| 34148 |
getRowColumnIndices(characterIndex) { |
| 34149 |
const lastColumnIndices = this.getLastColumnIndices(); |
| 34150 |
if (characterIndex <= lastColumnIndices[0]) { |
| 34151 |
return { |
| 34152 |
row: 0, |
| 34153 |
column: characterIndex |
| 34154 |
}; |
| 34155 |
} |
| 34156 |
let row = 1; |
| 34157 |
for(let i = 1; i < lastColumnIndices.length; i++){ |
| 34158 |
if (characterIndex > lastColumnIndices[i]) { |
| 34159 |
row = i + 1; |
| 34160 |
} |
| 34161 |
} |
| 34162 |
const column = characterIndex - lastColumnIndices[row - 1] - 1; |
| 34163 |
return { |
| 34164 |
row, |
| 34165 |
column |
| 34166 |
}; |
| 34167 |
} |
| 34168 |
setSelectionRangeIndices(start, end) { |
| 34169 |
const startRowColumn = this.getRowColumnIndices(start); |
| 34170 |
const endRowColumn = this.getRowColumnIndices(end); |
| 34171 |
this.instance.getSelection().setSelectionRange({ |
| 34172 |
start: startRowColumn, |
| 34173 |
end: endRowColumn |
| 34174 |
}); |
| 34175 |
} |
| 34176 |
getIndexByRowColumn(row, column) { |
| 34177 |
const lastColumnIndices = this.getLastColumnIndices(); |
| 34178 |
return lastColumnIndices[row] - this.getLastColumnIndex(row) + column; |
| 34179 |
} |
| 34180 |
init(editor) { |
| 34181 |
const tryInitAceEditor = ()=>{ |
| 34182 |
if (this.instance !== undefined || !this.aceExists()) { |
| 34183 |
return; |
| 34184 |
} |
| 34185 |
const fakeMirror = this.j.c.div('jodit-source__mirror-fake'); |
| 34186 |
this.container.appendChild(fakeMirror); |
| 34187 |
const ace = editor.ow.ace; |
| 34188 |
this.instance = ace.edit(fakeMirror); |
| 34189 |
if (editor.o.direction === 'rtl') { |
| 34190 |
this.instance.setOption('rtlText', true); |
| 34191 |
this.instance.setOption('rtl', true); |
| 34192 |
} |
| 34193 |
this.instance.setTheme(editor.o.sourceEditorNativeOptions.theme); |
| 34194 |
this.instance.renderer.setShowGutter(editor.o.sourceEditorNativeOptions.showGutter); |
| 34195 |
this.instance.getSession().setMode(editor.o.sourceEditorNativeOptions.mode); |
| 34196 |
this.instance.setHighlightActiveLine(editor.o.sourceEditorNativeOptions.highlightActiveLine); |
| 34197 |
this.instance.getSession().setUseWrapMode(true); |
| 34198 |
this.instance.setOption('indentedSoftWrap', false); |
| 34199 |
this.instance.setOption('wrap', editor.o.sourceEditorNativeOptions.wrap); |
| 34200 |
this.instance.getSession().setUseWorker(false); |
| 34201 |
this.instance.$blockScrolling = Infinity; |
| 34202 |
this.instance.on('change', this.toWYSIWYG); |
| 34203 |
this.instance.on('focus', this.proxyOnFocus); |
| 34204 |
this.instance.on('mousedown', this.proxyOnMouseDown); |
| 34205 |
this.instance.on('blur', this.proxyOnBlur); |
| 34206 |
if (editor.getRealMode() !== jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.MODE_WYSIWYG) { |
| 34207 |
this.setValue(this.getValue()); |
| 34208 |
} |
| 34209 |
const onResize = this.j.async.throttle(()=>{ |
| 34210 |
if (editor.isInDestruct || editor.getMode() === jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.MODE_WYSIWYG) { |
| 34211 |
return; |
| 34212 |
} |
| 34213 |
const hasFocus = this.instance.isFocused(); |
| 34214 |
if (editor.o.height !== 'auto') { |
| 34215 |
this.instance.setOption('maxLines', editor.workplace.offsetHeight / this.instance.renderer.lineHeight); |
| 34216 |
} else { |
| 34217 |
this.instance.setOption('maxLines', Infinity); |
| 34218 |
} |
| 34219 |
this.instance.resize(); |
| 34220 |
hasFocus && this.focus(); |
| 34221 |
}, this.j.defaultTimeout * 2); |
| 34222 |
editor.e.on(editor, 'resize', onResize).on('afterResize afterSetMode', onResize); |
| 34223 |
onResize(); |
| 34224 |
this.onReady(); |
| 34225 |
}; |
| 34226 |
const initAceEditor = ()=>{ |
| 34227 |
if (editor.isInDestruct || editor.getRealMode() !== jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.MODE_SOURCE && editor.getMode() !== jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.MODE_SPLIT) { |
| 34228 |
return; |
| 34229 |
} |
| 34230 |
this.fromWYSIWYG(); |
| 34231 |
tryInitAceEditor(); |
| 34232 |
}; |
| 34233 |
editor.e.on('afterSetMode', initAceEditor); |
| 34234 |
initAceEditor(); |
| 34235 |
// global add ace editor in browser |
| 34236 |
if (!this.aceExists()) { |
| 34237 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_2__.loadNext)(editor, editor.o.sourceEditorCDNUrlsJS).then(initAceEditor).catch(()=>null); |
| 34238 |
} |
| 34239 |
} |
| 34240 |
destruct() { |
| 34241 |
var _this_j_events, _this_j; |
| 34242 |
this.instance.off('change', this.toWYSIWYG); |
| 34243 |
this.instance.off('focus', this.proxyOnFocus); |
| 34244 |
this.instance.off('mousedown', this.proxyOnMouseDown); |
| 34245 |
this.instance.destroy(); |
| 34246 |
(_this_j = this.j) === null || _this_j === void 0 ? void 0 : (_this_j_events = _this_j.events) === null || _this_j_events === void 0 ? void 0 : _this_j_events.off('aceInited.source'); |
| 34247 |
} |
| 34248 |
setValue(value) { |
| 34249 |
if (!this.j.o.editHTMLDocumentMode && this.j.o.beautifyHTML) { |
| 34250 |
const html = this.j.e.fire('beautifyHTML', value); |
| 34251 |
if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_2__.isString)(html)) { |
| 34252 |
value = html; |
| 34253 |
} |
| 34254 |
} |
| 34255 |
this.instance.setValue(value); |
| 34256 |
this.instance.clearSelection(); |
| 34257 |
} |
| 34258 |
getValue() { |
| 34259 |
return this.instance.getValue(); |
| 34260 |
} |
| 34261 |
setReadOnly(isReadOnly) { |
| 34262 |
this.instance.setReadOnly(isReadOnly); |
| 34263 |
} |
| 34264 |
get isFocused() { |
| 34265 |
return this.instance.isFocused(); |
| 34266 |
} |
| 34267 |
focus() { |
| 34268 |
this.instance.container.focus(); |
| 34269 |
this.instance.focus(); |
| 34270 |
} |
| 34271 |
blur() { |
| 34272 |
this.instance.blur(); |
| 34273 |
} |
| 34274 |
getSelectionStart() { |
| 34275 |
const range = this.instance.selection.getRange(); |
| 34276 |
return this.getIndexByRowColumn(range.start.row, range.start.column); |
| 34277 |
} |
| 34278 |
getSelectionEnd() { |
| 34279 |
const range = this.instance.selection.getRange(); |
| 34280 |
return this.getIndexByRowColumn(range.end.row, range.end.column); |
| 34281 |
} |
| 34282 |
selectAll() { |
| 34283 |
this.instance.selection.selectAll(); |
| 34284 |
} |
| 34285 |
insertRaw(html) { |
| 34286 |
const start = this.instance.selection.getCursor(), end = this.instance.session.insert(start, html); |
| 34287 |
this.instance.selection.setRange({ |
| 34288 |
start, |
| 34289 |
end |
| 34290 |
}, false); |
| 34291 |
} |
| 34292 |
setSelectionRange(start, end) { |
| 34293 |
this.setSelectionRangeIndices(start, end); |
| 34294 |
} |
| 34295 |
setPlaceHolder(title) { |
| 34296 |
// ACE does not support placeholder |
| 34297 |
// title |
| 34298 |
} |
| 34299 |
replaceUndoManager() { |
| 34300 |
const { history } = this.jodit; |
| 34301 |
this.instance.commands.addCommand({ |
| 34302 |
name: 'Undo', |
| 34303 |
bindKey: { |
| 34304 |
win: 'Ctrl-Z', |
| 34305 |
mac: 'Command-Z' |
| 34306 |
}, |
| 34307 |
exec: ()=>{ |
| 34308 |
history.undo(); |
| 34309 |
} |
| 34310 |
}); |
| 34311 |
this.instance.commands.addCommand({ |
| 34312 |
name: 'Redo', |
| 34313 |
bindKey: { |
| 34314 |
win: 'Ctrl-Shift-Z', |
| 34315 |
mac: 'Command-Shift-Z' |
| 34316 |
}, |
| 34317 |
exec: ()=>{ |
| 34318 |
history.redo(); |
| 34319 |
} |
| 34320 |
}); |
| 34321 |
} |
| 34322 |
constructor(...args){ |
| 34323 |
super(...args), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "className", 'jodit_ace_editor'), /** |
| 34324 |
* Proxy Method |
| 34325 |
*/ (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "proxyOnBlur", (e)=>{ |
| 34326 |
this.j.e.fire('blur', e); |
| 34327 |
}), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "proxyOnFocus", (e)=>{ |
| 34328 |
this.j.e.fire('focus', e); |
| 34329 |
}), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "proxyOnMouseDown", (e)=>{ |
| 34330 |
this.j.e.fire('mousedown', e); |
| 34331 |
}); |
| 34332 |
} |
| 34333 |
} |
| 34334 |
|
| 34335 |
|
| 34336 |
/***/ }), |
| 34337 |
|
| 34338 |
/***/ 95032: |
| 34339 |
/***/ (function(module) { |
| 34340 |
|
| 34341 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M1520 1216q0-40-28-68l-208-208q-28-28-68-28-42 0-72 32 3 3 19 18.5t21.5 21.5 15 19 13 25.5 3.5 27.5q0 40-28 68t-68 28q-15 0-27.5-3.5t-25.5-13-19-15-21.5-21.5-18.5-19q-33 31-33 73 0 40 28 68l206 207q27 27 68 27 40 0 68-26l147-146q28-28 28-67zm-703-705q0-40-28-68l-206-207q-28-28-68-28-39 0-68 27l-147 146q-28 28-28 67 0 40 28 68l208 208q27 27 68 27 42 0 72-31-3-3-19-18.5t-21.5-21.5-15-19-13-25.5-3.5-27.5q0-40 28-68t68-28q15 0 27.5 3.5t25.5 13 19 15 21.5 21.5 18.5 19q33-31 33-73zm895 705q0 120-85 203l-147 146q-83 83-203 83-121 0-204-85l-206-207q-83-83-83-203 0-123 88-209l-88-88q-86 88-208 88-120 0-204-84l-208-208q-84-84-84-204t85-203l147-146q83-83 203-83 121 0 204 85l206 207q83 83 83 203 0 123-88 209l88 88q86-88 208-88 120 0 204 84l208 208q84 84 84 204z\"/> </svg>" |
| 34342 |
|
| 34343 |
/***/ }), |
| 34344 |
|
| 34345 |
/***/ 95134: |
| 34346 |
/***/ (function(module) { |
| 34347 |
|
| 34348 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M1664 960q-152-236-381-353 61 104 61 225 0 185-131.5 316.5t-316.5 131.5-316.5-131.5-131.5-316.5q0-121 61-225-229 117-381 353 133 205 333.5 326.5t434.5 121.5 434.5-121.5 333.5-326.5zm-720-384q0-20-14-34t-34-14q-125 0-214.5 89.5t-89.5 214.5q0 20 14 34t34 14 34-14 14-34q0-86 61-147t147-61q20 0 34-14t14-34zm848 384q0 34-20 69-140 230-376.5 368.5t-499.5 138.5-499.5-139-376.5-368q-20-35-20-69t20-69q140-229 376.5-368t499.5-139 499.5 139 376.5 368q20 35 20 69z\"/> </svg>" |
| 34349 |
|
| 34350 |
/***/ }), |
| 34351 |
|
| 34352 |
/***/ 95399: |
| 34353 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 34354 |
|
| 34355 |
"use strict"; |
| 34356 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 34357 |
/* harmony export */ UITooltip: function() { return /* binding */ UITooltip; } |
| 34358 |
/* harmony export */ }); |
| 34359 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 34360 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 34361 |
/* harmony import */ var jodit_core_component__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(16964); |
| 34362 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(84839); |
| 34363 |
/* harmony import */ var jodit_core_dom__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(27795); |
| 34364 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(28077); |
| 34365 |
/* harmony import */ var jodit_core_helpers_size_position__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(23599); |
| 34366 |
/* harmony import */ var jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(93640); |
| 34367 |
/* harmony import */ var jodit_core_ui_element__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(96007); |
| 34368 |
/*! |
| 34369 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 34370 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 34371 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 34372 |
*/ /** |
| 34373 |
* [[include:core/ui/button/tooltip/README.md]] |
| 34374 |
* @packageDocumentation |
| 34375 |
* @module ui/button |
| 34376 |
*/ |
| 34377 |
|
| 34378 |
|
| 34379 |
|
| 34380 |
|
| 34381 |
|
| 34382 |
|
| 34383 |
|
| 34384 |
|
| 34385 |
|
| 34386 |
const WINDOW_EVENTS_ON_HIDE = [ |
| 34387 |
'scroll.tooltip', |
| 34388 |
'joditCloseDialog', |
| 34389 |
'mouseleave.tooltip' |
| 34390 |
]; |
| 34391 |
const JODIT_EVENTS_ON_HIDE = [ |
| 34392 |
'escape.tooltip', |
| 34393 |
'change.tooltip', |
| 34394 |
'changePlace.tooltip', |
| 34395 |
'afterOpenPopup.tooltip', |
| 34396 |
'hidePopup.tooltip', |
| 34397 |
'beforePopupClose.tooltip', |
| 34398 |
'closeAllPopups.tooltip' |
| 34399 |
]; |
| 34400 |
class UITooltip extends jodit_core_ui_element__WEBPACK_IMPORTED_MODULE_8__.UIElement { |
| 34401 |
className() { |
| 34402 |
return 'UITooltip'; |
| 34403 |
} |
| 34404 |
render() { |
| 34405 |
return '<div><div class="&__content"></div></div>'; |
| 34406 |
} |
| 34407 |
__onAttach(container) { |
| 34408 |
// TODO Move it inside __show method. Now it is here because testcase failed with capturing |
| 34409 |
(0,jodit_core_global__WEBPACK_IMPORTED_MODULE_5__.getContainer)(this.j, UITooltip).appendChild(this.container); |
| 34410 |
this.__attachedContainers.add(container); |
| 34411 |
this.__attachedContainers.add(this.j.container); |
| 34412 |
this.j.e.on(container, 'mouseenter.tooltip', this.__onMouseEnter, { |
| 34413 |
capture: true |
| 34414 |
}).on(container, 'mouseleave.tooltip', this.__onMouseLeave, { |
| 34415 |
capture: true |
| 34416 |
}).on(this.j.container, 'mouseleave.tooltip', this.__onMouseLeave, { |
| 34417 |
capture: true |
| 34418 |
}); |
| 34419 |
} |
| 34420 |
__addListenersOnEnter() { |
| 34421 |
if (this.__listenClose) { |
| 34422 |
return; |
| 34423 |
} |
| 34424 |
this.__listenClose = true; |
| 34425 |
const view = this.j; |
| 34426 |
view.e.on(view.ow, WINDOW_EVENTS_ON_HIDE, this.__hide).on(JODIT_EVENTS_ON_HIDE, this.__hide); |
| 34427 |
} |
| 34428 |
__removeListenersOnLeave() { |
| 34429 |
if (!this.__listenClose) { |
| 34430 |
return; |
| 34431 |
} |
| 34432 |
this.__listenClose = false; |
| 34433 |
const view = this.j; |
| 34434 |
view.e.off(view.ow, WINDOW_EVENTS_ON_HIDE, this.__hide).off(JODIT_EVENTS_ON_HIDE, this.__hide); |
| 34435 |
} |
| 34436 |
__onMouseLeave(e) { |
| 34437 |
if (this.__currentTarget === e.target) { |
| 34438 |
this.__hideDelay(); |
| 34439 |
this.__currentTarget = null; |
| 34440 |
} |
| 34441 |
} |
| 34442 |
__onMouseEnter(e) { |
| 34443 |
if (!jodit_core_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isHTMLElement(e.target)) { |
| 34444 |
return; |
| 34445 |
} |
| 34446 |
const tooltip = (0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_7__.attr)(e.target, 'aria-label'); |
| 34447 |
if (!tooltip) { |
| 34448 |
return; |
| 34449 |
} |
| 34450 |
const disabled = Boolean((0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_7__.attr)(e.target, 'disabled')); |
| 34451 |
if (disabled) { |
| 34452 |
return; |
| 34453 |
} |
| 34454 |
const isOwn = e.target.className.includes('jodit'); |
| 34455 |
if (!isOwn) { |
| 34456 |
return; |
| 34457 |
} |
| 34458 |
this.__currentTarget = e.target; |
| 34459 |
const target = e.target; |
| 34460 |
this.__open(()=>{ |
| 34461 |
const pos = (0,jodit_core_helpers_size_position__WEBPACK_IMPORTED_MODULE_6__.position)(target); |
| 34462 |
return { |
| 34463 |
x: pos.left + pos.width / 2, |
| 34464 |
y: pos.top + pos.height |
| 34465 |
}; |
| 34466 |
}, tooltip); |
| 34467 |
} |
| 34468 |
__open(getPoint, content) { |
| 34469 |
this.__addListenersOnEnter(); |
| 34470 |
this.__isOpened = true; |
| 34471 |
this.j.async.clearTimeout(this.__hideTimeout); |
| 34472 |
this.j.async.clearTimeout(this.__delayShowTimeout); |
| 34473 |
const to = this.j.o.showTooltipDelay || this.j.defaultTimeout; |
| 34474 |
if (!to) { |
| 34475 |
this.__show(getPoint, content); |
| 34476 |
return; |
| 34477 |
} |
| 34478 |
this.__delayShowTimeout = this.j.async.setTimeout(()=>this.__show(getPoint, content), to); |
| 34479 |
} |
| 34480 |
__show(getPoint, content) { |
| 34481 |
this.setMod('visible', true); |
| 34482 |
this.getElm('content').innerHTML = content; |
| 34483 |
const point = getPoint(); |
| 34484 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_7__.css)(this.container, { |
| 34485 |
left: point.x, |
| 34486 |
top: point.y |
| 34487 |
}); |
| 34488 |
} |
| 34489 |
__hide() { |
| 34490 |
this.j.async.clearTimeout(this.__delayShowTimeout); |
| 34491 |
this.j.async.clearTimeout(this.__hideTimeout); |
| 34492 |
this.__removeListenersOnLeave(); |
| 34493 |
if (this.__isOpened) { |
| 34494 |
this.__isOpened = false; |
| 34495 |
this.setMod('visible', false); |
| 34496 |
this.getElm('content').innerHTML = ''; |
| 34497 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_7__.css)(this.container, { |
| 34498 |
left: -5000 |
| 34499 |
}); |
| 34500 |
} |
| 34501 |
} |
| 34502 |
__hideDelay() { |
| 34503 |
this.j.async.clearTimeout(this.__delayShowTimeout); |
| 34504 |
this.j.async.clearTimeout(this.__hideTimeout); |
| 34505 |
if (!this.__isOpened) { |
| 34506 |
return; |
| 34507 |
} |
| 34508 |
this.__hideTimeout = this.async.setTimeout(this.__hide, this.j.defaultTimeout); |
| 34509 |
} |
| 34510 |
destruct() { |
| 34511 |
this.__attachedContainers.forEach((container)=>{ |
| 34512 |
this.j.e.off(container, 'mouseenter.tooltip', this.__onMouseEnter).off(container, 'mouseleave.tooltip', this.__onMouseLeave); |
| 34513 |
}); |
| 34514 |
this.__hide(); |
| 34515 |
super.destruct(); |
| 34516 |
} |
| 34517 |
constructor(view){ |
| 34518 |
super(view), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__isOpened", false), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__attachedContainers", new Set()), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__listenClose", false), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__currentTarget", null), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__delayShowTimeout", 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__hideTimeout", 0); |
| 34519 |
if (!view.o.textIcons && view.o.showTooltip && !view.o.useNativeTooltip) { |
| 34520 |
this.j.e.on('getContainer', (box)=>{ |
| 34521 |
this.__onAttach(box); |
| 34522 |
}); |
| 34523 |
view.hookStatus(jodit_core_component__WEBPACK_IMPORTED_MODULE_2__.STATUSES.ready, ()=>{ |
| 34524 |
this.__onAttach(this.j.container); |
| 34525 |
}); |
| 34526 |
} |
| 34527 |
} |
| 34528 |
} |
| 34529 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 34530 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 34531 |
], UITooltip.prototype, "__onMouseLeave", null); |
| 34532 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 34533 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 34534 |
], UITooltip.prototype, "__onMouseEnter", null); |
| 34535 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 34536 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 34537 |
], UITooltip.prototype, "__hide", null); |
| 34538 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 34539 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 34540 |
], UITooltip.prototype, "__hideDelay", null); |
| 34541 |
UITooltip = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 34542 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.component |
| 34543 |
], UITooltip); |
| 34544 |
|
| 34545 |
|
| 34546 |
/***/ }), |
| 34547 |
|
| 34548 |
/***/ 95436: |
| 34549 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 34550 |
|
| 34551 |
"use strict"; |
| 34552 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 34553 |
/* harmony export */ processOldBrowserDrag: function() { return /* binding */ processOldBrowserDrag; } |
| 34554 |
/* harmony export */ }); |
| 34555 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 34556 |
/* harmony import */ var jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(27795); |
| 34557 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(28077); |
| 34558 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(65946); |
| 34559 |
/* harmony import */ var _data_uri_to_blob__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(23112); |
| 34560 |
/* harmony import */ var _send_files__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(46533); |
| 34561 |
/*! |
| 34562 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 34563 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 34564 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 34565 |
*/ /** |
| 34566 |
* @module modules/uploader |
| 34567 |
*/ |
| 34568 |
|
| 34569 |
|
| 34570 |
|
| 34571 |
|
| 34572 |
|
| 34573 |
function processOldBrowserDrag(self, cData, handlerSuccess, handlerError, onFinally) { |
| 34574 |
if (cData && (!cData.types.length || cData.types[0] !== jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.TEXT_PLAIN)) { |
| 34575 |
const div = self.j.c.div('', { |
| 34576 |
tabindex: -1, |
| 34577 |
style: 'left: -9999px; top: 0; width: 0; height: 100%;line-height: 140%; ' + 'overflow: hidden; position: fixed; z-index: 2147483647; word-break: break-all;', |
| 34578 |
contenteditable: true |
| 34579 |
}); |
| 34580 |
(0,jodit_core_global__WEBPACK_IMPORTED_MODULE_2__.getContainer)(self.j, self.constructor).appendChild(div); |
| 34581 |
const selection = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.isJoditObject)(self.j) ? self.j.s.save() : null, restore = ()=>selection && (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.isJoditObject)(self.j) && self.j.s.restore(); |
| 34582 |
div.focus(); |
| 34583 |
self.j.async.setTimeout(()=>{ |
| 34584 |
const child = div.firstChild; |
| 34585 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__.Dom.safeRemove(div); |
| 34586 |
if (child && child.hasAttribute('src')) { |
| 34587 |
const src = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.attr)(child, 'src') || ''; |
| 34588 |
restore(); |
| 34589 |
(0,_send_files__WEBPACK_IMPORTED_MODULE_5__.sendFiles)(self, [ |
| 34590 |
(0,_data_uri_to_blob__WEBPACK_IMPORTED_MODULE_4__.dataURItoBlob)(src) |
| 34591 |
], handlerSuccess, handlerError).finally(onFinally); |
| 34592 |
} |
| 34593 |
}, self.j.defaultTimeout); |
| 34594 |
} |
| 34595 |
} |
| 34596 |
|
| 34597 |
|
| 34598 |
/***/ }), |
| 34599 |
|
| 34600 |
/***/ 95461: |
| 34601 |
/***/ (function(module) { |
| 34602 |
|
| 34603 |
module.exports["default"] = ["Bitte geben Sie einen Text ein","Über Jodit","Jodit Editor","Das Jodit Benutzerhandbuch","beinhaltet ausführliche Informationen wie Sie den Editor verwenden können.","Für Informationen zur Lizenz, besuchen Sie bitte unsere Web-Präsenz:","Vollversion kaufen","Copyright © XDSoft.net - Chupurnov Valeriy. Alle Rechte vorbehalten.","Anker","In neuer Registerkarte öffnen","Editor in voller Größe öffnen","Formatierung löschen","Füllfarbe oder Textfarbe ändern","Wiederholen","Rückgängig machen","Fett","Kursiv","Unsortierte Liste einfügen","Nummerierte Liste einfügen","Mittig ausrichten","Blocksatz","Links ausrichten","Rechts ausrichten","Horizontale Linie einfügen","Bild einfügen","Datei einfügen","Youtube/vimeo Video einfügen","Link einfügen","Schriftgröße","Schriftfamilie","Formatblock einfügen","Normal","Überschrift 1","Überschrift 2","Überschrift 3","Überschrift 4","Zitat","Code","Einfügen","Tabelle einfügen","Einzug verkleinern","Einzug vergrößern","Sonderzeichen auswählen","Sonderzeichen einfügen","Format kopieren","Änderungsmodus","Ränder","Oben","Rechts","Unten","Links","CSS Stil","CSS Klassen","Ausrichtung","Rechts","Zentriert","Links","Keine","Pfad","Titel","Alternativer Text","Link","Link in neuem Tab öffnen","Bild","Datei","Fortgeschritten","Bildeigenschaften","Abbrechen","OK","Dateibrowser","Fehler beim Laden der Liste","Fehler beim Laden der Ordner","Sind Sie sicher?","Geben Sie den Verzeichnisnamen ein","Verzeichnis erstellen","Typname","Bild hier hinziehen","Datei löschen","oder hier klicken","Alternativtext","Hochladen","Auswählen","Hintergrund","Text","Oben","Mittig","Unten","Spalte davor einfügen","Spalte danach einfügen","Zeile oberhalb einfügen","Zeile unterhalb einfügen","Tabelle löschen","Zeile löschen","Spalte löschen","Zelle leeren","Zeichen: %d","Wörter: %d","Durchstreichen","Unterstreichen","Hochstellen","Tiefstellen","Auswahl ausschneiden","Alles markieren","Pause","Suche nach","Ersetzen durch","Ersetzen","Einfügen","Wählen Sie den Inhalt zum Einfügen aus","HTML","Fett gedruckt","Kursiv","Bürste","Verknüpfung","Rückgängig machen","Wiederholen","Tabelle","Bild","Radiergummi","Absatz","Schriftgröße","Video","Schriftart","Über","Drucken","Unterstreichen","Durchstreichen","Einzug","Herausstellen","Vollgröße","Schrumpfen","die Linie","Liste von","Nummerierte Liste","Schneiden","Wählen Sie Alle aus","Code einbetten","Link öffnen","Link bearbeiten","Nofollow-Attribut","Link entfernen","Aktualisieren","Bearbeiten","Ansehen","URL","Bearbeiten","Horizontale Ausrichtung","Filter","Sortieren nach geändert","Nach Name sortieren","Nach Größe sortiert","Ordner hinzufügen","Wiederherstellen","Speichern","Speichern als","Größe ändern","Größe anpassen","Breite","Höhe","Seitenverhältnis beibehalten","Ja","Nein","Entfernen","Markieren","Markieren: %s","Vertikale Ausrichtung","Unterteilen","Vereinen","Spalte hinzufügen","Zeile hinzufügen","Lizenz: %s","Löschen","Vertikal unterteilen","Horizontal unterteilen","Rand","Ihr Text ähnelt HTML-Code. Als HTML beibehalten?","Als HTML einfügen?","Original speichern","Als Text einfügen","Nur Text einfügen","Sie können nur Ihre eigenen Bilder bearbeiten. Dieses Bild auf den Host herunterladen?","Das Bild wurde erfolgreich auf den Server hochgeladen!","Palette","In diesem Verzeichnis befinden sich keine Dateien.","Umbenennen","Geben Sie einen neuen Namen ein","Vorschau","Herunterladen","Aus Zwischenablage einfügen","Ihr Browser unterstützt keinen direkten Zugriff auf die Zwischenablage.","Auswahl kopieren","Kopieren","Radius für abgerundete Ecken","Alle anzeigen","Anwenden","Bitte füllen Sie dieses Feld aus","Bitte geben Sie eine Web-Adresse ein","Standard","Kreis","Punkte","Quadrate","Suchen","Suche vorherige","Weitersuchen","Der Inhalt, den Sie einfügen, stammt aus einem Microsoft Word / Excel-Dokument. Möchten Sie das Format erhalten oder bereinigen?","In Word formatierter Text erkannt","Säubern","className (CSS) einfügen","Drücken Sie Alt für benutzerdefinierte Größenanpassung",null,null,null,"Alles markieren"] |
| 34604 |
|
| 34605 |
/***/ }), |
| 34606 |
|
| 34607 |
/***/ 95559: |
| 34608 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 34609 |
|
| 34610 |
"use strict"; |
| 34611 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 34612 |
/* harmony export */ allowAttributes: function() { return /* binding */ allowAttributes; } |
| 34613 |
/* harmony export */ }); |
| 34614 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 34615 |
/*! |
| 34616 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 34617 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 34618 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 34619 |
*/ /** |
| 34620 |
* @module plugins/clean-html |
| 34621 |
*/ |
| 34622 |
/** |
| 34623 |
* @private |
| 34624 |
*/ function allowAttributes(jodit, nodeElm, hadEffect, allow) { |
| 34625 |
if (allow && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isElement(nodeElm) && allow[nodeElm.nodeName] !== true) { |
| 34626 |
const attrs = nodeElm.attributes; |
| 34627 |
if (attrs && attrs.length) { |
| 34628 |
const removeAttrs = []; |
| 34629 |
for(let i = 0; i < attrs.length; i += 1){ |
| 34630 |
const attr = allow[nodeElm.nodeName][attrs[i].name]; |
| 34631 |
if (!attr || attr !== true && attr !== attrs[i].value) { |
| 34632 |
removeAttrs.push(attrs[i].name); |
| 34633 |
} |
| 34634 |
} |
| 34635 |
if (removeAttrs.length) { |
| 34636 |
hadEffect = true; |
| 34637 |
} |
| 34638 |
removeAttrs.forEach((attr)=>{ |
| 34639 |
nodeElm.removeAttribute(attr); |
| 34640 |
}); |
| 34641 |
} |
| 34642 |
} |
| 34643 |
return hadEffect; |
| 34644 |
} |
| 34645 |
|
| 34646 |
|
| 34647 |
/***/ }), |
| 34648 |
|
| 34649 |
/***/ 95971: |
| 34650 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 34651 |
|
| 34652 |
"use strict"; |
| 34653 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 34654 |
/* harmony export */ elementsEqualAttributes: function() { return /* binding */ elementsEqualAttributes; }, |
| 34655 |
/* harmony export */ isSameAttributes: function() { return /* binding */ isSameAttributes; } |
| 34656 |
/* harmony export */ }); |
| 34657 |
/* harmony import */ var jodit_core_helpers_size_object_size__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(18073); |
| 34658 |
/* harmony import */ var jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(93640); |
| 34659 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(28712); |
| 34660 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_2__); |
| 34661 |
/* harmony import */ var _has_same_style__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(9703); |
| 34662 |
/*! |
| 34663 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 34664 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 34665 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 34666 |
*/ |
| 34667 |
|
| 34668 |
|
| 34669 |
|
| 34670 |
/** |
| 34671 |
* Compares whether the given attributes match the element's own attributes |
| 34672 |
* @private |
| 34673 |
*/ function isSameAttributes(elm, attrs) { |
| 34674 |
if (!elm.attributes.length && !(0,jodit_core_helpers_size_object_size__WEBPACK_IMPORTED_MODULE_0__.size)(attrs)) { |
| 34675 |
return true; |
| 34676 |
} |
| 34677 |
if (!(0,jodit_core_helpers_size_object_size__WEBPACK_IMPORTED_MODULE_0__.size)(attrs)) { |
| 34678 |
return true; |
| 34679 |
} |
| 34680 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_2__.assert)(attrs, 'Attrs must be a non-empty object'); |
| 34681 |
return Object.keys(attrs).every((key)=>{ |
| 34682 |
if (key === 'class' || key === 'className') { |
| 34683 |
return elm.classList.contains(attrs[key]); |
| 34684 |
} |
| 34685 |
if (key === 'style') { |
| 34686 |
return (0,_has_same_style__WEBPACK_IMPORTED_MODULE_3__.hasSameStyle)(elm, attrs[key]); |
| 34687 |
} |
| 34688 |
return (0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_1__.attr)(elm, key) === attrs[key]; |
| 34689 |
}); |
| 34690 |
} |
| 34691 |
function elementsEqualAttributes(elm1, elm2) { |
| 34692 |
return elm1.attributes.length === elm2.attributes.length && Array.from(elm1.attributes).every((attr)=>elm2.hasAttribute(attr.name) && elm2.getAttribute(attr.name) === attr.value); |
| 34693 |
} |
| 34694 |
|
| 34695 |
|
| 34696 |
/***/ }), |
| 34697 |
|
| 34698 |
/***/ 96007: |
| 34699 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 34700 |
|
| 34701 |
"use strict"; |
| 34702 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 34703 |
/* harmony export */ UIElement: function() { return /* binding */ UIElement; } |
| 34704 |
/* harmony export */ }); |
| 34705 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 34706 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 34707 |
/* harmony import */ var jodit_core_component__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(16964); |
| 34708 |
/* harmony import */ var jodit_core_decorators_derive_derive__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(24968); |
| 34709 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(23211); |
| 34710 |
/* harmony import */ var jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(85932); |
| 34711 |
/* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(7909); |
| 34712 |
/* harmony import */ var jodit_core_traits_elms__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(23183); |
| 34713 |
/* harmony import */ var jodit_core_traits_mods__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(81987); |
| 34714 |
/* harmony import */ var jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(29434); |
| 34715 |
/*! |
| 34716 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 34717 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 34718 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 34719 |
*/ /** |
| 34720 |
* @module ui |
| 34721 |
*/ |
| 34722 |
|
| 34723 |
|
| 34724 |
|
| 34725 |
|
| 34726 |
|
| 34727 |
|
| 34728 |
|
| 34729 |
|
| 34730 |
|
| 34731 |
class UIElement extends jodit_core_component__WEBPACK_IMPORTED_MODULE_2__.ViewComponent { |
| 34732 |
getRole() { |
| 34733 |
var _this_options; |
| 34734 |
return ((_this_options = this.options) === null || _this_options === void 0 ? void 0 : _this_options.role) || ''; |
| 34735 |
} |
| 34736 |
get parentElement() { |
| 34737 |
return this.__parentElement; |
| 34738 |
} |
| 34739 |
set parentElement(parentElement) { |
| 34740 |
this.__parentElement = parentElement; |
| 34741 |
if (parentElement) { |
| 34742 |
parentElement.hookStatus('beforeDestruct', ()=>this.destruct()); |
| 34743 |
} |
| 34744 |
this.updateParentElement(this); |
| 34745 |
} |
| 34746 |
bubble(callback) { |
| 34747 |
let parent = this.parentElement; |
| 34748 |
while(parent){ |
| 34749 |
callback(parent); |
| 34750 |
parent = parent.parentElement; |
| 34751 |
} |
| 34752 |
return this; |
| 34753 |
} |
| 34754 |
updateParentElement(target) { |
| 34755 |
var _this___parentElement; |
| 34756 |
(_this___parentElement = this.__parentElement) === null || _this___parentElement === void 0 ? void 0 : _this___parentElement.updateParentElement(target); |
| 34757 |
return this; |
| 34758 |
} |
| 34759 |
/** @override */ get(chain, obj) { |
| 34760 |
return super.get(chain, obj) || this.getElm(chain); |
| 34761 |
} |
| 34762 |
/** |
| 34763 |
* Find match parent |
| 34764 |
*/ closest(type) { |
| 34765 |
const c = typeof type === 'object' ? (pe)=>pe === type : (pe)=>jodit_core_component__WEBPACK_IMPORTED_MODULE_2__.Component.isInstanceOf(pe, type); |
| 34766 |
let pe = this.__parentElement; |
| 34767 |
while(pe){ |
| 34768 |
if (c(pe)) { |
| 34769 |
return pe; |
| 34770 |
} |
| 34771 |
if (!pe.parentElement && pe.container.parentElement) { |
| 34772 |
pe = UIElement.closestElement(pe.container.parentElement, UIElement); |
| 34773 |
} else { |
| 34774 |
pe = pe.parentElement; |
| 34775 |
} |
| 34776 |
} |
| 34777 |
return null; |
| 34778 |
} |
| 34779 |
/** |
| 34780 |
* Find closest UIElement in DOM |
| 34781 |
*/ static closestElement(node, type) { |
| 34782 |
const elm = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.up(node, (elm)=>{ |
| 34783 |
if (elm) { |
| 34784 |
const { component } = elm; |
| 34785 |
return component && jodit_core_component__WEBPACK_IMPORTED_MODULE_2__.Component.isInstanceOf(component, type); |
| 34786 |
} |
| 34787 |
return false; |
| 34788 |
}); |
| 34789 |
return elm ? elm === null || elm === void 0 ? void 0 : elm.component : null; |
| 34790 |
} |
| 34791 |
/** |
| 34792 |
* Update UI from state |
| 34793 |
*/ update() { |
| 34794 |
// empty |
| 34795 |
} |
| 34796 |
/** |
| 34797 |
* Append container to element |
| 34798 |
*/ appendTo(element) { |
| 34799 |
element.appendChild(this.container); |
| 34800 |
return this; |
| 34801 |
} |
| 34802 |
/** |
| 34803 |
* Valid name only with valid chars |
| 34804 |
*/ clearName(name) { |
| 34805 |
return name.replace(/[^a-zA-Z0-9]/g, '_'); |
| 34806 |
} |
| 34807 |
/** |
| 34808 |
* Method create only box |
| 34809 |
*/ render(options) { |
| 34810 |
return this.j.c.div(this.componentName); |
| 34811 |
} |
| 34812 |
/** |
| 34813 |
* Create main HTML container |
| 34814 |
*/ createContainer(options) { |
| 34815 |
const result = this.render(options); |
| 34816 |
if ((0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_5__.isString)(result)) { |
| 34817 |
const elm = this.parseTemplate(result); |
| 34818 |
elm.classList.add(this.componentName); |
| 34819 |
return elm; |
| 34820 |
} |
| 34821 |
return result; |
| 34822 |
} |
| 34823 |
parseTemplate(result) { |
| 34824 |
return this.j.c.fromHTML(result.replace(/\*([^*]+?)\*/g, (_, name)=>jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_9__.Icon.get(name) || '').replace(/&_/g, this.componentName + '_').replace(/~([^~]+?)~/g, (_, s)=>this.i18n(s))); |
| 34825 |
} |
| 34826 |
/** @override */ destruct() { |
| 34827 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeRemove(this.container); |
| 34828 |
this.parentElement = null; |
| 34829 |
return super.destruct(); |
| 34830 |
} |
| 34831 |
constructor(jodit, options){ |
| 34832 |
super(jodit), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "container", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "name", ''), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "options", void 0), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "__parentElement", null), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "mods", {}); |
| 34833 |
this.options = options; |
| 34834 |
this.container = this.createContainer(options); |
| 34835 |
const role = this.getRole(); |
| 34836 |
role && (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_6__.attr)(this.container, 'role', role); |
| 34837 |
Object.defineProperty(this.container, 'component', { |
| 34838 |
value: this, |
| 34839 |
configurable: true |
| 34840 |
}); |
| 34841 |
} |
| 34842 |
} |
| 34843 |
UIElement = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 34844 |
(0,jodit_core_decorators_derive_derive__WEBPACK_IMPORTED_MODULE_3__.derive)(jodit_core_traits_mods__WEBPACK_IMPORTED_MODULE_8__.Mods, jodit_core_traits_elms__WEBPACK_IMPORTED_MODULE_7__.Elms) |
| 34845 |
], UIElement); |
| 34846 |
|
| 34847 |
|
| 34848 |
/***/ }), |
| 34849 |
|
| 34850 |
/***/ 96127: |
| 34851 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 34852 |
|
| 34853 |
"use strict"; |
| 34854 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 34855 |
/* harmony export */ ApplyStyle: function() { return /* binding */ ApplyStyle; } |
| 34856 |
/* harmony export */ }); |
| 34857 |
/* harmony import */ var _api__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(51640); |
| 34858 |
/* harmony import */ var _constants__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(98394); |
| 34859 |
/* harmony import */ var _transactions__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(78462); |
| 34860 |
/*! |
| 34861 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 34862 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 34863 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 34864 |
*/ /** |
| 34865 |
* @module selection |
| 34866 |
*/ |
| 34867 |
|
| 34868 |
|
| 34869 |
/** @internal */ function ApplyStyle(jodit, cs) { |
| 34870 |
var // sel.save(); |
| 34871 |
_editor_firstChild; |
| 34872 |
const { s: sel, editor } = jodit; |
| 34873 |
(_editor_firstChild = editor.firstChild) === null || _editor_firstChild === void 0 ? void 0 : _editor_firstChild.normalize(); // FF fix for test "commandsTest - Exec command "bold" |
| 34874 |
const fakes = sel.fakes(); |
| 34875 |
const gen = jodit.s.wrapInTagGen(fakes); |
| 34876 |
let font = gen.next(); |
| 34877 |
if (font.done) { |
| 34878 |
return; |
| 34879 |
} |
| 34880 |
let state = { |
| 34881 |
collapsed: sel.isCollapsed(), |
| 34882 |
mode: _constants__WEBPACK_IMPORTED_MODULE_1__.INITIAL, |
| 34883 |
element: font.value, |
| 34884 |
next: _transactions__WEBPACK_IMPORTED_MODULE_2__.states.START, |
| 34885 |
jodit, |
| 34886 |
style: cs |
| 34887 |
}; |
| 34888 |
while(font && !font.done){ |
| 34889 |
const machine = new _api__WEBPACK_IMPORTED_MODULE_0__.FiniteStateMachine(_transactions__WEBPACK_IMPORTED_MODULE_2__.states.START, _transactions__WEBPACK_IMPORTED_MODULE_2__.transactions); |
| 34890 |
state.element = font.value; |
| 34891 |
// machine.disableSilent(); |
| 34892 |
while(machine.getState() !== _transactions__WEBPACK_IMPORTED_MODULE_2__.states.END){ |
| 34893 |
// console.log(machine.getState(), state); |
| 34894 |
state = machine.dispatch('exec', state); |
| 34895 |
} |
| 34896 |
// console.log('-------------------'); |
| 34897 |
font = gen.next(); |
| 34898 |
} |
| 34899 |
// sel.restore(); |
| 34900 |
sel.restoreFakes(fakes); |
| 34901 |
} |
| 34902 |
|
| 34903 |
|
| 34904 |
/***/ }), |
| 34905 |
|
| 34906 |
/***/ 96340: |
| 34907 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 34908 |
|
| 34909 |
"use strict"; |
| 34910 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 34911 |
/* harmony export */ normalizeRelativePath: function() { return /* binding */ normalizeRelativePath; } |
| 34912 |
/* harmony export */ }); |
| 34913 |
/*! |
| 34914 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 34915 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 34916 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 34917 |
*/ /** |
| 34918 |
* @module helpers/normalize |
| 34919 |
*/ const normalizeRelativePath = (path)=>{ |
| 34920 |
const sections = path.split('/'), builder = sections.reduce((builder, section)=>{ |
| 34921 |
switch(section){ |
| 34922 |
case '': |
| 34923 |
{ |
| 34924 |
break; |
| 34925 |
} |
| 34926 |
case '.': |
| 34927 |
{ |
| 34928 |
break; |
| 34929 |
} |
| 34930 |
case '..': |
| 34931 |
{ |
| 34932 |
builder.pop(); |
| 34933 |
break; |
| 34934 |
} |
| 34935 |
default: |
| 34936 |
{ |
| 34937 |
builder.push(section); |
| 34938 |
break; |
| 34939 |
} |
| 34940 |
} |
| 34941 |
return builder; |
| 34942 |
}, []); |
| 34943 |
return builder.join('/') + (path.endsWith('/') ? '/' : ''); |
| 34944 |
}; |
| 34945 |
|
| 34946 |
|
| 34947 |
/***/ }), |
| 34948 |
|
| 34949 |
/***/ 96608: |
| 34950 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 34951 |
|
| 34952 |
"use strict"; |
| 34953 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5266); |
| 34954 |
/*! |
| 34955 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 34956 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 34957 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 34958 |
*/ /** |
| 34959 |
* @module plugins/resizer |
| 34960 |
*/ |
| 34961 |
jodit_config__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.allowResizeTags = new Set([ |
| 34962 |
'img', |
| 34963 |
'iframe', |
| 34964 |
'table', |
| 34965 |
'jodit' |
| 34966 |
]); |
| 34967 |
jodit_config__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.resizer = { |
| 34968 |
showSize: true, |
| 34969 |
hideSizeTimeout: 1000, |
| 34970 |
forImageChangeAttributes: true, |
| 34971 |
min_width: 10, |
| 34972 |
min_height: 10, |
| 34973 |
useAspectRatio: new Set([ |
| 34974 |
'img' |
| 34975 |
]) |
| 34976 |
}; |
| 34977 |
|
| 34978 |
|
| 34979 |
/***/ }), |
| 34980 |
|
| 34981 |
/***/ 96863: |
| 34982 |
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) { |
| 34983 |
|
| 34984 |
"use strict"; |
| 34985 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 34986 |
/* harmony import */ var jodit_core_helpers_checker_is_plain_object__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(62101); |
| 34987 |
/* harmony import */ var jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(29434); |
| 34988 |
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5266); |
| 34989 |
/* harmony import */ var _paragraph_svg__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(29348); |
| 34990 |
/* harmony import */ var _paragraph_svg__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_paragraph_svg__WEBPACK_IMPORTED_MODULE_4__); |
| 34991 |
/*! |
| 34992 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 34993 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 34994 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 34995 |
*/ /** |
| 34996 |
* @module plugins/format-block |
| 34997 |
*/ |
| 34998 |
|
| 34999 |
|
| 35000 |
|
| 35001 |
|
| 35002 |
jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_2__.Icon.set('paragraph', (_paragraph_svg__WEBPACK_IMPORTED_MODULE_4___default())); |
| 35003 |
jodit_config__WEBPACK_IMPORTED_MODULE_3__.Config.prototype.controls.paragraph = { |
| 35004 |
command: 'formatBlock', |
| 35005 |
value (editor, button) { |
| 35006 |
var _ref; |
| 35007 |
var _control_data; |
| 35008 |
const control = button.control, current = editor.s.current(); |
| 35009 |
const currentBox = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(current, jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isBlock, editor.editor); |
| 35010 |
return (_ref = currentBox === null || currentBox === void 0 ? void 0 : currentBox.nodeName.toLowerCase()) !== null && _ref !== void 0 ? _ref : (_control_data = control.data) === null || _control_data === void 0 ? void 0 : _control_data.currentValue; |
| 35011 |
}, |
| 35012 |
update (editor, button) { |
| 35013 |
const control = button.control, current = editor.s.current(); |
| 35014 |
if (!current) { |
| 35015 |
return false; |
| 35016 |
} |
| 35017 |
const currentValue = button.state.value, list = control.list; |
| 35018 |
if ((0,jodit_core_helpers_checker_is_plain_object__WEBPACK_IMPORTED_MODULE_1__.isPlainObject)(list) && list[currentValue.toString()]) { |
| 35019 |
if (editor.o.textIcons) { |
| 35020 |
button.state.text = list[currentValue.toString()].toString(); |
| 35021 |
} |
| 35022 |
} |
| 35023 |
return false; |
| 35024 |
}, |
| 35025 |
data: { |
| 35026 |
currentValue: 'p' |
| 35027 |
}, |
| 35028 |
list: { |
| 35029 |
p: 'Paragraph', |
| 35030 |
h1: 'Heading 1', |
| 35031 |
h2: 'Heading 2', |
| 35032 |
h3: 'Heading 3', |
| 35033 |
h4: 'Heading 4', |
| 35034 |
blockquote: 'Quote', |
| 35035 |
pre: 'Code' |
| 35036 |
}, |
| 35037 |
isChildActive: (editor, button)=>{ |
| 35038 |
var _button_control_args, _button_control; |
| 35039 |
return Boolean(button.state.value === ((_button_control = button.control) === null || _button_control === void 0 ? void 0 : (_button_control_args = _button_control.args) === null || _button_control_args === void 0 ? void 0 : _button_control_args[0])); |
| 35040 |
}, |
| 35041 |
isActive: (editor, button)=>{ |
| 35042 |
return button.state.value !== editor.o.enter && (0,jodit_core_helpers_checker_is_plain_object__WEBPACK_IMPORTED_MODULE_1__.isPlainObject)(button.control.list) && Boolean(button.control.list[button.state.value]); |
| 35043 |
}, |
| 35044 |
childTemplate: (e, key, value)=>`<${key} style="margin:0;padding:0"><span>${e.i18n(value)}</span></${key}>`, |
| 35045 |
tooltip: 'Insert format block' |
| 35046 |
}; |
| 35047 |
|
| 35048 |
|
| 35049 |
/***/ }), |
| 35050 |
|
| 35051 |
/***/ 97022: |
| 35052 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 35053 |
|
| 35054 |
"use strict"; |
| 35055 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 35056 |
/* harmony export */ NUMBER_FIELDS_REG: function() { return /* reexport safe */ _normalize_css_value__WEBPACK_IMPORTED_MODULE_1__.NUMBER_FIELDS_REG; }, |
| 35057 |
/* harmony export */ normalizeColor: function() { return /* reexport safe */ _normalize_color__WEBPACK_IMPORTED_MODULE_0__.normalizeColor; }, |
| 35058 |
/* harmony export */ normalizeCssNumericValue: function() { return /* reexport safe */ _normalize_css_value__WEBPACK_IMPORTED_MODULE_1__.normalizeCssNumericValue; }, |
| 35059 |
/* harmony export */ normalizeCssValue: function() { return /* reexport safe */ _normalize_css_value__WEBPACK_IMPORTED_MODULE_1__.normalizeCssValue; }, |
| 35060 |
/* harmony export */ normalizeKeyAliases: function() { return /* reexport safe */ _normalize_key_aliases__WEBPACK_IMPORTED_MODULE_2__.normalizeKeyAliases; }, |
| 35061 |
/* harmony export */ normalizeLicense: function() { return /* reexport safe */ _normalize_license__WEBPACK_IMPORTED_MODULE_3__.normalizeLicense; }, |
| 35062 |
/* harmony export */ normalizePath: function() { return /* reexport safe */ _normalize_path__WEBPACK_IMPORTED_MODULE_4__.normalizePath; }, |
| 35063 |
/* harmony export */ normalizeRelativePath: function() { return /* reexport safe */ _normalize_relative_path__WEBPACK_IMPORTED_MODULE_5__.normalizeRelativePath; }, |
| 35064 |
/* harmony export */ normalizeSize: function() { return /* reexport safe */ _normalize_size__WEBPACK_IMPORTED_MODULE_6__.normalizeSize; }, |
| 35065 |
/* harmony export */ normalizeUrl: function() { return /* reexport safe */ _normalize_url__WEBPACK_IMPORTED_MODULE_7__.normalizeUrl; } |
| 35066 |
/* harmony export */ }); |
| 35067 |
/* harmony import */ var _normalize_color__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(77367); |
| 35068 |
/* harmony import */ var _normalize_css_value__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(19147); |
| 35069 |
/* harmony import */ var _normalize_key_aliases__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(27978); |
| 35070 |
/* harmony import */ var _normalize_license__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(49663); |
| 35071 |
/* harmony import */ var _normalize_path__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(18377); |
| 35072 |
/* harmony import */ var _normalize_relative_path__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(96340); |
| 35073 |
/* harmony import */ var _normalize_size__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(98831); |
| 35074 |
/* harmony import */ var _normalize_url__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(48009); |
| 35075 |
/*! |
| 35076 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 35077 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 35078 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 35079 |
*/ /** |
| 35080 |
* @module helpers/normalize |
| 35081 |
*/ |
| 35082 |
|
| 35083 |
|
| 35084 |
|
| 35085 |
|
| 35086 |
|
| 35087 |
|
| 35088 |
|
| 35089 |
|
| 35090 |
|
| 35091 |
/***/ }), |
| 35092 |
|
| 35093 |
/***/ 97110: |
| 35094 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 35095 |
|
| 35096 |
"use strict"; |
| 35097 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 35098 |
/* harmony export */ wrapList: function() { return /* binding */ wrapList; } |
| 35099 |
/* harmony export */ }); |
| 35100 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23211); |
| 35101 |
/* harmony import */ var jodit_core_selection_style_api_is_same_attributes__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(95971); |
| 35102 |
/* harmony import */ var jodit_core_selection_style_api_toggle_attributes__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(82794); |
| 35103 |
/* harmony import */ var jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(98394); |
| 35104 |
/*! |
| 35105 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 35106 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 35107 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 35108 |
*/ |
| 35109 |
|
| 35110 |
|
| 35111 |
|
| 35112 |
/** |
| 35113 |
* Replaces non-leaf items with leaf items and either creates a new list or |
| 35114 |
* adds a new item to the nearest old list |
| 35115 |
* @private |
| 35116 |
*/ function wrapList(commitStyle, wrapper, jodit) { |
| 35117 |
const result = jodit.e.fire(`${jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_3__._PREFIX}BeforeWrapList`, jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_3__.REPLACE, wrapper, commitStyle); |
| 35118 |
const newWrapper = result !== null && result !== void 0 ? result : jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.replace(wrapper, 'li', jodit.createInside); |
| 35119 |
const prev = newWrapper.previousElementSibling; |
| 35120 |
const next = newWrapper.nextElementSibling; |
| 35121 |
let list = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(prev, commitStyle.element) ? prev : null; |
| 35122 |
list !== null && list !== void 0 ? list : list = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(next, commitStyle.element) ? next : null; |
| 35123 |
if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isList(list) || !(0,jodit_core_selection_style_api_is_same_attributes__WEBPACK_IMPORTED_MODULE_1__.isSameAttributes)(list, commitStyle.options.attributes)) { |
| 35124 |
list = jodit.createInside.element(commitStyle.element); |
| 35125 |
(0,jodit_core_selection_style_api_toggle_attributes__WEBPACK_IMPORTED_MODULE_2__.toggleAttributes)(commitStyle, list, jodit, jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_3__.INITIAL); |
| 35126 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.before(newWrapper, list); |
| 35127 |
} |
| 35128 |
if (prev === list) { |
| 35129 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.append(list, newWrapper); |
| 35130 |
} else { |
| 35131 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.prepend(list, newWrapper); |
| 35132 |
} |
| 35133 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(list.nextElementSibling, commitStyle.element) && (0,jodit_core_selection_style_api_is_same_attributes__WEBPACK_IMPORTED_MODULE_1__.elementsEqualAttributes)(list, list.nextElementSibling)) { |
| 35134 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.append(list, Array.from(list.nextElementSibling.childNodes)); |
| 35135 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(list.nextElementSibling); |
| 35136 |
} |
| 35137 |
jodit.e.fire(`${jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_3__._PREFIX}AfterWrapList`, jodit_core_selection_style_constants__WEBPACK_IMPORTED_MODULE_3__.WRAP, list, commitStyle); |
| 35138 |
return list; |
| 35139 |
} |
| 35140 |
|
| 35141 |
|
| 35142 |
/***/ }), |
| 35143 |
|
| 35144 |
/***/ 97228: |
| 35145 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 35146 |
|
| 35147 |
"use strict"; |
| 35148 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 35149 |
/* harmony export */ defaultLanguage: function() { return /* binding */ defaultLanguage; } |
| 35150 |
/* harmony export */ }); |
| 35151 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 35152 |
/* harmony import */ var jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(85932); |
| 35153 |
/*! |
| 35154 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 35155 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 35156 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 35157 |
*/ /** |
| 35158 |
* @module helpers/utils |
| 35159 |
*/ |
| 35160 |
|
| 35161 |
/** |
| 35162 |
* Try define user language |
| 35163 |
*/ const defaultLanguage = (language, defaultLanguage = 'en')=>{ |
| 35164 |
if (language !== 'auto' && (0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_1__.isString)(language)) { |
| 35165 |
return language; |
| 35166 |
} |
| 35167 |
if (jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.globalDocument.documentElement && jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.globalDocument.documentElement.lang) { |
| 35168 |
return jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.globalDocument.documentElement.lang; |
| 35169 |
} |
| 35170 |
if (navigator.language) { |
| 35171 |
return navigator.language.substring(0, 2); |
| 35172 |
} |
| 35173 |
return defaultLanguage; |
| 35174 |
}; |
| 35175 |
|
| 35176 |
|
| 35177 |
/***/ }), |
| 35178 |
|
| 35179 |
/***/ 97493: |
| 35180 |
/***/ (function(module) { |
| 35181 |
|
| 35182 |
/*! |
| 35183 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 35184 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 35185 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 35186 |
*/ module.exports = { |
| 35187 |
symbols: 'символ' |
| 35188 |
}; |
| 35189 |
|
| 35190 |
|
| 35191 |
/***/ }), |
| 35192 |
|
| 35193 |
/***/ 97642: |
| 35194 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 35195 |
|
| 35196 |
"use strict"; |
| 35197 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 35198 |
/* harmony export */ CamelCaseToKebabCase: function() { return /* reexport safe */ _kebab_case__WEBPACK_IMPORTED_MODULE_3__.CamelCaseToKebabCase; }, |
| 35199 |
/* harmony export */ camelCase: function() { return /* reexport safe */ _camel_case__WEBPACK_IMPORTED_MODULE_0__.camelCase; }, |
| 35200 |
/* harmony export */ fuzzySearchIndex: function() { return /* reexport safe */ _fuzzy_search_index__WEBPACK_IMPORTED_MODULE_1__.fuzzySearchIndex; }, |
| 35201 |
/* harmony export */ i18n: function() { return /* reexport safe */ _i18n__WEBPACK_IMPORTED_MODULE_2__.i18n; }, |
| 35202 |
/* harmony export */ kebabCase: function() { return /* reexport safe */ _kebab_case__WEBPACK_IMPORTED_MODULE_3__.kebabCase; }, |
| 35203 |
/* harmony export */ sprintf: function() { return /* reexport safe */ _i18n__WEBPACK_IMPORTED_MODULE_2__.sprintf; }, |
| 35204 |
/* harmony export */ stringify: function() { return /* reexport safe */ _stringify__WEBPACK_IMPORTED_MODULE_4__.stringify; }, |
| 35205 |
/* harmony export */ trim: function() { return /* reexport safe */ _trim__WEBPACK_IMPORTED_MODULE_5__.trim; }, |
| 35206 |
/* harmony export */ trimChars: function() { return /* reexport safe */ _trim__WEBPACK_IMPORTED_MODULE_5__.trimChars; }, |
| 35207 |
/* harmony export */ trimInv: function() { return /* reexport safe */ _trim__WEBPACK_IMPORTED_MODULE_5__.trimInv; }, |
| 35208 |
/* harmony export */ ucfirst: function() { return /* reexport safe */ _ucfirst__WEBPACK_IMPORTED_MODULE_6__.ucfirst; } |
| 35209 |
/* harmony export */ }); |
| 35210 |
/* harmony import */ var _camel_case__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(57821); |
| 35211 |
/* harmony import */ var _fuzzy_search_index__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(57626); |
| 35212 |
/* harmony import */ var _i18n__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(18080); |
| 35213 |
/* harmony import */ var _kebab_case__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(74264); |
| 35214 |
/* harmony import */ var _stringify__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(3347); |
| 35215 |
/* harmony import */ var _trim__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(4040); |
| 35216 |
/* harmony import */ var _ucfirst__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(99436); |
| 35217 |
/*! |
| 35218 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 35219 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 35220 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 35221 |
*/ /** |
| 35222 |
* @module helpers/string |
| 35223 |
*/ |
| 35224 |
|
| 35225 |
|
| 35226 |
|
| 35227 |
|
| 35228 |
|
| 35229 |
|
| 35230 |
|
| 35231 |
|
| 35232 |
/***/ }), |
| 35233 |
|
| 35234 |
/***/ 97834: |
| 35235 |
/***/ (function(module) { |
| 35236 |
|
| 35237 |
module.exports["default"] = ["Napisz coś","O Jodit","Edytor Jodit","Instrukcja Jodit","zawiera szczegółowe informacje dotyczące użytkowania.","Odwiedź naszą stronę, aby uzyskać więcej informacji na temat licencji:","Zakup pełnej wersji","Copyright © XDSoft.net - Chupurnov Valeriy. Wszystkie prawa zastrzeżone.","Kotwica","Otwórz w nowej zakładce","Otwórz edytor w pełnym rozmiarze","Wyczyść formatowanie","Kolor wypełnienia lub ustaw kolor tekstu","Ponów","Cofnij","Pogrubienie","Kursywa","Wstaw listę wypunktowaną","Wstaw listę numeryczną","Wyśrodkuj","Wyjustuj","Wyrównaj do lewej","Wyrównaj do prawej","Wstaw linię poziomą","Wstaw grafikę","Wstaw plik","Wstaw film Youtube/vimeo","Wstaw link","Rozmiar tekstu","Krój czcionki","Wstaw formatowanie","Normalne","Nagłówek 1","Nagłówek 2","Nagłówek 3","Nagłówek 4","Cytat","Kod","Wstaw","Wstaw tabelę","Zmniejsz wcięcie","Zwiększ wcięcie","Wybierz znak specjalny","Wstaw znak specjalny","Malarz formatów","Zmień tryb","Marginesy","Górny","Prawy","Dolny","Levy","Style CSS","Klasy CSS","Wyrównanie","Prawa","środek","Lewa","brak","Źródło","Tytuł","Tekst alternatywny","Link","Otwórz w nowej zakładce","Grafika","Plik","Zaawansowane","Właściwości grafiki","Anuluj","OK","Przeglądarka plików","Błąd ładowania listy plików","Błąd ładowania folderów","Czy jesteś pewien?","Wprowadź nazwę folderu","Utwórz folder","wprowadź nazwę","Upuść plik graficzny","Upuść plik","lub kliknij tu","Tekst alternatywny","Wczytaj","Przeglądaj","Tło","Treść","Góra","Środek","Dół","Wstaw kolumnę przed","Wstaw kolumnę po","Wstaw wiersz przed","Wstaw wiersz po","Usuń tabelę","Usuń wiersz","Usuń kolumnę","Wyczyść komórkę","Znaki: %d","Słowa: %d","Przekreślenie","Podkreślenie","indeks górny","index dolny","Wytnij zaznaczenie","Wybierz wszystko","Przerwa","Szukaj","Zamień na","Wymienić","Wklej","Wybierz zawartość do wklejenia","HTML","pogrubienie","kursywa","pędzel","link","cofnij","ponów","tabela","grafika","wyczyść","akapit","rozmiar czcionki","wideo","czcionka","O programie","drukuj","podkreślenie","przekreślenie","wcięcie","wycięcie","pełen rozmiar","przytnij","linia pozioma","lista","lista numerowana","wytnij","zaznacz wszystko","Wstaw kod","otwórz link","edytuj link","Atrybut no-follow","Usuń link","Aktualizuj","edytuj","szukaj","URL","Edytuj","Wyrównywanie w poziomie","Filtruj","Sortuj wg zmiany","Sortuj wg nazwy","Sortuj wg rozmiaru","Dodaj folder","wyczyść","zapisz","zapisz jako","Zmień rozmiar","Przytnij","Szerokość","Wysokość","Zachowaj proporcje","Tak","Nie","Usuń","Wybierz","Wybierz: %s","Wyrównywanie w pionie","Podziel","Scal","Dodaj kolumnę","Dodaj wiersz","Licencja: %s","Usuń","Podziel w pionie","Podziel w poziomie","Obramowanie","Twój kod wygląda jak HTML. Zachować HTML?","Wkleić jako HTML?","Oryginalny tekst","Wstaw jako tekst","Wstaw tylko treść","Możesz edytować tylko swoje grafiki. Czy chcesz pobrać tą grafikę?","Grafika została pomyślnienie dodana na serwer","Paleta","Brak plików.","zmień nazwę","Wprowadź nową nazwę","podgląd","pobierz","Wklej ze schowka","Twoja przeglądarka nie obsługuje schowka","Kopiuj zaznaczenie","kopiuj","Zaokrąglenie krawędzi","Pokaż wszystkie","Zastosuj","Proszę wypełnić to pole","Proszę, wpisz adres sieci web","Domyślnie","Koło","Punkt","Kwadrat","Znaleźć","Znaleźć Poprzednie","Znajdź Dalej","Wklejany tekst pochodzi z dokumentu Microsoft Word/Excel. Chcesz zachować ten format czy wyczyścić go? ","Wykryto tekst w formacie Word","Wyczyść","Wstaw nazwę zajęć","Naciśnij Alt, aby zmienić rozmiar",null,null,null,"Wszystko"] |
| 35238 |
|
| 35239 |
/***/ }), |
| 35240 |
|
| 35241 |
/***/ 97959: |
| 35242 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 35243 |
|
| 35244 |
"use strict"; |
| 35245 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 35246 |
/* harmony export */ UIList: function() { return /* binding */ UIList; } |
| 35247 |
/* harmony export */ }); |
| 35248 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 35249 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 35250 |
/* harmony import */ var jodit_core_component_component__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(80251); |
| 35251 |
/* harmony import */ var jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(91672); |
| 35252 |
/* harmony import */ var jodit_core_decorators_hook_hook__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(29200); |
| 35253 |
/* harmony import */ var jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(68616); |
| 35254 |
/* harmony import */ var jodit_core_helpers_array_split_array__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(32328); |
| 35255 |
/* harmony import */ var jodit_core_ui_button_button_button__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(53681); |
| 35256 |
/* harmony import */ var jodit_core_ui_group_group__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(63468); |
| 35257 |
/* harmony import */ var jodit_core_ui_group_separator__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(35676); |
| 35258 |
/* harmony import */ var jodit_core_ui_group_spacer__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(27987); |
| 35259 |
/* harmony import */ var jodit_core_ui_helpers_buttons__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(2496); |
| 35260 |
/* harmony import */ var jodit_core_ui_helpers_get_control_type__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(15982); |
| 35261 |
/* harmony import */ var jodit_core_ui_helpers_get_strong_control_types__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(40253); |
| 35262 |
/*! |
| 35263 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 35264 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 35265 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 35266 |
*/ /** |
| 35267 |
* @module ui/group |
| 35268 |
*/ |
| 35269 |
|
| 35270 |
|
| 35271 |
|
| 35272 |
|
| 35273 |
|
| 35274 |
|
| 35275 |
|
| 35276 |
|
| 35277 |
|
| 35278 |
|
| 35279 |
|
| 35280 |
|
| 35281 |
|
| 35282 |
|
| 35283 |
class UIList extends jodit_core_ui_group_group__WEBPACK_IMPORTED_MODULE_8__.UIGroup { |
| 35284 |
className() { |
| 35285 |
return 'UIList'; |
| 35286 |
} |
| 35287 |
getRole() { |
| 35288 |
return 'list'; |
| 35289 |
} |
| 35290 |
__onChangeMode() { |
| 35291 |
this.setMod('mode', this.mode); |
| 35292 |
} |
| 35293 |
/** |
| 35294 |
* Make new group and append it in list of elements |
| 35295 |
*/ makeGroup(role) { |
| 35296 |
return new jodit_core_ui_group_group__WEBPACK_IMPORTED_MODULE_8__.UIGroup(this.jodit, [], role ? { |
| 35297 |
role |
| 35298 |
} : undefined); |
| 35299 |
} |
| 35300 |
/** |
| 35301 |
* All buttons from list |
| 35302 |
*/ get buttons() { |
| 35303 |
return this.allChildren.filter((elm)=>jodit_core_component_component__WEBPACK_IMPORTED_MODULE_2__.Component.isInstanceOf(elm, jodit_core_ui_button_button_button__WEBPACK_IMPORTED_MODULE_7__.UIButton)); |
| 35304 |
} |
| 35305 |
/** |
| 35306 |
* Helper for getting full plain button list |
| 35307 |
*/ getButtonsNames() { |
| 35308 |
return this.buttons.map((a)=>a instanceof jodit_core_ui_button_button_button__WEBPACK_IMPORTED_MODULE_7__.UIButton && a.state.name || '').filter((a)=>a !== ''); |
| 35309 |
} |
| 35310 |
setRemoveButtons(removeButtons) { |
| 35311 |
this.removeButtons = removeButtons || []; |
| 35312 |
return this; |
| 35313 |
} |
| 35314 |
build(items, target = null) { |
| 35315 |
items = (0,jodit_core_helpers_array_split_array__WEBPACK_IMPORTED_MODULE_6__.splitArray)(items); |
| 35316 |
this.clear(); |
| 35317 |
let lastBtnSeparator = false; |
| 35318 |
let line = this.makeGroup('group'); |
| 35319 |
this.append(line); |
| 35320 |
line.setMod('line', true); |
| 35321 |
let group; |
| 35322 |
const addButton = (control)=>{ |
| 35323 |
let elm = null; |
| 35324 |
switch(control.name){ |
| 35325 |
case '\n': |
| 35326 |
line = this.makeGroup('group'); |
| 35327 |
line.setMod('line', true); |
| 35328 |
group = this.makeGroup(); |
| 35329 |
line.append(group); |
| 35330 |
this.append(line); |
| 35331 |
break; |
| 35332 |
case '|': |
| 35333 |
if (!lastBtnSeparator) { |
| 35334 |
lastBtnSeparator = true; |
| 35335 |
elm = new jodit_core_ui_group_separator__WEBPACK_IMPORTED_MODULE_9__.UISeparator(this.j); |
| 35336 |
} |
| 35337 |
break; |
| 35338 |
case '---': |
| 35339 |
{ |
| 35340 |
group.setMod('before-spacer', true); |
| 35341 |
const space = new jodit_core_ui_group_spacer__WEBPACK_IMPORTED_MODULE_10__.UISpacer(this.j); |
| 35342 |
line.append(space); |
| 35343 |
group = this.makeGroup(); |
| 35344 |
line.append(group); |
| 35345 |
lastBtnSeparator = false; |
| 35346 |
break; |
| 35347 |
} |
| 35348 |
default: |
| 35349 |
lastBtnSeparator = false; |
| 35350 |
switch(control.component){ |
| 35351 |
case 'select': |
| 35352 |
elm = this.makeSelect(control, target); |
| 35353 |
break; |
| 35354 |
case 'button': |
| 35355 |
default: |
| 35356 |
elm = this.makeButton(control, target); |
| 35357 |
} |
| 35358 |
} |
| 35359 |
if (elm) { |
| 35360 |
if (!group) { |
| 35361 |
group = this.makeGroup(); |
| 35362 |
line.append(group); |
| 35363 |
} |
| 35364 |
group.append(elm); |
| 35365 |
} |
| 35366 |
}; |
| 35367 |
const isNotRemoved = (b)=>{ |
| 35368 |
var _b_isVisible; |
| 35369 |
return !this.removeButtons.includes(b.name) && (!b.isVisible || ((_b_isVisible = b.isVisible) === null || _b_isVisible === void 0 ? void 0 : _b_isVisible.call(b, this.j, b))); |
| 35370 |
}; |
| 35371 |
items.forEach((item)=>{ |
| 35372 |
if ((0,jodit_core_ui_helpers_buttons__WEBPACK_IMPORTED_MODULE_11__.isButtonGroup)(item)) { |
| 35373 |
const buttons = item.buttons.filter((b)=>b); |
| 35374 |
if (buttons.length) { |
| 35375 |
group = this.makeGroup(); |
| 35376 |
group.setMod('separated', true).setMod('group', item.group); |
| 35377 |
line.append(group); |
| 35378 |
(0,jodit_core_ui_helpers_get_strong_control_types__WEBPACK_IMPORTED_MODULE_13__.getStrongControlTypes)(buttons, this.j.o.controls).filter(isNotRemoved).forEach(addButton); |
| 35379 |
} |
| 35380 |
} else { |
| 35381 |
if (!group) { |
| 35382 |
group = this.makeGroup(); |
| 35383 |
line.append(group); |
| 35384 |
} |
| 35385 |
const control = (0,jodit_core_ui_helpers_get_control_type__WEBPACK_IMPORTED_MODULE_12__.getControlType)(item, this.j.o.controls); |
| 35386 |
isNotRemoved(control) && addButton(control); |
| 35387 |
} |
| 35388 |
}); |
| 35389 |
this.update(); |
| 35390 |
return this; |
| 35391 |
} |
| 35392 |
makeSelect(control, target) { |
| 35393 |
throw new Error('Not implemented behaviour'); |
| 35394 |
} |
| 35395 |
/** |
| 35396 |
* Create button instance |
| 35397 |
*/ makeButton(control, target) { |
| 35398 |
return new jodit_core_ui_button_button_button__WEBPACK_IMPORTED_MODULE_7__.UIButton(this.j, { |
| 35399 |
name: control.name |
| 35400 |
}); |
| 35401 |
} |
| 35402 |
constructor(...args){ |
| 35403 |
super(...args), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "mode", 'horizontal'), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "removeButtons", []); |
| 35404 |
} |
| 35405 |
} |
| 35406 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 35407 |
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_5__.watch)('mode'), |
| 35408 |
(0,jodit_core_decorators_hook_hook__WEBPACK_IMPORTED_MODULE_4__.hook)('ready') |
| 35409 |
], UIList.prototype, "__onChangeMode", null); |
| 35410 |
UIList = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 35411 |
jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_3__.component |
| 35412 |
], UIList); |
| 35413 |
|
| 35414 |
|
| 35415 |
/***/ }), |
| 35416 |
|
| 35417 |
/***/ 98394: |
| 35418 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 35419 |
|
| 35420 |
"use strict"; |
| 35421 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 35422 |
/* harmony export */ CHANGE: function() { return /* binding */ CHANGE; }, |
| 35423 |
/* harmony export */ INITIAL: function() { return /* binding */ INITIAL; }, |
| 35424 |
/* harmony export */ REPLACE: function() { return /* binding */ REPLACE; }, |
| 35425 |
/* harmony export */ UNSET: function() { return /* binding */ UNSET; }, |
| 35426 |
/* harmony export */ UNWRAP: function() { return /* binding */ UNWRAP; }, |
| 35427 |
/* harmony export */ WRAP: function() { return /* binding */ WRAP; }, |
| 35428 |
/* harmony export */ _PREFIX: function() { return /* binding */ _PREFIX; } |
| 35429 |
/* harmony export */ }); |
| 35430 |
/*! |
| 35431 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 35432 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 35433 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 35434 |
*/ /** |
| 35435 |
* @module selection |
| 35436 |
*/ /** @internal */ const WRAP = 'wrap'; |
| 35437 |
/** @internal */ const UNWRAP = 'unwrap'; |
| 35438 |
/** @internal */ const CHANGE = 'change'; |
| 35439 |
/** @internal */ const UNSET = 'unset'; |
| 35440 |
/** @internal */ const INITIAL = 'initial'; |
| 35441 |
/** @internal */ const REPLACE = 'replace'; |
| 35442 |
/** @internal */ const _PREFIX = 'commitStyle'; |
| 35443 |
|
| 35444 |
|
| 35445 |
/***/ }), |
| 35446 |
|
| 35447 |
/***/ 98595: |
| 35448 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 35449 |
|
| 35450 |
"use strict"; |
| 35451 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 35452 |
/* harmony export */ Selection: function() { return /* binding */ Selection; } |
| 35453 |
/* harmony export */ }); |
| 35454 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 35455 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 35456 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(81937); |
| 35457 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(84839); |
| 35458 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(23211); |
| 35459 |
/* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(65946); |
| 35460 |
/* harmony import */ var jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(28686); |
| 35461 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(28712); |
| 35462 |
/* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_7__); |
| 35463 |
/* harmony import */ var jodit_core_selection_helpers_move_the_node_along_the_edge_outward__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(7470); |
| 35464 |
/* harmony import */ var _style_commit_style__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(84578); |
| 35465 |
/* harmony import */ var _helpers__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(42259); |
| 35466 |
/*! |
| 35467 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 35468 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 35469 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 35470 |
*/ /** |
| 35471 |
* [[include:core/selection/README.md]] |
| 35472 |
* @packageDocumentation |
| 35473 |
* @module selection |
| 35474 |
*/ |
| 35475 |
|
| 35476 |
|
| 35477 |
|
| 35478 |
|
| 35479 |
|
| 35480 |
|
| 35481 |
|
| 35482 |
|
| 35483 |
|
| 35484 |
|
| 35485 |
|
| 35486 |
|
| 35487 |
class Selection { |
| 35488 |
/** |
| 35489 |
* Short alias for this.jodit |
| 35490 |
*/ get j() { |
| 35491 |
return this.jodit; |
| 35492 |
} |
| 35493 |
/** |
| 35494 |
* Throw Error exception if parameter is not Node |
| 35495 |
*/ errorNode(node) { |
| 35496 |
if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isNode(node)) { |
| 35497 |
throw (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.error)('Parameter node must be instance of Node'); |
| 35498 |
} |
| 35499 |
} |
| 35500 |
/** |
| 35501 |
* Return current work place - for Jodit is Editor |
| 35502 |
*/ get area() { |
| 35503 |
return this.j.editor; |
| 35504 |
} |
| 35505 |
/** |
| 35506 |
* Editor Window - it can be different for iframe mode |
| 35507 |
*/ get win() { |
| 35508 |
return this.j.ew; |
| 35509 |
} |
| 35510 |
/** |
| 35511 |
* Current jodit editor doc |
| 35512 |
*/ get doc() { |
| 35513 |
return this.j.ed; |
| 35514 |
} |
| 35515 |
/** |
| 35516 |
* Return current selection object |
| 35517 |
*/ get sel() { |
| 35518 |
if (this.j.o.shadowRoot && (0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_6__.isFunction)(this.j.o.shadowRoot.getSelection)) { |
| 35519 |
return this.j.o.shadowRoot.getSelection(); |
| 35520 |
} |
| 35521 |
return this.win.getSelection(); |
| 35522 |
} |
| 35523 |
/** |
| 35524 |
* Return first selected range or create new |
| 35525 |
*/ get range() { |
| 35526 |
const sel = this.sel; |
| 35527 |
return sel && sel.rangeCount ? sel.getRangeAt(0) : this.createRange(); |
| 35528 |
} |
| 35529 |
/** |
| 35530 |
* Checks if the selected text is currently inside the editor |
| 35531 |
*/ get isInsideArea() { |
| 35532 |
const { sel } = this; |
| 35533 |
const range = (sel === null || sel === void 0 ? void 0 : sel.rangeCount) ? sel.getRangeAt(0) : null; |
| 35534 |
return !(!range || !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isOrContains(this.area, range.startContainer)); |
| 35535 |
} |
| 35536 |
/** |
| 35537 |
* Return current selection object |
| 35538 |
* @param select - Immediately add in selection |
| 35539 |
*/ createRange(select = false) { |
| 35540 |
const range = this.doc.createRange(); |
| 35541 |
if (select) { |
| 35542 |
this.selectRange(range); |
| 35543 |
} |
| 35544 |
return range; |
| 35545 |
} |
| 35546 |
/** |
| 35547 |
* Remove all selected content |
| 35548 |
*/ remove() { |
| 35549 |
const sel = this.sel, current = this.current(); |
| 35550 |
if (sel && current) { |
| 35551 |
for(let i = 0; i < sel.rangeCount; i += 1){ |
| 35552 |
sel.getRangeAt(i).deleteContents(); |
| 35553 |
sel.getRangeAt(i).collapse(true); |
| 35554 |
} |
| 35555 |
} |
| 35556 |
} |
| 35557 |
/** |
| 35558 |
* Clear all selection |
| 35559 |
*/ clear() { |
| 35560 |
var _this_sel; |
| 35561 |
if ((_this_sel = this.sel) === null || _this_sel === void 0 ? void 0 : _this_sel.rangeCount) { |
| 35562 |
var _this_sel1; |
| 35563 |
(_this_sel1 = this.sel) === null || _this_sel1 === void 0 ? void 0 : _this_sel1.removeAllRanges(); |
| 35564 |
} |
| 35565 |
} |
| 35566 |
/** |
| 35567 |
* Remove node element from editor |
| 35568 |
*/ removeNode(node) { |
| 35569 |
if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isOrContains(this.j.editor, node, true)) { |
| 35570 |
throw (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.error)("Selection.removeNode can remove only editor's children"); |
| 35571 |
} |
| 35572 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeRemove(node); |
| 35573 |
this.j.e.fire('afterRemoveNode', node); |
| 35574 |
} |
| 35575 |
/** |
| 35576 |
* Insert the cursor to any point x, y |
| 35577 |
* |
| 35578 |
* @param x - Coordinate by horizontal |
| 35579 |
* @param y - Coordinate by vertical |
| 35580 |
* @returns false - Something went wrong |
| 35581 |
*/ insertCursorAtPoint(x, y) { |
| 35582 |
this.removeMarkers(); |
| 35583 |
try { |
| 35584 |
const rng = this.createRange(); |
| 35585 |
(()=>{ |
| 35586 |
if (this.doc.caretPositionFromPoint) { |
| 35587 |
const caret = this.doc.caretPositionFromPoint(x, y); |
| 35588 |
if (caret) { |
| 35589 |
rng.setStart(caret.offsetNode, caret.offset); |
| 35590 |
return; |
| 35591 |
} |
| 35592 |
} |
| 35593 |
if (this.doc.caretRangeFromPoint) { |
| 35594 |
const caret = this.doc.caretRangeFromPoint(x, y); |
| 35595 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_7__.assert)(caret, 'Incorrect caretRangeFromPoint behaviour'); |
| 35596 |
rng.setStart(caret.startContainer, caret.startOffset); |
| 35597 |
} |
| 35598 |
})(); |
| 35599 |
rng.collapse(true); |
| 35600 |
this.selectRange(rng); |
| 35601 |
return true; |
| 35602 |
} catch (unused) {} |
| 35603 |
return false; |
| 35604 |
} |
| 35605 |
/** |
| 35606 |
* Check if editor has selection markers |
| 35607 |
*/ get hasMarkers() { |
| 35608 |
return Boolean(this.markers.length); |
| 35609 |
} |
| 35610 |
/** |
| 35611 |
* Check if editor has selection markers |
| 35612 |
*/ get markers() { |
| 35613 |
return (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.$$)('span[data-' + jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.MARKER_CLASS + ']', this.area); |
| 35614 |
} |
| 35615 |
/** |
| 35616 |
* Remove all markers |
| 35617 |
*/ removeMarkers() { |
| 35618 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeRemove.apply(null, this.markers); |
| 35619 |
} |
| 35620 |
/** |
| 35621 |
* Create marker element |
| 35622 |
*/ marker(atStart = false, range) { |
| 35623 |
let newRange = null; |
| 35624 |
if (range) { |
| 35625 |
newRange = range.cloneRange(); |
| 35626 |
newRange.collapse(atStart); |
| 35627 |
} |
| 35628 |
const marker = this.j.createInside.span(); |
| 35629 |
marker.id = jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.MARKER_CLASS + '_' + Number(new Date()) + '_' + String(Math.random()).slice(2); |
| 35630 |
marker.style.lineHeight = '0'; |
| 35631 |
marker.style.display = 'none'; |
| 35632 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.markTemporary(marker); |
| 35633 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.attr)(marker, 'data-' + jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.MARKER_CLASS, atStart ? 'start' : 'end'); |
| 35634 |
marker.appendChild(this.j.createInside.text(jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.INVISIBLE_SPACE)); |
| 35635 |
if (newRange) { |
| 35636 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isOrContains(this.area, atStart ? newRange.startContainer : newRange.endContainer)) { |
| 35637 |
// Here need do unsafe inserting |
| 35638 |
// Deny Dom.safeInsertNode(newRange, marker); |
| 35639 |
// Apply style -> Test Style module -> Base apply -> For selection <p><strong>|test|</strong></p> apply style {"element":"em","style":{"fontStyle":"italic"}} |
| 35640 |
newRange.insertNode(marker); |
| 35641 |
} |
| 35642 |
} |
| 35643 |
return marker; |
| 35644 |
} |
| 35645 |
/** |
| 35646 |
* Restores user selections using marker invisible elements in the DOM. |
| 35647 |
*/ restore() { |
| 35648 |
let range = false; |
| 35649 |
const markAttr = (start)=>`span[data-${jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.MARKER_CLASS}=${start ? 'start' : 'end'}]`; |
| 35650 |
const start = this.area.querySelector(markAttr(true)), end = this.area.querySelector(markAttr(false)); |
| 35651 |
if (!start) { |
| 35652 |
return; |
| 35653 |
} |
| 35654 |
range = this.createRange(); |
| 35655 |
if (!end) { |
| 35656 |
const previousNode = start.previousSibling; |
| 35657 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isText(previousNode)) { |
| 35658 |
range.setStart(previousNode, previousNode.nodeValue ? previousNode.nodeValue.length : 0); |
| 35659 |
} else { |
| 35660 |
range.setStartBefore(start); |
| 35661 |
} |
| 35662 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeRemove(start); |
| 35663 |
range.collapse(true); |
| 35664 |
} else { |
| 35665 |
range.setStartAfter(start); |
| 35666 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeRemove(start); |
| 35667 |
range.setEndBefore(end); |
| 35668 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeRemove(end); |
| 35669 |
} |
| 35670 |
if (range) { |
| 35671 |
this.selectRange(range); |
| 35672 |
} |
| 35673 |
} |
| 35674 |
fakes() { |
| 35675 |
const sel = this.sel; |
| 35676 |
if (!sel || !sel.rangeCount) { |
| 35677 |
return []; |
| 35678 |
} |
| 35679 |
const range = sel.getRangeAt(0); |
| 35680 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_7__.assert)(range, 'Range is null'); |
| 35681 |
const left = range.cloneRange(); |
| 35682 |
left.collapse(true); |
| 35683 |
const fakeLeft = this.j.createInside.fake(); |
| 35684 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeInsertNode(left, fakeLeft); |
| 35685 |
range.setStartBefore(fakeLeft); |
| 35686 |
const result = [ |
| 35687 |
fakeLeft |
| 35688 |
]; |
| 35689 |
if (!range.collapsed) { |
| 35690 |
const right = range.cloneRange(); |
| 35691 |
right.collapse(false); |
| 35692 |
const fakeRight = this.j.createInside.fake(); |
| 35693 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeInsertNode(right, fakeRight); |
| 35694 |
range.setEndAfter(fakeRight); |
| 35695 |
result.push(fakeRight); |
| 35696 |
} |
| 35697 |
this.selectRange(range); |
| 35698 |
return result; |
| 35699 |
} |
| 35700 |
restoreFakes(fakes) { |
| 35701 |
var _fakeLeft_parentNode, _fakeLeft_parentNode1, _fakeRight_parentNode, _fakeRight_parentNode1; |
| 35702 |
const nodes = fakes.filter((n)=>n.isConnected); |
| 35703 |
if (!nodes.length) { |
| 35704 |
return; |
| 35705 |
} |
| 35706 |
const [fakeLeft, fakeRight] = nodes; |
| 35707 |
const range = this.createRange(); |
| 35708 |
range.setStartAfter(fakeLeft); |
| 35709 |
if (fakeRight) { |
| 35710 |
range.setEndBefore(fakeRight); |
| 35711 |
} |
| 35712 |
this.selectRange(range); |
| 35713 |
if (((_fakeLeft_parentNode = fakeLeft.parentNode) === null || _fakeLeft_parentNode === void 0 ? void 0 : _fakeLeft_parentNode.firstChild) !== ((_fakeLeft_parentNode1 = fakeLeft.parentNode) === null || _fakeLeft_parentNode1 === void 0 ? void 0 : _fakeLeft_parentNode1.lastChild)) { |
| 35714 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeRemove(fakeLeft); |
| 35715 |
} |
| 35716 |
if ((fakeRight === null || fakeRight === void 0 ? void 0 : (_fakeRight_parentNode = fakeRight.parentNode) === null || _fakeRight_parentNode === void 0 ? void 0 : _fakeRight_parentNode.firstChild) !== (fakeRight === null || fakeRight === void 0 ? void 0 : (_fakeRight_parentNode1 = fakeRight.parentNode) === null || _fakeRight_parentNode1 === void 0 ? void 0 : _fakeRight_parentNode1.lastChild)) { |
| 35717 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeRemove(fakeRight); |
| 35718 |
} |
| 35719 |
} |
| 35720 |
/** |
| 35721 |
* Saves selections using marker invisible elements in the DOM. |
| 35722 |
* @param silent - Do not change current range |
| 35723 |
*/ save(silent = false) { |
| 35724 |
if (this.hasMarkers) { |
| 35725 |
return []; |
| 35726 |
} |
| 35727 |
const sel = this.sel; |
| 35728 |
if (!sel || !sel.rangeCount) { |
| 35729 |
return []; |
| 35730 |
} |
| 35731 |
const info = [], length = sel.rangeCount, ranges = []; |
| 35732 |
for(let i = 0; i < length; i += 1){ |
| 35733 |
ranges[i] = sel.getRangeAt(i); |
| 35734 |
if (ranges[i].collapsed) { |
| 35735 |
const start = this.marker(true, ranges[i]); |
| 35736 |
info[i] = { |
| 35737 |
startId: start.id, |
| 35738 |
collapsed: true, |
| 35739 |
startMarker: start.outerHTML |
| 35740 |
}; |
| 35741 |
} else { |
| 35742 |
const start = this.marker(true, ranges[i]); |
| 35743 |
const end = this.marker(false, ranges[i]); |
| 35744 |
info[i] = { |
| 35745 |
startId: start.id, |
| 35746 |
endId: end.id, |
| 35747 |
collapsed: false, |
| 35748 |
startMarker: start.outerHTML, |
| 35749 |
endMarker: end.outerHTML |
| 35750 |
}; |
| 35751 |
} |
| 35752 |
} |
| 35753 |
if (!silent) { |
| 35754 |
sel.removeAllRanges(); |
| 35755 |
for(let i = length - 1; i >= 0; --i){ |
| 35756 |
const startElm = this.doc.getElementById(info[i].startId); |
| 35757 |
if (!startElm) { |
| 35758 |
continue; |
| 35759 |
} |
| 35760 |
if (info[i].collapsed) { |
| 35761 |
ranges[i].setStartAfter(startElm); |
| 35762 |
ranges[i].collapse(true); |
| 35763 |
} else { |
| 35764 |
ranges[i].setStartBefore(startElm); |
| 35765 |
if (info[i].endId) { |
| 35766 |
const endElm = this.doc.getElementById(info[i].endId); |
| 35767 |
if (endElm) { |
| 35768 |
ranges[i].setEndAfter(endElm); |
| 35769 |
} |
| 35770 |
} |
| 35771 |
} |
| 35772 |
try { |
| 35773 |
sel.addRange(ranges[i].cloneRange()); |
| 35774 |
} catch (unused) {} |
| 35775 |
} |
| 35776 |
} |
| 35777 |
return info; |
| 35778 |
} |
| 35779 |
/** |
| 35780 |
* Set focus in editor |
| 35781 |
*/ focus(options = { |
| 35782 |
preventScroll: true |
| 35783 |
}) { |
| 35784 |
if (!this.isFocused()) { |
| 35785 |
const scrollParent = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.getScrollParent)(this.j.container), scrollTop = scrollParent === null || scrollParent === void 0 ? void 0 : scrollParent.scrollTop; |
| 35786 |
if (this.j.iframe) { |
| 35787 |
if (this.doc.readyState === 'complete') { |
| 35788 |
this.j.iframe.focus(options); |
| 35789 |
} |
| 35790 |
} |
| 35791 |
this.win.focus(); |
| 35792 |
this.area.focus(options); |
| 35793 |
if (scrollTop && (scrollParent === null || scrollParent === void 0 ? void 0 : scrollParent.scrollTo)) { |
| 35794 |
scrollParent.scrollTo(0, scrollTop); |
| 35795 |
} |
| 35796 |
const sel = this.sel, range = (sel === null || sel === void 0 ? void 0 : sel.rangeCount) ? sel === null || sel === void 0 ? void 0 : sel.getRangeAt(0) : null; |
| 35797 |
if (!range || !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isOrContains(this.area, range.startContainer)) { |
| 35798 |
const range = this.createRange(); |
| 35799 |
range.setStart(this.area, 0); |
| 35800 |
range.collapse(true); |
| 35801 |
this.selectRange(range, false); |
| 35802 |
} |
| 35803 |
if (!this.j.editorIsActive) { |
| 35804 |
var _this_j_events, _this_j; |
| 35805 |
(_this_j = this.j) === null || _this_j === void 0 ? void 0 : (_this_j_events = _this_j.events) === null || _this_j_events === void 0 ? void 0 : _this_j_events.fire('focus'); |
| 35806 |
} |
| 35807 |
return true; |
| 35808 |
} |
| 35809 |
return false; |
| 35810 |
} |
| 35811 |
/** |
| 35812 |
* Checks whether the current selection is something or just set the cursor is |
| 35813 |
* @returns true Selection does't have content |
| 35814 |
*/ isCollapsed() { |
| 35815 |
const sel = this.sel; |
| 35816 |
for(let r = 0; sel && r < sel.rangeCount; r += 1){ |
| 35817 |
if (!sel.getRangeAt(r).collapsed) { |
| 35818 |
return false; |
| 35819 |
} |
| 35820 |
} |
| 35821 |
return true; |
| 35822 |
} |
| 35823 |
/** |
| 35824 |
* Checks whether the editor currently in focus |
| 35825 |
*/ isFocused() { |
| 35826 |
return this.doc.hasFocus && this.doc.hasFocus() && this.area === this.doc.activeElement; |
| 35827 |
} |
| 35828 |
/** |
| 35829 |
* Returns the current element under the cursor inside editor |
| 35830 |
*/ current(checkChild = true) { |
| 35831 |
if (this.j.getRealMode() !== jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.MODE_WYSIWYG) { |
| 35832 |
return null; |
| 35833 |
} |
| 35834 |
const sel = this.sel; |
| 35835 |
if (!sel || sel.rangeCount === 0) { |
| 35836 |
return null; |
| 35837 |
} |
| 35838 |
const range = sel.getRangeAt(0); |
| 35839 |
let node = range.startContainer; |
| 35840 |
let rightMode = false; |
| 35841 |
const child = (nd)=>rightMode ? nd.lastChild : nd.firstChild; |
| 35842 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isTag(node, 'br') && sel.isCollapsed) { |
| 35843 |
return node; |
| 35844 |
} |
| 35845 |
if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isText(node)) { |
| 35846 |
const ret = (0,_helpers__WEBPACK_IMPORTED_MODULE_10__.findCorrectCurrentNode)(node, range, rightMode, sel.isCollapsed, checkChild, child); |
| 35847 |
node = ret.node; |
| 35848 |
rightMode = ret.rightMode; |
| 35849 |
} |
| 35850 |
// check - cursor inside editor |
| 35851 |
if (node && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isOrContains(this.area, node)) { |
| 35852 |
return node; |
| 35853 |
} |
| 35854 |
return null; |
| 35855 |
} |
| 35856 |
/** |
| 35857 |
* Insert element in editor |
| 35858 |
* |
| 35859 |
* @param node - Node for insert |
| 35860 |
* @param insertCursorAfter - After insert, cursor will move after element |
| 35861 |
* @param fireChange - After insert, editor fire change event. You can prevent this behavior |
| 35862 |
*/ insertNode(node, insertCursorAfter = true, fireChange = true) { |
| 35863 |
this.errorNode(node); |
| 35864 |
const child = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isFragment(node) ? node.lastChild : node; |
| 35865 |
this.j.e.fire('safeHTML', node); |
| 35866 |
if (!this.isFocused() && this.j.isEditorMode()) { |
| 35867 |
this.focus(); |
| 35868 |
this.restore(); |
| 35869 |
} |
| 35870 |
const sel = this.sel; |
| 35871 |
this.j.history.snapshot.transaction(()=>{ |
| 35872 |
if (!this.isCollapsed()) { |
| 35873 |
this.j.execCommand('Delete'); |
| 35874 |
} |
| 35875 |
this.j.e.fire('beforeInsertNode', node); |
| 35876 |
if (sel && sel.rangeCount) { |
| 35877 |
const range = sel.getRangeAt(0); |
| 35878 |
const { firstChild } = node; |
| 35879 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isOrContains(this.area, range.commonAncestorContainer)) { |
| 35880 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeInsertNode(range, node); |
| 35881 |
} else { |
| 35882 |
this.area.appendChild(node); |
| 35883 |
} |
| 35884 |
[ |
| 35885 |
()=>firstChild === null || firstChild === void 0 ? void 0 : firstChild.previousSibling, |
| 35886 |
()=>firstChild === null || firstChild === void 0 ? void 0 : firstChild.previousSibling, |
| 35887 |
()=>{ |
| 35888 |
var _firstChild_previousSibling; |
| 35889 |
return firstChild === null || firstChild === void 0 ? void 0 : (_firstChild_previousSibling = firstChild.previousSibling) === null || _firstChild_previousSibling === void 0 ? void 0 : _firstChild_previousSibling.lastChild; |
| 35890 |
} |
| 35891 |
].forEach((getChildNode)=>{ |
| 35892 |
const childNode = getChildNode(); |
| 35893 |
if (childNode && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isEmptyTextNode(childNode)) { |
| 35894 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeRemove(childNode); |
| 35895 |
} |
| 35896 |
}); |
| 35897 |
} else { |
| 35898 |
this.area.appendChild(node); |
| 35899 |
} |
| 35900 |
const setCursor = (node)=>{ |
| 35901 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isBlock(node)) { |
| 35902 |
const child = node.lastChild; |
| 35903 |
if (child) { |
| 35904 |
return setCursor(child); |
| 35905 |
} |
| 35906 |
} |
| 35907 |
this.setCursorAfter(node); |
| 35908 |
}; |
| 35909 |
if (insertCursorAfter) { |
| 35910 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isFragment(node)) { |
| 35911 |
child && setCursor(child); |
| 35912 |
} else { |
| 35913 |
setCursor(node); |
| 35914 |
} |
| 35915 |
} |
| 35916 |
if (this.j.o.scrollToPastedContent) { |
| 35917 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.scrollIntoViewIfNeeded)(child !== null && child !== void 0 ? child : node, this.j.editor, this.doc); |
| 35918 |
} |
| 35919 |
}); |
| 35920 |
if (fireChange && this.j.events) { |
| 35921 |
this.j.__imdSynchronizeValues(); |
| 35922 |
} |
| 35923 |
if (this.j.events) { |
| 35924 |
this.j.e.fire('afterInsertNode', jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isFragment(node) ? child : node); |
| 35925 |
} |
| 35926 |
} |
| 35927 |
/** |
| 35928 |
* Inserts in the current cursor position some HTML snippet |
| 35929 |
* |
| 35930 |
* @param html - HTML The text to be inserted into the document |
| 35931 |
* @param insertCursorAfter - After insert, cursor will move after element |
| 35932 |
* @example |
| 35933 |
* ```javascript |
| 35934 |
* parent.s.insertHTML('<img src="image.png"/>'); |
| 35935 |
* ``` |
| 35936 |
*/ insertHTML(html, insertCursorAfter = true) { |
| 35937 |
if (html === '') { |
| 35938 |
return; |
| 35939 |
} |
| 35940 |
const node = this.j.createInside.div(); |
| 35941 |
const fragment = this.j.createInside.fragment(); |
| 35942 |
let lastChild; |
| 35943 |
if (!this.isFocused() && this.j.isEditorMode()) { |
| 35944 |
this.focus(); |
| 35945 |
this.restore(); |
| 35946 |
} |
| 35947 |
if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isNode(html)) { |
| 35948 |
node.innerHTML = html.toString(); |
| 35949 |
} else { |
| 35950 |
node.appendChild(html); |
| 35951 |
} |
| 35952 |
if (!this.j.isEditorMode() && this.j.e.fire('insertHTML', node.innerHTML) === false) { |
| 35953 |
return; |
| 35954 |
} |
| 35955 |
lastChild = node.lastChild; |
| 35956 |
if (!lastChild) { |
| 35957 |
return; |
| 35958 |
} |
| 35959 |
while(node.firstChild){ |
| 35960 |
lastChild = node.firstChild; |
| 35961 |
fragment.appendChild(node.firstChild); |
| 35962 |
} |
| 35963 |
this.insertNode(fragment, insertCursorAfter, false); |
| 35964 |
// There is no need to use synchronizeValues because you need to apply the changes immediately |
| 35965 |
this.j.__imdSynchronizeValues(); |
| 35966 |
} |
| 35967 |
/** |
| 35968 |
* Insert image in editor |
| 35969 |
* |
| 35970 |
* @param url - URL for image, or HTMLImageElement |
| 35971 |
* @param styles - If specified, it will be applied <code>$(image).css(styles)</code> |
| 35972 |
* @param defaultWidth - If specified, it will be applied <code>css('width', defaultWidth)</code> |
| 35973 |
*/ insertImage(url, styles = null, defaultWidth = null) { |
| 35974 |
const image = (0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_6__.isString)(url) ? this.j.createInside.element('img') : url; |
| 35975 |
if ((0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_6__.isString)(url)) { |
| 35976 |
image.setAttribute('src', url); |
| 35977 |
} |
| 35978 |
if (defaultWidth != null) { |
| 35979 |
let dw = defaultWidth.toString(); |
| 35980 |
if (dw && 'auto' !== dw && String(dw).indexOf('px') < 0 && String(dw).indexOf('%') < 0) { |
| 35981 |
dw += 'px'; |
| 35982 |
} |
| 35983 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.attr)(image, 'width', dw); |
| 35984 |
} |
| 35985 |
if (styles && typeof styles === 'object') { |
| 35986 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.css)(image, styles); |
| 35987 |
} |
| 35988 |
const onload = ()=>{ |
| 35989 |
if (image.naturalHeight < image.offsetHeight || image.naturalWidth < image.offsetWidth) { |
| 35990 |
image.style.width = ''; |
| 35991 |
image.style.height = ''; |
| 35992 |
} |
| 35993 |
image.removeEventListener('load', onload); |
| 35994 |
}; |
| 35995 |
this.j.e.on(image, 'load', onload); |
| 35996 |
if (image.complete) { |
| 35997 |
onload(); |
| 35998 |
} |
| 35999 |
this.insertNode(image); |
| 36000 |
/** |
| 36001 |
* Triggered after image was inserted [[Select.insertImage]]. This method can executed from |
| 36002 |
* [[FileBrowser]] or [[Uploader]] |
| 36003 |
* @example |
| 36004 |
* ```javascript |
| 36005 |
* const editor = Jodit.make("#redactor"); |
| 36006 |
* editor.e.on('afterInsertImage', function (image) { |
| 36007 |
* image.className = 'bloghead4'; |
| 36008 |
* }); |
| 36009 |
* ``` |
| 36010 |
*/ this.j.e.fire('afterInsertImage', image); |
| 36011 |
} |
| 36012 |
/** |
| 36013 |
* Call callback for all selection node |
| 36014 |
*/ // eslint-disable-next-line complexity |
| 36015 |
eachSelection(callback) { |
| 36016 |
var _start_nodeValue; |
| 36017 |
const sel = this.sel; |
| 36018 |
if (!sel || !sel.rangeCount) { |
| 36019 |
return; |
| 36020 |
} |
| 36021 |
const range = sel.getRangeAt(0); |
| 36022 |
let root = range.commonAncestorContainer; |
| 36023 |
if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isHTMLElement(root)) { |
| 36024 |
root = root.parentElement; |
| 36025 |
} |
| 36026 |
const nodes = []; |
| 36027 |
const startOffset = range.startOffset; |
| 36028 |
const length = root.childNodes.length; |
| 36029 |
const elementOffset = startOffset < length ? startOffset : length - 1; |
| 36030 |
let start = range.startContainer === this.area ? root.childNodes[elementOffset] : range.startContainer; |
| 36031 |
let end = range.endContainer === this.area ? root.childNodes[range.endOffset - 1] : range.endContainer; |
| 36032 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isText(start) && start === range.startContainer && range.startOffset === ((_start_nodeValue = start.nodeValue) === null || _start_nodeValue === void 0 ? void 0 : _start_nodeValue.length) && start.nextSibling) { |
| 36033 |
start = start.nextSibling; |
| 36034 |
} |
| 36035 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isText(end) && end === range.endContainer && range.endOffset === 0 && end.previousSibling) { |
| 36036 |
end = end.previousSibling; |
| 36037 |
} |
| 36038 |
const checkElm = (node)=>{ |
| 36039 |
if (node && node !== root && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isEmptyTextNode(node) && !(0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_6__.isMarker)(node)) { |
| 36040 |
nodes.push(node); |
| 36041 |
} |
| 36042 |
}; |
| 36043 |
checkElm(start); |
| 36044 |
if (start !== end && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isOrContains(root, start, true)) { |
| 36045 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.find(start, (node)=>{ |
| 36046 |
checkElm(node); |
| 36047 |
// checks parentElement as well because partial selections are not equal to entire element |
| 36048 |
return node === end || node && node.contains && node.contains(end); |
| 36049 |
}, root, true, false); |
| 36050 |
} |
| 36051 |
const forEvery = (current)=>{ |
| 36052 |
if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isOrContains(this.j.editor, current, true)) { |
| 36053 |
return; |
| 36054 |
} |
| 36055 |
if (current.nodeName.match(/^(UL|OL)$/)) { |
| 36056 |
return (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.toArray)(current.childNodes).forEach(forEvery); |
| 36057 |
} |
| 36058 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isTag(current, 'li')) { |
| 36059 |
if (current.firstChild) { |
| 36060 |
current = current.firstChild; |
| 36061 |
} else { |
| 36062 |
const currentB = this.j.createInside.text(jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.INVISIBLE_SPACE); |
| 36063 |
current.appendChild(currentB); |
| 36064 |
current = currentB; |
| 36065 |
} |
| 36066 |
} |
| 36067 |
callback(current); |
| 36068 |
}; |
| 36069 |
if (nodes.length === 0) { |
| 36070 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isEmptyTextNode(start)) { |
| 36071 |
nodes.push(start); |
| 36072 |
} |
| 36073 |
if (start.firstChild) { |
| 36074 |
nodes.push(start.firstChild); |
| 36075 |
} |
| 36076 |
} |
| 36077 |
nodes.forEach(forEvery); |
| 36078 |
} |
| 36079 |
/** |
| 36080 |
* Checks if the cursor is at the end(start) block |
| 36081 |
* |
| 36082 |
* @param start - true - check whether the cursor is at the start block |
| 36083 |
* @param parentBlock - Find in this |
| 36084 |
* @param fake - Node for cursor position |
| 36085 |
* |
| 36086 |
* @returns true - the cursor is at the end(start) block, null - cursor somewhere outside |
| 36087 |
*/ cursorInTheEdge(start, parentBlock, fake = null) { |
| 36088 |
var _this_sel; |
| 36089 |
const end = !start, range = (_this_sel = this.sel) === null || _this_sel === void 0 ? void 0 : _this_sel.getRangeAt(0); |
| 36090 |
fake !== null && fake !== void 0 ? fake : fake = this.current(false); |
| 36091 |
if (!range || !fake || !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isOrContains(parentBlock, fake, true)) { |
| 36092 |
return null; |
| 36093 |
} |
| 36094 |
const container = start ? range.startContainer : range.endContainer; |
| 36095 |
const offset = start ? range.startOffset : range.endOffset; |
| 36096 |
const isSignificant = (elm)=>Boolean(elm && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isTag(elm, 'br') && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isEmptyTextNode(elm) && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isTemporary(elm) && !(jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isElement(elm) && this.j.e.fire('isInvisibleForCursor', elm) === true)); |
| 36097 |
// check right offset |
| 36098 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isText(container)) { |
| 36099 |
if ((0,_helpers__WEBPACK_IMPORTED_MODULE_10__.cursorInTheEdgeOfString)(container, offset, start, end)) { |
| 36100 |
return false; |
| 36101 |
} |
| 36102 |
} else { |
| 36103 |
const children = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.toArray)(container.childNodes); |
| 36104 |
if (end) { |
| 36105 |
if (children.slice(offset).some(isSignificant)) { |
| 36106 |
return false; |
| 36107 |
} |
| 36108 |
} else { |
| 36109 |
if (children.slice(0, offset).some(isSignificant)) { |
| 36110 |
return false; |
| 36111 |
} |
| 36112 |
} |
| 36113 |
} |
| 36114 |
let next = fake; |
| 36115 |
while(next && next !== parentBlock){ |
| 36116 |
const nextOne = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.sibling(next, start); |
| 36117 |
if (!nextOne) { |
| 36118 |
next = next.parentNode; |
| 36119 |
continue; |
| 36120 |
} |
| 36121 |
next = nextOne; |
| 36122 |
if (next && isSignificant(next)) { |
| 36123 |
return false; |
| 36124 |
} |
| 36125 |
} |
| 36126 |
return true; |
| 36127 |
} |
| 36128 |
/** |
| 36129 |
* Wrapper for cursorInTheEdge |
| 36130 |
*/ cursorOnTheLeft(parentBlock, fake) { |
| 36131 |
return this.cursorInTheEdge(true, parentBlock, fake); |
| 36132 |
} |
| 36133 |
/** |
| 36134 |
* Wrapper for cursorInTheEdge |
| 36135 |
*/ cursorOnTheRight(parentBlock, fake) { |
| 36136 |
return this.cursorInTheEdge(false, parentBlock, fake); |
| 36137 |
} |
| 36138 |
/** |
| 36139 |
* Set cursor after the node |
| 36140 |
* @returns fake invisible textnode. After insert it can be removed |
| 36141 |
*/ setCursorAfter(node) { |
| 36142 |
return this.setCursorNearWith(node, false); |
| 36143 |
} |
| 36144 |
/** |
| 36145 |
* Set cursor before the node |
| 36146 |
* @returns fake invisible textnode. After insert it can be removed |
| 36147 |
*/ setCursorBefore(node) { |
| 36148 |
return this.setCursorNearWith(node, true); |
| 36149 |
} |
| 36150 |
/** |
| 36151 |
* Add fake node for new cursor position |
| 36152 |
*/ setCursorNearWith(node, inStart) { |
| 36153 |
this.errorNode(node); |
| 36154 |
if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.up(node, (elm)=>elm === this.area || elm && elm.parentNode === this.area, this.area)) { |
| 36155 |
throw (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.error)('Node element must be in editor'); |
| 36156 |
} |
| 36157 |
const range = this.createRange(); |
| 36158 |
let fakeNode = null; |
| 36159 |
if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isText(node)) { |
| 36160 |
fakeNode = this.j.createInside.fake(); |
| 36161 |
inStart ? range.setStartBefore(node) : range.setEndAfter(node); |
| 36162 |
range.collapse(inStart); |
| 36163 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeInsertNode(range, fakeNode); |
| 36164 |
range.selectNode(fakeNode); |
| 36165 |
} else { |
| 36166 |
if (inStart) { |
| 36167 |
range.setStart(node, 0); |
| 36168 |
} else { |
| 36169 |
var _ref; |
| 36170 |
var _node_nodeValue; |
| 36171 |
range.setEnd(node, (_ref = (_node_nodeValue = node.nodeValue) === null || _node_nodeValue === void 0 ? void 0 : _node_nodeValue.length) !== null && _ref !== void 0 ? _ref : 0); |
| 36172 |
} |
| 36173 |
} |
| 36174 |
range.collapse(inStart); |
| 36175 |
this.selectRange(range); |
| 36176 |
return fakeNode; |
| 36177 |
} |
| 36178 |
/** |
| 36179 |
* Set cursor in the node |
| 36180 |
* @param node - Node element |
| 36181 |
* @param inStart - set cursor in start of element |
| 36182 |
*/ setCursorIn(node, inStart = false) { |
| 36183 |
this.errorNode(node); |
| 36184 |
if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.up(node, (elm)=>elm === this.area || elm && elm.parentNode === this.area, this.area)) { |
| 36185 |
throw (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.error)('Node element must be in editor'); |
| 36186 |
} |
| 36187 |
const range = this.createRange(); |
| 36188 |
let start = node, last = node; |
| 36189 |
do { |
| 36190 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isText(start) || jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isTag(start, jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.INSEPARABLE_TAGS)) { |
| 36191 |
break; |
| 36192 |
} |
| 36193 |
last = start; |
| 36194 |
start = inStart ? start.firstChild : start.lastChild; |
| 36195 |
}while (start) |
| 36196 |
if (!start) { |
| 36197 |
const fakeNode = this.j.createInside.text(jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.INVISIBLE_SPACE); |
| 36198 |
if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isTag(last, jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.INSEPARABLE_TAGS)) { |
| 36199 |
last.appendChild(fakeNode); |
| 36200 |
last = fakeNode; |
| 36201 |
} else { |
| 36202 |
start = last; |
| 36203 |
} |
| 36204 |
} |
| 36205 |
const workElm = start || last; |
| 36206 |
if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isTag(workElm, jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.INSEPARABLE_TAGS)) { |
| 36207 |
range.selectNodeContents(workElm); |
| 36208 |
range.collapse(inStart); |
| 36209 |
} else { |
| 36210 |
inStart || jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isTag(workElm, 'br') ? range.setStartBefore(workElm) : range.setEndAfter(workElm); |
| 36211 |
range.collapse(inStart); |
| 36212 |
} |
| 36213 |
this.selectRange(range); |
| 36214 |
return last; |
| 36215 |
} |
| 36216 |
/** |
| 36217 |
* Set range selection |
| 36218 |
*/ selectRange(range, focus = true) { |
| 36219 |
const sel = this.sel; |
| 36220 |
if (focus && !this.isFocused()) { |
| 36221 |
this.focus(); |
| 36222 |
} |
| 36223 |
if (sel) { |
| 36224 |
sel.removeAllRanges(); |
| 36225 |
sel.addRange(range); |
| 36226 |
} |
| 36227 |
/** |
| 36228 |
* Fired after change selection |
| 36229 |
*/ this.j.e.fire('changeSelection'); |
| 36230 |
return this; |
| 36231 |
} |
| 36232 |
/** |
| 36233 |
* Select node |
| 36234 |
* @param node - Node element |
| 36235 |
* @param inward - select all inside |
| 36236 |
*/ select(node, inward = false) { |
| 36237 |
this.errorNode(node); |
| 36238 |
if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.up(node, (elm)=>elm === this.area || elm && elm.parentNode === this.area, this.area)) { |
| 36239 |
throw (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.error)('Node element must be in editor'); |
| 36240 |
} |
| 36241 |
const range = this.createRange(); |
| 36242 |
range[inward ? 'selectNodeContents' : 'selectNode'](node); |
| 36243 |
return this.selectRange(range); |
| 36244 |
} |
| 36245 |
/** |
| 36246 |
* Return current selected HTML |
| 36247 |
* @example |
| 36248 |
* ```javascript |
| 36249 |
* const editor = Jodit.make(); |
| 36250 |
* console.log(editor.s.html); // html |
| 36251 |
* console.log(Jodit.modules.Helpers.stripTags(editor.s.html)); // plain text |
| 36252 |
* ``` |
| 36253 |
*/ get html() { |
| 36254 |
const sel = this.sel; |
| 36255 |
if (sel && sel.rangeCount > 0) { |
| 36256 |
const range = sel.getRangeAt(0); |
| 36257 |
const clonedSelection = range.cloneContents(); |
| 36258 |
const div = this.j.createInside.div(); |
| 36259 |
div.appendChild(clonedSelection); |
| 36260 |
return div.innerHTML; |
| 36261 |
} |
| 36262 |
return ''; |
| 36263 |
} |
| 36264 |
/** |
| 36265 |
* Wrap all selected fragments inside Tag or apply some callback |
| 36266 |
*/ *wrapInTagGen(fakes) { |
| 36267 |
if (this.isCollapsed()) { |
| 36268 |
const font = this.jodit.createInside.element('font', jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.INVISIBLE_SPACE); |
| 36269 |
this.insertNode(font, false, false); |
| 36270 |
if (fakes && fakes[0]) { |
| 36271 |
font.appendChild(fakes[0]); |
| 36272 |
} |
| 36273 |
yield font; |
| 36274 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.unwrap(font); |
| 36275 |
return; |
| 36276 |
} |
| 36277 |
// fix issue https://github.com/xdan/jodit/issues/65 |
| 36278 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.$$)('*[style*=font-size]', this.area).forEach((elm)=>{ |
| 36279 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.attr)(elm, 'data-font-size', elm.style.fontSize.toString()); |
| 36280 |
elm.style.removeProperty('font-size'); |
| 36281 |
}); |
| 36282 |
this.j.nativeExecCommand('fontsize', false, '7'); |
| 36283 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.$$)('*[data-font-size]', this.area).forEach((elm)=>{ |
| 36284 |
const fontSize = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.attr)(elm, 'data-font-size'); |
| 36285 |
if (fontSize) { |
| 36286 |
elm.style.fontSize = fontSize; |
| 36287 |
(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.attr)(elm, 'data-font-size', null); |
| 36288 |
} |
| 36289 |
}); |
| 36290 |
const elms = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.$$)('font[size="7"]', this.area); |
| 36291 |
for (const font of elms){ |
| 36292 |
const { firstChild, lastChild } = font; |
| 36293 |
if (firstChild && firstChild === lastChild && (0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_6__.isMarker)(firstChild)) { |
| 36294 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.unwrap(font); |
| 36295 |
continue; |
| 36296 |
} |
| 36297 |
if (firstChild && (0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_6__.isMarker)(firstChild)) { |
| 36298 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.before(font, firstChild); |
| 36299 |
} |
| 36300 |
if (lastChild && (0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_6__.isMarker)(lastChild)) { |
| 36301 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.after(font, lastChild); |
| 36302 |
} |
| 36303 |
yield font; |
| 36304 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.unwrap(font); |
| 36305 |
} |
| 36306 |
return; |
| 36307 |
} |
| 36308 |
/** |
| 36309 |
* Wrap all selected fragments inside Tag or apply some callback |
| 36310 |
*/ wrapInTag(tagOrCallback) { |
| 36311 |
const result = []; |
| 36312 |
for (const font of this.wrapInTagGen()){ |
| 36313 |
try { |
| 36314 |
if (font.firstChild && font.firstChild === font.lastChild && (0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_6__.isMarker)(font.firstChild)) { |
| 36315 |
continue; |
| 36316 |
} |
| 36317 |
if ((0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_6__.isFunction)(tagOrCallback)) { |
| 36318 |
tagOrCallback(font); |
| 36319 |
} else { |
| 36320 |
result.push(jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.replace(font, tagOrCallback, this.j.createInside)); |
| 36321 |
} |
| 36322 |
} finally{ |
| 36323 |
const pn = font.parentNode; |
| 36324 |
if (pn) { |
| 36325 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.unwrap(font); |
| 36326 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isEmpty(pn)) { |
| 36327 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.unwrap(pn); |
| 36328 |
} |
| 36329 |
} |
| 36330 |
} |
| 36331 |
} |
| 36332 |
return result; |
| 36333 |
} |
| 36334 |
/** |
| 36335 |
* Apply some css rules for all selections. It method wraps selections in nodeName tag. |
| 36336 |
* @example |
| 36337 |
* ```js |
| 36338 |
* const editor = Jodit.make('#editor'); |
| 36339 |
* editor.value = 'test'; |
| 36340 |
* editor.execCommand('selectall'); |
| 36341 |
* |
| 36342 |
* editor.s.commitStyle({ |
| 36343 |
* style: {color: 'red'} |
| 36344 |
* }) // will wrap `text` in `span` and add style `color:red` |
| 36345 |
* editor.s.commitStyle({ |
| 36346 |
* style: {color: 'red'} |
| 36347 |
* }) // will remove `color:red` from `span` |
| 36348 |
* ``` |
| 36349 |
*/ commitStyle(options) { |
| 36350 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_7__.assert)((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.size)(options) > 0, 'Need to pass at least one option'); |
| 36351 |
const styleElm = new _style_commit_style__WEBPACK_IMPORTED_MODULE_9__.CommitStyle(options); |
| 36352 |
styleElm.apply(this.j); |
| 36353 |
} |
| 36354 |
/** |
| 36355 |
* Split selection on two parts: left and right |
| 36356 |
*/ splitSelection(currentBox, edge) { |
| 36357 |
if (!this.isCollapsed()) { |
| 36358 |
return null; |
| 36359 |
} |
| 36360 |
const leftRange = this.createRange(); |
| 36361 |
const range = this.range; |
| 36362 |
leftRange.setStartBefore(currentBox); |
| 36363 |
const cursorOnTheRight = this.cursorOnTheRight(currentBox, edge); |
| 36364 |
const cursorOnTheLeft = this.cursorOnTheLeft(currentBox, edge); |
| 36365 |
const br = this.j.createInside.element('br'), prevFake = this.j.createInside.fake(), nextFake = prevFake.cloneNode(); |
| 36366 |
try { |
| 36367 |
if (cursorOnTheRight || cursorOnTheLeft) { |
| 36368 |
if (edge) { |
| 36369 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.before(edge, br); |
| 36370 |
} else { |
| 36371 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeInsertNode(range, br); |
| 36372 |
} |
| 36373 |
const clearBR = (start, getNext)=>{ |
| 36374 |
let next = getNext(start); |
| 36375 |
while(next){ |
| 36376 |
const nextSib = getNext(next); |
| 36377 |
if (next && (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isTag(next, 'br') || jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isEmptyTextNode(next))) { |
| 36378 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeRemove(next); |
| 36379 |
} else { |
| 36380 |
break; |
| 36381 |
} |
| 36382 |
next = nextSib; |
| 36383 |
} |
| 36384 |
}; |
| 36385 |
clearBR(br, (n)=>n.nextSibling); |
| 36386 |
clearBR(br, (n)=>n.previousSibling); |
| 36387 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.after(br, nextFake); |
| 36388 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.before(br, prevFake); |
| 36389 |
if (cursorOnTheRight) { |
| 36390 |
leftRange.setEndBefore(br); |
| 36391 |
range.setEndBefore(br); |
| 36392 |
} else { |
| 36393 |
leftRange.setEndAfter(br); |
| 36394 |
range.setEndAfter(br); |
| 36395 |
} |
| 36396 |
} else { |
| 36397 |
leftRange.setEnd(range.startContainer, range.startOffset); |
| 36398 |
} |
| 36399 |
const fragment = leftRange.extractContents(); |
| 36400 |
const clearEmpties = (node)=>jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.each(node, (node)=>jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isEmptyTextNode(node) && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeRemove(node)); |
| 36401 |
(0,jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_7__.assert)(currentBox.parentNode, 'Splitting fails'); |
| 36402 |
try { |
| 36403 |
clearEmpties(fragment); |
| 36404 |
clearEmpties(currentBox); |
| 36405 |
currentBox.parentNode.insertBefore(fragment, currentBox); |
| 36406 |
if (!edge && cursorOnTheRight && (br === null || br === void 0 ? void 0 : br.parentNode)) { |
| 36407 |
const range = this.createRange(); |
| 36408 |
range.setStartBefore(br); |
| 36409 |
this.selectRange(range); |
| 36410 |
} |
| 36411 |
} catch (e) { |
| 36412 |
if (!jodit_core_constants__WEBPACK_IMPORTED_MODULE_2__.IS_PROD) { |
| 36413 |
throw e; |
| 36414 |
} |
| 36415 |
} |
| 36416 |
// After splitting some part can be empty |
| 36417 |
const fillFakeParent = (fake)=>{ |
| 36418 |
var _fake_parentNode, _fake_parentNode1; |
| 36419 |
if ((fake === null || fake === void 0 ? void 0 : (_fake_parentNode = fake.parentNode) === null || _fake_parentNode === void 0 ? void 0 : _fake_parentNode.firstChild) === (fake === null || fake === void 0 ? void 0 : (_fake_parentNode1 = fake.parentNode) === null || _fake_parentNode1 === void 0 ? void 0 : _fake_parentNode1.lastChild)) { |
| 36420 |
var _fake_parentNode2; |
| 36421 |
fake === null || fake === void 0 ? void 0 : (_fake_parentNode2 = fake.parentNode) === null || _fake_parentNode2 === void 0 ? void 0 : _fake_parentNode2.appendChild(br.cloneNode()); |
| 36422 |
} |
| 36423 |
}; |
| 36424 |
fillFakeParent(prevFake); |
| 36425 |
fillFakeParent(nextFake); |
| 36426 |
} finally{ |
| 36427 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeRemove(prevFake); |
| 36428 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeRemove(nextFake); |
| 36429 |
} |
| 36430 |
return currentBox.previousElementSibling; |
| 36431 |
} |
| 36432 |
expandSelection() { |
| 36433 |
if (this.isCollapsed()) { |
| 36434 |
return this; |
| 36435 |
} |
| 36436 |
const { range } = this; |
| 36437 |
const c = range.cloneRange(); |
| 36438 |
if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isOrContains(this.j.editor, range.commonAncestorContainer, true)) { |
| 36439 |
return this; |
| 36440 |
} |
| 36441 |
const moveMaxEdgeFake = (start)=>{ |
| 36442 |
const fake = this.j.createInside.fake(); |
| 36443 |
const r = range.cloneRange(); |
| 36444 |
r.collapse(start); |
| 36445 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeInsertNode(r, fake); |
| 36446 |
(0,jodit_core_selection_helpers_move_the_node_along_the_edge_outward__WEBPACK_IMPORTED_MODULE_8__.moveTheNodeAlongTheEdgeOutward)(fake, start, this.j.editor); |
| 36447 |
return fake; |
| 36448 |
}; |
| 36449 |
const leftFake = moveMaxEdgeFake(true); |
| 36450 |
const rightFake = moveMaxEdgeFake(false); |
| 36451 |
c.setStartAfter(leftFake); |
| 36452 |
c.setEndBefore(rightFake); |
| 36453 |
const leftBox = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.findSibling(leftFake, false); |
| 36454 |
const rightBox = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.findSibling(rightFake, true); |
| 36455 |
if (leftBox !== rightBox) { |
| 36456 |
const rightInsideLeft = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isElement(leftBox) && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isOrContains(leftBox, rightFake); |
| 36457 |
const leftInsideRight = !rightInsideLeft && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isElement(rightBox) && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isOrContains(rightBox, leftFake); |
| 36458 |
if (rightInsideLeft || leftInsideRight) { |
| 36459 |
let child = rightInsideLeft ? leftBox : rightBox, container = child; |
| 36460 |
while(jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isElement(child)){ |
| 36461 |
child = rightInsideLeft ? child.firstElementChild : child.lastElementChild; |
| 36462 |
if (child) { |
| 36463 |
const isInside = rightInsideLeft ? jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isOrContains(child, rightFake) : jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.isOrContains(child, leftFake); |
| 36464 |
if (isInside) { |
| 36465 |
container = child; |
| 36466 |
} |
| 36467 |
} |
| 36468 |
} |
| 36469 |
if (rightInsideLeft) { |
| 36470 |
c.setStart(container, 0); |
| 36471 |
} else { |
| 36472 |
c.setEnd(container, container.childNodes.length); |
| 36473 |
} |
| 36474 |
} |
| 36475 |
} |
| 36476 |
this.selectRange(c); |
| 36477 |
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_4__.Dom.safeRemove(leftFake, rightFake); |
| 36478 |
if (this.isCollapsed()) { |
| 36479 |
throw (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.error)('Selection is collapsed'); |
| 36480 |
} |
| 36481 |
return this; |
| 36482 |
} |
| 36483 |
constructor(jodit){ |
| 36484 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "jodit", void 0); |
| 36485 |
this.jodit = jodit; |
| 36486 |
jodit.e.on('removeMarkers', ()=>{ |
| 36487 |
this.removeMarkers(); |
| 36488 |
}); |
| 36489 |
} |
| 36490 |
} |
| 36491 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 36492 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 36493 |
], Selection.prototype, "createRange", null); |
| 36494 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 36495 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 36496 |
], Selection.prototype, "focus", null); |
| 36497 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 36498 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 36499 |
], Selection.prototype, "setCursorAfter", null); |
| 36500 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 36501 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 36502 |
], Selection.prototype, "setCursorBefore", null); |
| 36503 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 36504 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_3__.autobind |
| 36505 |
], Selection.prototype, "setCursorIn", null); |
| 36506 |
|
| 36507 |
|
| 36508 |
/***/ }), |
| 36509 |
|
| 36510 |
/***/ 98711: |
| 36511 |
/***/ (function(module) { |
| 36512 |
|
| 36513 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M1792 1344v128q0 26-19 45t-45 19h-1664q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1664q26 0 45 19t19 45zm0-384v128q0 26-19 45t-45 19h-1280q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1280q26 0 45 19t19 45zm0-384v128q0 26-19 45t-45 19h-1536q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1536q26 0 45 19t19 45zm0-384v128q0 26-19 45t-45 19h-1152q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1152q26 0 45 19t19 45z\"/> </svg>" |
| 36514 |
|
| 36515 |
/***/ }), |
| 36516 |
|
| 36517 |
/***/ 98740: |
| 36518 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 36519 |
|
| 36520 |
"use strict"; |
| 36521 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 36522 |
/* harmony export */ hasBrowserColorPicker: function() { return /* binding */ hasBrowserColorPicker; } |
| 36523 |
/* harmony export */ }); |
| 36524 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81937); |
| 36525 |
/*! |
| 36526 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 36527 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 36528 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 36529 |
*/ /** |
| 36530 |
* @module helpers/checker |
| 36531 |
*/ |
| 36532 |
/** |
| 36533 |
* Check if browser has a color picker (a new HTML5 attribute for input tag) |
| 36534 |
*/ function hasBrowserColorPicker() { |
| 36535 |
let supportsColor = true; |
| 36536 |
try { |
| 36537 |
const a = jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.globalDocument.createElement('input'); |
| 36538 |
a.type = 'color'; |
| 36539 |
a.value = '!'; |
| 36540 |
supportsColor = a.type === 'color' && a.value !== '!'; |
| 36541 |
} catch (e) { |
| 36542 |
supportsColor = false; |
| 36543 |
} |
| 36544 |
return supportsColor; |
| 36545 |
} |
| 36546 |
|
| 36547 |
|
| 36548 |
/***/ }), |
| 36549 |
|
| 36550 |
/***/ 98792: |
| 36551 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 36552 |
|
| 36553 |
"use strict"; |
| 36554 |
/* unused harmony export orderedList */ |
| 36555 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 36556 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 36557 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(84839); |
| 36558 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(28077); |
| 36559 |
/* harmony import */ var jodit_core_plugin__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(91206); |
| 36560 |
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(60162); |
| 36561 |
/*! |
| 36562 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 36563 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 36564 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 36565 |
*/ /** |
| 36566 |
* [[include:plugins/ordered-list/README.md]] |
| 36567 |
* @packageDocumentation |
| 36568 |
* @module plugins/ordered-list |
| 36569 |
*/ |
| 36570 |
|
| 36571 |
|
| 36572 |
|
| 36573 |
|
| 36574 |
|
| 36575 |
/** |
| 36576 |
* Process commands insertOrderedList and insertUnOrderedList |
| 36577 |
*/ class orderedList extends jodit_core_plugin__WEBPACK_IMPORTED_MODULE_4__.Plugin { |
| 36578 |
afterInit(jodit) { |
| 36579 |
jodit.registerCommand('insertUnorderedList', this.onCommand).registerCommand('insertOrderedList', this.onCommand); |
| 36580 |
} |
| 36581 |
onCommand(command, _, type) { |
| 36582 |
this.jodit.s.commitStyle({ |
| 36583 |
element: command === 'insertunorderedlist' ? 'ul' : 'ol', |
| 36584 |
attributes: { |
| 36585 |
style: { |
| 36586 |
listStyleType: type !== null && type !== void 0 ? type : null |
| 36587 |
} |
| 36588 |
} |
| 36589 |
}); |
| 36590 |
this.jodit.synchronizeValues(); |
| 36591 |
return false; |
| 36592 |
} |
| 36593 |
beforeDestruct(jodit) {} |
| 36594 |
constructor(...args){ |
| 36595 |
super(...args), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "buttons", [ |
| 36596 |
{ |
| 36597 |
name: 'ul', |
| 36598 |
group: 'list' |
| 36599 |
}, |
| 36600 |
{ |
| 36601 |
name: 'ol', |
| 36602 |
group: 'list' |
| 36603 |
} |
| 36604 |
]); |
| 36605 |
} |
| 36606 |
} |
| 36607 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 36608 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.autobind |
| 36609 |
], orderedList.prototype, "onCommand", null); |
| 36610 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_3__.pluginSystem.add('orderedList', orderedList); |
| 36611 |
|
| 36612 |
|
| 36613 |
/***/ }), |
| 36614 |
|
| 36615 |
/***/ 98803: |
| 36616 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 36617 |
|
| 36618 |
"use strict"; |
| 36619 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 36620 |
/* harmony export */ Table: function() { return /* binding */ Table; } |
| 36621 |
/* harmony export */ }); |
| 36622 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 36623 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 36624 |
/* harmony import */ var jodit_core_component__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(16964); |
| 36625 |
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(81937); |
| 36626 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(84839); |
| 36627 |
/* harmony import */ var jodit_core_dom__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(27795); |
| 36628 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(28077); |
| 36629 |
/* harmony import */ var jodit_core_helpers___WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(65946); |
| 36630 |
/*! |
| 36631 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 36632 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 36633 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 36634 |
*/ /** |
| 36635 |
* [[include:modules/table/README.md]] |
| 36636 |
* @packageDocumentation |
| 36637 |
* @module modules/table |
| 36638 |
*/ |
| 36639 |
|
| 36640 |
|
| 36641 |
|
| 36642 |
|
| 36643 |
|
| 36644 |
|
| 36645 |
|
| 36646 |
const markedValue = new WeakMap(); |
| 36647 |
class Table extends jodit_core_component__WEBPACK_IMPORTED_MODULE_2__.ViewComponent { |
| 36648 |
/** @override */ className() { |
| 36649 |
return 'Table'; |
| 36650 |
} |
| 36651 |
__recalculateStyles() { |
| 36652 |
const style = (0,jodit_core_global__WEBPACK_IMPORTED_MODULE_6__.getContainer)(this.j, Table, 'style', true); |
| 36653 |
const selectors = []; |
| 36654 |
this.selected.forEach((td)=>{ |
| 36655 |
const selector = (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_7__.cssPath)(td); |
| 36656 |
selector && selectors.push(selector); |
| 36657 |
}); |
| 36658 |
style.innerHTML = selectors.length ? selectors.join(',') + `{${this.jodit.options.table.selectionCellStyle}}` : ''; |
| 36659 |
} |
| 36660 |
addSelection(td) { |
| 36661 |
this.selected.add(td); |
| 36662 |
this.__recalculateStyles(); |
| 36663 |
const table = jodit_core_dom__WEBPACK_IMPORTED_MODULE_5__.Dom.closest(td, 'table', this.j.editor); |
| 36664 |
if (table) { |
| 36665 |
const cells = Table.__selectedByTable.get(table) || new Set(); |
| 36666 |
cells.add(td); |
| 36667 |
Table.__selectedByTable.set(table, cells); |
| 36668 |
} |
| 36669 |
} |
| 36670 |
removeSelection(td) { |
| 36671 |
this.selected.delete(td); |
| 36672 |
this.__recalculateStyles(); |
| 36673 |
const table = jodit_core_dom__WEBPACK_IMPORTED_MODULE_5__.Dom.closest(td, 'table', this.j.editor); |
| 36674 |
if (table) { |
| 36675 |
const cells = Table.__selectedByTable.get(table); |
| 36676 |
if (cells) { |
| 36677 |
cells.delete(td); |
| 36678 |
if (!cells.size) { |
| 36679 |
Table.__selectedByTable.delete(table); |
| 36680 |
} |
| 36681 |
} |
| 36682 |
} |
| 36683 |
} |
| 36684 |
/** |
| 36685 |
* Returns array of selected cells |
| 36686 |
*/ getAllSelectedCells() { |
| 36687 |
return (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_7__.toArray)(this.selected); |
| 36688 |
} |
| 36689 |
static __getSelectedCellsByTable(table) { |
| 36690 |
const cells = Table.__selectedByTable.get(table); |
| 36691 |
return cells ? (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_7__.toArray)(cells) : []; |
| 36692 |
} |
| 36693 |
/** @override **/ destruct() { |
| 36694 |
this.selected.clear(); |
| 36695 |
return super.destruct(); |
| 36696 |
} |
| 36697 |
static __getRowsCount(table) { |
| 36698 |
return table.rows.length; |
| 36699 |
} |
| 36700 |
/** |
| 36701 |
* Returns rows count in the table |
| 36702 |
*/ getRowsCount(table) { |
| 36703 |
return Table.__getRowsCount(table); |
| 36704 |
} |
| 36705 |
static __getColumnsCount(table) { |
| 36706 |
const matrix = Table.__formalMatrix(table); |
| 36707 |
return matrix.reduce((max_count, cells)=>Math.max(max_count, cells.length), 0); |
| 36708 |
} |
| 36709 |
/** |
| 36710 |
* Returns columns count in the table |
| 36711 |
*/ getColumnsCount(table) { |
| 36712 |
return Table.__getColumnsCount(table); |
| 36713 |
} |
| 36714 |
static __formalMatrix(table, callback) { |
| 36715 |
const matrix = [ |
| 36716 |
[] |
| 36717 |
]; |
| 36718 |
const rows = (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_7__.toArray)(table.rows); |
| 36719 |
const setCell = (cell, i)=>{ |
| 36720 |
if (matrix[i] === undefined) { |
| 36721 |
matrix[i] = []; |
| 36722 |
} |
| 36723 |
const colSpan = cell.colSpan, rowSpan = cell.rowSpan; |
| 36724 |
let column, row, currentColumn = 0; |
| 36725 |
while(matrix[i][currentColumn]){ |
| 36726 |
currentColumn += 1; |
| 36727 |
} |
| 36728 |
for(row = 0; row < rowSpan; row += 1){ |
| 36729 |
for(column = 0; column < colSpan; column += 1){ |
| 36730 |
if (matrix[i + row] === undefined) { |
| 36731 |
matrix[i + row] = []; |
| 36732 |
} |
| 36733 |
if (callback && callback(cell, i + row, currentColumn + column, colSpan, rowSpan) === false) { |
| 36734 |
return false; |
| 36735 |
} |
| 36736 |
matrix[i + row][currentColumn + column] = cell; |
| 36737 |
} |
| 36738 |
} |
| 36739 |
}; |
| 36740 |
for(let i = 0; i < rows.length; i += 1){ |
| 36741 |
const cells = (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_7__.toArray)(rows[i].cells); |
| 36742 |
for(let j = 0; j < cells.length; j += 1){ |
| 36743 |
if (setCell(cells[j], i) === false) { |
| 36744 |
return matrix; |
| 36745 |
} |
| 36746 |
} |
| 36747 |
} |
| 36748 |
return matrix; |
| 36749 |
} |
| 36750 |
/** |
| 36751 |
* Generate formal table martix columns*rows |
| 36752 |
* @param table - Working table |
| 36753 |
* @param callback - if return false cycle break |
| 36754 |
*/ formalMatrix(table, callback) { |
| 36755 |
return Table.__formalMatrix(table, callback); |
| 36756 |
} |
| 36757 |
static __formalCoordinate(table, cell, max = false) { |
| 36758 |
let i = 0, j = 0, width = 1, height = 1; |
| 36759 |
Table.__formalMatrix(table, (td, ii, jj, colSpan, rowSpan)=>{ |
| 36760 |
if (cell === td) { |
| 36761 |
i = ii; |
| 36762 |
j = jj; |
| 36763 |
width = colSpan || 1; |
| 36764 |
height = rowSpan || 1; |
| 36765 |
if (max) { |
| 36766 |
j += (colSpan || 1) - 1; |
| 36767 |
i += (rowSpan || 1) - 1; |
| 36768 |
} |
| 36769 |
return false; |
| 36770 |
} |
| 36771 |
}); |
| 36772 |
return [ |
| 36773 |
i, |
| 36774 |
j, |
| 36775 |
width, |
| 36776 |
height |
| 36777 |
]; |
| 36778 |
} |
| 36779 |
/** |
| 36780 |
* Get cell coordinate in formal table (without colspan and rowspan) |
| 36781 |
*/ formalCoordinate(table, cell, max = false) { |
| 36782 |
return Table.__formalCoordinate(table, cell, max); |
| 36783 |
} |
| 36784 |
static __appendRow(table, line, after, create) { |
| 36785 |
let row; |
| 36786 |
if (!line) { |
| 36787 |
const columnsCount = Table.__getColumnsCount(table); |
| 36788 |
row = create.element('tr'); |
| 36789 |
for(let j = 0; j < columnsCount; j += 1){ |
| 36790 |
row.appendChild(create.element('td')); |
| 36791 |
} |
| 36792 |
} else { |
| 36793 |
row = line.cloneNode(true); |
| 36794 |
(0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_7__.$$)('td,th', line).forEach((cell)=>{ |
| 36795 |
const rowspan = (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_7__.attr)(cell, 'rowspan'); |
| 36796 |
if (rowspan && parseInt(rowspan, 10) > 1) { |
| 36797 |
const newRowSpan = parseInt(rowspan, 10) - 1; |
| 36798 |
(0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_7__.attr)(cell, 'rowspan', newRowSpan > 1 ? newRowSpan : null); |
| 36799 |
} |
| 36800 |
}); |
| 36801 |
(0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_7__.$$)('td,th', row).forEach((cell)=>{ |
| 36802 |
cell.innerHTML = ''; |
| 36803 |
}); |
| 36804 |
} |
| 36805 |
if (after && line && line.nextSibling) { |
| 36806 |
line.parentNode && line.parentNode.insertBefore(row, line.nextSibling); |
| 36807 |
} else if (!after && line) { |
| 36808 |
line.parentNode && line.parentNode.insertBefore(row, line); |
| 36809 |
} else { |
| 36810 |
var _table_getElementsByTagName; |
| 36811 |
(((_table_getElementsByTagName = table.getElementsByTagName('tbody')) === null || _table_getElementsByTagName === void 0 ? void 0 : _table_getElementsByTagName[0]) || table).appendChild(row); |
| 36812 |
} |
| 36813 |
} |
| 36814 |
/** |
| 36815 |
* Inserts a new line after row what contains the selected cell |
| 36816 |
* |
| 36817 |
* @param table - Working table |
| 36818 |
* @param line - Insert a new line after/before this |
| 36819 |
* line contains the selected cell |
| 36820 |
* @param after - Insert a new line after line contains the selected cell |
| 36821 |
*/ appendRow(table, line, after) { |
| 36822 |
return Table.__appendRow(table, line, after, this.j.createInside); |
| 36823 |
} |
| 36824 |
static __removeRow(table, rowIndex) { |
| 36825 |
const box = Table.__formalMatrix(table); |
| 36826 |
let dec; |
| 36827 |
const row = table.rows[rowIndex]; |
| 36828 |
box[rowIndex].forEach((cell, j)=>{ |
| 36829 |
dec = false; |
| 36830 |
if (rowIndex - 1 >= 0 && box[rowIndex - 1][j] === cell) { |
| 36831 |
dec = true; |
| 36832 |
} else if (box[rowIndex + 1] && box[rowIndex + 1][j] === cell) { |
| 36833 |
if (cell.parentNode === row && cell.parentNode.nextSibling) { |
| 36834 |
dec = true; |
| 36835 |
let nextCell = j + 1; |
| 36836 |
while(box[rowIndex + 1][nextCell] === cell){ |
| 36837 |
nextCell += 1; |
| 36838 |
} |
| 36839 |
const nextRow = jodit_core_dom__WEBPACK_IMPORTED_MODULE_5__.Dom.next(cell.parentNode, (elm)=>jodit_core_dom__WEBPACK_IMPORTED_MODULE_5__.Dom.isTag(elm, 'tr'), table); |
| 36840 |
if (nextRow) { |
| 36841 |
if (box[rowIndex + 1][nextCell]) { |
| 36842 |
nextRow.insertBefore(cell, box[rowIndex + 1][nextCell]); |
| 36843 |
} else { |
| 36844 |
nextRow.appendChild(cell); |
| 36845 |
} |
| 36846 |
} |
| 36847 |
} |
| 36848 |
} else { |
| 36849 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_5__.Dom.safeRemove(cell); |
| 36850 |
} |
| 36851 |
if (dec && (cell.parentNode === row || cell !== box[rowIndex][j - 1])) { |
| 36852 |
const rowSpan = cell.rowSpan; |
| 36853 |
(0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_7__.attr)(cell, 'rowspan', rowSpan - 1 > 1 ? rowSpan - 1 : null); |
| 36854 |
} |
| 36855 |
}); |
| 36856 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_5__.Dom.safeRemove(row); |
| 36857 |
} |
| 36858 |
/** |
| 36859 |
* Remove row |
| 36860 |
*/ removeRow(table, rowIndex) { |
| 36861 |
return Table.__removeRow(table, rowIndex); |
| 36862 |
} |
| 36863 |
/** |
| 36864 |
* Insert column before / after all the columns containing the selected cells |
| 36865 |
*/ appendColumn(table, selectedCell, insertAfter = true) { |
| 36866 |
const box = Table.__formalMatrix(table); |
| 36867 |
if (!insertAfter && jodit_core_dom__WEBPACK_IMPORTED_MODULE_5__.Dom.isCell(selectedCell.previousElementSibling)) { |
| 36868 |
return this.appendColumn(table, selectedCell.previousElementSibling, true); |
| 36869 |
} |
| 36870 |
const columnIndex = insertAfter ? selectedCell.cellIndex + ((selectedCell.colSpan || 1) - 1) : selectedCell.cellIndex; |
| 36871 |
const newColumnIndex = insertAfter ? columnIndex + 1 : columnIndex; |
| 36872 |
for(let i = 0; i < box.length;){ |
| 36873 |
const cells = box[i]; |
| 36874 |
if (cells[columnIndex] !== cells[newColumnIndex] || columnIndex === newColumnIndex) { |
| 36875 |
const cell = this.j.createInside.element('td'); |
| 36876 |
if (insertAfter) { |
| 36877 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_5__.Dom.after(cells[columnIndex], cell); |
| 36878 |
} else { |
| 36879 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_5__.Dom.before(cells[columnIndex], cell); |
| 36880 |
} |
| 36881 |
if (cells[columnIndex].rowSpan > 1) { |
| 36882 |
cell.rowSpan = cells[columnIndex].rowSpan; |
| 36883 |
} |
| 36884 |
} else { |
| 36885 |
cells[columnIndex].colSpan += 1; |
| 36886 |
} |
| 36887 |
i += cells[columnIndex].rowSpan || 1; |
| 36888 |
} |
| 36889 |
} |
| 36890 |
static __removeColumn(table, j) { |
| 36891 |
const box = Table.__formalMatrix(table); |
| 36892 |
let dec; |
| 36893 |
box.forEach((cells, i)=>{ |
| 36894 |
const td = cells[j]; |
| 36895 |
dec = false; |
| 36896 |
if (j - 1 >= 0 && box[i][j - 1] === td) { |
| 36897 |
dec = true; |
| 36898 |
} else if (j + 1 < cells.length && box[i][j + 1] === td) { |
| 36899 |
dec = true; |
| 36900 |
} else { |
| 36901 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_5__.Dom.safeRemove(td); |
| 36902 |
} |
| 36903 |
if (dec && (i - 1 < 0 || td !== box[i - 1][j])) { |
| 36904 |
const colSpan = td.colSpan; |
| 36905 |
(0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_7__.attr)(td, 'colspan', colSpan - 1 > 1 ? (colSpan - 1).toString() : null); |
| 36906 |
} |
| 36907 |
}); |
| 36908 |
} |
| 36909 |
/** |
| 36910 |
* Remove column by index |
| 36911 |
*/ removeColumn(table, j) { |
| 36912 |
return Table.__removeColumn(table, j); |
| 36913 |
} |
| 36914 |
static __getSelectedBound(table, selectedCells) { |
| 36915 |
const bound = [ |
| 36916 |
[ |
| 36917 |
Infinity, |
| 36918 |
Infinity |
| 36919 |
], |
| 36920 |
[ |
| 36921 |
0, |
| 36922 |
0 |
| 36923 |
] |
| 36924 |
]; |
| 36925 |
const box = Table.__formalMatrix(table); |
| 36926 |
let i, j, k; |
| 36927 |
for(i = 0; i < box.length; i += 1){ |
| 36928 |
for(j = 0; box[i] && j < box[i].length; j += 1){ |
| 36929 |
if (selectedCells.includes(box[i][j])) { |
| 36930 |
bound[0][0] = Math.min(i, bound[0][0]); |
| 36931 |
bound[0][1] = Math.min(j, bound[0][1]); |
| 36932 |
bound[1][0] = Math.max(i, bound[1][0]); |
| 36933 |
bound[1][1] = Math.max(j, bound[1][1]); |
| 36934 |
} |
| 36935 |
} |
| 36936 |
} |
| 36937 |
for(i = bound[0][0]; i <= bound[1][0]; i += 1){ |
| 36938 |
for(k = 1, j = bound[0][1]; j <= bound[1][1]; j += 1){ |
| 36939 |
while(box[i] && box[i][j - k] && box[i][j] === box[i][j - k]){ |
| 36940 |
bound[0][1] = Math.min(j - k, bound[0][1]); |
| 36941 |
bound[1][1] = Math.max(j - k, bound[1][1]); |
| 36942 |
k += 1; |
| 36943 |
} |
| 36944 |
k = 1; |
| 36945 |
while(box[i] && box[i][j + k] && box[i][j] === box[i][j + k]){ |
| 36946 |
bound[0][1] = Math.min(j + k, bound[0][1]); |
| 36947 |
bound[1][1] = Math.max(j + k, bound[1][1]); |
| 36948 |
k += 1; |
| 36949 |
} |
| 36950 |
k = 1; |
| 36951 |
while(box[i - k] && box[i][j] === box[i - k][j]){ |
| 36952 |
bound[0][0] = Math.min(i - k, bound[0][0]); |
| 36953 |
bound[1][0] = Math.max(i - k, bound[1][0]); |
| 36954 |
k += 1; |
| 36955 |
} |
| 36956 |
k = 1; |
| 36957 |
while(box[i + k] && box[i][j] === box[i + k][j]){ |
| 36958 |
bound[0][0] = Math.min(i + k, bound[0][0]); |
| 36959 |
bound[1][0] = Math.max(i + k, bound[1][0]); |
| 36960 |
k += 1; |
| 36961 |
} |
| 36962 |
} |
| 36963 |
} |
| 36964 |
return bound; |
| 36965 |
} |
| 36966 |
/** |
| 36967 |
* Define bound for selected cells |
| 36968 |
*/ getSelectedBound(table, selectedCells) { |
| 36969 |
return Table.__getSelectedBound(table, selectedCells); |
| 36970 |
} |
| 36971 |
static __normalizeTable(table) { |
| 36972 |
const __marked = [], box = Table.__formalMatrix(table); |
| 36973 |
Table.__removeExtraColspans(box, __marked); |
| 36974 |
Table.__removeExtraRowspans(box, __marked); |
| 36975 |
// remove rowspans and colspans equal 1 and empty class |
| 36976 |
for(let i = 0; i < box.length; i += 1){ |
| 36977 |
for(let j = 0; j < box[i].length; j += 1){ |
| 36978 |
if (box[i][j] === undefined) { |
| 36979 |
continue; // broken table |
| 36980 |
} |
| 36981 |
if (box[i][j].hasAttribute('rowspan') && box[i][j].rowSpan === 1) { |
| 36982 |
(0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_7__.attr)(box[i][j], 'rowspan', null); |
| 36983 |
} |
| 36984 |
if (box[i][j].hasAttribute('colspan') && box[i][j].colSpan === 1) { |
| 36985 |
(0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_7__.attr)(box[i][j], 'colspan', null); |
| 36986 |
} |
| 36987 |
if (box[i][j].hasAttribute('class') && !(0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_7__.attr)(box[i][j], 'class')) { |
| 36988 |
(0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_7__.attr)(box[i][j], 'class', null); |
| 36989 |
} |
| 36990 |
} |
| 36991 |
} |
| 36992 |
Table.__unmark(__marked); |
| 36993 |
} |
| 36994 |
static __removeExtraColspans(box, __marked) { |
| 36995 |
for(let j = 0; j < box[0].length; j += 1){ |
| 36996 |
let min = 1000000; |
| 36997 |
let not = false; |
| 36998 |
for(let i = 0; i < box.length; i += 1){ |
| 36999 |
if (box[i][j] === undefined) { |
| 37000 |
continue; // broken table |
| 37001 |
} |
| 37002 |
if (box[i][j].colSpan < 2) { |
| 37003 |
not = true; |
| 37004 |
break; |
| 37005 |
} |
| 37006 |
min = Math.min(min, box[i][j].colSpan); |
| 37007 |
} |
| 37008 |
if (!not) { |
| 37009 |
for(let i = 0; i < box.length; i += 1){ |
| 37010 |
if (box[i][j] === undefined) { |
| 37011 |
continue; // broken table |
| 37012 |
} |
| 37013 |
Table.__mark(box[i][j], 'colspan', box[i][j].colSpan - min + 1, __marked); |
| 37014 |
} |
| 37015 |
} |
| 37016 |
} |
| 37017 |
} |
| 37018 |
static __removeExtraRowspans(box, marked) { |
| 37019 |
let i = 0; |
| 37020 |
let j = 0; |
| 37021 |
for(i = 0; i < box.length; i += 1){ |
| 37022 |
let min = 1000000; |
| 37023 |
let not = false; |
| 37024 |
for(j = 0; j < box[i].length; j += 1){ |
| 37025 |
if (box[i][j] === undefined) { |
| 37026 |
continue; // broken table |
| 37027 |
} |
| 37028 |
if (box[i][j].rowSpan < 2) { |
| 37029 |
not = true; |
| 37030 |
break; |
| 37031 |
} |
| 37032 |
min = Math.min(min, box[i][j].rowSpan); |
| 37033 |
} |
| 37034 |
if (!not) { |
| 37035 |
for(j = 0; j < box[i].length; j += 1){ |
| 37036 |
if (box[i][j] === undefined) { |
| 37037 |
continue; // broken table |
| 37038 |
} |
| 37039 |
Table.__mark(box[i][j], 'rowspan', box[i][j].rowSpan - min + 1, marked); |
| 37040 |
} |
| 37041 |
} |
| 37042 |
} |
| 37043 |
} |
| 37044 |
/** |
| 37045 |
* Try recalculate all coluns and rows after change |
| 37046 |
*/ normalizeTable(table) { |
| 37047 |
return Table.__normalizeTable(table); |
| 37048 |
} |
| 37049 |
static __mergeSelected(table, jodit) { |
| 37050 |
const html = [], bound = Table.__getSelectedBound(table, Table.__getSelectedCellsByTable(table)); |
| 37051 |
let w = 0, first = null, first_j = 0, td, cols = 0, rows = 0; |
| 37052 |
const alreadyMerged = new Set(), __marked = []; |
| 37053 |
if (bound && (bound[0][0] - bound[1][0] || bound[0][1] - bound[1][1])) { |
| 37054 |
Table.__formalMatrix(table, (cell, i, j, cs, rs)=>{ |
| 37055 |
if (i >= bound[0][0] && i <= bound[1][0]) { |
| 37056 |
if (j >= bound[0][1] && j <= bound[1][1]) { |
| 37057 |
td = cell; |
| 37058 |
if (alreadyMerged.has(td)) { |
| 37059 |
return; |
| 37060 |
} |
| 37061 |
alreadyMerged.add(td); |
| 37062 |
if (i === bound[0][0] && td.style.width) { |
| 37063 |
w += td.offsetWidth; |
| 37064 |
} |
| 37065 |
if ((0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_7__.trim)(cell.innerHTML.replace(/<br(\/)?>/g, '')) !== '') { |
| 37066 |
html.push(cell.innerHTML); |
| 37067 |
} |
| 37068 |
if (cs > 1) { |
| 37069 |
cols += cs - 1; |
| 37070 |
} |
| 37071 |
if (rs > 1) { |
| 37072 |
rows += rs - 1; |
| 37073 |
} |
| 37074 |
if (!first) { |
| 37075 |
first = cell; |
| 37076 |
first_j = j; |
| 37077 |
} else { |
| 37078 |
Table.__mark(td, 'remove', 1, __marked); |
| 37079 |
instance(jodit).removeSelection(td); |
| 37080 |
} |
| 37081 |
} |
| 37082 |
} |
| 37083 |
}); |
| 37084 |
cols = bound[1][1] - bound[0][1] + 1; |
| 37085 |
rows = bound[1][0] - bound[0][0] + 1; |
| 37086 |
if (first) { |
| 37087 |
if (cols > 1) { |
| 37088 |
Table.__mark(first, 'colspan', cols, __marked); |
| 37089 |
} |
| 37090 |
if (rows > 1) { |
| 37091 |
Table.__mark(first, 'rowspan', rows, __marked); |
| 37092 |
} |
| 37093 |
if (w) { |
| 37094 |
Table.__mark(first, 'width', (w / table.offsetWidth * 100).toFixed(jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.ACCURACY) + '%', __marked); |
| 37095 |
if (first_j) { |
| 37096 |
Table.__setColumnWidthByDelta(table, first_j, 0, true, __marked); |
| 37097 |
} |
| 37098 |
} |
| 37099 |
first.innerHTML = html.join('<br/>'); |
| 37100 |
instance(jodit).addSelection(first); |
| 37101 |
alreadyMerged.delete(first); |
| 37102 |
Table.__unmark(__marked); |
| 37103 |
Table.__normalizeTable(table); |
| 37104 |
(0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_7__.toArray)(table.rows).forEach((tr)=>{ |
| 37105 |
if (!tr.cells.length) { |
| 37106 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_5__.Dom.safeRemove(tr); |
| 37107 |
} |
| 37108 |
}); |
| 37109 |
} |
| 37110 |
} |
| 37111 |
} |
| 37112 |
/** |
| 37113 |
* It combines all the selected cells into one. The contents of the cells will also be combined |
| 37114 |
*/ mergeSelected(table) { |
| 37115 |
return Table.__mergeSelected(table, this.j); |
| 37116 |
} |
| 37117 |
static __splitHorizontal(table, jodit) { |
| 37118 |
let coord, td, tr, parent, after; |
| 37119 |
const __marked = []; |
| 37120 |
Table.__getSelectedCellsByTable(table).forEach((cell)=>{ |
| 37121 |
td = jodit.createInside.element('td'); |
| 37122 |
td.appendChild(jodit.createInside.element('br')); |
| 37123 |
tr = jodit.createInside.element('tr'); |
| 37124 |
coord = Table.__formalCoordinate(table, cell); |
| 37125 |
if (cell.rowSpan < 2) { |
| 37126 |
Table.__formalMatrix(table, (tdElm, i, j)=>{ |
| 37127 |
if (coord[0] === i && coord[1] !== j && tdElm !== cell) { |
| 37128 |
Table.__mark(tdElm, 'rowspan', tdElm.rowSpan + 1, __marked); |
| 37129 |
} |
| 37130 |
}); |
| 37131 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_5__.Dom.after(jodit_core_dom__WEBPACK_IMPORTED_MODULE_5__.Dom.closest(cell, 'tr', table), tr); |
| 37132 |
tr.appendChild(td); |
| 37133 |
} else { |
| 37134 |
Table.__mark(cell, 'rowspan', cell.rowSpan - 1, __marked); |
| 37135 |
Table.__formalMatrix(table, (tdElm, i, j)=>{ |
| 37136 |
if (i > coord[0] && i < coord[0] + cell.rowSpan && coord[1] > j && tdElm.parentNode.rowIndex === i) { |
| 37137 |
after = tdElm; |
| 37138 |
} |
| 37139 |
if (coord[0] < i && tdElm === cell) { |
| 37140 |
parent = table.rows[i]; |
| 37141 |
} |
| 37142 |
}); |
| 37143 |
if (after) { |
| 37144 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_5__.Dom.after(after, td); |
| 37145 |
} else { |
| 37146 |
parent.insertBefore(td, parent.firstChild); |
| 37147 |
} |
| 37148 |
} |
| 37149 |
if (cell.colSpan > 1) { |
| 37150 |
Table.__mark(td, 'colspan', cell.colSpan, __marked); |
| 37151 |
} |
| 37152 |
Table.__unmark(__marked); |
| 37153 |
instance(jodit).removeSelection(cell); |
| 37154 |
}); |
| 37155 |
this.__normalizeTable(table); |
| 37156 |
} |
| 37157 |
/** |
| 37158 |
* Divides all selected by `jodit_focused_cell` class table cell in 2 parts vertical. Those division into 2 columns |
| 37159 |
*/ splitHorizontal(table) { |
| 37160 |
return Table.__splitHorizontal(table, this.j); |
| 37161 |
} |
| 37162 |
static __splitVertical(table, jodit) { |
| 37163 |
let coord, td, percentage; |
| 37164 |
const __marked = []; |
| 37165 |
Table.__getSelectedCellsByTable(table).forEach((cell)=>{ |
| 37166 |
coord = Table.__formalCoordinate(table, cell); |
| 37167 |
if (cell.colSpan < 2) { |
| 37168 |
Table.__formalMatrix(table, (tdElm, i, j)=>{ |
| 37169 |
if (coord[1] === j && coord[0] !== i && tdElm !== cell) { |
| 37170 |
Table.__mark(tdElm, 'colspan', tdElm.colSpan + 1, __marked); |
| 37171 |
} |
| 37172 |
}); |
| 37173 |
} else { |
| 37174 |
Table.__mark(cell, 'colspan', cell.colSpan - 1, __marked); |
| 37175 |
} |
| 37176 |
td = jodit.createInside.element('td'); |
| 37177 |
td.appendChild(jodit.createInside.element('br')); |
| 37178 |
if (cell.rowSpan > 1) { |
| 37179 |
Table.__mark(td, 'rowspan', cell.rowSpan, __marked); |
| 37180 |
} |
| 37181 |
const oldWidth = cell.offsetWidth; // get old width |
| 37182 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_5__.Dom.after(cell, td); |
| 37183 |
percentage = oldWidth / table.offsetWidth / 2; |
| 37184 |
Table.__mark(cell, 'width', (percentage * 100).toFixed(jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.ACCURACY) + '%', __marked); |
| 37185 |
Table.__mark(td, 'width', (percentage * 100).toFixed(jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.ACCURACY) + '%', __marked); |
| 37186 |
Table.__unmark(__marked); |
| 37187 |
instance(jodit).removeSelection(cell); |
| 37188 |
}); |
| 37189 |
Table.__normalizeTable(table); |
| 37190 |
} |
| 37191 |
/** |
| 37192 |
* It splits all the selected cells into 2 parts horizontally. Those. are added new row |
| 37193 |
*/ splitVertical(table) { |
| 37194 |
return Table.__splitVertical(table, this.j); |
| 37195 |
} |
| 37196 |
static __setColumnWidthByDelta(table, column, delta, noUnmark, marked) { |
| 37197 |
const box = Table.__formalMatrix(table); |
| 37198 |
let clearWidthIndex = 0; |
| 37199 |
for(let i = 0; i < box.length; i += 1){ |
| 37200 |
const cell = box[i][column]; |
| 37201 |
if (cell.colSpan > 1 && box.length > 1) { |
| 37202 |
continue; |
| 37203 |
} |
| 37204 |
const w = cell.offsetWidth; |
| 37205 |
const percent = (w + delta) / table.offsetWidth * 100; |
| 37206 |
Table.__mark(cell, 'width', percent.toFixed(jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.ACCURACY) + '%', marked); |
| 37207 |
clearWidthIndex = i; |
| 37208 |
break; |
| 37209 |
} |
| 37210 |
for(let i = clearWidthIndex + 1; i < box.length; i += 1){ |
| 37211 |
const cell = box[i][column]; |
| 37212 |
Table.__mark(cell, 'width', null, marked); |
| 37213 |
} |
| 37214 |
if (!noUnmark) { |
| 37215 |
Table.__unmark(marked); |
| 37216 |
} |
| 37217 |
} |
| 37218 |
/** |
| 37219 |
* Set column width used delta value |
| 37220 |
*/ setColumnWidthByDelta(table, column, delta, noUnmark, marked) { |
| 37221 |
return Table.__setColumnWidthByDelta(table, column, delta, noUnmark, marked); |
| 37222 |
} |
| 37223 |
static __mark(cell, key, value, marked) { |
| 37224 |
var _markedValue_get; |
| 37225 |
marked.push(cell); |
| 37226 |
const dict = (_markedValue_get = markedValue.get(cell)) !== null && _markedValue_get !== void 0 ? _markedValue_get : {}; |
| 37227 |
dict[key] = value === undefined ? 1 : value; |
| 37228 |
markedValue.set(cell, dict); |
| 37229 |
} |
| 37230 |
static __unmark(marked) { |
| 37231 |
marked.forEach((cell)=>{ |
| 37232 |
const dict = markedValue.get(cell); |
| 37233 |
if (dict) { |
| 37234 |
Object.keys(dict).forEach((key)=>{ |
| 37235 |
const value = dict[key]; |
| 37236 |
switch(key){ |
| 37237 |
case 'remove': |
| 37238 |
jodit_core_dom__WEBPACK_IMPORTED_MODULE_5__.Dom.safeRemove(cell); |
| 37239 |
break; |
| 37240 |
case 'rowspan': |
| 37241 |
(0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_7__.attr)(cell, 'rowspan', (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_7__.isNumber)(value) && value > 1 ? value : null); |
| 37242 |
break; |
| 37243 |
case 'colspan': |
| 37244 |
(0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_7__.attr)(cell, 'colspan', (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_7__.isNumber)(value) && value > 1 ? value : null); |
| 37245 |
break; |
| 37246 |
case 'width': |
| 37247 |
if (value == null) { |
| 37248 |
cell.style.removeProperty('width'); |
| 37249 |
if (!(0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_7__.attr)(cell, 'style')) { |
| 37250 |
(0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_7__.attr)(cell, 'style', null); |
| 37251 |
} |
| 37252 |
} else { |
| 37253 |
cell.style.width = value.toString(); |
| 37254 |
} |
| 37255 |
break; |
| 37256 |
} |
| 37257 |
delete dict[key]; |
| 37258 |
}); |
| 37259 |
markedValue.delete(cell); |
| 37260 |
} |
| 37261 |
}); |
| 37262 |
} |
| 37263 |
constructor(...args){ |
| 37264 |
super(...args), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "selected", new Set()); |
| 37265 |
} |
| 37266 |
} |
| 37267 |
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(Table, "__selectedByTable", new WeakMap()); |
| 37268 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 37269 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_4__.debounce)() |
| 37270 |
], Table.prototype, "__recalculateStyles", null); |
| 37271 |
const instance = (j)=>j.getInstance('Table', j.o); |
| 37272 |
|
| 37273 |
|
| 37274 |
/***/ }), |
| 37275 |
|
| 37276 |
/***/ 98831: |
| 37277 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 37278 |
|
| 37279 |
"use strict"; |
| 37280 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 37281 |
/* harmony export */ normalizeSize: function() { return /* binding */ normalizeSize; } |
| 37282 |
/* harmony export */ }); |
| 37283 |
/*! |
| 37284 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 37285 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 37286 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 37287 |
*/ /** |
| 37288 |
* @module helpers/normalize |
| 37289 |
*/ /** |
| 37290 |
* Normalize value to CSS meters |
| 37291 |
*/ const normalizeSize = (value, units)=>{ |
| 37292 |
if (/^[0-9]+$/.test(value.toString())) { |
| 37293 |
return value + units; |
| 37294 |
} |
| 37295 |
return value.toString(); |
| 37296 |
}; |
| 37297 |
|
| 37298 |
|
| 37299 |
/***/ }), |
| 37300 |
|
| 37301 |
/***/ 98838: |
| 37302 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 37303 |
|
| 37304 |
"use strict"; |
| 37305 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 37306 |
/* harmony export */ UIForm: function() { return /* binding */ UIForm; } |
| 37307 |
/* harmony export */ }); |
| 37308 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(31635); |
| 37309 |
/* harmony import */ var jodit_core_component_component__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(80251); |
| 37310 |
/* harmony import */ var jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(91672); |
| 37311 |
/* harmony import */ var jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(93640); |
| 37312 |
/* harmony import */ var jodit_core_ui_form_inputs_input_input__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(65273); |
| 37313 |
/* harmony import */ var jodit_core_ui_form_inputs_select_select__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(49999); |
| 37314 |
/* harmony import */ var jodit_core_ui_group_group__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(63468); |
| 37315 |
/*! |
| 37316 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 37317 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 37318 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 37319 |
*/ /** |
| 37320 |
* [[include:core/ui/form/README.md]] |
| 37321 |
* @packageDocumentation |
| 37322 |
* @module ui/form |
| 37323 |
*/ |
| 37324 |
|
| 37325 |
|
| 37326 |
|
| 37327 |
|
| 37328 |
|
| 37329 |
|
| 37330 |
class UIForm extends jodit_core_ui_group_group__WEBPACK_IMPORTED_MODULE_6__.UIGroup { |
| 37331 |
/** @override */ className() { |
| 37332 |
return 'UIForm'; |
| 37333 |
} |
| 37334 |
submit() { |
| 37335 |
this.j.e.fire(this.container, 'submit'); |
| 37336 |
} |
| 37337 |
validate() { |
| 37338 |
const inputs = this.allChildren.filter((elm)=>jodit_core_component_component__WEBPACK_IMPORTED_MODULE_1__.Component.isInstanceOf(elm, jodit_core_ui_form_inputs_input_input__WEBPACK_IMPORTED_MODULE_4__.UIInput)); |
| 37339 |
for (const input of inputs){ |
| 37340 |
if (!input.validate()) { |
| 37341 |
return false; |
| 37342 |
} |
| 37343 |
} |
| 37344 |
const selects = this.allChildren.filter((elm)=>jodit_core_component_component__WEBPACK_IMPORTED_MODULE_1__.Component.isInstanceOf(elm, jodit_core_ui_form_inputs_select_select__WEBPACK_IMPORTED_MODULE_5__.UISelect)); |
| 37345 |
for (const select of selects){ |
| 37346 |
if (!select.validate()) { |
| 37347 |
return false; |
| 37348 |
} |
| 37349 |
} |
| 37350 |
return true; |
| 37351 |
} |
| 37352 |
onSubmit(handler) { |
| 37353 |
this.j.e.on(this.container, 'submit', ()=>{ |
| 37354 |
const inputs = this.allChildren.filter((elm)=>jodit_core_component_component__WEBPACK_IMPORTED_MODULE_1__.Component.isInstanceOf(elm, jodit_core_ui_form_inputs_input_input__WEBPACK_IMPORTED_MODULE_4__.UIInput)); |
| 37355 |
if (!this.validate()) { |
| 37356 |
return false; |
| 37357 |
} |
| 37358 |
handler(inputs.reduce((res, item)=>{ |
| 37359 |
res[item.state.name] = item.value; |
| 37360 |
return res; |
| 37361 |
}, {})); |
| 37362 |
return false; |
| 37363 |
}); |
| 37364 |
return this; |
| 37365 |
} |
| 37366 |
/** @override */ createContainer() { |
| 37367 |
const form = this.j.c.element('form'); |
| 37368 |
form.classList.add(this.componentName); |
| 37369 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_3__.attr)(form, 'dir', this.j.o.direction || 'auto'); |
| 37370 |
(0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_3__.attr)(form, 'novalidate', ''); |
| 37371 |
return form; |
| 37372 |
} |
| 37373 |
constructor(...args){ |
| 37374 |
var _this_options; |
| 37375 |
super(...args); |
| 37376 |
if ((_this_options = this.options) === null || _this_options === void 0 ? void 0 : _this_options.className) { |
| 37377 |
var _this_options1; |
| 37378 |
this.container.classList.add((_this_options1 = this.options) === null || _this_options1 === void 0 ? void 0 : _this_options1.className); |
| 37379 |
} |
| 37380 |
} |
| 37381 |
} |
| 37382 |
UIForm = (0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_0__.__decorate)([ |
| 37383 |
jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_2__.component |
| 37384 |
], UIForm); |
| 37385 |
|
| 37386 |
|
| 37387 |
/***/ }), |
| 37388 |
|
| 37389 |
/***/ 98964: |
| 37390 |
/***/ (function(module) { |
| 37391 |
|
| 37392 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M1152 1376v-160q0-14-9-23t-23-9h-96v-512q0-14-9-23t-23-9h-320q-14 0-23 9t-9 23v160q0 14 9 23t23 9h96v320h-96q-14 0-23 9t-9 23v160q0 14 9 23t23 9h448q14 0 23-9t9-23zm-128-896v-160q0-14-9-23t-23-9h-192q-14 0-23 9t-9 23v160q0 14 9 23t23 9h192q14 0 23-9t9-23zm640 416q0 209-103 385.5t-279.5 279.5-385.5 103-385.5-103-279.5-279.5-103-385.5 103-385.5 279.5-279.5 385.5-103 385.5 103 279.5 279.5 103 385.5z\"/> </svg>" |
| 37393 |
|
| 37394 |
/***/ }), |
| 37395 |
|
| 37396 |
/***/ 98988: |
| 37397 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 37398 |
|
| 37399 |
"use strict"; |
| 37400 |
/* unused harmony export select */ |
| 37401 |
/* harmony import */ var _swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(25045); |
| 37402 |
/* harmony import */ var _swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31635); |
| 37403 |
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(84839); |
| 37404 |
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(23211); |
| 37405 |
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(28077); |
| 37406 |
/* harmony import */ var jodit_core_helpers_string_camel_case__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(57821); |
| 37407 |
/* harmony import */ var jodit_core_plugin__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(91206); |
| 37408 |
/* harmony import */ var jodit_core_ui__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(4099); |
| 37409 |
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(47670); |
| 37410 |
/*! |
| 37411 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 37412 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 37413 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 37414 |
*/ /** |
| 37415 |
* [[include:plugins/select/README.md]] |
| 37416 |
* @packageDocumentation |
| 37417 |
* @module plugins/select |
| 37418 |
*/ |
| 37419 |
|
| 37420 |
|
| 37421 |
|
| 37422 |
|
| 37423 |
|
| 37424 |
|
| 37425 |
|
| 37426 |
|
| 37427 |
/** |
| 37428 |
* A utility plugin that allows you to subscribe to a click/mousedown/touchstart/mouseup on an element in DOM order |
| 37429 |
* |
| 37430 |
* @example |
| 37431 |
* ```js |
| 37432 |
* const editor = Jodit.make('#editor'); |
| 37433 |
* editor.e.on('clickImg', (img) => { |
| 37434 |
* console.log(img.src); |
| 37435 |
* }) |
| 37436 |
* ``` |
| 37437 |
*/ class select extends jodit_core_plugin__WEBPACK_IMPORTED_MODULE_6__.Plugin { |
| 37438 |
afterInit(jodit) { |
| 37439 |
this.proxyEventsList.forEach((eventName)=>{ |
| 37440 |
jodit.e.on(eventName + '.select', this.onStartSelection); |
| 37441 |
}); |
| 37442 |
} |
| 37443 |
beforeDestruct(jodit) { |
| 37444 |
this.proxyEventsList.forEach((eventName)=>{ |
| 37445 |
jodit.e.on(eventName + '.select', this.onStartSelection); |
| 37446 |
}); |
| 37447 |
} |
| 37448 |
onStartSelection(e) { |
| 37449 |
const { j } = this; |
| 37450 |
let result, target = e.target; |
| 37451 |
while(result === undefined && target && target !== j.editor){ |
| 37452 |
result = j.e.fire((0,jodit_core_helpers_string_camel_case__WEBPACK_IMPORTED_MODULE_5__.camelCase)(e.type + '_' + target.nodeName.toLowerCase()), target, e); |
| 37453 |
target = target.parentElement; |
| 37454 |
} |
| 37455 |
if (e.type === 'click' && result === undefined && target === j.editor) { |
| 37456 |
j.e.fire(e.type + 'Editor', target, e); |
| 37457 |
} |
| 37458 |
} |
| 37459 |
/** |
| 37460 |
* @event outsideClick(e) - when user clicked on the outside of editor |
| 37461 |
*/ onOutsideClick(e) { |
| 37462 |
const node = e.target; |
| 37463 |
if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.up(node, (elm)=>elm === this.j.editor)) { |
| 37464 |
return; |
| 37465 |
} |
| 37466 |
const box = jodit_core_ui__WEBPACK_IMPORTED_MODULE_7__.UIElement.closestElement(node, jodit_core_ui__WEBPACK_IMPORTED_MODULE_7__.Popup); |
| 37467 |
if (!box) { |
| 37468 |
this.j.e.fire('outsideClick', e); |
| 37469 |
} |
| 37470 |
} |
| 37471 |
beforeCommandCut() { |
| 37472 |
const { s } = this.j; |
| 37473 |
if (!s.isCollapsed()) { |
| 37474 |
const current = s.current(); |
| 37475 |
if (current && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.isOrContains(this.j.editor, current)) { |
| 37476 |
this.onCopyNormalizeSelectionBound(); |
| 37477 |
} |
| 37478 |
} |
| 37479 |
} |
| 37480 |
beforeCommandSelectAll() { |
| 37481 |
const { s } = this.j; |
| 37482 |
s.focus(); |
| 37483 |
s.select(this.j.editor, true); |
| 37484 |
s.expandSelection(); |
| 37485 |
return false; |
| 37486 |
} |
| 37487 |
/** |
| 37488 |
* Normalize selection after triple click |
| 37489 |
*/ onTripleClickNormalizeSelection(e) { |
| 37490 |
if (e.detail !== 3 || !this.j.o.select.normalizeTripleClick) { |
| 37491 |
return; |
| 37492 |
} |
| 37493 |
const { s } = this.j; |
| 37494 |
const { startContainer, startOffset } = s.range; |
| 37495 |
if (startOffset === 0 && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.isText(startContainer)) { |
| 37496 |
s.select(jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.closest(startContainer, jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.isBlock, this.j.editor) || startContainer, true); |
| 37497 |
} |
| 37498 |
} |
| 37499 |
onCopyNormalizeSelectionBound(e) { |
| 37500 |
const { s, editor, o } = this.j; |
| 37501 |
if (!o.select.normalizeSelectionBeforeCutAndCopy || s.isCollapsed()) { |
| 37502 |
return; |
| 37503 |
} |
| 37504 |
if (e && (!e.isTrusted || !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.isNode(e.target) || !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_3__.Dom.isOrContains(editor, e.target))) { |
| 37505 |
return; |
| 37506 |
} |
| 37507 |
this.jodit.s.expandSelection(); |
| 37508 |
} |
| 37509 |
constructor(...args){ |
| 37510 |
super(...args), (0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_0__._)(this, "proxyEventsList", [ |
| 37511 |
'click', |
| 37512 |
'mousedown', |
| 37513 |
'touchstart', |
| 37514 |
'mouseup', |
| 37515 |
'touchend' |
| 37516 |
]); |
| 37517 |
} |
| 37518 |
} |
| 37519 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 37520 |
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.autobind |
| 37521 |
], select.prototype, "onStartSelection", null); |
| 37522 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 37523 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.watch)('ow:click') |
| 37524 |
], select.prototype, "onOutsideClick", null); |
| 37525 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 37526 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.watch)([ |
| 37527 |
':beforeCommandCut' |
| 37528 |
]) |
| 37529 |
], select.prototype, "beforeCommandCut", null); |
| 37530 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 37531 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.watch)([ |
| 37532 |
':beforeCommandSelectall' |
| 37533 |
]) |
| 37534 |
], select.prototype, "beforeCommandSelectAll", null); |
| 37535 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 37536 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.watch)([ |
| 37537 |
':click' |
| 37538 |
]) |
| 37539 |
], select.prototype, "onTripleClickNormalizeSelection", null); |
| 37540 |
(0,_swc_helpers_ts_decorate__WEBPACK_IMPORTED_MODULE_1__.__decorate)([ |
| 37541 |
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.watch)([ |
| 37542 |
':copy', |
| 37543 |
':cut' |
| 37544 |
]) |
| 37545 |
], select.prototype, "onCopyNormalizeSelectionBound", null); |
| 37546 |
jodit_core_global__WEBPACK_IMPORTED_MODULE_4__.pluginSystem.add('select', select); |
| 37547 |
|
| 37548 |
|
| 37549 |
/***/ }), |
| 37550 |
|
| 37551 |
/***/ 99436: |
| 37552 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 37553 |
|
| 37554 |
"use strict"; |
| 37555 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 37556 |
/* harmony export */ ucfirst: function() { return /* binding */ ucfirst; } |
| 37557 |
/* harmony export */ }); |
| 37558 |
/*! |
| 37559 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 37560 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 37561 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 37562 |
*/ /** |
| 37563 |
* @module helpers/string |
| 37564 |
*/ /** |
| 37565 |
* Make a string's first character uppercase |
| 37566 |
*/ function ucfirst(value) { |
| 37567 |
if (!value.length) { |
| 37568 |
return ''; |
| 37569 |
} |
| 37570 |
return value[0].toUpperCase() + value.substring(1); |
| 37571 |
} |
| 37572 |
|
| 37573 |
|
| 37574 |
/***/ }), |
| 37575 |
|
| 37576 |
/***/ 99732: |
| 37577 |
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { |
| 37578 |
|
| 37579 |
"use strict"; |
| 37580 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 37581 |
/* harmony export */ isInt: function() { return /* binding */ isInt; } |
| 37582 |
/* harmony export */ }); |
| 37583 |
/* harmony import */ var _is_numeric__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(70222); |
| 37584 |
/* harmony import */ var _is_string__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(85932); |
| 37585 |
/*! |
| 37586 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 37587 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 37588 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 37589 |
*/ /** |
| 37590 |
* @module helpers/checker |
| 37591 |
*/ |
| 37592 |
|
| 37593 |
/** |
| 37594 |
* Check value is Int |
| 37595 |
*/ function isInt(value) { |
| 37596 |
if ((0,_is_string__WEBPACK_IMPORTED_MODULE_1__.isString)(value) && (0,_is_numeric__WEBPACK_IMPORTED_MODULE_0__.isNumeric)(value)) { |
| 37597 |
value = parseFloat(value); |
| 37598 |
} |
| 37599 |
return typeof value === 'number' && Number.isFinite(value) && !(value % 1); |
| 37600 |
} |
| 37601 |
|
| 37602 |
|
| 37603 |
/***/ }), |
| 37604 |
|
| 37605 |
/***/ 99876: |
| 37606 |
/***/ (function(module) { |
| 37607 |
|
| 37608 |
module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 1792 1792\"> <path d=\"M1344 1472q0-26-19-45t-45-19-45 19-19 45 19 45 45 19 45-19 19-45zm256 0q0-26-19-45t-45-19-45 19-19 45 19 45 45 19 45-19 19-45zm128-224v320q0 40-28 68t-68 28h-1472q-40 0-68-28t-28-68v-320q0-40 28-68t68-28h427q21 56 70.5 92t110.5 36h256q61 0 110.5-36t70.5-92h427q40 0 68 28t28 68zm-325-648q-17 40-59 40h-256v448q0 26-19 45t-45 19h-256q-26 0-45-19t-19-45v-448h-256q-42 0-59-40-17-39 14-69l448-448q18-19 45-19t45 19l448 448q31 30 14 69z\"/> </svg>" |
| 37609 |
|
| 37610 |
/***/ }) |
| 37611 |
|
| 37612 |
/******/ }); |
| 37613 |
/************************************************************************/ |
| 37614 |
/******/ // The module cache |
| 37615 |
/******/ var __webpack_module_cache__ = {}; |
| 37616 |
/******/ |
| 37617 |
/******/ // The require function |
| 37618 |
/******/ function __webpack_require__(moduleId) { |
| 37619 |
/******/ // Check if module is in cache |
| 37620 |
/******/ var cachedModule = __webpack_module_cache__[moduleId]; |
| 37621 |
/******/ if (cachedModule !== undefined) { |
| 37622 |
/******/ return cachedModule.exports; |
| 37623 |
/******/ } |
| 37624 |
/******/ // Create a new module (and put it into the cache) |
| 37625 |
/******/ var module = __webpack_module_cache__[moduleId] = { |
| 37626 |
/******/ // no module.id needed |
| 37627 |
/******/ // no module.loaded needed |
| 37628 |
/******/ exports: {} |
| 37629 |
/******/ }; |
| 37630 |
/******/ |
| 37631 |
/******/ // Execute the module function |
| 37632 |
/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__); |
| 37633 |
/******/ |
| 37634 |
/******/ // Return the exports of the module |
| 37635 |
/******/ return module.exports; |
| 37636 |
/******/ } |
| 37637 |
/******/ |
| 37638 |
/******/ // expose the modules object (__webpack_modules__) |
| 37639 |
/******/ __webpack_require__.m = __webpack_modules__; |
| 37640 |
/******/ |
| 37641 |
/************************************************************************/ |
| 37642 |
/******/ /* webpack/runtime/chunk loaded */ |
| 37643 |
/******/ !function() { |
| 37644 |
/******/ var deferred = []; |
| 37645 |
/******/ __webpack_require__.O = function(result, chunkIds, fn, priority) { |
| 37646 |
/******/ if(chunkIds) { |
| 37647 |
/******/ priority = priority || 0; |
| 37648 |
/******/ for(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1]; |
| 37649 |
/******/ deferred[i] = [chunkIds, fn, priority]; |
| 37650 |
/******/ return; |
| 37651 |
/******/ } |
| 37652 |
/******/ var notFulfilled = Infinity; |
| 37653 |
/******/ for (var i = 0; i < deferred.length; i++) { |
| 37654 |
/******/ var chunkIds = deferred[i][0]; |
| 37655 |
/******/ var fn = deferred[i][1]; |
| 37656 |
/******/ var priority = deferred[i][2]; |
| 37657 |
/******/ var fulfilled = true; |
| 37658 |
/******/ for (var j = 0; j < chunkIds.length; j++) { |
| 37659 |
/******/ if ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every(function(key) { return __webpack_require__.O[key](chunkIds[j]); })) { |
| 37660 |
/******/ chunkIds.splice(j--, 1); |
| 37661 |
/******/ } else { |
| 37662 |
/******/ fulfilled = false; |
| 37663 |
/******/ if(priority < notFulfilled) notFulfilled = priority; |
| 37664 |
/******/ } |
| 37665 |
/******/ } |
| 37666 |
/******/ if(fulfilled) { |
| 37667 |
/******/ deferred.splice(i--, 1) |
| 37668 |
/******/ var r = fn(); |
| 37669 |
/******/ if (r !== undefined) result = r; |
| 37670 |
/******/ } |
| 37671 |
/******/ } |
| 37672 |
/******/ return result; |
| 37673 |
/******/ }; |
| 37674 |
/******/ }(); |
| 37675 |
/******/ |
| 37676 |
/******/ /* webpack/runtime/compat get default export */ |
| 37677 |
/******/ !function() { |
| 37678 |
/******/ // getDefaultExport function for compatibility with non-harmony modules |
| 37679 |
/******/ __webpack_require__.n = function(module) { |
| 37680 |
/******/ var getter = module && module.__esModule ? |
| 37681 |
/******/ function() { return module['default']; } : |
| 37682 |
/******/ function() { return module; }; |
| 37683 |
/******/ __webpack_require__.d(getter, { a: getter }); |
| 37684 |
/******/ return getter; |
| 37685 |
/******/ }; |
| 37686 |
/******/ }(); |
| 37687 |
/******/ |
| 37688 |
/******/ /* webpack/runtime/define property getters */ |
| 37689 |
/******/ !function() { |
| 37690 |
/******/ // define getter functions for harmony exports |
| 37691 |
/******/ __webpack_require__.d = function(exports, definition) { |
| 37692 |
/******/ for(var key in definition) { |
| 37693 |
/******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { |
| 37694 |
/******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] }); |
| 37695 |
/******/ } |
| 37696 |
/******/ } |
| 37697 |
/******/ }; |
| 37698 |
/******/ }(); |
| 37699 |
/******/ |
| 37700 |
/******/ /* webpack/runtime/hasOwnProperty shorthand */ |
| 37701 |
/******/ !function() { |
| 37702 |
/******/ __webpack_require__.o = function(obj, prop) { return Object.prototype.hasOwnProperty.call(obj, prop); } |
| 37703 |
/******/ }(); |
| 37704 |
/******/ |
| 37705 |
/******/ /* webpack/runtime/make namespace object */ |
| 37706 |
/******/ !function() { |
| 37707 |
/******/ // define __esModule on exports |
| 37708 |
/******/ __webpack_require__.r = function(exports) { |
| 37709 |
/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { |
| 37710 |
/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); |
| 37711 |
/******/ } |
| 37712 |
/******/ Object.defineProperty(exports, '__esModule', { value: true }); |
| 37713 |
/******/ }; |
| 37714 |
/******/ }(); |
| 37715 |
/******/ |
| 37716 |
/******/ /* webpack/runtime/jsonp chunk loading */ |
| 37717 |
/******/ !function() { |
| 37718 |
/******/ // no baseURI |
| 37719 |
/******/ |
| 37720 |
/******/ // object to store loaded and loading chunks |
| 37721 |
/******/ // undefined = chunk not loaded, null = chunk preloaded/prefetched |
| 37722 |
/******/ // [resolve, reject, Promise] = chunk loading, 0 = chunk loaded |
| 37723 |
/******/ var installedChunks = { |
| 37724 |
/******/ 521: 0 |
| 37725 |
/******/ }; |
| 37726 |
/******/ |
| 37727 |
/******/ // no chunk on demand loading |
| 37728 |
/******/ |
| 37729 |
/******/ // no prefetching |
| 37730 |
/******/ |
| 37731 |
/******/ // no preloaded |
| 37732 |
/******/ |
| 37733 |
/******/ // no HMR |
| 37734 |
/******/ |
| 37735 |
/******/ // no HMR manifest |
| 37736 |
/******/ |
| 37737 |
/******/ __webpack_require__.O.j = function(chunkId) { return installedChunks[chunkId] === 0; }; |
| 37738 |
/******/ |
| 37739 |
/******/ // install a JSONP callback for chunk loading |
| 37740 |
/******/ var webpackJsonpCallback = function(parentChunkLoadingFunction, data) { |
| 37741 |
/******/ var chunkIds = data[0]; |
| 37742 |
/******/ var moreModules = data[1]; |
| 37743 |
/******/ var runtime = data[2]; |
| 37744 |
/******/ // add "moreModules" to the modules object, |
| 37745 |
/******/ // then flag all "chunkIds" as loaded and fire callback |
| 37746 |
/******/ var moduleId, chunkId, i = 0; |
| 37747 |
/******/ if(chunkIds.some(function(id) { return installedChunks[id] !== 0; })) { |
| 37748 |
/******/ for(moduleId in moreModules) { |
| 37749 |
/******/ if(__webpack_require__.o(moreModules, moduleId)) { |
| 37750 |
/******/ __webpack_require__.m[moduleId] = moreModules[moduleId]; |
| 37751 |
/******/ } |
| 37752 |
/******/ } |
| 37753 |
/******/ if(runtime) var result = runtime(__webpack_require__); |
| 37754 |
/******/ } |
| 37755 |
/******/ if(parentChunkLoadingFunction) parentChunkLoadingFunction(data); |
| 37756 |
/******/ for(;i < chunkIds.length; i++) { |
| 37757 |
/******/ chunkId = chunkIds[i]; |
| 37758 |
/******/ if(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) { |
| 37759 |
/******/ installedChunks[chunkId][0](); |
| 37760 |
/******/ } |
| 37761 |
/******/ installedChunks[chunkId] = 0; |
| 37762 |
/******/ } |
| 37763 |
/******/ return __webpack_require__.O(result); |
| 37764 |
/******/ } |
| 37765 |
/******/ |
| 37766 |
/******/ var chunkLoadingGlobal = self["webpackChunkjodit"] = self["webpackChunkjodit"] || []; |
| 37767 |
/******/ chunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0)); |
| 37768 |
/******/ chunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal)); |
| 37769 |
/******/ }(); |
| 37770 |
/******/ |
| 37771 |
/************************************************************************/ |
| 37772 |
var __webpack_exports__ = {}; |
| 37773 |
// This entry needs to be wrapped in an IIFE because it needs to be in strict mode. |
| 37774 |
!function() { |
| 37775 |
"use strict"; |
| 37776 |
__webpack_require__.r(__webpack_exports__); |
| 37777 |
/* harmony export */ __webpack_require__.d(__webpack_exports__, { |
| 37778 |
/* harmony export */ CommitMode: function() { return /* binding */ CommitMode; }, |
| 37779 |
/* harmony export */ Jodit: function() { return /* reexport safe */ _jodit__WEBPACK_IMPORTED_MODULE_0__.Jodit; } |
| 37780 |
/* harmony export */ }); |
| 37781 |
/* harmony import */ var _jodit__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(73302); |
| 37782 |
/* harmony import */ var jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(28686); |
| 37783 |
/* harmony import */ var _core_constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(81937); |
| 37784 |
/* harmony import */ var _core_decorators__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(84839); |
| 37785 |
/* harmony import */ var _modules___WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(60936); |
| 37786 |
/* harmony import */ var _styles_icons___WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(13564); |
| 37787 |
/* harmony import */ var _languages__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(89317); |
| 37788 |
/* harmony import */ var jodit_plugins_index__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(93637); |
| 37789 |
/*! |
| 37790 |
* Jodit Editor (https://xdsoft.net/jodit/) |
| 37791 |
* Released under MIT see LICENSE.txt in the project root for license information. |
| 37792 |
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net |
| 37793 |
*/ /** |
| 37794 |
* [[include:README.md]] |
| 37795 |
* @packageDocumentation |
| 37796 |
* @module jodit |
| 37797 |
*/ // eslint-disable-next-line simple-import-sort/imports |
| 37798 |
|
| 37799 |
|
| 37800 |
|
| 37801 |
|
| 37802 |
|
| 37803 |
|
| 37804 |
|
| 37805 |
|
| 37806 |
|
| 37807 |
|
| 37808 |
// copy constants in Jodit |
| 37809 |
Object.keys(_core_constants__WEBPACK_IMPORTED_MODULE_2__).forEach((key)=>{ |
| 37810 |
_jodit__WEBPACK_IMPORTED_MODULE_0__.Jodit[key] = _core_constants__WEBPACK_IMPORTED_MODULE_2__[key]; |
| 37811 |
}); |
| 37812 |
const esFilter = (key)=>key !== '__esModule'; |
| 37813 |
// Icons |
| 37814 |
Object.keys(_styles_icons___WEBPACK_IMPORTED_MODULE_5__).filter(esFilter).forEach((key)=>{ |
| 37815 |
_modules___WEBPACK_IMPORTED_MODULE_4__.Icon.set(key.replace('_', '-'), _styles_icons___WEBPACK_IMPORTED_MODULE_5__[key]); |
| 37816 |
}); |
| 37817 |
// Modules |
| 37818 |
Object.keys(_modules___WEBPACK_IMPORTED_MODULE_4__).filter(esFilter).forEach((key)=>{ |
| 37819 |
var _module_prototype; |
| 37820 |
// @ts-ignore |
| 37821 |
const module = _modules___WEBPACK_IMPORTED_MODULE_4__[key]; |
| 37822 |
const name = (0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_1__.isFunction)((_module_prototype = module.prototype) === null || _module_prototype === void 0 ? void 0 : _module_prototype.className) ? module.prototype.className() : key; |
| 37823 |
if (!(0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_1__.isString)(name)) { |
| 37824 |
console.warn('Module name must be a string', key); |
| 37825 |
return; |
| 37826 |
} |
| 37827 |
// @ts-ignore |
| 37828 |
_jodit__WEBPACK_IMPORTED_MODULE_0__.Jodit.modules[name] = module; |
| 37829 |
}); |
| 37830 |
// Decorators |
| 37831 |
Object.keys(_core_decorators__WEBPACK_IMPORTED_MODULE_3__).filter(esFilter).forEach((key)=>{ |
| 37832 |
// @ts-ignore |
| 37833 |
_jodit__WEBPACK_IMPORTED_MODULE_0__.Jodit.decorators[key] = _core_decorators__WEBPACK_IMPORTED_MODULE_3__[key]; |
| 37834 |
}); |
| 37835 |
[ |
| 37836 |
'Confirm', |
| 37837 |
'Alert', |
| 37838 |
'Prompt' |
| 37839 |
].forEach((key)=>{ |
| 37840 |
// @ts-ignore |
| 37841 |
_jodit__WEBPACK_IMPORTED_MODULE_0__.Jodit[key] = _modules___WEBPACK_IMPORTED_MODULE_4__[key]; |
| 37842 |
}); |
| 37843 |
// Languages |
| 37844 |
Object.keys(_languages__WEBPACK_IMPORTED_MODULE_6__["default"]).filter(esFilter).forEach((key)=>{ |
| 37845 |
_jodit__WEBPACK_IMPORTED_MODULE_0__.Jodit.lang[key] = _languages__WEBPACK_IMPORTED_MODULE_6__["default"][key]; |
| 37846 |
}); |
| 37847 |
|
| 37848 |
class CommitMode { |
| 37849 |
} |
| 37850 |
|
| 37851 |
}(); |
| 37852 |
__webpack_exports__ = __webpack_require__.O(__webpack_exports__); |
| 37853 |
/******/ return __webpack_exports__; |
| 37854 |
/******/ })() |
| 37855 |
; |
| 37856 |
}); |