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/es2015/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
|
*/
|
|
@@ -1735,7 +1735,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
1735
1735
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
1736
1736
|
* Copyright (c) 2013-2024 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
|
|
1737
1737
|
*/
|
|
1738
|
-
const APP_VERSION = "4.2.
|
|
1738
|
+
const APP_VERSION = "4.2.49";
|
|
1739
1739
|
// prettier-ignore
|
|
1740
1740
|
const ES = "es2015";
|
|
1741
1741
|
const IS_ES_MODERN = true;
|
|
@@ -16240,11 +16240,11 @@ let View = View_1 = class View extends jodit_core_component_component__WEBPACK_I
|
|
|
16240
16240
|
super.destruct();
|
|
16241
16241
|
}
|
|
16242
16242
|
};
|
|
16243
|
-
// from webpack.config.
|
|
16243
|
+
// from webpack.config.ts
|
|
16244
16244
|
View.ES = jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.ES;
|
|
16245
16245
|
View.version = jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.APP_VERSION;
|
|
16246
|
-
View.esNext = jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.IS_ES_NEXT; // from webpack.config.
|
|
16247
|
-
View.esModern = jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.IS_ES_MODERN; // from webpack.config.
|
|
16246
|
+
View.esNext = jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.IS_ES_NEXT; // from webpack.config.ts
|
|
16247
|
+
View.esModern = jodit_core_constants__WEBPACK_IMPORTED_MODULE_3__.IS_ES_MODERN; // from webpack.config.ts
|
|
16248
16248
|
(0,tslib__WEBPACK_IMPORTED_MODULE_15__/* .__decorate */ .Cg)([
|
|
16249
16249
|
jodit_core_decorators_cache_cache__WEBPACK_IMPORTED_MODULE_5__/* .cache */ .PP
|
|
16250
16250
|
], View.prototype, "buffer", null);
|
|
@@ -39617,6 +39617,7 @@ let size = class size extends jodit_core_plugin_plugin__WEBPACK_IMPORTED_MODULE_
|
|
|
39617
39617
|
* Manually change height
|
|
39618
39618
|
*/
|
|
39619
39619
|
__setHeight(height) {
|
|
39620
|
+
const { clientHeight, clientWidth } = this.j.container;
|
|
39620
39621
|
if ((0,jodit_core_helpers_checker_is_number__WEBPACK_IMPORTED_MODULE_5__/* .isNumber */ .E)(height)) {
|
|
39621
39622
|
const { minHeight, maxHeight } = this.j.o;
|
|
39622
39623
|
if ((0,jodit_core_helpers_checker_is_number__WEBPACK_IMPORTED_MODULE_5__/* .isNumber */ .E)(minHeight) && minHeight > height) {
|
|
@@ -39630,12 +39631,13 @@ let size = class size extends jodit_core_plugin_plugin__WEBPACK_IMPORTED_MODULE_
|
|
|
39630
39631
|
if (this.j.o.saveHeightInStorage) {
|
|
39631
39632
|
this.j.storage.set('height', height);
|
|
39632
39633
|
}
|
|
39633
|
-
this.__resizeWorkspaceImd();
|
|
39634
|
+
this.__resizeWorkspaceImd({ clientHeight, clientWidth });
|
|
39634
39635
|
}
|
|
39635
39636
|
/**
|
|
39636
39637
|
* Manually change width
|
|
39637
39638
|
*/
|
|
39638
39639
|
__setWidth(width) {
|
|
39640
|
+
const { clientHeight, clientWidth } = this.j.container;
|
|
39639
39641
|
if ((0,jodit_core_helpers_checker_is_number__WEBPACK_IMPORTED_MODULE_5__/* .isNumber */ .E)(width)) {
|
|
39640
39642
|
const { minWidth, maxWidth } = this.j.o;
|
|
39641
39643
|
if ((0,jodit_core_helpers_checker_is_number__WEBPACK_IMPORTED_MODULE_5__/* .isNumber */ .E)(minWidth) && minWidth > width) {
|
|
@@ -39646,7 +39648,7 @@ let size = class size extends jodit_core_plugin_plugin__WEBPACK_IMPORTED_MODULE_
|
|
|
39646
39648
|
}
|
|
39647
39649
|
}
|
|
39648
39650
|
(0,jodit_core_helpers_utils_css__WEBPACK_IMPORTED_MODULE_4__/* .css */ .A)(this.j.container, 'width', width);
|
|
39649
|
-
this.__resizeWorkspaceImd();
|
|
39651
|
+
this.__resizeWorkspaceImd({ clientHeight, clientWidth });
|
|
39650
39652
|
}
|
|
39651
39653
|
/**
|
|
39652
39654
|
* Returns service spaces: toolbar + statusbar
|
|
@@ -39660,7 +39662,7 @@ let size = class size extends jodit_core_plugin_plugin__WEBPACK_IMPORTED_MODULE_
|
|
|
39660
39662
|
/**
|
|
39661
39663
|
* Calculate workspace height
|
|
39662
39664
|
*/
|
|
39663
|
-
__resizeWorkspaceImd() {
|
|
39665
|
+
__resizeWorkspaceImd({ clientHeight, clientWidth } = this.j.container) {
|
|
39664
39666
|
if (!this.j || this.j.isDestructed || !this.j.o || this.j.o.inline) {
|
|
39665
39667
|
return;
|
|
39666
39668
|
}
|
|
@@ -39687,6 +39689,11 @@ let size = class size extends jodit_core_plugin_plugin__WEBPACK_IMPORTED_MODULE_
|
|
|
39687
39689
|
? this.j.container.offsetHeight - this.__getNotWorkHeight()
|
|
39688
39690
|
: 'auto');
|
|
39689
39691
|
}
|
|
39692
|
+
const { clientHeight: newClientHeight, clientWidth: newClientWidth } = this.j.container;
|
|
39693
|
+
if (clientHeight !== newClientHeight ||
|
|
39694
|
+
clientWidth !== newClientWidth) {
|
|
39695
|
+
this.j.e.fire(this.j, 'resize');
|
|
39696
|
+
}
|
|
39690
39697
|
}
|
|
39691
39698
|
/** @override **/
|
|
39692
39699
|
beforeDestruct(jodit) {
|
|
@@ -39885,10 +39892,12 @@ class AceEditor extends jodit_plugins_source_editor_sourceEditor__WEBPACK_IMPORT
|
|
|
39885
39892
|
if (editor.getRealMode() !== jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.MODE_WYSIWYG) {
|
|
39886
39893
|
this.setValue(this.getValue());
|
|
39887
39894
|
}
|
|
39888
|
-
const onResize = this.j.async.
|
|
39889
|
-
if (editor.isInDestruct
|
|
39895
|
+
const onResize = this.j.async.throttle(() => {
|
|
39896
|
+
if (editor.isInDestruct ||
|
|
39897
|
+
editor.getMode() === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.MODE_WYSIWYG) {
|
|
39890
39898
|
return;
|
|
39891
39899
|
}
|
|
39900
|
+
const hasFocus = this.instance.isFocused();
|
|
39892
39901
|
if (editor.o.height !== 'auto') {
|
|
39893
39902
|
this.instance.setOption('maxLines', editor.workplace.offsetHeight /
|
|
39894
39903
|
this.instance.renderer.lineHeight);
|
|
@@ -39897,8 +39906,11 @@ class AceEditor extends jodit_plugins_source_editor_sourceEditor__WEBPACK_IMPORT
|
|
|
39897
39906
|
this.instance.setOption('maxLines', Infinity);
|
|
39898
39907
|
}
|
|
39899
39908
|
this.instance.resize();
|
|
39909
|
+
hasFocus && this.focus();
|
|
39900
39910
|
}, this.j.defaultTimeout * 2);
|
|
39901
|
-
editor.e
|
|
39911
|
+
editor.e
|
|
39912
|
+
.on(editor, 'resize', onResize)
|
|
39913
|
+
.on('afterResize afterSetMode', onResize);
|
|
39902
39914
|
onResize();
|
|
39903
39915
|
this.onReady();
|
|
39904
39916
|
};
|
|
@@ -39950,6 +39962,7 @@ class AceEditor extends jodit_plugins_source_editor_sourceEditor__WEBPACK_IMPORT
|
|
|
39950
39962
|
return this.instance.isFocused();
|
|
39951
39963
|
}
|
|
39952
39964
|
focus() {
|
|
39965
|
+
this.instance.container.focus();
|
|
39953
39966
|
this.instance.focus();
|
|
39954
39967
|
}
|
|
39955
39968
|
blur() {
|