jodit 4.2.46 → 4.2.49
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +33 -0
- package/README.md +1 -0
- package/es2015/jodit.css +1 -1
- package/es2015/jodit.fat.min.js +2 -2
- package/es2015/jodit.js +24 -11
- 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 +1 -1
- 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 +24 -11
- 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 +1 -1
- package/es2018/plugins/speech-recognize/speech-recognize.min.js +1 -1
- package/es2021/jodit.css +1 -1
- package/es2021/jodit.fat.min.js +2 -2
- package/es2021/jodit.js +24 -11
- 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 +1 -1
- package/es2021/plugins/speech-recognize/speech-recognize.min.js +1 -1
- package/es2021.en/jodit.css +1 -1
- package/es2021.en/jodit.fat.min.js +2 -2
- package/es2021.en/jodit.js +24 -11
- 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 +1 -1
- package/es2021.en/plugins/speech-recognize/speech-recognize.min.js +1 -1
- package/es5/164.fat.min.js +1 -1
- package/es5/164.min.js +1 -1
- 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 +27 -13
- package/es5/jodit.min.css +2 -2
- package/es5/jodit.min.js +2 -2
- package/es5/plugins/debug/debug.css +1 -1
- package/es5/plugins/debug/debug.js +1 -1
- package/es5/plugins/debug/debug.min.js +1 -1
- package/es5/plugins/speech-recognize/speech-recognize.css +1 -1
- package/es5/plugins/speech-recognize/speech-recognize.js +1 -1
- package/es5/plugins/speech-recognize/speech-recognize.min.js +1 -1
- package/esm/core/constants.js +1 -1
- package/esm/core/view/view.js +3 -3
- package/esm/jodit.d.ts +3 -3
- package/esm/plugins/size/size.js +10 -3
- package/esm/plugins/source/editor/engines/ace.js +9 -3
- package/esm/types/types.d.ts +3 -0
- package/package.json +1 -1
- package/types/jodit.d.ts +3 -3
- package/types/types/types.d.ts +3 -0
package/es2021/jodit.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* jodit - Jodit is an awesome and useful wysiwyg editor with filebrowser
|
|
3
3
|
* Author: Chupurnov <chupurnov@gmail.com> (https://xdsoft.net/jodit/)
|
|
4
|
-
* Version: v4.2.
|
|
4
|
+
* Version: v4.2.49
|
|
5
5
|
* Url: https://xdsoft.net/jodit/
|
|
6
6
|
* License(s): MIT
|
|
7
7
|
*/
|
|
@@ -1736,7 +1736,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
1736
1736
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
1737
1737
|
* Copyright (c) 2013-2024 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
|
|
1738
1738
|
*/
|
|
1739
|
-
const APP_VERSION = "4.2.
|
|
1739
|
+
const APP_VERSION = "4.2.49";
|
|
1740
1740
|
// prettier-ignore
|
|
1741
1741
|
const ES = "es2021";
|
|
1742
1742
|
const IS_ES_MODERN = true;
|
|
@@ -16242,11 +16242,11 @@ let View = View_1 = class View extends jodit_core_component_component__WEBPACK_I
|
|
|
16242
16242
|
super.destruct();
|
|
16243
16243
|
}
|
|
16244
16244
|
};
|
|
16245
|
-
// from webpack.config.
|
|
16245
|
+
// from webpack.config.ts
|
|
16246
16246
|
View.ES = jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.ES;
|
|
16247
16247
|
View.version = jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.APP_VERSION;
|
|
16248
|
-
View.esNext = jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.IS_ES_NEXT; // from webpack.config.
|
|
16249
|
-
View.esModern = jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.IS_ES_MODERN; // from webpack.config.
|
|
16248
|
+
View.esNext = jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.IS_ES_NEXT; // from webpack.config.ts
|
|
16249
|
+
View.esModern = jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.IS_ES_MODERN; // from webpack.config.ts
|
|
16250
16250
|
(0,tslib__WEBPACK_IMPORTED_MODULE_15__/* .__decorate */ .Cg)([
|
|
16251
16251
|
jodit_core_decorators_cache_cache__WEBPACK_IMPORTED_MODULE_5__/* .cache */ .PP
|
|
16252
16252
|
], View.prototype, "buffer", null);
|
|
@@ -39556,6 +39556,7 @@ let size = class size extends jodit_core_plugin_plugin__WEBPACK_IMPORTED_MODULE_
|
|
|
39556
39556
|
* Manually change height
|
|
39557
39557
|
*/
|
|
39558
39558
|
__setHeight(height) {
|
|
39559
|
+
const { clientHeight, clientWidth } = this.j.container;
|
|
39559
39560
|
if ((0,jodit_core_helpers_checker_is_number__WEBPACK_IMPORTED_MODULE_5__/* .isNumber */ .E)(height)) {
|
|
39560
39561
|
const { minHeight, maxHeight } = this.j.o;
|
|
39561
39562
|
if ((0,jodit_core_helpers_checker_is_number__WEBPACK_IMPORTED_MODULE_5__/* .isNumber */ .E)(minHeight) && minHeight > height) {
|
|
@@ -39569,12 +39570,13 @@ let size = class size extends jodit_core_plugin_plugin__WEBPACK_IMPORTED_MODULE_
|
|
|
39569
39570
|
if (this.j.o.saveHeightInStorage) {
|
|
39570
39571
|
this.j.storage.set('height', height);
|
|
39571
39572
|
}
|
|
39572
|
-
this.__resizeWorkspaceImd();
|
|
39573
|
+
this.__resizeWorkspaceImd({ clientHeight, clientWidth });
|
|
39573
39574
|
}
|
|
39574
39575
|
/**
|
|
39575
39576
|
* Manually change width
|
|
39576
39577
|
*/
|
|
39577
39578
|
__setWidth(width) {
|
|
39579
|
+
const { clientHeight, clientWidth } = this.j.container;
|
|
39578
39580
|
if ((0,jodit_core_helpers_checker_is_number__WEBPACK_IMPORTED_MODULE_5__/* .isNumber */ .E)(width)) {
|
|
39579
39581
|
const { minWidth, maxWidth } = this.j.o;
|
|
39580
39582
|
if ((0,jodit_core_helpers_checker_is_number__WEBPACK_IMPORTED_MODULE_5__/* .isNumber */ .E)(minWidth) && minWidth > width) {
|
|
@@ -39585,7 +39587,7 @@ let size = class size extends jodit_core_plugin_plugin__WEBPACK_IMPORTED_MODULE_
|
|
|
39585
39587
|
}
|
|
39586
39588
|
}
|
|
39587
39589
|
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_4__/* .css */ .A)(this.j.container, 'width', width);
|
|
39588
|
-
this.__resizeWorkspaceImd();
|
|
39590
|
+
this.__resizeWorkspaceImd({ clientHeight, clientWidth });
|
|
39589
39591
|
}
|
|
39590
39592
|
/**
|
|
39591
39593
|
* Returns service spaces: toolbar + statusbar
|
|
@@ -39598,7 +39600,7 @@ let size = class size extends jodit_core_plugin_plugin__WEBPACK_IMPORTED_MODULE_
|
|
|
39598
39600
|
/**
|
|
39599
39601
|
* Calculate workspace height
|
|
39600
39602
|
*/
|
|
39601
|
-
__resizeWorkspaceImd() {
|
|
39603
|
+
__resizeWorkspaceImd({ clientHeight, clientWidth } = this.j.container) {
|
|
39602
39604
|
if (!this.j || this.j.isDestructed || !this.j.o || this.j.o.inline) {
|
|
39603
39605
|
return;
|
|
39604
39606
|
}
|
|
@@ -39625,6 +39627,11 @@ let size = class size extends jodit_core_plugin_plugin__WEBPACK_IMPORTED_MODULE_
|
|
|
39625
39627
|
? this.j.container.offsetHeight - this.__getNotWorkHeight()
|
|
39626
39628
|
: 'auto');
|
|
39627
39629
|
}
|
|
39630
|
+
const { clientHeight: newClientHeight, clientWidth: newClientWidth } = this.j.container;
|
|
39631
|
+
if (clientHeight !== newClientHeight ||
|
|
39632
|
+
clientWidth !== newClientWidth) {
|
|
39633
|
+
this.j.e.fire(this.j, 'resize');
|
|
39634
|
+
}
|
|
39628
39635
|
}
|
|
39629
39636
|
/** @override **/
|
|
39630
39637
|
beforeDestruct(jodit) {
|
|
@@ -39823,10 +39830,12 @@ class AceEditor extends jodit_plugins_source_editor_sourceEditor__WEBPACK_IMPORT
|
|
|
39823
39830
|
if (editor.getRealMode() !== jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.MODE_WYSIWYG) {
|
|
39824
39831
|
this.setValue(this.getValue());
|
|
39825
39832
|
}
|
|
39826
|
-
const onResize = this.j.async.
|
|
39827
|
-
if (editor.isInDestruct
|
|
39833
|
+
const onResize = this.j.async.throttle(() => {
|
|
39834
|
+
if (editor.isInDestruct ||
|
|
39835
|
+
editor.getMode() === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.MODE_WYSIWYG) {
|
|
39828
39836
|
return;
|
|
39829
39837
|
}
|
|
39838
|
+
const hasFocus = this.instance.isFocused();
|
|
39830
39839
|
if (editor.o.height !== 'auto') {
|
|
39831
39840
|
this.instance.setOption('maxLines', editor.workplace.offsetHeight /
|
|
39832
39841
|
this.instance.renderer.lineHeight);
|
|
@@ -39835,8 +39844,11 @@ class AceEditor extends jodit_plugins_source_editor_sourceEditor__WEBPACK_IMPORT
|
|
|
39835
39844
|
this.instance.setOption('maxLines', Infinity);
|
|
39836
39845
|
}
|
|
39837
39846
|
this.instance.resize();
|
|
39847
|
+
hasFocus && this.focus();
|
|
39838
39848
|
}, this.j.defaultTimeout * 2);
|
|
39839
|
-
editor.e
|
|
39849
|
+
editor.e
|
|
39850
|
+
.on(editor, 'resize', onResize)
|
|
39851
|
+
.on('afterResize afterSetMode', onResize);
|
|
39840
39852
|
onResize();
|
|
39841
39853
|
this.onReady();
|
|
39842
39854
|
};
|
|
@@ -39887,6 +39899,7 @@ class AceEditor extends jodit_plugins_source_editor_sourceEditor__WEBPACK_IMPORT
|
|
|
39887
39899
|
return this.instance.isFocused();
|
|
39888
39900
|
}
|
|
39889
39901
|
focus() {
|
|
39902
|
+
this.instance.container.focus();
|
|
39890
39903
|
this.instance.focus();
|
|
39891
39904
|
}
|
|
39892
39905
|
blur() {
|