jodit-pro 4.5.22 → 4.5.23
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/es2015/jodit.css +1 -1
- package/es2015/jodit.fat.min.js +2 -2
- package/es2015/jodit.js +2 -2
- package/es2015/jodit.min.js +2 -2
- package/es2015/plugins/autocomplete/autocomplete.js +1 -1
- package/es2015/plugins/autocomplete/autocomplete.min.js +1 -1
- package/es2015/plugins/backup/backup.css +1 -1
- package/es2015/plugins/backup/backup.js +1 -1
- package/es2015/plugins/backup/backup.min.js +1 -1
- package/es2015/plugins/button-generator/button-generator.css +1 -1
- package/es2015/plugins/button-generator/button-generator.js +1 -1
- package/es2015/plugins/button-generator/button-generator.min.js +1 -1
- package/es2015/plugins/change-case/change-case.js +1 -1
- package/es2015/plugins/change-case/change-case.min.js +1 -1
- package/es2015/plugins/color-picker/color-picker.css +1 -1
- package/es2015/plugins/color-picker/color-picker.js +1 -1
- package/es2015/plugins/color-picker/color-picker.min.js +1 -1
- package/es2015/plugins/emoji/emoji.css +1 -1
- package/es2015/plugins/emoji/emoji.js +1 -1
- package/es2015/plugins/emoji/emoji.min.js +1 -1
- package/es2015/plugins/export-docs/export-docs.js +1 -1
- package/es2015/plugins/export-docs/export-docs.min.js +1 -1
- package/es2015/plugins/finder/finder.css +1 -1
- package/es2015/plugins/finder/finder.js +1 -1
- package/es2015/plugins/finder/finder.min.js +1 -1
- package/es2015/plugins/google-maps/google-maps.css +1 -1
- package/es2015/plugins/google-maps/google-maps.js +1 -1
- package/es2015/plugins/google-maps/google-maps.min.js +1 -1
- package/es2015/plugins/google-search/google-search.js +1 -1
- package/es2015/plugins/google-search/google-search.min.js +1 -1
- package/es2015/plugins/highlight-signature/highlight-signature.js +2 -1
- package/es2015/plugins/highlight-signature/highlight-signature.min.js +2 -2
- package/es2015/plugins/iframe-editor/iframe-editor.css +1 -1
- package/es2015/plugins/iframe-editor/iframe-editor.js +1 -1
- package/es2015/plugins/iframe-editor/iframe-editor.min.js +1 -1
- package/es2015/plugins/keyboard/keyboard.css +1 -1
- package/es2015/plugins/keyboard/keyboard.js +1 -1
- package/es2015/plugins/keyboard/keyboard.min.js +1 -1
- package/es2015/plugins/mobile-view/mobile-view.js +1 -1
- package/es2015/plugins/mobile-view/mobile-view.min.js +1 -1
- package/es2015/plugins/page-break/page-break.js +1 -1
- package/es2015/plugins/page-break/page-break.min.js +1 -1
- package/es2015/plugins/paste-code/paste-code.css +1 -1
- package/es2015/plugins/paste-code/paste-code.js +1 -1
- package/es2015/plugins/paste-code/paste-code.min.js +1 -1
- package/es2015/plugins/paste-from-word/paste-from-word.js +1 -1
- package/es2015/plugins/paste-from-word/paste-from-word.min.js +1 -1
- package/es2015/plugins/show-blocks/show-blocks.js +1 -1
- package/es2015/plugins/show-blocks/show-blocks.min.js +1 -1
- package/es2015/plugins/todo-list/todo-list.css +1 -1
- package/es2015/plugins/todo-list/todo-list.js +1 -1
- package/es2015/plugins/todo-list/todo-list.min.js +1 -1
- package/es2015/plugins/translate/translate.css +1 -1
- package/es2015/plugins/translate/translate.js +1 -1
- package/es2015/plugins/translate/translate.min.js +1 -1
- package/es2015/plugins/tune-block/tune-block.css +1 -1
- package/es2015/plugins/tune-block/tune-block.js +1 -1
- package/es2015/plugins/tune-block/tune-block.min.js +1 -1
- package/es2018/jodit.css +1 -1
- package/es2018/jodit.fat.min.js +2 -2
- package/es2018/jodit.js +2 -2
- package/es2018/jodit.min.js +2 -2
- package/es2018/plugins/autocomplete/autocomplete.js +1 -1
- package/es2018/plugins/autocomplete/autocomplete.min.js +1 -1
- package/es2018/plugins/backup/backup.css +1 -1
- package/es2018/plugins/backup/backup.js +1 -1
- package/es2018/plugins/backup/backup.min.js +1 -1
- package/es2018/plugins/button-generator/button-generator.css +1 -1
- package/es2018/plugins/button-generator/button-generator.js +1 -1
- package/es2018/plugins/button-generator/button-generator.min.js +1 -1
- package/es2018/plugins/change-case/change-case.js +1 -1
- package/es2018/plugins/change-case/change-case.min.js +1 -1
- package/es2018/plugins/color-picker/color-picker.css +1 -1
- package/es2018/plugins/color-picker/color-picker.js +1 -1
- package/es2018/plugins/color-picker/color-picker.min.js +1 -1
- package/es2018/plugins/emoji/emoji.css +1 -1
- package/es2018/plugins/emoji/emoji.js +1 -1
- package/es2018/plugins/emoji/emoji.min.js +1 -1
- package/es2018/plugins/export-docs/export-docs.js +1 -1
- package/es2018/plugins/export-docs/export-docs.min.js +1 -1
- package/es2018/plugins/finder/finder.css +1 -1
- package/es2018/plugins/finder/finder.js +1 -1
- package/es2018/plugins/finder/finder.min.js +1 -1
- package/es2018/plugins/google-maps/google-maps.css +1 -1
- package/es2018/plugins/google-maps/google-maps.js +1 -1
- package/es2018/plugins/google-maps/google-maps.min.js +1 -1
- package/es2018/plugins/google-search/google-search.js +1 -1
- package/es2018/plugins/google-search/google-search.min.js +1 -1
- package/es2018/plugins/highlight-signature/highlight-signature.js +2 -1
- package/es2018/plugins/highlight-signature/highlight-signature.min.js +2 -2
- package/es2018/plugins/iframe-editor/iframe-editor.css +1 -1
- package/es2018/plugins/iframe-editor/iframe-editor.js +1 -1
- package/es2018/plugins/iframe-editor/iframe-editor.min.js +1 -1
- package/es2018/plugins/keyboard/keyboard.css +1 -1
- package/es2018/plugins/keyboard/keyboard.js +1 -1
- package/es2018/plugins/keyboard/keyboard.min.js +1 -1
- package/es2018/plugins/mobile-view/mobile-view.js +1 -1
- package/es2018/plugins/mobile-view/mobile-view.min.js +1 -1
- package/es2018/plugins/page-break/page-break.js +1 -1
- package/es2018/plugins/page-break/page-break.min.js +1 -1
- package/es2018/plugins/paste-code/paste-code.css +1 -1
- package/es2018/plugins/paste-code/paste-code.js +1 -1
- package/es2018/plugins/paste-code/paste-code.min.js +1 -1
- package/es2018/plugins/paste-from-word/paste-from-word.js +1 -1
- package/es2018/plugins/paste-from-word/paste-from-word.min.js +1 -1
- package/es2018/plugins/show-blocks/show-blocks.js +1 -1
- package/es2018/plugins/show-blocks/show-blocks.min.js +1 -1
- package/es2018/plugins/todo-list/todo-list.css +1 -1
- package/es2018/plugins/todo-list/todo-list.js +1 -1
- package/es2018/plugins/todo-list/todo-list.min.js +1 -1
- package/es2018/plugins/translate/translate.css +1 -1
- package/es2018/plugins/translate/translate.js +1 -1
- package/es2018/plugins/translate/translate.min.js +1 -1
- package/es2018/plugins/tune-block/tune-block.css +1 -1
- package/es2018/plugins/tune-block/tune-block.js +1 -1
- package/es2018/plugins/tune-block/tune-block.min.js +1 -1
- package/es2021/jodit.css +1 -1
- package/es2021/jodit.fat.min.js +2 -2
- package/es2021/jodit.js +2 -2
- package/es2021/jodit.min.js +2 -2
- package/es2021/plugins/autocomplete/autocomplete.js +1 -1
- package/es2021/plugins/autocomplete/autocomplete.min.js +1 -1
- package/es2021/plugins/backup/backup.css +1 -1
- package/es2021/plugins/backup/backup.js +1 -1
- package/es2021/plugins/backup/backup.min.js +1 -1
- package/es2021/plugins/button-generator/button-generator.css +1 -1
- package/es2021/plugins/button-generator/button-generator.js +1 -1
- package/es2021/plugins/button-generator/button-generator.min.js +1 -1
- package/es2021/plugins/change-case/change-case.js +1 -1
- package/es2021/plugins/change-case/change-case.min.js +1 -1
- package/es2021/plugins/color-picker/color-picker.css +1 -1
- package/es2021/plugins/color-picker/color-picker.js +1 -1
- package/es2021/plugins/color-picker/color-picker.min.js +1 -1
- package/es2021/plugins/emoji/emoji.css +1 -1
- package/es2021/plugins/emoji/emoji.js +1 -1
- package/es2021/plugins/emoji/emoji.min.js +1 -1
- package/es2021/plugins/export-docs/export-docs.js +1 -1
- package/es2021/plugins/export-docs/export-docs.min.js +1 -1
- package/es2021/plugins/finder/finder.css +1 -1
- package/es2021/plugins/finder/finder.js +1 -1
- package/es2021/plugins/finder/finder.min.js +1 -1
- package/es2021/plugins/google-maps/google-maps.css +1 -1
- package/es2021/plugins/google-maps/google-maps.js +1 -1
- package/es2021/plugins/google-maps/google-maps.min.js +1 -1
- package/es2021/plugins/google-search/google-search.js +1 -1
- package/es2021/plugins/google-search/google-search.min.js +1 -1
- package/es2021/plugins/highlight-signature/highlight-signature.js +2 -1
- package/es2021/plugins/highlight-signature/highlight-signature.min.js +2 -2
- package/es2021/plugins/iframe-editor/iframe-editor.css +1 -1
- package/es2021/plugins/iframe-editor/iframe-editor.js +1 -1
- package/es2021/plugins/iframe-editor/iframe-editor.min.js +1 -1
- package/es2021/plugins/keyboard/keyboard.css +1 -1
- package/es2021/plugins/keyboard/keyboard.js +1 -1
- package/es2021/plugins/keyboard/keyboard.min.js +1 -1
- package/es2021/plugins/mobile-view/mobile-view.js +1 -1
- package/es2021/plugins/mobile-view/mobile-view.min.js +1 -1
- package/es2021/plugins/page-break/page-break.js +1 -1
- package/es2021/plugins/page-break/page-break.min.js +1 -1
- package/es2021/plugins/paste-code/paste-code.css +1 -1
- package/es2021/plugins/paste-code/paste-code.js +1 -1
- package/es2021/plugins/paste-code/paste-code.min.js +1 -1
- package/es2021/plugins/paste-from-word/paste-from-word.js +1 -1
- package/es2021/plugins/paste-from-word/paste-from-word.min.js +1 -1
- package/es2021/plugins/show-blocks/show-blocks.js +1 -1
- package/es2021/plugins/show-blocks/show-blocks.min.js +1 -1
- package/es2021/plugins/todo-list/todo-list.css +1 -1
- package/es2021/plugins/todo-list/todo-list.js +1 -1
- package/es2021/plugins/todo-list/todo-list.min.js +1 -1
- package/es2021/plugins/translate/translate.css +1 -1
- package/es2021/plugins/translate/translate.js +1 -1
- package/es2021/plugins/translate/translate.min.js +1 -1
- package/es2021/plugins/tune-block/tune-block.css +1 -1
- package/es2021/plugins/tune-block/tune-block.js +1 -1
- package/es2021/plugins/tune-block/tune-block.min.js +1 -1
- package/es2021.en/jodit.css +1 -1
- package/es2021.en/jodit.fat.min.js +2 -2
- package/es2021.en/jodit.js +2 -2
- package/es2021.en/jodit.min.js +2 -2
- package/es2021.en/plugins/autocomplete/autocomplete.js +1 -1
- package/es2021.en/plugins/autocomplete/autocomplete.min.js +1 -1
- package/es2021.en/plugins/backup/backup.css +1 -1
- package/es2021.en/plugins/backup/backup.js +1 -1
- package/es2021.en/plugins/backup/backup.min.js +1 -1
- package/es2021.en/plugins/button-generator/button-generator.css +1 -1
- package/es2021.en/plugins/button-generator/button-generator.js +1 -1
- package/es2021.en/plugins/button-generator/button-generator.min.js +1 -1
- package/es2021.en/plugins/change-case/change-case.js +1 -1
- package/es2021.en/plugins/change-case/change-case.min.js +1 -1
- package/es2021.en/plugins/color-picker/color-picker.css +1 -1
- package/es2021.en/plugins/color-picker/color-picker.js +1 -1
- package/es2021.en/plugins/color-picker/color-picker.min.js +1 -1
- package/es2021.en/plugins/emoji/emoji.css +1 -1
- package/es2021.en/plugins/emoji/emoji.js +1 -1
- package/es2021.en/plugins/emoji/emoji.min.js +1 -1
- package/es2021.en/plugins/export-docs/export-docs.js +1 -1
- package/es2021.en/plugins/export-docs/export-docs.min.js +1 -1
- package/es2021.en/plugins/finder/finder.css +1 -1
- package/es2021.en/plugins/finder/finder.js +1 -1
- package/es2021.en/plugins/finder/finder.min.js +1 -1
- package/es2021.en/plugins/google-maps/google-maps.css +1 -1
- package/es2021.en/plugins/google-maps/google-maps.js +1 -1
- package/es2021.en/plugins/google-maps/google-maps.min.js +1 -1
- package/es2021.en/plugins/google-search/google-search.js +1 -1
- package/es2021.en/plugins/google-search/google-search.min.js +1 -1
- package/es2021.en/plugins/highlight-signature/highlight-signature.js +2 -1
- package/es2021.en/plugins/highlight-signature/highlight-signature.min.js +2 -2
- package/es2021.en/plugins/iframe-editor/iframe-editor.css +1 -1
- package/es2021.en/plugins/iframe-editor/iframe-editor.js +1 -1
- package/es2021.en/plugins/iframe-editor/iframe-editor.min.js +1 -1
- package/es2021.en/plugins/keyboard/keyboard.css +1 -1
- package/es2021.en/plugins/keyboard/keyboard.js +1 -1
- package/es2021.en/plugins/keyboard/keyboard.min.js +1 -1
- package/es2021.en/plugins/mobile-view/mobile-view.js +1 -1
- package/es2021.en/plugins/mobile-view/mobile-view.min.js +1 -1
- package/es2021.en/plugins/page-break/page-break.js +1 -1
- package/es2021.en/plugins/page-break/page-break.min.js +1 -1
- package/es2021.en/plugins/paste-code/paste-code.css +1 -1
- package/es2021.en/plugins/paste-code/paste-code.js +1 -1
- package/es2021.en/plugins/paste-code/paste-code.min.js +1 -1
- package/es2021.en/plugins/paste-from-word/paste-from-word.js +1 -1
- package/es2021.en/plugins/paste-from-word/paste-from-word.min.js +1 -1
- package/es2021.en/plugins/show-blocks/show-blocks.js +1 -1
- package/es2021.en/plugins/show-blocks/show-blocks.min.js +1 -1
- package/es2021.en/plugins/todo-list/todo-list.css +1 -1
- package/es2021.en/plugins/todo-list/todo-list.js +1 -1
- package/es2021.en/plugins/todo-list/todo-list.min.js +1 -1
- package/es2021.en/plugins/translate/translate.css +1 -1
- package/es2021.en/plugins/translate/translate.js +1 -1
- package/es2021.en/plugins/translate/translate.min.js +1 -1
- package/es2021.en/plugins/tune-block/tune-block.css +1 -1
- package/es2021.en/plugins/tune-block/tune-block.js +1 -1
- package/es2021.en/plugins/tune-block/tune-block.min.js +1 -1
- package/es5/jodit.css +2 -2
- package/es5/jodit.fat.min.js +2 -2
- package/es5/jodit.js +2 -2
- package/es5/jodit.min.css +2 -2
- package/es5/jodit.min.js +2 -2
- package/es5/plugins/autocomplete/autocomplete.js +1 -1
- package/es5/plugins/autocomplete/autocomplete.min.js +1 -1
- package/es5/plugins/backup/backup.css +1 -1
- package/es5/plugins/backup/backup.js +1 -1
- package/es5/plugins/backup/backup.min.js +1 -1
- package/es5/plugins/button-generator/button-generator.css +1 -1
- package/es5/plugins/button-generator/button-generator.js +1 -1
- package/es5/plugins/button-generator/button-generator.min.js +1 -1
- package/es5/plugins/change-case/change-case.js +1 -1
- package/es5/plugins/change-case/change-case.min.js +1 -1
- package/es5/plugins/color-picker/color-picker.css +1 -1
- package/es5/plugins/color-picker/color-picker.js +1 -1
- package/es5/plugins/color-picker/color-picker.min.js +1 -1
- package/es5/plugins/emoji/emoji.css +1 -1
- package/es5/plugins/emoji/emoji.js +1 -1
- package/es5/plugins/emoji/emoji.min.js +1 -1
- package/es5/plugins/export-docs/export-docs.js +1 -1
- package/es5/plugins/export-docs/export-docs.min.js +1 -1
- package/es5/plugins/finder/finder.css +1 -1
- package/es5/plugins/finder/finder.js +1 -1
- package/es5/plugins/finder/finder.min.js +1 -1
- package/es5/plugins/google-maps/google-maps.css +1 -1
- package/es5/plugins/google-maps/google-maps.js +1 -1
- package/es5/plugins/google-maps/google-maps.min.js +1 -1
- package/es5/plugins/google-search/google-search.js +1 -1
- package/es5/plugins/google-search/google-search.min.js +1 -1
- package/es5/plugins/highlight-signature/highlight-signature.js +2 -1
- package/es5/plugins/highlight-signature/highlight-signature.min.js +2 -2
- package/es5/plugins/iframe-editor/iframe-editor.css +1 -1
- package/es5/plugins/iframe-editor/iframe-editor.js +1 -1
- package/es5/plugins/iframe-editor/iframe-editor.min.js +1 -1
- package/es5/plugins/keyboard/keyboard.css +1 -1
- package/es5/plugins/keyboard/keyboard.js +1 -1
- package/es5/plugins/keyboard/keyboard.min.js +1 -1
- package/es5/plugins/mobile-view/mobile-view.js +1 -1
- package/es5/plugins/mobile-view/mobile-view.min.js +1 -1
- package/es5/plugins/page-break/page-break.js +1 -1
- package/es5/plugins/page-break/page-break.min.js +1 -1
- package/es5/plugins/paste-code/paste-code.css +1 -1
- package/es5/plugins/paste-code/paste-code.js +1 -1
- package/es5/plugins/paste-code/paste-code.min.js +1 -1
- package/es5/plugins/paste-from-word/paste-from-word.js +1 -1
- package/es5/plugins/paste-from-word/paste-from-word.min.js +1 -1
- package/es5/plugins/show-blocks/show-blocks.js +1 -1
- package/es5/plugins/show-blocks/show-blocks.min.js +1 -1
- package/es5/plugins/todo-list/todo-list.css +1 -1
- package/es5/plugins/todo-list/todo-list.js +1 -1
- package/es5/plugins/todo-list/todo-list.min.js +1 -1
- package/es5/plugins/translate/translate.css +1 -1
- package/es5/plugins/translate/translate.js +1 -1
- package/es5/plugins/translate/translate.min.js +1 -1
- package/es5/plugins/tune-block/tune-block.css +1 -1
- package/es5/plugins/tune-block/tune-block.js +1 -1
- package/es5/plugins/tune-block/tune-block.min.js +1 -1
- package/esm/plugins/highlight-signature/highlight-signature.js +1 -1
- 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.5.
|
|
4
|
+
* Version: v4.5.23
|
|
5
5
|
* Url: https://xdsoft.net/jodit/pro/
|
|
6
6
|
* License(s): SEE LICENSE IN LICENSE.md
|
|
7
7
|
*/
|
|
@@ -57,6 +57,7 @@ var highlightSignature = /** @class */ (function (_super) {
|
|
|
57
57
|
jodit.e
|
|
58
58
|
.on('change afterSetMode', this.walkNodes)
|
|
59
59
|
.on('afterGetValueFromEditor', highlightSignature.removeUtilWrappers);
|
|
60
|
+
this.walkNodes();
|
|
60
61
|
}
|
|
61
62
|
};
|
|
62
63
|
highlightSignature.prototype.beforeDestruct = function (jodit) {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* jodit-pro - PRO Version of Jodit Editor
|
|
3
3
|
* Author: Chupurnov Valeriy <chupurnov@gmail.com>
|
|
4
|
-
* Version: v4.5.
|
|
4
|
+
* Version: v4.5.23
|
|
5
5
|
* Url: https://xdsoft.net/jodit/pro/
|
|
6
6
|
* License(s): SEE LICENSE IN LICENSE.md
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
9
|
|
|
10
|
-
"use strict";!function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var r=t();for(var o in r)("object"==typeof exports?exports:e)[o]=r[o]}}(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[726],{29571:function(e,t,r){r.r(t),r.d(t,{highlightSignature:function(){return h}});var o=r(31635),i=(r(66628),r(65478)),n=r(2748),a=r(29960),s=r(20356),l=r(34013),h=function(e){function t(){var t=e.apply(this,(0,o.fX)([],(0,o.zs)(arguments),!1))||this;return t.abortController=null,t}return(0,o.C6)(t,e),t.prototype.afterInit=function(e){Object.keys(e.o.highlightSignature.schema).length&&e.e.on("change afterSetMode",this.walkNodes).on("afterGetValueFromEditor",t.removeUtilWrappers)},t.prototype.beforeDestruct=function(e){e.e.off("change afterSetMode",this.walkNodes).off("afterGetValueFromEditor",t.removeUtilWrappers)},t.prototype.walkNodes=function(){var e;if(this.j.isEditorMode()){this.checkUtilsBoxToSchema();var t=this.j,r=t.ed.createNodeIterator(t.editor,NodeFilter.SHOW_TEXT);null===(e=this.abortController)||void 0===e||e.abort(),this.workLoop(r)}},t.prototype.runWorker=function(e){var t;this.j.e.mute();var r=0,o=this.j.o.highlightSignature.processInChunkCount;try{do{if(r+=1,!(t=e.nextNode()))return;if(this.checkNormalizing(t))return;this.checkReplaceSchemas(t)}while(t&&o>r)}finally{this.j.e.unmute()}this.workLoop(e)},t.prototype.workLoop=function(e){var t=this;this.abortController=new AbortController,this.j.async.schedulerPostTask((function(){return t.runWorker(e)}),{delay:this.j.o.highlightSignature.processDelay}).catch((function(){return null}))},t.prototype.checkNormalizing=function(e){return!!n.J.isText(e.nextSibling)&&(this.j.editor.normalize(),this.walkNodes(),!0)},t.prototype.checkReplaceSchemas=function(e){if(!t.hasUtilWrapper(e)){var r=e.nodeValue;if(null!=r){var o=this.j.o.highlightSignature;for(var i in o.schema){var a=RegExp(i);if(a.test(r)){var s=r.match(a);if(!s||void 0===s.index)continue;var l=o.schema[i](this.j,s);if(l)return n.J.markTemporary(l,{dataHighlightSchema:i}),void this.replaceMatchedTextToElm(e,r,s,l)}}}}},t.prototype.replaceMatchedTextToElm=function(e,t,r,o){var i,a=this.j,s=a.s.range,l=s.startContainer===e,h=s.startOffset,u=null!==(i=r.index)&&void 0!==i?i:0;e.nodeValue=t.substring(0,u);var c=t.substring(u+r[0].length);if(c.length){var p=a.createInside.text(c);n.J.after(e,p)}o.innerText=r[0],n.J.after(e,o),l&&this.restoreCursorPosition(h,e,o.firstChild,o.nextSibling)},t.hasUtilWrapper=function(e){return n.J.isTemporary(e.parentElement)},t.removeUtilWrappers=function(e){e.value=n.J.replaceTemporaryFromString(e.value)},t.prototype.restoreCursorPosition=function(e){for(var t,r,i=[],n=1;arguments.length>n;n++)i[n-1]=arguments[n];try{for(var a=(0,o.Ju)(i),s=a.next();!s.done;s=a.next()){var l=s.value;if(l&&l.nodeValue){var h=l.nodeValue;if(h.length>=e){var u=this.j.s.createRange();u.setStart(l,e),this.j.s.selectRange(u,!1);break}e-=h.length}}}catch(e){t={error:e}}finally{try{s&&!s.done&&(r=a.return)&&r.call(a)}finally{if(t)throw t.error}}},t.prototype.checkUtilsBoxToSchema=function(){var e=this;n.J.temporaryList(this.j.editor).forEach((function(t){var r,o=(0,a.C)(t,"dataHighlightSchema");if(o){var i=RegExp(o),s=null!==(r=t.innerText)&&void 0!==r?r:"";i.test(s)&&!s.replace(i,"").length||(e.j.s.save(),n.J.unwrap(t),e.j.s.restore())}}))},t.requires=["license"],(0,o.Cg)([(0,i.debounce)()],t.prototype,"walkNodes",null),(0,o.Cg)([i.autobind],t.prototype,"runWorker",null),t}(s.k);l.A.plugins.add("highlight-signature",h)},66628:function(e,t,r){r(6441).T.prototype.highlightSignature={processDelay:0,processInChunkCount:300,schema:{},excludeTags:["pre"]}}},function(e){return e(e.s=29571)}])}));
|
|
10
|
+
"use strict";!function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var r=t();for(var o in r)("object"==typeof exports?exports:e)[o]=r[o]}}(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[726],{29571:function(e,t,r){r.r(t),r.d(t,{highlightSignature:function(){return h}});var o=r(31635),i=(r(66628),r(65478)),n=r(2748),a=r(29960),s=r(20356),l=r(34013),h=function(e){function t(){var t=e.apply(this,(0,o.fX)([],(0,o.zs)(arguments),!1))||this;return t.abortController=null,t}return(0,o.C6)(t,e),t.prototype.afterInit=function(e){Object.keys(e.o.highlightSignature.schema).length&&(e.e.on("change afterSetMode",this.walkNodes).on("afterGetValueFromEditor",t.removeUtilWrappers),this.walkNodes())},t.prototype.beforeDestruct=function(e){e.e.off("change afterSetMode",this.walkNodes).off("afterGetValueFromEditor",t.removeUtilWrappers)},t.prototype.walkNodes=function(){var e;if(this.j.isEditorMode()){this.checkUtilsBoxToSchema();var t=this.j,r=t.ed.createNodeIterator(t.editor,NodeFilter.SHOW_TEXT);null===(e=this.abortController)||void 0===e||e.abort(),this.workLoop(r)}},t.prototype.runWorker=function(e){var t;this.j.e.mute();var r=0,o=this.j.o.highlightSignature.processInChunkCount;try{do{if(r+=1,!(t=e.nextNode()))return;if(this.checkNormalizing(t))return;this.checkReplaceSchemas(t)}while(t&&o>r)}finally{this.j.e.unmute()}this.workLoop(e)},t.prototype.workLoop=function(e){var t=this;this.abortController=new AbortController,this.j.async.schedulerPostTask((function(){return t.runWorker(e)}),{delay:this.j.o.highlightSignature.processDelay}).catch((function(){return null}))},t.prototype.checkNormalizing=function(e){return!!n.J.isText(e.nextSibling)&&(this.j.editor.normalize(),this.walkNodes(),!0)},t.prototype.checkReplaceSchemas=function(e){if(!t.hasUtilWrapper(e)){var r=e.nodeValue;if(null!=r){var o=this.j.o.highlightSignature;for(var i in o.schema){var a=RegExp(i);if(a.test(r)){var s=r.match(a);if(!s||void 0===s.index)continue;var l=o.schema[i](this.j,s);if(l)return n.J.markTemporary(l,{dataHighlightSchema:i}),void this.replaceMatchedTextToElm(e,r,s,l)}}}}},t.prototype.replaceMatchedTextToElm=function(e,t,r,o){var i,a=this.j,s=a.s.range,l=s.startContainer===e,h=s.startOffset,u=null!==(i=r.index)&&void 0!==i?i:0;e.nodeValue=t.substring(0,u);var c=t.substring(u+r[0].length);if(c.length){var p=a.createInside.text(c);n.J.after(e,p)}o.innerText=r[0],n.J.after(e,o),l&&this.restoreCursorPosition(h,e,o.firstChild,o.nextSibling)},t.hasUtilWrapper=function(e){return n.J.isTemporary(e.parentElement)},t.removeUtilWrappers=function(e){e.value=n.J.replaceTemporaryFromString(e.value)},t.prototype.restoreCursorPosition=function(e){for(var t,r,i=[],n=1;arguments.length>n;n++)i[n-1]=arguments[n];try{for(var a=(0,o.Ju)(i),s=a.next();!s.done;s=a.next()){var l=s.value;if(l&&l.nodeValue){var h=l.nodeValue;if(h.length>=e){var u=this.j.s.createRange();u.setStart(l,e),this.j.s.selectRange(u,!1);break}e-=h.length}}}catch(e){t={error:e}}finally{try{s&&!s.done&&(r=a.return)&&r.call(a)}finally{if(t)throw t.error}}},t.prototype.checkUtilsBoxToSchema=function(){var e=this;n.J.temporaryList(this.j.editor).forEach((function(t){var r,o=(0,a.C)(t,"dataHighlightSchema");if(o){var i=RegExp(o),s=null!==(r=t.innerText)&&void 0!==r?r:"";i.test(s)&&!s.replace(i,"").length||(e.j.s.save(),n.J.unwrap(t),e.j.s.restore())}}))},t.requires=["license"],(0,o.Cg)([(0,i.debounce)()],t.prototype,"walkNodes",null),(0,o.Cg)([i.autobind],t.prototype,"runWorker",null),t}(s.k);l.A.plugins.add("highlight-signature",h)},66628:function(e,t,r){r(6441).T.prototype.highlightSignature={processDelay:0,processInChunkCount:300,schema:{},excludeTags:["pre"]}}},function(e){return e(e.s=29571)}])}));
|
|
@@ -3,4 +3,4 @@
|
|
|
3
3
|
* See LICENSE.md in the project root for license information.
|
|
4
4
|
* Copyright (c) 2013-2025 Valeriy Chupurnov. All rights reserved. https://xdsoft.net/jodit/pro/
|
|
5
5
|
*/
|
|
6
|
-
var e=this&&this.__decorate||function(e,t,r,i){var o,s=arguments.length,n=s<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,r):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,r,i);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(s<3?o(n):s>3?o(t,r,n):o(t,r))||n);return s>3&&n&&Object.defineProperty(t,r,n),n};import"./config.js";import{autobind as t,debounce as r}from"jodit/esm/core/decorators/index.js";import{Dom as i}from"jodit/esm/core/dom/dom.js";import{attr as o}from"jodit/esm/core/helpers/utils/attr.js";import{Plugin as s}from"jodit/esm/core/plugin/plugin.js";import{JoditPro as n}from"../../jodit-pro.js";export class highlightSignature extends s{constructor(){super(...arguments),this.abortController=null}afterInit(e){Object.keys(e.o.highlightSignature.schema).length&&e.e.on("change afterSetMode",this.walkNodes).on("afterGetValueFromEditor",highlightSignature.removeUtilWrappers)}beforeDestruct(e){e.e.off("change afterSetMode",this.walkNodes).off("afterGetValueFromEditor",highlightSignature.removeUtilWrappers)}walkNodes(){var e;if(!this.j.isEditorMode())return;this.checkUtilsBoxToSchema();const{j:t}=this,r=t.ed.createNodeIterator(t.editor,NodeFilter.SHOW_TEXT);null===(e=this.abortController)||void 0===e||e.abort(),this.workLoop(r)}runWorker(e){let t;this.j.e.mute();let r=0;const{processInChunkCount:i}=this.j.o.highlightSignature;try{do{if(r+=1,t=e.nextNode(),!t)return;if(this.checkNormalizing(t))return;this.checkReplaceSchemas(t)}while(t&&i>r)}finally{this.j.e.unmute()}this.workLoop(e)}workLoop(e){this.abortController=new AbortController,this.j.async.schedulerPostTask((()=>this.runWorker(e)),{delay:this.j.o.highlightSignature.processDelay}).catch((()=>null))}checkNormalizing(e){return!!i.isText(e.nextSibling)&&(this.j.editor.normalize(),this.walkNodes(),!0)}checkReplaceSchemas(e){if(highlightSignature.hasUtilWrapper(e))return;const t=e.nodeValue;if(null==t)return;const{j:r}=this,o=r.o.highlightSignature;for(const r in o.schema){const s=RegExp(r);if(s.test(t)){const n=t.match(s);if(!n||void 0===n.index)continue;const a=o.schema[r](this.j,n);if(a)return i.markTemporary(a,{dataHighlightSchema:r}),void this.replaceMatchedTextToElm(e,t,n,a)}}}replaceMatchedTextToElm(e,t,r,o){var s;const{j:n}=this,{range:a}=n.s,h=a.startContainer===e,l=a.startOffset,c=null!==(s=r.index)&&void 0!==s?s:0;e.nodeValue=t.substring(0,c);const g=t.substring(c+r[0].length);if(g.length){const t=n.createInside.text(g);i.after(e,t)}o.innerText=r[0],i.after(e,o),h&&this.restoreCursorPosition(l,e,o.firstChild,o.nextSibling)}static hasUtilWrapper(e){return i.isTemporary(e.parentElement)}static removeUtilWrappers(e){e.value=i.replaceTemporaryFromString(e.value)}restoreCursorPosition(e,...t){for(const r of t)if(r&&r.nodeValue){const t=r.nodeValue;if(t.length>=e){const t=this.j.s.createRange();t.setStart(r,e),this.j.s.selectRange(t,!1);break}e-=t.length}}checkUtilsBoxToSchema(){i.temporaryList(this.j.editor).forEach((e=>{var t;const r=o(e,"dataHighlightSchema");if(!r)return;const s=RegExp(r),n=null!==(t=e.innerText)&&void 0!==t?t:"";s.test(n)&&!n.replace(s,"").length||(this.j.s.save(),i.unwrap(e),this.j.s.restore())}))}}highlightSignature.requires=["license"],e([r()],highlightSignature.prototype,"walkNodes",null),e([t],highlightSignature.prototype,"runWorker",null),n.plugins.add("highlight-signature",highlightSignature);
|
|
6
|
+
var e=this&&this.__decorate||function(e,t,r,i){var o,s=arguments.length,n=s<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,r):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,r,i);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(s<3?o(n):s>3?o(t,r,n):o(t,r))||n);return s>3&&n&&Object.defineProperty(t,r,n),n};import"./config.js";import{autobind as t,debounce as r}from"jodit/esm/core/decorators/index.js";import{Dom as i}from"jodit/esm/core/dom/dom.js";import{attr as o}from"jodit/esm/core/helpers/utils/attr.js";import{Plugin as s}from"jodit/esm/core/plugin/plugin.js";import{JoditPro as n}from"../../jodit-pro.js";export class highlightSignature extends s{constructor(){super(...arguments),this.abortController=null}afterInit(e){Object.keys(e.o.highlightSignature.schema).length&&(e.e.on("change afterSetMode",this.walkNodes).on("afterGetValueFromEditor",highlightSignature.removeUtilWrappers),this.walkNodes())}beforeDestruct(e){e.e.off("change afterSetMode",this.walkNodes).off("afterGetValueFromEditor",highlightSignature.removeUtilWrappers)}walkNodes(){var e;if(!this.j.isEditorMode())return;this.checkUtilsBoxToSchema();const{j:t}=this,r=t.ed.createNodeIterator(t.editor,NodeFilter.SHOW_TEXT);null===(e=this.abortController)||void 0===e||e.abort(),this.workLoop(r)}runWorker(e){let t;this.j.e.mute();let r=0;const{processInChunkCount:i}=this.j.o.highlightSignature;try{do{if(r+=1,t=e.nextNode(),!t)return;if(this.checkNormalizing(t))return;this.checkReplaceSchemas(t)}while(t&&i>r)}finally{this.j.e.unmute()}this.workLoop(e)}workLoop(e){this.abortController=new AbortController,this.j.async.schedulerPostTask((()=>this.runWorker(e)),{delay:this.j.o.highlightSignature.processDelay}).catch((()=>null))}checkNormalizing(e){return!!i.isText(e.nextSibling)&&(this.j.editor.normalize(),this.walkNodes(),!0)}checkReplaceSchemas(e){if(highlightSignature.hasUtilWrapper(e))return;const t=e.nodeValue;if(null==t)return;const{j:r}=this,o=r.o.highlightSignature;for(const r in o.schema){const s=RegExp(r);if(s.test(t)){const n=t.match(s);if(!n||void 0===n.index)continue;const a=o.schema[r](this.j,n);if(a)return i.markTemporary(a,{dataHighlightSchema:r}),void this.replaceMatchedTextToElm(e,t,n,a)}}}replaceMatchedTextToElm(e,t,r,o){var s;const{j:n}=this,{range:a}=n.s,h=a.startContainer===e,l=a.startOffset,c=null!==(s=r.index)&&void 0!==s?s:0;e.nodeValue=t.substring(0,c);const g=t.substring(c+r[0].length);if(g.length){const t=n.createInside.text(g);i.after(e,t)}o.innerText=r[0],i.after(e,o),h&&this.restoreCursorPosition(l,e,o.firstChild,o.nextSibling)}static hasUtilWrapper(e){return i.isTemporary(e.parentElement)}static removeUtilWrappers(e){e.value=i.replaceTemporaryFromString(e.value)}restoreCursorPosition(e,...t){for(const r of t)if(r&&r.nodeValue){const t=r.nodeValue;if(t.length>=e){const t=this.j.s.createRange();t.setStart(r,e),this.j.s.selectRange(t,!1);break}e-=t.length}}checkUtilsBoxToSchema(){i.temporaryList(this.j.editor).forEach((e=>{var t;const r=o(e,"dataHighlightSchema");if(!r)return;const s=RegExp(r),n=null!==(t=e.innerText)&&void 0!==t?t:"";s.test(n)&&!n.replace(s,"").length||(this.j.s.save(),i.unwrap(e),this.j.s.restore())}))}}highlightSignature.requires=["license"],e([r()],highlightSignature.prototype,"walkNodes",null),e([t],highlightSignature.prototype,"runWorker",null),n.plugins.add("highlight-signature",highlightSignature);
|