jodit 4.2.41 → 4.2.45

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.
Files changed (119) hide show
  1. package/CHANGELOG.md +65 -5
  2. package/es2015/jodit.css +5 -7
  3. package/es2015/jodit.fat.min.css +1 -1
  4. package/es2015/jodit.fat.min.js +2 -2
  5. package/es2015/jodit.js +121 -45
  6. package/es2015/jodit.min.css +1 -1
  7. package/es2015/jodit.min.js +2 -2
  8. package/es2015/plugins/debug/debug.css +1 -1
  9. package/es2015/plugins/debug/debug.js +1 -1
  10. package/es2015/plugins/debug/debug.min.js +1 -1
  11. package/es2015/plugins/speech-recognize/speech-recognize.css +1 -1
  12. package/es2015/plugins/speech-recognize/speech-recognize.js +1 -1
  13. package/es2015/plugins/speech-recognize/speech-recognize.min.js +1 -1
  14. package/es2018/jodit.css +5 -7
  15. package/es2018/jodit.fat.min.css +1 -1
  16. package/es2018/jodit.fat.min.js +2 -2
  17. package/es2018/jodit.js +121 -45
  18. package/es2018/jodit.min.css +1 -1
  19. package/es2018/jodit.min.js +2 -2
  20. package/es2018/plugins/debug/debug.css +1 -1
  21. package/es2018/plugins/debug/debug.js +1 -1
  22. package/es2018/plugins/debug/debug.min.js +1 -1
  23. package/es2018/plugins/speech-recognize/speech-recognize.css +1 -1
  24. package/es2018/plugins/speech-recognize/speech-recognize.js +1 -1
  25. package/es2018/plugins/speech-recognize/speech-recognize.min.js +1 -1
  26. package/es2021/jodit.css +5 -7
  27. package/es2021/jodit.fat.min.css +1 -1
  28. package/es2021/jodit.fat.min.js +2 -2
  29. package/es2021/jodit.js +121 -45
  30. package/es2021/jodit.min.css +1 -1
  31. package/es2021/jodit.min.js +2 -2
  32. package/es2021/plugins/debug/debug.css +1 -1
  33. package/es2021/plugins/debug/debug.js +1 -1
  34. package/es2021/plugins/debug/debug.min.js +1 -1
  35. package/es2021/plugins/speech-recognize/speech-recognize.css +1 -1
  36. package/es2021/plugins/speech-recognize/speech-recognize.js +1 -1
  37. package/es2021/plugins/speech-recognize/speech-recognize.min.js +1 -1
  38. package/es2021.en/jodit.css +5 -7
  39. package/es2021.en/jodit.fat.min.css +1 -1
  40. package/es2021.en/jodit.fat.min.js +2 -2
  41. package/es2021.en/jodit.js +121 -45
  42. package/es2021.en/jodit.min.css +1 -1
  43. package/es2021.en/jodit.min.js +2 -2
  44. package/es2021.en/plugins/debug/debug.css +1 -1
  45. package/es2021.en/plugins/debug/debug.js +1 -1
  46. package/es2021.en/plugins/debug/debug.min.js +1 -1
  47. package/es2021.en/plugins/speech-recognize/speech-recognize.css +1 -1
  48. package/es2021.en/plugins/speech-recognize/speech-recognize.js +1 -1
  49. package/es2021.en/plugins/speech-recognize/speech-recognize.min.js +1 -1
  50. package/es5/164.fat.min.js +1 -1
  51. package/es5/164.min.js +1 -1
  52. package/es5/5.fat.min.js +1 -1
  53. package/es5/5.min.js +1 -1
  54. package/es5/jodit.css +35 -66
  55. package/es5/jodit.fat.min.css +1 -1
  56. package/es5/jodit.fat.min.js +2 -2
  57. package/es5/jodit.js +121 -45
  58. package/es5/jodit.min.css +3 -3
  59. package/es5/jodit.min.js +2 -2
  60. package/es5/plugins/debug/debug.css +1 -1
  61. package/es5/plugins/debug/debug.js +1 -1
  62. package/es5/plugins/debug/debug.min.js +1 -1
  63. package/es5/plugins/speech-recognize/speech-recognize.css +1 -1
  64. package/es5/plugins/speech-recognize/speech-recognize.js +1 -1
  65. package/es5/plugins/speech-recognize/speech-recognize.min.js +1 -1
  66. package/esm/core/constants.js +1 -1
  67. package/esm/core/helpers/utils/complete-url.d.ts +0 -3
  68. package/esm/core/helpers/utils/complete-url.js +1 -1
  69. package/esm/core/helpers/utils/config-proto.d.ts +18 -0
  70. package/esm/core/helpers/utils/config-proto.js +25 -0
  71. package/esm/core/selection/style/api/extract.js +1 -0
  72. package/esm/jodit.d.ts +11 -1
  73. package/esm/jodit.js +14 -8
  74. package/esm/modules/history/snapshot.d.ts +1 -0
  75. package/esm/modules/history/snapshot.js +8 -1
  76. package/esm/modules/toolbar/button/button.js +18 -9
  77. package/esm/plugins/ai-assistant/langs/index.d.ts +3 -0
  78. package/esm/plugins/ai-assistant/langs/index.js +3 -0
  79. package/esm/plugins/image-properties/readers/align.d.ts +3 -1
  80. package/esm/plugins/image-properties/readers/align.js +3 -1
  81. package/esm/plugins/image-properties/readers/index.d.ts +3 -0
  82. package/esm/plugins/image-properties/readers/link.d.ts +3 -0
  83. package/esm/plugins/image-properties/readers/margin.js +3 -0
  84. package/esm/plugins/image-properties/readers/size.js +3 -0
  85. package/esm/plugins/image-properties/ui/ui-image-form.d.ts +3 -0
  86. package/esm/plugins/image-properties/ui/ui-image-main-tab.d.ts +3 -0
  87. package/esm/plugins/image-properties/ui/ui-image-position-tab.d.ts +3 -0
  88. package/esm/plugins/image-properties/utils/open-image-editor.d.ts +3 -0
  89. package/esm/plugins/image-properties/utils/open-image-popup.d.ts +3 -0
  90. package/esm/plugins/image-properties/utils/utils.js +3 -0
  91. package/esm/plugins/image-properties/writers/index.d.ts +3 -0
  92. package/esm/plugins/image-properties/writers/link.d.ts +3 -0
  93. package/esm/plugins/image-properties/writers/margin.d.ts +3 -0
  94. package/esm/plugins/image-properties/writers/size.js +3 -0
  95. package/esm/plugins/source/editor/engines/ace.js +4 -0
  96. package/esm/plugins/source/editor/engines/area.js +2 -1
  97. package/esm/plugins/symbols/config.js +6 -7
  98. package/esm/plugins/symbols/symbols.d.ts +1 -3
  99. package/esm/plugins/symbols/symbols.js +16 -11
  100. package/esm/types/history.d.ts +3 -0
  101. package/package.json +1 -1
  102. package/types/core/helpers/utils/complete-url.d.ts +0 -3
  103. package/types/core/helpers/utils/config-proto.d.ts +18 -0
  104. package/types/jodit.d.ts +11 -1
  105. package/types/modules/history/snapshot.d.ts +1 -0
  106. package/types/plugins/ai-assistant/langs/index.d.ts +3 -0
  107. package/types/plugins/image-properties/readers/align.d.ts +3 -1
  108. package/types/plugins/image-properties/readers/index.d.ts +3 -0
  109. package/types/plugins/image-properties/readers/link.d.ts +3 -0
  110. package/types/plugins/image-properties/ui/ui-image-form.d.ts +3 -0
  111. package/types/plugins/image-properties/ui/ui-image-main-tab.d.ts +3 -0
  112. package/types/plugins/image-properties/ui/ui-image-position-tab.d.ts +3 -0
  113. package/types/plugins/image-properties/utils/open-image-editor.d.ts +3 -0
  114. package/types/plugins/image-properties/utils/open-image-popup.d.ts +3 -0
  115. package/types/plugins/image-properties/writers/index.d.ts +3 -0
  116. package/types/plugins/image-properties/writers/link.d.ts +3 -0
  117. package/types/plugins/image-properties/writers/margin.d.ts +3 -0
  118. package/types/plugins/symbols/symbols.d.ts +1 -3
  119. package/types/types/history.d.ts +3 -0
package/es5/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.41
4
+ * Version: v4.2.45
5
5
  * Url: https://xdsoft.net/jodit/
6
6
  * License(s): MIT
7
7
  */
@@ -1838,7 +1838,7 @@ __webpack_require__.r(__webpack_exports__);
1838
1838
  * Copyright (c) 2013-2024 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
1839
1839
  */
1840
1840
 
1841
- var APP_VERSION = "4.2.41";
1841
+ var APP_VERSION = "4.2.45";
1842
1842
  // prettier-ignore
1843
1843
  var ES = "es5";
1844
1844
  var IS_ES_MODERN = false;
@@ -7886,10 +7886,10 @@ var buildQuery = function (data, prefix) {
7886
7886
  * Released under MIT see LICENSE.txt in the project root for license information.
7887
7887
  * Copyright (c) 2013-2024 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
7888
7888
  */
7889
-
7890
7889
  /**
7891
7890
  * @module helpers/utils
7892
7891
  */
7892
+
7893
7893
  var completeUrl = function (url) {
7894
7894
  if (jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.globalWindow.location.protocol === 'file:' && /^\/\//.test(url)) {
7895
7895
  url = 'https:' + url;
@@ -7905,8 +7905,9 @@ var completeUrl = function (url) {
7905
7905
 
7906
7906
  "use strict";
7907
7907
  /* harmony export */ __webpack_require__.d(__webpack_exports__, {
7908
- /* harmony export */ V: function() { return /* binding */ ConfigFlatten; },
7909
- /* harmony export */ t: function() { return /* binding */ ConfigProto; }
7908
+ /* harmony export */ VL: function() { return /* binding */ ConfigFlatten; },
7909
+ /* harmony export */ pi: function() { return /* binding */ ConfigDeepFlatten; },
7910
+ /* harmony export */ tb: function() { return /* binding */ ConfigProto; }
7910
7911
  /* harmony export */ });
7911
7912
  /* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(31635);
7912
7913
  /* harmony import */ var jodit_core_helpers_checker_is_array__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(37923);
@@ -8000,6 +8001,31 @@ function ConfigFlatten(obj) {
8000
8001
  return app;
8001
8002
  }, {});
8002
8003
  }
8004
+ /**
8005
+ * Returns a plain object from a prototype-based object.
8006
+ * ```typescript
8007
+ * const editor = Jodit.make('#editor', {
8008
+ * image: {
8009
+ * dialogWidth: 500
8010
+ * }
8011
+ * });
8012
+ *
8013
+ * console.log(editor.o.image.openOnDblClick) // true
8014
+ * // But you can't get all options in plain object
8015
+ * console.log(JSON.stringify(editor.o.image)); // {"dialogWidth":500}
8016
+ *
8017
+ * const plain = Jodit.modules.Helpers.ConfigDeepFlatten(editor.o.image);
8018
+ * console.log(JSON.stringify(plain)); // {"dialogWidth":500, "openOnDblClick": true, "editSrc": true, ...}
8019
+ * ```
8020
+ */
8021
+ function ConfigDeepFlatten(obj) {
8022
+ return (0,_utils__WEBPACK_IMPORTED_MODULE_1__/* .keys */ .HP)(obj, false).reduce(function (app, key) {
8023
+ app[key] = (0,jodit_core_helpers_checker_is_plain_object__WEBPACK_IMPORTED_MODULE_4__/* .isPlainObject */ .Q)(obj[key])
8024
+ ? ConfigDeepFlatten(obj[key])
8025
+ : obj[key];
8026
+ return app;
8027
+ }, {});
8028
+ }
8003
8029
 
8004
8030
 
8005
8031
  /***/ }),
@@ -8660,8 +8686,9 @@ var humanSizeToBytes = function (human) {
8660
8686
  __webpack_require__.r(__webpack_exports__);
8661
8687
  /* harmony export */ __webpack_require__.d(__webpack_exports__, {
8662
8688
  /* harmony export */ $$: function() { return /* reexport safe */ _selector__WEBPACK_IMPORTED_MODULE_23__.$$; },
8663
- /* harmony export */ ConfigFlatten: function() { return /* reexport safe */ _config_proto__WEBPACK_IMPORTED_MODULE_7__.V; },
8664
- /* harmony export */ ConfigProto: function() { return /* reexport safe */ _config_proto__WEBPACK_IMPORTED_MODULE_7__.t; },
8689
+ /* harmony export */ ConfigDeepFlatten: function() { return /* reexport safe */ _config_proto__WEBPACK_IMPORTED_MODULE_7__.pi; },
8690
+ /* harmony export */ ConfigFlatten: function() { return /* reexport safe */ _config_proto__WEBPACK_IMPORTED_MODULE_7__.VL; },
8691
+ /* harmony export */ ConfigProto: function() { return /* reexport safe */ _config_proto__WEBPACK_IMPORTED_MODULE_7__.tb; },
8665
8692
  /* harmony export */ ConnectionError: function() { return /* reexport safe */ _error__WEBPACK_IMPORTED_MODULE_13__.Rc; },
8666
8693
  /* harmony export */ LimitedStack: function() { return /* reexport safe */ _stack__WEBPACK_IMPORTED_MODULE_25__.d; },
8667
8694
  /* harmony export */ OptionsError: function() { return /* reexport safe */ _error__WEBPACK_IMPORTED_MODULE_13__.ZW; },
@@ -11851,6 +11878,7 @@ function extractSelectedPart(wrapper, font, jodit) {
11851
11878
  }
11852
11879
  /**
11853
11880
  * Retrieves content before after the selected area, clears it if it is empty, and inserts before after the framed selection
11881
+ * @private
11854
11882
  */
11855
11883
  function extractAndMove(wrapper, range, left) {
11856
11884
  var fragment = range.extractContents();
@@ -17284,7 +17312,17 @@ var Jodit = /** @class */ (function (_super) {
17284
17312
  configurable: true
17285
17313
  });
17286
17314
  /**
17287
- * Method wrap usual Has Object in Object helper for prevent deep object merging in options*
17315
+ * Method wrap usual object in Object helper for prevent deep object merging in options*
17316
+ * ```js
17317
+ * const editor = Jodit.make('#editor', {
17318
+ * controls: {
17319
+ * fontsize: {
17320
+ * list: Jodit.atom([8, 9, 10])
17321
+ * }
17322
+ * }
17323
+ * });
17324
+ * ```
17325
+ * In this case, the array [8, 9, 10] will not be combined with other arrays, but will replace them
17288
17326
  */
17289
17327
  Jodit.atom = function (object) {
17290
17328
  return (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.markAsAtomic)(object);
@@ -18318,13 +18356,6 @@ var Jodit = /** @class */ (function (_super) {
18318
18356
  })
18319
18357
  .on('blur', function () { return (_this.editorIsActive = false); });
18320
18358
  _this.__prepareWYSIWYGEditor();
18321
- // direction
18322
- if (_this.o.direction) {
18323
- var direction = _this.o.direction.toLowerCase() === 'rtl' ? 'rtl' : 'ltr';
18324
- _this.container.style.direction = direction;
18325
- _this.container.setAttribute('dir', direction);
18326
- _this.toolbar.setDirection(direction);
18327
- }
18328
18359
  if (_this.o.triggerChangeEvent) {
18329
18360
  _this.e.on('change', _this.async.debounce(function () {
18330
18361
  _this.e && _this.e.fire(_this.element, 'change');
@@ -18343,6 +18374,9 @@ var Jodit = /** @class */ (function (_super) {
18343
18374
  var direction = this.o.direction.toLowerCase() === 'rtl' ? 'rtl' : 'ltr';
18344
18375
  this.editor.style.direction = direction;
18345
18376
  this.editor.setAttribute('dir', direction);
18377
+ this.container.style.direction = direction;
18378
+ this.container.setAttribute('dir', direction);
18379
+ this.toolbar.setDirection(direction);
18346
18380
  }
18347
18381
  // proxy events
18348
18382
  this.e
@@ -22022,6 +22056,7 @@ var Snapshot = /** @class */ (function (_super) {
22022
22056
  function Snapshot() {
22023
22057
  var _this = _super.apply(this, (0,tslib__WEBPACK_IMPORTED_MODULE_3__/* .__spreadArray */ .fX)([], (0,tslib__WEBPACK_IMPORTED_MODULE_3__/* .__read */ .zs)(arguments), false)) || this;
22024
22058
  _this.__isBlocked = false;
22059
+ _this.__levelOfTransaction = 0;
22025
22060
  return _this;
22026
22061
  }
22027
22062
  /** @override */
@@ -22107,6 +22142,7 @@ var Snapshot = /** @class */ (function (_super) {
22107
22142
  };
22108
22143
  Snapshot.prototype.transaction = function (changes) {
22109
22144
  this.__block(true);
22145
+ this.__levelOfTransaction += 1;
22110
22146
  try {
22111
22147
  changes();
22112
22148
  }
@@ -22115,7 +22151,12 @@ var Snapshot = /** @class */ (function (_super) {
22115
22151
  throw e;
22116
22152
  }
22117
22153
  }
22118
- this.__block(false);
22154
+ finally {
22155
+ this.__levelOfTransaction -= 1;
22156
+ if (this.__levelOfTransaction === 0) {
22157
+ this.__block(false);
22158
+ }
22159
+ }
22119
22160
  };
22120
22161
  /**
22121
22162
  * Creates object a snapshot of editor: html and the current selection. Current selection calculate by
@@ -24363,17 +24404,26 @@ var ToolbarButton = /** @class */ (function (_super) {
24363
24404
  if ((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.isFunction)(ctr.popup)) {
24364
24405
  var popup = this.openPopup();
24365
24406
  popup.parentElement = this;
24366
- if (this.j.e.fire((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.camelCase)("before-".concat(ctr.name, "-open-popup")), this.target, ctr, popup) !== false) {
24367
- var target = (_c = (_b = (_a = this.toolbar) === null || _a === void 0 ? void 0 : _a.getTarget(this)) !== null && _b !== void 0 ? _b : this.target) !== null && _c !== void 0 ? _c : null;
24368
- var elm = ctr.popup(this.j, target, this.__closePopup, this);
24369
- if (elm) {
24370
- popup
24371
- .setContent((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.isString)(elm) ? this.j.c.fromHTML(elm) : elm)
24372
- .open(function () { return (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.position)(_this.container); }, false, this.j.o.allowTabNavigation
24373
- ? this.container
24374
- : undefined);
24407
+ try {
24408
+ if (this.j.e.fire((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.camelCase)("before-".concat(ctr.name, "-open-popup")), this.target, ctr, popup) !== false) {
24409
+ var target = (_c = (_b = (_a = this.toolbar) === null || _a === void 0 ? void 0 : _a.getTarget(this)) !== null && _b !== void 0 ? _b : this.target) !== null && _c !== void 0 ? _c : null;
24410
+ var elm = ctr.popup(this.j, target, this.__closePopup, this);
24411
+ if (elm) {
24412
+ popup
24413
+ .setContent((0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.isString)(elm) ? this.j.c.fromHTML(elm) : elm)
24414
+ .open(function () { return (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.position)(_this.container); }, false, this.j.o.allowTabNavigation
24415
+ ? this.container
24416
+ : undefined);
24417
+ }
24418
+ else {
24419
+ this.__closePopup();
24420
+ }
24375
24421
  }
24376
24422
  }
24423
+ catch (e) {
24424
+ this.__closePopup();
24425
+ throw e;
24426
+ }
24377
24427
  /**
24378
24428
  * Fired after the popup was opened for some control button
24379
24429
  */
@@ -26845,6 +26895,9 @@ __webpack_require__.r(__webpack_exports__);
26845
26895
  * Released under MIT see LICENSE.txt in the project root for license information.
26846
26896
  * Copyright (c) 2013-2024 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
26847
26897
  */
26898
+ /**
26899
+ * @module plugins/ai-assistant
26900
+ */
26848
26901
 
26849
26902
 
26850
26903
 
@@ -33013,7 +33066,9 @@ jodit_core_global__WEBPACK_IMPORTED_MODULE_2__/* .pluginSystem */ .fg.add('image
33013
33066
  * Copyright (c) 2013-2024 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
33014
33067
  */
33015
33068
 
33016
- /** @private */
33069
+ /**
33070
+ * @private
33071
+ */
33017
33072
  function readAlign(image, values) {
33018
33073
  // Align
33019
33074
  if (image.style.cssFloat &&
@@ -33141,6 +33196,9 @@ function readLink(state, j, values) {
33141
33196
  * Released under MIT see LICENSE.txt in the project root for license information.
33142
33197
  * Copyright (c) 2013-2024 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
33143
33198
  */
33199
+ /**
33200
+ * @module plugins/image-properties
33201
+ */
33144
33202
 
33145
33203
  /** @private */
33146
33204
  function readMargins(image, values, state) {
@@ -33186,6 +33244,9 @@ function readMargins(image, values, state) {
33186
33244
  * Copyright (c) 2013-2024 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
33187
33245
  */
33188
33246
 
33247
+ /**
33248
+ * @module plugins/image-properties
33249
+ */
33189
33250
 
33190
33251
 
33191
33252
 
@@ -33970,6 +34031,9 @@ function openImagePopup(j, dialog, state, button) {
33970
34031
  * Released under MIT see LICENSE.txt in the project root for license information.
33971
34032
  * Copyright (c) 2013-2024 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
33972
34033
  */
34034
+ /**
34035
+ * @module plugins/image-properties
34036
+ */
33973
34037
 
33974
34038
 
33975
34039
  /** @private */
@@ -34158,6 +34222,9 @@ function applyMargin(j, marginTop, marginRight, marginBottom, marginLeft, image,
34158
34222
  * Released under MIT see LICENSE.txt in the project root for license information.
34159
34223
  * Copyright (c) 2013-2024 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
34160
34224
  */
34225
+ /**
34226
+ * @module plugins/image-properties
34227
+ */
34161
34228
 
34162
34229
 
34163
34230
 
@@ -41467,6 +41534,10 @@ var AceEditor = /** @class */ (function (_super) {
41467
41534
  _this.container.appendChild(fakeMirror);
41468
41535
  var ace = editor.ow.ace;
41469
41536
  _this.instance = ace.edit(fakeMirror);
41537
+ if (editor.o.direction === 'rtl') {
41538
+ _this.instance.setOption('rtlText', true);
41539
+ _this.instance.setOption('rtl', true);
41540
+ }
41470
41541
  _this.instance.setTheme(editor.o.sourceEditorNativeOptions.theme);
41471
41542
  _this.instance.renderer.setShowGutter(editor.o.sourceEditorNativeOptions.showGutter);
41472
41543
  _this.instance
@@ -41641,7 +41712,8 @@ var TextAreaEditor = /** @class */ (function (_super) {
41641
41712
  TextAreaEditor.prototype.init = function (editor) {
41642
41713
  var _this = this;
41643
41714
  this.instance = editor.c.element('textarea', {
41644
- class: 'jodit-source__mirror'
41715
+ class: 'jodit-source__mirror',
41716
+ dir: editor.o.direction === 'rtl' ? 'rtl' : undefined
41645
41717
  });
41646
41718
  this.container.appendChild(this.instance);
41647
41719
  editor.e
@@ -43286,14 +43358,13 @@ jodit_config__WEBPACK_IMPORTED_MODULE_1__/* .Config */ .T.prototype.controls.sym
43286
43358
  editor.e.on(container, 'close_dialog', close);
43287
43359
  return box;
43288
43360
  }
43289
- else {
43290
- editor
43291
- .alert(container, 'Select Special Character', undefined, 'jodit-symbols')
43292
- .bindDestruct(editor);
43293
- var a = container.querySelector('a');
43294
- a && a.focus();
43295
- }
43361
+ editor
43362
+ .alert(container, 'Select Special Character', undefined, 'jodit-symbols')
43363
+ .bindDestruct(editor);
43364
+ var a = container.querySelector('a');
43365
+ a && a.focus();
43296
43366
  }
43367
+ return;
43297
43368
  }
43298
43369
  };
43299
43370
 
@@ -43813,25 +43884,28 @@ var symbols = /** @class */ (function (_super) {
43813
43884
  (0,tslib__WEBPACK_IMPORTED_MODULE_7__/* .__extends */ .C6)(symbols, _super);
43814
43885
  function symbols(jodit) {
43815
43886
  var _this = _super.call(this, jodit) || this;
43816
- /** @override */
43817
43887
  _this.buttons = [
43818
43888
  {
43819
43889
  name: 'symbols',
43820
43890
  group: 'insert'
43821
43891
  }
43822
43892
  ];
43823
- _this.countInRow = 17;
43893
+ _this.__countInRow = 17;
43824
43894
  (0,jodit_core_global__WEBPACK_IMPORTED_MODULE_2__/* .extendLang */ .JW)(_langs__WEBPACK_IMPORTED_MODULE_6__);
43825
43895
  return _this;
43826
43896
  }
43827
- /** @override */
43828
43897
  symbols.prototype.afterInit = function (jodit) {
43829
43898
  var _this = this;
43830
43899
  jodit.e.on('generateSpecialCharactersTable.symbols', function () {
43831
- var container = jodit.c.fromHTML("<div class=\"jodit-symbols__container\">\n\t\t\t\t\t\t<div class=\"jodit-symbols__container_table\">\n\t\t\t\t\t\t\t<table class=\"jodit-symbols__table\"><tbody></tbody></table>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t\t<div class=\"jodit-symbols__container_preview\">\n\t\t\t\t\t\t\t<div class=\"jodit-symbols__preview\"></div>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</div>"), preview = container.querySelector('.jodit-symbols__preview'), table = container.querySelector('table'), body = table.tBodies[0], chars = [];
43900
+ var container = jodit.c.fromHTML("<div class=\"jodit-symbols__container\">\n\t\t\t\t\t\t<div class=\"jodit-symbols__container_table\">\n\t\t\t\t\t\t\t<table class=\"jodit-symbols__table\"><tbody></tbody></table>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t\t<div class=\"jodit-symbols__container_preview\">\n\t\t\t\t\t\t\t<div class=\"jodit-symbols__preview\"></div>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</div>");
43901
+ var preview = container.querySelector('.jodit-symbols__preview');
43902
+ var table = container.querySelector('table');
43903
+ var body = table.tBodies[0];
43904
+ var chars = [];
43832
43905
  for (var i = 0; i < jodit.o.specialCharacters.length;) {
43833
43906
  var tr = jodit.c.element('tr');
43834
- for (var j = 0; j < _this.countInRow && i < jodit.o.specialCharacters.length; j += 1, i += 1) {
43907
+ for (var j = 0; j < _this.__countInRow &&
43908
+ i < jodit.o.specialCharacters.length; j += 1, i += 1) {
43835
43909
  var td = jodit.c.element('td'), a = jodit.c.fromHTML("<a\n\t\t\t\t\t\t\t\t\tdata-index=\"".concat(i, "\"\n\t\t\t\t\t\t\t\t\tdata-index-j=\"").concat(j, "\"\n\t\t\t\t\t\t\t\t\trole=\"option\"\n\t\t\t\t\t\t\t\t\ttabindex=\"-1\"\n\t\t\t\t\t\t\t>").concat(jodit.o.specialCharacters[i], "</a>"));
43836
43910
  chars.push(a);
43837
43911
  td.appendChild(a);
@@ -43848,7 +43922,9 @@ var symbols = /** @class */ (function (_super) {
43848
43922
  if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.isTag(this, 'a')) {
43849
43923
  jodit.s.focus();
43850
43924
  jodit.s.insertHTML(this.innerHTML);
43851
- jodit.e.fire(this, 'close_dialog');
43925
+ if (!(e === null || e === void 0 ? void 0 : e.shiftKey)) {
43926
+ jodit.e.fire(this, 'close_dialog');
43927
+ }
43852
43928
  e && e.preventDefault();
43853
43929
  e && e.stopImmediatePropagation();
43854
43930
  }
@@ -43868,18 +43944,18 @@ var symbols = /** @class */ (function (_super) {
43868
43944
  case jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_DOWN:
43869
43945
  newIndex =
43870
43946
  e.key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_UP
43871
- ? index - self.countInRow
43872
- : index + self.countInRow;
43947
+ ? index - self.__countInRow
43948
+ : index + self.__countInRow;
43873
43949
  if (chars[newIndex] === undefined) {
43874
43950
  newIndex =
43875
43951
  e.key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_UP
43876
43952
  ? Math.floor(chars.length /
43877
- self.countInRow) *
43878
- self.countInRow +
43953
+ self.__countInRow) *
43954
+ self.__countInRow +
43879
43955
  jIndex
43880
43956
  : jIndex;
43881
43957
  if (newIndex > chars.length - 1) {
43882
- newIndex -= self.countInRow;
43958
+ newIndex -= self.__countInRow;
43883
43959
  }
43884
43960
  }
43885
43961
  chars[newIndex] && chars[newIndex].focus();