UNPKG

jodit

Version:

Jodit is an awesome and useful wysiwyg editor with filebrowser

1,185 lines (1,065 loc) 2.1 MB
/*! * jodit - Jodit is an awesome and useful wysiwyg editor with filebrowser * Author: Chupurnov <chupurnov@gmail.com> (https://xdsoft.net/jodit/) * Version: v4.6.2 * Url: https://xdsoft.net/jodit/ * License(s): MIT */ (function webpackUniversalModuleDefinition(root, factory) { if(typeof exports === 'object' && typeof module === 'object') module.exports = factory(); else if(typeof define === 'function' && define.amd) define([], factory); else { var a = factory(); for(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i]; } })(self, function() { return /******/ (function() { // webpackBootstrap /******/ var __webpack_modules__ = ({ /***/ 140: /***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { "use strict"; /* harmony export */ __webpack_require__.d(__webpack_exports__, { /* harmony export */ V: function() { return /* binding */ FileBrowser; } /* harmony export */ }); /* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(31635); /* harmony import */ var jodit_core_component__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(77753); /* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(17352); /* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(22664); /* harmony import */ var jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(66927); /* harmony import */ var jodit_core_event_emitter__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(50025); /* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(65147); /* harmony import */ var jodit_core_storage__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(63915); /* harmony import */ var jodit_core_traits_dlgs__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(58597); /* harmony import */ var jodit_core_view_view_with_toolbar__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(14961); /* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(36115); /* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(70265); /* harmony import */ var _fetch_load_items__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(9979); /* harmony import */ var _fetch_load_tree__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(31859); /* harmony import */ var _listeners_native_listeners__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(62994); /* harmony import */ var _listeners_self_listeners__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(18043); /* harmony import */ var _listeners_state_listeners__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(80004); /* harmony import */ var _data_provider__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(75889); /* harmony import */ var _factories__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(83797); /* harmony import */ var _ui__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(10274); /*! * Jodit Editor (https://xdsoft.net/jodit/) * Released under MIT see LICENSE.txt in the project root for license information. * Copyright (c) 2013-2025 Valeriy Chupurnov. All rights reserved. https://xdsoft.net */ var FileBrowser = /** @class */ (function (_super) { (0,tslib__WEBPACK_IMPORTED_MODULE_18__/* .__extends */ .C6)(FileBrowser, _super); function FileBrowser(options) { var _this = _super.call(this, options) || this; _this.browser = _this.c.div(_this.componentName); _this.status_line = _this.c.div(_this.getFullElName('status')); _this.tree = new _ui__WEBPACK_IMPORTED_MODULE_17__/* .FileBrowserTree */ .V(_this); _this.files = new _ui__WEBPACK_IMPORTED_MODULE_17__/* .FileBrowserFiles */ .Q(_this); _this.state = (0,jodit_core_event_emitter__WEBPACK_IMPORTED_MODULE_4__/* .observable */ .sH)({ currentPath: '', currentSource: _data_provider__WEBPACK_IMPORTED_MODULE_15__/* .DEFAULT_SOURCE_NAME */ .o, currentBaseUrl: '', activeElements: [], elements: [], sources: [], view: 'tiles', sortBy: 'changed-desc', filterWord: '', onlyImages: false }); _this.errorHandler = function (resp) { if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.isAbortError)(resp)) { return; } if (resp instanceof Error) { _this.status(_this.i18n(resp.message)); } else { _this.status(_this.dataProvider.getMessage(resp)); } }; /** * Close dialog */ _this.close = function () { _this._dialog.close(); }; _this.__prevButtons = []; _this.attachEvents(options); var self = _this; self.options = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.ConfigProto)(options || {}, jodit_config__WEBPACK_IMPORTED_MODULE_9__/* .Config */ .T.defaultOptions.filebrowser); self.browser.component = _this; self.container = self.browser; if (self.o.showFoldersPanel) { self.browser.appendChild(self.tree.container); } self.browser.appendChild(self.files.container); self.browser.appendChild(self.status_line); _listeners_self_listeners__WEBPACK_IMPORTED_MODULE_13__/* .selfListeners */ .c.call(self); _listeners_native_listeners__WEBPACK_IMPORTED_MODULE_12__/* .nativeListeners */ .nW.call(self); _listeners_state_listeners__WEBPACK_IMPORTED_MODULE_14__/* .stateListeners */ .r.call(self); var keys = [ 'getLocalFileByUrl', 'crop', 'resize', 'create', 'fileMove', 'folderMove', 'fileRename', 'folderRename', 'fileRemove', 'folderRemove', 'folder', 'items', 'permissions' ]; keys.forEach(function (key) { if (_this.options[key] != null) { _this.options[key] = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.ConfigProto)(_this.options[key], _this.o.ajax); } }); var _a = _this.o .saveStateInStorage || { storeLastOpenedFolder: false, storeView: false, storeSortBy: false }, storeView = _a.storeView, storeSortBy = _a.storeSortBy, storeLastOpenedFolder = _a.storeLastOpenedFolder; var view = storeView && _this.storage.get('view'); if (view && _this.o.view == null) { self.state.view = view === 'list' ? 'list' : 'tiles'; } else { self.state.view = self.o.view === 'list' ? 'list' : 'tiles'; } self.files.setMod('view', self.state.view); var sortBy = storeSortBy && self.storage.get('sortBy'); if (sortBy) { var parts = sortBy.split('-'); self.state.sortBy = ['changed', 'name', 'size'].includes(parts[0]) ? sortBy : 'changed-desc'; } else { self.state.sortBy = self.o.sortBy || 'changed-desc'; } if (storeLastOpenedFolder) { var currentPath = self.storage.get('currentPath'), currentSource = self.storage.get('currentSource'); self.state.currentPath = currentPath !== null && currentPath !== void 0 ? currentPath : ''; self.state.currentSource = currentSource !== null && currentSource !== void 0 ? currentSource : ''; } self.initUploader(self); self.setStatus(jodit_core_component__WEBPACK_IMPORTED_MODULE_0__/* .STATUSES */ .f.ready); return _this; } /** @override */ FileBrowser.prototype.className = function () { return 'FileBrowser'; }; Object.defineProperty(FileBrowser.prototype, "dataProvider", { get: function () { return (0,_factories__WEBPACK_IMPORTED_MODULE_16__/* .makeDataProvider */ .S)(this, this.options); }, enumerable: false, configurable: true }); FileBrowser.prototype.onSelect = function (callback) { var _this = this; return function () { if (_this.state.activeElements.length) { var files_1 = []; var isImages_1 = []; _this.state.activeElements.forEach(function (elm) { var url = elm.fileURL; if (url) { files_1.push(url); isImages_1.push(elm.isImage || false); } }); _this.close(); var data = { baseurl: '', files: files_1, isImages: isImages_1 }; if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.isFunction)(callback)) { callback(data); } _this.close(); } return false; }; }; Object.defineProperty(FileBrowser.prototype, "_dialog", { get: function () { var _this = this; var _a; var dialog = this.dlg({ minWidth: Math.min(700, screen.width), minHeight: 300, buttons: (_a = this.o.headerButtons) !== null && _a !== void 0 ? _a : ['fullsize', 'dialog.close'] }); ['beforeClose', 'afterClose', 'beforeOpen'].forEach(function (proxyEvent) { return dialog.events.on(dialog, proxyEvent, function () { return _this.e.fire(proxyEvent); }); }); dialog.setSize(this.o.width, this.o.height); return dialog; }, enumerable: false, configurable: true }); Object.defineProperty(FileBrowser.prototype, "storage", { /** * Container for set/get value */ get: function () { return jodit_core_storage__WEBPACK_IMPORTED_MODULE_6__/* .Storage */ .wc.makeStorage(Boolean(this.o.saveStateInStorage), this.componentName); }, enumerable: false, configurable: true }); Object.defineProperty(FileBrowser.prototype, "isOpened", { get: function () { return this._dialog.isOpened && this.browser.style.display !== 'none'; }, enumerable: false, configurable: true }); /** * It displays a message in the status bar of filebrowser * * @param message - The message that will be displayed * @param success - true It will be shown a message light . If no option is specified , * ßan error will be shown the red * @example * ```javascript * parent.filebrowser.status('There was an error uploading file', false); * ``` */ FileBrowser.prototype.status = function (message, success) { if (!message || (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.isAbortError)(message)) { return; } if (!(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.isString)(message)) { message = message.message; } if (!(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.isString)(message) || !(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.trim)(message).length) { return; } this.message.message(message, success ? 'success' : 'error', this.o.howLongShowMsg); }; /** * It opens a web browser window * * @param callback - The function that will be called after the file selection in the browser * @param onlyImages - Show only images * @example * ```javascript * var fb = new Jodit.modules.FileBrowser(parent); * fb.open(function (data) { * var i; * for (i = 0;i < data.files.length; i += 1) { * parent.s.insertImage(data.baseurl + data.files[i]); * } * }); * ``` */ FileBrowser.prototype.open = function (callback, onlyImages) { var _this = this; if (callback === void 0) { callback = this.o .defaultCallback; } if (onlyImages === void 0) { onlyImages = false; } this.state.onlyImages = onlyImages; return this.async .promise(function (resolve, reject) { var _a; if (!_this.o.items || !_this.o.items.url) { throw (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.error)('Need set options.filebrowser.ajax.url'); } var localTimeout = 0; _this.e .off(_this.files.container, 'dblclick') .on(_this.files.container, 'dblclick', _this.onSelect(callback)) .on(_this.files.container, 'touchstart', function () { var now = new Date().getTime(); if (now - localTimeout < jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.EMULATE_DBLCLICK_TIMEOUT) { _this.onSelect(callback)(); } localTimeout = now; }) .off('select.filebrowser') .on('select.filebrowser', _this.onSelect(callback)); var header = _this.c.div(); (_a = _this.toolbar) === null || _a === void 0 ? void 0 : _a.appendTo(header); _this.__updateToolbarButtons(); _this._dialog.open(_this.browser, header); _this.e.fire('sort.filebrowser', _this.state.sortBy); (0,_fetch_load_tree__WEBPACK_IMPORTED_MODULE_11__/* .loadTree */ .r)(_this) .then(resolve, reject) .finally(function () { var _a; if (_this.isInDestruct) { return; } (_a = _this === null || _this === void 0 ? void 0 : _this.e) === null || _a === void 0 ? void 0 : _a.fire('fileBrowserReady.filebrowser'); }); }) .catch(function (e) { if (!(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.isAbortError)(e) && !jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.IS_PROD) { throw e; } }); }; FileBrowser.prototype.__getButtons = function () { var _this = this; var _a; var options = ((_a = this.o.buttons) !== null && _a !== void 0 ? _a : []); return options.filter(function (btn) { if (!(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.isString)(btn)) { return true; } switch (btn) { case 'filebrowser.upload': return _this.dataProvider.canI('FileUpload'); case 'filebrowser.edit': return (_this.dataProvider.canI('ImageResize') || _this.dataProvider.canI('ImageCrop')); case 'filebrowser.remove': return _this.dataProvider.canI('FileRemove'); } return true; }); }; FileBrowser.prototype.initUploader = function (editor) { var _this = this; var _a; var self = this, options = (_a = editor === null || editor === void 0 ? void 0 : editor.options) === null || _a === void 0 ? void 0 : _a.uploader, uploaderOptions = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_5__.ConfigProto)(options || {}, jodit_config__WEBPACK_IMPORTED_MODULE_9__/* .Config */ .T.defaultOptions.uploader); var uploadHandler = function () { return (0,_fetch_load_items__WEBPACK_IMPORTED_MODULE_19__/* .loadItems */ .f)(_this); }; self.uploader = self.getInstance('Uploader', uploaderOptions); self.uploader .setPath(self.state.currentPath) .setSource(self.state.currentSource) .bind(self.browser, uploadHandler, self.errorHandler); this.state.on(['change.currentPath', 'change.currentSource'], function () { _this.uploader .setPath(_this.state.currentPath) .setSource(_this.state.currentSource); }); self.e.on('bindUploader.filebrowser', function (button) { self.uploader.bind(button, uploadHandler, self.errorHandler); }); }; FileBrowser.prototype.destruct = function () { var _a; if (this.isInDestruct) { return; } (_a = (0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.cached)(this, '_dialog')) === null || _a === void 0 ? void 0 : _a.destruct(); _super.prototype.destruct.call(this); this.events && this.e.off('.filebrowser'); this.uploader && this.uploader.destruct(); }; FileBrowser.prototype.__updateToolbarButtons = function () { var _a; var buttons = this.__getButtons(); if (isEqualButtonList(this.__prevButtons, buttons)) { return; } this.__prevButtons = buttons; (_a = this.toolbar) === null || _a === void 0 ? void 0 : _a.build(buttons); }; (0,tslib__WEBPACK_IMPORTED_MODULE_18__/* .__decorate */ .Cg)([ jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.cache ], FileBrowser.prototype, "dataProvider", null); (0,tslib__WEBPACK_IMPORTED_MODULE_18__/* .__decorate */ .Cg)([ jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.cache ], FileBrowser.prototype, "_dialog", null); (0,tslib__WEBPACK_IMPORTED_MODULE_18__/* .__decorate */ .Cg)([ jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.cache ], FileBrowser.prototype, "storage", null); (0,tslib__WEBPACK_IMPORTED_MODULE_18__/* .__decorate */ .Cg)([ jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.autobind ], FileBrowser.prototype, "status", null); (0,tslib__WEBPACK_IMPORTED_MODULE_18__/* .__decorate */ .Cg)([ jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.autobind ], FileBrowser.prototype, "open", null); (0,tslib__WEBPACK_IMPORTED_MODULE_18__/* .__decorate */ .Cg)([ (0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_3__/* .watch */ .w)('dataProvider:changePermissions') ], FileBrowser.prototype, "__updateToolbarButtons", null); FileBrowser = (0,tslib__WEBPACK_IMPORTED_MODULE_18__/* .__decorate */ .Cg)([ (0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_2__.derive)(jodit_core_traits_dlgs__WEBPACK_IMPORTED_MODULE_7__/* .Dlgs */ .z) ], FileBrowser); return FileBrowser; }(jodit_core_view_view_with_toolbar__WEBPACK_IMPORTED_MODULE_8__/* .ViewWithToolbar */ .T)); function isEqualButtonList(prevButtons, buttons) { if (prevButtons.length !== buttons.length) { return false; } for (var i = 0; i < prevButtons.length; i++) { if (prevButtons[i] !== buttons[i]) { return false; } } return true; } /***/ }), /***/ 223: /***/ (function(module) { module.exports = "<svg viewBox=\"0 0 24 24\" xmlns=\"http://www.w3.org/2000/svg\"> <path d=\"M5.09668 6.99707H7.17358L4.17358 3.99707L1.17358 6.99707H3.09668V17.0031H1.15881L4.15881 20.0031L7.15881 17.0031H5.09668V6.99707Z\"/> <path d=\"M22.8412 7H8.84119V5H22.8412V7Z\"/> <path d=\"M22.8412 11H8.84119V9H22.8412V11Z\"/> <path d=\"M8.84119 15H22.8412V13H8.84119V15Z\"/> <path d=\"M22.8412 19H8.84119V17H22.8412V19Z\"/> </svg>" /***/ }), /***/ 225: /***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { "use strict"; /* unused harmony exports isEditorEmpty, placeholder */ /* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(31635); /* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(17352); /* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(22664); /* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(55186); /* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(56298); /* harmony import */ var jodit_core_helpers_checker_is_marker__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(71274); /* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(26150); /* harmony import */ var jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(38322); /* harmony import */ var jodit_core_plugin_plugin__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(29866); /* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(50248); /*! * Jodit Editor (https://xdsoft.net/jodit/) * Released under MIT see LICENSE.txt in the project root for license information. * Copyright (c) 2013-2025 Valeriy Chupurnov. All rights reserved. https://xdsoft.net */ /** * Check if root node is empty * @private */ function isEditorEmpty(root) { var _a; if (!root.firstChild) { return true; } var first = root.firstChild; if (jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INSEPARABLE_TAGS.has((_a = first.nodeName) === null || _a === void 0 ? void 0 : _a.toLowerCase()) || /^(TABLE)$/i.test(first.nodeName)) { return false; } var next = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.next(first, function (node) { return node && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isEmptyTextNode(node); }, root); if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isText(first) && !next) { return jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isEmptyTextNode(first); } return (!next && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.each(first, function (elm) { return !(jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isLeaf(elm) || jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isList(elm)) && (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isEmpty(elm) || jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isTag(elm, 'br')); })); } /** * Show placeholder inside empty editor */ var placeholder = /** @class */ (function (_super) { (0,tslib__WEBPACK_IMPORTED_MODULE_8__/* .__extends */ .C6)(placeholder, _super); function placeholder() { var _this = _super.apply(this, (0,tslib__WEBPACK_IMPORTED_MODULE_8__/* .__spreadArray */ .fX)([], (0,tslib__WEBPACK_IMPORTED_MODULE_8__/* .__read */ .zs)(arguments), false)) || this; _this.addNativeListeners = function () { _this.j.e .off(_this.j.editor, 'input.placeholder keydown.placeholder') .on(_this.j.editor, 'input.placeholder keydown.placeholder', _this.toggle); }; _this.addEvents = function () { var editor = _this.j; if (editor.o.useInputsPlaceholder && editor.element.hasAttribute('placeholder')) { _this.placeholderElm.innerHTML = (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_5__/* .attr */ .C)(editor.element, 'placeholder') || ''; } editor.e.fire('placeholder', _this.placeholderElm.innerHTML); editor.e .off('.placeholder') .on('changePlace.placeholder', _this.addNativeListeners) .on('change.placeholder focus.placeholder keyup.placeholder mouseup.placeholder keydown.placeholder ' + 'mousedown.placeholder afterSetMode.placeholder changePlace.placeholder', _this.toggle) .on(window, 'load', _this.toggle); _this.addNativeListeners(); _this.toggle(); }; return _this; } placeholder.prototype.afterInit = function (editor) { var _this = this; if (!editor.o.showPlaceholder) { return; } this.placeholderElm = editor.c.fromHTML("<span data-ref=\"placeholder\" style=\"display: none;\" class=\"jodit-placeholder\">".concat(editor.i18n(editor.o.placeholder), "</span>")); if (editor.o.direction === 'rtl') { this.placeholderElm.style.right = '0px'; this.placeholderElm.style.direction = 'rtl'; } editor.e .on('readonly', function (isReadOnly) { if (isReadOnly) { _this.hide(); } else { _this.toggle(); } }) .on('changePlace', this.addEvents); this.addEvents(); }; placeholder.prototype.show = function () { var editor = this.j; if (editor.o.readonly) { return; } var marginTop = 0, marginLeft = 0; var current = editor.s.current(), wrapper = (current && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.closest(current, jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isBlock, editor.editor)) || editor.editor; var style = editor.ew.getComputedStyle(wrapper); var styleEditor = editor.ew.getComputedStyle(editor.editor); editor.workplace.appendChild(this.placeholderElm); var firstChild = editor.editor.firstChild; if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isElement(firstChild) && !(0,jodit_core_helpers_checker_is_marker__WEBPACK_IMPORTED_MODULE_4__/* .isMarker */ .r)(firstChild)) { var style2 = editor.ew.getComputedStyle(firstChild); marginTop = parseInt(style2.getPropertyValue('margin-top'), 10); marginLeft = parseInt(style2.getPropertyValue('margin-left'), 10); this.placeholderElm.style.fontSize = parseInt(style2.getPropertyValue('font-size'), 10) + 'px'; this.placeholderElm.style.lineHeight = style2.getPropertyValue('line-height'); } else { this.placeholderElm.style.fontSize = parseInt(style.getPropertyValue('font-size'), 10) + 'px'; this.placeholderElm.style.lineHeight = style.getPropertyValue('line-height'); } (0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_9__/* .css */ .A)(this.placeholderElm, { display: 'block', textAlign: style.getPropertyValue('text-align'), paddingTop: parseInt(styleEditor.paddingTop, 10) + 'px', paddingLeft: parseInt(styleEditor.paddingLeft, 10) + 'px', paddingRight: parseInt(styleEditor.paddingRight, 10) + 'px', marginTop: Math.max(parseInt(style.getPropertyValue('margin-top'), 10), marginTop), marginLeft: Math.max(parseInt(style.getPropertyValue('margin-left'), 10), marginLeft) }); }; placeholder.prototype.hide = function () { jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.safeRemove(this.placeholderElm); }; placeholder.prototype.toggle = function () { var editor = this.j; if (!editor.editor || editor.isInDestruct) { return; } if (editor.getRealMode() !== jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.MODE_WYSIWYG) { this.hide(); return; } if (!isEditorEmpty(editor.editor)) { this.hide(); } else { this.show(); } }; placeholder.prototype.beforeDestruct = function (jodit) { this.hide(); jodit.e.off('.placeholder').off(window, 'load', this.toggle); }; (0,tslib__WEBPACK_IMPORTED_MODULE_8__/* .__decorate */ .Cg)([ (0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_1__.debounce)(function (ctx) { return ctx.defaultTimeout / 10; }, true) ], placeholder.prototype, "toggle", null); return placeholder; }(jodit_core_plugin_plugin__WEBPACK_IMPORTED_MODULE_6__/* .Plugin */ .k)); jodit_core_global__WEBPACK_IMPORTED_MODULE_3__/* .pluginSystem */ .fg.add('placeholder', placeholder); /***/ }), /***/ 449: /***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { "use strict"; /* harmony export */ __webpack_require__.d(__webpack_exports__, { /* harmony export */ N: function() { return /* binding */ CamelCaseToKebabCase; }, /* harmony export */ k: function() { return /* binding */ kebabCase; } /* harmony export */ }); /*! * Jodit Editor (https://xdsoft.net/jodit/) * Released under MIT see LICENSE.txt in the project root for license information. * Copyright (c) 2013-2025 Valeriy Chupurnov. All rights reserved. https://xdsoft.net */ /** * @module helpers/string */ var kebabCase = function (key) { 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(); }; var CamelCaseToKebabCase = function (key) { return key .replace(/([A-Z])([A-Z])([a-z])/g, '$1-$2$3') .replace(/([a-z])([A-Z])/g, '$1-$2') .toLowerCase(); }; /***/ }), /***/ 641: /***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { "use strict"; /* harmony export */ __webpack_require__.d(__webpack_exports__, { /* harmony export */ $: function() { return /* binding */ scrollIntoViewIfNeeded; }, /* harmony export */ l: function() { return /* binding */ inView; } /* harmony export */ }); /* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(55186); /*! * Jodit Editor (https://xdsoft.net/jodit/) * Released under MIT see LICENSE.txt in the project root for license information. * Copyright (c) 2013-2025 Valeriy Chupurnov. All rights reserved. https://xdsoft.net */ /** * @module helpers/utils */ /** * Check if element is in view */ function inView(elm, root, doc) { var rect = elm.getBoundingClientRect(), el = elm; var top = rect.top, height = rect.height; while (el && el !== root && el.parentNode) { el = el.parentNode; rect = el.getBoundingClientRect(); if (!(top <= rect.bottom)) { return false; } // Check if the element is out of view due to a container scrolling if (top + height <= rect.top) { return false; } } // Check it's within the document viewport return (top <= ((doc.documentElement && doc.documentElement.clientHeight) || 0)); } /** * Scroll element into view if it is not in view */ function scrollIntoViewIfNeeded(elm, root, doc) { if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__/* .Dom */ .J.isHTMLElement(elm) && !inView(elm, root, doc)) { if (root.clientHeight !== root.scrollHeight) { root.scrollTop = elm.offsetTop; } if (!inView(elm, root, doc)) { elm.scrollIntoView(); } } } /***/ }), /***/ 926: /***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { "use strict"; /* harmony export */ __webpack_require__.d(__webpack_exports__, { /* harmony export */ r: function() { return /* binding */ removeEmptyTextNode; } /* harmony export */ }); /* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(55186); /*! * Jodit Editor (https://xdsoft.net/jodit/) * Released under MIT see LICENSE.txt in the project root for license information. * Copyright (c) 2013-2025 Valeriy Chupurnov. All rights reserved. https://xdsoft.net */ /** * @private */ function removeEmptyTextNode(jodit, node, hadEffect, arg, argi, currentNode) { if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__/* .Dom */ .J.isText(node) && !node.nodeValue) { if (node === currentNode && jodit.s.isCollapsed()) { jodit.s.setCursorAfter(node); } jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__/* .Dom */ .J.safeRemove(node); return true; } return hadEffect; } /***/ }), /***/ 928: /***/ (function(module) { 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>" /***/ }), /***/ 931: /***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { "use strict"; /* harmony export */ __webpack_require__.d(__webpack_exports__, { /* harmony export */ I: function() { return /* binding */ Icon; } /* harmony export */ }); /* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(17352); /* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(65147); /* harmony import */ var jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(38322); /*! * Jodit Editor (https://xdsoft.net/jodit/) * Released under MIT see LICENSE.txt in the project root for license information. * Copyright (c) 2013-2025 Valeriy Chupurnov. All rights reserved. https://xdsoft.net */ var Icon = /** @class */ (function () { function Icon() { } Icon.getIcon = function (name) { if (/<svg/i.test(name)) { return name; } var icon = Icon.icons[name] || Icon.icons[name.replace(/-/g, '_')] || Icon.icons[name.replace(/_/g, '-')] || Icon.icons[(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__.camelCase)(name)] || Icon.icons[(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__.kebabCase)(name)] || Icon.icons[name.toLowerCase()]; if (!jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.IS_PROD && !icon) { console.warn("Icon \"".concat(name, "\" not found")); } return icon; }; /** * Check if icon exist in store */ Icon.exists = function (name) { return this.getIcon(name) !== undefined; }; /** * Return SVG icon */ Icon.get = function (name, defaultValue) { if (defaultValue === void 0) { defaultValue = '<span></span>'; } return this.getIcon(name) || defaultValue; }; /** * Set SVG in store */ Icon.set = function (name, value) { this.icons[name.replace('_', '-')] = value; return this; }; /** * Make icon html element */ Icon.makeIcon = function (jodit, icon) { var _a, _b, _c, _d; if (!icon) { return; } var iconElement; var name = icon.name, iconURL = icon.iconURL, fill = icon.fill; var clearName = name.replace(/[^a-zA-Z0-9]/g, '_'); var iconFromEvent; if (!/<svg/.test(name)) { iconFromEvent = (_b = (_a = jodit.o).getIcon) === null || _b === void 0 ? void 0 : _b.call(_a, name, clearName); } var cacheKey = "".concat(name).concat(iconURL).concat(fill).concat(iconFromEvent !== null && iconFromEvent !== void 0 ? iconFromEvent : ''); if (jodit.o.cache && this.__cache.has(cacheKey)) { return (_c = this.__cache.get(cacheKey)) === null || _c === void 0 ? void 0 : _c.cloneNode(true); } if (iconURL) { iconElement = jodit.c.span(); (0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_2__/* .css */ .A)(iconElement, 'backgroundImage', 'url(' + iconURL.replace('{basePath}', (jodit === null || jodit === void 0 ? void 0 : jodit.basePath) || '') + ')'); } else { var svg = iconFromEvent || Icon.get(name, '') || ((_d = jodit.o.extraIcons) === null || _d === void 0 ? void 0 : _d[name]); if (svg) { iconElement = jodit.c.fromHTML(svg.trim()); if (!/^<svg/i.test(name)) { iconElement.classList.add('jodit-icon_' + clearName); } } } if (iconElement) { iconElement.classList.add('jodit-icon'); iconElement.style.fill = fill; jodit.o.cache && this.__cache.set(cacheKey, iconElement.cloneNode(true)); } return iconElement; }; Icon.icons = {}; Icon.__cache = new Map(); return Icon; }()); /***/ }), /***/ 1239: /***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { "use strict"; /* unused harmony export orderedList */ /* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(31635); /* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(22664); /* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(56298); /* harmony import */ var jodit_core_plugin__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(71005); /* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(20797); /*! * Jodit Editor (https://xdsoft.net/jodit/) * Released under MIT see LICENSE.txt in the project root for license information. * Copyright (c) 2013-2025 Valeriy Chupurnov. All rights reserved. https://xdsoft.net */ /** * Process commands insertOrderedList and insertUnOrderedList */ var orderedList = /** @class */ (function (_super) { (0,tslib__WEBPACK_IMPORTED_MODULE_4__/* .__extends */ .C6)(orderedList, _super); function orderedList() { var _this = _super.apply(this, (0,tslib__WEBPACK_IMPORTED_MODULE_4__/* .__spreadArray */ .fX)([], (0,tslib__WEBPACK_IMPORTED_MODULE_4__/* .__read */ .zs)(arguments), false)) || this; _this.buttons = [ { name: 'ul', group: 'list' }, { name: 'ol', group: 'list' } ]; return _this; } orderedList.prototype.afterInit = function (jodit) { jodit .registerCommand('insertUnorderedList', this.onCommand) .registerCommand('insertOrderedList', this.onCommand); }; orderedList.prototype.onCommand = function (command, _, type) { this.jodit.s.commitStyle({ element: command === 'insertunorderedlist' ? 'ul' : 'ol', attributes: { style: { listStyleType: type !== null && type !== void 0 ? type : null } } }); this.jodit.synchronizeValues(); return false; }; orderedList.prototype.beforeDestruct = function (jodit) { }; (0,tslib__WEBPACK_IMPORTED_MODULE_4__/* .__decorate */ .Cg)([ jodit_core_decorators__WEBPACK_IMPORTED_MODULE_0__.autobind ], orderedList.prototype, "onCommand", null); return orderedList; }(jodit_core_plugin__WEBPACK_IMPORTED_MODULE_2__/* .Plugin */ .k)); jodit_core_global__WEBPACK_IMPORTED_MODULE_1__/* .pluginSystem */ .fg.add('orderedList', orderedList); /***/ }), /***/ 1311: /***/ (function(module) { "use strict"; /*! * Jodit Editor (https://xdsoft.net/jodit/) * Released under MIT see LICENSE.txt in the project root for license information. * Copyright (c) 2013-2025 Valeriy Chupurnov. All rights reserved. https://xdsoft.net */ module.exports = { symbols: 'Symbolit' }; /***/ }), /***/ 1540: /***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { "use strict"; /* harmony export */ __webpack_require__.d(__webpack_exports__, { /* harmony export */ $: function() { return /* binding */ UISelect; } /* harmony export */ }); /* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(31635); /* harmony import */ var jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(24767); /* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(26150); /* harmony import */ var jodit_core_ui_form_inputs_input_input__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(69198); /* harmony import */ var jodit_core_ui_form_validators__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(84103); /*! * Jodit Editor (https://xdsoft.net/jodit/) * Released under MIT see LICENSE.txt in the project root for license information. * Copyright (c) 2013-2025 Valeriy Chupurnov. All rights reserved. https://xdsoft.net */ var UISelect = /** @class */ (function (_super) { (0,tslib__WEBPACK_IMPORTED_MODULE_3__/* .__extends */ .C6)(UISelect, _super); function UISelect(jodit, state) { var _this = _super.call(this, jodit, state) || this; /** @override */ _this.state = (0,tslib__WEBPACK_IMPORTED_MODULE_3__/* .__assign */ .Cl)({}, UISelect_1.defaultState); Object.assign(_this.state, state); return _this; } UISelect_1 = UISelect; /** @override */ UISelect.prototype.className = function () { return 'UISelect'; }; /** @override **/ UISelect.prototype.createContainer = function (state) { var _a; var container = _super.prototype.createContainer.call(this, state); var j = this.j, nativeInput = this.nativeInput; var opt = function () { return j.create.element('option'); }; if (state.placeholder !== undefined) { var option = opt(); option.value = ''; option.text = j.i18n(state.placeholder); nativeInput.add(option); } (_a = state.options) === null || _a === void 0 ? void 0 : _a.forEach(function (element) { var option = opt(); option.value = element.value.toString(); option.text = j.i18n(element.text); nativeInput.add(option); }); if (state.size && state.size > 0) { (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_0__/* .attr */ .C)(nativeInput, 'size', state.size); } if (state.multiple) { (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_0__/* .attr */ .C)(nativeInput, 'multiple', ''); } return container; }; /** @override **/ UISelect.prototype.createNativeInput = function () { return this.j.create.element('select'); }; /** @override **/ UISelect.prototype.updateValidators = function () { _super.prototype.updateValidators.call(this); if (this.state.required) { this.validators.delete(jodit_core_ui_form_validators__WEBPACK_IMPORTED_MODULE_2__/* .inputValidators.required */ .O.required); this.validators.add(jodit_core_ui_form_validators__WEBPACK_IMPORTED_MODULE_2__/* .selectValidators.required */ .U.m); } }; var UISelect_1; /** @override */ UISelect.defaultState = (0,tslib__WEBPACK_IMPORTED_MODULE_3__/* .__assign */ .Cl)((0,tslib__WEBPACK_IMPORTED_MODULE_3__/* .__assign */ .Cl)({}, jodit_core_ui_form_inputs_input_input__WEBPACK_IMPORTED_MODULE_1__/* .UIInput */ .t.defaultState), { options: [], size: 1, multiple: false }); UISelect = UISelect_1 = (0,tslib__WEBPACK_IMPORTED_MODULE_3__/* .__decorate */ .Cg)([ jodit_core_decorators_component_component__WEBPACK_IMPORTED_MODULE_4__/* .component */ .s ], UISelect); return UISelect; }(jodit_core_ui_form_inputs_input_input__WEBPACK_IMPORTED_MODULE_1__/* .UIInput */ .t)); /***/ }), /***/ 1663: /***/ (function(module) { "use strict"; /*! * Jodit Editor (https://xdsoft.net/jodit/) * Released under MIT see LICENSE.txt in the project root for license information. * Copyright (c) 2013-2025 Valeriy Chupurnov. All rights reserved. https://xdsoft.net */ module.exports = { symbols: 'Simbolo' }; /***/ }), /***/ 1677: /***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { "use strict"; /* unused harmony export sticky */ /* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(31635); /* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(17352); /* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(22664); /* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(55186); /* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(56298); /* harmony import */ var jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(65147); /* harmony import */ var jodit_core_plugin_plugin__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(29866); /* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(63400); /*! * Jodit Editor (https://xdsoft.net/jodit/) * Released under MIT see LICENSE.txt in the project root for license information. * Copyright (c) 2013-2025 Valeriy Chupurnov. All rights reserved. https://xdsoft.net */ var NEED_DUMMY_BOX = !jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.IS_ES_NEXT && jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.IS_IE; var sticky = /** @class */ (function (_super) { (0,tslib__WEBPACK_IMPORTED_MODULE_7__/* .__extends */ .C6)(sticky, _super); function sticky() { var _this = _super.apply(this, (0,tslib__WEBPACK_IMPORTED_MODULE_7__/* .__spreadArray */ .fX)([], (0,tslib__WEBPACK_IMPORTED_MODULE_7__/* .__read */ .zs)(arguments), false)) || this; _this.__isToolbarStuck = false; _this.__createDummy = function (toolbar) { _this.__dummyBox = _this.j.c.div(); _this.__dummyBox.classList.add('jodit_sticky-dummy_toolbar'); _this.j.container.insertBefore(_this.__dummyBox, toolbar); }; /** * Add sticky */ _this.addSticky = function (toolbar) { if (!_this.__isToolbarStuck) { if (NEED_DUMMY_BOX && !_this.__dummyBox) { _this.__createDummy(toolbar); } _this.j.container.classList.add('jodit_sticky'); _this.__isToolbarStuck = true; } // on resize, it should work always (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.css)(toolbar, { top: _this.j.o.toolbarStickyOffset || null, width: _this.j.container.offsetWidth - 2 }); _this.__dummyBox && (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.css)(_this.__dummyBox, { height: toolbar.offsetHeight }); }; /** * Remove sticky behaviour */ _this.removeSticky = function (toolbar) { if (!_this.__isToolbarStuck) { return; } (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.css)(toolbar, { width: '', top: '' }); _this.j.container.classList.remove('jodit_sticky'); _this.__isToolbarStuck = false; }; return _this; } sticky.prototype.afterInit = function (jodit) { var _this = this; jodit.e .on(jodit.ow, 'scroll.sticky wheel.sticky mousewheel.sticky resize.sticky', this.__onScroll) .on('getStickyState.sticky', function () { return _this.__isToolbarStuck; }); }; /** * Scroll handler */ sticky.prototype.__onScroll = function () { var jodit = this.jodit; if (!jodit.o.toolbarSticky || !jodit.o.toolbar) { return; } var scrollWindowTop = jodit.ow.pageYOffset || (jodit.od.documentElement && jodit.od.documentElement.scrollTop) || 0; var offsetEditor = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.offset)(jodit.container, jodit, jodit.od, true); var doSticky = jodit.getMode() === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.MODE_WYSIWYG && scrollWindowTop + jodit.o.toolbarStickyOffset > offsetEditor.top && scrollWindowTop + jodit.o.toolbarStickyOffset < offsetEditor.top + offsetEditor.height && !(jodit.o.toolbarDisableStickyForMobile && this.__isMobile()); if (this.__isToolbarStuck === doSticky) { return; } var container = jodit.toolbarContainer; if (container) { doSticky ? this.addSticky(container) : this.removeSticky(container); } jodit.e.fire('toggleSticky', doSticky); }; /** * Is mobile device */ sticky.prototype.__isMobile = function () { var j = this.j; return (j && j.options && j.container && j.options.sizeSM >= j.container.offsetWidth); }; sticky.prototype.beforeDestruct = function (jodit) { jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.safeRemove(this.__dummyBox); jodit.e .off(jodit.ow, 'scroll.sticky wheel.sticky mousewheel.sticky resize.sticky', this.__onScroll) .off('.sticky'); }; (0,tslib__WEBPACK_IMPORTED_MODULE_7__/* .__decorate */ .Cg)([ (0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_1__.throttle)() ], sticky.prototype, "__onScroll", null); return sticky; }(jodit_core_plugin_plugin__WEBPACK_IMPORTED_MODULE_5__/* .Plugin */ .k)); jodit_core_global__WEBPACK_IMPORTED_MODULE_3__/* .pluginSystem */ .fg.add('sticky', sticky); /***/ }), /***/ 1916: /***/ (function(module) { module.exports = "<svg xmlns='http://www.w3.org/2000/svg' viewBox=\"0 0 24 24\"> <g transform=\"scale(1.2 1.2) translate(-2 -0.5)\"> <path d=\"M 22,12.5 A 1.49995,1.49995 0 0 0 20.50006,11 H 20 V 10 A 3,3 0 0 0 17,7 H 13 V 5.7226 a 2,2 0 1 0 -2,0 V 7 H 7 a 3,3 0 0 0 -3,3 v 1 H 3.49994 a 1.5,1.5 0 0 0 0,3 H 4 v 1 A 3.00128,3.00128 0 0 0 6.20251,17.89282 1.03113,1.03113