jodit 4.0.0-beta.88 → 4.0.0-beta.91
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 +28 -5
- package/README.md +4 -4
- package/es2015/jodit.css +1 -1
- package/es2015/jodit.fat.min.js +2 -2
- package/es2015/jodit.js +29 -12
- package/es2015/jodit.min.js +2 -2
- 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 +33 -12
- package/es2018/jodit.min.js +2 -2
- 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 +33 -12
- package/es2021/jodit.min.js +2 -2
- 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 +33 -12
- package/es2021.en/jodit.min.js +2 -2
- 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/jodit.css +2 -2
- package/es5/jodit.fat.min.js +2 -2
- package/es5/jodit.js +29 -11
- package/es5/jodit.min.css +2 -2
- package/es5/jodit.min.js +2 -2
- 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/traits/dlgs.js +3 -3
- package/esm/modules/dialog/alert.js +3 -1
- package/esm/modules/dialog/confirm.js +3 -1
- package/esm/modules/dialog/dialog.d.ts +1 -0
- package/esm/modules/dialog/dialog.js +17 -3
- package/esm/modules/dialog/prompt.d.ts +1 -0
- package/esm/modules/dialog/prompt.js +4 -1
- package/esm/plugins/about/about.js +1 -1
- package/esm/types/dialog.d.ts +2 -0
- package/package.json +1 -1
- package/types/modules/dialog/dialog.d.ts +1 -0
- package/types/modules/dialog/prompt.d.ts +1 -0
- package/types/types/dialog.d.ts +2 -0
package/es5/jodit.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* jodit - Jodit is awesome and usefully wysiwyg editor with filebrowser
|
|
3
3
|
* Author: Chupurnov <chupurnov@gmail.com> (https://xdsoft.net/jodit/)
|
|
4
|
-
* Version: v4.0.0-beta.
|
|
4
|
+
* Version: v4.0.0-beta.91
|
|
5
5
|
* Url: https://xdsoft.net/jodit/
|
|
6
6
|
* License(s): MIT
|
|
7
7
|
*/
|
|
@@ -6925,7 +6925,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
6925
6925
|
* Copyright (c) 2013-2023 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
|
|
6926
6926
|
*/
|
|
6927
6927
|
|
|
6928
|
-
var APP_VERSION = "4.0.0-beta.
|
|
6928
|
+
var APP_VERSION = "4.0.0-beta.91";
|
|
6929
6929
|
// prettier-ignore
|
|
6930
6930
|
var ES = "es5";
|
|
6931
6931
|
var IS_ES_MODERN = false;
|
|
@@ -18399,18 +18399,18 @@ var Dlgs = /** @class */ (function () {
|
|
|
18399
18399
|
Dlgs.prototype.confirm = function (msg, title, callback) {
|
|
18400
18400
|
msg = processTitle(msg, this);
|
|
18401
18401
|
title = processTitle(title, this);
|
|
18402
|
-
return jodit_modules_dialog__WEBPACK_IMPORTED_MODULE_0__/* .Confirm */ .I4.call(this.dlg(), msg, title, callback);
|
|
18402
|
+
return jodit_modules_dialog__WEBPACK_IMPORTED_MODULE_0__/* .Confirm */ .I4.call(this.dlg({ closeOnClickOverlay: true }), msg, title, callback);
|
|
18403
18403
|
};
|
|
18404
18404
|
Dlgs.prototype.prompt = function (msg, title, callback, placeholder, defaultValue) {
|
|
18405
18405
|
msg = processTitle(msg, this);
|
|
18406
18406
|
title = processTitle(title, this);
|
|
18407
18407
|
placeholder = processTitle(placeholder, this);
|
|
18408
|
-
return jodit_modules_dialog__WEBPACK_IMPORTED_MODULE_0__/* .Prompt */ .NL.call(this.dlg(), msg, title, callback, placeholder, defaultValue);
|
|
18408
|
+
return jodit_modules_dialog__WEBPACK_IMPORTED_MODULE_0__/* .Prompt */ .NL.call(this.dlg({ closeOnClickOverlay: true }), msg, title, callback, placeholder, defaultValue);
|
|
18409
18409
|
};
|
|
18410
18410
|
Dlgs.prototype.alert = function (msg, title, callback, className) {
|
|
18411
18411
|
msg = processTitle(msg, this);
|
|
18412
18412
|
title = processTitle(title, this);
|
|
18413
|
-
return jodit_modules_dialog__WEBPACK_IMPORTED_MODULE_0__/* .Alert */ .bZ.call(this.dlg(), msg, title, callback, className);
|
|
18413
|
+
return jodit_modules_dialog__WEBPACK_IMPORTED_MODULE_0__/* .Alert */ .bZ.call(this.dlg({ closeOnClickOverlay: true }), msg, title, callback, className);
|
|
18414
18414
|
};
|
|
18415
18415
|
return Dlgs;
|
|
18416
18416
|
}());
|
|
@@ -23575,7 +23575,9 @@ function Alert(msg, title, callback, className) {
|
|
|
23575
23575
|
callback = title;
|
|
23576
23576
|
title = undefined;
|
|
23577
23577
|
}
|
|
23578
|
-
var dialog = this instanceof _dialog__WEBPACK_IMPORTED_MODULE_2__/* .Dialog */ .V
|
|
23578
|
+
var dialog = this instanceof _dialog__WEBPACK_IMPORTED_MODULE_2__/* .Dialog */ .V
|
|
23579
|
+
? this
|
|
23580
|
+
: new _dialog__WEBPACK_IMPORTED_MODULE_2__/* .Dialog */ .V({ closeOnClickOverlay: true }), container = dialog.c.div(className), okButton = (0,jodit_core_ui_button_button_button__WEBPACK_IMPORTED_MODULE_1__/* .Button */ .zx)(dialog, 'ok', 'Ok');
|
|
23579
23581
|
(0,jodit_core_helpers_array_as_array__WEBPACK_IMPORTED_MODULE_4__/* .asArray */ ._)(msg).forEach(function (oneMessage) {
|
|
23580
23582
|
container.appendChild(jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__/* .Dom */ .i.isNode(oneMessage) ? oneMessage : dialog.c.fromHTML(oneMessage));
|
|
23581
23583
|
});
|
|
@@ -23626,7 +23628,9 @@ function Alert(msg, title, callback, className) {
|
|
|
23626
23628
|
* ```
|
|
23627
23629
|
*/
|
|
23628
23630
|
function Confirm(msg, title, callback) {
|
|
23629
|
-
var dialog = this instanceof jodit_modules_dialog_dialog__WEBPACK_IMPORTED_MODULE_0__/* .Dialog */ .V
|
|
23631
|
+
var dialog = this instanceof jodit_modules_dialog_dialog__WEBPACK_IMPORTED_MODULE_0__/* .Dialog */ .V
|
|
23632
|
+
? this
|
|
23633
|
+
: new jodit_modules_dialog_dialog__WEBPACK_IMPORTED_MODULE_0__/* .Dialog */ .V({ closeOnClickOverlay: true }), $div = dialog.c.fromHTML('<form class="jodit-dialog_prompt"></form>'), $label = dialog.c.element('label');
|
|
23630
23634
|
if ((0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_2__/* .isFunction */ .m)(title)) {
|
|
23631
23635
|
callback = title;
|
|
23632
23636
|
title = undefined;
|
|
@@ -23761,7 +23765,7 @@ var Dialog = /** @class */ (function (_super) {
|
|
|
23761
23765
|
*/
|
|
23762
23766
|
_this.isOpened = false;
|
|
23763
23767
|
var self = _this;
|
|
23764
|
-
self.options = (0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_4__.ConfigProto)(options, (0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_4__.ConfigProto)(jodit_config__WEBPACK_IMPORTED_MODULE_0__/* .Config */ .D.prototype.dialog,
|
|
23768
|
+
self.options = (0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_4__.ConfigProto)(options, (0,jodit_core_helpers_utils__WEBPACK_IMPORTED_MODULE_4__.ConfigProto)(jodit_config__WEBPACK_IMPORTED_MODULE_0__/* .Config */ .D.prototype.dialog, Dialog_1.defaultOptions));
|
|
23765
23769
|
jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_7__/* .Dom */ .i.safeRemove(self.container);
|
|
23766
23770
|
var n = _this.getFullElName.bind(_this);
|
|
23767
23771
|
self.container = _this.c.fromHTML("<div class=\"jodit jodit-dialog ".concat(_this.componentName, "\">\n\t\t\t\t<div class=\"").concat(n('overlay'), "\"></div>\n\t\t\t\t<div class=\"").concat(_this.getFullElName('panel'), "\">\n\t\t\t\t\t<div class=\"").concat(n('header'), "\">\n\t\t\t\t\t\t<div class=\"").concat(n('header-title'), "\"></div>\n\t\t\t\t\t\t<div class=\"").concat(n('header-toolbar'), "\"></div>\n\t\t\t\t\t</div>\n\t\t\t\t\t<div class=\"").concat(n('content'), "\"></div>\n\t\t\t\t\t<div class=\"").concat(n('footer'), "\"></div>\n\t\t\t\t\t<div class=\"").concat(n('resizer'), "\">").concat(jodit_core_ui__WEBPACK_IMPORTED_MODULE_12__/* .Icon */ .JO.get('resize_handler'), "</div>\n\t\t\t\t</div>\n\t\t\t</div>"));
|
|
@@ -23806,8 +23810,14 @@ var Dialog = /** @class */ (function (_super) {
|
|
|
23806
23810
|
.on(self.container, 'close_dialog', self.close)
|
|
23807
23811
|
.on(_this.ow, 'keydown', _this.onEsc)
|
|
23808
23812
|
.on(_this.ow, 'resize', _this.onResize);
|
|
23813
|
+
if (_this.o.closeOnClickOverlay) {
|
|
23814
|
+
var overlay = self.getElm('overlay');
|
|
23815
|
+
void 0;
|
|
23816
|
+
_this.e.on(overlay, 'click', self.close);
|
|
23817
|
+
}
|
|
23809
23818
|
return _this;
|
|
23810
23819
|
}
|
|
23820
|
+
Dialog_1 = Dialog;
|
|
23811
23821
|
/** @override */
|
|
23812
23822
|
Dialog.prototype.className = function () {
|
|
23813
23823
|
return 'Dialog';
|
|
@@ -23912,6 +23922,9 @@ var Dialog = /** @class */ (function (_super) {
|
|
|
23912
23922
|
}
|
|
23913
23923
|
};
|
|
23914
23924
|
Dialog.prototype.onEsc = function (e) {
|
|
23925
|
+
if (!this.o.closeOnEsc) {
|
|
23926
|
+
return;
|
|
23927
|
+
}
|
|
23915
23928
|
if (this.isOpened &&
|
|
23916
23929
|
e.key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_1__.KEY_ESC &&
|
|
23917
23930
|
this.getMod('static') !== true) {
|
|
@@ -24245,6 +24258,7 @@ var Dialog = /** @class */ (function (_super) {
|
|
|
24245
24258
|
}
|
|
24246
24259
|
_super.prototype.destruct.call(this);
|
|
24247
24260
|
};
|
|
24261
|
+
var Dialog_1;
|
|
24248
24262
|
(0,tslib__WEBPACK_IMPORTED_MODULE_13__/* .__decorate */ .gn)([
|
|
24249
24263
|
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_10__.autobind
|
|
24250
24264
|
], Dialog.prototype, "onMouseUp", null);
|
|
@@ -24266,12 +24280,13 @@ var Dialog = /** @class */ (function (_super) {
|
|
|
24266
24280
|
(0,tslib__WEBPACK_IMPORTED_MODULE_13__/* .__decorate */ .gn)([
|
|
24267
24281
|
(0,jodit_core_decorators__WEBPACK_IMPORTED_MODULE_10__.hook)('ready')
|
|
24268
24282
|
], Dialog.prototype, "buildToolbar", null);
|
|
24269
|
-
Dialog = (0,tslib__WEBPACK_IMPORTED_MODULE_13__/* .__decorate */ .gn)([
|
|
24283
|
+
Dialog = Dialog_1 = (0,tslib__WEBPACK_IMPORTED_MODULE_13__/* .__decorate */ .gn)([
|
|
24270
24284
|
jodit_core_decorators__WEBPACK_IMPORTED_MODULE_10__.component
|
|
24271
24285
|
], Dialog);
|
|
24272
24286
|
return Dialog;
|
|
24273
24287
|
}(jodit_core_view_view_with_toolbar__WEBPACK_IMPORTED_MODULE_6__/* .ViewWithToolbar */ .C));
|
|
24274
24288
|
|
|
24289
|
+
Dialog.defaultOptions = (0,tslib__WEBPACK_IMPORTED_MODULE_13__/* .__assign */ .pi)((0,tslib__WEBPACK_IMPORTED_MODULE_13__/* .__assign */ .pi)({}, jodit_core_view_view__WEBPACK_IMPORTED_MODULE_11__/* .View */ .G.defaultOptions), { closeOnClickOverlay: false, closeOnEsc: true });
|
|
24275
24290
|
|
|
24276
24291
|
|
|
24277
24292
|
/***/ }),
|
|
@@ -24331,6 +24346,7 @@ var Dialog = /** @class */ (function (_super) {
|
|
|
24331
24346
|
/**
|
|
24332
24347
|
* Show `Prompt` dialog. Work without Jodit object
|
|
24333
24348
|
*
|
|
24349
|
+
* @param msg - Dialog content
|
|
24334
24350
|
* @param title - Title or callback
|
|
24335
24351
|
* @param callback - callback. The first argument is the value entered
|
|
24336
24352
|
* @param placeholder - Placeholder for input
|
|
@@ -24346,7 +24362,9 @@ var Dialog = /** @class */ (function (_super) {
|
|
|
24346
24362
|
* ```
|
|
24347
24363
|
*/
|
|
24348
24364
|
function Prompt(msg, title, callback, placeholder, defaultValue) {
|
|
24349
|
-
var dialog = this instanceof _dialog__WEBPACK_IMPORTED_MODULE_2__/* .Dialog */ .V
|
|
24365
|
+
var dialog = this instanceof _dialog__WEBPACK_IMPORTED_MODULE_2__/* .Dialog */ .V
|
|
24366
|
+
? this
|
|
24367
|
+
: new _dialog__WEBPACK_IMPORTED_MODULE_2__/* .Dialog */ .V({ closeOnClickOverlay: true }), cancelButton = (0,jodit_core_ui_button_button_button__WEBPACK_IMPORTED_MODULE_0__/* .Button */ .zx)(dialog, 'cancel', 'Cancel'), okButton = (0,jodit_core_ui_button_button_button__WEBPACK_IMPORTED_MODULE_0__/* .Button */ .zx)(dialog, 'ok', 'Ok'), form = dialog.c.element('form', {
|
|
24350
24368
|
class: 'jodit-dialog_prompt'
|
|
24351
24369
|
}), inputElement = dialog.c.element('input', {
|
|
24352
24370
|
autofocus: true,
|
|
@@ -30916,7 +30934,7 @@ var TabsWidget = function (jodit, tabs, state) {
|
|
|
30916
30934
|
|
|
30917
30935
|
jodit_config__WEBPACK_IMPORTED_MODULE_0__/* .Config */ .D.prototype.controls.about = {
|
|
30918
30936
|
exec: function (editor) {
|
|
30919
|
-
var dialog = editor.dlg(), i = editor.i18n.bind(editor);
|
|
30937
|
+
var dialog = editor.dlg({ closeOnClickOverlay: true }), i = editor.i18n.bind(editor);
|
|
30920
30938
|
dialog
|
|
30921
30939
|
.setMod('theme', editor.o.theme)
|
|
30922
30940
|
.setHeader(i('About Jodit'))
|
package/es5/jodit.min.css
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* jodit - Jodit is awesome and usefully wysiwyg editor with filebrowser
|
|
3
3
|
* Author: Chupurnov <chupurnov@gmail.com> (https://xdsoft.net/jodit/)
|
|
4
|
-
* Version: v4.0.0-beta.
|
|
4
|
+
* Version: v4.0.0-beta.91
|
|
5
5
|
* Url: https://xdsoft.net/jodit/
|
|
6
6
|
* License(s): MIT
|
|
7
7
|
*/
|
|
8
8
|
/*!
|
|
9
9
|
* jodit - Jodit is awesome and usefully wysiwyg editor with filebrowser
|
|
10
10
|
* Author: Chupurnov <chupurnov@gmail.com> (https://xdsoft.net/jodit/)
|
|
11
|
-
* Version: v4.0.0-beta.
|
|
11
|
+
* Version: v4.0.0-beta.91
|
|
12
12
|
* Url: https://xdsoft.net/jodit/
|
|
13
13
|
* License(s): MIT
|
|
14
14
|
*/
|