jodit-pro 4.2.11 → 4.2.13

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 (301) hide show
  1. package/es2015/jodit.css +115 -115
  2. package/es2015/jodit.fat.min.css +1 -1
  3. package/es2015/jodit.fat.min.js +2 -2
  4. package/es2015/jodit.js +525 -444
  5. package/es2015/jodit.min.css +1 -1
  6. package/es2015/jodit.min.js +2 -2
  7. package/es2015/plugins/autocomplete/autocomplete.js +1 -1
  8. package/es2015/plugins/autocomplete/autocomplete.min.js +1 -1
  9. package/es2015/plugins/backup/backup.css +1 -1
  10. package/es2015/plugins/backup/backup.js +1 -1
  11. package/es2015/plugins/backup/backup.min.js +1 -1
  12. package/es2015/plugins/button-generator/button-generator.css +1 -1
  13. package/es2015/plugins/button-generator/button-generator.js +1 -1
  14. package/es2015/plugins/button-generator/button-generator.min.js +1 -1
  15. package/es2015/plugins/change-case/change-case.js +1 -1
  16. package/es2015/plugins/change-case/change-case.min.js +1 -1
  17. package/es2015/plugins/color-picker/color-picker.css +1 -1
  18. package/es2015/plugins/color-picker/color-picker.js +1 -1
  19. package/es2015/plugins/color-picker/color-picker.min.js +1 -1
  20. package/es2015/plugins/emoji/emoji.css +1 -1
  21. package/es2015/plugins/emoji/emoji.js +1 -1
  22. package/es2015/plugins/emoji/emoji.min.js +1 -1
  23. package/es2015/plugins/export-docs/export-docs.js +1 -1
  24. package/es2015/plugins/export-docs/export-docs.min.js +1 -1
  25. package/es2015/plugins/finder/finder.css +1 -1
  26. package/es2015/plugins/finder/finder.js +1 -1
  27. package/es2015/plugins/finder/finder.min.js +1 -1
  28. package/es2015/plugins/google-maps/google-maps.css +1 -1
  29. package/es2015/plugins/google-maps/google-maps.js +1 -1
  30. package/es2015/plugins/google-maps/google-maps.min.js +1 -1
  31. package/es2015/plugins/google-search/google-search.js +1 -1
  32. package/es2015/plugins/google-search/google-search.min.js +1 -1
  33. package/es2015/plugins/highlight-signature/highlight-signature.js +1 -1
  34. package/es2015/plugins/highlight-signature/highlight-signature.min.js +1 -1
  35. package/es2015/plugins/iframe-editor/iframe-editor.css +1 -1
  36. package/es2015/plugins/iframe-editor/iframe-editor.js +1 -1
  37. package/es2015/plugins/iframe-editor/iframe-editor.min.js +1 -1
  38. package/es2015/plugins/keyboard/keyboard.css +1 -1
  39. package/es2015/plugins/keyboard/keyboard.js +1 -1
  40. package/es2015/plugins/keyboard/keyboard.min.js +1 -1
  41. package/es2015/plugins/mobile-view/mobile-view.js +1 -1
  42. package/es2015/plugins/mobile-view/mobile-view.min.js +1 -1
  43. package/es2015/plugins/page-break/page-break.js +1 -1
  44. package/es2015/plugins/page-break/page-break.min.js +1 -1
  45. package/es2015/plugins/paste-code/paste-code.css +1 -1
  46. package/es2015/plugins/paste-code/paste-code.js +1 -1
  47. package/es2015/plugins/paste-code/paste-code.min.js +1 -1
  48. package/es2015/plugins/paste-from-word/paste-from-word.js +1 -1
  49. package/es2015/plugins/paste-from-word/paste-from-word.min.js +1 -1
  50. package/es2015/plugins/show-blocks/show-blocks.js +1 -1
  51. package/es2015/plugins/show-blocks/show-blocks.min.js +1 -1
  52. package/es2015/plugins/todo-list/todo-list.css +1 -1
  53. package/es2015/plugins/todo-list/todo-list.js +1 -1
  54. package/es2015/plugins/todo-list/todo-list.min.js +1 -1
  55. package/es2015/plugins/translate/translate.css +1 -1
  56. package/es2015/plugins/translate/translate.js +1 -1
  57. package/es2015/plugins/translate/translate.min.js +1 -1
  58. package/es2015/plugins/tune-block/tune-block.css +1 -1
  59. package/es2015/plugins/tune-block/tune-block.js +1 -1
  60. package/es2015/plugins/tune-block/tune-block.min.js +1 -1
  61. package/es2018/jodit.css +115 -115
  62. package/es2018/jodit.fat.min.css +1 -1
  63. package/es2018/jodit.fat.min.js +2 -2
  64. package/es2018/jodit.js +525 -444
  65. package/es2018/jodit.min.css +1 -1
  66. package/es2018/jodit.min.js +2 -2
  67. package/es2018/plugins/autocomplete/autocomplete.js +1 -1
  68. package/es2018/plugins/autocomplete/autocomplete.min.js +1 -1
  69. package/es2018/plugins/backup/backup.css +1 -1
  70. package/es2018/plugins/backup/backup.js +1 -1
  71. package/es2018/plugins/backup/backup.min.js +1 -1
  72. package/es2018/plugins/button-generator/button-generator.css +1 -1
  73. package/es2018/plugins/button-generator/button-generator.js +1 -1
  74. package/es2018/plugins/button-generator/button-generator.min.js +1 -1
  75. package/es2018/plugins/change-case/change-case.js +1 -1
  76. package/es2018/plugins/change-case/change-case.min.js +1 -1
  77. package/es2018/plugins/color-picker/color-picker.css +1 -1
  78. package/es2018/plugins/color-picker/color-picker.js +1 -1
  79. package/es2018/plugins/color-picker/color-picker.min.js +1 -1
  80. package/es2018/plugins/emoji/emoji.css +1 -1
  81. package/es2018/plugins/emoji/emoji.js +1 -1
  82. package/es2018/plugins/emoji/emoji.min.js +1 -1
  83. package/es2018/plugins/export-docs/export-docs.js +1 -1
  84. package/es2018/plugins/export-docs/export-docs.min.js +1 -1
  85. package/es2018/plugins/finder/finder.css +1 -1
  86. package/es2018/plugins/finder/finder.js +1 -1
  87. package/es2018/plugins/finder/finder.min.js +1 -1
  88. package/es2018/plugins/google-maps/google-maps.css +1 -1
  89. package/es2018/plugins/google-maps/google-maps.js +1 -1
  90. package/es2018/plugins/google-maps/google-maps.min.js +1 -1
  91. package/es2018/plugins/google-search/google-search.js +1 -1
  92. package/es2018/plugins/google-search/google-search.min.js +1 -1
  93. package/es2018/plugins/highlight-signature/highlight-signature.js +1 -1
  94. package/es2018/plugins/highlight-signature/highlight-signature.min.js +1 -1
  95. package/es2018/plugins/iframe-editor/iframe-editor.css +1 -1
  96. package/es2018/plugins/iframe-editor/iframe-editor.js +1 -1
  97. package/es2018/plugins/iframe-editor/iframe-editor.min.js +1 -1
  98. package/es2018/plugins/keyboard/keyboard.css +1 -1
  99. package/es2018/plugins/keyboard/keyboard.js +1 -1
  100. package/es2018/plugins/keyboard/keyboard.min.js +1 -1
  101. package/es2018/plugins/mobile-view/mobile-view.js +1 -1
  102. package/es2018/plugins/mobile-view/mobile-view.min.js +1 -1
  103. package/es2018/plugins/page-break/page-break.js +1 -1
  104. package/es2018/plugins/page-break/page-break.min.js +1 -1
  105. package/es2018/plugins/paste-code/paste-code.css +1 -1
  106. package/es2018/plugins/paste-code/paste-code.js +1 -1
  107. package/es2018/plugins/paste-code/paste-code.min.js +1 -1
  108. package/es2018/plugins/paste-from-word/paste-from-word.js +1 -1
  109. package/es2018/plugins/paste-from-word/paste-from-word.min.js +1 -1
  110. package/es2018/plugins/show-blocks/show-blocks.js +1 -1
  111. package/es2018/plugins/show-blocks/show-blocks.min.js +1 -1
  112. package/es2018/plugins/todo-list/todo-list.css +1 -1
  113. package/es2018/plugins/todo-list/todo-list.js +1 -1
  114. package/es2018/plugins/todo-list/todo-list.min.js +1 -1
  115. package/es2018/plugins/translate/translate.css +1 -1
  116. package/es2018/plugins/translate/translate.js +1 -1
  117. package/es2018/plugins/translate/translate.min.js +1 -1
  118. package/es2018/plugins/tune-block/tune-block.css +1 -1
  119. package/es2018/plugins/tune-block/tune-block.js +1 -1
  120. package/es2018/plugins/tune-block/tune-block.min.js +1 -1
  121. package/es2021/jodit.css +115 -115
  122. package/es2021/jodit.fat.min.css +1 -1
  123. package/es2021/jodit.fat.min.js +2 -2
  124. package/es2021/jodit.js +519 -440
  125. package/es2021/jodit.min.css +1 -1
  126. package/es2021/jodit.min.js +2 -2
  127. package/es2021/plugins/autocomplete/autocomplete.js +1 -1
  128. package/es2021/plugins/autocomplete/autocomplete.min.js +1 -1
  129. package/es2021/plugins/backup/backup.css +1 -1
  130. package/es2021/plugins/backup/backup.js +1 -1
  131. package/es2021/plugins/backup/backup.min.js +1 -1
  132. package/es2021/plugins/button-generator/button-generator.css +1 -1
  133. package/es2021/plugins/button-generator/button-generator.js +1 -1
  134. package/es2021/plugins/button-generator/button-generator.min.js +1 -1
  135. package/es2021/plugins/change-case/change-case.js +1 -1
  136. package/es2021/plugins/change-case/change-case.min.js +1 -1
  137. package/es2021/plugins/color-picker/color-picker.css +1 -1
  138. package/es2021/plugins/color-picker/color-picker.js +1 -1
  139. package/es2021/plugins/color-picker/color-picker.min.js +1 -1
  140. package/es2021/plugins/emoji/emoji.css +1 -1
  141. package/es2021/plugins/emoji/emoji.js +1 -1
  142. package/es2021/plugins/emoji/emoji.min.js +1 -1
  143. package/es2021/plugins/export-docs/export-docs.js +1 -1
  144. package/es2021/plugins/export-docs/export-docs.min.js +1 -1
  145. package/es2021/plugins/finder/finder.css +1 -1
  146. package/es2021/plugins/finder/finder.js +1 -1
  147. package/es2021/plugins/finder/finder.min.js +1 -1
  148. package/es2021/plugins/google-maps/google-maps.css +1 -1
  149. package/es2021/plugins/google-maps/google-maps.js +1 -1
  150. package/es2021/plugins/google-maps/google-maps.min.js +1 -1
  151. package/es2021/plugins/google-search/google-search.js +1 -1
  152. package/es2021/plugins/google-search/google-search.min.js +1 -1
  153. package/es2021/plugins/highlight-signature/highlight-signature.js +1 -1
  154. package/es2021/plugins/highlight-signature/highlight-signature.min.js +1 -1
  155. package/es2021/plugins/iframe-editor/iframe-editor.css +1 -1
  156. package/es2021/plugins/iframe-editor/iframe-editor.js +1 -1
  157. package/es2021/plugins/iframe-editor/iframe-editor.min.js +1 -1
  158. package/es2021/plugins/keyboard/keyboard.css +1 -1
  159. package/es2021/plugins/keyboard/keyboard.js +1 -1
  160. package/es2021/plugins/keyboard/keyboard.min.js +1 -1
  161. package/es2021/plugins/mobile-view/mobile-view.js +1 -1
  162. package/es2021/plugins/mobile-view/mobile-view.min.js +1 -1
  163. package/es2021/plugins/page-break/page-break.js +1 -1
  164. package/es2021/plugins/page-break/page-break.min.js +1 -1
  165. package/es2021/plugins/paste-code/paste-code.css +1 -1
  166. package/es2021/plugins/paste-code/paste-code.js +1 -1
  167. package/es2021/plugins/paste-code/paste-code.min.js +1 -1
  168. package/es2021/plugins/paste-from-word/paste-from-word.js +1 -1
  169. package/es2021/plugins/paste-from-word/paste-from-word.min.js +1 -1
  170. package/es2021/plugins/show-blocks/show-blocks.js +1 -1
  171. package/es2021/plugins/show-blocks/show-blocks.min.js +1 -1
  172. package/es2021/plugins/todo-list/todo-list.css +1 -1
  173. package/es2021/plugins/todo-list/todo-list.js +1 -1
  174. package/es2021/plugins/todo-list/todo-list.min.js +1 -1
  175. package/es2021/plugins/translate/translate.css +1 -1
  176. package/es2021/plugins/translate/translate.js +1 -1
  177. package/es2021/plugins/translate/translate.min.js +1 -1
  178. package/es2021/plugins/tune-block/tune-block.css +1 -1
  179. package/es2021/plugins/tune-block/tune-block.js +1 -1
  180. package/es2021/plugins/tune-block/tune-block.min.js +1 -1
  181. package/es2021.en/jodit.css +115 -115
  182. package/es2021.en/jodit.fat.min.css +1 -1
  183. package/es2021.en/jodit.fat.min.js +2 -2
  184. package/es2021.en/jodit.js +519 -440
  185. package/es2021.en/jodit.min.css +1 -1
  186. package/es2021.en/jodit.min.js +2 -2
  187. package/es2021.en/plugins/autocomplete/autocomplete.js +1 -1
  188. package/es2021.en/plugins/autocomplete/autocomplete.min.js +1 -1
  189. package/es2021.en/plugins/backup/backup.css +1 -1
  190. package/es2021.en/plugins/backup/backup.js +1 -1
  191. package/es2021.en/plugins/backup/backup.min.js +1 -1
  192. package/es2021.en/plugins/button-generator/button-generator.css +1 -1
  193. package/es2021.en/plugins/button-generator/button-generator.js +1 -1
  194. package/es2021.en/plugins/button-generator/button-generator.min.js +1 -1
  195. package/es2021.en/plugins/change-case/change-case.js +1 -1
  196. package/es2021.en/plugins/change-case/change-case.min.js +1 -1
  197. package/es2021.en/plugins/color-picker/color-picker.css +1 -1
  198. package/es2021.en/plugins/color-picker/color-picker.js +1 -1
  199. package/es2021.en/plugins/color-picker/color-picker.min.js +1 -1
  200. package/es2021.en/plugins/emoji/emoji.css +1 -1
  201. package/es2021.en/plugins/emoji/emoji.js +1 -1
  202. package/es2021.en/plugins/emoji/emoji.min.js +1 -1
  203. package/es2021.en/plugins/export-docs/export-docs.js +1 -1
  204. package/es2021.en/plugins/export-docs/export-docs.min.js +1 -1
  205. package/es2021.en/plugins/finder/finder.css +1 -1
  206. package/es2021.en/plugins/finder/finder.js +1 -1
  207. package/es2021.en/plugins/finder/finder.min.js +1 -1
  208. package/es2021.en/plugins/google-maps/google-maps.css +1 -1
  209. package/es2021.en/plugins/google-maps/google-maps.js +1 -1
  210. package/es2021.en/plugins/google-maps/google-maps.min.js +1 -1
  211. package/es2021.en/plugins/google-search/google-search.js +1 -1
  212. package/es2021.en/plugins/google-search/google-search.min.js +1 -1
  213. package/es2021.en/plugins/highlight-signature/highlight-signature.js +1 -1
  214. package/es2021.en/plugins/highlight-signature/highlight-signature.min.js +1 -1
  215. package/es2021.en/plugins/iframe-editor/iframe-editor.css +1 -1
  216. package/es2021.en/plugins/iframe-editor/iframe-editor.js +1 -1
  217. package/es2021.en/plugins/iframe-editor/iframe-editor.min.js +1 -1
  218. package/es2021.en/plugins/keyboard/keyboard.css +1 -1
  219. package/es2021.en/plugins/keyboard/keyboard.js +1 -1
  220. package/es2021.en/plugins/keyboard/keyboard.min.js +1 -1
  221. package/es2021.en/plugins/mobile-view/mobile-view.js +1 -1
  222. package/es2021.en/plugins/mobile-view/mobile-view.min.js +1 -1
  223. package/es2021.en/plugins/page-break/page-break.js +1 -1
  224. package/es2021.en/plugins/page-break/page-break.min.js +1 -1
  225. package/es2021.en/plugins/paste-code/paste-code.css +1 -1
  226. package/es2021.en/plugins/paste-code/paste-code.js +1 -1
  227. package/es2021.en/plugins/paste-code/paste-code.min.js +1 -1
  228. package/es2021.en/plugins/paste-from-word/paste-from-word.js +1 -1
  229. package/es2021.en/plugins/paste-from-word/paste-from-word.min.js +1 -1
  230. package/es2021.en/plugins/show-blocks/show-blocks.js +1 -1
  231. package/es2021.en/plugins/show-blocks/show-blocks.min.js +1 -1
  232. package/es2021.en/plugins/todo-list/todo-list.css +1 -1
  233. package/es2021.en/plugins/todo-list/todo-list.js +1 -1
  234. package/es2021.en/plugins/todo-list/todo-list.min.js +1 -1
  235. package/es2021.en/plugins/translate/translate.css +1 -1
  236. package/es2021.en/plugins/translate/translate.js +1 -1
  237. package/es2021.en/plugins/translate/translate.min.js +1 -1
  238. package/es2021.en/plugins/tune-block/tune-block.css +1 -1
  239. package/es2021.en/plugins/tune-block/tune-block.js +1 -1
  240. package/es2021.en/plugins/tune-block/tune-block.min.js +1 -1
  241. package/es5/jodit.css +129 -129
  242. package/es5/jodit.fat.min.css +1 -1
  243. package/es5/jodit.fat.min.js +2 -2
  244. package/es5/jodit.js +543 -461
  245. package/es5/jodit.min.css +3 -3
  246. package/es5/jodit.min.js +2 -2
  247. package/es5/plugins/autocomplete/autocomplete.js +1 -1
  248. package/es5/plugins/autocomplete/autocomplete.min.js +1 -1
  249. package/es5/plugins/backup/backup.css +1 -1
  250. package/es5/plugins/backup/backup.js +1 -1
  251. package/es5/plugins/backup/backup.min.js +1 -1
  252. package/es5/plugins/button-generator/button-generator.css +1 -1
  253. package/es5/plugins/button-generator/button-generator.js +1 -1
  254. package/es5/plugins/button-generator/button-generator.min.js +1 -1
  255. package/es5/plugins/change-case/change-case.js +1 -1
  256. package/es5/plugins/change-case/change-case.min.js +1 -1
  257. package/es5/plugins/color-picker/color-picker.css +1 -1
  258. package/es5/plugins/color-picker/color-picker.js +1 -1
  259. package/es5/plugins/color-picker/color-picker.min.js +1 -1
  260. package/es5/plugins/emoji/emoji.css +1 -1
  261. package/es5/plugins/emoji/emoji.js +1 -1
  262. package/es5/plugins/emoji/emoji.min.js +1 -1
  263. package/es5/plugins/export-docs/export-docs.js +1 -1
  264. package/es5/plugins/export-docs/export-docs.min.js +1 -1
  265. package/es5/plugins/finder/finder.css +1 -1
  266. package/es5/plugins/finder/finder.js +1 -1
  267. package/es5/plugins/finder/finder.min.js +1 -1
  268. package/es5/plugins/google-maps/google-maps.css +1 -1
  269. package/es5/plugins/google-maps/google-maps.js +1 -1
  270. package/es5/plugins/google-maps/google-maps.min.js +1 -1
  271. package/es5/plugins/google-search/google-search.js +1 -1
  272. package/es5/plugins/google-search/google-search.min.js +1 -1
  273. package/es5/plugins/highlight-signature/highlight-signature.js +1 -1
  274. package/es5/plugins/highlight-signature/highlight-signature.min.js +1 -1
  275. package/es5/plugins/iframe-editor/iframe-editor.css +1 -1
  276. package/es5/plugins/iframe-editor/iframe-editor.js +1 -1
  277. package/es5/plugins/iframe-editor/iframe-editor.min.js +1 -1
  278. package/es5/plugins/keyboard/keyboard.css +1 -1
  279. package/es5/plugins/keyboard/keyboard.js +1 -1
  280. package/es5/plugins/keyboard/keyboard.min.js +1 -1
  281. package/es5/plugins/mobile-view/mobile-view.js +1 -1
  282. package/es5/plugins/mobile-view/mobile-view.min.js +1 -1
  283. package/es5/plugins/page-break/page-break.js +1 -1
  284. package/es5/plugins/page-break/page-break.min.js +1 -1
  285. package/es5/plugins/paste-code/paste-code.css +1 -1
  286. package/es5/plugins/paste-code/paste-code.js +1 -1
  287. package/es5/plugins/paste-code/paste-code.min.js +1 -1
  288. package/es5/plugins/paste-from-word/paste-from-word.js +1 -1
  289. package/es5/plugins/paste-from-word/paste-from-word.min.js +1 -1
  290. package/es5/plugins/show-blocks/show-blocks.js +1 -1
  291. package/es5/plugins/show-blocks/show-blocks.min.js +1 -1
  292. package/es5/plugins/todo-list/todo-list.css +1 -1
  293. package/es5/plugins/todo-list/todo-list.js +1 -1
  294. package/es5/plugins/todo-list/todo-list.min.js +1 -1
  295. package/es5/plugins/translate/translate.css +1 -1
  296. package/es5/plugins/translate/translate.js +1 -1
  297. package/es5/plugins/translate/translate.min.js +1 -1
  298. package/es5/plugins/tune-block/tune-block.css +1 -1
  299. package/es5/plugins/tune-block/tune-block.js +1 -1
  300. package/es5/plugins/tune-block/tune-block.min.js +1 -1
  301. package/package.json +1 -1
@@ -1,7 +1,7 @@
1
1
  /*!
2
2
  * jodit-pro - PRO Version of Jodit Editor
3
3
  * Author: Chupurnov Valeriy <chupurnov@gmail.com>
4
- * Version: v4.2.11
4
+ * Version: v4.2.13
5
5
  * Url: https://xdsoft.net/jodit/pro/
6
6
  * License(s): SEE LICENSE IN LICENSE.md
7
7
  */
@@ -2304,7 +2304,7 @@ __webpack_require__.r(__webpack_exports__);
2304
2304
  * Released under MIT see LICENSE.txt in the project root for license information.
2305
2305
  * Copyright (c) 2013-2024 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
2306
2306
  */
2307
- const APP_VERSION = "4.2.11";
2307
+ const APP_VERSION = "4.2.13";
2308
2308
  // prettier-ignore
2309
2309
  const ES = "es2021";
2310
2310
  const IS_ES_MODERN = true;
@@ -10390,10 +10390,14 @@ class Response {
10390
10390
 
10391
10391
  "use strict";
10392
10392
  /* harmony export */ __webpack_require__.d(__webpack_exports__, {
10393
- /* harmony export */ W: function() { return /* reexport safe */ _move_node_inside_start__WEBPACK_IMPORTED_MODULE_0__.W; }
10393
+ /* harmony export */ Qe: function() { return /* binding */ cursorInTheEdgeOfString; },
10394
+ /* harmony export */ W8: function() { return /* reexport safe */ _move_node_inside_start__WEBPACK_IMPORTED_MODULE_2__.W; },
10395
+ /* harmony export */ dY: function() { return /* binding */ findCorrectCurrentNode; }
10394
10396
  /* harmony export */ });
10395
- /* harmony import */ var _move_node_inside_start__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(49967);
10396
- /* harmony import */ var _move_the_node_along_the_edge_outward__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(13088);
10397
+ /* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(67259);
10398
+ /* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(23545);
10399
+ /* harmony import */ var _move_node_inside_start__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(49967);
10400
+ /* harmony import */ var _move_the_node_along_the_edge_outward__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(13088);
10397
10401
  /*!
10398
10402
  * Jodit Editor (https://xdsoft.net/jodit/)
10399
10403
  * Released under MIT see LICENSE.txt in the project root for license information.
@@ -10406,6 +10410,54 @@ class Response {
10406
10410
 
10407
10411
 
10408
10412
 
10413
+ /**
10414
+ * Check if the cursor is at the edge of the string
10415
+ * @private
10416
+ */
10417
+ function cursorInTheEdgeOfString(container, offset, start, end) {
10418
+ const text = container.nodeValue?.length ? container.nodeValue : '';
10419
+ if (end && text.replace((0,jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE_REG_EXP_END)(), '').length > offset) {
10420
+ return true;
10421
+ }
10422
+ const inv = (0,jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE_REG_EXP_START)().exec(text);
10423
+ return start && ((inv && inv[0].length < offset) || (!inv && offset > 0));
10424
+ }
10425
+ function findCorrectCurrentNode(node, range, rightMode, isCollapsed, checkChild, child) {
10426
+ node = range.startContainer.childNodes[range.startOffset];
10427
+ if (!node) {
10428
+ node = range.startContainer.childNodes[range.startOffset - 1];
10429
+ rightMode = true;
10430
+ }
10431
+ if (node && isCollapsed && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.isText(node)) {
10432
+ // test Current method - Cursor in the left of some SPAN
10433
+ if (!rightMode && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.isText(node.previousSibling)) {
10434
+ node = node.previousSibling;
10435
+ }
10436
+ else if (checkChild) {
10437
+ let current = child(node);
10438
+ while (current) {
10439
+ if (current && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.isText(current)) {
10440
+ node = current;
10441
+ break;
10442
+ }
10443
+ current = child(current);
10444
+ }
10445
+ }
10446
+ }
10447
+ if (node && !isCollapsed && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.isText(node)) {
10448
+ let leftChild = node, rightChild = node;
10449
+ do {
10450
+ leftChild = leftChild.firstChild;
10451
+ rightChild = rightChild.lastChild;
10452
+ } while (leftChild && rightChild && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.isText(leftChild));
10453
+ if (leftChild === rightChild && leftChild && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.isText(leftChild)) {
10454
+ node = leftChild;
10455
+ }
10456
+ }
10457
+ return { node, rightMode };
10458
+ }
10459
+
10460
+
10409
10461
  /***/ }),
10410
10462
 
10411
10463
  /***/ 49967:
@@ -10527,7 +10579,7 @@ function moveTheNodeAlongTheEdgeOutward(node, start, root) {
10527
10579
  /* harmony export */ __webpack_require__.d(__webpack_exports__, {
10528
10580
  /* harmony export */ L: function() { return /* binding */ Selection; }
10529
10581
  /* harmony export */ });
10530
- /* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(31635);
10582
+ /* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(31635);
10531
10583
  /* harmony import */ var jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(67259);
10532
10584
  /* harmony import */ var jodit_core_decorators__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(53557);
10533
10585
  /* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(23545);
@@ -10537,6 +10589,7 @@ function moveTheNodeAlongTheEdgeOutward(node, start, root) {
10537
10589
  /* harmony import */ var jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(jodit_core_helpers_utils_assert__WEBPACK_IMPORTED_MODULE_5__);
10538
10590
  /* harmony import */ var jodit_core_selection_helpers_move_the_node_along_the_edge_outward__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(13088);
10539
10591
  /* harmony import */ var _style_commit_style__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(11232);
10592
+ /* harmony import */ var _helpers__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(92185);
10540
10593
  /*!
10541
10594
  * Jodit Editor (https://xdsoft.net/jodit/)
10542
10595
  * Released under MIT see LICENSE.txt in the project root for license information.
@@ -10553,6 +10606,7 @@ function moveTheNodeAlongTheEdgeOutward(node, start, root) {
10553
10606
 
10554
10607
 
10555
10608
 
10609
+
10556
10610
  class Selection {
10557
10611
  constructor(jodit) {
10558
10612
  this.jodit = jodit;
@@ -10935,63 +10989,35 @@ class Selection {
10935
10989
  * Returns the current element under the cursor inside editor
10936
10990
  */
10937
10991
  current(checkChild = true) {
10938
- if (this.j.getRealMode() === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.MODE_WYSIWYG) {
10939
- const sel = this.sel;
10940
- if (!sel || sel.rangeCount === 0) {
10941
- return null;
10942
- }
10943
- const range = sel.getRangeAt(0);
10944
- let node = range.startContainer, rightMode = false;
10945
- const child = (nd) => rightMode ? nd.lastChild : nd.firstChild;
10946
- if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isTag(node, 'br') && sel.isCollapsed) {
10947
- return node;
10948
- }
10949
- if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isText(node)) {
10950
- node = range.startContainer.childNodes[range.startOffset];
10951
- if (!node) {
10952
- node =
10953
- range.startContainer.childNodes[range.startOffset - 1];
10954
- rightMode = true;
10955
- }
10956
- if (node && sel.isCollapsed && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isText(node)) {
10957
- // test Current method - Cursor in the left of some SPAN
10958
- if (!rightMode && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isText(node.previousSibling)) {
10959
- node = node.previousSibling;
10960
- }
10961
- else if (checkChild) {
10962
- let current = child(node);
10963
- while (current) {
10964
- if (current && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isText(current)) {
10965
- node = current;
10966
- break;
10967
- }
10968
- current = child(current);
10969
- }
10970
- }
10971
- }
10972
- if (node && !sel.isCollapsed && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isText(node)) {
10973
- let leftChild = node, rightChild = node;
10974
- do {
10975
- leftChild = leftChild.firstChild;
10976
- rightChild = rightChild.lastChild;
10977
- } while (leftChild && rightChild && !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isText(leftChild));
10978
- if (leftChild === rightChild &&
10979
- leftChild &&
10980
- jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isText(leftChild)) {
10981
- node = leftChild;
10982
- }
10983
- }
10984
- }
10985
- // check - cursor inside editor
10986
- if (node && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isOrContains(this.area, node)) {
10987
- return node;
10988
- }
10992
+ if (this.j.getRealMode() !== jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.MODE_WYSIWYG) {
10993
+ return null;
10994
+ }
10995
+ const sel = this.sel;
10996
+ if (!sel || sel.rangeCount === 0) {
10997
+ return null;
10998
+ }
10999
+ const range = sel.getRangeAt(0);
11000
+ let node = range.startContainer;
11001
+ let rightMode = false;
11002
+ const child = (nd) => rightMode ? nd.lastChild : nd.firstChild;
11003
+ if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isTag(node, 'br') && sel.isCollapsed) {
11004
+ return node;
11005
+ }
11006
+ if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isText(node)) {
11007
+ const ret = (0,_helpers__WEBPACK_IMPORTED_MODULE_8__/* .findCorrectCurrentNode */ .dY)(node, range, rightMode, sel.isCollapsed, checkChild, child);
11008
+ node = ret.node;
11009
+ rightMode = ret.rightMode;
11010
+ }
11011
+ // check - cursor inside editor
11012
+ if (node && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isOrContains(this.area, node)) {
11013
+ return node;
10989
11014
  }
10990
11015
  return null;
10991
11016
  }
10992
11017
  /**
10993
11018
  * Insert element in editor
10994
11019
  *
11020
+ * @param node - Node for insert
10995
11021
  * @param insertCursorAfter - After insert, cursor will move after element
10996
11022
  * @param fireChange - After insert, editor fire change event. You can prevent this behavior
10997
11023
  */
@@ -11053,6 +11079,7 @@ class Selection {
11053
11079
  * Inserts in the current cursor position some HTML snippet
11054
11080
  *
11055
11081
  * @param html - HTML The text to be inserted into the document
11082
+ * @param insertCursorAfter - After insert, cursor will move after element
11056
11083
  * @example
11057
11084
  * ```javascript
11058
11085
  * parent.s.insertHTML('<img src="image.png"/>');
@@ -11096,6 +11123,7 @@ class Selection {
11096
11123
  *
11097
11124
  * @param url - URL for image, or HTMLImageElement
11098
11125
  * @param styles - If specified, it will be applied <code>$(image).css(styles)</code>
11126
+ * @param defaultWidth - If specified, it will be applied <code>css('width', defaultWidth)</code>
11099
11127
  */
11100
11128
  insertImage(url, styles = null, defaultWidth = null) {
11101
11129
  const image = (0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_4__/* .isString */ .Kg)(url) ? this.j.createInside.element('img') : url;
@@ -11150,74 +11178,81 @@ class Selection {
11150
11178
  */
11151
11179
  eachSelection(callback) {
11152
11180
  const sel = this.sel;
11153
- if (sel && sel.rangeCount) {
11154
- const range = sel.getRangeAt(0);
11155
- let root = range.commonAncestorContainer;
11156
- if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isHTMLElement(root)) {
11157
- root = root.parentElement;
11158
- }
11159
- const nodes = [], startOffset = range.startOffset, length = root.childNodes.length, elementOffset = startOffset < length ? startOffset : length - 1;
11160
- let start = range.startContainer === this.area
11161
- ? root.childNodes[elementOffset]
11162
- : range.startContainer, end = range.endContainer === this.area
11163
- ? root.childNodes[range.endOffset - 1]
11164
- : range.endContainer;
11165
- if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isText(start) &&
11166
- start === range.startContainer &&
11167
- range.startOffset === start.nodeValue?.length &&
11168
- start.nextSibling) {
11169
- start = start.nextSibling;
11170
- }
11171
- if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isText(end) &&
11172
- end === range.endContainer &&
11173
- range.endOffset === 0 &&
11174
- end.previousSibling) {
11175
- end = end.previousSibling;
11176
- }
11177
- const checkElm = (node) => {
11178
- if (node &&
11179
- node !== root &&
11180
- !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isEmptyTextNode(node) &&
11181
- !(0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_4__/* .isMarker */ .rg)(node)) {
11182
- nodes.push(node);
11183
- }
11184
- };
11185
- checkElm(start);
11186
- if (start !== end && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isOrContains(root, start, true)) {
11187
- jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.find(start, node => {
11188
- checkElm(node);
11189
- // checks parentElement as well because partial selections are not equal to entire element
11190
- return (node === end ||
11191
- (node && node.contains && node.contains(end)));
11192
- }, root, true, false);
11193
- }
11194
- const forEvery = (current) => {
11195
- if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isOrContains(this.j.editor, current, true)) {
11196
- return;
11197
- }
11198
- if (current.nodeName.match(/^(UL|OL)$/)) {
11199
- return (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.toArray)(current.childNodes).forEach(forEvery);
11181
+ if (!sel || !sel.rangeCount) {
11182
+ return;
11183
+ }
11184
+ const range = sel.getRangeAt(0);
11185
+ let root = range.commonAncestorContainer;
11186
+ if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isHTMLElement(root)) {
11187
+ root = root.parentElement;
11188
+ }
11189
+ const nodes = [];
11190
+ const startOffset = range.startOffset;
11191
+ const length = root.childNodes.length;
11192
+ const elementOffset = startOffset < length ? startOffset : length - 1;
11193
+ let start = range.startContainer === this.area
11194
+ ? root.childNodes[elementOffset]
11195
+ : range.startContainer;
11196
+ let end = range.endContainer === this.area
11197
+ ? root.childNodes[range.endOffset - 1]
11198
+ : range.endContainer;
11199
+ if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isText(start) &&
11200
+ start === range.startContainer &&
11201
+ range.startOffset === start.nodeValue?.length &&
11202
+ start.nextSibling) {
11203
+ start = start.nextSibling;
11204
+ }
11205
+ if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isText(end) &&
11206
+ end === range.endContainer &&
11207
+ range.endOffset === 0 &&
11208
+ end.previousSibling) {
11209
+ end = end.previousSibling;
11210
+ }
11211
+ const checkElm = (node) => {
11212
+ if (node &&
11213
+ node !== root &&
11214
+ !jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isEmptyTextNode(node) &&
11215
+ !(0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_4__/* .isMarker */ .rg)(node)) {
11216
+ nodes.push(node);
11217
+ }
11218
+ };
11219
+ checkElm(start);
11220
+ if (start !== end && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isOrContains(root, start, true)) {
11221
+ jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.find(start, node => {
11222
+ checkElm(node);
11223
+ // checks parentElement as well because partial selections are not equal to entire element
11224
+ return (node === end ||
11225
+ (node && node.contains && node.contains(end)));
11226
+ }, root, true, false);
11227
+ }
11228
+ const forEvery = (current) => {
11229
+ if (!jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isOrContains(this.j.editor, current, true)) {
11230
+ return;
11231
+ }
11232
+ if (current.nodeName.match(/^(UL|OL)$/)) {
11233
+ return (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.toArray)(current.childNodes).forEach(forEvery);
11234
+ }
11235
+ if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isTag(current, 'li')) {
11236
+ if (current.firstChild) {
11237
+ current = current.firstChild;
11200
11238
  }
11201
- if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isTag(current, 'li')) {
11202
- if (current.firstChild) {
11203
- current = current.firstChild;
11204
- }
11205
- else {
11206
- const currentB = this.j.createInside.text(jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE);
11207
- current.appendChild(currentB);
11208
- current = currentB;
11209
- }
11239
+ else {
11240
+ const currentB = this.j.createInside.text(jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE);
11241
+ current.appendChild(currentB);
11242
+ current = currentB;
11210
11243
  }
11211
- callback(current);
11212
- };
11213
- if (nodes.length === 0 && jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isEmptyTextNode(start)) {
11244
+ }
11245
+ callback(current);
11246
+ };
11247
+ if (nodes.length === 0) {
11248
+ if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isEmptyTextNode(start)) {
11214
11249
  nodes.push(start);
11215
11250
  }
11216
- if (nodes.length === 0 && start.firstChild) {
11251
+ if (start.firstChild) {
11217
11252
  nodes.push(start.firstChild);
11218
11253
  }
11219
- nodes.forEach(forEvery);
11220
11254
  }
11255
+ nodes.forEach(forEvery);
11221
11256
  }
11222
11257
  /**
11223
11258
  * Checks if the cursor is at the end(start) block
@@ -11244,13 +11279,7 @@ class Selection {
11244
11279
  this.j.e.fire('isInvisibleForCursor', elm) === true));
11245
11280
  // check right offset
11246
11281
  if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isText(container)) {
11247
- const text = container.nodeValue?.length ? container.nodeValue : '';
11248
- if (end && text.replace((0,jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE_REG_EXP_END)(), '').length > offset) {
11249
- return false;
11250
- }
11251
- const inv = (0,jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE_REG_EXP_START)().exec(text);
11252
- if (start &&
11253
- ((inv && inv[0].length < offset) || (!inv && offset > 0))) {
11282
+ if ((0,_helpers__WEBPACK_IMPORTED_MODULE_8__/* .cursorInTheEdgeOfString */ .Qe)(container, offset, start, end)) {
11254
11283
  return false;
11255
11284
  }
11256
11285
  }
@@ -11338,6 +11367,7 @@ class Selection {
11338
11367
  }
11339
11368
  /**
11340
11369
  * Set cursor in the node
11370
+ * @param node - Node element
11341
11371
  * @param inStart - set cursor in start of element
11342
11372
  */
11343
11373
  setCursorIn(node, inStart = false) {
@@ -11398,6 +11428,7 @@ class Selection {
11398
11428
  }
11399
11429
  /**
11400
11430
  * Select node
11431
+ * @param node - Node element
11401
11432
  * @param inward - select all inside
11402
11433
  */
11403
11434
  select(node, inward = false) {
@@ -11671,19 +11702,19 @@ class Selection {
11671
11702
  return this;
11672
11703
  }
11673
11704
  }
11674
- (0,tslib__WEBPACK_IMPORTED_MODULE_8__/* .__decorate */ .Cg)([
11705
+ (0,tslib__WEBPACK_IMPORTED_MODULE_9__/* .__decorate */ .Cg)([
11675
11706
  jodit_core_decorators__WEBPACK_IMPORTED_MODULE_1__.autobind
11676
11707
  ], Selection.prototype, "createRange", null);
11677
- (0,tslib__WEBPACK_IMPORTED_MODULE_8__/* .__decorate */ .Cg)([
11708
+ (0,tslib__WEBPACK_IMPORTED_MODULE_9__/* .__decorate */ .Cg)([
11678
11709
  jodit_core_decorators__WEBPACK_IMPORTED_MODULE_1__.autobind
11679
11710
  ], Selection.prototype, "focus", null);
11680
- (0,tslib__WEBPACK_IMPORTED_MODULE_8__/* .__decorate */ .Cg)([
11711
+ (0,tslib__WEBPACK_IMPORTED_MODULE_9__/* .__decorate */ .Cg)([
11681
11712
  jodit_core_decorators__WEBPACK_IMPORTED_MODULE_1__.autobind
11682
11713
  ], Selection.prototype, "setCursorAfter", null);
11683
- (0,tslib__WEBPACK_IMPORTED_MODULE_8__/* .__decorate */ .Cg)([
11714
+ (0,tslib__WEBPACK_IMPORTED_MODULE_9__/* .__decorate */ .Cg)([
11684
11715
  jodit_core_decorators__WEBPACK_IMPORTED_MODULE_1__.autobind
11685
11716
  ], Selection.prototype, "setCursorBefore", null);
11686
- (0,tslib__WEBPACK_IMPORTED_MODULE_8__/* .__decorate */ .Cg)([
11717
+ (0,tslib__WEBPACK_IMPORTED_MODULE_9__/* .__decorate */ .Cg)([
11687
11718
  jodit_core_decorators__WEBPACK_IMPORTED_MODULE_1__.autobind
11688
11719
  ], Selection.prototype, "setCursorIn", null);
11689
11720
 
@@ -16701,17 +16732,17 @@ View.defaultOptions = {
16701
16732
 
16702
16733
  "use strict";
16703
16734
  /* harmony export */ __webpack_require__.d(__webpack_exports__, {
16704
- /* harmony export */ x: function() { return /* reexport safe */ _jodit__WEBPACK_IMPORTED_MODULE_6__.x; }
16735
+ /* harmony export */ x: function() { return /* reexport safe */ _jodit__WEBPACK_IMPORTED_MODULE_0__.x; }
16705
16736
  /* harmony export */ });
16706
16737
  /* unused harmony export CommitMode */
16707
- /* harmony import */ var jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(58588);
16708
- /* harmony import */ var jodit_plugins_index__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(22743);
16738
+ /* harmony import */ var _jodit__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(90268);
16739
+ /* harmony import */ var jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(58588);
16709
16740
  /* harmony import */ var _core_constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(67259);
16710
16741
  /* harmony import */ var _core_decorators__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(53557);
16711
16742
  /* harmony import */ var _modules___WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(35102);
16712
16743
  /* harmony import */ var _styles_icons___WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(97186);
16713
- /* harmony import */ var _jodit__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(90268);
16714
- /* harmony import */ var _languages__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(459);
16744
+ /* harmony import */ var _languages__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(459);
16745
+ /* harmony import */ var jodit_plugins_index__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(22743);
16715
16746
  /*!
16716
16747
  * Jodit Editor (https://xdsoft.net/jodit/)
16717
16748
  * Released under MIT see LICENSE.txt in the project root for license information.
@@ -16722,6 +16753,7 @@ View.defaultOptions = {
16722
16753
  * @packageDocumentation
16723
16754
  * @module jodit
16724
16755
  */
16756
+ // eslint-disable-next-line simple-import-sort/imports
16725
16757
 
16726
16758
 
16727
16759
 
@@ -16734,7 +16766,7 @@ View.defaultOptions = {
16734
16766
 
16735
16767
  // copy constants in Jodit
16736
16768
  Object.keys(_core_constants__WEBPACK_IMPORTED_MODULE_2__).forEach((key) => {
16737
- _jodit__WEBPACK_IMPORTED_MODULE_6__/* .Jodit */ .x[key] = _core_constants__WEBPACK_IMPORTED_MODULE_2__[key];
16769
+ _jodit__WEBPACK_IMPORTED_MODULE_0__/* .Jodit */ .x[key] = _core_constants__WEBPACK_IMPORTED_MODULE_2__[key];
16738
16770
  });
16739
16771
  const esFilter = (key) => key !== '__esModule';
16740
16772
  // Icons
@@ -16749,32 +16781,32 @@ Object.keys(_modules___WEBPACK_IMPORTED_MODULE_4__)
16749
16781
  .forEach((key) => {
16750
16782
  // @ts-ignore
16751
16783
  const module = _modules___WEBPACK_IMPORTED_MODULE_4__[key];
16752
- const name = (0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_0__/* .isFunction */ .Tn)(module.prototype?.className)
16784
+ const name = (0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_1__/* .isFunction */ .Tn)(module.prototype?.className)
16753
16785
  ? module.prototype.className()
16754
16786
  : key;
16755
- if (!(0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_0__/* .isString */ .Kg)(name)) {
16787
+ if (!(0,jodit_core_helpers_checker__WEBPACK_IMPORTED_MODULE_1__/* .isString */ .Kg)(name)) {
16756
16788
  console.warn('Module name must be a string', key);
16757
16789
  return;
16758
16790
  }
16759
16791
  // @ts-ignore
16760
- _jodit__WEBPACK_IMPORTED_MODULE_6__/* .Jodit */ .x.modules[name] = module;
16792
+ _jodit__WEBPACK_IMPORTED_MODULE_0__/* .Jodit */ .x.modules[name] = module;
16761
16793
  });
16762
16794
  // Decorators
16763
16795
  Object.keys(_core_decorators__WEBPACK_IMPORTED_MODULE_3__)
16764
16796
  .filter(esFilter)
16765
16797
  .forEach((key) => {
16766
16798
  // @ts-ignore
16767
- _jodit__WEBPACK_IMPORTED_MODULE_6__/* .Jodit */ .x.decorators[key] = _core_decorators__WEBPACK_IMPORTED_MODULE_3__[key];
16799
+ _jodit__WEBPACK_IMPORTED_MODULE_0__/* .Jodit */ .x.decorators[key] = _core_decorators__WEBPACK_IMPORTED_MODULE_3__[key];
16768
16800
  });
16769
16801
  ['Confirm', 'Alert', 'Prompt'].forEach((key) => {
16770
16802
  // @ts-ignore
16771
- _jodit__WEBPACK_IMPORTED_MODULE_6__/* .Jodit */ .x[key] = _modules___WEBPACK_IMPORTED_MODULE_4__[key];
16803
+ _jodit__WEBPACK_IMPORTED_MODULE_0__/* .Jodit */ .x[key] = _modules___WEBPACK_IMPORTED_MODULE_4__[key];
16772
16804
  });
16773
16805
  // Languages
16774
- Object.keys(_languages__WEBPACK_IMPORTED_MODULE_7__/* ["default"] */ .A)
16806
+ Object.keys(_languages__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A)
16775
16807
  .filter(esFilter)
16776
16808
  .forEach((key) => {
16777
- _jodit__WEBPACK_IMPORTED_MODULE_6__/* .Jodit */ .x.lang[key] = _languages__WEBPACK_IMPORTED_MODULE_7__/* ["default"] */ .A[key];
16809
+ _jodit__WEBPACK_IMPORTED_MODULE_0__/* .Jodit */ .x.lang[key] = _languages__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A[key];
16778
16810
  });
16779
16811
 
16780
16812
  class CommitMode {
@@ -22931,6 +22963,7 @@ class Table extends jodit_core_component__WEBPACK_IMPORTED_MODULE_0__/* .ViewCom
22931
22963
  }
22932
22964
  /**
22933
22965
  * Generate formal table martix columns*rows
22966
+ * @param table - Working table
22934
22967
  * @param callback - if return false cycle break
22935
22968
  */
22936
22969
  formalMatrix(table, callback) {
@@ -22999,7 +23032,6 @@ class Table extends jodit_core_component__WEBPACK_IMPORTED_MODULE_0__/* .ViewCom
22999
23032
  * @param line - Insert a new line after/before this
23000
23033
  * line contains the selected cell
23001
23034
  * @param after - Insert a new line after line contains the selected cell
23002
- * @param create - Instance of Create class
23003
23035
  */
23004
23036
  appendRow(table, line, after) {
23005
23037
  return Table.__appendRow(table, line, after, this.j.createInside);
@@ -23168,13 +23200,36 @@ class Table extends jodit_core_component__WEBPACK_IMPORTED_MODULE_0__/* .ViewCom
23168
23200
  return Table.__getSelectedBound(table, selectedCells);
23169
23201
  }
23170
23202
  static __normalizeTable(table) {
23171
- let i, j, min, not;
23172
23203
  const __marked = [], box = Table.__formalMatrix(table);
23173
- // remove extra colspans
23174
- for (j = 0; j < box[0].length; j += 1) {
23175
- min = 1000000;
23176
- not = false;
23177
- for (i = 0; i < box.length; i += 1) {
23204
+ Table.__removeExtraColspans(box, __marked);
23205
+ Table.__removeExtraRowspans(box, __marked);
23206
+ // remove rowspans and colspans equal 1 and empty class
23207
+ for (let i = 0; i < box.length; i += 1) {
23208
+ for (let j = 0; j < box[i].length; j += 1) {
23209
+ if (box[i][j] === undefined) {
23210
+ continue; // broken table
23211
+ }
23212
+ if (box[i][j].hasAttribute('rowspan') &&
23213
+ box[i][j].rowSpan === 1) {
23214
+ (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_5__.attr)(box[i][j], 'rowspan', null);
23215
+ }
23216
+ if (box[i][j].hasAttribute('colspan') &&
23217
+ box[i][j].colSpan === 1) {
23218
+ (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_5__.attr)(box[i][j], 'colspan', null);
23219
+ }
23220
+ if (box[i][j].hasAttribute('class') &&
23221
+ !(0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_5__.attr)(box[i][j], 'class')) {
23222
+ (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_5__.attr)(box[i][j], 'class', null);
23223
+ }
23224
+ }
23225
+ }
23226
+ Table.__unmark(__marked);
23227
+ }
23228
+ static __removeExtraColspans(box, __marked) {
23229
+ for (let j = 0; j < box[0].length; j += 1) {
23230
+ let min = 1000000;
23231
+ let not = false;
23232
+ for (let i = 0; i < box.length; i += 1) {
23178
23233
  if (box[i][j] === undefined) {
23179
23234
  continue; // broken table
23180
23235
  }
@@ -23185,7 +23240,7 @@ class Table extends jodit_core_component__WEBPACK_IMPORTED_MODULE_0__/* .ViewCom
23185
23240
  min = Math.min(min, box[i][j].colSpan);
23186
23241
  }
23187
23242
  if (!not) {
23188
- for (i = 0; i < box.length; i += 1) {
23243
+ for (let i = 0; i < box.length; i += 1) {
23189
23244
  if (box[i][j] === undefined) {
23190
23245
  continue; // broken table
23191
23246
  }
@@ -23193,10 +23248,13 @@ class Table extends jodit_core_component__WEBPACK_IMPORTED_MODULE_0__/* .ViewCom
23193
23248
  }
23194
23249
  }
23195
23250
  }
23196
- // remove extra rowspans
23251
+ }
23252
+ static __removeExtraRowspans(box, marked) {
23253
+ let i = 0;
23254
+ let j = 0;
23197
23255
  for (i = 0; i < box.length; i += 1) {
23198
- min = 1000000;
23199
- not = false;
23256
+ let min = 1000000;
23257
+ let not = false;
23200
23258
  for (j = 0; j < box[i].length; j += 1) {
23201
23259
  if (box[i][j] === undefined) {
23202
23260
  continue; // broken table
@@ -23212,31 +23270,10 @@ class Table extends jodit_core_component__WEBPACK_IMPORTED_MODULE_0__/* .ViewCom
23212
23270
  if (box[i][j] === undefined) {
23213
23271
  continue; // broken table
23214
23272
  }
23215
- Table.__mark(box[i][j], 'rowspan', box[i][j].rowSpan - min + 1, __marked);
23273
+ Table.__mark(box[i][j], 'rowspan', box[i][j].rowSpan - min + 1, marked);
23216
23274
  }
23217
23275
  }
23218
23276
  }
23219
- // remove rowspans and colspans equal 1 and empty class
23220
- for (i = 0; i < box.length; i += 1) {
23221
- for (j = 0; j < box[i].length; j += 1) {
23222
- if (box[i][j] === undefined) {
23223
- continue; // broken table
23224
- }
23225
- if (box[i][j].hasAttribute('rowspan') &&
23226
- box[i][j].rowSpan === 1) {
23227
- (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_5__.attr)(box[i][j], 'rowspan', null);
23228
- }
23229
- if (box[i][j].hasAttribute('colspan') &&
23230
- box[i][j].colSpan === 1) {
23231
- (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_5__.attr)(box[i][j], 'colspan', null);
23232
- }
23233
- if (box[i][j].hasAttribute('class') &&
23234
- !(0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_5__.attr)(box[i][j], 'class')) {
23235
- (0,jodit_core_helpers___WEBPACK_IMPORTED_MODULE_5__.attr)(box[i][j], 'class', null);
23236
- }
23237
- }
23238
- }
23239
- Table.__unmark(__marked);
23240
23277
  }
23241
23278
  /**
23242
23279
  * Try recalculate all coluns and rows after change
@@ -24654,34 +24691,7 @@ function sendFiles(uploader, files, handlerSuccess, handlerError, process) {
24654
24691
  }
24655
24692
  const promises = [];
24656
24693
  if (o.insertImageAsBase64URI) {
24657
- let file, i;
24658
- for (i = 0; i < fileList.length; i += 1) {
24659
- file = fileList[i];
24660
- if (file && file.type) {
24661
- const mime = file.type.match(/\/([a-z0-9]+)/i);
24662
- const extension = mime[1] ? mime[1].toLowerCase() : '';
24663
- if (o.imagesExtensions.includes(extension)) {
24664
- const reader = new FileReader();
24665
- promises.push(uploader.j.async.promise((resolve, reject) => {
24666
- reader.onerror = reject;
24667
- reader.onloadend = () => {
24668
- const resp = {
24669
- baseurl: '',
24670
- files: [reader.result],
24671
- isImages: [true]
24672
- };
24673
- const handler = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_0__.isFunction)(handlerSuccess)
24674
- ? handlerSuccess
24675
- : o.defaultHandlerSuccess;
24676
- handler.call(uploader, resp);
24677
- resolve(resp);
24678
- };
24679
- reader.readAsDataURL(file);
24680
- }));
24681
- fileList[i] = null;
24682
- }
24683
- }
24684
- }
24694
+ readImagesWithReader(fileList, o.imagesExtensions, promises, uploader, handlerSuccess, o.defaultHandlerSuccess);
24685
24695
  }
24686
24696
  fileList = fileList.filter(a => a);
24687
24697
  if (fileList.length) {
@@ -24692,7 +24702,7 @@ function sendFiles(uploader, files, handlerSuccess, handlerError, process) {
24692
24702
  for (let i = 0; i < fileList.length; i += 1) {
24693
24703
  file = fileList[i];
24694
24704
  if (file) {
24695
- const hasRealExtension = /\.[\d\w]+$/.test(file.name);
24705
+ const hasRealExtension = /\.\w+$/.test(file.name);
24696
24706
  const mime = file.type.match(/\/([a-z0-9]+)/i);
24697
24707
  const extension = mime && mime[1] ? mime[1].toLowerCase() : '';
24698
24708
  let newName = fileList[i].name ||
@@ -24741,6 +24751,37 @@ function sendFiles(uploader, files, handlerSuccess, handlerError, process) {
24741
24751
  }
24742
24752
  return Promise.all(promises);
24743
24753
  }
24754
+ function readImagesWithReader(fileList, imagesExtensions, promises, uploader, handlerSuccess, defaultHandlerSuccess) {
24755
+ let file, i;
24756
+ for (i = 0; i < fileList.length; i += 1) {
24757
+ file = fileList[i];
24758
+ if (file && file.type) {
24759
+ const mime = file.type.match(/\/([a-z0-9]+)/i);
24760
+ const extension = mime[1] ? mime[1].toLowerCase() : '';
24761
+ if (!imagesExtensions.includes(extension)) {
24762
+ continue;
24763
+ }
24764
+ const reader = new FileReader();
24765
+ promises.push(uploader.j.async.promise((resolve, reject) => {
24766
+ reader.onerror = reject;
24767
+ reader.onloadend = () => {
24768
+ const resp = {
24769
+ baseurl: '',
24770
+ files: [reader.result],
24771
+ isImages: [true]
24772
+ };
24773
+ const handler = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_0__.isFunction)(handlerSuccess)
24774
+ ? handlerSuccess
24775
+ : defaultHandlerSuccess;
24776
+ handler.call(uploader, resp);
24777
+ resolve(resp);
24778
+ };
24779
+ reader.readAsDataURL(file);
24780
+ }));
24781
+ fileList[i] = null;
24782
+ }
24783
+ }
24784
+ }
24744
24785
 
24745
24786
 
24746
24787
  /***/ }),
@@ -26306,7 +26347,7 @@ class backspace extends jodit_core_plugin__WEBPACK_IMPORTED_MODULE_3__/* .Plugin
26306
26347
  if (jodit.e.fire('backSpaceBeforeCases', backspace, fakeNode)) {
26307
26348
  return false;
26308
26349
  }
26309
- (0,jodit_core_selection_helpers__WEBPACK_IMPORTED_MODULE_4__/* .moveNodeInsideStart */ .W)(jodit, fakeNode, backspace);
26350
+ (0,jodit_core_selection_helpers__WEBPACK_IMPORTED_MODULE_4__/* .moveNodeInsideStart */ .W8)(jodit, fakeNode, backspace);
26310
26351
  if (_cases__WEBPACK_IMPORTED_MODULE_6__/* .cases */ .C.some((func) => {
26311
26352
  if ((0,jodit_core_helpers_checker_is_function__WEBPACK_IMPORTED_MODULE_8__/* .isFunction */ .T)(func) &&
26312
26353
  func(jodit, fakeNode, backspace, mode)) {
@@ -26566,19 +26607,12 @@ function checkNotCollapsed(jodit) {
26566
26607
  function checkRemoveChar(jodit, fakeNode, backspace, mode) {
26567
26608
  const step = backspace ? -1 : 1;
26568
26609
  const anotherSibling = jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.sibling(fakeNode, !backspace);
26569
- let sibling = jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.sibling(fakeNode, backspace), removeNeighbor = null;
26570
- let charRemoved = false, removed;
26571
- const getNextInlineSibling = (sibling) => {
26572
- let nextSibling = jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.sibling(sibling, backspace);
26573
- if (!nextSibling &&
26574
- sibling.parentNode &&
26575
- sibling.parentNode !== jodit.editor) {
26576
- nextSibling = (0,jodit_plugins_backspace_helpers__WEBPACK_IMPORTED_MODULE_3__/* .findMostNestedNeighbor */ .s)(sibling, !backspace, jodit.editor, true);
26577
- }
26578
- return nextSibling;
26579
- };
26610
+ let sibling = jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.sibling(fakeNode, backspace);
26611
+ let removeNeighbor = null;
26612
+ let charRemoved = false;
26613
+ let removed;
26580
26614
  if (!sibling) {
26581
- sibling = getNextInlineSibling(fakeNode);
26615
+ sibling = getNextInlineSibling(fakeNode, backspace, jodit.editor);
26582
26616
  }
26583
26617
  while (sibling && (jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.isText(sibling) || jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.isInlineBlock(sibling))) {
26584
26618
  while (jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.isInlineBlock(sibling)) {
@@ -26588,57 +26622,17 @@ function checkRemoveChar(jodit, fakeNode, backspace, mode) {
26588
26622
  break;
26589
26623
  }
26590
26624
  if (sibling.nodeValue?.length) {
26591
- // For Unicode escapes
26592
- let value = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_2__.toArray)(sibling.nodeValue);
26593
- const length = value.length;
26594
- let index = backspace ? length - 1 : 0;
26595
- if (value[index] === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE) {
26596
- while (value[index] === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE) {
26597
- index += step;
26598
- }
26599
- }
26600
- removed = value[index];
26601
- if (value[index + step] === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE) {
26602
- index += step;
26603
- while (value[index] === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE) {
26604
- index += step;
26605
- }
26606
- index += backspace ? 1 : -1;
26607
- }
26608
- if (backspace && index < 0) {
26609
- value = [];
26610
- }
26611
- else {
26612
- value = value.slice(backspace ? 0 : index + 1, backspace ? index : length);
26613
- }
26614
- if (!anotherSibling ||
26615
- !jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.isText(anotherSibling) ||
26616
- (!backspace ? / $/ : /^ /).test(anotherSibling.nodeValue ?? '') ||
26617
- !(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_2__.trimInv)(anotherSibling.nodeValue || '').length) {
26618
- for (let i = backspace ? value.length - 1 : 0; backspace ? i >= 0 : i < value.length; i += backspace ? -1 : 1) {
26619
- if (value[i] === ' ') {
26620
- value[i] = jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.NBSP_SPACE;
26621
- }
26622
- else {
26623
- break;
26624
- }
26625
- }
26626
- }
26627
- sibling.nodeValue = value.join('');
26625
+ removed = tryRemoveChar(sibling, backspace, step, anotherSibling);
26628
26626
  }
26629
26627
  if (!sibling.nodeValue?.length) {
26630
26628
  removeNeighbor = sibling;
26631
26629
  }
26632
26630
  if (!(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_2__.isVoid)(removed) && removed !== jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE) {
26631
+ checkRepeatRemoveCharAction(backspace, sibling, fakeNode, mode, removed, jodit);
26633
26632
  charRemoved = true;
26634
- (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_2__.call)(backspace ? jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.after : jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.before, sibling, fakeNode);
26635
- if (mode === 'sentence' ||
26636
- (mode === 'word' && removed !== ' ' && removed !== jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.NBSP_SPACE)) {
26637
- checkRemoveChar(jodit, fakeNode, backspace, mode);
26638
- }
26639
26633
  break;
26640
26634
  }
26641
- const nextSibling = getNextInlineSibling(sibling);
26635
+ const nextSibling = getNextInlineSibling(sibling, backspace, jodit.editor);
26642
26636
  if (removeNeighbor) {
26643
26637
  jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.safeRemove(removeNeighbor);
26644
26638
  removeNeighbor = null;
@@ -26660,6 +26654,13 @@ function checkRemoveChar(jodit, fakeNode, backspace, mode) {
26660
26654
  }
26661
26655
  return charRemoved;
26662
26656
  }
26657
+ function getNextInlineSibling(sibling, backspace, root) {
26658
+ let nextSibling = jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.sibling(sibling, backspace);
26659
+ if (!nextSibling && sibling.parentNode && sibling.parentNode !== root) {
26660
+ nextSibling = (0,jodit_plugins_backspace_helpers__WEBPACK_IMPORTED_MODULE_3__/* .findMostNestedNeighbor */ .s)(sibling, !backspace, root, true);
26661
+ }
26662
+ return nextSibling;
26663
+ }
26663
26664
  /**
26664
26665
  * Helper removes all empty inline parents
26665
26666
  */
@@ -26684,6 +26685,56 @@ function addBRInsideEmptyBlock(jodit, node) {
26684
26685
  jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.after(node, jodit.createInside.element('br'));
26685
26686
  }
26686
26687
  }
26688
+ function tryRemoveChar(sibling, backspace, step, anotherSibling) {
26689
+ // For Unicode escapes
26690
+ let value = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_2__.toArray)(sibling.nodeValue);
26691
+ const length = value.length;
26692
+ let index = backspace ? length - 1 : 0;
26693
+ if (value[index] === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE) {
26694
+ while (value[index] === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE) {
26695
+ index += step;
26696
+ }
26697
+ }
26698
+ const removed = value[index];
26699
+ if (value[index + step] === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE) {
26700
+ index += step;
26701
+ while (value[index] === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE) {
26702
+ index += step;
26703
+ }
26704
+ index += backspace ? 1 : -1;
26705
+ }
26706
+ if (backspace && index < 0) {
26707
+ value = [];
26708
+ }
26709
+ else {
26710
+ value = value.slice(backspace ? 0 : index + 1, backspace ? index : length);
26711
+ }
26712
+ replaceSpaceOnNBSP(anotherSibling, backspace, value);
26713
+ sibling.nodeValue = value.join('');
26714
+ return removed;
26715
+ }
26716
+ function replaceSpaceOnNBSP(anotherSibling, backspace, value) {
26717
+ if (!anotherSibling ||
26718
+ !jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.isText(anotherSibling) ||
26719
+ (!backspace ? / $/ : /^ /).test(anotherSibling.nodeValue ?? '') ||
26720
+ !(0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_2__.trimInv)(anotherSibling.nodeValue || '').length) {
26721
+ for (let i = backspace ? value.length - 1 : 0; backspace ? i >= 0 : i < value.length; i += backspace ? -1 : 1) {
26722
+ if (value[i] === ' ') {
26723
+ value[i] = jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.NBSP_SPACE;
26724
+ }
26725
+ else {
26726
+ break;
26727
+ }
26728
+ }
26729
+ }
26730
+ }
26731
+ function checkRepeatRemoveCharAction(backspace, sibling, fakeNode, mode, removed, jodit) {
26732
+ (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_2__.call)(backspace ? jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.after : jodit_core_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.before, sibling, fakeNode);
26733
+ if (mode === 'sentence' ||
26734
+ (mode === 'word' && removed !== ' ' && removed !== jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.NBSP_SPACE)) {
26735
+ checkRemoveChar(jodit, fakeNode, backspace, mode);
26736
+ }
26737
+ }
26687
26738
 
26688
26739
 
26689
26740
  /***/ }),
@@ -26721,7 +26772,7 @@ function checkRemoveContentNotEditable(jodit, fakeNode, backspace) {
26721
26772
  !jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__/* .Dom */ .J.isContentEditable(neighbor, jodit.editor)) {
26722
26773
  (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__.call)(backspace ? jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__/* .Dom */ .J.before : jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__/* .Dom */ .J.after, neighbor, fakeNode);
26723
26774
  jodit_core_dom__WEBPACK_IMPORTED_MODULE_0__/* .Dom */ .J.safeRemove(neighbor);
26724
- (0,jodit_core_selection_helpers__WEBPACK_IMPORTED_MODULE_2__/* .moveNodeInsideStart */ .W)(jodit, fakeNode, backspace);
26775
+ (0,jodit_core_selection_helpers__WEBPACK_IMPORTED_MODULE_2__/* .moveNodeInsideStart */ .W8)(jodit, fakeNode, backspace);
26725
26776
  (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_1__.call)(backspace ? jodit.s.setCursorBefore : jodit.s.setCursorAfter, fakeNode);
26726
26777
  return true;
26727
26778
  }
@@ -29180,45 +29231,11 @@ class dragAndDrop extends jodit_core_plugin__WEBPACK_IMPORTED_MODULE_5__/* .Plug
29180
29231
  const sel = this.j.s.sel;
29181
29232
  const range = this.bufferRange ||
29182
29233
  (sel && sel.rangeCount ? sel.getRangeAt(0) : null);
29183
- let fragment = null;
29184
- if (!this.draggable && range) {
29185
- fragment = this.isCopyMode
29186
- ? range.cloneContents()
29187
- : range.extractContents();
29188
- }
29189
- else if (this.draggable) {
29190
- if (this.isCopyMode) {
29191
- const [tagName, field] = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.attr)(this.draggable, '-is-file') === '1'
29192
- ? ['a', 'href']
29193
- : ['img', 'src'];
29194
- fragment = this.j.createInside.element(tagName);
29195
- fragment.setAttribute(field, (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.attr)(this.draggable, 'data-src') ||
29196
- (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.attr)(this.draggable, 'src') ||
29197
- '');
29198
- if (tagName === 'a') {
29199
- fragment.textContent = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.attr)(fragment, field) || '';
29200
- }
29201
- }
29202
- else {
29203
- fragment = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.dataBind)(this.draggable, 'target');
29204
- }
29205
- }
29206
- else if (this.getText(event)) {
29207
- fragment = this.j.createInside.fromHTML(this.getText(event));
29208
- }
29234
+ const fragment = this.__getWorkFragment(range, event);
29209
29235
  sel && sel.removeAllRanges();
29210
29236
  this.j.s.insertCursorAtPoint(event.clientX, event.clientY);
29211
29237
  if (fragment) {
29212
- this.j.s.insertNode(fragment, false, false);
29213
- if (range && fragment.firstChild && fragment.lastChild) {
29214
- range.setStartBefore(fragment.firstChild);
29215
- range.setEndAfter(fragment.lastChild);
29216
- this.j.s.selectRange(range);
29217
- this.j.e.fire('synchro');
29218
- }
29219
- if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isTag(fragment, 'img') && this.j.events) {
29220
- this.j.e.fire('afterInsertImage', fragment);
29221
- }
29238
+ this.__insertFragment.call(this, fragment, range);
29222
29239
  }
29223
29240
  event.preventDefault();
29224
29241
  event.stopPropagation();
@@ -29226,6 +29243,47 @@ class dragAndDrop extends jodit_core_plugin__WEBPACK_IMPORTED_MODULE_5__/* .Plug
29226
29243
  this.isFragmentFromEditor = false;
29227
29244
  this.removeDragListeners();
29228
29245
  }
29246
+ __getWorkFragment(range, event) {
29247
+ let fragment = null;
29248
+ if (!this.draggable && range) {
29249
+ fragment = this.isCopyMode
29250
+ ? range.cloneContents()
29251
+ : range.extractContents();
29252
+ }
29253
+ else if (this.draggable) {
29254
+ if (this.isCopyMode) {
29255
+ const [tagName, field] = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.attr)(this.draggable, '-is-file') === '1'
29256
+ ? ['a', 'href']
29257
+ : ['img', 'src'];
29258
+ fragment = this.j.createInside.element(tagName);
29259
+ fragment.setAttribute(field, (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.attr)(this.draggable, 'data-src') ||
29260
+ (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.attr)(this.draggable, 'src') ||
29261
+ '');
29262
+ if (tagName === 'a') {
29263
+ fragment.textContent = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.attr)(fragment, field) || '';
29264
+ }
29265
+ }
29266
+ else {
29267
+ fragment = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_4__.dataBind)(this.draggable, 'target');
29268
+ }
29269
+ }
29270
+ else if (this.getText(event)) {
29271
+ fragment = this.j.createInside.fromHTML(this.getText(event));
29272
+ }
29273
+ return fragment;
29274
+ }
29275
+ __insertFragment(fragment, range) {
29276
+ this.j.s.insertNode(fragment, false, false);
29277
+ if (range && fragment.firstChild && fragment.lastChild) {
29278
+ range.setStartBefore(fragment.firstChild);
29279
+ range.setEndAfter(fragment.lastChild);
29280
+ this.j.s.selectRange(range);
29281
+ this.j.e.fire('synchro');
29282
+ }
29283
+ if (jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_2__/* .Dom */ .J.isTag(fragment, 'img') && this.j.events) {
29284
+ this.j.e.fire('afterInsertImage', fragment);
29285
+ }
29286
+ }
29229
29287
  /** @override */
29230
29288
  beforeDestruct() {
29231
29289
  this.onDragEnd();
@@ -34539,35 +34597,7 @@ class link extends jodit_core_plugin__WEBPACK_IMPORTED_MODULE_4__/* .Plugin */ .
34539
34597
  if (link) {
34540
34598
  url_input.value = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.attr)(link, 'href') || '';
34541
34599
  if (modeClassName) {
34542
- switch (modeClassName) {
34543
- case 'input':
34544
- if (className_input) {
34545
- className_input.value = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.attr)(link, 'class') || '';
34546
- }
34547
- break;
34548
- case 'select':
34549
- if (className_select) {
34550
- for (let i = 0; i < className_select.selectedOptions.length; i++) {
34551
- const option = className_select.options.item(i);
34552
- if (option) {
34553
- option.selected = false;
34554
- }
34555
- }
34556
- const classNames = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.attr)(link, 'class') || '';
34557
- classNames.split(' ').forEach(className => {
34558
- if (className) {
34559
- for (let i = 0; i < className_select.options.length; i++) {
34560
- const option = className_select.options.item(i);
34561
- if (option?.value &&
34562
- option.value === className) {
34563
- option.selected = true;
34564
- }
34565
- }
34566
- }
34567
- });
34568
- }
34569
- break;
34570
- }
34600
+ readClassnames(modeClassName, className_input, link, className_select);
34571
34601
  }
34572
34602
  if (openInNewTabCheckbox && target_checkbox) {
34573
34603
  target_checkbox.checked = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.attr)(link, 'target') === '_blank';
@@ -34629,42 +34659,9 @@ class link extends jodit_core_plugin__WEBPACK_IMPORTED_MODULE_4__/* .Plugin */ .
34629
34659
  }
34630
34660
  links.forEach(a => {
34631
34661
  (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.attr)(a, 'href', url_input.value);
34632
- if (modeClassName && (className_input ?? className_select)) {
34633
- if (modeClassName === 'input') {
34634
- if (className_input.value === '' &&
34635
- a.hasAttribute('class')) {
34636
- (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.attr)(a, 'class', null);
34637
- }
34638
- if (className_input.value !== '') {
34639
- (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.attr)(a, 'class', className_input.value);
34640
- }
34641
- }
34642
- else if (modeClassName === 'select') {
34643
- if (a.hasAttribute('class')) {
34644
- (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.attr)(a, 'class', null);
34645
- }
34646
- for (let i = 0; i < className_select.selectedOptions.length; i++) {
34647
- const className = className_select.selectedOptions.item(i)?.value;
34648
- if (className) {
34649
- a.classList.add(className);
34650
- }
34651
- }
34652
- }
34653
- }
34662
+ writeClasses(modeClassName, className_input, className_select, a);
34654
34663
  if (!isImageContent) {
34655
- let newContent = a.textContent;
34656
- if (content_input.value.trim().length) {
34657
- if (textWasChanged) {
34658
- newContent = content_input.value;
34659
- }
34660
- }
34661
- else {
34662
- newContent = url_input.value;
34663
- }
34664
- const content = a.textContent;
34665
- if (newContent !== content) {
34666
- a.textContent = newContent;
34667
- }
34664
+ writeImage(a, content_input, textWasChanged, url_input);
34668
34665
  }
34669
34666
  if (openInNewTabCheckbox && target_checkbox) {
34670
34667
  (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.attr)(a, 'target', target_checkbox.checked ? '_blank' : null);
@@ -34709,6 +34706,74 @@ class link extends jodit_core_plugin__WEBPACK_IMPORTED_MODULE_4__/* .Plugin */ .
34709
34706
  jodit_core_decorators__WEBPACK_IMPORTED_MODULE_0__.autobind
34710
34707
  ], link.prototype, "__generateForm", null);
34711
34708
  jodit_core_global__WEBPACK_IMPORTED_MODULE_2__/* .pluginSystem */ .fg.add('link', link);
34709
+ function writeClasses(modeClassName, className_input, className_select, a) {
34710
+ if (modeClassName && (className_input ?? className_select)) {
34711
+ if (modeClassName === 'input') {
34712
+ if (className_input.value === '' && a.hasAttribute('class')) {
34713
+ (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.attr)(a, 'class', null);
34714
+ }
34715
+ if (className_input.value !== '') {
34716
+ (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.attr)(a, 'class', className_input.value);
34717
+ }
34718
+ }
34719
+ else if (modeClassName === 'select') {
34720
+ if (a.hasAttribute('class')) {
34721
+ (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.attr)(a, 'class', null);
34722
+ }
34723
+ for (let i = 0; i < className_select.selectedOptions.length; i++) {
34724
+ const className = className_select.selectedOptions.item(i)?.value;
34725
+ if (className) {
34726
+ a.classList.add(className);
34727
+ }
34728
+ }
34729
+ }
34730
+ }
34731
+ }
34732
+ function readClassnames(modeClassName, className_input, link, className_select) {
34733
+ switch (modeClassName) {
34734
+ case 'input':
34735
+ if (className_input) {
34736
+ className_input.value = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.attr)(link, 'class') || '';
34737
+ }
34738
+ break;
34739
+ case 'select':
34740
+ if (className_select) {
34741
+ for (let i = 0; i < className_select.selectedOptions.length; i++) {
34742
+ const option = className_select.options.item(i);
34743
+ if (option) {
34744
+ option.selected = false;
34745
+ }
34746
+ }
34747
+ const classNames = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.attr)(link, 'class') || '';
34748
+ classNames.split(' ').forEach(className => {
34749
+ if (className) {
34750
+ for (let i = 0; i < className_select.options.length; i++) {
34751
+ const option = className_select.options.item(i);
34752
+ if (option?.value && option.value === className) {
34753
+ option.selected = true;
34754
+ }
34755
+ }
34756
+ }
34757
+ });
34758
+ }
34759
+ break;
34760
+ }
34761
+ }
34762
+ function writeImage(a, content_input, textWasChanged, url_input) {
34763
+ let newContent = a.textContent;
34764
+ if (content_input.value.trim().length) {
34765
+ if (textWasChanged) {
34766
+ newContent = content_input.value;
34767
+ }
34768
+ }
34769
+ else {
34770
+ newContent = url_input.value;
34771
+ }
34772
+ const content = a.textContent;
34773
+ if (newContent !== content) {
34774
+ a.textContent = newContent;
34775
+ }
34776
+ }
34712
34777
 
34713
34778
 
34714
34779
  /***/ }),
@@ -37551,7 +37616,6 @@ jodit_config__WEBPACK_IMPORTED_MODULE_2__/* .Config */ .T.prototype.controls.fin
37551
37616
  /* harmony export */ _B: function() { return /* binding */ highlightTextRanges; },
37552
37617
  /* harmony export */ zy: function() { return /* binding */ getSelectionWrappers; }
37553
37618
  /* harmony export */ });
37554
- /* unused harmony export isSelectionWrapper */
37555
37619
  /* harmony import */ var jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23545);
37556
37620
  /* harmony import */ var jodit_core_helpers_utils_selector__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(52989);
37557
37621
  /*!
@@ -37573,60 +37637,14 @@ function highlightTextRanges(jodit, rng, restRanges, ci, root) {
37573
37637
  rng.endContainer.nodeValue == null) {
37574
37638
  return;
37575
37639
  }
37576
- if (jodit.o.search.useCustomHighlightAPI &&
37577
- // @ts-ignore Because Highlight is not defined in the types TS 5.3.3
37578
- typeof window.Highlight !== 'undefined') {
37579
- const ranges = [rng, ...restRanges].map(rng => {
37580
- const range = jodit.selection.createRange();
37581
- range.setStart(rng.startContainer, rng.startOffset);
37582
- range.setEnd(rng.endContainer, rng.endOffset);
37583
- return range;
37584
- });
37585
- // @ts-ignore Because Highlight is not defined in the types TS 5.3.3
37586
- const searchHighlight = new Highlight(...ranges);
37587
- // @ts-ignore
37588
- CSS.highlights.clear();
37589
- // @ts-ignore
37590
- CSS.highlights.set('jodit-search-result', searchHighlight);
37591
- restRanges.length = 0;
37640
+ if (checkNativeSelectionMethod(jodit, rng, restRanges)) {
37592
37641
  return;
37593
37642
  }
37594
37643
  const span = ci.element('span', {
37595
37644
  [TMP_ATTR]: true
37596
37645
  });
37597
37646
  jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__/* .Dom */ .J.markTemporary(span);
37598
- const startText = rng.startContainer.nodeValue;
37599
- let diff = 0;
37600
- if (rng.startOffset !== 0) {
37601
- const text = ci.text(startText.substring(0, rng.startOffset));
37602
- rng.startContainer.nodeValue = startText.substring(rng.startOffset);
37603
- jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__/* .Dom */ .J.before(rng.startContainer, text);
37604
- if (rng.startContainer === rng.endContainer) {
37605
- diff = rng.startOffset;
37606
- rng.endOffset -= diff;
37607
- }
37608
- rng.startOffset = 0;
37609
- }
37610
- const endText = rng.endContainer.nodeValue;
37611
- if (rng.endOffset !== endText.length) {
37612
- const text = ci.text(endText.substring(rng.endOffset));
37613
- rng.endContainer.nodeValue = endText.substring(0, rng.endOffset);
37614
- jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__/* .Dom */ .J.after(rng.endContainer, text);
37615
- for (const range of restRanges) {
37616
- if (range.startContainer === rng.endContainer) {
37617
- range.startContainer = text;
37618
- range.startOffset = range.startOffset - rng.endOffset - diff;
37619
- if (range.endContainer === rng.endContainer) {
37620
- range.endContainer = text;
37621
- range.endOffset = range.endOffset - rng.endOffset - diff;
37622
- }
37623
- }
37624
- else {
37625
- break;
37626
- }
37627
- }
37628
- rng.endOffset = rng.endContainer.nodeValue.length;
37629
- }
37647
+ normalizeRanges(rng, restRanges, ci);
37630
37648
  let next = rng.startContainer;
37631
37649
  do {
37632
37650
  if (!next) {
@@ -37672,6 +37690,61 @@ function clearSelectionWrappersFromHTML(root) {
37672
37690
  function isSelectionWrapper(node) {
37673
37691
  return jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__/* .Dom */ .J.isElement(node) && node.hasAttribute(TMP_ATTR);
37674
37692
  }
37693
+ function checkNativeSelectionMethod(jodit, rng, restRanges) {
37694
+ if (jodit.o.search.useCustomHighlightAPI &&
37695
+ // @ts-ignore Because Highlight is not defined in the types TS 5.3.3
37696
+ typeof window.Highlight !== 'undefined') {
37697
+ const ranges = [rng, ...restRanges].map(rng => {
37698
+ const range = jodit.selection.createRange();
37699
+ range.setStart(rng.startContainer, rng.startOffset);
37700
+ range.setEnd(rng.endContainer, rng.endOffset);
37701
+ return range;
37702
+ });
37703
+ // @ts-ignore Because Highlight is not defined in the types TS 5.3.3
37704
+ const searchHighlight = new Highlight(...ranges);
37705
+ // @ts-ignore
37706
+ CSS.highlights.clear();
37707
+ // @ts-ignore
37708
+ CSS.highlights.set('jodit-search-result', searchHighlight);
37709
+ restRanges.length = 0;
37710
+ return true;
37711
+ }
37712
+ return false;
37713
+ }
37714
+ function normalizeRanges(rng, restRanges, ci) {
37715
+ const startText = rng.startContainer.nodeValue;
37716
+ let diff = 0;
37717
+ if (rng.startOffset !== 0) {
37718
+ const text = ci.text(startText.substring(0, rng.startOffset));
37719
+ rng.startContainer.nodeValue = startText.substring(rng.startOffset);
37720
+ jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__/* .Dom */ .J.before(rng.startContainer, text);
37721
+ if (rng.startContainer === rng.endContainer) {
37722
+ diff = rng.startOffset;
37723
+ rng.endOffset -= diff;
37724
+ }
37725
+ rng.startOffset = 0;
37726
+ }
37727
+ const endText = rng.endContainer.nodeValue;
37728
+ if (rng.endOffset !== endText.length) {
37729
+ const text = ci.text(endText.substring(rng.endOffset));
37730
+ rng.endContainer.nodeValue = endText.substring(0, rng.endOffset);
37731
+ jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_0__/* .Dom */ .J.after(rng.endContainer, text);
37732
+ for (const range of restRanges) {
37733
+ if (range.startContainer === rng.endContainer) {
37734
+ range.startContainer = text;
37735
+ range.startOffset = range.startOffset - rng.endOffset - diff;
37736
+ if (range.endContainer === rng.endContainer) {
37737
+ range.endContainer = text;
37738
+ range.endOffset = range.endOffset - rng.endOffset - diff;
37739
+ }
37740
+ }
37741
+ else {
37742
+ break;
37743
+ }
37744
+ }
37745
+ rng.endOffset = rng.endContainer.nodeValue.length;
37746
+ }
37747
+ }
37675
37748
 
37676
37749
 
37677
37750
  /***/ }),
@@ -41053,38 +41126,10 @@ function tableKeyboardNavigation(editor) {
41053
41126
  .off('.tableKeyboardNavigation')
41054
41127
  .on('keydown.tableKeyboardNavigation', (event) => {
41055
41128
  const { key } = event;
41056
- if (!WORK_KEYS.has(key)) {
41057
- return;
41058
- }
41059
- const current = editor.s.current();
41060
- if (!current) {
41061
- return;
41062
- }
41063
- const cell = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.up(current, jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.isCell, editor.editor);
41129
+ const cell = findCell(editor, key);
41064
41130
  if (!cell) {
41065
41131
  return;
41066
41132
  }
41067
- const { range } = editor.s;
41068
- if (key !== jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_TAB && current !== cell) {
41069
- const isNextDirection = key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_RIGHT || key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_DOWN;
41070
- const hasNext = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.call)(!isNextDirection ? jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.prev : jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.next, current, elm => key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_UP || key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_DOWN
41071
- ? jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.isTag(elm, 'br')
41072
- : Boolean(elm), cell);
41073
- if ((!isNextDirection &&
41074
- (hasNext ||
41075
- (key !== jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_UP &&
41076
- jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.isText(current) &&
41077
- range.startOffset !== 0))) ||
41078
- (isNextDirection &&
41079
- (hasNext ||
41080
- (key !== jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_DOWN &&
41081
- jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.isText(current) &&
41082
- current.nodeValue &&
41083
- range.startOffset !==
41084
- current.nodeValue.length)))) {
41085
- return;
41086
- }
41087
- }
41088
41133
  const tableModule = editor.getInstance(jodit_modules_table_table__WEBPACK_IMPORTED_MODULE_4__/* .Table */ .X, editor.o);
41089
41134
  const table = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.closest(cell, 'table', editor.editor);
41090
41135
  let next = null;
@@ -41142,6 +41187,40 @@ function tableKeyboardNavigation(editor) {
41142
41187
  });
41143
41188
  }
41144
41189
  jodit_core_global__WEBPACK_IMPORTED_MODULE_2__/* .pluginSystem */ .fg.add('tableKeyboardNavigation', tableKeyboardNavigation);
41190
+ function findCell(editor, key) {
41191
+ if (!WORK_KEYS.has(key)) {
41192
+ return;
41193
+ }
41194
+ const current = editor.s.current();
41195
+ if (!current) {
41196
+ return;
41197
+ }
41198
+ const cell = jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.up(current, jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.isCell, editor.editor);
41199
+ if (!cell) {
41200
+ return;
41201
+ }
41202
+ const { range } = editor.s;
41203
+ if (key !== jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_TAB && current !== cell) {
41204
+ const isNextDirection = key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_RIGHT || key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_DOWN;
41205
+ const hasNext = (0,jodit_core_helpers__WEBPACK_IMPORTED_MODULE_3__.call)(!isNextDirection ? jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.prev : jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.next, current, elm => key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_UP || key === jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_DOWN
41206
+ ? jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.isTag(elm, 'br')
41207
+ : Boolean(elm), cell);
41208
+ if ((!isNextDirection &&
41209
+ (hasNext ||
41210
+ (key !== jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_UP &&
41211
+ jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.isText(current) &&
41212
+ range.startOffset !== 0))) ||
41213
+ (isNextDirection &&
41214
+ (hasNext ||
41215
+ (key !== jodit_core_constants__WEBPACK_IMPORTED_MODULE_0__.KEY_DOWN &&
41216
+ jodit_core_dom_dom__WEBPACK_IMPORTED_MODULE_1__/* .Dom */ .J.isText(current) &&
41217
+ current.nodeValue &&
41218
+ range.startOffset !== current.nodeValue.length)))) {
41219
+ return;
41220
+ }
41221
+ }
41222
+ return cell;
41223
+ }
41145
41224
 
41146
41225
 
41147
41226
  /***/ }),