jodit 4.6.1 → 4.6.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.nvmrc +1 -1
- package/CHANGELOG.md +22 -0
- package/es2015/jodit.css +1 -1
- package/es2015/jodit.fat.min.js +2 -2
- package/es2015/jodit.js +2930 -2896
- package/es2015/jodit.min.js +2 -2
- package/es2015/plugins/debug/debug.css +1 -1
- package/es2015/plugins/debug/debug.js +1 -1
- package/es2015/plugins/debug/debug.min.js +1 -1
- package/es2015/plugins/speech-recognize/speech-recognize.css +1 -1
- package/es2015/plugins/speech-recognize/speech-recognize.js +56 -56
- package/es2015/plugins/speech-recognize/speech-recognize.min.js +1 -1
- package/es2018/jodit.css +1 -1
- package/es2018/jodit.fat.min.js +2 -2
- package/es2018/jodit.js +2837 -2803
- package/es2018/jodit.min.js +2 -2
- package/es2018/plugins/debug/debug.css +1 -1
- package/es2018/plugins/debug/debug.js +1 -1
- package/es2018/plugins/debug/debug.min.js +1 -1
- package/es2018/plugins/speech-recognize/speech-recognize.css +1 -1
- package/es2018/plugins/speech-recognize/speech-recognize.js +56 -56
- package/es2018/plugins/speech-recognize/speech-recognize.min.js +1 -1
- package/es2021/jodit.css +1 -1
- package/es2021/jodit.fat.min.js +2 -2
- package/es2021/jodit.js +2838 -2804
- package/es2021/jodit.min.js +2 -2
- package/es2021/plugins/debug/debug.css +1 -1
- package/es2021/plugins/debug/debug.js +1 -1
- package/es2021/plugins/debug/debug.min.js +1 -1
- package/es2021/plugins/speech-recognize/speech-recognize.css +1 -1
- package/es2021/plugins/speech-recognize/speech-recognize.js +56 -56
- package/es2021/plugins/speech-recognize/speech-recognize.min.js +1 -1
- package/es2021.en/jodit.css +1 -1
- package/es2021.en/jodit.fat.min.js +2 -2
- package/es2021.en/jodit.js +2796 -2762
- package/es2021.en/jodit.min.js +2 -2
- package/es2021.en/plugins/debug/debug.css +1 -1
- package/es2021.en/plugins/debug/debug.js +1 -1
- package/es2021.en/plugins/debug/debug.min.js +1 -1
- package/es2021.en/plugins/speech-recognize/speech-recognize.css +1 -1
- package/es2021.en/plugins/speech-recognize/speech-recognize.js +56 -56
- package/es2021.en/plugins/speech-recognize/speech-recognize.min.js +1 -1
- package/es5/415.fat.min.js +2 -2
- package/es5/415.js +69 -5
- package/es5/415.min.js +2 -2
- package/es5/5.fat.min.js +1 -1
- package/es5/5.min.js +1 -1
- package/es5/jodit.css +2 -2
- package/es5/jodit.fat.min.js +2 -2
- package/es5/jodit.js +3796 -3758
- package/es5/jodit.min.css +2 -2
- package/es5/jodit.min.js +2 -2
- package/es5/plugins/debug/debug.css +1 -1
- package/es5/plugins/debug/debug.js +12 -12
- package/es5/plugins/debug/debug.min.js +1 -1
- package/es5/plugins/speech-recognize/speech-recognize.css +1 -1
- package/es5/plugins/speech-recognize/speech-recognize.js +59 -59
- package/es5/plugins/speech-recognize/speech-recognize.min.js +1 -1
- package/esm/core/constants.d.ts +7 -0
- package/esm/core/constants.js +31 -11
- package/esm/core/helpers/utils/append-script.js +1 -1
- package/esm/core/plugin/helpers/load.js +2 -0
- package/esm/core/view/view.d.ts +4 -0
- package/esm/core/view/view.js +10 -1
- package/esm/langs/ar.d.ts +1 -0
- package/esm/langs/ar.js +4 -1
- package/esm/langs/cs_cz.js +2 -0
- package/esm/langs/de.d.ts +1 -0
- package/esm/langs/de.js +4 -1
- package/esm/langs/en.js +2 -0
- package/esm/langs/es.d.ts +1 -0
- package/esm/langs/es.js +4 -1
- package/esm/langs/fa.js +3 -1
- package/esm/langs/fi.d.ts +1 -0
- package/esm/langs/fi.js +3 -1
- package/esm/langs/fr.d.ts +4 -0
- package/esm/langs/fr.js +6 -1
- package/esm/langs/he.d.ts +1 -0
- package/esm/langs/he.js +3 -1
- package/esm/langs/hu.d.ts +1 -0
- package/esm/langs/hu.js +3 -1
- package/esm/langs/id.js +1 -0
- package/esm/langs/it.d.ts +1 -0
- package/esm/langs/it.js +3 -1
- package/esm/langs/ja.d.ts +1 -0
- package/esm/langs/ja.js +3 -1
- package/esm/langs/ko.js +1 -0
- package/esm/langs/mn.d.ts +1 -0
- package/esm/langs/mn.js +3 -1
- package/esm/langs/nl.d.ts +1 -0
- package/esm/langs/nl.js +3 -1
- package/esm/langs/no.d.ts +22 -0
- package/esm/langs/no.js +27 -1
- package/esm/langs/pl.d.ts +1 -0
- package/esm/langs/pl.js +3 -1
- package/esm/langs/pt_br.d.ts +1 -0
- package/esm/langs/pt_br.js +3 -1
- package/esm/langs/ru.js +1 -0
- package/esm/langs/sv.js +231 -0
- package/esm/langs/tr.d.ts +1 -0
- package/esm/langs/tr.js +3 -1
- package/esm/langs/ua.js +1 -0
- package/esm/langs/zh_cn.d.ts +1 -0
- package/esm/langs/zh_cn.js +3 -1
- package/esm/langs/zh_tw.d.ts +2 -0
- package/esm/langs/zh_tw.js +4 -1
- package/esm/modules/uploader/helpers/data-uri-to-blob.js +1 -1
- package/esm/plugins/clean-html/helpers/visitor/filters/try-remove-node.js +2 -2
- package/esm/types/view.d.ts +6 -1
- package/package.json +1 -1
- package/types/core/constants.d.ts +7 -0
- package/types/core/view/view.d.ts +4 -0
- package/types/langs/ar.d.ts +1 -0
- package/types/langs/de.d.ts +1 -0
- package/types/langs/es.d.ts +1 -0
- package/types/langs/fi.d.ts +1 -0
- package/types/langs/fr.d.ts +4 -0
- package/types/langs/he.d.ts +1 -0
- package/types/langs/hu.d.ts +1 -0
- package/types/langs/it.d.ts +1 -0
- package/types/langs/ja.d.ts +1 -0
- package/types/langs/mn.d.ts +1 -0
- package/types/langs/nl.d.ts +1 -0
- package/types/langs/no.d.ts +22 -0
- package/types/langs/pl.d.ts +1 -0
- package/types/langs/pt_br.d.ts +1 -0
- package/types/langs/tr.d.ts +1 -0
- package/types/langs/zh_cn.d.ts +1 -0
- package/types/langs/zh_tw.d.ts +2 -0
- package/types/types/view.d.ts +6 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* jodit - Jodit is an awesome and useful wysiwyg editor with filebrowser
|
|
3
3
|
* Author: Chupurnov <chupurnov@gmail.com> (https://xdsoft.net/jodit/)
|
|
4
|
-
* Version: v4.6.
|
|
4
|
+
* Version: v4.6.4
|
|
5
5
|
* Url: https://xdsoft.net/jodit/
|
|
6
6
|
* License(s): MIT
|
|
7
7
|
*/
|
|
@@ -26,12 +26,12 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
26
26
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
27
27
|
/* harmony export */ Debug: function() { return /* binding */ Debug; }
|
|
28
28
|
/* harmony export */ });
|
|
29
|
-
/* harmony import */ var
|
|
30
|
-
/* harmony import */ var
|
|
31
|
-
/* harmony import */ var
|
|
32
|
-
/* harmony import */ var
|
|
33
|
-
/* harmony import */ var
|
|
34
|
-
/* harmony import */ var
|
|
29
|
+
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(31635);
|
|
30
|
+
/* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(17352);
|
|
31
|
+
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(55186);
|
|
32
|
+
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(56298);
|
|
33
|
+
/* harmony import */ var jodit_core_helpers_html_strip_tags__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(61793);
|
|
34
|
+
/* harmony import */ var jodit_core_plugin_plugin__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(29866);
|
|
35
35
|
/*!
|
|
36
36
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
37
37
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
@@ -46,7 +46,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
46
46
|
|
|
47
47
|
|
|
48
48
|
var Debug = /** @class */ (function (_super) {
|
|
49
|
-
(0,
|
|
49
|
+
(0,tslib__WEBPACK_IMPORTED_MODULE_0__/* .__extends */ .C6)(Debug, _super);
|
|
50
50
|
function Debug() {
|
|
51
51
|
return _super !== null && _super.apply(this, arguments) || this;
|
|
52
52
|
}
|
|
@@ -147,7 +147,7 @@ var Debug = /** @class */ (function (_super) {
|
|
|
147
147
|
result.push("".concat(e.key));
|
|
148
148
|
break;
|
|
149
149
|
}
|
|
150
|
-
if (e &&
|
|
150
|
+
if (e && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isNode(e.target)) {
|
|
151
151
|
result.push("<span>".concat(e.target.nodeName, "</span>"));
|
|
152
152
|
}
|
|
153
153
|
return result.join(' ');
|
|
@@ -160,7 +160,7 @@ var Debug = /** @class */ (function (_super) {
|
|
|
160
160
|
};
|
|
161
161
|
Debug.prototype.beforeDestruct = function (jodit) { };
|
|
162
162
|
return Debug;
|
|
163
|
-
}(
|
|
163
|
+
}(jodit_core_plugin_plugin__WEBPACK_IMPORTED_MODULE_5__/* .Plugin */ .k));
|
|
164
164
|
|
|
165
165
|
function renderText(elm, range) {
|
|
166
166
|
if (!elm.nodeValue) {
|
|
@@ -197,7 +197,7 @@ function renderText(elm, range) {
|
|
|
197
197
|
value.slice(range.endOffset);
|
|
198
198
|
}
|
|
199
199
|
}
|
|
200
|
-
return (0,
|
|
200
|
+
return (0,jodit_core_helpers_html_strip_tags__WEBPACK_IMPORTED_MODULE_4__/* .stripTags */ .K)(value.replace((0,jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.INVISIBLE_SPACE_REG_EXP)(), 'INV'))
|
|
201
201
|
.replace(/%CURSOR%/, '<span class="jodit-debug__tree-cursor">|</span>')
|
|
202
202
|
.replace(/%START-CURSOR%/, '<span class="jodit-debug__tree-cursor">|')
|
|
203
203
|
.replace(/%END-CURSOR%/, '|</span>');
|
|
@@ -207,7 +207,7 @@ function render(elm, level, range) {
|
|
|
207
207
|
var isSelected = (_a = window.getSelection()) === null || _a === void 0 ? void 0 : _a.containsNode(elm);
|
|
208
208
|
var content = [
|
|
209
209
|
"<span class=\"jodit-debug__tree-elm-name\">".concat(elm.nodeName, "</span>"),
|
|
210
|
-
|
|
210
|
+
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isText(elm) ? "- ".concat(renderText(elm, range)) : ''
|
|
211
211
|
]
|
|
212
212
|
.map(function (i) { return i.trim(); })
|
|
213
213
|
.filter(Boolean);
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* jodit - Jodit is an awesome and useful wysiwyg editor with filebrowser
|
|
3
3
|
* Author: Chupurnov <chupurnov@gmail.com> (https://xdsoft.net/jodit/)
|
|
4
|
-
* Version: v4.6.
|
|
4
|
+
* Version: v4.6.4
|
|
5
5
|
* Url: https://xdsoft.net/jodit/
|
|
6
6
|
* License(s): MIT
|
|
7
7
|
*/
|
|
@@ -297,16 +297,16 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
297
297
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
298
298
|
/* harmony export */ SpeechRecognizeNative: function() { return /* binding */ SpeechRecognizeNative; }
|
|
299
299
|
/* harmony export */ });
|
|
300
|
-
/* harmony import */ var
|
|
301
|
-
/* harmony import */ var
|
|
302
|
-
/* harmony import */ var
|
|
303
|
-
/* harmony import */ var
|
|
304
|
-
/* harmony import */ var
|
|
305
|
-
/* harmony import */ var
|
|
306
|
-
/* harmony import */ var
|
|
307
|
-
/* harmony import */ var
|
|
308
|
-
/* harmony import */ var
|
|
309
|
-
/* harmony import */ var
|
|
300
|
+
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(31635);
|
|
301
|
+
/* harmony import */ var jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(66927);
|
|
302
|
+
/* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(55186);
|
|
303
|
+
/* harmony import */ var jodit_core_global__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(56298);
|
|
304
|
+
/* harmony import */ var jodit_core_helpers_utils_utils__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(84976);
|
|
305
|
+
/* harmony import */ var jodit_core_plugin__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(71005);
|
|
306
|
+
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(71096);
|
|
307
|
+
/* harmony import */ var _jodit__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(46173);
|
|
308
|
+
/* harmony import */ var _helpers_exec_spell_command__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(50834);
|
|
309
|
+
/* harmony import */ var _langs__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(25202);
|
|
310
310
|
/*!
|
|
311
311
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
312
312
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
@@ -324,9 +324,9 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
324
324
|
|
|
325
325
|
|
|
326
326
|
var SpeechRecognizeNative = /** @class */ (function (_super) {
|
|
327
|
-
(0,
|
|
327
|
+
(0,tslib__WEBPACK_IMPORTED_MODULE_0__/* .__extends */ .C6)(SpeechRecognizeNative, _super);
|
|
328
328
|
function SpeechRecognizeNative() {
|
|
329
|
-
var _this = _super.apply(this, (0,
|
|
329
|
+
var _this = _super.apply(this, (0,tslib__WEBPACK_IMPORTED_MODULE_0__/* .__spreadArray */ .fX)([], (0,tslib__WEBPACK_IMPORTED_MODULE_0__/* .__read */ .zs)(arguments), false)) || this;
|
|
330
330
|
_this.buttons = [
|
|
331
331
|
{
|
|
332
332
|
group: 'state',
|
|
@@ -340,8 +340,8 @@ var SpeechRecognizeNative = /** @class */ (function (_super) {
|
|
|
340
340
|
var _this = this;
|
|
341
341
|
var commands = jodit.o.speechRecognize.commands;
|
|
342
342
|
if (commands) {
|
|
343
|
-
(0,
|
|
344
|
-
(0,
|
|
343
|
+
(0,jodit_core_global__WEBPACK_IMPORTED_MODULE_3__/* .extendLang */ .JW)(_langs__WEBPACK_IMPORTED_MODULE_9__);
|
|
344
|
+
(0,jodit_core_helpers_utils_utils__WEBPACK_IMPORTED_MODULE_4__/* .keys */ .HP)(commands, false).forEach(function (words) {
|
|
345
345
|
var keys = words.split('|');
|
|
346
346
|
keys.forEach(function (key) {
|
|
347
347
|
key = key.trim().toLowerCase();
|
|
@@ -357,7 +357,7 @@ var SpeechRecognizeNative = /** @class */ (function (_super) {
|
|
|
357
357
|
}
|
|
358
358
|
};
|
|
359
359
|
SpeechRecognizeNative.prototype.beforeDestruct = function (jodit) {
|
|
360
|
-
|
|
360
|
+
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.safeRemove(this.messagePopup);
|
|
361
361
|
};
|
|
362
362
|
SpeechRecognizeNative.prototype.onSpeechRecognizeProgressResult = function (text) {
|
|
363
363
|
var _this = this;
|
|
@@ -367,20 +367,20 @@ var SpeechRecognizeNative = /** @class */ (function (_super) {
|
|
|
367
367
|
this.j.workplace.appendChild(this.messagePopup);
|
|
368
368
|
this.j.async.clearTimeout(this.__hidePopupTimeout);
|
|
369
369
|
this.__hidePopupTimeout = this.j.async.setTimeout(function () {
|
|
370
|
-
|
|
370
|
+
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.safeRemove(_this.messagePopup);
|
|
371
371
|
}, 1000);
|
|
372
372
|
this.messagePopup.innerText = text + '|';
|
|
373
373
|
};
|
|
374
374
|
SpeechRecognizeNative.prototype.onSpeechRecognizeResult = function (text) {
|
|
375
375
|
this.j.async.clearTimeout(this.__hidePopupTimeout);
|
|
376
|
-
|
|
376
|
+
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.safeRemove(this.messagePopup);
|
|
377
377
|
var j = this.j;
|
|
378
378
|
var s = j.s;
|
|
379
379
|
if (!this._checkCommand(text)) {
|
|
380
380
|
var range = s.range, node = s.current();
|
|
381
381
|
if (s.isCollapsed() &&
|
|
382
|
-
|
|
383
|
-
|
|
382
|
+
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isText(node) &&
|
|
383
|
+
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isOrContains(j.editor, node) &&
|
|
384
384
|
node.nodeValue) {
|
|
385
385
|
var sentence = node.nodeValue;
|
|
386
386
|
node.nodeValue =
|
|
@@ -399,21 +399,21 @@ var SpeechRecognizeNative = /** @class */ (function (_super) {
|
|
|
399
399
|
SpeechRecognizeNative.prototype._checkCommand = function (command) {
|
|
400
400
|
command = command.toLowerCase().replace(/\./g, '');
|
|
401
401
|
if (this._commandToWord[command]) {
|
|
402
|
-
(0,
|
|
402
|
+
(0,_helpers_exec_spell_command__WEBPACK_IMPORTED_MODULE_8__/* .execSpellCommand */ .F)(this.j, this._commandToWord[command]);
|
|
403
403
|
return true;
|
|
404
404
|
}
|
|
405
405
|
return false;
|
|
406
406
|
};
|
|
407
|
-
(0,
|
|
408
|
-
(0,
|
|
407
|
+
(0,tslib__WEBPACK_IMPORTED_MODULE_0__/* .__decorate */ .Cg)([
|
|
408
|
+
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_1__/* .watch */ .w)(':speechRecognizeProgressResult')
|
|
409
409
|
], SpeechRecognizeNative.prototype, "onSpeechRecognizeProgressResult", null);
|
|
410
|
-
(0,
|
|
411
|
-
(0,
|
|
410
|
+
(0,tslib__WEBPACK_IMPORTED_MODULE_0__/* .__decorate */ .Cg)([
|
|
411
|
+
(0,jodit_core_decorators_watch_watch__WEBPACK_IMPORTED_MODULE_1__/* .watch */ .w)(':speechRecognizeResult')
|
|
412
412
|
], SpeechRecognizeNative.prototype, "onSpeechRecognizeResult", null);
|
|
413
413
|
return SpeechRecognizeNative;
|
|
414
|
-
}(
|
|
414
|
+
}(jodit_core_plugin__WEBPACK_IMPORTED_MODULE_5__/* .Plugin */ .k));
|
|
415
415
|
|
|
416
|
-
|
|
416
|
+
_jodit__WEBPACK_IMPORTED_MODULE_7__/* .Jodit */ .x.plugins.add('speech-recognize', SpeechRecognizeNative);
|
|
417
417
|
|
|
418
418
|
|
|
419
419
|
/***/ }),
|
|
@@ -598,16 +598,16 @@ module.exports = {
|
|
|
598
598
|
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) {
|
|
599
599
|
|
|
600
600
|
"use strict";
|
|
601
|
-
/* harmony import */ var
|
|
602
|
-
/* harmony import */ var
|
|
603
|
-
/* harmony import */ var
|
|
604
|
-
/* harmony import */ var
|
|
605
|
-
/* harmony import */ var
|
|
606
|
-
/* harmony import */ var
|
|
607
|
-
/* harmony import */ var
|
|
608
|
-
/* harmony import */ var
|
|
609
|
-
/* harmony import */ var
|
|
610
|
-
/* harmony import */ var
|
|
601
|
+
/* harmony import */ var jodit_core_helpers_checker_is_boolean__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(9810);
|
|
602
|
+
/* harmony import */ var jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(98253);
|
|
603
|
+
/* harmony import */ var jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(26150);
|
|
604
|
+
/* harmony import */ var jodit_core_helpers_utils_data_bind__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(72197);
|
|
605
|
+
/* harmony import */ var jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(931);
|
|
606
|
+
/* harmony import */ var jodit_config__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(36115);
|
|
607
|
+
/* harmony import */ var _helpers_api__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(71722);
|
|
608
|
+
/* harmony import */ var _helpers_recognize_manager__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(93676);
|
|
609
|
+
/* harmony import */ var _speech_recognize_svg__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(22227);
|
|
610
|
+
/* harmony import */ var _speech_recognize_svg__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(_speech_recognize_svg__WEBPACK_IMPORTED_MODULE_8__);
|
|
611
611
|
/*!
|
|
612
612
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
613
613
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
@@ -622,8 +622,8 @@ module.exports = {
|
|
|
622
622
|
|
|
623
623
|
|
|
624
624
|
|
|
625
|
-
|
|
626
|
-
api: typeof
|
|
625
|
+
jodit_config__WEBPACK_IMPORTED_MODULE_5__/* .Config */ .T.prototype.speechRecognize = {
|
|
626
|
+
api: typeof _helpers_api__WEBPACK_IMPORTED_MODULE_6__/* .SpeechRecognition */ .o !== 'undefined' ? _helpers_api__WEBPACK_IMPORTED_MODULE_6__/* .SpeechRecognition */ .o : null,
|
|
627
627
|
sound: true,
|
|
628
628
|
continuous: false,
|
|
629
629
|
interimResults: true,
|
|
@@ -641,13 +641,13 @@ jodit_config__WEBPACK_IMPORTED_MODULE_3__/* .Config */ .T.prototype.speechRecogn
|
|
|
641
641
|
'select all': 'selectall'
|
|
642
642
|
}
|
|
643
643
|
};
|
|
644
|
-
|
|
645
|
-
|
|
644
|
+
jodit_core_ui_icon__WEBPACK_IMPORTED_MODULE_4__/* .Icon */ .I.set('speech-recognize', (_speech_recognize_svg__WEBPACK_IMPORTED_MODULE_8___default()));
|
|
645
|
+
jodit_config__WEBPACK_IMPORTED_MODULE_5__/* .Config */ .T.prototype.controls.speechRecognize = {
|
|
646
646
|
isVisible: function (j) {
|
|
647
647
|
return Boolean(j.o.speechRecognize.api);
|
|
648
648
|
},
|
|
649
649
|
isActive: function (jodit, _) {
|
|
650
|
-
var api = (0,
|
|
650
|
+
var api = (0,jodit_core_helpers_utils_data_bind__WEBPACK_IMPORTED_MODULE_3__/* .dataBind */ .m)(jodit, 'speech');
|
|
651
651
|
return Boolean(api === null || api === void 0 ? void 0 : api.isEnabled);
|
|
652
652
|
},
|
|
653
653
|
isDisabled: function (jodit) {
|
|
@@ -661,17 +661,17 @@ jodit_config__WEBPACK_IMPORTED_MODULE_3__/* .Config */ .T.prototype.controls.spe
|
|
|
661
661
|
jodit.alert('Speech recognize API unsupported in your browser');
|
|
662
662
|
return;
|
|
663
663
|
}
|
|
664
|
-
var api = (0,
|
|
664
|
+
var api = (0,jodit_core_helpers_utils_data_bind__WEBPACK_IMPORTED_MODULE_3__/* .dataBind */ .m)(jodit, 'speech');
|
|
665
665
|
if (!api) {
|
|
666
666
|
var nativeApi = new ApiConstructor();
|
|
667
|
-
api = new
|
|
668
|
-
api.lang = (0,
|
|
667
|
+
api = new _helpers_recognize_manager__WEBPACK_IMPORTED_MODULE_7__/* .RecognizeManager */ .g(jodit.async, nativeApi);
|
|
668
|
+
api.lang = (0,jodit_core_helpers_checker_is_string__WEBPACK_IMPORTED_MODULE_1__/* .isString */ .K)(lang)
|
|
669
669
|
? lang
|
|
670
|
-
: ((_b = (0,
|
|
670
|
+
: ((_b = (0,jodit_core_helpers_utils_attr__WEBPACK_IMPORTED_MODULE_2__/* .attr */ .C)(jodit.od.documentElement, 'lang')) !== null && _b !== void 0 ? _b : undefined);
|
|
671
671
|
api.continuous = continuous;
|
|
672
672
|
api.interimResults = interimResults;
|
|
673
673
|
api.sound = sound;
|
|
674
|
-
(0,
|
|
674
|
+
(0,jodit_core_helpers_utils_data_bind__WEBPACK_IMPORTED_MODULE_3__/* .dataBind */ .m)(jodit, 'speech', api);
|
|
675
675
|
api.on('pulse', function (enable) {
|
|
676
676
|
button.setMod('pulse', enable);
|
|
677
677
|
});
|
|
@@ -683,13 +683,13 @@ jodit_config__WEBPACK_IMPORTED_MODULE_3__/* .Config */ .T.prototype.controls.spe
|
|
|
683
683
|
});
|
|
684
684
|
api.on('error', function (text) { return jodit.message.error(text); });
|
|
685
685
|
button.hookStatus('beforeDestruct', function () {
|
|
686
|
-
(0,
|
|
686
|
+
(0,jodit_core_helpers_utils_data_bind__WEBPACK_IMPORTED_MODULE_3__/* .dataBind */ .m)(jodit, 'speech', null);
|
|
687
687
|
api.destruct();
|
|
688
688
|
});
|
|
689
689
|
}
|
|
690
690
|
if (control.args) {
|
|
691
691
|
var key = control.args[0];
|
|
692
|
-
if ((0,
|
|
692
|
+
if ((0,jodit_core_helpers_checker_is_boolean__WEBPACK_IMPORTED_MODULE_0__/* .isBoolean */ .L)(api[key])) {
|
|
693
693
|
api[key] = !api[key];
|
|
694
694
|
if (api.isEnabled) {
|
|
695
695
|
api.restart();
|
|
@@ -712,7 +712,7 @@ jodit_config__WEBPACK_IMPORTED_MODULE_3__/* .Config */ .T.prototype.controls.spe
|
|
|
712
712
|
},
|
|
713
713
|
childTemplate: function (jodit, key, value) {
|
|
714
714
|
var _a;
|
|
715
|
-
var api = (0,
|
|
715
|
+
var api = (0,jodit_core_helpers_utils_data_bind__WEBPACK_IMPORTED_MODULE_3__/* .dataBind */ .m)(jodit, 'speech'), checked = (_a = api === null || api === void 0 ? void 0 : api[key]) !== null && _a !== void 0 ? _a : jodit.o.speechRecognize[key];
|
|
716
716
|
return "<span class='jodit-speech-recognize__list-item'><input ".concat(checked ? 'checked' : '', " class='jodit-checkbox' type='checkbox'> ").concat(value, "</span>");
|
|
717
717
|
},
|
|
718
718
|
mods: {
|
|
@@ -951,10 +951,10 @@ module.exports = {
|
|
|
951
951
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
952
952
|
/* harmony export */ g: function() { return /* binding */ RecognizeManager; }
|
|
953
953
|
/* harmony export */ });
|
|
954
|
-
/* harmony import */ var
|
|
955
|
-
/* harmony import */ var
|
|
956
|
-
/* harmony import */ var
|
|
957
|
-
/* harmony import */ var
|
|
954
|
+
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(31635);
|
|
955
|
+
/* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(22664);
|
|
956
|
+
/* harmony import */ var jodit_core_event_emitter_eventify__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(43431);
|
|
957
|
+
/* harmony import */ var _sound__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(95473);
|
|
958
958
|
/* harmony import */ var jodit_plugins_speech_recognize_constants__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(81629);
|
|
959
959
|
/*!
|
|
960
960
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
@@ -967,7 +967,7 @@ module.exports = {
|
|
|
967
967
|
|
|
968
968
|
|
|
969
969
|
var RecognizeManager = /** @class */ (function (_super) {
|
|
970
|
-
(0,
|
|
970
|
+
(0,tslib__WEBPACK_IMPORTED_MODULE_0__/* .__extends */ .C6)(RecognizeManager, _super);
|
|
971
971
|
function RecognizeManager(async, api) {
|
|
972
972
|
var _this = _super.call(this) || this;
|
|
973
973
|
_this.async = async;
|
|
@@ -1141,16 +1141,16 @@ var RecognizeManager = /** @class */ (function (_super) {
|
|
|
1141
1141
|
};
|
|
1142
1142
|
RecognizeManager.prototype._makeSound = function (frequency) {
|
|
1143
1143
|
if (this.sound) {
|
|
1144
|
-
(0,
|
|
1144
|
+
(0,_sound__WEBPACK_IMPORTED_MODULE_3__/* .sound */ .s)({ frequency: frequency });
|
|
1145
1145
|
}
|
|
1146
1146
|
};
|
|
1147
1147
|
var RecognizeManager_1;
|
|
1148
1148
|
RecognizeManager._instances = new Set();
|
|
1149
|
-
RecognizeManager = RecognizeManager_1 = (0,
|
|
1150
|
-
|
|
1149
|
+
RecognizeManager = RecognizeManager_1 = (0,tslib__WEBPACK_IMPORTED_MODULE_0__/* .__decorate */ .Cg)([
|
|
1150
|
+
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_1__.autobind
|
|
1151
1151
|
], RecognizeManager);
|
|
1152
1152
|
return RecognizeManager;
|
|
1153
|
-
}(
|
|
1153
|
+
}(jodit_core_event_emitter_eventify__WEBPACK_IMPORTED_MODULE_2__/* .Eventify */ .h));
|
|
1154
1154
|
|
|
1155
1155
|
|
|
1156
1156
|
|
package/esm/core/constants.d.ts
CHANGED
|
@@ -130,7 +130,14 @@ export declare const INSERT_ONLY_TEXT = "insert_only_text";
|
|
|
130
130
|
export declare const SAFE_COUNT_CHANGE_CALL = 10;
|
|
131
131
|
export declare const IS_MAC: boolean;
|
|
132
132
|
export declare const KEY_ALIASES: IDictionary<string>;
|
|
133
|
+
/**
|
|
134
|
+
* Path to the current script
|
|
135
|
+
*/
|
|
133
136
|
export declare const BASE_PATH: string;
|
|
137
|
+
/**
|
|
138
|
+
* Current script is minified
|
|
139
|
+
*/
|
|
140
|
+
export declare const BASE_PATH_IS_MIN: boolean;
|
|
134
141
|
export declare const TEMP_ATTR = "data-jodit-temp";
|
|
135
142
|
export declare const lang: IDictionary<IDictionary<string>>;
|
|
136
143
|
export declare const CLIPBOARD_ID = "clipboard";
|
package/esm/core/constants.js
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
4
4
|
* Copyright (c) 2013-2025 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
|
|
5
5
|
*/
|
|
6
|
-
export const APP_VERSION = "4.6.
|
|
6
|
+
export const APP_VERSION = "4.6.4";
|
|
7
7
|
// prettier-ignore
|
|
8
8
|
export const ES = "es2020";
|
|
9
9
|
export const IS_ES_MODERN = true;
|
|
@@ -175,17 +175,29 @@ export const KEY_ALIASES = {
|
|
|
175
175
|
win: 'meta',
|
|
176
176
|
windows: 'meta'
|
|
177
177
|
};
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
178
|
+
const removeScriptName = (src) => {
|
|
179
|
+
const parts = src.split('/');
|
|
180
|
+
const isMin = typeof false === 'boolean'
|
|
181
|
+
? false : /\.min\.js/.test(src);
|
|
182
|
+
if (/\.js/.test(parts[parts.length - 1])) {
|
|
183
|
+
return {
|
|
184
|
+
basePath: parts.slice(0, parts.length - 1).join('/') + '/',
|
|
185
|
+
isMin
|
|
186
|
+
};
|
|
181
187
|
}
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
return parts.slice(0, parts.length - 1).join('/') + '/';
|
|
186
|
-
}
|
|
187
|
-
return s;
|
|
188
|
+
return {
|
|
189
|
+
basePath: src,
|
|
190
|
+
isMin
|
|
188
191
|
};
|
|
192
|
+
};
|
|
193
|
+
const { basePath, isMin } = (() => {
|
|
194
|
+
if (typeof document === 'undefined') {
|
|
195
|
+
return {
|
|
196
|
+
basePath: '',
|
|
197
|
+
isMin: Boolean(false)
|
|
198
|
+
};
|
|
199
|
+
}
|
|
200
|
+
const script = globalDocument.currentScript;
|
|
189
201
|
if (script) {
|
|
190
202
|
return removeScriptName(script.src);
|
|
191
203
|
}
|
|
@@ -193,8 +205,16 @@ export const BASE_PATH = (() => {
|
|
|
193
205
|
if (scripts && scripts.length) {
|
|
194
206
|
return removeScriptName(scripts[scripts.length - 1].src);
|
|
195
207
|
}
|
|
196
|
-
return globalWindow.location.href;
|
|
208
|
+
return removeScriptName(globalWindow.location.href);
|
|
197
209
|
})();
|
|
210
|
+
/**
|
|
211
|
+
* Path to the current script
|
|
212
|
+
*/
|
|
213
|
+
export const BASE_PATH = basePath;
|
|
214
|
+
/**
|
|
215
|
+
* Current script is minified
|
|
216
|
+
*/
|
|
217
|
+
export const BASE_PATH_IS_MIN = isMin;
|
|
198
218
|
export const TEMP_ATTR = 'data-jodit-temp';
|
|
199
219
|
export const lang = {};
|
|
200
220
|
export const CLIPBOARD_ID = 'clipboard';
|
|
@@ -31,8 +31,8 @@ export const appendScriptAsync = cacheLoaders((jodit, url) => {
|
|
|
31
31
|
async: true,
|
|
32
32
|
src: completeUrl(url)
|
|
33
33
|
});
|
|
34
|
+
jodit.e.one(script, 'error', reject).one(script, 'load', resolve);
|
|
34
35
|
jodit.od.body.appendChild(script);
|
|
35
|
-
jodit.e.on(script, 'error', reject).on(script, 'load', resolve);
|
|
36
36
|
});
|
|
37
37
|
});
|
|
38
38
|
/**
|
|
@@ -25,11 +25,13 @@ export async function loadStyle(jodit, pluginName) {
|
|
|
25
25
|
*/
|
|
26
26
|
function getFullUrl(jodit, name, js) {
|
|
27
27
|
name = kebabCase(name);
|
|
28
|
+
const min = jodit.minified ? '.min' : '';
|
|
28
29
|
return (jodit.basePath +
|
|
29
30
|
'plugins/' +
|
|
30
31
|
name +
|
|
31
32
|
'/' +
|
|
32
33
|
name +
|
|
34
|
+
min +
|
|
33
35
|
'.' +
|
|
34
36
|
(js ? 'js' : 'css'));
|
|
35
37
|
}
|
package/esm/core/view/view.d.ts
CHANGED
|
@@ -31,6 +31,10 @@ export declare abstract class View extends Component implements IViewBased, Mods
|
|
|
31
31
|
* Get a path for loading extra staff
|
|
32
32
|
*/
|
|
33
33
|
get basePath(): string;
|
|
34
|
+
/**
|
|
35
|
+
* Plugin autoloader should load minified version of the file
|
|
36
|
+
*/
|
|
37
|
+
get minified(): boolean;
|
|
34
38
|
static readonly ES: 'es5' | 'es2015' | 'es2018' | 'es2021';
|
|
35
39
|
static readonly version: string;
|
|
36
40
|
static readonly esNext: boolean;
|
package/esm/core/view/view.js
CHANGED
|
@@ -17,7 +17,7 @@ var View_1;
|
|
|
17
17
|
import { ViewComponent } from "../component/index.js";
|
|
18
18
|
import { Component } from "../component/component.js";
|
|
19
19
|
import { STATUSES } from "../component/statuses.js";
|
|
20
|
-
import { APP_VERSION, BASE_PATH, ES, IS_ES_MODERN, IS_ES_NEXT } from "../constants.js";
|
|
20
|
+
import { APP_VERSION, BASE_PATH, BASE_PATH_IS_MIN, ES, IS_ES_MODERN, IS_ES_NEXT } from "../constants.js";
|
|
21
21
|
import { Create } from "../create/create.js";
|
|
22
22
|
import { cache, cached } from "../decorators/cache/cache.js";
|
|
23
23
|
import { derive } from "../decorators/derive/derive.js";
|
|
@@ -41,6 +41,15 @@ let View = View_1 = class View extends Component {
|
|
|
41
41
|
}
|
|
42
42
|
return BASE_PATH;
|
|
43
43
|
}
|
|
44
|
+
/**
|
|
45
|
+
* Plugin autoloader should load minified version of the file
|
|
46
|
+
*/
|
|
47
|
+
get minified() {
|
|
48
|
+
if (this.o.minified !== undefined) {
|
|
49
|
+
return this.o.minified;
|
|
50
|
+
}
|
|
51
|
+
return BASE_PATH_IS_MIN;
|
|
52
|
+
}
|
|
44
53
|
/**
|
|
45
54
|
* Return a default timeout period in milliseconds for some debounce or throttle functions.
|
|
46
55
|
* By default, `{history.timeout}` options
|
package/esm/langs/ar.d.ts
CHANGED
package/esm/langs/ar.js
CHANGED
|
@@ -4,6 +4,8 @@
|
|
|
4
4
|
* Copyright (c) 2013-2025 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
|
|
5
5
|
*/
|
|
6
6
|
|
|
7
|
+
// Arabic (العربية)
|
|
8
|
+
|
|
7
9
|
export default {
|
|
8
10
|
'Type something': 'إبدأ في الكتابة...',
|
|
9
11
|
'About Jodit': 'حول جوديت',
|
|
@@ -223,5 +225,6 @@ export default {
|
|
|
223
225
|
'Press Alt for custom resizing': 'اضغط البديل لتغيير حجم مخصص',
|
|
224
226
|
'Line height': 'ارتفاع الخط',
|
|
225
227
|
spellcheck: 'التدقيق الإملائي',
|
|
226
|
-
'Speech Recognize': 'التعرف على الكلام'
|
|
228
|
+
'Speech Recognize': 'التعرف على الكلام',
|
|
229
|
+
All: 'تحديد الكل'
|
|
227
230
|
};
|
package/esm/langs/cs_cz.js
CHANGED
package/esm/langs/de.d.ts
CHANGED
package/esm/langs/de.js
CHANGED
|
@@ -4,6 +4,8 @@
|
|
|
4
4
|
* Copyright (c) 2013-2025 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
|
|
5
5
|
*/
|
|
6
6
|
|
|
7
|
+
// German (Deutsch)
|
|
8
|
+
|
|
7
9
|
export default {
|
|
8
10
|
'Type something': 'Bitte geben Sie einen Text ein',
|
|
9
11
|
Advanced: 'Fortgeschritten',
|
|
@@ -227,5 +229,6 @@ export default {
|
|
|
227
229
|
'Find Next': 'Weitersuchen',
|
|
228
230
|
'Insert className': 'className (CSS) einfügen',
|
|
229
231
|
'Press Alt for custom resizing':
|
|
230
|
-
'Drücken Sie Alt für benutzerdefinierte Größenanpassung'
|
|
232
|
+
'Drücken Sie Alt für benutzerdefinierte Größenanpassung',
|
|
233
|
+
'License: %s': 'Lizenz: %s'
|
|
231
234
|
};
|
package/esm/langs/en.js
CHANGED
package/esm/langs/es.d.ts
CHANGED
package/esm/langs/es.js
CHANGED
|
@@ -4,6 +4,8 @@
|
|
|
4
4
|
* Copyright (c) 2013-2025 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
|
|
5
5
|
*/
|
|
6
6
|
|
|
7
|
+
// Spanish (Español)
|
|
8
|
+
|
|
7
9
|
export default {
|
|
8
10
|
'Type something': 'Escriba algo...',
|
|
9
11
|
Advanced: 'Avanzado',
|
|
@@ -226,5 +228,6 @@ export default {
|
|
|
226
228
|
'Find Next': 'Buscar Siguiente',
|
|
227
229
|
'Insert className': 'Insertar nombre de clase',
|
|
228
230
|
'Press Alt for custom resizing':
|
|
229
|
-
'Presione Alt para cambiar el tamaño personalizado'
|
|
231
|
+
'Presione Alt para cambiar el tamaño personalizado',
|
|
232
|
+
'License: %s': 'Licencia: %s'
|
|
230
233
|
};
|