jodit-pro 4.13.35 → 4.13.37
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 +5 -5
- package/es2015/jodit.js +199 -109
- package/es2015/jodit.min.js +10 -10
- package/es2015/plugins/ai-assistant-pro/ai-assistant-pro.css +1 -1
- package/es2015/plugins/ai-assistant-pro/ai-assistant-pro.js +1 -1
- package/es2015/plugins/ai-assistant-pro/ai-assistant-pro.min.js +1 -1
- package/es2015/plugins/autocomplete/autocomplete.css +1 -1
- 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 +1 -1
- package/es2015/plugins/highlight-signature/highlight-signature.min.js +1 -1
- 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/image-editor-pro/image-editor-pro.css +1 -1
- package/es2015/plugins/image-editor-pro/image-editor-pro.js +1 -1
- package/es2015/plugins/image-editor-pro/image-editor-pro.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/style/style.css +1 -1
- package/es2015/plugins/style/style.js +1 -1
- package/es2015/plugins/style/style.min.js +1 -1
- package/es2015/plugins/templates/templates.css +1 -1
- package/es2015/plugins/templates/templates.js +1 -1
- package/es2015/plugins/templates/templates.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.fat.min.js +5 -5
- package/es2018/jodit.min.js +5 -5
- package/es2018/plugins/ai-assistant-pro/ai-assistant-pro.min.js +1 -1
- package/es2018/plugins/autocomplete/autocomplete.min.js +1 -1
- package/es2018/plugins/backup/backup.min.js +1 -1
- package/es2018/plugins/button-generator/button-generator.min.js +1 -1
- package/es2018/plugins/change-case/change-case.min.js +1 -1
- package/es2018/plugins/color-picker/color-picker.min.js +1 -1
- package/es2018/plugins/emoji/emoji.min.js +1 -1
- package/es2018/plugins/export-docs/export-docs.min.js +1 -1
- package/es2018/plugins/finder/finder.min.js +1 -1
- package/es2018/plugins/google-maps/google-maps.min.js +1 -1
- package/es2018/plugins/google-search/google-search.min.js +1 -1
- package/es2018/plugins/highlight-signature/highlight-signature.min.js +1 -1
- package/es2018/plugins/iframe-editor/iframe-editor.min.js +1 -1
- package/es2018/plugins/image-editor-pro/image-editor-pro.min.js +1 -1
- package/es2018/plugins/keyboard/keyboard.min.js +1 -1
- package/es2018/plugins/mobile-view/mobile-view.min.js +1 -1
- package/es2018/plugins/page-break/page-break.min.js +1 -1
- package/es2018/plugins/paste-code/paste-code.min.js +1 -1
- package/es2018/plugins/paste-from-word/paste-from-word.min.js +1 -1
- package/es2018/plugins/show-blocks/show-blocks.min.js +1 -1
- package/es2018/plugins/style/style.min.js +1 -1
- package/es2018/plugins/templates/templates.min.js +1 -1
- package/es2018/plugins/todo-list/todo-list.min.js +1 -1
- package/es2018/plugins/translate/translate.min.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 +8 -8
- package/es2021/jodit.js +199 -109
- package/es2021/jodit.min.js +8 -8
- package/es2021/plugins/ai-assistant-pro/ai-assistant-pro.css +1 -1
- package/es2021/plugins/ai-assistant-pro/ai-assistant-pro.js +1 -1
- package/es2021/plugins/ai-assistant-pro/ai-assistant-pro.min.js +1 -1
- package/es2021/plugins/autocomplete/autocomplete.css +1 -1
- 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 +1 -1
- package/es2021/plugins/highlight-signature/highlight-signature.min.js +1 -1
- 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/image-editor-pro/image-editor-pro.css +1 -1
- package/es2021/plugins/image-editor-pro/image-editor-pro.js +1 -1
- package/es2021/plugins/image-editor-pro/image-editor-pro.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/style/style.css +1 -1
- package/es2021/plugins/style/style.js +1 -1
- package/es2021/plugins/style/style.min.js +1 -1
- package/es2021/plugins/templates/templates.css +1 -1
- package/es2021/plugins/templates/templates.js +1 -1
- package/es2021/plugins/templates/templates.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 +8 -8
- package/es2021.en/jodit.js +199 -109
- package/es2021.en/jodit.min.js +8 -8
- package/es2021.en/plugins/ai-assistant-pro/ai-assistant-pro.css +1 -1
- package/es2021.en/plugins/ai-assistant-pro/ai-assistant-pro.js +1 -1
- package/es2021.en/plugins/ai-assistant-pro/ai-assistant-pro.min.js +1 -1
- package/es2021.en/plugins/autocomplete/autocomplete.css +1 -1
- 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 +1 -1
- package/es2021.en/plugins/highlight-signature/highlight-signature.min.js +1 -1
- 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/image-editor-pro/image-editor-pro.css +1 -1
- package/es2021.en/plugins/image-editor-pro/image-editor-pro.js +1 -1
- package/es2021.en/plugins/image-editor-pro/image-editor-pro.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/style/style.css +1 -1
- package/es2021.en/plugins/style/style.js +1 -1
- package/es2021.en/plugins/style/style.min.js +1 -1
- package/es2021.en/plugins/templates/templates.css +1 -1
- package/es2021.en/plugins/templates/templates.js +1 -1
- package/es2021.en/plugins/templates/templates.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 +216 -113
- package/es5/jodit.min.css +2 -2
- package/es5/jodit.min.js +2 -2
- package/es5/plugins/ai-assistant-pro/ai-assistant-pro.css +1 -1
- package/es5/plugins/ai-assistant-pro/ai-assistant-pro.js +1 -1
- package/es5/plugins/ai-assistant-pro/ai-assistant-pro.min.js +1 -1
- package/es5/plugins/autocomplete/autocomplete.css +1 -1
- 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 +1 -1
- package/es5/plugins/highlight-signature/highlight-signature.min.js +1 -1
- 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/image-editor-pro/image-editor-pro.css +1 -1
- package/es5/plugins/image-editor-pro/image-editor-pro.js +1 -1
- package/es5/plugins/image-editor-pro/image-editor-pro.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/style/style.css +1 -1
- package/es5/plugins/style/style.js +1 -1
- package/es5/plugins/style/style.min.js +1 -1
- package/es5/plugins/templates/templates.css +1 -1
- package/es5/plugins/templates/templates.js +1 -1
- package/es5/plugins/templates/templates.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/es5/polyfills.fat.min.js +1 -1
- package/es5/polyfills.js +1 -1
- package/es5/polyfills.min.js +1 -1
- package/package.json +1 -1
package/es2021/jodit.fat.min.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* jodit-pro - PRO Version of Jodit Editor
|
|
3
3
|
* Author: Chupurnov Valerii <chupurnov@gmail.com>
|
|
4
|
-
* Version: v4.13.
|
|
4
|
+
* Version: v4.13.37
|
|
5
5
|
* Url: https://xdsoft.net/jodit/pro/
|
|
6
6
|
* License(s): SEE LICENSE IN LICENSE.md
|
|
7
7
|
*/
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
*/.a-color-picker{background-color:#fff;padding:0;display:inline-flex;flex-direction:column;user-select:none;width:232px;font:400 10px Helvetica,Arial,sans-serif;border-radius:3px;box-shadow:0 0 0 1px rgba(0,0,0,.05),0 2px 4px rgba(0,0,0,.25)}.a-color-picker,.a-color-picker-row,.a-color-picker input{box-sizing:border-box}.a-color-picker-row{padding:15px;display:flex;flex-direction:row;align-items:center;justify-content:space-between;user-select:none}.a-color-picker-row-top{padding:0}.a-color-picker-row:not(:first-child){border-top:1px solid #f5f5f5}.a-color-picker-column{display:flex;flex-direction:column}.a-color-picker-cell{flex:1 1 auto;margin-bottom:4px}.a-color-picker-cell:last-child{margin-bottom:0}.a-color-picker-stack{position:relative}.a-color-picker-dot{position:absolute;width:14px;height:14px;top:0;left:0;background:#fff;pointer-events:none;border-radius:50px;z-index:1000;box-shadow:0 1px 2px rgba(0,0,0,.75)}.a-color-picker-a,.a-color-picker-h,.a-color-picker-sl{cursor:cell}.a-color-picker-a+.a-color-picker-dot,.a-color-picker-h+.a-color-picker-dot{top:-2px}.a-color-picker-a,.a-color-picker-h{border-radius:2px}.a-color-picker-preview{box-sizing:border-box;width:30px;height:30px;user-select:none;border-radius:15px}.a-color-picker-circle{border-radius:50px;border:1px solid #eee}.a-color-picker-hsl,.a-color-picker-rgb,.a-color-picker-single-input{justify-content:space-evenly}.a-color-picker-hsl>label,.a-color-picker-rgb>label,.a-color-picker-single-input>label{padding:0 8px;flex:0 0 auto;color:#969696}.a-color-picker-hsl>input,.a-color-picker-rgb>input,.a-color-picker-single-input>input{text-align:center;padding:2px 0;width:0;flex:1 1 auto;border:1px solid #e0e0e0;line-height:20px}.a-color-picker-hsl>input::-webkit-inner-spin-button,.a-color-picker-rgb>input::-webkit-inner-spin-button,.a-color-picker-single-input>input::-webkit-inner-spin-button{-webkit-appearance:none;margin:0}.a-color-picker-hsl>input:focus,.a-color-picker-rgb>input:focus,.a-color-picker-single-input>input:focus{border-color:#04a9f4;outline:none}.a-color-picker-transparent{background-image:linear-gradient(-45deg,#cdcdcd 25%,transparent 0),linear-gradient(45deg,#cdcdcd 25%,transparent 0),linear-gradient(-45deg,transparent 75%,#cdcdcd 0),linear-gradient(45deg,transparent 75%,#cdcdcd 0);background-size:11px 11px;background-position:0 0,0 -5.5px,-5.5px 5.5px,5.5px 0}.a-color-picker-sl{border-radius:3px 3px 0 0}.a-color-picker.hide-alpha [show-on-alpha],.a-color-picker.hide-hsl [show-on-hsl],.a-color-picker.hide-rgb [show-on-rgb],.a-color-picker.hide-single-input [show-on-single-input]{display:none}.a-color-picker-clipbaord{width:100%;height:100%;opacity:0;cursor:pointer}.a-color-picker-palette{flex-flow:wrap;flex-direction:row;justify-content:flex-start;padding:10px}.a-color-picker-palette-color{width:15px;height:15px;flex:0 1 15px;margin:3px;box-sizing:border-box;cursor:pointer;border-radius:3px;box-shadow:inset 0 0 0 1px rgba(0,0,0,.1)}.a-color-picker-palette-add{text-align:center;line-height:13px;color:#607d8b}.a-color-picker.hidden{display:none}`,""])},function(t,i){t.exports=function(t){var i=[];return i.toString=function(){return this.map(function(i){var n=function(t,i){var n=t[1]||"",o=t[3];if(!o)return n;if(i&&"function"==typeof btoa){var r="/*# sourceMappingURL=data:application/json;charset=utf-8;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(o))))+" */";return[n].concat(o.sources.map(function(t){return"/*# sourceURL="+o.sourceRoot+t+" */"})).concat([r]).join(`
|
|
15
15
|
`)}return[n].join(`
|
|
16
16
|
`)}(i,t);return i[2]?"@media "+i[2]+"{"+n+"}":n}).join("")},i.i=function(t,n){"string"==typeof t&&(t=[[null,t,""]]);for(var o={},r=0;r<this.length;r++){var s=this[r][0];"number"==typeof s&&(o[s]=!0)}for(r=0;r<t.length;r++){var a=t[r];"number"==typeof a[0]&&o[a[0]]||(n&&!a[2]?a[2]=n:n&&(a[2]="("+a[2]+") and ("+n+")"),i.push(a))}},i}}],i={};function n(o){if(i[o])return i[o].exports;var r=i[o]={i:o,l:!1,exports:{}};return t[o].call(r.exports,r,r.exports,n),r.l=!0,r.exports}return n.m=t,n.c=i,n.d=function(t,i,o){n.o(t,i)||Object.defineProperty(t,i,{enumerable:!0,get:o})},n.r=function(t){"u">typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,i){if(1&i&&(t=n(t)),8&i||4&i&&"object"==typeof t&&t&&t.__esModule)return t;var o=Object.create(null);if(n.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:t}),2&i&&"string"!=typeof t)for(var r in t)n.d(o,r,(function(i){return t[i]}).bind(null,r));return o},n.n=function(t){var i=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(i,"a",i),i},n.o=function(t,i){return Object.prototype.hasOwnProperty.call(t,i)},n.p="",n(n.s=1)}()},6441:function(t,i,n){"use strict";n.d(i,{Config:function(){return s}});var o=n(82758);let r={};class s{static get defaultOptions(){return s.__defaultOptions||(s.__defaultOptions=new s),s.__defaultOptions}constructor(){this.cache=!0,this.defaultTimeout=100,this.namespace="",this.safeMode=!1,this.width="auto",this.height="auto",this.safePluginsList=["about","enter","backspace","size","bold","hotkeys"],this.license="",this.preset="custom",this.presets={inline:{inline:!0,toolbar:!1,toolbarInline:!0,toolbarInlineForSelection:!0,showXPathInStatusbar:!1,showCharsCounter:!1,showWordsCounter:!1,showPlaceholder:!1}},this.ownerDocument=o.globalDocument,this.ownerWindow=o.globalWindow,this.shadowRoot=null,this.nonce="",this.zIndex=0,this.readonly=!1,this.disabled=!1,this.activeButtonsInReadOnly=["source","fullsize","print","about","dots","selectall"],this.allowCommandsInReadOnly=["selectall","preview","print"],this.toolbarButtonSize="middle",this.allowTabNavigation=!1,this.inline=!1,this.theme="default",this.saveModeInStorage=!1,this.asyncStorage={},this.editorClassName=!1,this.className=!1,this.style=!1,this.containerStyle=!1,this.styleValues={},this.triggerChangeEvent=!0,this.direction="",this.language="auto",this.debugLanguage=!1,this.i18n=!1,this.tabIndex=-1,this.toolbar=!0,this.statusbar=!0,this.showTooltip=!0,this.showTooltipDelay=200,this.useNativeTooltip=!1,this.defaultActionOnPaste=o.INSERT_AS_HTML,this.enter=o.PARAGRAPH,this.iframe=!1,this.editHTMLDocumentMode=!1,this.enterBlock="br"!==this.enter?this.enter:o.PARAGRAPH,this.defaultMode=o.MODE_WYSIWYG,this.useSplitMode=!1,this.colors={greyscale:["#000000","#434343","#666666","#999999","#B7B7B7","#CCCCCC","#D9D9D9","#EFEFEF","#F3F3F3","#FFFFFF"],palette:["#980000","#FF0000","#FF9900","#FFFF00","#00F0F0","#00FFFF","#4A86E8","#0000FF","#9900FF","#FF00FF"],full:["#E6B8AF","#F4CCCC","#FCE5CD","#FFF2CC","#D9EAD3","#D0E0E3","#C9DAF8","#CFE2F3","#D9D2E9","#EAD1DC","#DD7E6B","#EA9999","#F9CB9C","#FFE599","#B6D7A8","#A2C4C9","#A4C2F4","#9FC5E8","#B4A7D6","#D5A6BD","#CC4125","#E06666","#F6B26B","#FFD966","#93C47D","#76A5AF","#6D9EEB","#6FA8DC","#8E7CC3","#C27BA0","#A61C00","#CC0000","#E69138","#F1C232","#6AA84F","#45818E","#3C78D8","#3D85C6","#674EA7","#A64D79","#85200C","#990000","#B45F06","#BF9000","#38761D","#134F5C","#1155CC","#0B5394","#351C75","#733554","#5B0F00","#660000","#783F04","#7F6000","#274E13","#0C343D","#1C4587","#073763","#20124D","#4C1130"]},this.colorPickerDefaultTab="background",this.imageDefaultWidth=300,this.removeButtons=[],this.disablePlugins=[],this.extraPlugins=[],this.extraButtons=[],this.extraIcons={},this.createAttributes={table:{style:"border-collapse:collapse;width: 100%;"}},this.sizeLG=900,this.sizeMD=700,this.sizeSM=400,this.buttons=[{group:"font-style",buttons:[]},{group:"list",buttons:[]},{group:"font",buttons:[]},"---",{group:"script",buttons:[]},{group:"media",buttons:[]},`
|
|
17
|
-
`,{group:"state",buttons:[]},{group:"clipboard",buttons:[]},{group:"insert",buttons:[]},{group:"indent",buttons:[]},{group:"color",buttons:[]},{group:"form",buttons:[]},"---",{group:"history",buttons:[]},{group:"search",buttons:[]},{group:"source",buttons:[]},{group:"other",buttons:[]},{group:"info",buttons:[]}],this.events={},this.textIcons=!1,this.popupRoot=null,this.showBrowserColorPicker=!0,Object.assign(this,r)}}r=s.prototype,s.prototype.controls={}},26992:function(t,i,n){"use strict";n.d(i,{Async:function(){return m}});var o=n(82758),r=n(91898),s=n(12045),a=n(23282),l=n(84767),c=n(72430),d=n(14773),u=n(70799),h=n(86068),p=n(38837),f=n(93661);class m{delay(t){return this.promise(i=>this.setTimeout(i,t))}setTimeout(t,i,...n){if(this.isDestructed)return 0;let o={};(0,h.isVoid)(i)&&(i=0),(0,l.isNumber)(i)||(i=(o=i).timeout||0),o.label&&this.clearLabel(o.label);let s=(0,r.setTimeout)(t,i,...n),a=o.label||s;return this.timers.set(a,s),this.__callbacks.set(a,t),s}updateTimeout(t,i){if((0,p.assert)(t&&this.timers.has(t),"Label does not exist"),!t||!this.timers.has(t))return null;let n=this.__callbacks.get(t);return(0,p.assert)((0,a.isFunction)(n),"Callback is not a function"),this.setTimeout(n,{label:t,timeout:i})}clearLabel(t){t&&this.timers.has(t)&&((0,r.clearTimeout)(this.timers.get(t)),this.timers.delete(t),this.__callbacks.delete(t))}clearTimeout(t){if((0,u.isString)(t))return this.clearLabel(t);(0,r.clearTimeout)(t),this.timers.delete(t),this.__callbacks.delete(t)}debounce(t,i,n=!1){let o=0,l=!1,u=[],h=(...i)=>{if(!l){o=0;let n=t(...i);if(l=!0,u.length){let t=()=>{u.forEach(t=>t()),u.length=0};(0,d.isPromise)(n)?n.finally(t):t()}}},p=(...s)=>{l=!1,i?(!o&&n&&h(...s),(0,r.clearTimeout)(o),o=this.setTimeout(()=>h(...s),(0,a.isFunction)(i)?i():i),this.timers.set(t,o)):h(...s)};return(0,c.isPlainObject)(i)&&i.promisify?(...t)=>{let i=this.promise(t=>{u.push(t)}).catch(t=>{if((0,s.isAbortError)(t))return null;throw t});return p(...t),i}:p}microDebounce(t,i=!1){let n,o=!1,r=!0;return(...s)=>{if(n=s,o){r=!0;return}r=!0,i&&(r=!1,t(...n)),o=!0,this.__queueMicrotaskNative(()=>{o=!1,!this.isDestructed&&r&&t(...n)})}}throttle(t,i,n=!1){let o=null,r,s,l;return(...n)=>{(r=!0,l=n,i)?o||(s=()=>{r?(t(...l),r=!1,o=this.setTimeout(s,(0,a.isFunction)(i)?i():i),this.timers.set(s,o)):o=null})():t(...l)}}promise(t){let i=()=>{},n=new Promise((n,o)=>{i=()=>o((0,f.abort)("Abort async")),this.promisesRejections.add(i),t(n,o)});return!n.finally&&"u">typeof process&&!o.IS_ES_NEXT&&(n.finally=t=>(n.then(t).catch(t),n)),n.finally(()=>{this.promisesRejections.delete(i)}).catch(()=>null),n.rejectCallback=i,n}promiseState(t){if(t.status)return t.status;if(!Promise.race)return new Promise(i=>{t.then(t=>(i("fulfilled"),t),t=>{throw i("rejected"),t}),this.setTimeout(()=>{i("pending")},100)});let i={};return Promise.race([t,i]).then(t=>t===i?"pending":"fulfilled",()=>"rejected")}requestIdleCallback(t,i={timeout:100}){let n=this.__requestIdleCallbackNative(t,i);return this.__requestsIdle.add(n),n}requestIdlePromise(t){return this.promise(i=>{let n=this.requestIdleCallback(()=>i(n),t)})}schedulerPostTask(t,i={delay:0,priority:"user-visible"}){let n=new AbortController;if(i.signal&&i.signal.addEventListener("abort",()=>n.abort()),this.__controllers.add(n),void 0!==globalThis.scheduler){let o=globalThis.scheduler.postTask(t,{...i,signal:n.signal});return o.finally(()=>{this.__controllers.delete(n)}).catch(()=>null),o}return this.promise((o,r)=>{let s=this.setTimeout(()=>{try{o(t())}catch(t){r(t)}this.__controllers.delete(n)},i.delay||1);n.signal.addEventListener("abort",()=>{this.clearTimeout(s),this.__controllers.delete(n),r((0,f.abort)())})})}schedulerYield(){return this.schedulerPostTask(()=>{},{priority:"user-visible"})}cancelIdleCallback(t){return this.__requestsIdle.delete(t),this.__cancelIdleCallbackNative(t)}requestAnimationFrame(t){let i=requestAnimationFrame(t);return this.__requestsRaf.add(i),i}cancelAnimationFrame(t){this.__requestsRaf.delete(t),cancelAnimationFrame(t)}clear(){this.__requestsIdle.forEach(t=>this.cancelIdleCallback(t)),this.__requestsRaf.forEach(t=>this.cancelAnimationFrame(t)),this.__controllers.forEach(t=>t.abort()),this.timers.forEach(t=>(0,r.clearTimeout)(this.timers.get(t))),this.timers.clear(),this.promisesRejections.forEach(t=>t()),this.promisesRejections.clear()}destruct(){this.clear(),this.isDestructed=!0}constructor(){var t,i,n,o,r;this.timers=new Map,this.__callbacks=new Map,this.__queueMicrotaskNative=null!=(t=null==queueMicrotask?void 0:queueMicrotask.bind(window))?t:Promise.resolve().then.bind(Promise.resolve()),this.promisesRejections=new Set,this.__requestsIdle=new Set,this.__controllers=new Set,this.__requestsRaf=new Set,this.__requestIdleCallbackNative=null!=(n=null==(i=window.requestIdleCallback)?void 0:i.bind(window))?n:(t,i)=>{var n;let o=Date.now();return this.setTimeout(()=>{t({didTimeout:!1,timeRemaining:()=>Math.max(0,50-(Date.now()-o))})},null!=(n=null==i?void 0:i.timeout)?n:1)},this.__cancelIdleCallbackNative=null!=(r=null==(o=window.cancelIdleCallback)?void 0:o.bind(window))?r:t=>{this.clearTimeout(t)},this.isDestructed=!1}}},8884:function(t,i,n){"use strict";n.d(i,{Async:function(){return o.Async}});var o=n(26992)},4012:function(t,i,n){"use strict";n.d(i,{Component:function(){return c}});var o=n(8884),r=n(78213),s=n(580),a=n(21537);let l=new Map;class c{get componentName(){return this.__componentName||(this.__componentName="jodit-"+(0,a.kebabCase)(((0,a.isFunction)(this.className)?this.className():"")||(0,a.getClassName)(this))),this.__componentName}getFullElName(t,i,n){let o=[this.componentName];return t&&o.push("__"+(t=t.replace(/[^a-z0-9-]/gi,"-"))),i&&(o.push("_",i),o.push("_",(0,a.isVoid)(n)?"true":n.toString())),o.join("")}get ownerDocument(){return this.ow.document}get od(){return this.ownerDocument}get ow(){return this.ownerWindow}get(t,i){return(0,a.get)(t,i||this)}get isReady(){return this.componentStatus===r.STATUSES.ready}get isDestructed(){return this.componentStatus===r.STATUSES.destructed}get isInDestruct(){return r.STATUSES.beforeDestruct===this.componentStatus||r.STATUSES.destructed===this.componentStatus}bindDestruct(t){return t.hookStatus(r.STATUSES.beforeDestruct,()=>!this.isInDestruct&&this.destruct()),this}destruct(){this.setStatus(r.STATUSES.destructed),this.async&&(this.async.destruct(),this.async=void 0),l.get(this)&&l.delete(this),this.ownerWindow=void 0}get componentStatus(){return this.__componentStatus}set componentStatus(t){this.setStatus(t)}setStatus(t){return this.setStatusComponent(t,this)}setStatusComponent(t,i){if(t===this.__componentStatus)return;i===this&&(this.__componentStatus=t);let n=Object.getPrototypeOf(this);n&&(0,a.isFunction)(n.setStatusComponent)&&n.setStatusComponent(t,i);let o=l.get(this),r=null==o?void 0:o[t];r&&r.length&&r.forEach(t=>t(i))}hookStatus(t,i){let n=l.get(this);n||(n={},l.set(this,n)),n[t]||(n[t]=[]),n[t].push(i)}static isInstanceOf(t,i){return t instanceof i}constructor(){this.async=new o.Async,this.ownerWindow=window,this.__componentStatus=r.STATUSES.beforeInit,this.uid="jodit-uid-"+(0,s.uniqueUid)()}}c.STATUSES=r.STATUSES},91907:function(t,i,n){"use strict";n.d(i,{Component:function(){return o.Component},STATUSES:function(){return r.STATUSES},ViewComponent:function(){return s.ViewComponent}});var o=n(4012),r=n(78213),s=n(80480)},78213:function(t,i,n){"use strict";n.d(i,{STATUSES:function(){return o}});let o={beforeInit:"beforeInit",ready:"ready",beforeDestruct:"beforeDestruct",destructed:"destructed"}},80480:function(t,i,n){"use strict";n.d(i,{ViewComponent:function(){return r}});var o=n(4012);class r extends o.Component{get j(){return this.jodit}get defaultTimeout(){return this.j.defaultTimeout}i18n(t,...i){return this.j.i18n(t,...i)}setParentView(t){return this.jodit=t,t.ow&&(this.ownerWindow=t.ow),t.components.add(this),this}destruct(){return this.j.components.delete(this),super.destruct()}constructor(t){super(),this.setParentView(t)}}},82758:function(t,i,n){"use strict";n.r(i),n.d(i,{ACCURACY:function(){return W},APP_VERSION:function(){return o},BASE_PATH:function(){return ef},BASE_PATH_IS_MIN:function(){return em},BR:function(){return G},CLIPBOARD_ID:function(){return ev},COMMAND_KEYS:function(){return $},EMULATE_DBLCLICK_TIMEOUT:function(){return en},ES:function(){return r},FAT_MODE:function(){return d},HOMEPAGE:function(){return u},INSEPARABLE_TAGS:function(){return j},INSERT_AS_HTML:function(){return eo},INSERT_AS_TEXT:function(){return es},INSERT_CLEAR_HTML:function(){return er},INSERT_ONLY_TEXT:function(){return ea},INVISIBLE_SPACE:function(){return f},INVISIBLE_SPACE_REG_EXP:function(){return g},INVISIBLE_SPACE_REG_EXP_END:function(){return b},INVISIBLE_SPACE_REG_EXP_START:function(){return y},IS_BLOCK:function(){return x},IS_ES_MODERN:function(){return s},IS_ES_NEXT:function(){return a},IS_IE:function(){return Z},IS_INLINE:function(){return I},IS_MAC:function(){return ec},IS_PROD:function(){return l},IS_TEST:function(){return c},KEY_ALIASES:function(){return ed},KEY_ALT:function(){return z},KEY_BACKSPACE:function(){return L},KEY_DELETE:function(){return U},KEY_DOWN:function(){return F},KEY_ENTER:function(){return M},KEY_ESC:function(){return R},KEY_F3:function(){return q},KEY_LEFT:function(){return B},KEY_META:function(){return P},KEY_RIGHT:function(){return O},KEY_SPACE:function(){return H},KEY_TAB:function(){return D},KEY_UP:function(){return N},LIST_TAGS:function(){return E},MARKER_CLASS:function(){return ei},MODE_SOURCE:function(){return J},MODE_SPLIT:function(){return X},MODE_WYSIWYG:function(){return Y},NBSP_SPACE:function(){return m},NEARBY:function(){return V},NO_EMPTY_TAGS:function(){return A},PARAGRAPH:function(){return K},PASSIVE_EVENTS:function(){return ew},SAFE_COUNT_CHANGE_CALL:function(){return el},SET_TEST:function(){return h},SOURCE_CONSUMER:function(){return ey},SPACE_REG_EXP:function(){return w},SPACE_REG_EXP_END:function(){return C},SPACE_REG_EXP_START:function(){return _},TEMP_ATTR:function(){return eg},TEXT_HTML:function(){return ee},TEXT_PLAIN:function(){return Q},TEXT_RTF:function(){return et},TOKENS:function(){return p},globalDocument:function(){return S},globalWindow:function(){return k},lang:function(){return eb}});let o="4.13.35",r="es2021",s=!0,a=!0,l=!0,c=!1,d=!0,u="https://xdsoft.net/jodit/pro/",h=()=>c=!0,p={},f="\uFEFF",m=" ",g=()=>/[\uFEFF]/g,b=()=>/[\uFEFF]+$/g,y=()=>/^[\uFEFF]+/g,w=()=>/[\s\n\t\r\uFEFF\u200b]+/g,_=()=>/^[\s\n\t\r\uFEFF\u200b]+/g,C=()=>/[\s\n\t\r\uFEFF\u200b]+$/g,k="u">typeof window?window:void 0,S="u">typeof document?document:void 0,x=/^(ADDRESS|ARTICLE|ASIDE|BLOCKQUOTE|CANVAS|DD|DFN|DIV|DL|DT|FIELDSET|FIGCAPTION|FIGURE|FOOTER|FORM|H[1-6]|HEADER|HGROUP|HR|LI|MAIN|NAV|NOSCRIPT|OUTPUT|P|PRE|RUBY|SCRIPT|STYLE|OBJECT|OL|SECTION|IFRAME|JODIT|JODIT-MEDIA|UL|TR|TD|TH|TBODY|THEAD|TFOOT|TABLE|BODY|HTML|VIDEO)$/i,I=/^(STRONG|SPAN|I|EM|B|SUP|SUB|A|U)$/i,E=new Set(["ul","ol"]),T=["img","video","svg","iframe","script","input","textarea","link","jodit","jodit-media"],j=new Set([...T,"br","hr"]),A=new Set(T),P="Meta",L="Backspace",D="Tab",M="Enter",R="Escape",z="Alt",B="ArrowLeft",N="ArrowUp",O="ArrowRight",F="ArrowDown",H="Space",U="Delete",q="F3",V=5,W=10,$=[P,L,U,N,F,O,B,M,R,q,D],G="br",K="p",Y=1,J=2,X=3,Z="u">typeof navigator&&(-1!==navigator.userAgent.indexOf("MSIE")||/rv:11.0/i.test(navigator.userAgent)),Q=Z?"text":"text/plain",ee=Z?"html":"text/html",et=Z?"rtf":"text/rtf",ei="jodit-selection_marker",en=300,eo="insert_as_html",er="insert_clear_html",es="insert_as_text",ea="insert_only_text",el=10,ec=void 0!==k&&/Mac|iPod|iPhone|iPad/.test(k.navigator.platform),ed={add:"+",break:"pause",cmd:"meta",command:"meta",ctl:"control",ctrl:"control",del:"delete",down:"arrowdown",esc:"escape",ins:"insert",left:"arrowleft",mod:ec?"meta":"control",opt:"alt",option:"alt",return:"enter",right:"arrowright",space:"space",spacebar:"space",up:"arrowup",win:"meta",windows:"meta"},eu=t=>{let i=t.split("/");return/\.js/.test(i[i.length-1])?{basePath:i.slice(0,i.length-1).join("/")+"/",isMin:!0}:{basePath:t,isMin:!0}},{basePath:eh,isMin:ep}=(()=>{if("u"<typeof document)return{basePath:"",isMin:!0};let t=S.currentScript;if(t)return eu(t.src);let i=S.querySelectorAll("script[src]");return i&&i.length?eu(i[i.length-1].src):eu(k.location.href)})(),ef=eh,em=ep,eg="data-jodit-temp",eb={},ev="clipboard",ey="source-consumer",ew=new Set(["touchstart","touchend","scroll","mousewheel","mousemove","touchmove"])},20218:function(t,i,n){"use strict";n.d(i,{Create:function(){return l}});var o=n(82758),r=n(2748),s=n(21537),a=n(38837);class l{get doc(){return(0,s.isFunction)(this.document)?this.document():this.document}element(t,i,n){let o=this.doc.createElement(t.toLowerCase());return this.applyCreateAttributes(o),i&&((0,s.isPlainObject)(i)?(0,s.attr)(o,i):n=i),n&&(0,s.asArray)(n).forEach(t=>o.appendChild((0,s.isString)(t)?this.fromHTML(t):t)),o}div(t,i,n){let o=this.element("div",i,n);return t&&(o.className=t),o}sandbox(){var t;let i=this.element("iframe",{sandbox:"allow-same-origin"});this.doc.body.appendChild(i);let n=null==(t=i.contentWindow)?void 0:t.document;if((0,a.assert)(n,"iframe.contentWindow.document"),!n)throw Error("Iframe error");return n.open(),n.write("<!DOCTYPE html><html><head></head><body></body></html>"),n.close(),[n.body,i]}span(t,i,n){let o=this.element("span",i,n);return t&&(o.className=t),o}a(t,i,n){let o=this.element("a",i,n);return t&&(o.className=t),o}text(t){return this.doc.createTextNode(t)}fake(){return this.text(o.INVISIBLE_SPACE)}fragment(){return this.doc.createDocumentFragment()}fromHTML(t,i){let n=this.div();n.innerHTML=t.toString();let o=n.firstChild===n.lastChild&&n.firstChild?n.firstChild:n;if(r.Dom.safeRemove(o),i){let t=(0,s.refs)(o);Object.keys(i).forEach(n=>{let o=t[n];o&&!1===i[n]&&r.Dom.hide(o)})}return o}applyCreateAttributes(t){if(this.createAttributes){let i=this.createAttributes;if(i&&i[t.tagName.toLowerCase()]){let n=i[t.tagName.toLowerCase()];(0,s.isFunction)(n)?n(t):(0,s.isPlainObject)(n)&&(0,s.attr)(t,n)}}}constructor(t,i){this.document=t,this.createAttributes=i}}},12060:function(t,i,n){"use strict";n.d(i,{Create:function(){return o.Create}});var o=n(20218)},45219:function(t,i,n){"use strict";n.d(i,{autobind:function(){return r}});var o=n(23282);function r(t,i,n){if(!(0,o.isFunction)(n.value))throw TypeError(`@autobind can only be applied to methods, but "${i}" is not a function`);let r=n.value;return{configurable:!0,get(){let t=r.bind(this);return Object.defineProperty(this,i,{value:t,configurable:!0,writable:!0}),t}}}},33433:function(t,i,n){"use strict";n.d(i,{cache:function(){return c},cacheHTML:function(){return d},cached:function(){return l}});var o=n(78213),r=n(2748),s=n(27613),a=n(82760);function l(t,i){let n=Object.getOwnPropertyDescriptor(t,i);return!n||(0,s.isFunction)(n.get)?null:n.value}function c(t,i,n){let o=n.get;if(!o)throw(0,a.error)("Getter property descriptor expected");n.get=function(){let t=o.call(this);return t&&!0===t.noCache||Object.defineProperty(this,i,{configurable:n.configurable,enumerable:n.enumerable,writable:!1,value:t}),t}}function d(t,i,n){let l=n.value;if(!(0,s.isFunction)(l))throw(0,a.error)("Handler must be a Function");let c=!0,d=new WeakMap;n.value=function(...t){var i;if(c&&d.has(this.constructor))return null==(i=d.get(this.constructor))?void 0:i.cloneNode(!0);let n=l.apply(this,t);return c&&r.Dom.isElement(n)&&d.set(this.constructor,n),c?n.cloneNode(!0):n},t.hookStatus(o.STATUSES.ready,t=>{c=!!((0,s.isViewObject)(t)?t:t.jodit).options.cache})}},87325:function(t,i,n){"use strict";n.d(i,{component:function(){return a},getComponentClass:function(){return l}});var o=n(82758),r=n(80568);let s=new Map;function a(t){class i extends t{constructor(...t){super(...t),this.constructor===i&&(this instanceof i||Object.setPrototypeOf(this,i.prototype),this.setStatus("ready"))}}let n=(0,r.getClassName)(t.prototype);if(s.has(n)&&!o.IS_PROD)throw Error(`Component with name "${n}" is already registered`);return s.set(n,i),i}function l(t){return s.get(t)}},81577:function(t,i,n){"use strict";n.d(i,{debounce:function(){return l},throttle:function(){return c}});var o=n(91907),r=n(27613),s=n(38837),a=n(89890);function l(t,i=!1,n="debounce"){return(l,c)=>{let d=l[c];if(!(0,r.isFunction)(d))throw(0,a.error)("Handler must be a Function");return l.hookStatus(o.STATUSES.ready,o=>{let{async:a}=o;(0,s.assert)(null!=a,`Component ${o.componentName||o.constructor.name} should have "async:IAsync" field`);let l=(0,r.isFunction)(t)?t(o):t,d=(0,r.isNumber)(l)||(0,r.isPlainObject)(l)?l:o.defaultTimeout;Object.defineProperty(o,c,{configurable:!0,value:a[n](o[c].bind(o),d,i)})}),{configurable:!0,get(){return d.bind(this)}}}}function c(t,i=!1){return l(t,i,"throttle")}},55153:function(t,i,n){"use strict";n.d(i,{derive:function(){return r}});var o=n(23282);function r(...t){return i=>{let n=i.prototype;for(let i=0;i<t.length;i++){let r=t[i],s=Object.getOwnPropertyNames(r.prototype);for(let t=0;t<s.length;t++){let i=s[t],a=Object.getOwnPropertyDescriptor(r.prototype,i);null!=a&&(0,o.isFunction)(a.value)&&!(0,o.isFunction)(n[i])&&Object.defineProperty(n,i,{enumerable:!0,configurable:!0,writable:!0,value:function(...t){return a.value.call(this,...t)}})}}}}},97357:function(t,i,n){"use strict";n.d(i,{hook:function(){return s}});var o=n(23282),r=n(89890);function s(t){return(i,n)=>{if(!(0,o.isFunction)(i[n]))throw(0,r.error)("Handler must be a Function");i.hookStatus(t,t=>{t[n].call(t)})}}},78927:function(t,i,n){"use strict";n.d(i,{idle:function(){return a}});var o=n(91907),r=n(23282),s=n(89890);function a(){return(t,i)=>{if(!(0,r.isFunction)(t[i]))throw(0,s.error)("Handler must be a Function");t.hookStatus(o.STATUSES.ready,t=>{let{async:n}=t,o=t[i];t[i]=(...i)=>n.requestIdleCallback(o.bind(t,...i))})}}},65478:function(t,i,n){"use strict";n.r(i),n.d(i,{autobind:function(){return o.autobind},cache:function(){return r.cache},cacheHTML:function(){return r.cacheHTML},cached:function(){return r.cached},component:function(){return s.component},debounce:function(){return a.debounce},derive:function(){return l.derive},getComponentClass:function(){return s.getComponentClass},hook:function(){return c.hook},idle:function(){return d.idle},nonenumerable:function(){return u.nonenumerable},persistent:function(){return h.persistent},throttle:function(){return a.throttle},wait:function(){return p.wait},watch:function(){return f.watch}});var o=n(45219),r=n(33433),s=n(87325),a=n(81577),l=n(55153),c=n(97357),d=n(78927),u=n(31589),h=n(53213),p=n(13525),f=n(37133)},31589:function(t,i,n){"use strict";n.d(i,{nonenumerable:function(){return o}});let o=(t,i)=>{!1!==(Object.getOwnPropertyDescriptor(t,i)||{}).enumerable&&Object.defineProperty(t,i,{enumerable:!1,set(t){Object.defineProperty(this,i,{enumerable:!1,writable:!0,value:t})}})}},53213:function(t,i,n){"use strict";n.d(i,{persistent:function(){return s}});var o=n(78213),r=n(39955);function s(t,i){t.hookStatus(o.STATUSES.ready,t=>{let n=(0,r.isViewObject)(t)?t:t.jodit,o=`${n.options.namespace}${t.componentName}_prop_${i}`,s=t[i];Object.defineProperty(t,i,{get(){var t;return null!=(t=n.storage.get(o))?t:s},set(t){n.storage.set(o,t)}})})}},13525:function(t,i,n){"use strict";n.d(i,{wait:function(){return a}});var o=n(78213),r=n(23282),s=n(89890);function a(t){return(i,n)=>{let a=i[n];if(!(0,r.isFunction)(a))throw(0,s.error)("Handler must be a Function");i.hookStatus(o.STATUSES.ready,i=>{let{async:o}=i,r=i[n],s=0;Object.defineProperty(i,n,{configurable:!0,value:function n(...a){o.clearTimeout(s),t(i)?r.apply(i,a):s=o.setTimeout(()=>n(...a),10)}})})}}},37133:function(t,i,n){"use strict";n.d(i,{watch:function(){return h}});var o=n(78213),r=n(73026),s=n(46559),a=n(23282),l=n(72430),c=n(39955),d=n(89890),u=n(37790);function h(t,i){return(n,h)=>{var p;if(!(0,a.isFunction)(n[h]))throw(0,d.error)("Handler must be a Function");let f=null==(p=null==i?void 0:i.immediately)||p,m=null==i?void 0:i.context,g=i=>{let o=(0,c.isViewObject)(i)?i:i.jodit,d=(t,...n)=>{if(!i.isInDestruct)return i[h](t,...n)};f||(d=i.async.microDebounce(d,!0)),(0,s.splitArray)(t).forEach(t=>{if(/:/.test(t)){let[n,r]=t.split(":"),s=m;n.length&&(s=i.get(n)),(0,a.isFunction)(s)&&(s=s(i)),o.events.on(s||i,r,d),s||o.events.on(r,d),i.hookStatus("beforeDestruct",()=>{o.events.off(s||i,r,d).off(r,d)});return}let s=t.split("."),[c]=s,h=s.slice(1),p=i[c];(0,l.isPlainObject)(p)&&(0,r.observable)(p).on("change."+h.join("."),d);let f=(0,u.getPropertyDescriptor)(n,c);Object.defineProperty(i,c,{configurable:!0,set(t){let n=p;n!==t&&(p=t,f&&f.set&&f.set.call(i,t),(0,l.isPlainObject)(p)&&(p=(0,r.observable)(p)).on("change."+h.join("."),d),d(c,n,p))},get:()=>f&&f.get?f.get.call(i):p})})};(0,a.isFunction)(n.hookStatus)?n.hookStatus(o.STATUSES.ready,g):g(n)}}},2748:function(t,i,n){"use strict";n.d(i,{Dom:function(){return _}});var o=n(82758),r=n(4510),s=n(68345),a=n(23282),l=n(58487),c=n(42320),d=n(70799),u=n(86068),h=n(49055),p=n(38837),f=n(29960),m=n(41180),g=n(86583),b=n(89890),y=n(37790);let w=RegExp(`<([a-z]+)[^>]+${o.TEMP_ATTR}[^>]*>(.+?)</\\1>`,"gi");class _{static detach(t){for(;t&&t.firstChild;)t.removeChild(t.firstChild)}static wrapNextInline(t,i,n){let o,r=t;n.s.save();let s=!1;do s=!1,(o=r.nextSibling)&&!_.isBlock(o)&&!_.isTag(o,"br")&&(s=!0,r=o);while(s)return _.__wrapElements(i,n,t,r)}static __wrapElements(t,i,n,o){let r=(0,d.isString)(t)?i.createInside.element(t):t;n.parentNode&&n.parentNode.insertBefore(r,n);let s=n;for(;s&&(s=n.nextSibling,r.appendChild(n),n!==o&&s);)n=s;return i.s.restore(),r}static wrapInline(t,i,n){let o,r=t,s=t;n.s.save();let a=!1;do a=!1,(o=r.previousSibling)&&!_.isBlock(o)&&(a=!0,r=o);while(a)do a=!1,(o=s.nextSibling)&&!_.isBlock(o)&&(a=!0,s=o);while(a)return _.__wrapElements(i,n,r,s)}static wrap(t,i,n){let o=(0,d.isString)(i)?n.element(i):i;if(_.isNode(t)){if(!t.parentNode)throw(0,b.error)("Element should be in DOM");t.parentNode.insertBefore(o,t),o.appendChild(t)}else{let i=t.extractContents();t.insertNode(o),o.appendChild(i)}return o}static unwrap(t){let i=t.parentNode;if(i){for(;t.firstChild;)i.insertBefore(t.firstChild,t);_.safeRemove(t)}}static between(t,i,n){let o=t;for(;o&&o!==i&&!(t!==o&&n(o));){let t=o.firstChild||o.nextSibling;if(!t){for(;o&&!o.nextSibling;)if((o=o.parentNode)===i)return;t=null==o?void 0:o.nextSibling}o=t}}static replace(t,i,n,o=!1,s=!1){let a;if((0,l.isHTML)(i)&&((0,p.assert)(n,"Need create instance for new tag"),i=n.fromHTML(i)),(0,d.isString)(i)?((0,p.assert)(n,"Need create instance for new tag"),a=n.element(i)):a=i,!s)for(;t.firstChild;)a.appendChild(t.firstChild);return o&&_.isElement(t)&&_.isElement(a)&&(0,r.toArray)(t.attributes).forEach(t=>{a.setAttribute(t.name,t.value)}),t.parentNode&&t.parentNode.replaceChild(a,t),a}static isEmptyTextNode(t){return _.isText(t)&&(!t.nodeValue||0===t.nodeValue.replace(o.INVISIBLE_SPACE_REG_EXP(),"").trim().length)}static isEmptyContent(t){return _.each(t,t=>_.isEmptyTextNode(t))}static isContentEditable(t,i){return _.isNode(t)&&!_.closest(t,t=>_.isElement(t)&&"false"===t.getAttribute("contenteditable"),i)}static isEmpty(t,i=o.NO_EMPTY_TAGS){let n;if(!t)return!0;n=(0,a.isFunction)(i)?i:t=>i.has(t.nodeName.toLowerCase());let r=t=>null==t.nodeValue||0===(0,h.trim)(t.nodeValue).length;return _.isText(t)?r(t):!(_.isElement(t)&&n(t))&&_.each(t,t=>{if(_.isText(t)&&!r(t)||_.isElement(t)&&n(t))return!1})}static isNode(t){return!!(t&&(0,d.isString)(t.nodeName)&&"number"==typeof t.nodeType&&t.childNodes&&(0,a.isFunction)(t.appendChild))}static isCell(t){return _.isNode(t)&&("TD"===t.nodeName||"TH"===t.nodeName)}static isList(t){return _.isTag(t,o.LIST_TAGS)}static isLeaf(t){return _.isTag(t,"li")}static isImage(t){return _.isNode(t)&&/^(img|svg|picture|canvas)$/i.test(t.nodeName)}static isBlock(t){return!(0,u.isVoid)(t)&&"object"==typeof t&&_.isNode(t)&&o.IS_BLOCK.test(t.nodeName)}static isText(t){return!!(t&&t.nodeType===Node.TEXT_NODE)}static isComment(t){return!!(t&&t.nodeType===Node.COMMENT_NODE)}static isElement(t){return!!_.isNode(t)&&t.nodeType===Node.ELEMENT_NODE}static isFragment(t){return!!_.isNode(t)&&t.nodeType===Node.DOCUMENT_FRAGMENT_NODE}static isHTMLElement(t){var i;if(!_.isNode(t))return!1;let n=null==(i=t.ownerDocument)?void 0:i.defaultView;return t instanceof(n?n.HTMLElement:HTMLElement)}static isInlineBlock(t){return _.isElement(t)&&!/^(BR|HR)$/i.test(t.tagName)&&-1!==["inline","inline-block"].indexOf((0,m.css)(t,"display").toString())}static canSplitBlock(t){return!(0,u.isVoid)(t)&&_.isHTMLElement(t)&&_.isBlock(t)&&!/^(TD|TH|CAPTION|FORM)$/.test(t.nodeName)&&void 0!==t.style&&!/^(fixed|absolute)/i.test(t.style.position)}static first(t,i){let n=null==t?void 0:t.firstChild;if(!n)return null;do{if(i(n))return n;let o=n.firstChild;if(o||(o=n.nextSibling),!o&&n.parentNode!==t){do n=n.parentNode;while(n&&!(null==n?void 0:n.nextSibling)&&n.parentNode!==t)o=null==n?void 0:n.nextSibling}n=o}while(n)return null}static last(t,i){let n=null==t?void 0:t.lastChild;if(!n)return null;do{if(i(n))return n;let o=n.lastChild;if(o||(o=n.previousSibling),!o&&n.parentNode!==t){do n=n.parentNode;while(n&&!(null==n?void 0:n.previousSibling)&&n.parentNode!==t)o=null==n?void 0:n.previousSibling}n=o}while(n)return null}static prev(t,i,n,o=!0){return _.find(t,i,n,!1,o)}static next(t,i,n,o=!0){return _.find(t,i,n,!0,o)}static prevWithClass(t,i){return _.prev(t,t=>_.isElement(t)&&t.classList.contains(i),t.parentNode)}static nextWithClass(t,i){return _.next(t,t=>_.isElement(t)&&t.classList.contains(i),t.parentNode)}static find(t,i,n,o=!0,r=!0){let s=this.nextGen(t,n,o,r),a=s.next();for(;!a.done;){if(i(a.value))return a.value;a=s.next()}return null}static*nextGen(t,i,n=!0,o=!0){let r=[],s=t;do{let i=n?s.nextSibling:s.previousSibling;for(;i;)r.push(i),i=n?i.nextSibling:i.previousSibling;r.reverse(),yield*this.runInStack(t,r,n,o),s=s.parentNode}while(s&&s!==i)return null}static each(t,i,n=!0){let o=this.eachGen(t,n),r=o.next();for(;!r.done;){if(!1===i(r.value))return!1;r=o.next()}return!0}static eachGen(t,i=!0){return this.runInStack(t,[t],i)}static*runInStack(t,i,n,o=!0){for(;i.length;){let r=i.pop();if(o){let t=n?r.lastChild:r.firstChild;for(;t;)i.push(t),t=n?t.previousSibling:t.nextSibling}t!==r&&(yield r)}}static findWithCurrent(t,i,n,o="nextSibling",r="firstChild"){let s=t;do{if(i(s))return s||null;if(r&&s&&s[r]){let t=_.findWithCurrent(s[r],i,s,o,r);if(t)return t}for(;s&&!s[o]&&s!==n;)s=s.parentNode;s&&s[o]&&s!==n&&(s=s[o])}while(s&&s!==n)return null}static findSibling(t,i=!0,n=t=>!_.isEmptyTextNode(t)){let o=_.sibling(t,i);for(;o&&!n(o);)o=_.sibling(o,i);return o&&n(o)?o:null}static findNotEmptySibling(t,i){return _.findSibling(t,i,t=>{var i;return!_.isEmptyTextNode(t)&&!!(!_.isText(t)||(null==(i=t.nodeValue)?void 0:i.length)&&(0,h.trim)(t.nodeValue))})}static findNotEmptyNeighbor(t,i,n){return(0,y.call)(i?_.prev:_.next,t,t=>!!(t&&(!(_.isText(t)||_.isComment(t))||(0,h.trim)((null==t?void 0:t.nodeValue)||"").length)),n)}static sibling(t,i){return i?t.previousSibling:t.nextSibling}static up(t,i,n,o=!1){let r=t;if(!r)return null;do{if(i(r))return r;if(r===n||!r.parentNode)break;r=r.parentNode}while(r&&r!==n)return r===n&&o&&i(r)?r:null}static closest(t,i,n){let o,r=t=>t.toLowerCase();if((0,a.isFunction)(i))o=i;else if((0,s.isArray)(i)||(0,c.isSet)(i)){let t=(0,c.isSet)(i)?i:new Set(i.map(r));o=i=>!!(i&&t.has(r(i.nodeName)))}else o=t=>!!(t&&r(i)===r(t.nodeName));return _.up(t,o,n)}static furthest(t,i,n){let o=null,r=null==t?void 0:t.parentElement;for(;r&&r!==n;)i(r)&&(o=r),r=null==r?void 0:r.parentElement;return o}static appendChildFirst(t,i){let n=t.firstChild;n?n!==i&&t.insertBefore(i,n):t.appendChild(i)}static after(t,i){let{parentNode:n}=t;n&&(n.lastChild===t?n.appendChild(i):n.insertBefore(i,t.nextSibling))}static before(t,i){let{parentNode:n}=t;n&&n.insertBefore(i,t)}static prepend(t,i){t.insertBefore(i,t.firstChild)}static append(t,i){(0,s.isArray)(i)?i.forEach(i=>{this.append(t,i)}):t.appendChild(i)}static moveContent(t,i,n=!1,s=()=>!0){let a=(t.ownerDocument||o.globalDocument).createDocumentFragment();(0,r.toArray)(t.childNodes).filter(t=>!!s(t)||(_.safeRemove(t),!1)).forEach(t=>{a.appendChild(t)}),n&&i.firstChild?i.insertBefore(a,i.firstChild):i.appendChild(a)}static isOrContains(t,i,n=!1){return t===i?!n:!!(i&&t&&this.up(i,i=>i===t,t,!0))}static safeRemove(...t){t.forEach(t=>_.isNode(t)&&t.parentNode&&t.parentNode.removeChild(t))}static safeInsertNode(t,i){t.collapsed||t.deleteContents();let n=_.isFragment(i)?i.lastChild:i;t.startContainer===t.endContainer&&t.collapsed&&_.isTag(t.startContainer,o.INSEPARABLE_TAGS)?_.after(t.startContainer,i):(t.insertNode(i),n&&t.setStartBefore(n)),t.collapse(!0),[i.nextSibling,i.previousSibling].forEach(t=>_.isText(t)&&!t.nodeValue&&_.safeRemove(t))}static hide(t){t&&((0,g.dataBind)(t,"__old_display",t.style.display),t.style.display="none")}static show(t){if(!t)return;let i=(0,g.dataBind)(t,"__old_display");"none"===t.style.display&&(t.style.display=i||"")}static isTag(t,i){if(Array.isArray(i))throw TypeError("Dom.isTag does not support array");if(!this.isElement(t))return!1;let n=t.tagName.toLowerCase();return i instanceof Set?i.has(n)||i.has(t.tagName.toUpperCase()):n===i||t.tagName.toUpperCase()===i}static markTemporary(t,i){return i&&(0,f.attr)(t,i),(0,f.attr)(t,o.TEMP_ATTR,!0),t}static isTemporary(t){return!!_.isElement(t)&&(_.isMarker(t)||"true"===(0,f.attr)(t,o.TEMP_ATTR))}static isMarker(t){return _.isNode(t)&&_.isTag(t,"span")&&t.hasAttribute("data-"+o.MARKER_CLASS)}static replaceTemporaryFromString(t){return t.replace(w,"$2")}static temporaryList(t){return(0,r.toArray)(t.querySelectorAll(`[${o.TEMP_ATTR}]`))}constructor(){throw Error("Dom is static module")}}},22732:function(t,i,n){"use strict";n.d(i,{Dom:function(){return o.Dom},LazyWalker:function(){return r.LazyWalker}});var o=n(2748),r=n(70071)},70071:function(t,i,n){"use strict";n.d(i,{LazyWalker:function(){return a}});var o=n(45219),r=n(2748),s=n(72757);class a extends s.Eventify{setWork(t){return this.isWorked?this.break():this.stop(),this.workNodes=r.Dom.eachGen(t,!this.options.reverse),this.isFinished=!1,this.hadAffect=!1,this._requestStarting(),this}_requestStarting(){this.__schedulerController=new AbortController,this.async.schedulerPostTask(this.__workPerform,{delay:this.options.timeout,signal:this.__schedulerController.signal}).catch(()=>null)}break(t){this.isWorked&&(this.stop(),this.emit("break",t))}end(){this.isWorked&&(this.stop(),this.emit("end",this.hadAffect),this.hadAffect=!1)}stop(){var t;this.isWorked=!1,this.isFinished=!0,this.workNodes=null,null==(t=this.__schedulerController)||t.abort(),this.__schedulerController=null}destruct(){super.destruct(),this.stop()}__workPerform(){var t;if(this.workNodes){this.isWorked=!0;let i=0,n=null!=(t=this.options.timeoutChunkSize)?t:50;for(;!this.isFinished&&i<n;){let t=this.workNodes.next();if(i+=1,this.visitNode(t.value)&&(this.hadAffect=!0),t.done)return void this.end()}}else this.end();this.isFinished||this._requestStarting()}visitNode(t){var i;return!!t&&(void 0===this.options.whatToShow||t.nodeType===this.options.whatToShow)&&null!=(i=this.emit("visit",t))&&i}constructor(t,i={}){super(),this.async=t,this.options=i,this.workNodes=null,this.hadAffect=!1,this.isWorked=!1,this.isFinished=!1,this.__schedulerController=null}}!function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);s>3&&a&&Object.defineProperty(i,n,a)}([o.autobind],a.prototype,"__workPerform",null)},98220:function(t,i,n){"use strict";n.d(i,{EventEmitter:function(){return u}});var o=n(82758),r=n(46559),s=n(68345),a=n(23282),l=n(70799),c=n(89890),d=n(15738);class u{mute(t){return this.__mutedEvents.add(null!=t?t:"*"),this}isMuted(t){return!!(t&&this.__mutedEvents.has(t))||this.__mutedEvents.has("*")}unmute(t){return this.__mutedEvents.delete(null!=t?t:"*"),this}__eachEvent(t,i){(0,r.splitArray)(t).map(t=>t.trim()).forEach(t=>{let n=t.split("."),o=n[1]||d.defaultNameSpace;i.call(this,n[0],o)})}__getStore(t){if(!t)throw(0,c.error)("Need subject");if(void 0===t[this.__key]){let i=new d.EventHandlersStore;Object.defineProperty(t,this.__key,{enumerable:!1,configurable:!0,writable:!0,value:i})}return t[this.__key]}__removeStoreFromSubject(t){void 0!==t[this.__key]&&delete t[this.__key]}__triggerNativeEvent(t,i){let n=this.__doc.createEvent("HTMLEvents");(0,l.isString)(i)?n.initEvent(i,!0,!0):(n.initEvent(i.type,i.bubbles,i.cancelable),["screenX","screenY","clientX","clientY","target","srcElement","currentTarget","timeStamp","which","keyCode"].forEach(t=>{Object.defineProperty(n,t,{value:i[t],enumerable:!0})}),Object.defineProperty(n,"originalEvent",{value:i,enumerable:!0})),t.dispatchEvent(n)}get current(){return this.currents[this.currents.length-1]}on(t,i,n,r){let d,u,p,f;if((0,l.isString)(t)||(0,l.isStringArray)(t)?(d=this,u=t,p=i,f=n):(d=t,u=i,p=n,f=r),!((0,l.isString)(u)||(0,l.isStringArray)(u))||0===u.length)throw(0,c.error)("Need events names");if(!(0,a.isFunction)(p))throw(0,c.error)("Need event handler");if((0,s.isArray)(d))return d.forEach(t=>{this.on(t,u,p,f)}),this;let m=d,g=this.__getStore(m),b=this,y=function(t,...i){if(!b.isMuted(t))return p&&p.call(this,...i)};return h(m)&&(y=function(t){if(!b.isMuted(t.type)&&(b.__prepareEvent(t),p&&!1===p.call(this,t)))return t.preventDefault(),t.stopImmediatePropagation(),!1}),this.__eachEvent(u,(t,i)=>{var n,r;if(0===t.length)throw(0,c.error)("Need event name");if(!1===g.indexOf(t,i,p)){let s={event:t,originalCallback:p,syntheticCallback:y};if(g.set(t,i,s,null==f?void 0:f.top),h(m)){let i=o.PASSIVE_EVENTS.has(t)?{passive:!0,capture:null!=(n=null==f?void 0:f.capture)&&n}:null!=(r=null==f?void 0:f.capture)&&r;y.options=i,m.addEventListener(t,y,i),this.__memoryDOMSubjectToHandler(m,y)}}}),this}__memoryDOMSubjectToHandler(t,i){let n=this.__domEventsMap.get(t)||new Set;n.add(i),this.__domEventsMap.set(t,n)}__unmemoryDOMSubjectToHandler(t,i){let n=this.__domEventsMap,o=n.get(t)||new Set;o.delete(i),o.size?n.set(t,o):n.delete(t)}one(t,i,n,o){let r,s,a,c;(0,l.isString)(t)||(0,l.isStringArray)(t)?(r=this,s=t,a=i,c=n):(r=t,s=i,a=n,c=o);let d=(...t)=>(this.off(r,s,d),a(...t));return this.on(r,s,d,c),this}off(t,i,n){let o,r,c;if((0,l.isString)(t)||(0,l.isStringArray)(t)?(o=this,r=t,c=i):(o=t,r=i,c=n),(0,s.isArray)(o))return o.forEach(t=>{this.off(t,r,c)}),this;let u=o,p=this.__getStore(u);if(!((0,l.isString)(r)||(0,l.isStringArray)(r))||0===r.length)return p.namespaces().forEach(t=>{this.off(u,"."+t)}),this.__removeStoreFromSubject(u),this;let f=t=>{var i;h(u)&&(u.removeEventListener(t.event,t.syntheticCallback,null!=(i=t.syntheticCallback.options)&&i),this.__unmemoryDOMSubjectToHandler(u,t.syntheticCallback))},m=(t,i)=>{if(""===t)return void p.events(i).forEach(t=>{""!==t&&m(t,i)});let n=p.get(t,i);if(n&&n.length)if((0,a.isFunction)(c)){let o=p.indexOf(t,i,c);!1!==o&&(f(n[o]),n.splice(o,1),n.length||p.clearEvents(i,t))}else n.forEach(f),n.length=0,p.clearEvents(i,t)};return this.__eachEvent(r,(t,i)=>{i===d.defaultNameSpace?p.namespaces().forEach(i=>{m(t,i)}):m(t,i)}),p.isEmpty()&&this.__removeStoreFromSubject(u),this}stopPropagation(t,i){let n=(0,l.isString)(t)?this:t,o=(0,l.isString)(t)?t:i;if("string"!=typeof o)throw(0,c.error)("Need event names");let r=this.__getStore(n);this.__eachEvent(o,(t,i)=>{let o=r.get(t,i);o&&this.__stopped.push(o),i===d.defaultNameSpace&&r.namespaces(!0).forEach(i=>this.stopPropagation(n,t+"."+i))})}__removeStop(t){if(t){let i=this.__stopped.indexOf(t);-1!==i&&this.__stopped.splice(0,i+1)}}__isStopped(t){return void 0!==t&&-1!==this.__stopped.indexOf(t)}fire(t,i,...n){let o,r,s=(0,l.isString)(t)?this:t,a=(0,l.isString)(t)?t:i,u=(0,l.isString)(t)?[i,...n]:n;if(!h(s)&&!(0,l.isString)(a))throw(0,c.error)("Need events names");let p=this.__getStore(s);return!(0,l.isString)(a)&&h(s)?this.__triggerNativeEvent(s,i):this.__eachEvent(a,(t,i)=>{if(h(s))this.__triggerNativeEvent(s,t);else{let n=p.get(t,i);if(n)try{[...n].every(i=>!this.__isStopped(n)&&(this.currents.push(t),r=i.syntheticCallback.call(s,t,...u),this.currents.pop(),void 0!==r&&(o=r),!0))}finally{this.__removeStop(n)}i!==d.defaultNameSpace||h(s)||p.namespaces().filter(t=>t!==i).forEach(i=>{let n=this.fire.apply(this,[s,t+"."+i,...u]);void 0!==n&&(o=n)})}}),o}destruct(){this.__isDestructed||(this.__isDestructed=!0,this.__domEventsMap.forEach((t,i)=>{this.off(i)}),this.__domEventsMap.clear(),this.__mutedEvents.clear(),this.currents.length=0,this.__stopped.length=0,this.off(this),this.__getStore(this).clear(),this.__removeStoreFromSubject(this))}constructor(t){this.__domEventsMap=new Map,this.__mutedEvents=new Set,this.__key="__JoditEventEmitterNamespaces",this.__doc=o.globalDocument,this.__prepareEvent=t=>{!t.cancelBubble&&(t.composed&&(0,a.isFunction)(t.composedPath)&&t.composedPath()[0]&&Object.defineProperty(t,"target",{value:t.composedPath()[0],configurable:!0,enumerable:!0}),t.type.match(/^touch/)&&t.changedTouches&&t.changedTouches.length&&["clientX","clientY","pageX","pageY"].forEach(i=>{Object.defineProperty(t,i,{value:t.changedTouches[0][i],configurable:!0,enumerable:!0})}),t.originalEvent||(t.originalEvent=t),"paste"===t.type&&void 0===t.clipboardData&&this.__doc.defaultView.clipboardData&&Object.defineProperty(t,"clipboardData",{get:()=>this.__doc.defaultView.clipboardData,configurable:!0,enumerable:!0}))},this.currents=[],this.__stopped=[],this.__isDestructed=!1,t&&(this.__doc=t),this.__key+=new Date().getTime()}}function h(t){return t&&(0,a.isFunction)(t.addEventListener)}},72757:function(t,i,n){"use strict";n.d(i,{Eventify:function(){return o}});class o{on(t,i){var n;return this.__map.has(t)||this.__map.set(t,new Set),null==(n=this.__map.get(t))||n.add(i),this}off(t,i){var n;return this.__map.has(t)&&(null==(n=this.__map.get(t))||n.delete(i)),this}destruct(){this.__map.clear()}emit(t,...i){var n;let o;return this.__map.has(t)&&(null==(n=this.__map.get(t))||n.forEach(t=>{o=t(...i)})),o}constructor(){this.__map=new Map}}},57012:function(t,i,n){"use strict";n.d(i,{eventEmitter:function(){return o}});let o=new(n(98220)).EventEmitter},3827:function(t,i,n){"use strict";n.d(i,{EventEmitter:function(){return o.EventEmitter},EventHandlersStore:function(){return a.EventHandlersStore},Eventify:function(){return r.Eventify},defaultNameSpace:function(){return a.defaultNameSpace},observable:function(){return s.observable}});var o=n(98220),r=n(72757),s=n(73026),a=n(15738)},73026:function(t,i,n){"use strict";n.d(i,{observable:function(){return d}});var o=n(68345),r=n(59292),s=n(72430),a=n(37790);let l=Symbol("observable-object");function c(t){return void 0!==t[l]}function d(t){if(c(t))return t;let i={},n={},d=(i,r)=>((0,o.isArray)(i)?i.map(t=>d(t,r)):(n[i]||(n[i]=[]),n[i].push(r)),t),u=(r,...s)=>{if((0,o.isArray)(r))return void r.map(t=>u(t,...s));try{!i[r]&&n[r]&&(i[r]=!0,n[r].forEach(i=>i.call(t,...s)))}finally{i[r]=!1}},h=(i,n=[])=>{let o={};c(i)||(Object.defineProperty(i,l,{enumerable:!1,value:!0}),Object.keys(i).forEach(l=>{let c=n.concat(l).filter(t=>t.length);o[l]=i[l];let d=(0,a.getPropertyDescriptor)(i,l);Object.defineProperty(i,l,{set(i){let n=o[l];if(!(0,r.isFastEqual)(o[l],i)){u(["beforeChange","beforeChange."+c.join(".")],l,i),(0,s.isPlainObject)(i)&&h(i,c),d&&d.set?d.set.call(t,i):o[l]=i;let r=[];u(["change",...c.reduce((t,i)=>(r.push(i),t.push("change."+r.join(".")),t),[])],c.join("."),n,(null==i?void 0:i.valueOf)?i.valueOf():i)}},get:()=>d&&d.get?d.get.call(t):o[l],enumerable:!0,configurable:!0}),(0,s.isPlainObject)(o[l])&&h(o[l],c)}),Object.defineProperty(t,"on",{value:d}))};return h(t),t}},15738:function(t,i,n){"use strict";n.d(i,{EventHandlersStore:function(){return a},defaultNameSpace:function(){return s}});var o=n(4510),r=n(38837);let s="JoditEventDefaultNamespace";class a{get(t,i){if(this.__store.has(i)){let n=this.__store.get(i);return(0,r.assert)(n,"-"),n[t]}}indexOf(t,i,n){let o=this.get(t,i);if(o){for(let t=0;t<o.length;t+=1)if(o[t].originalCallback===n)return t}return!1}namespaces(t=!1){let i=(0,o.toArray)(this.__store.keys());return t?i.filter(t=>t!==s):i}events(t){let i=this.__store.get(t);return i?Object.keys(i):[]}set(t,i,n,o=!1){let r=this.__store.get(i);r||(r={},this.__store.set(i,r)),void 0===r[t]&&(r[t]=[]),o?r[t].unshift(n):r[t].push(n)}clear(){this.__store.clear()}clearEvents(t,i){let n=this.__store.get(t);n&&n[i]&&(delete n[i],Object.keys(n).length||this.__store.delete(t))}isEmpty(){return 0===this.__store.size}constructor(){this.__store=new Map}}},580:function(t,i,n){"use strict";n.d(i,{eventEmitter:function(){return x},extendLang:function(){return _},getContainer:function(){return k},getPopupViewRoot:function(){return S},instances:function(){return f},modules:function(){return w},pluginSystem:function(){return y},uniqueUid:function(){return b}});var o=n(19306),r=n(70799),s=n(39955),a=n(12475),l=n(41180),c=n(80568),d=n(41876),u=n(57012),h=n(82758),p=n(22732);let f={},m=1,g=new Set;function b(){function t(){return Math.round(m+=10*(Math.random()+1)).toString(16)}let i=t();for(;g.has(i);)i=t();return g.add(i),i}let y=new d.PluginSystem({getContainer:k}),w={},_=t=>{Object.keys(t).forEach(i=>{h.lang[i]?Object.assign(h.lang[i],t[i]):h.lang[i]=t[i]})},C=new WeakMap;function k(t,i,n="div",l=!1){let d=(0,r.isString)(i)?i:i?(0,c.getClassName)(i.prototype):"jodit-utils",u=C.get(t)||{},h=d+n,f=(0,s.isViewObject)(t)?t:t.j,m=null;if(!u[h]){let i=f.c;if(m=S(f.o,f.container,t.od.body),l&&(0,o.isJoditObject)(t)&&t.od!==t.ed){i=t.createInside;let r="style"===n?t.ed.head:t.ed.body;m=(0,o.isJoditObject)(t)&&t.o.shadowRoot?t.o.shadowRoot:r}let r=i.element(n,{className:`jodit jodit-${(0,a.kebabCase)(d)}-container jodit-box`});f.o.nonce&&("style"===n||"script"===n)&&r.setAttribute("nonce",f.o.nonce),r.classList.add("jodit_theme_"+(f.o.theme||"default")),m.appendChild(r),u[h]=r,t.hookStatus("beforeDestruct",()=>{f.events.off(r),p.Dom.safeRemove(r),delete u[h],Object.keys(u).length&&C.delete(t)}),C.set(t,u),f.events.fire("getContainer",r)}return u[h].classList.remove("jodit_theme_default","jodit_theme_dark"),u[h].classList.add("jodit_theme_"+(f.o.theme||"default")),u[h]}function S(t,i,n){var o,r,s;return null!=(s=null!=(r=null!=(o=t.popupRoot)?o:t.shadowRoot)?r:p.Dom.closest(i,t=>p.Dom.isHTMLElement(t)&&(p.Dom.isTag(t,"dialog")||["fixed","absolute"].includes((0,l.css)(t,"position"))),n))?s:n}let x=u.eventEmitter},29999:function(t,i,n){"use strict";n.d(i,{asArray:function(){return r}});var o=n(68345);let r=t=>(0,o.isArray)(t)?t:[t]},76855:function(t,i,n){"use strict";n.d(i,{asArray:function(){return o.asArray},splitArray:function(){return r.splitArray},toArray:function(){return s.toArray}});var o=n(29999),r=n(46559),s=n(4510)},46559:function(t,i,n){"use strict";function o(t){return Array.isArray(t)?t:t.split(/[,\s]+/)}n.d(i,{splitArray:function(){return o}})},4510:function(t,i,n){"use strict";n.d(i,{toArray:function(){return s}});var o=n(70722),r=n(58844);let s=function(...t){var i;return((0,o.isNativeFunction)(Array.from)?Array.from:null!=(i=(0,r.reset)("Array.from"))?i:Array.from).apply(Array,t)}},91898:function(t,i,n){"use strict";n.d(i,{clearTimeout:function(){return o.clearTimeout},setTimeout:function(){return o.setTimeout}});var o=n(13252)},13252:function(t,i,n){"use strict";n.d(i,{clearTimeout:function(){return s},setTimeout:function(){return r}});var o=n(82758);function r(t,i,...n){return i?o.globalWindow.setTimeout(t,i,...n):(t.call(null,...n),0)}function s(t){o.globalWindow.clearTimeout(t)}},54765:function(t,i,n){"use strict";n.d(i,{hasBrowserColorPicker:function(){return r}});var o=n(82758);function r(){let t=!0;try{let i=o.globalDocument.createElement("input");i.type="color",i.value="!",t="color"===i.type&&"!"!==i.value}catch(i){t=!1}return t}},27613:function(t,i,n){"use strict";n.d(i,{hasBrowserColorPicker:function(){return o.hasBrowserColorPicker},hasContainer:function(){return h.hasContainer},isAbortError:function(){return r.isAbortError},isArray:function(){return s.isArray},isBoolean:function(){return a.isBoolean},isDestructable:function(){return h.isDestructable},isEqual:function(){return l.isEqual},isFastEqual:function(){return l.isFastEqual},isFunction:function(){return c.isFunction},isHTML:function(){return d.isHTML},isHtmlFromWord:function(){return u.isHtmlFromWord},isInitable:function(){return h.isInitable},isInt:function(){return p.isInt},isJoditObject:function(){return f.isJoditObject},isLicense:function(){return m.isLicense},isMarker:function(){return g.isMarker},isNativeFunction:function(){return b.isNativeFunction},isNumber:function(){return y.isNumber},isNumeric:function(){return w.isNumeric},isPlainObject:function(){return _.isPlainObject},isPromise:function(){return C.isPromise},isSet:function(){return k.isSet},isString:function(){return S.isString},isStringArray:function(){return S.isStringArray},isURL:function(){return x.isURL},isValidName:function(){return I.isValidName},isViewObject:function(){return E.isViewObject},isVoid:function(){return T.isVoid},isWindow:function(){return j.isWindow}});var o=n(54765),r=n(12045),s=n(68345),a=n(87612),l=n(59292),c=n(23282),d=n(58487),u=n(29673),h=n(60132),p=n(72913),f=n(19306),m=n(45603),g=n(78116),b=n(70722),y=n(84767),w=n(29807),_=n(72430),C=n(14773),k=n(42320),S=n(70799),x=n(26049),I=n(37508),E=n(39955),T=n(86068),j=n(52742)},12045:function(t,i,n){"use strict";function o(t){return!!t&&t instanceof DOMException&&"AbortError"===t.name}n.d(i,{isAbortError:function(){return o}})},68345:function(t,i,n){"use strict";function o(t){return Array.isArray(t)}n.d(i,{isArray:function(){return o}})},87612:function(t,i,n){"use strict";function o(t){return"boolean"==typeof t}n.d(i,{isBoolean:function(){return o}})},59292:function(t,i,n){"use strict";n.d(i,{isEqual:function(){return r},isFastEqual:function(){return s}});var o=n(67462);function r(t,i){return t===i||(0,o.stringify)(t)===(0,o.stringify)(i)}function s(t,i){return t===i}},23282:function(t,i,n){"use strict";function o(t){return"function"==typeof t}n.d(i,{isFunction:function(){return o}})},29673:function(t,i,n){"use strict";function o(t){return -1!==t.search(/<meta.*?Microsoft Excel\s[\d].*?>/)||-1!==t.search(/<meta.*?Microsoft Word\s[\d].*?>/)||-1!==t.search(/<meta[^>]*?ProgId[^>]*?(Word|Excel)\./i)||-1!==t.search(/<meta[^>]*?(LibreOffice|OpenOffice)/i)||-1!==t.search(/urn:schemas-microsoft-com:office:(word|excel)/)||-1!==t.search(/<\w[^>]*\sclass=("|')?Mso/)||-1!==t.search(/style='[^']*mso-/)||-1!==t.search(/style="[^"]*mso-/)&&-1!==t.search(/<font/)}n.d(i,{isHtmlFromWord:function(){return o}})},58487:function(t,i,n){"use strict";n.d(i,{isHTML:function(){return r}});var o=n(70799);let r=t=>(0,o.isString)(t)&&/<([A-Za-z][A-Za-z0-9]*)\b[^>]*>(.*?)<\/\1>/m.test(t.replace(/[\r\n]/g,""))},60132:function(t,i,n){"use strict";n.d(i,{hasContainer:function(){return c},isDestructable:function(){return l},isInitable:function(){return a}});var o=n(2748),r=n(23282),s=n(86068);function a(t){return!(0,s.isVoid)(t)&&(0,r.isFunction)(t.init)}function l(t){return!(0,s.isVoid)(t)&&(0,r.isFunction)(t.destruct)}function c(t){return!(0,s.isVoid)(t)&&o.Dom.isElement(t.container)}},72913:function(t,i,n){"use strict";n.d(i,{isInt:function(){return s}});var o=n(29807),r=n(70799);function s(t){return(0,r.isString)(t)&&(0,o.isNumeric)(t)&&(t=parseFloat(t)),"number"==typeof t&&Number.isFinite(t)&&!(t%1)}},19306:function(t,i,n){"use strict";n.d(i,{isJoditObject:function(){return r}});var o=n(23282);function r(t){return!!(t&&t instanceof Object&&(0,o.isFunction)(t.constructor)&&("u">typeof Jodit&&t instanceof Jodit||t.isJodit))}},45603:function(t,i,n){"use strict";n.d(i,{isLicense:function(){return r}});var o=n(70799);let r=t=>(0,o.isString)(t)&&23===t.length&&/^[a-z0-9]{5}-[a-z0-9]{5}-[a-z0-9]{5}-[a-z0-9]{5}$/i.test(t)},78116:function(t,i,n){"use strict";n.d(i,{isMarker:function(){return r}});var o=n(2748);function r(t){return o.Dom.isMarker(t)}},70722:function(t,i,n){"use strict";function o(t){return!!t&&"function"===(typeof t).toLowerCase()&&(t===Function.prototype||/^\s*function\s*(\b[a-z$_][a-z0-9$_]*\b)*\s*\((|([a-z$_][a-z0-9$_]*)(\s*,[a-z$_][a-z0-9$_]*)*)\)\s*{\s*\[native code]\s*}\s*$/i.test(t+""))}n.d(i,{isNativeFunction:function(){return o}})},84767:function(t,i,n){"use strict";function o(t){return"number"==typeof t&&!isNaN(t)&&isFinite(t)}n.d(i,{isNumber:function(){return o}})},29807:function(t,i,n){"use strict";n.d(i,{isNumeric:function(){return r}});var o=n(70799);function r(t){if((0,o.isString)(t)){if(!t.match(/^([+-])?[0-9]+(\.?)([0-9]+)?(e[0-9]+)?$/))return!1;t=parseFloat(t)}return"number"==typeof t&&!isNaN(t)&&isFinite(t)}},72430:function(t,i,n){"use strict";n.d(i,{isPlainObject:function(){return r}});var o=n(52742);function r(t){return!(!t||"object"!=typeof t||t.nodeType||(0,o.isWindow)(t))&&!(t.constructor&&!({}).hasOwnProperty.call(t.constructor.prototype,"isPrototypeOf"))}},14773:function(t,i,n){"use strict";function o(t){return t&&"function"==typeof t.then}n.d(i,{isPromise:function(){return o}})},42320:function(t,i,n){"use strict";n.d(i,{isSet:function(){return r}});var o=n(23282);function r(t){return!!t&&(0,o.isFunction)(t.has)&&(0,o.isFunction)(t.add)&&(0,o.isFunction)(t.delete)}},70799:function(t,i,n){"use strict";n.d(i,{isString:function(){return r},isStringArray:function(){return s}});var o=n(68345);function r(t){return"string"==typeof t}function s(t){return(0,o.isArray)(t)&&r(t[0])}},26049:function(t,i,n){"use strict";n.d(i,{isURL:function(){return r}});var o=n(82758);function r(t){if(t.includes(" "))return!1;if("u">typeof URL)try{let i=new URL(t);return["https:","http:","ftp:","file:","rtmp:"].includes(i.protocol)}catch(t){return!1}let i=o.globalDocument.createElement("a");return i.href=t,!!i.hostname}},37508:function(t,i,n){"use strict";function o(t){return!!t.length&&!/[^0-9A-Za-zа-яА-ЯЁё\w\-_. ]/.test(t)&&t.trim().length>0}n.d(i,{isValidName:function(){return o}})},39955:function(t,i,n){"use strict";n.d(i,{isViewObject:function(){return r}});var o=n(23282);function r(t){return!!(t&&t instanceof Object&&(0,o.isFunction)(t.constructor)&&t.isView)}},86068:function(t,i,n){"use strict";function o(t){return null==t}n.d(i,{isVoid:function(){return o}})},52742:function(t,i,n){"use strict";function o(t){return null!=t&&t===t.window}n.d(i,{isWindow:function(){return o}})},35278:function(t,i,n){"use strict";n.d(i,{colorToHex:function(){return o}});let o=t=>{if("rgba(0, 0, 0, 0)"===t||""===t)return!1;if(!t)return"#000000";if("#"===t.substr(0,1))return t;let i=/([\s\n\t\r]*?)rgb\((\d+), (\d+), (\d+)\)/.exec(t)||/([\s\n\t\r]*?)rgba\((\d+), (\d+), (\d+), ([\d.]+)\)/.exec(t);if(!i)return"#000000";let n=parseInt(i[2],10),o=parseInt(i[3],10),r=(parseInt(i[4],10)|o<<8|n<<16).toString(16).toUpperCase();for(;r.length<6;)r="0"+r;return i[1]+"#"+r}},58149:function(t,i,n){"use strict";n.d(i,{colorToHex:function(){return o.colorToHex}});var o=n(35278)},32574:function(t,i,n){"use strict";n.d(i,{applyStyles:function(){return c}});var o=n(82758),r=n(2748),s=n(49055),a=n(76078);function l(t){return t.replace(/mso-[a-z-]+:[\s]*[^;]+;/gi,"").replace(/mso-[a-z-]+:[\s]*[^";']+$/gi,"").replace(/border[a-z-]*:[\s]*[^;]+;/gi,"").replace(/([0-9.]+)(pt|cm)/gi,(t,i,n)=>{switch(n.toLowerCase()){case"pt":return(1.328*parseFloat(i)).toFixed(0)+"px";case"cm":return(.02645833*parseFloat(i)).toFixed(0)+"px"}return t})}function c(t){let i=/<html(?:\s[^>]*)?>/i.exec(t);if(!i)return t;let n=(t=t.substring(i.index)).toLowerCase().lastIndexOf("</html>");-1!==n&&(t=t.substring(0,n+7));let c=o.globalDocument.createElement("iframe");c.style.display="none",o.globalDocument.body.appendChild(c);let d="";try{let i=c.contentDocument||(c.contentWindow?c.contentWindow.document:null);if(i){i.open(),i.write(t),i.close(),r.Dom.each(i.body,t=>{r.Dom.isElement(t)&&/mso-list:\s*ignore/i.test(t.getAttribute("style")||"")&&r.Dom.safeRemove(t)});try{for(let t=0;t<i.styleSheets.length;t+=1){let n=i.styleSheets[t].cssRules;for(let t=0;t<n.length;t+=1)""!==n[t].selectorText&&(0,a.$$)(n[t].selectorText,i.body).forEach(i=>{i.style.cssText=l(n[t].style.cssText+";"+i.style.cssText)})}}catch(t){if(!o.IS_PROD)throw t}r.Dom.each(i.body,t=>{if(r.Dom.isElement(t)){let i=t.getAttribute("style");i&&(t.style.cssText=l(i)),t.hasAttribute("style")&&!t.getAttribute("style")&&t.removeAttribute("style")}}),d=i.firstChild?(0,s.trim)(i.body.innerHTML):""}}catch(t){}finally{r.Dom.safeRemove(c)}return d&&(t=d),(0,s.trim)(t.replace(/<(\/)?(html|colgroup|col|o:p)[^>]*>/g,"").replace(/<!--[^>]*>/g,""))}},53212:function(t,i,n){"use strict";n.d(i,{cleanFromWord:function(){return l}});var o=n(82758),r=n(2748),s=n(4510),a=n(49055);function l(t){-1!==t.indexOf("<html ")&&(t=(t=t.substring(t.indexOf("<html "),t.length)).substring(0,t.lastIndexOf("</html>")+7));let i="";try{let n=o.globalDocument.createElement("div");n.innerHTML=t;let a=[];n.firstChild&&r.Dom.each(n,t=>{if(t)switch(t.nodeType){case Node.ELEMENT_NODE:switch(t.nodeName){case"STYLE":case"LINK":case"META":a.push(t);break;case"W:SDT":case"W:SDTPR":case"FONT":r.Dom.unwrap(t);break;default:if(/mso-list:\s*ignore/i.test(t.getAttribute("style")||"")){a.push(t);break}(0,s.toArray)(t.attributes).forEach(i=>{-1===["src","href","rel","content"].indexOf(i.name.toLowerCase())&&t.removeAttribute(i.name)})}break;case Node.TEXT_NODE:break;default:a.push(t)}}),r.Dom.safeRemove.apply(null,a),i=n.innerHTML}catch(t){}return i&&(t=i),(t=t.split(/(\n)/).filter(a.trim).join(`
|
|
17
|
+
`,{group:"state",buttons:[]},{group:"clipboard",buttons:[]},{group:"insert",buttons:[]},{group:"indent",buttons:[]},{group:"color",buttons:[]},{group:"form",buttons:[]},"---",{group:"history",buttons:[]},{group:"search",buttons:[]},{group:"source",buttons:[]},{group:"other",buttons:[]},{group:"info",buttons:[]}],this.events={},this.textIcons=!1,this.popupRoot=null,this.showBrowserColorPicker=!0,Object.assign(this,r)}}r=s.prototype,s.prototype.controls={}},26992:function(t,i,n){"use strict";n.d(i,{Async:function(){return m}});var o=n(82758),r=n(91898),s=n(12045),a=n(23282),l=n(84767),c=n(72430),d=n(14773),u=n(70799),h=n(86068),p=n(38837),f=n(93661);class m{delay(t){return this.promise(i=>this.setTimeout(i,t))}setTimeout(t,i,...n){if(this.isDestructed)return 0;let o={};(0,h.isVoid)(i)&&(i=0),(0,l.isNumber)(i)||(i=(o=i).timeout||0),o.label&&this.clearLabel(o.label);let s=(0,r.setTimeout)(t,i,...n),a=o.label||s;return this.timers.set(a,s),this.__callbacks.set(a,t),s}updateTimeout(t,i){if((0,p.assert)(t&&this.timers.has(t),"Label does not exist"),!t||!this.timers.has(t))return null;let n=this.__callbacks.get(t);return(0,p.assert)((0,a.isFunction)(n),"Callback is not a function"),this.setTimeout(n,{label:t,timeout:i})}clearLabel(t){t&&this.timers.has(t)&&((0,r.clearTimeout)(this.timers.get(t)),this.timers.delete(t),this.__callbacks.delete(t))}clearTimeout(t){if((0,u.isString)(t))return this.clearLabel(t);(0,r.clearTimeout)(t),this.timers.delete(t),this.__callbacks.delete(t)}debounce(t,i,n=!1){let o=0,l=!1,u=[],h=(...i)=>{if(!l){o=0;let n=t(...i);if(l=!0,u.length){let t=()=>{u.forEach(t=>t()),u.length=0};(0,d.isPromise)(n)?n.finally(t):t()}}},p=(...s)=>{l=!1,i?(!o&&n&&h(...s),(0,r.clearTimeout)(o),o=this.setTimeout(()=>h(...s),(0,a.isFunction)(i)?i():i),this.timers.set(t,o)):h(...s)};return(0,c.isPlainObject)(i)&&i.promisify?(...t)=>{let i=this.promise(t=>{u.push(t)}).catch(t=>{if((0,s.isAbortError)(t))return null;throw t});return p(...t),i}:p}microDebounce(t,i=!1){let n,o=!1,r=!0;return(...s)=>{if(n=s,o){r=!0;return}r=!0,i&&(r=!1,t(...n)),o=!0,this.__queueMicrotaskNative(()=>{o=!1,!this.isDestructed&&r&&t(...n)})}}throttle(t,i,n=!1){let o=null,r,s,l;return(...n)=>{(r=!0,l=n,i)?o||(s=()=>{r?(t(...l),r=!1,o=this.setTimeout(s,(0,a.isFunction)(i)?i():i),this.timers.set(s,o)):o=null})():t(...l)}}promise(t){let i=()=>{},n=new Promise((n,o)=>{i=()=>o((0,f.abort)("Abort async")),this.promisesRejections.add(i),t(n,o)});return!n.finally&&"u">typeof process&&!o.IS_ES_NEXT&&(n.finally=t=>(n.then(t).catch(t),n)),n.finally(()=>{this.promisesRejections.delete(i)}).catch(()=>null),n.rejectCallback=i,n}promiseState(t){if(t.status)return t.status;if(!Promise.race)return new Promise(i=>{t.then(t=>(i("fulfilled"),t),t=>{throw i("rejected"),t}),this.setTimeout(()=>{i("pending")},100)});let i={};return Promise.race([t,i]).then(t=>t===i?"pending":"fulfilled",()=>"rejected")}requestIdleCallback(t,i={timeout:100}){let n=this.__requestIdleCallbackNative(t,i);return this.__requestsIdle.add(n),n}requestIdlePromise(t){return this.promise(i=>{let n=this.requestIdleCallback(()=>i(n),t)})}schedulerPostTask(t,i={delay:0,priority:"user-visible"}){let n=new AbortController;if(i.signal&&i.signal.addEventListener("abort",()=>n.abort()),this.__controllers.add(n),void 0!==globalThis.scheduler){let o=globalThis.scheduler.postTask(t,{...i,signal:n.signal});return o.finally(()=>{this.__controllers.delete(n)}).catch(()=>null),o}return this.promise((o,r)=>{let s=this.setTimeout(()=>{try{o(t())}catch(t){r(t)}this.__controllers.delete(n)},i.delay||1);n.signal.addEventListener("abort",()=>{this.clearTimeout(s),this.__controllers.delete(n),r((0,f.abort)())})})}schedulerYield(){return this.schedulerPostTask(()=>{},{priority:"user-visible"})}cancelIdleCallback(t){return this.__requestsIdle.delete(t),this.__cancelIdleCallbackNative(t)}requestAnimationFrame(t){let i=requestAnimationFrame(t);return this.__requestsRaf.add(i),i}cancelAnimationFrame(t){this.__requestsRaf.delete(t),cancelAnimationFrame(t)}clear(){this.__requestsIdle.forEach(t=>this.cancelIdleCallback(t)),this.__requestsRaf.forEach(t=>this.cancelAnimationFrame(t)),this.__controllers.forEach(t=>t.abort()),this.timers.forEach(t=>(0,r.clearTimeout)(this.timers.get(t))),this.timers.clear(),this.promisesRejections.forEach(t=>t()),this.promisesRejections.clear()}destruct(){this.clear(),this.isDestructed=!0}constructor(){var t,i,n,o,r;this.timers=new Map,this.__callbacks=new Map,this.__queueMicrotaskNative=null!=(t=null==queueMicrotask?void 0:queueMicrotask.bind(window))?t:Promise.resolve().then.bind(Promise.resolve()),this.promisesRejections=new Set,this.__requestsIdle=new Set,this.__controllers=new Set,this.__requestsRaf=new Set,this.__requestIdleCallbackNative=null!=(n=null==(i=window.requestIdleCallback)?void 0:i.bind(window))?n:(t,i)=>{var n;let o=Date.now();return this.setTimeout(()=>{t({didTimeout:!1,timeRemaining:()=>Math.max(0,50-(Date.now()-o))})},null!=(n=null==i?void 0:i.timeout)?n:1)},this.__cancelIdleCallbackNative=null!=(r=null==(o=window.cancelIdleCallback)?void 0:o.bind(window))?r:t=>{this.clearTimeout(t)},this.isDestructed=!1}}},8884:function(t,i,n){"use strict";n.d(i,{Async:function(){return o.Async}});var o=n(26992)},4012:function(t,i,n){"use strict";n.d(i,{Component:function(){return c}});var o=n(8884),r=n(78213),s=n(580),a=n(21537);let l=new Map;class c{get componentName(){return this.__componentName||(this.__componentName="jodit-"+(0,a.kebabCase)(((0,a.isFunction)(this.className)?this.className():"")||(0,a.getClassName)(this))),this.__componentName}getFullElName(t,i,n){let o=[this.componentName];return t&&o.push("__"+(t=t.replace(/[^a-z0-9-]/gi,"-"))),i&&(o.push("_",i),o.push("_",(0,a.isVoid)(n)?"true":n.toString())),o.join("")}get ownerDocument(){return this.ow.document}get od(){return this.ownerDocument}get ow(){return this.ownerWindow}get(t,i){return(0,a.get)(t,i||this)}get isReady(){return this.componentStatus===r.STATUSES.ready}get isDestructed(){return this.componentStatus===r.STATUSES.destructed}get isInDestruct(){return r.STATUSES.beforeDestruct===this.componentStatus||r.STATUSES.destructed===this.componentStatus}bindDestruct(t){return t.hookStatus(r.STATUSES.beforeDestruct,()=>!this.isInDestruct&&this.destruct()),this}destruct(){this.setStatus(r.STATUSES.destructed),this.async&&(this.async.destruct(),this.async=void 0),l.get(this)&&l.delete(this),this.ownerWindow=void 0}get componentStatus(){return this.__componentStatus}set componentStatus(t){this.setStatus(t)}setStatus(t){return this.setStatusComponent(t,this)}setStatusComponent(t,i){if(t===this.__componentStatus)return;i===this&&(this.__componentStatus=t);let n=Object.getPrototypeOf(this);n&&(0,a.isFunction)(n.setStatusComponent)&&n.setStatusComponent(t,i);let o=l.get(this),r=null==o?void 0:o[t];r&&r.length&&r.forEach(t=>t(i))}hookStatus(t,i){let n=l.get(this);n||(n={},l.set(this,n)),n[t]||(n[t]=[]),n[t].push(i)}static isInstanceOf(t,i){return t instanceof i}constructor(){this.async=new o.Async,this.ownerWindow=window,this.__componentStatus=r.STATUSES.beforeInit,this.uid="jodit-uid-"+(0,s.uniqueUid)()}}c.STATUSES=r.STATUSES},91907:function(t,i,n){"use strict";n.d(i,{Component:function(){return o.Component},STATUSES:function(){return r.STATUSES},ViewComponent:function(){return s.ViewComponent}});var o=n(4012),r=n(78213),s=n(80480)},78213:function(t,i,n){"use strict";n.d(i,{STATUSES:function(){return o}});let o={beforeInit:"beforeInit",ready:"ready",beforeDestruct:"beforeDestruct",destructed:"destructed"}},80480:function(t,i,n){"use strict";n.d(i,{ViewComponent:function(){return r}});var o=n(4012);class r extends o.Component{get j(){return this.jodit}get defaultTimeout(){return this.j.defaultTimeout}i18n(t,...i){return this.j.i18n(t,...i)}setParentView(t){return this.jodit=t,t.ow&&(this.ownerWindow=t.ow),t.components.add(this),this}destruct(){return this.j.components.delete(this),super.destruct()}constructor(t){super(),this.setParentView(t)}}},82758:function(t,i,n){"use strict";n.r(i),n.d(i,{ACCURACY:function(){return W},APP_VERSION:function(){return o},BASE_PATH:function(){return ef},BASE_PATH_IS_MIN:function(){return em},BR:function(){return G},CLIPBOARD_ID:function(){return ev},COMMAND_KEYS:function(){return $},EMULATE_DBLCLICK_TIMEOUT:function(){return en},ES:function(){return r},FAT_MODE:function(){return d},HOMEPAGE:function(){return u},INSEPARABLE_TAGS:function(){return j},INSERT_AS_HTML:function(){return eo},INSERT_AS_TEXT:function(){return es},INSERT_CLEAR_HTML:function(){return er},INSERT_ONLY_TEXT:function(){return ea},INVISIBLE_SPACE:function(){return f},INVISIBLE_SPACE_REG_EXP:function(){return g},INVISIBLE_SPACE_REG_EXP_END:function(){return b},INVISIBLE_SPACE_REG_EXP_START:function(){return y},IS_BLOCK:function(){return x},IS_ES_MODERN:function(){return s},IS_ES_NEXT:function(){return a},IS_IE:function(){return Z},IS_INLINE:function(){return I},IS_MAC:function(){return ec},IS_PROD:function(){return l},IS_TEST:function(){return c},KEY_ALIASES:function(){return ed},KEY_ALT:function(){return z},KEY_BACKSPACE:function(){return L},KEY_DELETE:function(){return U},KEY_DOWN:function(){return F},KEY_ENTER:function(){return M},KEY_ESC:function(){return R},KEY_F3:function(){return q},KEY_LEFT:function(){return B},KEY_META:function(){return P},KEY_RIGHT:function(){return O},KEY_SPACE:function(){return H},KEY_TAB:function(){return D},KEY_UP:function(){return N},LIST_TAGS:function(){return E},MARKER_CLASS:function(){return ei},MODE_SOURCE:function(){return J},MODE_SPLIT:function(){return X},MODE_WYSIWYG:function(){return Y},NBSP_SPACE:function(){return m},NEARBY:function(){return V},NO_EMPTY_TAGS:function(){return A},PARAGRAPH:function(){return K},PASSIVE_EVENTS:function(){return ew},SAFE_COUNT_CHANGE_CALL:function(){return el},SET_TEST:function(){return h},SOURCE_CONSUMER:function(){return ey},SPACE_REG_EXP:function(){return w},SPACE_REG_EXP_END:function(){return C},SPACE_REG_EXP_START:function(){return _},TEMP_ATTR:function(){return eg},TEXT_HTML:function(){return ee},TEXT_PLAIN:function(){return Q},TEXT_RTF:function(){return et},TOKENS:function(){return p},globalDocument:function(){return S},globalWindow:function(){return k},lang:function(){return eb}});let o="4.13.37",r="es2021",s=!0,a=!0,l=!0,c=!1,d=!0,u="https://xdsoft.net/jodit/pro/",h=()=>c=!0,p={},f="\uFEFF",m=" ",g=()=>/[\uFEFF]/g,b=()=>/[\uFEFF]+$/g,y=()=>/^[\uFEFF]+/g,w=()=>/[\s\n\t\r\uFEFF\u200b]+/g,_=()=>/^[\s\n\t\r\uFEFF\u200b]+/g,C=()=>/[\s\n\t\r\uFEFF\u200b]+$/g,k="u">typeof window?window:void 0,S="u">typeof document?document:void 0,x=/^(ADDRESS|ARTICLE|ASIDE|BLOCKQUOTE|CANVAS|DD|DFN|DIV|DL|DT|FIELDSET|FIGCAPTION|FIGURE|FOOTER|FORM|H[1-6]|HEADER|HGROUP|HR|LI|MAIN|NAV|NOSCRIPT|OUTPUT|P|PRE|RUBY|SCRIPT|STYLE|OBJECT|OL|SECTION|IFRAME|JODIT|JODIT-MEDIA|UL|TR|TD|TH|TBODY|THEAD|TFOOT|TABLE|BODY|HTML|VIDEO)$/i,I=/^(STRONG|SPAN|I|EM|B|SUP|SUB|A|U)$/i,E=new Set(["ul","ol"]),T=["img","video","svg","iframe","script","input","textarea","link","jodit","jodit-media"],j=new Set([...T,"br","hr"]),A=new Set(T),P="Meta",L="Backspace",D="Tab",M="Enter",R="Escape",z="Alt",B="ArrowLeft",N="ArrowUp",O="ArrowRight",F="ArrowDown",H="Space",U="Delete",q="F3",V=5,W=10,$=[P,L,U,N,F,O,B,M,R,q,D],G="br",K="p",Y=1,J=2,X=3,Z="u">typeof navigator&&(-1!==navigator.userAgent.indexOf("MSIE")||/rv:11.0/i.test(navigator.userAgent)),Q=Z?"text":"text/plain",ee=Z?"html":"text/html",et=Z?"rtf":"text/rtf",ei="jodit-selection_marker",en=300,eo="insert_as_html",er="insert_clear_html",es="insert_as_text",ea="insert_only_text",el=10,ec=void 0!==k&&/Mac|iPod|iPhone|iPad/.test(k.navigator.platform),ed={add:"+",break:"pause",cmd:"meta",command:"meta",ctl:"control",ctrl:"control",del:"delete",down:"arrowdown",esc:"escape",ins:"insert",left:"arrowleft",mod:ec?"meta":"control",opt:"alt",option:"alt",return:"enter",right:"arrowright",space:"space",spacebar:"space",up:"arrowup",win:"meta",windows:"meta"},eu=t=>{let i=t.split("/");return/\.js/.test(i[i.length-1])?{basePath:i.slice(0,i.length-1).join("/")+"/",isMin:!0}:{basePath:t,isMin:!0}},{basePath:eh,isMin:ep}=(()=>{if("u"<typeof document)return{basePath:"",isMin:!0};let t=S.currentScript;if(t)return eu(t.src);let i=S.querySelectorAll("script[src]");return i&&i.length?eu(i[i.length-1].src):eu(k.location.href)})(),ef=eh,em=ep,eg="data-jodit-temp",eb={},ev="clipboard",ey="source-consumer",ew=new Set(["touchstart","touchend","scroll","mousewheel","mousemove","touchmove"])},20218:function(t,i,n){"use strict";n.d(i,{Create:function(){return l}});var o=n(82758),r=n(2748),s=n(21537),a=n(38837);class l{get doc(){return(0,s.isFunction)(this.document)?this.document():this.document}element(t,i,n){let o=this.doc.createElement(t.toLowerCase());return this.applyCreateAttributes(o),i&&((0,s.isPlainObject)(i)?(0,s.attr)(o,i):n=i),n&&(0,s.asArray)(n).forEach(t=>o.appendChild((0,s.isString)(t)?this.fromHTML(t):t)),o}div(t,i,n){let o=this.element("div",i,n);return t&&(o.className=t),o}sandbox(){var t;let i=this.element("iframe",{sandbox:"allow-same-origin"});this.doc.body.appendChild(i);let n=null==(t=i.contentWindow)?void 0:t.document;if((0,a.assert)(n,"iframe.contentWindow.document"),!n)throw Error("Iframe error");return n.open(),n.write("<!DOCTYPE html><html><head></head><body></body></html>"),n.close(),[n.body,i]}span(t,i,n){let o=this.element("span",i,n);return t&&(o.className=t),o}a(t,i,n){let o=this.element("a",i,n);return t&&(o.className=t),o}text(t){return this.doc.createTextNode(t)}fake(){return this.text(o.INVISIBLE_SPACE)}fragment(){return this.doc.createDocumentFragment()}fromHTML(t,i){let n=this.div();n.innerHTML=t.toString();let o=n.firstChild===n.lastChild&&n.firstChild?n.firstChild:n;if(r.Dom.safeRemove(o),i){let t=(0,s.refs)(o);Object.keys(i).forEach(n=>{let o=t[n];o&&!1===i[n]&&r.Dom.hide(o)})}return o}applyCreateAttributes(t){if(this.createAttributes){let i=this.createAttributes;if(i&&i[t.tagName.toLowerCase()]){let n=i[t.tagName.toLowerCase()];(0,s.isFunction)(n)?n(t):(0,s.isPlainObject)(n)&&(0,s.attr)(t,n)}}}constructor(t,i){this.document=t,this.createAttributes=i}}},12060:function(t,i,n){"use strict";n.d(i,{Create:function(){return o.Create}});var o=n(20218)},45219:function(t,i,n){"use strict";n.d(i,{autobind:function(){return r}});var o=n(23282);function r(t,i,n){if(!(0,o.isFunction)(n.value))throw TypeError(`@autobind can only be applied to methods, but "${i}" is not a function`);let r=n.value;return{configurable:!0,get(){let t=r.bind(this);return Object.defineProperty(this,i,{value:t,configurable:!0,writable:!0}),t}}}},33433:function(t,i,n){"use strict";n.d(i,{cache:function(){return c},cacheHTML:function(){return d},cached:function(){return l}});var o=n(78213),r=n(2748),s=n(27613),a=n(82760);function l(t,i){let n=Object.getOwnPropertyDescriptor(t,i);return!n||(0,s.isFunction)(n.get)?null:n.value}function c(t,i,n){let o=n.get;if(!o)throw(0,a.error)("Getter property descriptor expected");n.get=function(){let t=o.call(this);return t&&!0===t.noCache||Object.defineProperty(this,i,{configurable:n.configurable,enumerable:n.enumerable,writable:!1,value:t}),t}}function d(t,i,n){let l=n.value;if(!(0,s.isFunction)(l))throw(0,a.error)("Handler must be a Function");let c=!0,d=new WeakMap;n.value=function(...t){var i;if(c&&d.has(this.constructor))return null==(i=d.get(this.constructor))?void 0:i.cloneNode(!0);let n=l.apply(this,t);return c&&r.Dom.isElement(n)&&d.set(this.constructor,n),c?n.cloneNode(!0):n},t.hookStatus(o.STATUSES.ready,t=>{c=!!((0,s.isViewObject)(t)?t:t.jodit).options.cache})}},87325:function(t,i,n){"use strict";n.d(i,{component:function(){return a},getComponentClass:function(){return l}});var o=n(82758),r=n(80568);let s=new Map;function a(t){class i extends t{constructor(...t){super(...t),this.constructor===i&&(this instanceof i||Object.setPrototypeOf(this,i.prototype),this.setStatus("ready"))}}let n=(0,r.getClassName)(t.prototype);if(s.has(n)&&!o.IS_PROD)throw Error(`Component with name "${n}" is already registered`);return s.set(n,i),i}function l(t){return s.get(t)}},81577:function(t,i,n){"use strict";n.d(i,{debounce:function(){return l},throttle:function(){return c}});var o=n(91907),r=n(27613),s=n(38837),a=n(89890);function l(t,i=!1,n="debounce"){return(l,c)=>{let d=l[c];if(!(0,r.isFunction)(d))throw(0,a.error)("Handler must be a Function");return l.hookStatus(o.STATUSES.ready,o=>{let{async:a}=o;(0,s.assert)(null!=a,`Component ${o.componentName||o.constructor.name} should have "async:IAsync" field`);let l=(0,r.isFunction)(t)?t(o):t,d=(0,r.isNumber)(l)||(0,r.isPlainObject)(l)?l:o.defaultTimeout;Object.defineProperty(o,c,{configurable:!0,value:a[n](o[c].bind(o),d,i)})}),{configurable:!0,get(){return d.bind(this)}}}}function c(t,i=!1){return l(t,i,"throttle")}},55153:function(t,i,n){"use strict";n.d(i,{derive:function(){return r}});var o=n(23282);function r(...t){return i=>{let n=i.prototype;for(let i=0;i<t.length;i++){let r=t[i],s=Object.getOwnPropertyNames(r.prototype);for(let t=0;t<s.length;t++){let i=s[t],a=Object.getOwnPropertyDescriptor(r.prototype,i);null!=a&&(0,o.isFunction)(a.value)&&!(0,o.isFunction)(n[i])&&Object.defineProperty(n,i,{enumerable:!0,configurable:!0,writable:!0,value:function(...t){return a.value.call(this,...t)}})}}}}},97357:function(t,i,n){"use strict";n.d(i,{hook:function(){return s}});var o=n(23282),r=n(89890);function s(t){return(i,n)=>{if(!(0,o.isFunction)(i[n]))throw(0,r.error)("Handler must be a Function");i.hookStatus(t,t=>{t[n].call(t)})}}},78927:function(t,i,n){"use strict";n.d(i,{idle:function(){return a}});var o=n(91907),r=n(23282),s=n(89890);function a(){return(t,i)=>{if(!(0,r.isFunction)(t[i]))throw(0,s.error)("Handler must be a Function");t.hookStatus(o.STATUSES.ready,t=>{let{async:n}=t,o=t[i];t[i]=(...i)=>n.requestIdleCallback(o.bind(t,...i))})}}},65478:function(t,i,n){"use strict";n.r(i),n.d(i,{autobind:function(){return o.autobind},cache:function(){return r.cache},cacheHTML:function(){return r.cacheHTML},cached:function(){return r.cached},component:function(){return s.component},debounce:function(){return a.debounce},derive:function(){return l.derive},getComponentClass:function(){return s.getComponentClass},hook:function(){return c.hook},idle:function(){return d.idle},nonenumerable:function(){return u.nonenumerable},persistent:function(){return h.persistent},throttle:function(){return a.throttle},wait:function(){return p.wait},watch:function(){return f.watch}});var o=n(45219),r=n(33433),s=n(87325),a=n(81577),l=n(55153),c=n(97357),d=n(78927),u=n(31589),h=n(53213),p=n(13525),f=n(37133)},31589:function(t,i,n){"use strict";n.d(i,{nonenumerable:function(){return o}});let o=(t,i)=>{!1!==(Object.getOwnPropertyDescriptor(t,i)||{}).enumerable&&Object.defineProperty(t,i,{enumerable:!1,set(t){Object.defineProperty(this,i,{enumerable:!1,writable:!0,value:t})}})}},53213:function(t,i,n){"use strict";n.d(i,{persistent:function(){return s}});var o=n(78213),r=n(39955);function s(t,i){t.hookStatus(o.STATUSES.ready,t=>{let n=(0,r.isViewObject)(t)?t:t.jodit,o=`${n.options.namespace}${t.componentName}_prop_${i}`,s=t[i];Object.defineProperty(t,i,{get(){var t;return null!=(t=n.storage.get(o))?t:s},set(t){n.storage.set(o,t)}})})}},13525:function(t,i,n){"use strict";n.d(i,{wait:function(){return a}});var o=n(78213),r=n(23282),s=n(89890);function a(t){return(i,n)=>{let a=i[n];if(!(0,r.isFunction)(a))throw(0,s.error)("Handler must be a Function");i.hookStatus(o.STATUSES.ready,i=>{let{async:o}=i,r=i[n],s=0;Object.defineProperty(i,n,{configurable:!0,value:function n(...a){o.clearTimeout(s),t(i)?r.apply(i,a):s=o.setTimeout(()=>n(...a),10)}})})}}},37133:function(t,i,n){"use strict";n.d(i,{watch:function(){return h}});var o=n(78213),r=n(73026),s=n(46559),a=n(23282),l=n(72430),c=n(39955),d=n(89890),u=n(37790);function h(t,i){return(n,h)=>{var p;if(!(0,a.isFunction)(n[h]))throw(0,d.error)("Handler must be a Function");let f=null==(p=null==i?void 0:i.immediately)||p,m=null==i?void 0:i.context,g=i=>{let o=(0,c.isViewObject)(i)?i:i.jodit,d=(t,...n)=>{if(!i.isInDestruct)return i[h](t,...n)};f||(d=i.async.microDebounce(d,!0)),(0,s.splitArray)(t).forEach(t=>{if(/:/.test(t)){let[n,r]=t.split(":"),s=m;n.length&&(s=i.get(n)),(0,a.isFunction)(s)&&(s=s(i)),o.events.on(s||i,r,d),s||o.events.on(r,d),i.hookStatus("beforeDestruct",()=>{o.events.off(s||i,r,d).off(r,d)});return}let s=t.split("."),[c]=s,h=s.slice(1),p=i[c];(0,l.isPlainObject)(p)&&(0,r.observable)(p).on("change."+h.join("."),d);let f=(0,u.getPropertyDescriptor)(n,c);Object.defineProperty(i,c,{configurable:!0,set(t){let n=p;n!==t&&(p=t,f&&f.set&&f.set.call(i,t),(0,l.isPlainObject)(p)&&(p=(0,r.observable)(p)).on("change."+h.join("."),d),d(c,n,p))},get:()=>f&&f.get?f.get.call(i):p})})};(0,a.isFunction)(n.hookStatus)?n.hookStatus(o.STATUSES.ready,g):g(n)}}},2748:function(t,i,n){"use strict";n.d(i,{Dom:function(){return _}});var o=n(82758),r=n(4510),s=n(68345),a=n(23282),l=n(58487),c=n(42320),d=n(70799),u=n(86068),h=n(49055),p=n(38837),f=n(29960),m=n(41180),g=n(86583),b=n(89890),y=n(37790);let w=RegExp(`<([a-z]+)[^>]+${o.TEMP_ATTR}[^>]*>(.+?)</\\1>`,"gi");class _{static detach(t){for(;t&&t.firstChild;)t.removeChild(t.firstChild)}static wrapNextInline(t,i,n){let o,r=t;n.s.save();let s=!1;do s=!1,(o=r.nextSibling)&&!_.isBlock(o)&&!_.isTag(o,"br")&&(s=!0,r=o);while(s)return _.__wrapElements(i,n,t,r)}static __wrapElements(t,i,n,o){let r=(0,d.isString)(t)?i.createInside.element(t):t;n.parentNode&&n.parentNode.insertBefore(r,n);let s=n;for(;s&&(s=n.nextSibling,r.appendChild(n),n!==o&&s);)n=s;return i.s.restore(),r}static wrapInline(t,i,n){let o,r=t,s=t;n.s.save();let a=!1;do a=!1,(o=r.previousSibling)&&!_.isBlock(o)&&(a=!0,r=o);while(a)do a=!1,(o=s.nextSibling)&&!_.isBlock(o)&&(a=!0,s=o);while(a)return _.__wrapElements(i,n,r,s)}static wrap(t,i,n){let o=(0,d.isString)(i)?n.element(i):i;if(_.isNode(t)){if(!t.parentNode)throw(0,b.error)("Element should be in DOM");t.parentNode.insertBefore(o,t),o.appendChild(t)}else{let i=t.extractContents();t.insertNode(o),o.appendChild(i)}return o}static unwrap(t){let i=t.parentNode;if(i){for(;t.firstChild;)i.insertBefore(t.firstChild,t);_.safeRemove(t)}}static between(t,i,n){let o=t;for(;o&&o!==i&&!(t!==o&&n(o));){let t=o.firstChild||o.nextSibling;if(!t){for(;o&&!o.nextSibling;)if((o=o.parentNode)===i)return;t=null==o?void 0:o.nextSibling}o=t}}static replace(t,i,n,o=!1,s=!1){let a;if((0,l.isHTML)(i)&&((0,p.assert)(n,"Need create instance for new tag"),i=n.fromHTML(i)),(0,d.isString)(i)?((0,p.assert)(n,"Need create instance for new tag"),a=n.element(i)):a=i,!s)for(;t.firstChild;)a.appendChild(t.firstChild);return o&&_.isElement(t)&&_.isElement(a)&&(0,r.toArray)(t.attributes).forEach(t=>{a.setAttribute(t.name,t.value)}),t.parentNode&&t.parentNode.replaceChild(a,t),a}static isEmptyTextNode(t){return _.isText(t)&&(!t.nodeValue||0===t.nodeValue.replace(o.INVISIBLE_SPACE_REG_EXP(),"").trim().length)}static isEmptyContent(t){return _.each(t,t=>_.isEmptyTextNode(t))}static isContentEditable(t,i){return _.isNode(t)&&!_.closest(t,t=>_.isElement(t)&&"false"===t.getAttribute("contenteditable"),i)}static isEmpty(t,i=o.NO_EMPTY_TAGS){let n;if(!t)return!0;n=(0,a.isFunction)(i)?i:t=>i.has(t.nodeName.toLowerCase());let r=t=>null==t.nodeValue||0===(0,h.trim)(t.nodeValue).length;return _.isText(t)?r(t):!(_.isElement(t)&&n(t))&&_.each(t,t=>{if(_.isText(t)&&!r(t)||_.isElement(t)&&n(t))return!1})}static isNode(t){return!!(t&&(0,d.isString)(t.nodeName)&&"number"==typeof t.nodeType&&t.childNodes&&(0,a.isFunction)(t.appendChild))}static isCell(t){return _.isNode(t)&&("TD"===t.nodeName||"TH"===t.nodeName)}static isList(t){return _.isTag(t,o.LIST_TAGS)}static isLeaf(t){return _.isTag(t,"li")}static isImage(t){return _.isNode(t)&&/^(img|svg|picture|canvas)$/i.test(t.nodeName)}static isBlock(t){return!(0,u.isVoid)(t)&&"object"==typeof t&&_.isNode(t)&&o.IS_BLOCK.test(t.nodeName)}static isText(t){return!!(t&&t.nodeType===Node.TEXT_NODE)}static isComment(t){return!!(t&&t.nodeType===Node.COMMENT_NODE)}static isElement(t){return!!_.isNode(t)&&t.nodeType===Node.ELEMENT_NODE}static isFragment(t){return!!_.isNode(t)&&t.nodeType===Node.DOCUMENT_FRAGMENT_NODE}static isHTMLElement(t){var i;if(!_.isNode(t))return!1;let n=null==(i=t.ownerDocument)?void 0:i.defaultView;return t instanceof(n?n.HTMLElement:HTMLElement)}static isInlineBlock(t){return _.isElement(t)&&!/^(BR|HR)$/i.test(t.tagName)&&-1!==["inline","inline-block"].indexOf((0,m.css)(t,"display").toString())}static canSplitBlock(t){return!(0,u.isVoid)(t)&&_.isHTMLElement(t)&&_.isBlock(t)&&!/^(TD|TH|CAPTION|FORM)$/.test(t.nodeName)&&void 0!==t.style&&!/^(fixed|absolute)/i.test(t.style.position)}static first(t,i){let n=null==t?void 0:t.firstChild;if(!n)return null;do{if(i(n))return n;let o=n.firstChild;if(o||(o=n.nextSibling),!o&&n.parentNode!==t){do n=n.parentNode;while(n&&!(null==n?void 0:n.nextSibling)&&n.parentNode!==t)o=null==n?void 0:n.nextSibling}n=o}while(n)return null}static last(t,i){let n=null==t?void 0:t.lastChild;if(!n)return null;do{if(i(n))return n;let o=n.lastChild;if(o||(o=n.previousSibling),!o&&n.parentNode!==t){do n=n.parentNode;while(n&&!(null==n?void 0:n.previousSibling)&&n.parentNode!==t)o=null==n?void 0:n.previousSibling}n=o}while(n)return null}static prev(t,i,n,o=!0){return _.find(t,i,n,!1,o)}static next(t,i,n,o=!0){return _.find(t,i,n,!0,o)}static prevWithClass(t,i){return _.prev(t,t=>_.isElement(t)&&t.classList.contains(i),t.parentNode)}static nextWithClass(t,i){return _.next(t,t=>_.isElement(t)&&t.classList.contains(i),t.parentNode)}static find(t,i,n,o=!0,r=!0){let s=this.nextGen(t,n,o,r),a=s.next();for(;!a.done;){if(i(a.value))return a.value;a=s.next()}return null}static*nextGen(t,i,n=!0,o=!0){let r=[],s=t;do{let i=n?s.nextSibling:s.previousSibling;for(;i;)r.push(i),i=n?i.nextSibling:i.previousSibling;r.reverse(),yield*this.runInStack(t,r,n,o),s=s.parentNode}while(s&&s!==i)return null}static each(t,i,n=!0){let o=this.eachGen(t,n),r=o.next();for(;!r.done;){if(!1===i(r.value))return!1;r=o.next()}return!0}static eachGen(t,i=!0){return this.runInStack(t,[t],i)}static*runInStack(t,i,n,o=!0){for(;i.length;){let r=i.pop();if(o){let t=n?r.lastChild:r.firstChild;for(;t;)i.push(t),t=n?t.previousSibling:t.nextSibling}t!==r&&(yield r)}}static findWithCurrent(t,i,n,o="nextSibling",r="firstChild"){let s=t;do{if(i(s))return s||null;if(r&&s&&s[r]){let t=_.findWithCurrent(s[r],i,s,o,r);if(t)return t}for(;s&&!s[o]&&s!==n;)s=s.parentNode;s&&s[o]&&s!==n&&(s=s[o])}while(s&&s!==n)return null}static findSibling(t,i=!0,n=t=>!_.isEmptyTextNode(t)){let o=_.sibling(t,i);for(;o&&!n(o);)o=_.sibling(o,i);return o&&n(o)?o:null}static findNotEmptySibling(t,i){return _.findSibling(t,i,t=>{var i;return!_.isEmptyTextNode(t)&&!!(!_.isText(t)||(null==(i=t.nodeValue)?void 0:i.length)&&(0,h.trim)(t.nodeValue))})}static findNotEmptyNeighbor(t,i,n){return(0,y.call)(i?_.prev:_.next,t,t=>!!(t&&(!(_.isText(t)||_.isComment(t))||(0,h.trim)((null==t?void 0:t.nodeValue)||"").length)),n)}static sibling(t,i){return i?t.previousSibling:t.nextSibling}static up(t,i,n,o=!1){let r=t;if(!r)return null;do{if(i(r))return r;if(r===n||!r.parentNode)break;r=r.parentNode}while(r&&r!==n)return r===n&&o&&i(r)?r:null}static closest(t,i,n){let o,r=t=>t.toLowerCase();if((0,a.isFunction)(i))o=i;else if((0,s.isArray)(i)||(0,c.isSet)(i)){let t=(0,c.isSet)(i)?i:new Set(i.map(r));o=i=>!!(i&&t.has(r(i.nodeName)))}else o=t=>!!(t&&r(i)===r(t.nodeName));return _.up(t,o,n)}static furthest(t,i,n){let o=null,r=null==t?void 0:t.parentElement;for(;r&&r!==n;)i(r)&&(o=r),r=null==r?void 0:r.parentElement;return o}static appendChildFirst(t,i){let n=t.firstChild;n?n!==i&&t.insertBefore(i,n):t.appendChild(i)}static after(t,i){let{parentNode:n}=t;n&&(n.lastChild===t?n.appendChild(i):n.insertBefore(i,t.nextSibling))}static before(t,i){let{parentNode:n}=t;n&&n.insertBefore(i,t)}static prepend(t,i){t.insertBefore(i,t.firstChild)}static append(t,i){(0,s.isArray)(i)?i.forEach(i=>{this.append(t,i)}):t.appendChild(i)}static moveContent(t,i,n=!1,s=()=>!0){let a=(t.ownerDocument||o.globalDocument).createDocumentFragment();(0,r.toArray)(t.childNodes).filter(t=>!!s(t)||(_.safeRemove(t),!1)).forEach(t=>{a.appendChild(t)}),n&&i.firstChild?i.insertBefore(a,i.firstChild):i.appendChild(a)}static isOrContains(t,i,n=!1){return t===i?!n:!!(i&&t&&this.up(i,i=>i===t,t,!0))}static safeRemove(...t){t.forEach(t=>_.isNode(t)&&t.parentNode&&t.parentNode.removeChild(t))}static safeInsertNode(t,i){t.collapsed||t.deleteContents();let n=_.isFragment(i)?i.lastChild:i;t.startContainer===t.endContainer&&t.collapsed&&_.isTag(t.startContainer,o.INSEPARABLE_TAGS)?_.after(t.startContainer,i):(t.insertNode(i),n&&t.setStartBefore(n)),t.collapse(!0),[i.nextSibling,i.previousSibling].forEach(t=>_.isText(t)&&!t.nodeValue&&_.safeRemove(t))}static hide(t){t&&((0,g.dataBind)(t,"__old_display",t.style.display),t.style.display="none")}static show(t){if(!t)return;let i=(0,g.dataBind)(t,"__old_display");"none"===t.style.display&&(t.style.display=i||"")}static isTag(t,i){if(Array.isArray(i))throw TypeError("Dom.isTag does not support array");if(!this.isElement(t))return!1;let n=t.tagName.toLowerCase();return i instanceof Set?i.has(n)||i.has(t.tagName.toUpperCase()):n===i||t.tagName.toUpperCase()===i}static markTemporary(t,i){return i&&(0,f.attr)(t,i),(0,f.attr)(t,o.TEMP_ATTR,!0),t}static isTemporary(t){return!!_.isElement(t)&&(_.isMarker(t)||"true"===(0,f.attr)(t,o.TEMP_ATTR))}static isMarker(t){return _.isNode(t)&&_.isTag(t,"span")&&t.hasAttribute("data-"+o.MARKER_CLASS)}static replaceTemporaryFromString(t){return t.replace(w,"$2")}static temporaryList(t){return(0,r.toArray)(t.querySelectorAll(`[${o.TEMP_ATTR}]`))}constructor(){throw Error("Dom is static module")}}},22732:function(t,i,n){"use strict";n.d(i,{Dom:function(){return o.Dom},LazyWalker:function(){return r.LazyWalker}});var o=n(2748),r=n(70071)},70071:function(t,i,n){"use strict";n.d(i,{LazyWalker:function(){return a}});var o=n(45219),r=n(2748),s=n(72757);class a extends s.Eventify{setWork(t){return this.isWorked?this.break():this.stop(),this.workNodes=r.Dom.eachGen(t,!this.options.reverse),this.isFinished=!1,this.hadAffect=!1,this._requestStarting(),this}_requestStarting(){this.__schedulerController=new AbortController,this.async.schedulerPostTask(this.__workPerform,{delay:this.options.timeout,signal:this.__schedulerController.signal}).catch(()=>null)}break(t){this.isWorked&&(this.stop(),this.emit("break",t))}end(){this.isWorked&&(this.stop(),this.emit("end",this.hadAffect),this.hadAffect=!1)}stop(){var t;this.isWorked=!1,this.isFinished=!0,this.workNodes=null,null==(t=this.__schedulerController)||t.abort(),this.__schedulerController=null}destruct(){super.destruct(),this.stop()}__workPerform(){var t;if(this.workNodes){this.isWorked=!0;let i=0,n=null!=(t=this.options.timeoutChunkSize)?t:50;for(;!this.isFinished&&i<n;){let t=this.workNodes.next();if(i+=1,this.visitNode(t.value)&&(this.hadAffect=!0),t.done)return void this.end()}}else this.end();this.isFinished||this._requestStarting()}visitNode(t){var i;return!!t&&(void 0===this.options.whatToShow||t.nodeType===this.options.whatToShow)&&null!=(i=this.emit("visit",t))&&i}constructor(t,i={}){super(),this.async=t,this.options=i,this.workNodes=null,this.hadAffect=!1,this.isWorked=!1,this.isFinished=!1,this.__schedulerController=null}}!function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);s>3&&a&&Object.defineProperty(i,n,a)}([o.autobind],a.prototype,"__workPerform",null)},98220:function(t,i,n){"use strict";n.d(i,{EventEmitter:function(){return u}});var o=n(82758),r=n(46559),s=n(68345),a=n(23282),l=n(70799),c=n(89890),d=n(15738);class u{mute(t){return this.__mutedEvents.add(null!=t?t:"*"),this}isMuted(t){return!!(t&&this.__mutedEvents.has(t))||this.__mutedEvents.has("*")}unmute(t){return this.__mutedEvents.delete(null!=t?t:"*"),this}__eachEvent(t,i){(0,r.splitArray)(t).map(t=>t.trim()).forEach(t=>{let n=t.split("."),o=n[1]||d.defaultNameSpace;i.call(this,n[0],o)})}__getStore(t){if(!t)throw(0,c.error)("Need subject");if(void 0===t[this.__key]){let i=new d.EventHandlersStore;Object.defineProperty(t,this.__key,{enumerable:!1,configurable:!0,writable:!0,value:i})}return t[this.__key]}__removeStoreFromSubject(t){void 0!==t[this.__key]&&delete t[this.__key]}__triggerNativeEvent(t,i){let n=this.__doc.createEvent("HTMLEvents");(0,l.isString)(i)?n.initEvent(i,!0,!0):(n.initEvent(i.type,i.bubbles,i.cancelable),["screenX","screenY","clientX","clientY","target","srcElement","currentTarget","timeStamp","which","keyCode"].forEach(t=>{Object.defineProperty(n,t,{value:i[t],enumerable:!0})}),Object.defineProperty(n,"originalEvent",{value:i,enumerable:!0})),t.dispatchEvent(n)}get current(){return this.currents[this.currents.length-1]}on(t,i,n,r){let d,u,p,f;if((0,l.isString)(t)||(0,l.isStringArray)(t)?(d=this,u=t,p=i,f=n):(d=t,u=i,p=n,f=r),!((0,l.isString)(u)||(0,l.isStringArray)(u))||0===u.length)throw(0,c.error)("Need events names");if(!(0,a.isFunction)(p))throw(0,c.error)("Need event handler");if((0,s.isArray)(d))return d.forEach(t=>{this.on(t,u,p,f)}),this;let m=d,g=this.__getStore(m),b=this,y=function(t,...i){if(!b.isMuted(t))return p&&p.call(this,...i)};return h(m)&&(y=function(t){if(!b.isMuted(t.type)&&(b.__prepareEvent(t),p&&!1===p.call(this,t)))return t.preventDefault(),t.stopImmediatePropagation(),!1}),this.__eachEvent(u,(t,i)=>{var n,r;if(0===t.length)throw(0,c.error)("Need event name");if(!1===g.indexOf(t,i,p)){let s={event:t,originalCallback:p,syntheticCallback:y};if(g.set(t,i,s,null==f?void 0:f.top),h(m)){let i=o.PASSIVE_EVENTS.has(t)?{passive:!0,capture:null!=(n=null==f?void 0:f.capture)&&n}:null!=(r=null==f?void 0:f.capture)&&r;y.options=i,m.addEventListener(t,y,i),this.__memoryDOMSubjectToHandler(m,y)}}}),this}__memoryDOMSubjectToHandler(t,i){let n=this.__domEventsMap.get(t)||new Set;n.add(i),this.__domEventsMap.set(t,n)}__unmemoryDOMSubjectToHandler(t,i){let n=this.__domEventsMap,o=n.get(t)||new Set;o.delete(i),o.size?n.set(t,o):n.delete(t)}one(t,i,n,o){let r,s,a,c;(0,l.isString)(t)||(0,l.isStringArray)(t)?(r=this,s=t,a=i,c=n):(r=t,s=i,a=n,c=o);let d=(...t)=>(this.off(r,s,d),a(...t));return this.on(r,s,d,c),this}off(t,i,n){let o,r,c;if((0,l.isString)(t)||(0,l.isStringArray)(t)?(o=this,r=t,c=i):(o=t,r=i,c=n),(0,s.isArray)(o))return o.forEach(t=>{this.off(t,r,c)}),this;let u=o,p=this.__getStore(u);if(!((0,l.isString)(r)||(0,l.isStringArray)(r))||0===r.length)return p.namespaces().forEach(t=>{this.off(u,"."+t)}),this.__removeStoreFromSubject(u),this;let f=t=>{var i;h(u)&&(u.removeEventListener(t.event,t.syntheticCallback,null!=(i=t.syntheticCallback.options)&&i),this.__unmemoryDOMSubjectToHandler(u,t.syntheticCallback))},m=(t,i)=>{if(""===t)return void p.events(i).forEach(t=>{""!==t&&m(t,i)});let n=p.get(t,i);if(n&&n.length)if((0,a.isFunction)(c)){let o=p.indexOf(t,i,c);!1!==o&&(f(n[o]),n.splice(o,1),n.length||p.clearEvents(i,t))}else n.forEach(f),n.length=0,p.clearEvents(i,t)};return this.__eachEvent(r,(t,i)=>{i===d.defaultNameSpace?p.namespaces().forEach(i=>{m(t,i)}):m(t,i)}),p.isEmpty()&&this.__removeStoreFromSubject(u),this}stopPropagation(t,i){let n=(0,l.isString)(t)?this:t,o=(0,l.isString)(t)?t:i;if("string"!=typeof o)throw(0,c.error)("Need event names");let r=this.__getStore(n);this.__eachEvent(o,(t,i)=>{let o=r.get(t,i);o&&this.__stopped.push(o),i===d.defaultNameSpace&&r.namespaces(!0).forEach(i=>this.stopPropagation(n,t+"."+i))})}__removeStop(t){if(t){let i=this.__stopped.indexOf(t);-1!==i&&this.__stopped.splice(0,i+1)}}__isStopped(t){return void 0!==t&&-1!==this.__stopped.indexOf(t)}fire(t,i,...n){let o,r,s=(0,l.isString)(t)?this:t,a=(0,l.isString)(t)?t:i,u=(0,l.isString)(t)?[i,...n]:n;if(!h(s)&&!(0,l.isString)(a))throw(0,c.error)("Need events names");let p=this.__getStore(s);return!(0,l.isString)(a)&&h(s)?this.__triggerNativeEvent(s,i):this.__eachEvent(a,(t,i)=>{if(h(s))this.__triggerNativeEvent(s,t);else{let n=p.get(t,i);if(n)try{[...n].every(i=>!this.__isStopped(n)&&(this.currents.push(t),r=i.syntheticCallback.call(s,t,...u),this.currents.pop(),void 0!==r&&(o=r),!0))}finally{this.__removeStop(n)}i!==d.defaultNameSpace||h(s)||p.namespaces().filter(t=>t!==i).forEach(i=>{let n=this.fire.apply(this,[s,t+"."+i,...u]);void 0!==n&&(o=n)})}}),o}destruct(){this.__isDestructed||(this.__isDestructed=!0,this.__domEventsMap.forEach((t,i)=>{this.off(i)}),this.__domEventsMap.clear(),this.__mutedEvents.clear(),this.currents.length=0,this.__stopped.length=0,this.off(this),this.__getStore(this).clear(),this.__removeStoreFromSubject(this))}constructor(t){this.__domEventsMap=new Map,this.__mutedEvents=new Set,this.__key="__JoditEventEmitterNamespaces",this.__doc=o.globalDocument,this.__prepareEvent=t=>{!t.cancelBubble&&(t.composed&&(0,a.isFunction)(t.composedPath)&&t.composedPath()[0]&&Object.defineProperty(t,"target",{value:t.composedPath()[0],configurable:!0,enumerable:!0}),t.type.match(/^touch/)&&t.changedTouches&&t.changedTouches.length&&["clientX","clientY","pageX","pageY"].forEach(i=>{Object.defineProperty(t,i,{value:t.changedTouches[0][i],configurable:!0,enumerable:!0})}),t.originalEvent||(t.originalEvent=t),"paste"===t.type&&void 0===t.clipboardData&&this.__doc.defaultView.clipboardData&&Object.defineProperty(t,"clipboardData",{get:()=>this.__doc.defaultView.clipboardData,configurable:!0,enumerable:!0}))},this.currents=[],this.__stopped=[],this.__isDestructed=!1,t&&(this.__doc=t),this.__key+=new Date().getTime()}}function h(t){return t&&(0,a.isFunction)(t.addEventListener)}},72757:function(t,i,n){"use strict";n.d(i,{Eventify:function(){return o}});class o{on(t,i){var n;return this.__map.has(t)||this.__map.set(t,new Set),null==(n=this.__map.get(t))||n.add(i),this}off(t,i){var n;return this.__map.has(t)&&(null==(n=this.__map.get(t))||n.delete(i)),this}destruct(){this.__map.clear()}emit(t,...i){var n;let o;return this.__map.has(t)&&(null==(n=this.__map.get(t))||n.forEach(t=>{o=t(...i)})),o}constructor(){this.__map=new Map}}},57012:function(t,i,n){"use strict";n.d(i,{eventEmitter:function(){return o}});let o=new(n(98220)).EventEmitter},3827:function(t,i,n){"use strict";n.d(i,{EventEmitter:function(){return o.EventEmitter},EventHandlersStore:function(){return a.EventHandlersStore},Eventify:function(){return r.Eventify},defaultNameSpace:function(){return a.defaultNameSpace},observable:function(){return s.observable}});var o=n(98220),r=n(72757),s=n(73026),a=n(15738)},73026:function(t,i,n){"use strict";n.d(i,{observable:function(){return d}});var o=n(68345),r=n(59292),s=n(72430),a=n(37790);let l=Symbol("observable-object");function c(t){return void 0!==t[l]}function d(t){if(c(t))return t;let i={},n={},d=(i,r)=>((0,o.isArray)(i)?i.map(t=>d(t,r)):(n[i]||(n[i]=[]),n[i].push(r)),t),u=(r,...s)=>{if((0,o.isArray)(r))return void r.map(t=>u(t,...s));try{!i[r]&&n[r]&&(i[r]=!0,n[r].forEach(i=>i.call(t,...s)))}finally{i[r]=!1}},h=(i,n=[])=>{let o={};c(i)||(Object.defineProperty(i,l,{enumerable:!1,value:!0}),Object.keys(i).forEach(l=>{let c=n.concat(l).filter(t=>t.length);o[l]=i[l];let d=(0,a.getPropertyDescriptor)(i,l);Object.defineProperty(i,l,{set(i){let n=o[l];if(!(0,r.isFastEqual)(o[l],i)){u(["beforeChange","beforeChange."+c.join(".")],l,i),(0,s.isPlainObject)(i)&&h(i,c),d&&d.set?d.set.call(t,i):o[l]=i;let r=[];u(["change",...c.reduce((t,i)=>(r.push(i),t.push("change."+r.join(".")),t),[])],c.join("."),n,(null==i?void 0:i.valueOf)?i.valueOf():i)}},get:()=>d&&d.get?d.get.call(t):o[l],enumerable:!0,configurable:!0}),(0,s.isPlainObject)(o[l])&&h(o[l],c)}),Object.defineProperty(t,"on",{value:d}))};return h(t),t}},15738:function(t,i,n){"use strict";n.d(i,{EventHandlersStore:function(){return a},defaultNameSpace:function(){return s}});var o=n(4510),r=n(38837);let s="JoditEventDefaultNamespace";class a{get(t,i){if(this.__store.has(i)){let n=this.__store.get(i);return(0,r.assert)(n,"-"),n[t]}}indexOf(t,i,n){let o=this.get(t,i);if(o){for(let t=0;t<o.length;t+=1)if(o[t].originalCallback===n)return t}return!1}namespaces(t=!1){let i=(0,o.toArray)(this.__store.keys());return t?i.filter(t=>t!==s):i}events(t){let i=this.__store.get(t);return i?Object.keys(i):[]}set(t,i,n,o=!1){let r=this.__store.get(i);r||(r={},this.__store.set(i,r)),void 0===r[t]&&(r[t]=[]),o?r[t].unshift(n):r[t].push(n)}clear(){this.__store.clear()}clearEvents(t,i){let n=this.__store.get(t);n&&n[i]&&(delete n[i],Object.keys(n).length||this.__store.delete(t))}isEmpty(){return 0===this.__store.size}constructor(){this.__store=new Map}}},580:function(t,i,n){"use strict";n.d(i,{eventEmitter:function(){return x},extendLang:function(){return _},getContainer:function(){return k},getPopupViewRoot:function(){return S},instances:function(){return f},modules:function(){return w},pluginSystem:function(){return y},uniqueUid:function(){return b}});var o=n(19306),r=n(70799),s=n(39955),a=n(12475),l=n(41180),c=n(80568),d=n(41876),u=n(57012),h=n(82758),p=n(22732);let f={},m=1,g=new Set;function b(){function t(){return Math.round(m+=10*(Math.random()+1)).toString(16)}let i=t();for(;g.has(i);)i=t();return g.add(i),i}let y=new d.PluginSystem({getContainer:k}),w={},_=t=>{Object.keys(t).forEach(i=>{h.lang[i]?Object.assign(h.lang[i],t[i]):h.lang[i]=t[i]})},C=new WeakMap;function k(t,i,n="div",l=!1){let d=(0,r.isString)(i)?i:i?(0,c.getClassName)(i.prototype):"jodit-utils",u=C.get(t)||{},h=d+n,f=(0,s.isViewObject)(t)?t:t.j,m=null;if(!u[h]){let i=f.c;if(m=S(f.o,f.container,t.od.body),l&&(0,o.isJoditObject)(t)&&t.od!==t.ed){i=t.createInside;let r="style"===n?t.ed.head:t.ed.body;m=(0,o.isJoditObject)(t)&&t.o.shadowRoot?t.o.shadowRoot:r}let r=i.element(n,{className:`jodit jodit-${(0,a.kebabCase)(d)}-container jodit-box`});f.o.nonce&&("style"===n||"script"===n)&&r.setAttribute("nonce",f.o.nonce),r.classList.add("jodit_theme_"+(f.o.theme||"default")),m.appendChild(r),u[h]=r,t.hookStatus("beforeDestruct",()=>{f.events.off(r),p.Dom.safeRemove(r),delete u[h],Object.keys(u).length&&C.delete(t)}),C.set(t,u),f.events.fire("getContainer",r)}return u[h].classList.remove("jodit_theme_default","jodit_theme_dark"),u[h].classList.add("jodit_theme_"+(f.o.theme||"default")),u[h]}function S(t,i,n){var o,r,s;return null!=(s=null!=(r=null!=(o=t.popupRoot)?o:t.shadowRoot)?r:p.Dom.closest(i,t=>p.Dom.isHTMLElement(t)&&(p.Dom.isTag(t,"dialog")||["fixed","absolute"].includes((0,l.css)(t,"position"))),n))?s:n}let x=u.eventEmitter},29999:function(t,i,n){"use strict";n.d(i,{asArray:function(){return r}});var o=n(68345);let r=t=>(0,o.isArray)(t)?t:[t]},76855:function(t,i,n){"use strict";n.d(i,{asArray:function(){return o.asArray},splitArray:function(){return r.splitArray},toArray:function(){return s.toArray}});var o=n(29999),r=n(46559),s=n(4510)},46559:function(t,i,n){"use strict";function o(t){return Array.isArray(t)?t:t.split(/[,\s]+/)}n.d(i,{splitArray:function(){return o}})},4510:function(t,i,n){"use strict";n.d(i,{toArray:function(){return s}});var o=n(70722),r=n(58844);let s=function(...t){var i;return((0,o.isNativeFunction)(Array.from)?Array.from:null!=(i=(0,r.reset)("Array.from"))?i:Array.from).apply(Array,t)}},91898:function(t,i,n){"use strict";n.d(i,{clearTimeout:function(){return o.clearTimeout},setTimeout:function(){return o.setTimeout}});var o=n(13252)},13252:function(t,i,n){"use strict";n.d(i,{clearTimeout:function(){return s},setTimeout:function(){return r}});var o=n(82758);function r(t,i,...n){return i?o.globalWindow.setTimeout(t,i,...n):(t.call(null,...n),0)}function s(t){o.globalWindow.clearTimeout(t)}},54765:function(t,i,n){"use strict";n.d(i,{hasBrowserColorPicker:function(){return r}});var o=n(82758);function r(){let t=!0;try{let i=o.globalDocument.createElement("input");i.type="color",i.value="!",t="color"===i.type&&"!"!==i.value}catch(i){t=!1}return t}},27613:function(t,i,n){"use strict";n.d(i,{hasBrowserColorPicker:function(){return o.hasBrowserColorPicker},hasContainer:function(){return h.hasContainer},isAbortError:function(){return r.isAbortError},isArray:function(){return s.isArray},isBoolean:function(){return a.isBoolean},isDestructable:function(){return h.isDestructable},isEqual:function(){return l.isEqual},isFastEqual:function(){return l.isFastEqual},isFunction:function(){return c.isFunction},isHTML:function(){return d.isHTML},isHtmlFromWord:function(){return u.isHtmlFromWord},isInitable:function(){return h.isInitable},isInt:function(){return p.isInt},isJoditObject:function(){return f.isJoditObject},isLicense:function(){return m.isLicense},isMarker:function(){return g.isMarker},isNativeFunction:function(){return b.isNativeFunction},isNumber:function(){return y.isNumber},isNumeric:function(){return w.isNumeric},isPlainObject:function(){return _.isPlainObject},isPromise:function(){return C.isPromise},isSet:function(){return k.isSet},isString:function(){return S.isString},isStringArray:function(){return S.isStringArray},isURL:function(){return x.isURL},isValidName:function(){return I.isValidName},isViewObject:function(){return E.isViewObject},isVoid:function(){return T.isVoid},isWindow:function(){return j.isWindow}});var o=n(54765),r=n(12045),s=n(68345),a=n(87612),l=n(59292),c=n(23282),d=n(58487),u=n(29673),h=n(60132),p=n(72913),f=n(19306),m=n(45603),g=n(78116),b=n(70722),y=n(84767),w=n(29807),_=n(72430),C=n(14773),k=n(42320),S=n(70799),x=n(26049),I=n(37508),E=n(39955),T=n(86068),j=n(52742)},12045:function(t,i,n){"use strict";function o(t){return!!t&&t instanceof DOMException&&"AbortError"===t.name}n.d(i,{isAbortError:function(){return o}})},68345:function(t,i,n){"use strict";function o(t){return Array.isArray(t)}n.d(i,{isArray:function(){return o}})},87612:function(t,i,n){"use strict";function o(t){return"boolean"==typeof t}n.d(i,{isBoolean:function(){return o}})},59292:function(t,i,n){"use strict";n.d(i,{isEqual:function(){return r},isFastEqual:function(){return s}});var o=n(67462);function r(t,i){return t===i||(0,o.stringify)(t)===(0,o.stringify)(i)}function s(t,i){return t===i}},23282:function(t,i,n){"use strict";function o(t){return"function"==typeof t}n.d(i,{isFunction:function(){return o}})},29673:function(t,i,n){"use strict";function o(t){return -1!==t.search(/<meta.*?Microsoft Excel\s[\d].*?>/)||-1!==t.search(/<meta.*?Microsoft Word\s[\d].*?>/)||-1!==t.search(/<meta[^>]*?ProgId[^>]*?(Word|Excel)\./i)||-1!==t.search(/<meta[^>]*?(LibreOffice|OpenOffice)/i)||-1!==t.search(/urn:schemas-microsoft-com:office:(word|excel)/)||-1!==t.search(/<\w[^>]*\sclass=("|')?Mso/)||-1!==t.search(/style='[^']*mso-/)||-1!==t.search(/style="[^"]*mso-/)&&-1!==t.search(/<font/)}n.d(i,{isHtmlFromWord:function(){return o}})},58487:function(t,i,n){"use strict";n.d(i,{isHTML:function(){return r}});var o=n(70799);let r=t=>(0,o.isString)(t)&&/<([A-Za-z][A-Za-z0-9]*)\b[^>]*>(.*?)<\/\1>/m.test(t.replace(/[\r\n]/g,""))},60132:function(t,i,n){"use strict";n.d(i,{hasContainer:function(){return c},isDestructable:function(){return l},isInitable:function(){return a}});var o=n(2748),r=n(23282),s=n(86068);function a(t){return!(0,s.isVoid)(t)&&(0,r.isFunction)(t.init)}function l(t){return!(0,s.isVoid)(t)&&(0,r.isFunction)(t.destruct)}function c(t){return!(0,s.isVoid)(t)&&o.Dom.isElement(t.container)}},72913:function(t,i,n){"use strict";n.d(i,{isInt:function(){return s}});var o=n(29807),r=n(70799);function s(t){return(0,r.isString)(t)&&(0,o.isNumeric)(t)&&(t=parseFloat(t)),"number"==typeof t&&Number.isFinite(t)&&!(t%1)}},19306:function(t,i,n){"use strict";n.d(i,{isJoditObject:function(){return r}});var o=n(23282);function r(t){return!!(t&&t instanceof Object&&(0,o.isFunction)(t.constructor)&&("u">typeof Jodit&&t instanceof Jodit||t.isJodit))}},45603:function(t,i,n){"use strict";n.d(i,{isLicense:function(){return r}});var o=n(70799);let r=t=>(0,o.isString)(t)&&23===t.length&&/^[a-z0-9]{5}-[a-z0-9]{5}-[a-z0-9]{5}-[a-z0-9]{5}$/i.test(t)},78116:function(t,i,n){"use strict";n.d(i,{isMarker:function(){return r}});var o=n(2748);function r(t){return o.Dom.isMarker(t)}},70722:function(t,i,n){"use strict";function o(t){return!!t&&"function"===(typeof t).toLowerCase()&&(t===Function.prototype||/^\s*function\s*(\b[a-z$_][a-z0-9$_]*\b)*\s*\((|([a-z$_][a-z0-9$_]*)(\s*,[a-z$_][a-z0-9$_]*)*)\)\s*{\s*\[native code]\s*}\s*$/i.test(t+""))}n.d(i,{isNativeFunction:function(){return o}})},84767:function(t,i,n){"use strict";function o(t){return"number"==typeof t&&!isNaN(t)&&isFinite(t)}n.d(i,{isNumber:function(){return o}})},29807:function(t,i,n){"use strict";n.d(i,{isNumeric:function(){return r}});var o=n(70799);function r(t){if((0,o.isString)(t)){if(!t.match(/^([+-])?[0-9]+(\.?)([0-9]+)?(e[0-9]+)?$/))return!1;t=parseFloat(t)}return"number"==typeof t&&!isNaN(t)&&isFinite(t)}},72430:function(t,i,n){"use strict";n.d(i,{isPlainObject:function(){return r}});var o=n(52742);function r(t){return!(!t||"object"!=typeof t||t.nodeType||(0,o.isWindow)(t))&&!(t.constructor&&!({}).hasOwnProperty.call(t.constructor.prototype,"isPrototypeOf"))}},14773:function(t,i,n){"use strict";function o(t){return t&&"function"==typeof t.then}n.d(i,{isPromise:function(){return o}})},42320:function(t,i,n){"use strict";n.d(i,{isSet:function(){return r}});var o=n(23282);function r(t){return!!t&&(0,o.isFunction)(t.has)&&(0,o.isFunction)(t.add)&&(0,o.isFunction)(t.delete)}},70799:function(t,i,n){"use strict";n.d(i,{isString:function(){return r},isStringArray:function(){return s}});var o=n(68345);function r(t){return"string"==typeof t}function s(t){return(0,o.isArray)(t)&&r(t[0])}},26049:function(t,i,n){"use strict";n.d(i,{isURL:function(){return r}});var o=n(82758);function r(t){if(t.includes(" "))return!1;if("u">typeof URL)try{let i=new URL(t);return["https:","http:","ftp:","file:","rtmp:"].includes(i.protocol)}catch(t){return!1}let i=o.globalDocument.createElement("a");return i.href=t,!!i.hostname}},37508:function(t,i,n){"use strict";function o(t){return!!t.length&&!/[^0-9A-Za-zа-яА-ЯЁё\w\-_. ]/.test(t)&&t.trim().length>0}n.d(i,{isValidName:function(){return o}})},39955:function(t,i,n){"use strict";n.d(i,{isViewObject:function(){return r}});var o=n(23282);function r(t){return!!(t&&t instanceof Object&&(0,o.isFunction)(t.constructor)&&t.isView)}},86068:function(t,i,n){"use strict";function o(t){return null==t}n.d(i,{isVoid:function(){return o}})},52742:function(t,i,n){"use strict";function o(t){return null!=t&&t===t.window}n.d(i,{isWindow:function(){return o}})},35278:function(t,i,n){"use strict";n.d(i,{colorToHex:function(){return o}});let o=t=>{if("rgba(0, 0, 0, 0)"===t||""===t)return!1;if(!t)return"#000000";if("#"===t.substr(0,1))return t;let i=/([\s\n\t\r]*?)rgb\((\d+), (\d+), (\d+)\)/.exec(t)||/([\s\n\t\r]*?)rgba\((\d+), (\d+), (\d+), ([\d.]+)\)/.exec(t);if(!i)return"#000000";let n=parseInt(i[2],10),o=parseInt(i[3],10),r=(parseInt(i[4],10)|o<<8|n<<16).toString(16).toUpperCase();for(;r.length<6;)r="0"+r;return i[1]+"#"+r}},58149:function(t,i,n){"use strict";n.d(i,{colorToHex:function(){return o.colorToHex}});var o=n(35278)},32574:function(t,i,n){"use strict";n.d(i,{applyStyles:function(){return c}});var o=n(82758),r=n(2748),s=n(49055),a=n(76078);function l(t){return t.replace(/mso-[a-z-]+:[\s]*[^;]+;/gi,"").replace(/mso-[a-z-]+:[\s]*[^";']+$/gi,"").replace(/border[a-z-]*:[\s]*[^;]+;/gi,"").replace(/([0-9.]+)(pt|cm)/gi,(t,i,n)=>{switch(n.toLowerCase()){case"pt":return(1.328*parseFloat(i)).toFixed(0)+"px";case"cm":return(.02645833*parseFloat(i)).toFixed(0)+"px"}return t})}function c(t){let i=/<html(?:\s[^>]*)?>/i.exec(t);if(!i)return t;let n=(t=t.substring(i.index)).toLowerCase().lastIndexOf("</html>");-1!==n&&(t=t.substring(0,n+7));let c=o.globalDocument.createElement("iframe");c.style.display="none",o.globalDocument.body.appendChild(c);let d="";try{let i=c.contentDocument||(c.contentWindow?c.contentWindow.document:null);if(i){i.open(),i.write(t),i.close(),r.Dom.each(i.body,t=>{r.Dom.isElement(t)&&/mso-list:\s*ignore/i.test(t.getAttribute("style")||"")&&r.Dom.safeRemove(t)});try{for(let t=0;t<i.styleSheets.length;t+=1){let n=i.styleSheets[t].cssRules;for(let t=0;t<n.length;t+=1)""!==n[t].selectorText&&(0,a.$$)(n[t].selectorText,i.body).forEach(i=>{i.style.cssText=l(n[t].style.cssText+";"+i.style.cssText)})}}catch(t){if(!o.IS_PROD)throw t}r.Dom.each(i.body,t=>{if(r.Dom.isElement(t)){let i=t.getAttribute("style");i&&(t.style.cssText=l(i)),t.hasAttribute("style")&&!t.getAttribute("style")&&t.removeAttribute("style")}}),d=i.firstChild?(0,s.trim)(i.body.innerHTML):""}}catch(t){}finally{r.Dom.safeRemove(c)}return d&&(t=d),(0,s.trim)(t.replace(/<(\/)?(html|colgroup|col|o:p)[^>]*>/g,"").replace(/<!--[^>]*>/g,""))}},53212:function(t,i,n){"use strict";n.d(i,{cleanFromWord:function(){return l}});var o=n(82758),r=n(2748),s=n(4510),a=n(49055);function l(t){-1!==t.indexOf("<html ")&&(t=(t=t.substring(t.indexOf("<html "),t.length)).substring(0,t.lastIndexOf("</html>")+7));let i="";try{let n=o.globalDocument.createElement("div");n.innerHTML=t;let a=[];n.firstChild&&r.Dom.each(n,t=>{if(t)switch(t.nodeType){case Node.ELEMENT_NODE:switch(t.nodeName){case"STYLE":case"LINK":case"META":a.push(t);break;case"W:SDT":case"W:SDTPR":case"FONT":r.Dom.unwrap(t);break;default:if(/mso-list:\s*ignore/i.test(t.getAttribute("style")||"")){a.push(t);break}(0,s.toArray)(t.attributes).forEach(i=>{-1===["src","href","rel","content"].indexOf(i.name.toLowerCase())&&t.removeAttribute(i.name)})}break;case Node.TEXT_NODE:break;default:a.push(t)}}),r.Dom.safeRemove.apply(null,a),i=n.innerHTML}catch(t){}return i&&(t=i),(t=t.split(/(\n)/).filter(a.trim).join(`
|
|
18
18
|
`)).replace(/<(\/)?(html|colgroup|col|o:p)[^>]*>/g,"").replace(/<!--[^>]*>/g,"")}},53326:function(t,i,n){"use strict";n.d(i,{htmlspecialchars:function(){return r}});var o=n(82758);function r(t){let i=o.globalDocument.createElement("div");return i.textContent=t,i.innerHTML}},75275:function(t,i,n){"use strict";n.d(i,{applyStyles:function(){return o.applyStyles},cleanFromWord:function(){return r.cleanFromWord},htmlspecialchars:function(){return s.htmlspecialchars},nl2br:function(){return a.nl2br},safeHTML:function(){return l.safeHTML},sanitizeHTMLElement:function(){return l.sanitizeHTMLElement},stripTags:function(){return c.stripTags}});var o=n(32574),r=n(53212),s=n(53326),a=n(45971),l=n(86518),c=n(91003)},45971:function(t,i,n){"use strict";function o(t){return t.replace(/\r\n|\r|\n/g,"<br/>")}n.d(i,{nl2br:function(){return o}})},86518:function(t,i,n){"use strict";n.d(i,{safeHTML:function(){return a},sanitizeHTMLElement:function(){return u}});var o=n(2748),r=n(43555);let s=new Set(["foreignobject","annotation-xml","desc","title"]);function a(t,i){var n;if(!o.Dom.isElement(t)&&!o.Dom.isFragment(t))return;let a=t.querySelectorAll("math *, svg *");for(let i=0;i<a.length;i++)t.contains(a[i])&&function(t){if("http://www.w3.org/1999/xhtml"!==t.namespaceURI||null==t.closest("math,svg"))return!1;for(let i=t.parentElement;i;i=i.parentElement){let t=i.nodeName.toLowerCase();if("math"===t||"svg"===t)break;if(s.has(t))return!1}return!0}(a[i])&&o.Dom.safeRemove(a[i]);let l=null!=(n=i.removeEventAttributes)?n:i.removeOnError,c=t=>{if(o.Dom.isElement(t)&&(l&&function(t){if(!o.Dom.isElement(t))return;let i=[];for(let n=0;n<t.attributes.length;n++)t.attributes[n].name.toLowerCase().startsWith("on")&&i.push(t.attributes[n].name);for(let n of i)t.removeAttribute(n)}(t),u(t,i),i.safeLinksTarget&&"A"===t.nodeName&&"_blank"===t.getAttribute("target"))){let i=(t.getAttribute("rel")||"").split(/\s+/).filter(Boolean);i.includes("noopener")||i.push("noopener"),i.includes("noreferrer")||i.push("noreferrer"),(0,r.attr)(t,"rel",i.join(" "))}};c(t),o.Dom.each(t,c)}let l=["src","data","action","formaction","poster","background","xlink:href"],c=new Set(["iframe","frame","object","embed"]);function d(t,i){let n=t.replace(/[\u0000-\u0020]+/g,"").toLowerCase();return!!(/^(?:javascript|vbscript|livescript|mocha):/.test(n)||/^data:(?:text\/html|application\/xhtml)/.test(n))||/^data:image\/svg/.test(n)&&c.has(i)}function u(t,{safeJavaScriptLink:i,removeOnError:n}={safeJavaScriptLink:!0,removeOnError:!0}){if(!o.Dom.isElement(t))return!1;let s=!1;n&&t.hasAttribute("onerror")&&((0,r.attr)(t,"onerror",null),s=!0);let a=t.nodeName.toLowerCase(),c=t.getAttribute("href");if(i&&c&&d(c,a)){let i="u">typeof location?location.protocol:"http:";(0,r.attr)(t,"href",i+"//"+c),s=!0}if(i)for(let i of(t.hasAttribute("srcdoc")&&((0,r.attr)(t,"srcdoc",null),s=!0),l)){let n=t.getAttribute(i);n&&d(n,a)&&((0,r.attr)(t,i,null),s=!0)}return s}},91003:function(t,i,n){"use strict";n.d(i,{stripTags:function(){return function t(i,n=document,u=null,h=!1){let p=n.createElement("div");return(0,r.isString)(i)?p.innerHTML=i:p.appendChild(i),(0,a.$$)("*",p).forEach(i=>{let r=i.parentNode;if(!r)return;if(u&&o.Dom.isTag(i,u)){let r=i.nodeName.toLowerCase(),s=o.Dom.isTag(i,d)?`%%%jodit-single-${r}%%%`:`%%%jodit-${r}%%%${t(i.innerHTML,n,u,h)}%%%/jodit-${r}%%%`;o.Dom.before(i,n.createTextNode(s)),o.Dom.safeRemove(i);return}if(o.Dom.isTag(i,c))return void o.Dom.safeRemove(i);if(!o.Dom.isTag(i,l))return;let s=i.nextSibling;!(o.Dom.isText(s)&&/^\s/.test(s.nodeValue||""))&&s&&r.insertBefore(n.createTextNode(h?"%%%jodit-single-br%%%":" "),s)}),(0,s.trim)(p.innerText).replace(/%%%(\/)?jodit(-single)?-([\w\n]+)%%%/g,(t,i,n,o)=>`<${i?"/":""}${o}>`)}}});var o=n(2748),r=n(70799),s=n(49055),a=n(43555);let l=new Set(["div","p","br","h1","h2","h3","h4","h5","h6","hr"]),c=new Set(["script","style"]),d=new Set(["br","hr","input"])},21537:function(t,i,n){"use strict";n.r(i),n.d(i,{$$:function(){return h.$$},CamelCaseToKebabCase:function(){return u.CamelCaseToKebabCase},ConfigDeepFlatten:function(){return h.ConfigDeepFlatten},ConfigFlatten:function(){return h.ConfigFlatten},ConfigMerge:function(){return h.ConfigMerge},ConfigProto:function(){return h.ConfigProto},ConnectionError:function(){return h.ConnectionError},LimitedStack:function(){return h.LimitedStack},NUMBER_FIELDS_REG:function(){return c.NUMBER_FIELDS_REG},OptionsError:function(){return h.OptionsError},UNSAFE_PROTO_KEYS:function(){return h.UNSAFE_PROTO_KEYS},abort:function(){return h.abort},alignElement:function(){return h.alignElement},alreadyLoadedList:function(){return h.alreadyLoadedList},appendScriptAsync:function(){return h.appendScriptAsync},appendStyleAsync:function(){return h.appendStyleAsync},applyStyles:function(){return l.applyStyles},asArray:function(){return o.asArray},assert:function(){return h.assert},attr:function(){return h.attr},browser:function(){return h.browser},buildQuery:function(){return h.buildQuery},call:function(){return h.call},callPromise:function(){return h.callPromise},callThis:function(){return h.callThis},camelCase:function(){return u.camelCase},cleanFromWord:function(){return l.cleanFromWord},clearAlign:function(){return h.clearAlign},clearCenterAlign:function(){return h.clearCenterAlign},clearTimeout:function(){return r.clearTimeout},cns:function(){return h.cns},colorToHex:function(){return a.colorToHex},completeUrl:function(){return h.completeUrl},connection:function(){return h.connection},convertMediaUrlToVideoEmbed:function(){return h.convertMediaUrlToVideoEmbed},css:function(){return h.css},cssPath:function(){return h.cssPath},ctrlKey:function(){return h.ctrlKey},dataBind:function(){return h.dataBind},defaultLanguage:function(){return h.defaultLanguage},error:function(){return h.error},fastClone:function(){return h.fastClone},fuzzySearchIndex:function(){return u.fuzzySearchIndex},get:function(){return h.get},getClassName:function(){return h.getClassName},getContentWidth:function(){return d.getContentWidth},getDataTransfer:function(){return h.getDataTransfer},getFixedPositionOffset:function(){return d.getFixedPositionOffset},getPropertyDescriptor:function(){return h.getPropertyDescriptor},getScrollParent:function(){return d.getScrollParent},getXPathByElement:function(){return h.getXPathByElement},hAlignElement:function(){return h.hAlignElement},hasBrowserColorPicker:function(){return s.hasBrowserColorPicker},hasContainer:function(){return s.hasContainer},htmlspecialchars:function(){return l.htmlspecialchars},humanSizeToBytes:function(){return h.humanSizeToBytes},i18n:function(){return u.i18n},inView:function(){return h.inView},innerWidth:function(){return d.innerWidth},isAbortError:function(){return s.isAbortError},isArray:function(){return s.isArray},isAtom:function(){return h.isAtom},isBoolean:function(){return s.isBoolean},isDestructable:function(){return s.isDestructable},isEqual:function(){return s.isEqual},isFastEqual:function(){return s.isFastEqual},isFunction:function(){return s.isFunction},isHTML:function(){return s.isHTML},isHtmlFromWord:function(){return s.isHtmlFromWord},isInitable:function(){return s.isInitable},isInt:function(){return s.isInt},isJoditObject:function(){return s.isJoditObject},isLicense:function(){return s.isLicense},isMarker:function(){return s.isMarker},isNativeFunction:function(){return s.isNativeFunction},isNumber:function(){return s.isNumber},isNumeric:function(){return s.isNumeric},isPlainObject:function(){return s.isPlainObject},isPromise:function(){return s.isPromise},isSet:function(){return s.isSet},isString:function(){return s.isString},isStringArray:function(){return s.isStringArray},isURL:function(){return s.isURL},isUnsafeProtoKey:function(){return h.isUnsafeProtoKey},isValidName:function(){return s.isValidName},isViewObject:function(){return s.isViewObject},isVoid:function(){return s.isVoid},isWindow:function(){return s.isWindow},kebabCase:function(){return u.kebabCase},keepNames:function(){return h.keepNames},keys:function(){return h.keys},loadImage:function(){return h.loadImage},loadNext:function(){return h.loadNext},loadNextStyle:function(){return h.loadNextStyle},markAsAtomic:function(){return h.markAsAtomic},markDeprecated:function(){return h.markDeprecated},markOwner:function(){return h.markOwner},memorizeExec:function(){return h.memorizeExec},nl2br:function(){return l.nl2br},normalizeColor:function(){return c.normalizeColor},normalizeCssNumericValue:function(){return c.normalizeCssNumericValue},normalizeCssValue:function(){return c.normalizeCssValue},normalizeKeyAliases:function(){return c.normalizeKeyAliases},normalizeLicense:function(){return c.normalizeLicense},normalizePath:function(){return c.normalizePath},normalizeRelativePath:function(){return c.normalizeRelativePath},normalizeSize:function(){return c.normalizeSize},normalizeUrl:function(){return c.normalizeUrl},offset:function(){return d.offset},options:function(){return h.options},parseQuery:function(){return h.parseQuery},position:function(){return d.position},previewBox:function(){return h.previewBox},refs:function(){return h.refs},reset:function(){return h.reset},resolveElement:function(){return h.resolveElement},safeHTML:function(){return l.safeHTML},sanitizeHTMLElement:function(){return l.sanitizeHTMLElement},scrollIntoViewIfNeeded:function(){return h.scrollIntoViewIfNeeded},set:function(){return h.set},setTimeout:function(){return r.setTimeout},size:function(){return d.size},splitArray:function(){return o.splitArray},sprintf:function(){return u.sprintf},stringify:function(){return u.stringify},stripTags:function(){return l.stripTags},toArray:function(){return o.toArray},trim:function(){return u.trim},trimChars:function(){return u.trimChars},trimInv:function(){return u.trimInv},ucfirst:function(){return u.ucfirst}});var o=n(76855),r=n(91898),s=n(27613),a=n(58149),l=n(75275),c=n(71521),d=n(56175),u=n(59007),h=n(43555)},71521:function(t,i,n){"use strict";n.d(i,{NUMBER_FIELDS_REG:function(){return r.NUMBER_FIELDS_REG},normalizeColor:function(){return o.normalizeColor},normalizeCssNumericValue:function(){return r.normalizeCssNumericValue},normalizeCssValue:function(){return r.normalizeCssValue},normalizeKeyAliases:function(){return s.normalizeKeyAliases},normalizeLicense:function(){return a.normalizeLicense},normalizePath:function(){return l.normalizePath},normalizeRelativePath:function(){return c.normalizeRelativePath},normalizeSize:function(){return d.normalizeSize},normalizeUrl:function(){return u.normalizeUrl}});var o=n(21224),r=n(3760),s=n(49033),a=n(12972),l=n(9992),c=n(70091),d=n(46334),u=n(37406)},21224:function(t,i,n){"use strict";n.d(i,{normalizeColor:function(){return s}});var o=n(35278),r=n(49055);let s=t=>{let i=["#"],n=(0,o.colorToHex)(t);if(!n)return!1;if(3===(n=(n=(0,r.trim)(n.toUpperCase())).substring(1)).length){for(let t=0;t<3;t+=1)i.push(n[t]),i.push(n[t]);return i.join("")}return n.length>6&&(n=n.slice(0,6)),"#"+n}},3760:function(t,i,n){"use strict";n.d(i,{NUMBER_FIELDS_REG:function(){return l},normalizeCssNumericValue:function(){return c},normalizeCssValue:function(){return d}});var o=n(29807),r=n(86068),s=n(35278),a=n(12475);let l=/^(left|top|bottom|right|width|min|max|height|margin|padding|fontsize|font-size)/i;function c(t,i){return!(0,r.isVoid)(i)&&l.test(t)&&(0,o.isNumeric)(i.toString())?parseInt(i.toString(),10)+"px":i}function d(t,i){if("font-weight"===(0,a.kebabCase)(t)){switch(i.toString().toLowerCase()){case"700":case"bold":return 700;case"400":case"normal":return 400;case"900":case"heavy":return 900}return(0,o.isNumeric)(i)?Number(i):i}return/color/i.test(t)&&/^rgb/i.test(i.toString())&&(0,s.colorToHex)(i.toString())||i}},49033:function(t,i,n){"use strict";n.d(i,{normalizeKeyAliases:function(){return s}});var o=n(82758),r=n(49055);function s(t){let i={},n={meta:1,ctrl:2,control:2,alt:3,shift:4,space:5};return t.replace(/\+\+/g,"+add").split(/[\s]*\+[\s]*/).map(t=>(0,r.trim)(t.toLowerCase())).map(t=>o.KEY_ALIASES[t]||t).sort((t,i)=>n[t]&&!n[i]?-1:!n[t]&&n[i]?1:n[t]&&n[i]?n[t]-n[i]:t>i?1:-1).filter(t=>!i[t]&&""!==t&&(i[t]=!0)).join("+")}},12972:function(t,i,n){"use strict";n.d(i,{normalizeLicense:function(){return o}});let o=(t,i=8)=>{let n=[];for(;t.length;)n.push(t.substr(0,i)),t=t.substr(i);return n[1]=n[1].replace(/./g,"*"),n[2]=n[2].replace(/./g,"*"),n.join("-")}},9992:function(t,i,n){"use strict";n.d(i,{normalizePath:function(){return r}});var o=n(49055);let r=(...t)=>t.filter(t=>(0,o.trim)(t).length).map((i,n)=>(i=i.replace(/([^:])[\\/]+/g,"$1/"),n&&(i=i.replace(/^\//,"")),n!==t.length-1&&(i=i.replace(/\/$/,"")),i)).join("/")},70091:function(t,i,n){"use strict";n.d(i,{normalizeRelativePath:function(){return o}});let o=t=>t.split("/").reduce((t,i)=>{switch(i){case"":case".":break;case"..":t.pop();break;default:t.push(i)}return t},[]).join("/")+(t.endsWith("/")?"/":"")},46334:function(t,i,n){"use strict";n.d(i,{normalizeSize:function(){return o}});let o=(t,i)=>/^[0-9]+$/.test(t.toString())?t+i:t.toString()},37406:function(t,i,n){"use strict";n.d(i,{normalizeUrl:function(){return o}});let o=(...t)=>t.filter(t=>t.length).map(t=>t.replace(/\/$/,"")).join("/").replace(/([^:])[\\/]+/g,"$1/")},44506:function(t,i,n){"use strict";n.d(i,{getContentWidth:function(){return o}});let o=(t,i)=>{let n=i.getComputedStyle(t);return t.offsetWidth-parseInt(n.getPropertyValue("padding-left")||"0",10)-parseInt(n.getPropertyValue("padding-right")||"0",10)}},35224:function(t,i,n){"use strict";function o(t){var i,n;let o=null==(i=t.ownerDocument)?void 0:i.defaultView,r=t.parentElement;for(;o&&r;){if(""!==(n=o.getComputedStyle(r)).transform&&"none"!==n.transform||""!==n.perspective&&"none"!==n.perspective||""!==n.filter&&"none"!==n.filter||"transform"===n.willChange||"perspective"===n.willChange||"filter"===n.willChange||"paint"===n.contain||"layout"===n.contain||"strict"===n.contain||"content"===n.contain){let t=r.getBoundingClientRect();return{x:t.left,y:t.top}}r=r.parentElement}return{x:0,y:0}}n.d(i,{getFixedPositionOffset:function(){return o}})},16442:function(t,i,n){"use strict";n.d(i,{getScrollParent:function(){return function t(i){if(!i)return null;let n=r.Dom.isHTMLElement(i),a=n&&(0,s.css)(i,"overflowY");return n&&"visible"!==a&&"hidden"!==a&&i.scrollHeight>=i.clientHeight?i:t(i.parentNode)||o.globalDocument.scrollingElement||o.globalDocument.body}}});var o=n(82758),r=n(2748),s=n(43555)},56175:function(t,i,n){"use strict";n.d(i,{getContentWidth:function(){return o.getContentWidth},getFixedPositionOffset:function(){return r.getFixedPositionOffset},getScrollParent:function(){return s.getScrollParent},innerWidth:function(){return a.innerWidth},offset:function(){return c.offset},position:function(){return d.position},size:function(){return l.size}});var o=n(44506),r=n(35224),s=n(16442),a=n(81630),l=n(21496),c=n(81284),d=n(5700)},81630:function(t,i,n){"use strict";n.d(i,{innerWidth:function(){return o}});let o=(t,i)=>{let n=i.getComputedStyle(t);return t.clientWidth-(parseFloat(n.paddingLeft||"0")+parseFloat(n.paddingRight||"0"))}},21496:function(t,i,n){"use strict";n.d(i,{size:function(){return r}});var o=n(27613);function r(t){return(0,o.isString)(t)||(0,o.isArray)(t)?t.length:(0,o.isPlainObject)(t)?Object.keys(t).length:0}},81284:function(t,i,n){"use strict";n.d(i,{offset:function(){return o}});let o=(t,i,n,r=!1)=>{let s,a,l;try{s=t.getBoundingClientRect()}catch(t){s={top:0,bottom:0,left:0,right:0,width:0,height:0}}let c=n.body,d=n.documentElement||{clientTop:0,clientLeft:0,scrollTop:0,scrollLeft:0},u=n.defaultView||n.parentWindow,h=u.pageYOffset||d.scrollTop||c.scrollTop,p=u.pageXOffset||d.scrollLeft||c.scrollLeft,f=d.clientTop||c.clientTop||0,m=d.clientLeft||c.clientLeft||0,g=i.iframe;if(!r&&i&&i.options&&i.o.iframe&&g){let{top:t,left:n}=o(g,i,i.od,!0);a=s.top+t,l=s.left+n}else a=s.top+h-f,l=s.left+p-m;return{top:Math.round(a),left:Math.round(l),width:s.width,height:s.height}}},5700:function(t,i,n){"use strict";n.d(i,{position:function(){return function t(i,n,r=!1){var s,a;let l=i.getBoundingClientRect(),c=l.left,d=l.top;if((0,o.isJoditObject)(n)&&n.iframe&&n.ed.body.contains(i)&&!r){let{left:i,top:o}=t(n.iframe,n,!0);c+=i,d+=o}return{left:Math.round(c),top:Math.round(d),width:Math.round(null!=(s=i.offsetWidth)?s:l.width),height:Math.round(null!=(a=i.offsetHeight)?a:l.height)}}}});var o=n(19306)},87058:function(t,i,n){"use strict";n.d(i,{camelCase:function(){return o}});let o=t=>t.replace(/([-_])(.)/g,(t,i,n)=>n.toUpperCase())},67477:function(t,i,n){"use strict";n.d(i,{fuzzySearchIndex:function(){return r}});var o=n(82758);function r(t,i,n=0,s=1){let a=0,l=0,c=-1,d=0,u=0;for(l=n;a<t.length&&l<i.length;)t[a].toLowerCase()===i[l].toLowerCase()?(a++,d++,u=0,-1===c&&(c=l)):a>0&&(u>=s&&i[l]!==o.INVISIBLE_SPACE?(a=0,c=-1,d=0,u=0,l--):(u++,d++)),l++;return a===t.length?[c,d]:[-1,0]}},56967:function(t,i,n){"use strict";n.d(i,{i18n:function(){return d},sprintf:function(){return c}});var o=n(82758),r=n(70799),s=n(36409),a=n(43555),l=n(6441);let c=(t,i)=>{if(!i||!i.length)return t;let n=/%([sd])/g,o=n.exec(t),r=t,s=0;for(;o&&void 0!==i[s];)r=r.replace(o[0],i[s].toString()),s+=1,o=n.exec(t);return r};function d(t,i,n){if(!(0,r.isString)(t))throw(0,a.error)("i18n: Need string in first argument");if(!t.length)return t;let d=!!(null==n?void 0:n.debugLanguage),u={},h=t=>i&&i.length?c(t,i):t,p=(0,a.defaultLanguage)(l.Config.defaultOptions.language,l.Config.defaultOptions.language),f=(0,a.defaultLanguage)(null==n?void 0:n.language,p),m=i=>{if(!i)return;if((0,r.isString)(i[t]))return h(i[t]);let n=t.toLowerCase();if((0,r.isString)(i[n]))return h(i[n]);let o=(0,s.ucfirst)(t);if((0,r.isString)(i[o]))return h(i[o])};void 0!==o.lang[f]?u=o.lang[f]:d||(u=void 0!==o.lang[p]?o.lang[p]:o.lang.en);let g=null==n?void 0:n.i18n;if(g&&g[f]){let t=m(g[f]);if(t)return t}return m(u)||(!d&&o.lang.en&&(0,r.isString)(o.lang.en[t])&&o.lang.en[t]?h(o.lang.en[t]):d?"{"+t+"}":(o.IS_PROD,h(t)))}},59007:function(t,i,n){"use strict";n.d(i,{CamelCaseToKebabCase:function(){return a.CamelCaseToKebabCase},camelCase:function(){return o.camelCase},fuzzySearchIndex:function(){return r.fuzzySearchIndex},i18n:function(){return s.i18n},kebabCase:function(){return a.kebabCase},sprintf:function(){return s.sprintf},stringify:function(){return l.stringify},trim:function(){return c.trim},trimChars:function(){return c.trimChars},trimInv:function(){return c.trimInv},ucfirst:function(){return d.ucfirst}});var o=n(87058),r=n(67477),s=n(56967),a=n(12475),l=n(67462),c=n(49055),d=n(36409)},12475:function(t,i,n){"use strict";n.d(i,{CamelCaseToKebabCase:function(){return r},kebabCase:function(){return o}});let o=t=>t.replace(/([A-Z])([A-Z])([a-z])/g,"$1-$2$3").replace(/([a-z])([A-Z])/g,"$1-$2").replace(/[\s_]+/g,"-").toLowerCase(),r=t=>t.replace(/([A-Z])([A-Z])([a-z])/g,"$1-$2$3").replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()},67462:function(t,i,n){"use strict";function o(t,i={}){if("object"!=typeof t)return t+"";let n=new Set(i.excludeKeys),r=new WeakMap;return JSON.stringify(t,(t,i)=>{if(!n.has(t)){if("object"==typeof i&&null!=i){if(r.get(i))return"[refObject]";r.set(i,!0)}return i}},i.prettify)}n.d(i,{stringify:function(){return o}})},49055:function(t,i,n){"use strict";n.d(i,{trim:function(){return r},trimChars:function(){return s},trimInv:function(){return a}});var o=n(82758);function r(t){return t.replace((0,o.SPACE_REG_EXP_END)(),"").replace((0,o.SPACE_REG_EXP_START)(),"")}function s(t,i){return t.replace(RegExp(`[${i}]+$`),"").replace(RegExp(`^[${i}]+`),"")}function a(t){return t.replace((0,o.INVISIBLE_SPACE_REG_EXP_END)(),"").replace((0,o.INVISIBLE_SPACE_REG_EXP_START)(),"")}},36409:function(t,i,n){"use strict";function o(t){return t.length?t[0].toUpperCase()+t.substring(1):""}n.d(i,{ucfirst:function(){return o}})},25726:function(t,i,n){"use strict";n.d(i,{alignElement:function(){return l},clearAlign:function(){return a},hAlignElement:function(){return s}});var o=n(22732),r=n(41180);function s(t,i){i&&"normal"!==i?"center"!==i?((0,r.css)(t,"float",i),(0,r.clearCenterAlign)(t)):(0,r.css)(t,{float:"",display:"block",marginLeft:"auto",marginRight:"auto"}):((0,r.css)(t,"float")&&-1!==["right","left"].indexOf((0,r.css)(t,"float").toString().toLowerCase())&&(0,r.css)(t,"float",""),(0,r.clearCenterAlign)(t))}function a(t){o.Dom.each(t,t=>{o.Dom.isHTMLElement(t)&&t.style.textAlign&&(t.style.textAlign="",t.style.cssText.trim().length||t.removeAttribute("style"))})}function l(t,i){if(o.Dom.isNode(i)&&o.Dom.isElement(i))switch(a(i),t.toLowerCase()){case"justifyfull":i.style.textAlign="justify";break;case"justifyright":i.style.textAlign="right";break;case"justifyleft":i.style.textAlign="left";break;case"justifycenter":i.style.textAlign="center"}}},63799:function(t,i,n){"use strict";n.d(i,{alreadyLoadedList:function(){return s},appendScriptAsync:function(){return l},appendStyleAsync:function(){return c},loadNext:function(){return function t(i,n,r=0){return(0,o.isString)(n[r])?l(i,n[r]).then(()=>t(i,n,r+1)):Promise.resolve()}},loadNextStyle:function(){return function t(i,n,r=0){return(0,o.isString)(n[r])?c(i,n[r]).then(()=>t(i,n,r+1)):Promise.resolve()}}});var o=n(70799),r=n(66292);let s=new Map,a=t=>(i,n)=>{if(s.has(n))return s.get(n);let o=t(i,n);return s.set(n,o),o},l=a((t,i)=>t.async.promise((n,o)=>{if(t.isInDestruct)return o();let s=t.c.element("script",{type:"text/javascript",crossorigin:"anonymous",referrerpolicy:"no-referrer",async:!0,src:(0,r.completeUrl)(i)});t.o.nonce&&s.setAttribute("nonce",t.o.nonce),t.e.one(s,"error",o).one(s,"load",n),t.od.body.appendChild(s)})),c=a((t,i)=>t.async.promise((n,o)=>{if(t.isInDestruct)return o();let s=t.c.element("link");s.rel="stylesheet",s.media="all",s.crossOrigin="anonymous",t.o.nonce&&s.setAttribute("nonce",t.o.nonce),t.isInDestruct||t.e.on(s,"load",()=>n(s)).on(s,"error",o),s.href=(0,r.completeUrl)(i),t.o.shadowRoot?t.o.shadowRoot.appendChild(s):t.od.body.appendChild(s)}))},38837:function(t,i,n){"use strict";n.d(i,{assert:function(){return r}});class o extends Error{constructor(t){super(t),this.name="AssertionError"}}function r(t,i){if(!t)throw new o("Assertion failed: "+i)}},29960:function(t,i,n){"use strict";n.d(i,{attr:function(){return function t(i,n,c){if(!i||!(0,o.isFunction)(i.getAttribute))return null;if(!(0,s.isString)(n))return Object.keys(n).forEach(o=>{let s=n[o];(0,r.isPlainObject)(s)&&"style"===o?(0,l.css)(i,s):("className"===o&&(o="class"),t(i,o,s))}),null;let d=(0,a.CamelCaseToKebabCase)(n);if(/^-/.test(d)){let n=t(i,"data"+d);if(n)return n;d=d.substr(1)}if(void 0!==c)if(null==c)i.hasAttribute(d)&&i.removeAttribute(d);else{let t=c.toString();return"IMG"===i.nodeName&&("width"===d||"height"===d)&&(t=t.replace("px","")),i.setAttribute(d,t),t}return i.getAttribute(d)}}});var o=n(23282),r=n(72430),s=n(70799),a=n(12475),l=n(41180)},97639:function(t,i,n){"use strict";n.d(i,{browser:function(){return o}});let o=t=>{let i=navigator.userAgent.toLowerCase(),n=/(firefox)[\s/]([\w.]+)/.exec(i)||/(chrome)[\s/]([\w.]+)/.exec(i)||/(webkit)[\s/]([\w.]+)/.exec(i)||/(opera)(?:.*version)[\s/]([\w.]+)/.exec(i)||/(msie)[\s]([\w.]+)/.exec(i)||/(trident)\/([\w.]+)/.exec(i)||0>i.indexOf("compatible")||[];return"version"===t?n[2]:"webkit"===t?"chrome"===n[1]||"webkit"===n[1]:"ff"===t?"firefox"===n[1]:"msie"===t?"trident"===n[1]||"msie"===n[1]:n[1]===t}},44710:function(t,i,n){"use strict";n.d(i,{buildQuery:function(){return r}});var o=n(72430);let r=(t,i)=>{let n=[],s=encodeURIComponent;for(let a in t)if(Object.prototype.hasOwnProperty.call(t,a)){let l=i?i+"["+a+"]":a,c=t[a];n.push((0,o.isPlainObject)(c)?r(c,l):s(l)+"="+s(c))}return n.join("&")}},66292:function(t,i,n){"use strict";n.d(i,{completeUrl:function(){return r}});var o=n(82758);let r=t=>("file:"===o.globalWindow.location.protocol&&/^\/\//.test(t)&&(t="https:"+t),t)},68934:function(t,i,n){"use strict";n.d(i,{ConfigDeepFlatten:function(){return function t(i){return(0,u.keys)(i,!1).reduce((n,o)=>(n[o]=(0,r.isPlainObject)(i[o])?t(i[o]):i[o],n),{})}},ConfigFlatten:function(){return h},ConfigMerge:function(){return function t(i,n){Object.keys(n).forEach(o=>{if((0,d.isUnsafeProtoKey)(o))return;let s=n[o],a=i[o];(0,r.isPlainObject)(s)&&(0,r.isPlainObject)(a)&&!(0,c.isAtom)(s)?t(a,s):i[o]=s})}},ConfigProto:function(){return function t(i,n,u=0){if(Object.getPrototypeOf(i)!==Object.prototype)return i;let h=l.Config.defaultOptions;if((0,s.isString)(i.preset)){if(void 0!==h.presets[i.preset]){let t=h.presets[i.preset];Object.keys(t).forEach(n=>{(0,a.isVoid)(i[n])&&(i[n]=t[n])})}delete i.preset}let p={};return Object.keys(i).forEach(s=>{if((0,d.isUnsafeProtoKey)(s))return;let a=i[s],l=n?n[s]:null;if((0,r.isPlainObject)(a)&&(0,r.isPlainObject)(l)&&!(0,c.isAtom)(a)){p[s]=t(a,l,u+1);return}if(0!==u&&(0,o.isArray)(a)&&!(0,c.isAtom)(a)&&(0,o.isArray)(l)){p[s]=[...a,...l.slice(a.length)];return}p[s]=a}),Object.setPrototypeOf(p,n),p}}});var o=n(68345),r=n(72430),s=n(70799),a=n(86068),l=n(6441),c=n(97735),d=n(69175),u=n(37790);function h(t){return(0,u.keys)(t,!1).reduce((i,n)=>(i[n]=t[n],i),{})}},55877:function(t,i,n){"use strict";n.d(i,{convertMediaUrlToVideoEmbed:function(){return a}});var o=n(82758),r=n(26049),s=n(82501);let a=(t,{width:i=400,height:n=345}={})=>{if(!(0,r.isURL)(t))return t;let a=o.globalDocument.createElement("a");a.href=t,i||(i=400),n||(n=345);let l=a.protocol||"";switch(a.hostname){case"www.vimeo.com":case"vimeo.com":{let o=a.pathname.split("/").filter(Boolean),r=o.findIndex(t=>/^\d+$/.test(t));if(-1===r)return t;let s=o[r],c=o[r+1];return c&&0===r&&(s+="/"+c),'<iframe width="'+i+'" height="'+n+'" src="'+l+"//player.vimeo.com/video/"+s+'" frameborder="0" allowfullscreen></iframe>'}case"youtube.com":case"www.youtube.com":case"m.youtube.com":case"music.youtube.com":case"youtu.be":case"www.youtu.be":{let o=(a.search?(0,s.parseQuery)(a.search):{}).v||a.pathname.substring(1);return(o=o.replace(/^(watch|embed|shorts|live|v)\//,"").replace(/\/$/,""))?'<iframe width="'+i+'" height="'+n+'" src="'+l+"//www.youtube.com/embed/"+o+'" frameborder="0" allowfullscreen></iframe>':t}}return t}},41180:function(t,i,n){"use strict";n.d(i,{clearCenterAlign:function(){return d},css:function(){return c}});var o=n(87612),r=n(72430),s=n(3760),a=n(87058),l=n(12475);function c(t,i,n,d=!1){if((0,o.isBoolean)(n)&&(d=n,n=void 0),(0,r.isPlainObject)(i)||void 0!==n){let o=(t,i,n)=>{void 0!==(n=(0,s.normalizeCssNumericValue)(i,n))&&(null==n||c(t,i,!0)!==(0,s.normalizeCssValue)(i,n))&&(t.style[i]=n)};if((0,r.isPlainObject)(i)){let n=Object.keys(i);for(let r=0;r<n.length;r+=1)o(t,(0,a.camelCase)(n[r]),i[n[r]])}else o(t,(0,a.camelCase)(i),n);return""}let u=(0,l.kebabCase)(i),h=t.ownerDocument||document,p=!!h&&(h.defaultView||h.parentWindow),f=t.style[i],m="";return void 0!==f&&""!==f?m=f:p&&!d&&(m=p.getComputedStyle(t).getPropertyValue(u)),s.NUMBER_FIELDS_REG.test(i)&&/^[-+]?[0-9.]+px$/.test(m.toString())&&(m=parseInt(m.toString(),10)),(0,s.normalizeCssValue)(i,m)}let d=t=>{"block"===c(t,"display")&&c(t,"display","");let{style:i}=t;"auto"===i.marginLeft&&"auto"===i.marginRight&&(i.marginLeft="",i.marginRight="")}},15456:function(t,i,n){"use strict";n.d(i,{ctrlKey:function(){return o}});let o=t=>{if("u">typeof navigator&&-1!==navigator.userAgent.indexOf("Mac OS X")){if(t.metaKey&&!t.altKey)return!0}else if(t.ctrlKey&&!t.altKey)return!0;return!1}},86583:function(t,i,n){"use strict";n.d(i,{dataBind:function(){return s}});var o=n(39955);let r=new WeakMap,s=(t,i,n)=>{let s=r.get(t);if(!s){s={},r.set(t,s);let i=null;(0,o.isViewObject)(t.j)&&(i=t.j.e),(0,o.isViewObject)(t)&&(i=t.e),i&&i.on("beforeDestruct",()=>{r.delete(t)})}return void 0===n?s[i]:(s[i]=n,n)}},96325:function(t,i,n){"use strict";n.d(i,{defaultLanguage:function(){return s}});var o=n(82758),r=n(70799);let s=(t,i="en")=>"auto"!==t&&(0,r.isString)(t)?t:o.globalDocument.documentElement&&o.globalDocument.documentElement.lang?o.globalDocument.documentElement.lang:navigator.language?navigator.language.substring(0,2):i},82760:function(t,i,n){"use strict";n.d(i,{connection:function(){return s},error:function(){return r},options:function(){return a}});var o=n(32880);function r(t){return TypeError(t)}function s(t){return new o.ConnectionError(t)}function a(t){return new o.OptionsError(t)}},93661:function(t,i,n){"use strict";function o(t="Aborted"){return new DOMException(t,"AbortError")}n.d(i,{abort:function(){return o}})},86397:function(t,i,n){"use strict";n.d(i,{ConnectionError:function(){return o}});class o extends Error{constructor(t){super(t),Object.setPrototypeOf(this,o.prototype)}}},32880:function(t,i,n){"use strict";n.d(i,{ConnectionError:function(){return r.ConnectionError},OptionsError:function(){return s.OptionsError},abort:function(){return o.abort}});var o=n(93661),r=n(86397),s=n(57865)},57865:function(t,i,n){"use strict";n.d(i,{OptionsError:function(){return o}});class o extends TypeError{constructor(t){super(t),Object.setPrototypeOf(this,o.prototype)}}},89890:function(t,i,n){"use strict";n.d(i,{ConnectionError:function(){return r.ConnectionError},OptionsError:function(){return r.OptionsError},abort:function(){return r.abort},connection:function(){return o.connection},error:function(){return o.error},options:function(){return o.options}});var o=n(82760),r=n(32880)},97735:function(t,i,n){"use strict";n.d(i,{fastClone:function(){return a},isAtom:function(){return r},markAsAtomic:function(){return s}});var o=n(67462);function r(t){return t&&t.isAtom}function s(t){return Object.defineProperty(t,"isAtom",{enumerable:!1,value:!0,configurable:!1}),t}function a(t){return JSON.parse((0,o.stringify)(t))}},80568:function(t,i,n){"use strict";n.d(i,{getClassName:function(){return s},keepNames:function(){return r}});var o=n(23282);let r=new Map,s=t=>{var i;if((0,o.isFunction)(t.className))return t.className();let n=(null==(i=t.constructor)?void 0:i.originalConstructor)||t.constructor;if(r.has(n))return r.get(n);if(n.name)return n.name;let s=new RegExp(/^\s*function\s*(\S*)\s*\(/),a=n.toString().match(s);return a?a[1]:""}},94643:function(t,i,n){"use strict";n.d(i,{get:function(){return s}});var o=n(70799),r=n(86068);function s(t,i){if(!(0,o.isString)(t)||!t.length)return null;let n=t.split("."),s=i;try{for(let t of n){if((0,r.isVoid)(s[t]))return null;s=s[t]}}catch(t){return null}return(0,r.isVoid)(s)?null:s}},38420:function(t,i,n){"use strict";n.d(i,{humanSizeToBytes:function(){return o}});let o=t=>{if(/^[0-9.]+$/.test(t.toString()))return parseFloat(t);let i=t.substr(-2,2).toUpperCase(),n=["KB","MB","GB","TB"],o=parseFloat(t.substr(0,t.length-2));return -1!==n.indexOf(i)?o*Math.pow(1024,n.indexOf(i)+1):parseInt(t,10)}},43555:function(t,i,n){"use strict";n.d(i,{$$:function(){return j.$$},ConfigDeepFlatten:function(){return u.ConfigDeepFlatten},ConfigFlatten:function(){return u.ConfigFlatten},ConfigMerge:function(){return u.ConfigMerge},ConfigProto:function(){return u.ConfigProto},ConnectionError:function(){return b.ConnectionError},LimitedStack:function(){return P.LimitedStack},OptionsError:function(){return b.OptionsError},UNSAFE_PROTO_KEYS:function(){return k.UNSAFE_PROTO_KEYS},abort:function(){return b.abort},alignElement:function(){return o.alignElement},alreadyLoadedList:function(){return r.alreadyLoadedList},appendScriptAsync:function(){return r.appendScriptAsync},appendStyleAsync:function(){return r.appendStyleAsync},assert:function(){return s.assert},attr:function(){return a.attr},browser:function(){return l.browser},buildQuery:function(){return c.buildQuery},call:function(){return L.call},callPromise:function(){return L.callPromise},callThis:function(){return L.callThis},clearAlign:function(){return o.clearAlign},clearCenterAlign:function(){return p.clearCenterAlign},cns:function(){return S.cns},completeUrl:function(){return d.completeUrl},connection:function(){return b.connection},convertMediaUrlToVideoEmbed:function(){return h.convertMediaUrlToVideoEmbed},css:function(){return p.css},cssPath:function(){return j.cssPath},ctrlKey:function(){return f.ctrlKey},dataBind:function(){return m.dataBind},defaultLanguage:function(){return g.defaultLanguage},error:function(){return b.error},fastClone:function(){return y.fastClone},get:function(){return w.get},getClassName:function(){return _.getClassName},getDataTransfer:function(){return L.getDataTransfer},getPropertyDescriptor:function(){return L.getPropertyDescriptor},getXPathByElement:function(){return j.getXPathByElement},hAlignElement:function(){return o.hAlignElement},humanSizeToBytes:function(){return C.humanSizeToBytes},inView:function(){return T.inView},isAtom:function(){return y.isAtom},isUnsafeProtoKey:function(){return k.isUnsafeProtoKey},keepNames:function(){return _.keepNames},keys:function(){return L.keys},loadImage:function(){return L.loadImage},loadNext:function(){return r.loadNext},loadNextStyle:function(){return r.loadNextStyle},markAsAtomic:function(){return y.markAsAtomic},markDeprecated:function(){return S.markDeprecated},markOwner:function(){return L.markOwner},memorizeExec:function(){return L.memorizeExec},options:function(){return b.options},parseQuery:function(){return x.parseQuery},previewBox:function(){return I.previewBox},refs:function(){return j.refs},reset:function(){return E.reset},resolveElement:function(){return j.resolveElement},scrollIntoViewIfNeeded:function(){return T.scrollIntoViewIfNeeded},set:function(){return A.set}});var o=n(25726),r=n(63799),s=n(38837),a=n(29960),l=n(97639),c=n(44710),d=n(66292),u=n(68934),h=n(55877),p=n(41180),f=n(15456),m=n(86583),g=n(96325),b=n(89890),y=n(97735),w=n(94643),_=n(80568),C=n(38420),k=n(69175),S=n(95942),x=n(82501),I=n(11628),E=n(58844),T=n(26395),j=n(76078),A=n(3703),P=n(50535),L=n(37790)},69175:function(t,i,n){"use strict";n.d(i,{UNSAFE_PROTO_KEYS:function(){return o},isUnsafeProtoKey:function(){return r}});let o=["__proto__","constructor","prototype"];function r(t){return -1!==o.indexOf(t)}},95942:function(t,i,n){"use strict";n.d(i,{cns:function(){return o},markDeprecated:function(){return r}});let o=console;function r(t,i=[""],n=null){return(...r)=>(o.warn(`Method "${i[0]}" deprecated.`+(i[1]?` Use "${i[1]}" instead`:"")),t.call(n,...r))}},82501:function(t,i,n){"use strict";n.d(i,{parseQuery:function(){return o}});let o=t=>{let i={},n=t.substring(1).split("&");for(let t=0;t<n.length;t+=1){let o=n[t].split("=");i[decodeURIComponent(o[0])]=decodeURIComponent(o[1]||"")}return i}},11628:function(t,i,n){"use strict";n.d(i,{previewBox:function(){return c}});var o=n(2748),r=n(70799),s=n(29960),a=n(41180),l=n(76078);function c(t,i,n="px",d=null){let u=[],h=function(t,i){let n=[];try{(0,l.$$)("img",t.editor).forEach(r=>{let a=[(0,s.attr)(r,"width"),(0,s.attr)(r,"height"),r.src];(0,s.attr)(r,{width:r.offsetWidth+i,height:r.offsetHeight+i});let l=t.createInside.a();t.ed.body.appendChild(l),l.href=r.src,r.src=l.href,o.Dom.safeRemove(l),n.push(()=>{var t;r.src=null!=(t=a[2])?t:"",(0,s.attr)(r,{width:a[0]||null,height:a[1]||null})})})}catch(t){throw n.forEach(t=>t()),n.length=0,t}return n}(t,n);try{let l=t.e.fire("beforePreviewBox",i,n);if(null!=l)return l;let c=t.c.div("jodit__preview-box jodit-context");d&&d.appendChild(c),(0,a.css)(c,{position:"relative",padding:16});let h=t.value||`<div style='position: absolute;left:50%;top:50%;transform: translateX(-50%) translateY(-50%);color:#ccc;'>${t.i18n("Empty")}</div>`;if(t.iframe){let i=t.create.element("iframe");(0,a.css)(i,{minWidth:800,minHeight:600,border:0}),c.appendChild(i);let n=i.contentWindow;if(n&&(t.e.fire("generateDocumentStructure.iframe",n.document,t),c=n.document.body,"function"==typeof ResizeObserver)){let o=!1,r=n.document.body,s=new ResizeObserver(t.async.debounce(()=>{s.unobserve(r),i.style.height=`${r.offsetHeight+20}px`,t.async.requestAnimationFrame(()=>{o||s.observe(r)})},100)),a=()=>{o=!0,s.unobserve(r),s.disconnect(),t.e.off("beforeDestruct",a)};u.push(a),t.e.on("beforeDestruct",a)}}else(0,a.css)(c,{minWidth:1024,minHeight:600,border:0});let p=(i,n)=>{let a=(0,r.isString)(n)?t.c.div():n;(0,r.isString)(n)&&(a.innerHTML=n);for(let t=0;t<a.childNodes.length;t+=1){let n=a.childNodes[t];if(o.Dom.isElement(n)){let t=i.ownerDocument.createElement(n.nodeName);for(let i=0;i<n.attributes.length;i+=1)(0,s.attr)(t,n.attributes[i].nodeName,n.attributes[i].nodeValue);0===n.childNodes.length||o.Dom.isTag(n,"table")?"SCRIPT"===n.nodeName?n.textContent&&(t.textContent=n.textContent):n.innerHTML&&(t.innerHTML=n.innerHTML):p(t,n);try{i.appendChild(t)}catch(t){}}else try{i.appendChild(n.cloneNode(!0))}catch(t){}}};return p(c,h),t.e.fire("afterPreviewBox",c),[c,()=>{u.forEach(t=>t())}]}finally{h.forEach(t=>t())}}},58844:function(t,i,n){"use strict";n.d(i,{reset:function(){return l}});var o=n(82758),r=n(23282),s=n(94643);let a={};function l(t){var i,n;if(!(t in a)){let n=o.globalDocument.createElement("iframe");try{if(n.src="about:blank",o.globalDocument.body.appendChild(n),!n.contentWindow)return null;let i=(0,s.get)(t,n.contentWindow),l=(0,s.get)(t.split(".").slice(0,-1).join("."),n.contentWindow);(0,r.isFunction)(i)&&(a[t]=i.bind(l))}catch(t){if(!o.IS_PROD)throw t}finally{null==(i=n.parentNode)||i.removeChild(n)}}return null!=(n=a[t])?n:null}},26395:function(t,i,n){"use strict";n.d(i,{inView:function(){return r},scrollIntoViewIfNeeded:function(){return s}});var o=n(2748);function r(t,i,n){let o=t.getBoundingClientRect(),r=t,s=o.top,a=o.height;for(;r&&r!==i&&r.parentNode;)if(s+a>(o=(r=r.parentNode).getBoundingClientRect()).bottom+1&&s>o.top||s+a<=o.top)return!1;return(s+a<=(n.documentElement&&n.documentElement.clientHeight||0)+1||s<=0)&&s+a>=0}function s(t,i,n){if(o.Dom.isHTMLElement(t)&&!r(t,i,n)){if(i.clientHeight!==i.scrollHeight){let n=t.offsetTop+t.offsetHeight-i.clientHeight;i.scrollTop=i.scrollTop<n?n:t.offsetTop}r(t,i,n)||t.scrollIntoView()}}},76078:function(t,i,n){"use strict";n.d(i,{$$:function(){return h},cssPath:function(){return m},getXPathByElement:function(){return p},refs:function(){return f},resolveElement:function(){return g}});var o=n(82758),r=n(2748),s=n(4510),a=n(70799),l=n(87058),c=n(29960),d=n(89890);let u=1;function h(t,i){let n;if(!o.IS_ES_NEXT&&/:scope/.test(t)&&o.IS_IE&&!(i&&i.nodeType===Node.DOCUMENT_NODE)){let o=i.id,r=o||"_selector_id_"+(Math.random()+"").slice(2)+ ++u;t=t.replace(/:scope/g,"#"+r),o||i.setAttribute("id",r),n=i.parentNode.querySelectorAll(t),o||i.removeAttribute("id")}else n=i.querySelectorAll(t);return[].slice.call(n)}let p=(t,i)=>{if(!t||t.nodeType!==Node.ELEMENT_NODE||!t.parentNode||i===t)return"";if(t.id)return"//*[@id='"+t.id+"']";let n=[].filter.call(t.parentNode.childNodes,i=>i.nodeName===t.nodeName);return p(t.parentNode,i)+"/"+t.nodeName.toLowerCase()+(n.length>1?"["+((0,s.toArray)(n).indexOf(t)+1)+"]":"")},f=t=>("container"in t&&(t=t.container),h("[ref],[data-ref]",t).reduce((t,i)=>{let n=(0,c.attr)(i,"-ref");return n&&(0,a.isString)(n)&&(t[(0,l.camelCase)(n)]=i,t[n]=i),t},{})),m=t=>{if(!r.Dom.isElement(t))return null;let i=[],n=t;for(;n&&n.nodeType===Node.ELEMENT_NODE;){let t=n.nodeName.toLowerCase();if(n.id){t+="#"+n.id,i.unshift(t);break}{let i=n,o=1;do(i=i.previousElementSibling)&&i.nodeName.toLowerCase()===t&&o++;while(i)t+=":nth-of-type("+o+")"}i.unshift(t),n=n.parentNode}return i.join(" > ")};function g(t,i){let n=t;if((0,a.isString)(t))try{n=i.querySelector(t)}catch(i){throw(0,d.error)('String "'+t+'" should be valid HTML selector')}if(!n||"object"!=typeof n||!r.Dom.isElement(n)||!n.cloneNode)throw(0,d.error)('Element "'+t+'" should be string or HTMLElement instance');return n}},3703:function(t,i,n){"use strict";n.d(i,{set:function(){return c}});var o=n(68345),r=n(29807),s=n(72430),a=n(70799),l=n(69175);function c(t,i,n){if(!(0,a.isString)(t)||!t.length)return;let c=t.split(".");if(c.some(l.isUnsafeProtoKey))return;let d=n,u=c[0];for(let t=0;t<c.length-1;t+=1)u=c[t],(0,o.isArray)(d[u])||(0,s.isPlainObject)(d[u])||(d[u]=(0,r.isNumeric)(c[t+1])?[]:{}),d=d[u];d&&(d[c[c.length-1]]=i)}},50535:function(t,i,n){"use strict";n.d(i,{LimitedStack:function(){return o}});class o{push(t){return this.stack.push(t),this.stack.length>this.limit&&this.stack.shift(),this}pop(){return this.stack.pop()}find(t){return this.stack.find(t)}constructor(t){this.limit=t,this.stack=[]}}},37790:function(t,i,n){"use strict";n.d(i,{call:function(){return l},callPromise:function(){return u},callThis:function(){return c},getDataTransfer:function(){return m},getPropertyDescriptor:function(){return g},keys:function(){return p},loadImage:function(){return h},markOwner:function(){return d},memorizeExec:function(){return f}});var o=n(14773),r=n(86068),s=n(29960),a=n(86583);function l(t,...i){return t(...i)}function c(t,i,...n){return t.apply(i,n)}function d(t,i){(0,s.attr)(i,"data-editor_id",t.id),i.component||Object.defineProperty(i,"jodit",{value:t})}function u(t,i){return(0,o.isPromise)(t)?t.then(t=>t,()=>null).finally(i):null==i?void 0:i()}let h=(t,i)=>i.async.promise((n,o)=>{let r=new Image,s=()=>{i.e.off(r),null==o||o()},a=()=>{i.e.off(r),n(r)};i.e.one(r,"load",a).one(r,"error",s).one(r,"abort",s),r.src=t,r.complete&&a()}),p=(t,i=!0)=>{if(i)return Object.keys(t);let n=[];for(let i in t)n.push(i);return n},f=(t,i,{control:n},o)=>{var s;let l="button"+n.command,c=null!=(s=n.args&&n.args[0])?s:(0,a.dataBind)(t,l);if((0,r.isVoid)(c))return!1;(0,a.dataBind)(t,l,c),o&&(c=o(c)),t.execCommand(n.command,!1,null!=c?c:void 0)},m=t=>{if(t.clipboardData)return t.clipboardData;try{return t.dataTransfer||new DataTransfer}catch(t){return null}};function g(t,i){let n;do n=Object.getOwnPropertyDescriptor(t,i),t=Object.getPrototypeOf(t);while(!n&&t)return n}},31359:function(t,i,n){"use strict";n.d(i,{init:function(){return a}});var o=n(82758),r=n(60132),s=n(14041);function a(t,i,n,a,l,c,d){if((0,r.isInitable)(a))try{a.init(t)}catch(t){if(!o.IS_PROD)throw t}l.set(i,a),c.delete(i),a.hasStyle&&(0,s.loadStyle)(t,i).catch(t=>{o.IS_PROD}),a.styles&&(d(t,i,"style").innerHTML=a.styles)}},14041:function(t,i,n){"use strict";n.d(i,{loadExtras:function(){return u},loadStyle:function(){return c}});var o=n(82758),r=n(12475),s=n(63799),a=n(89672);let l=new Set;async function c(t,i){let n=d(t,i,!1);if(!l.has(n))return l.add(n),(0,s.appendStyleAsync)(t,n)}function d(t,i,n){i=(0,r.kebabCase)(i);let o=t.minified?".min":"";return t.basePath+"plugins/"+i+"/"+i+o+"."+(n?"js":"css")}function u(t,i,n,r){try{let o=n.filter(i=>!t.has((0,a.normalizeName)(i.name)));o.length&&o.map(t=>{let n=t.url||d(i,t.name,!0);return(0,s.appendScriptAsync)(i,n).then(r).catch(()=>null)})}catch(t){if(!o.IS_PROD)throw t}}},48591:function(t,i,n){"use strict";n.d(i,{makeInstance:function(){return s}});var o=n(82758),r=n(23282);function s(t,i){try{try{return(0,r.isFunction)(i)?new i(t):i}catch(n){if((0,r.isFunction)(i)&&!i.prototype)return i(t)}}catch(t){if(!o.IS_PROD)throw t}return null}},89672:function(t,i,n){"use strict";n.d(i,{normalizeName:function(){return r}});var o=n(12475);function r(t){return(0,o.kebabCase)(t).toLowerCase()}},50911:function(t,i,n){"use strict";n.d(i,{Plugin:function(){return o.Plugin}});var o=n(20356);n(41876)},41876:function(t,i,n){"use strict";n.d(i,{PluginSystem:function(){return f}});var o=n(82758),r=n(57012),s=n(46559),a=n(68345),l=n(60132),c=n(70799),d=n(31359),u=n(14041),h=n(48591),p=n(89672);class f{get size(){return this.__items.size}add(t,i){this.__items.set((0,p.normalizeName)(t),i),r.eventEmitter.fire(`plugin:${t}:ready`)}get(t){return this.__items.get((0,p.normalizeName)(t))}remove(t){this.__items.delete((0,p.normalizeName)(t))}__getFullPluginsList(t){let i=[];return this.__items.forEach((n,o)=>{(!t||t.has(o))&&i.push([o,n])}),i}__init(t){let{extraList:i,disableList:n,filter:r}={extraList:t.o.extraPlugins.map(t=>(0,c.isString)(t)?{name:t}:t),disableList:new Set((0,s.splitArray)(t.o.disablePlugins).map(p.normalizeName)),filter:t.o.safeMode?new Set(t.o.safePluginsList):null},f=new Map,m={},g=new Set;t.__plugins=m;let b=()=>{if(t.isInDestruct)return;let i=!1;this.__getFullPluginsList(r).forEach(([o,r])=>{if(n.has(o)||f.has(o))return;let s=null==r?void 0:r.requires;if(s&&(0,a.isArray)(s)&&s.length){if(s.some(t=>n.has(t)))return;if(!s.every(t=>f.has(t)))return void g.add(o)}i=!0;let l=(0,h.makeInstance)(t,r);if(!l){f.set(o,null),g.delete(o);return}(0,d.init)(t,o,r,l,f,g,this.opts.getContainer),m[o]=l}),i&&(t.e.fire("updatePlugins"),b())};i&&i.length&&(0,u.loadExtras)(this.__items,t,i,b),b(),t.e.on("beforeDestruct",()=>{Object.keys(m).forEach(i=>{let n=m[i];(0,l.isDestructable)(n)&&n.destruct(t),delete m[i]}),delete t.__plugins}),o.IS_PROD||g.size}wait(t){return new Promise(i=>{if(this.get(t))return i();let n=()=>{i(),r.eventEmitter.off(`plugin:${t}:ready`,n)};r.eventEmitter.on(`plugin:${t}:ready`,n)})}constructor(t){this.opts=t,this.__items=new Map}}},20356:function(t,i,n){"use strict";n.d(i,{Plugin:function(){return l}});var o=n(91907),r=n(65478),s=n(19306),a=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a};class l extends o.ViewComponent{className(){return"Plugin"}__afterPluginSystemInit(){let{j:t,buttons:i}=this;i&&(0,s.isJoditObject)(t)&&i.forEach(i=>{t.registerButton(i)})}__afterInit(){this.__inited=!0,this.setStatus(o.STATUSES.ready),this.afterInit(this.jodit)}init(t){this.jodit.isReady&&(this.afterInit(this.jodit),this.__afterPluginSystemInit(),this.jodit.e.fire("rebuildToolbar"))}__beforeDestruct(){var t;if(this.isInDestruct)return;let{j:i}=this;if(i.e.off("afterPluginSystemInit",this.__afterPluginSystemInit).off("afterInit",this.__afterInit).off("beforeDestruct",this.destruct),this.setStatus(o.STATUSES.beforeDestruct),!this.__inited)return super.destruct();(0,s.isJoditObject)(i)&&(null==(t=this.buttons)||t.forEach(t=>{null==i||i.unregisterButton(t)})),this.beforeDestruct(this.j),super.destruct()}constructor(t){super(t),this.buttons=[],this.hasStyle=!1,this.__inited=!1,t.e.on("afterPluginSystemInit",this.__afterPluginSystemInit).on("afterInit",this.__afterInit).on("beforeDestruct",this.__beforeDestruct)}}l.requires=[],a([r.autobind],l.prototype,"__afterPluginSystemInit",null),a([r.autobind],l.prototype,"__afterInit",null),a([r.autobind],l.prototype,"__beforeDestruct",null)},54079:function(t,i,n){"use strict";n.d(i,{Ajax:function(){return u}});var o=n(8884),r=n(82758),s=n(45219),a=n(21537),l=n(89890),c=n(6441);n(57459);var d=n(98582);class u{className(){return"Ajax"}__buildParams(t,i){return(0,a.isPlainObject)(t)&&this.options.contentType&&this.options.contentType.includes("application/json")?JSON.stringify(t):(0,a.isFunction)(this.o.queryBuild)?this.o.queryBuild.call(this,t,i):(0,a.isString)(t)||t instanceof r.globalWindow.FormData||"object"==typeof t&&null!=t&&(0,a.isFunction)(t.append)?t:(0,a.buildQuery)(t)}get o(){return this.options}abort(){if(this.__isFulfilled)return this;try{this.__isFulfilled=!0,this.xhr.abort()}catch(t){}return this}send(){this.__activated=!0;let{xhr:t,o:i}=this,n=this.prepareRequest();return this.__async.promise(async(o,r)=>{var s;let c=()=>{this.__isFulfilled=!0,r(l.connection("Connection error"))},u=()=>{this.__isFulfilled=!0,o(new d.Response(n,t.status,t.statusText,!t.responseType?t.responseText:t.response))};t.onload=u,t.onabort=()=>{this.__isFulfilled=!0,r(l.abort("Abort connection"))},t.onerror=c,t.ontimeout=c,i.responseType&&(t.responseType=i.responseType),t.onprogress=t=>{var i,n;let o=0;t.lengthComputable&&(o=t.loaded/t.total*100),null==(n=(i=this.options).onProgress)||n.call(i,o)},t.onreadystatechange=()=>{var n,o;null==(o=(n=this.options).onProgress)||o.call(n,10),t.readyState===XMLHttpRequest.DONE&&(i.successStatuses.includes(t.status)?u():t.statusText&&(this.__isFulfilled=!0,r(l.connection(t.statusText))))},t.withCredentials=null!=(s=i.withCredentials)&&s;let{url:h,data:p,method:f}=n;t.open(f,h,!0),i.contentType&&t.setRequestHeader&&t.setRequestHeader("Content-type",i.contentType);let{headers:m}=i;(0,a.isFunction)(m)&&(m=await m.call(this)),m&&t.setRequestHeader&&Object.keys(m).forEach(i=>{t.setRequestHeader(i,m[i])}),this.__async.setTimeout(()=>{t.send(p?this.__buildParams(p):void 0)},0)})}async *stream(){var t;this.__activated=!0;let{xhr:i,o:n}=this,o=this.prepareRequest(),r=0,s="",c=[],d=null,u=!1,h=null,p=()=>{if(d){let t=d;d=null,t()}},f=t=>{var n;let o=i.responseText;s+=o.substring(r),r=o.length;let a=s.split(`
|
|
19
19
|
|
|
20
20
|
`);for(let i of(s=t?"":null!=(n=a.pop())?n:"",a)){let t=i.trim();if(!t)continue;let n=[];for(let i of t.split(`
|
|
@@ -120,7 +120,7 @@
|
|
|
120
120
|
</div>`:""}
|
|
121
121
|
</div>
|
|
122
122
|
</div>
|
|
123
|
-
</form>`)}},41409:function(t,i,n){"use strict";n.r(i),n.d(i,{Ajax:function(){return f.Ajax},Alert:function(){return a.Alert},Async:function(){return c.Async},AsyncStorage:function(){return P.AsyncStorage},Button:function(){return m.Button},CommitStyle:function(){return A.CommitStyle},Component:function(){return o.Component},Confirm:function(){return a.Confirm},ContextMenu:function(){return s.ContextMenu},Create:function(){return d.Create},Dialog:function(){return a.Dialog},Dom:function(){return u.Dom},EventEmitter:function(){return h.EventEmitter},EventHandlersStore:function(){return h.EventHandlersStore},Eventify:function(){return h.Eventify},FileBrowser:function(){return l.FileBrowser},Helpers:function(){return r},History:function(){return y.History},Icon:function(){return m.Icon},ImageEditor:function(){return _.ImageEditor},IndexedDBProvider:function(){return P.IndexedDBProvider},LazyWalker:function(){return u.LazyWalker},LocalStorageProvider:function(){return P.LocalStorageProvider},MemoryStorageProvider:function(){return P.MemoryStorageProvider},Plugin:function(){return p.Plugin},PluginSystem:function(){return j.PluginSystem},Popup:function(){return m.Popup},ProgressBar:function(){return m.ProgressBar},Prompt:function(){return a.Prompt},Response:function(){return f.Response},STATUSES:function(){return o.STATUSES},Selection:function(){return A.Selection},Snapshot:function(){return w.Snapshot},StatusBar:function(){return k.StatusBar},Storage:function(){return P.Storage},StorageKey:function(){return P.StorageKey},Table:function(){return S.Table},ToolbarButton:function(){return x.ToolbarButton},ToolbarCollection:function(){return I.ToolbarCollection},ToolbarContent:function(){return x.ToolbarContent},ToolbarEditorCollection:function(){return E.ToolbarEditorCollection},ToolbarSelect:function(){return x.ToolbarSelect},UIBlock:function(){return m.UIBlock},UIButton:function(){return m.UIButton},UIButtonGroup:function(){return m.UIButtonGroup},UIButtonState:function(){return m.UIButtonState},UICheckbox:function(){return m.UICheckbox},UIElement:function(){return m.UIElement},UIFileInput:function(){return m.UIFileInput},UIForm:function(){return m.UIForm},UIGroup:function(){return m.UIGroup},UIInput:function(){return m.UIInput},UIList:function(){return m.UIList},UIMessages:function(){return C.UIMessages},UISelect:function(){return m.UISelect},UISeparator:function(){return m.UISeparator},UISpacer:function(){return m.UISpacer},UITextArea:function(){return m.UITextArea},UITooltip:function(){return m.UITooltip},Uploader:function(){return T.Uploader},View:function(){return g.View},ViewComponent:function(){return o.ViewComponent},ViewWithToolbar:function(){return b.ViewWithToolbar},canUseIndexedDB:function(){return P.canUseIndexedDB},canUsePersistentStorage:function(){return P.canUsePersistentStorage},clearUseIndexedDBCache:function(){return P.clearUseIndexedDBCache},defaultNameSpace:function(){return h.defaultNameSpace},observable:function(){return h.observable}});var o=n(91907),r=n(21537),s=n(80870),a=n(638),l=n(78513),c=n(8884),d=n(12060),u=n(22732),h=n(3827),p=n(50911),f=n(41601),m=n(67510),g=n(35608),b=n(84075),y=n(78818),w=n(52604),_=n(50050),C=n(1808),k=n(23512),S=n(76014),x=n(36646),I=n(11676),E=n(37426),T=n(57380),j=n(41876),A=n(59242),P=n(12081)},68389:function(t,i,n){"use strict";n.d(i,{UIMessage:function(){return s}});var o=n(87325),r=n(67510);let s=class t extends r.UIElement{className(){return"UIMessage"}constructor(t,i){super(t),this.setMod("active",!0),this.setMod("variant",i.variant),this.container.textContent=i.text}};s=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a}([o.component],s)},1808:function(t,i,n){"use strict";n.d(i,{UIMessages:function(){return l}});var o=n(87325),r=n(41180),s=n(62405),a=n(68389);let l=class t extends s.UIGroup{className(){return"UIMessages"}info(t,i){this.__message(t,"info",i)}success(t,i){this.__message(t,"success",i)}error(t,i){this.__message(t,"error",i)}message(t,i,n){this.__message(t,i,n)}__message(t,i="info",n){let o=t+":"+i;if(this.__messages.has(o))return void this.async.updateTimeout(o,n||this.options.defaultTimeout);if(!this.__box)throw Error("Container is not defined: "+o);this.__box.appendChild(this.container);let r=new a.UIMessage(this.j,{text:t,variant:i});this.append(r),this.__calcOffsets(),this.__messages.add(o);let s=this.__getRemoveCallback(r,o);this.j.e.on(r.container,"pointerdown",s),this.async.setTimeout(s,{label:o,timeout:n||this.options.defaultTimeout})}__getRemoveCallback(t,i){let n=o=>{o&&o.preventDefault(),t.isInDestruct||(this.async.clearTimeout(i),this.j.e.off(t.container,"pointerdown",n),this.__messages.delete(i),t.setMod("active",!1),this.async.setTimeout(()=>{this.remove(t),t.destruct(),this.__calcOffsets()},300))};return n}__calcOffsets(){let t=5;this.elements.forEach(i=>{(0,r.css)(i.container,"bottom",t+"px"),t+=i.container.offsetHeight+this.options.defaultOffset})}constructor(t,i,n={defaultTimeout:3e3,defaultOffset:5}){super(t),this.__box=i,this.options=n,this.__messages=new Set}};l=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a}([o.component],l)},23512:function(t,i,n){"use strict";n.d(i,{StatusBar:function(){return c}});var o=n(91907),r=n(65478),s=n(2748),a=n(14316),l=n(34176);let c=class t extends o.ViewComponent{className(){return"StatusBar"}hide(){this.container.classList.add("jodit_hidden")}show(){this.container.classList.remove("jodit_hidden")}get isShown(){return!this.container.classList.contains("jodit_hidden")}getHeight(){var t,i;return null!=(i=null==(t=this.container)?void 0:t.offsetHeight)?i:0}findEmpty(t=!1){let i=this.getElms(t?"item-right":"item");for(let t=0;t<i.length;t+=1)if(!i[t].innerHTML.trim().length)return i[t]}append(t,i=!1){var n;let o=this.findEmpty(i)||this.j.c.div(this.getFullElName("item"));i&&o.classList.add(this.getFullElName("item-right")),o.appendChild(t),null==(n=this.container)||n.appendChild(o),this.j.o.statusbar&&this.show(),this.j.e.fire("resize")}destruct(){this.isInDestruct||(this.setStatus(o.STATUSES.beforeDestruct),s.Dom.safeRemove(this.container),super.destruct())}constructor(t,i){super(t),this.target=i,this.mods={},this.container=t.c.div("jodit-status-bar"),i.appendChild(this.container),this.hide()}};c=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a}([r.component,(0,r.derive)(l.Mods,a.Elms)],c)},76014:function(t,i,n){"use strict";n.d(i,{Table:function(){return u}});var o=n(91907),r=n(82758),s=n(65478),a=n(22732),l=n(580),c=n(21537);let d=new WeakMap;class u extends o.ViewComponent{className(){return"Table"}__recalculateStyles(){let t=(0,l.getContainer)(this.j,u,"style",!0),i=[];this.selected.forEach(t=>{let n=(0,c.cssPath)(t);n&&i.push(n)}),t.innerHTML=i.length?i.join(",")+`{${this.jodit.options.table.selectionCellStyle}}`:""}addSelection(t){this.selected.add(t),this.__recalculateStyles();let i=a.Dom.closest(t,"table",this.j.editor);if(i){let n=u.__selectedByTable.get(i)||new Set;n.add(t),u.__selectedByTable.set(i,n)}}removeSelection(t){this.selected.delete(t),this.__recalculateStyles();let i=a.Dom.closest(t,"table",this.j.editor);if(i){let n=u.__selectedByTable.get(i);n&&(n.delete(t),n.size||u.__selectedByTable.delete(i))}}getAllSelectedCells(){return(0,c.toArray)(this.selected)}static __getSelectedCellsByTable(t){let i=u.__selectedByTable.get(t);return i?(0,c.toArray)(i):[]}destruct(){return this.selected.clear(),super.destruct()}static __getRowsCount(t){return t.rows.length}getRowsCount(t){return u.__getRowsCount(t)}static __getColumnsCount(t){return u.__formalMatrix(t).reduce((t,i)=>Math.max(t,i.length),0)}getColumnsCount(t){return u.__getColumnsCount(t)}static __formalMatrix(t,i){let n=[[]],o=(0,c.toArray)(t.rows),r=(t,o)=>{void 0===n[o]&&(n[o]=[]);let r=t.colSpan,s=t.rowSpan,a,l,c=0;for(;n[o][c];)c+=1;for(l=0;s>l;l+=1)for(a=0;a<r;a+=1){if(void 0===n[o+l]&&(n[o+l]=[]),i&&!1===i(t,o+l,c+a,r,s))return!1;n[o+l][c+a]=t}};for(let t=0;t<o.length;t+=1){let i=(0,c.toArray)(o[t].cells);for(let o=0;o<i.length;o+=1)if(!1===r(i[o],t))return n}return n}formalMatrix(t,i){return u.__formalMatrix(t,i)}static __formalCoordinate(t,i,n=!1){let o=0,r=0,s=1,a=1;return u.__formalMatrix(t,(t,l,c,d,u)=>{if(i===t)return o=l,r=c,s=d||1,a=u||1,n&&(r+=(d||1)-1,o+=(u||1)-1),!1}),[o,r,s,a]}formalCoordinate(t,i,n=!1){return u.__formalCoordinate(t,i,n)}static __appendRow(t,i,n,o){var r;let s;if(i)s=i.cloneNode(!0),(0,c.$$)("td,th",i).forEach(t=>{let i=(0,c.attr)(t,"rowspan");if(i&&parseInt(i,10)>1){let n=parseInt(i,10)-1;(0,c.attr)(t,"rowspan",n>1?n:null)}}),(0,c.$$)("td,th",s).forEach(t=>{t.innerHTML=""});else{let i=u.__getColumnsCount(t);s=o.element("tr");for(let t=0;t<i;t+=1)s.appendChild(o.element("td"))}n&&i&&i.nextSibling?i.parentNode&&i.parentNode.insertBefore(s,i.nextSibling):!n&&i?i.parentNode&&i.parentNode.insertBefore(s,i):((null==(r=t.getElementsByTagName("tbody"))?void 0:r[0])||t).appendChild(s)}appendRow(t,i,n){return u.__appendRow(t,i,n,this.j.createInside)}static __removeRow(t,i){let n,o=u.__formalMatrix(t),r=t.rows[i];o[i].forEach((s,l)=>{if(n=!1,i-1>=0&&o[i-1][l]===s)n=!0;else if(o[i+1]&&o[i+1][l]===s){if(s.parentNode===r&&s.parentNode.nextSibling){n=!0;let r=l+1;for(;o[i+1][r]===s;)r+=1;let c=a.Dom.next(s.parentNode,t=>a.Dom.isTag(t,"tr"),t);if(c){let t=null;for(let n=r;n<o[i+1].length;n+=1){let r=o[i+1][n];if(r&&r.parentNode===c){t=r;break}}t?c.insertBefore(s,t):c.appendChild(s)}}}else a.Dom.safeRemove(s);if(n&&(s.parentNode===r||s!==o[i][l-1])){let t=s.rowSpan;(0,c.attr)(s,"rowspan",t-1>1?t-1:null)}}),a.Dom.safeRemove(r)}removeRow(t,i){return u.__removeRow(t,i)}appendColumn(t,i,n=!0){let o=u.__formalMatrix(t);if(!n&&a.Dom.isCell(i.previousElementSibling))return this.appendColumn(t,i.previousElementSibling,!0);let[,r]=u.__formalCoordinate(t,i,n),s=n?r+1:r;for(let t=0;t<o.length;){let i=o[t];if(i[r]!==i[s]||r===s){let t=this.j.createInside.element("td");n?a.Dom.after(i[r],t):a.Dom.before(i[r],t),i[r].rowSpan>1&&(t.rowSpan=i[r].rowSpan)}else i[r].colSpan+=1;t+=i[r].rowSpan||1}}static __removeColumn(t,i){let n,o=u.__formalMatrix(t);o.forEach((t,r)=>{let s=t[i];if(n=!1,i-1>=0&&o[r][i-1]===s||i+1<t.length&&o[r][i+1]===s?n=!0:a.Dom.safeRemove(s),n&&(r-1<0||s!==o[r-1][i])){let t=s.colSpan;(0,c.attr)(s,"colspan",t-1>1?(t-1).toString():null)}})}removeColumn(t,i){return u.__removeColumn(t,i)}static __getSelectedBound(t,i){let n,o,r,s=[[1/0,1/0],[0,0]],a=u.__formalMatrix(t);for(n=0;n<a.length;n+=1)for(o=0;a[n]&&o<a[n].length;o+=1)i.includes(a[n][o])&&(s[0][0]=Math.min(n,s[0][0]),s[0][1]=Math.min(o,s[0][1]),s[1][0]=Math.max(n,s[1][0]),s[1][1]=Math.max(o,s[1][1]));for(n=s[0][0];n<=s[1][0];n+=1)for(r=1,o=s[0][1];o<=s[1][1];o+=1){for(;a[n]&&a[n][o-r]&&a[n][o]===a[n][o-r];)s[0][1]=Math.min(o-r,s[0][1]),s[1][1]=Math.max(o-r,s[1][1]),r+=1;for(r=1;a[n]&&a[n][o+r]&&a[n][o]===a[n][o+r];)s[0][1]=Math.min(o+r,s[0][1]),s[1][1]=Math.max(o+r,s[1][1]),r+=1;for(r=1;a[n-r]&&a[n][o]===a[n-r][o];)s[0][0]=Math.min(n-r,s[0][0]),s[1][0]=Math.max(n-r,s[1][0]),r+=1;for(r=1;a[n+r]&&a[n][o]===a[n+r][o];)s[0][0]=Math.min(n+r,s[0][0]),s[1][0]=Math.max(n+r,s[1][0]),r+=1}return s}getSelectedBound(t,i){return u.__getSelectedBound(t,i)}static __normalizeTable(t){let i=[],n=u.__formalMatrix(t);u.__removeExtraColspans(n,i),u.__removeExtraRowspans(n,i);for(let t=0;t<n.length;t+=1)for(let i=0;i<n[t].length;i+=1)void 0!==n[t][i]&&(n[t][i].hasAttribute("rowspan")&&1===n[t][i].rowSpan&&(0,c.attr)(n[t][i],"rowspan",null),n[t][i].hasAttribute("colspan")&&1===n[t][i].colSpan&&(0,c.attr)(n[t][i],"colspan",null),n[t][i].hasAttribute("class")&&!(0,c.attr)(n[t][i],"class")&&(0,c.attr)(n[t][i],"class",null));u.__unmark(i)}static __removeExtraColspans(t,i){for(let n=0;n<t[0].length;n+=1){let o=1e6,r=!1;for(let i=0;i<t.length;i+=1)if(void 0!==t[i][n]){if(t[i][n].colSpan<2){r=!0;break}o=Math.min(o,t[i][n].colSpan)}if(!r)for(let r=0;r<t.length;r+=1)void 0!==t[r][n]&&u.__mark(t[r][n],"colspan",t[r][n].colSpan-o+1,i)}}static __removeExtraRowspans(t,i){let n=0,o=0;for(n=0;n<t.length;n+=1){let r=1e6,s=!1;for(o=0;o<t[n].length;o+=1)if(void 0!==t[n][o]){if(t[n][o].rowSpan<2){s=!0;break}r=Math.min(r,t[n][o].rowSpan)}if(!s)for(o=0;o<t[n].length;o+=1)void 0!==t[n][o]&&u.__mark(t[n][o],"rowspan",t[n][o].rowSpan-r+1,i)}}normalizeTable(t){return u.__normalizeTable(t)}static __mergeSelected(t,i){let n=[],o=u.__getSelectedBound(t,u.__getSelectedCellsByTable(t)),s=0,l=null,d=0,p=0,f=0,m=new Set,g=[];o&&(o[0][0]-o[1][0]||o[0][1]-o[1][1])&&(u.__formalMatrix(t,(t,r,a,b,y)=>{r>=o[0][0]&&r<=o[1][0]&&a>=o[0][1]&&a<=o[1][1]&&(m.has(t)||(m.add(t),r===o[0][0]&&t.style.width&&(s+=t.offsetWidth),""!==(0,c.trim)(t.innerHTML.replace(/<br(\/)?>/g,""))&&n.push(t.innerHTML),b>1&&(p+=b-1),y>1&&(f+=y-1),l?(u.__mark(t,"remove",1,g),h(i).removeSelection(t)):(l=t,d=a)))}),p=o[1][1]-o[0][1]+1,f=o[1][0]-o[0][0]+1,l&&(p>1&&u.__mark(l,"colspan",p,g),f>1&&u.__mark(l,"rowspan",f,g),s&&(u.__mark(l,"width",(s/t.offsetWidth*100).toFixed(r.ACCURACY)+"%",g),d&&u.__setColumnWidthByDelta(t,d,0,!0,g)),l.innerHTML=n.join("<br/>"),h(i).addSelection(l),m.delete(l),u.__unmark(g),u.__normalizeTable(t),(0,c.toArray)(t.rows).forEach(t=>{t.cells.length||a.Dom.safeRemove(t)})))}mergeSelected(t){return u.__mergeSelected(t,this.j)}static __splitHorizontal(t,i){let n,o,r,s,l,c=[];u.__getSelectedCellsByTable(t).forEach(d=>{(o=i.createInside.element("td")).appendChild(i.createInside.element("br")),r=i.createInside.element("tr"),n=u.__formalCoordinate(t,d),d.rowSpan<2?(u.__formalMatrix(t,(t,i,o)=>{n[0]===i&&n[1]!==o&&t!==d&&u.__mark(t,"rowspan",t.rowSpan+1,c)}),a.Dom.after(a.Dom.closest(d,"tr",t),r),r.appendChild(o)):(u.__mark(d,"rowspan",d.rowSpan-1,c),u.__formalMatrix(t,(i,o,r)=>{o>n[0]&&o<n[0]+d.rowSpan&&n[1]>r&&i.parentNode.rowIndex===o&&(l=i),n[0]<o&&i===d&&(s=t.rows[o])}),l?a.Dom.after(l,o):s.insertBefore(o,s.firstChild)),d.colSpan>1&&u.__mark(o,"colspan",d.colSpan,c),u.__unmark(c),h(i).removeSelection(d)}),this.__normalizeTable(t)}splitHorizontal(t){return u.__splitHorizontal(t,this.j)}static __splitVertical(t,i){let n,o,s,l=[];u.__getSelectedCellsByTable(t).forEach(c=>{n=u.__formalCoordinate(t,c),c.colSpan<2?u.__formalMatrix(t,(t,i,o)=>{n[1]===o&&n[0]!==i&&t!==c&&u.__mark(t,"colspan",t.colSpan+1,l)}):u.__mark(c,"colspan",c.colSpan-1,l),(o=i.createInside.element("td")).appendChild(i.createInside.element("br")),c.rowSpan>1&&u.__mark(o,"rowspan",c.rowSpan,l);let d=c.offsetWidth;a.Dom.after(c,o),s=d/t.offsetWidth/2,u.__mark(c,"width",(100*s).toFixed(r.ACCURACY)+"%",l),u.__mark(o,"width",(100*s).toFixed(r.ACCURACY)+"%",l),u.__unmark(l),h(i).removeSelection(c)}),u.__normalizeTable(t)}splitVertical(t){return u.__splitVertical(t,this.j)}static __setColumnWidthByDelta(t,i,n,o,s){let a=u.__formalMatrix(t),l=0;for(let o=0;o<a.length;o+=1){let c=a[o][i];if(c.colSpan>1&&a.length>1)continue;let d=(c.offsetWidth+n)/t.offsetWidth*100;u.__mark(c,"width",d.toFixed(r.ACCURACY)+"%",s),l=o;break}for(let t=l+1;t<a.length;t+=1){let n=a[t][i];u.__mark(n,"width",null,s)}o||u.__unmark(s)}setColumnWidthByDelta(t,i,n,o,r){return u.__setColumnWidthByDelta(t,i,n,o,r)}static __mark(t,i,n,o){var r;o.push(t);let s=null!=(r=d.get(t))?r:{};s[i]=void 0===n?1:n,d.set(t,s)}static __unmark(t){t.forEach(t=>{let i=d.get(t);i&&(Object.keys(i).forEach(n=>{let o=i[n];switch(n){case"remove":a.Dom.safeRemove(t);break;case"rowspan":(0,c.attr)(t,"rowspan",(0,c.isNumber)(o)&&o>1?o:null);break;case"colspan":(0,c.attr)(t,"colspan",(0,c.isNumber)(o)&&o>1?o:null);break;case"width":null==o?(t.style.removeProperty("width"),(0,c.attr)(t,"style")||(0,c.attr)(t,"style",null)):t.style.width=o.toString()}delete i[n]}),d.delete(t))})}constructor(){super(...arguments),this.selected=new Set}}u.__selectedByTable=new WeakMap,function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);s>3&&a&&Object.defineProperty(i,n,a)}([(0,s.debounce)()],u.prototype,"__recalculateStyles",null);let h=t=>t.getInstance("Table",t.o)},78644:function(t,i,n){"use strict";n.d(i,{ToolbarButton:function(){return E}});var o=n(78213),r=n(45219),s=n(33433),a=n(87325),l=n(37133),c=n(2748),d=n(68345),u=n(23282),h=n(19306),p=n(72430),f=n(70799),m=n(56175),g=n(87058),b=n(38837),y=n(29960),w=n(37790),_=n(62843),C=n(72157),k=n(12153),S=n(56917),x=n(21491),I=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a};let E=class t extends _.UIButton{className(){return"ToolbarButton"}getRole(){return"listitem"}updateAriaLabel(){if(super.updateAriaLabel(),this.trigger){let t=this.state.tooltip?this.jodit.i18n(this.state.tooltip):null;(0,y.attr)(this.trigger,"aria-label",t)}}get toolbar(){let t=(0,a.getComponentClass)("ToolbarCollection");return this.closest(t)}update(){var t,i;let{control:n,state:o}=this,r=this.toolbar;if(!r)return;let s=null==(t=n.value)?void 0:t.call(n,r.jodit,this);void 0!==s&&(o.value=s),o.disabled=this.__calculateDisabledStatus(r),o.activated=this.__calculateActivatedStatus(r),null==(i=n.update)||i.call(n,r.jodit,this)}__calculateActivatedStatus(t){var i,n;return(!(0,h.isJoditObject)(this.j)||!!this.j.editorIsActive)&&(null!=(n=(i=this.control).isActive)&&!!n.call(i,this.j,this)||!!(t&&t.shouldBeActive(this)))}__calculateDisabledStatus(t){var i,n;return!!(this.j.o.disabled||this.j.o.readonly&&(!this.j.o.activeButtonsInReadOnly||!this.j.o.activeButtonsInReadOnly.includes(this.control.name))||(null==(n=(i=this.control).isDisabled)?void 0:n.call(i,this.j,this)))||!!(t&&t.shouldBeDisabled(this))}onChangeActivated(){(0,y.attr)(this.button,"aria-pressed",this.state.activated),super.onChangeActivated()}onChangeText(){(0,u.isFunction)(this.control.template)?this.text.innerHTML=this.control.template(this.j,this.control.name,this.j.i18n(this.state.text)):super.onChangeText(),this.setMod("text-icons",!!this.text.innerText.trim().length)}onChangeTabIndex(){(0,y.attr)(this.button,"tabindex",this.state.tabIndex)}createContainer(){let t=this.componentName,i=this.j.c.span(t),n=super.createContainer();n.classList.remove(t),n.classList.add(t+"__button"),Object.defineProperty(n,"component",{value:this,configurable:!0}),i.appendChild(n);let o=this.j.c.fromHTML(`<span role="button" aria-haspopup="true" aria-expanded="false" class="${t}__trigger">${k.Icon.get("chevron")}</span>`);return n.appendChild(o),i}focus(){var t;null==(t=this.container.querySelector("button"))||t.focus()}onChangeHasTrigger(){this.state.hasTrigger?this.container.appendChild(this.trigger):c.Dom.safeRemove(this.trigger),this.setMod("with-trigger",this.state.hasTrigger||null)}onChangeDisabled(){let t=this.state.disabled?"disabled":null;(0,y.attr)(this.trigger,"disabled",t),(0,y.attr)(this.button,"disabled",t),(0,y.attr)(this.container,"disabled",t)}__initFromControl(){let{control:t,state:i}=this;this.updateSize(),i.name=t.name,this.__initIconFromControl(),t.tooltip&&(i.tooltip=(0,u.isFunction)(t.tooltip)?t.tooltip(this.j,t,this):t.tooltip),i.hasTrigger=!!(t.list||t.popup&&t.exec)}__initIconFromControl(){var t;let{control:i,state:n}=this,{textIcons:o}=this.j.o;if(!0===o||(0,u.isFunction)(o)&&o(i.name)||i.template){n.icon=(0,_.UIButtonState)().icon,n.text=i.text||i.name;return}if(!(0,f.isString)(i.icon)&&null!=i.icon){n.icon={name:i.icon.name||i.name,iconURL:i.icon.iconURL||"",fill:i.icon.fill||"",scale:i.icon.scale};return}if(i.iconURL)n.icon.iconURL=i.iconURL;else{let o=i.icon||i.name;n.icon.name=k.Icon.exists(o)||(null==(t=this.j.o.extraIcons)?void 0:t[o])?o:""}i.iconURL||n.icon.name||(n.text=i.text||i.name)}onTriggerClick(t){var i,n,o;if(this.openedPopup)return void this.__closePopup();let{control:r}=this;if((0,y.attr)(this.trigger,"aria-expanded",!0),t.buffer={actionTrigger:this},r.list)return this.__openControlList(r);if((0,u.isFunction)(r.popup)){let t=this.openPopup();t.parentElement=this;try{if(!1!==this.j.e.fire((0,g.camelCase)(`before-${r.name}-open-popup`),this.target,r,t)){let s=null!=(o=null!=(n=null==(i=this.toolbar)?void 0:i.getTarget(this))?n:this.target)?o:null,a=r.popup(this.j,s,this.__closePopup,this);a?t.setContent((0,f.isString)(a)?this.j.c.fromHTML(a):a).open(()=>(0,m.position)(this.container),!1,this.j.o.allowTabNavigation?this.container:void 0):this.__closePopup()}}catch(t){throw this.__closePopup(),t}this.j.e.fire((0,g.camelCase)(`after-${r.name}-open-popup`),t.container)}}__openControlList(t){var i;let n=null!=(i=this.jodit.options.controls)?i:{},o=t=>(0,C.findControlType)(t,n),r=t.list,s=this.openPopup(),a=(0,x.makeCollection)(this.j);s.parentElement=this,a.parentElement=s,a.mode="vertical";let l=(i,n)=>{let r;if((0,f.isString)(n)&&o(n))return{name:n.toString(),...o(n)};if((0,f.isString)(i)&&o(i))return{name:i.toString(),...o(i),..."object"==typeof n?n:{}};r=i,(0,p.isPlainObject)(r)&&"title"in r&&"value"in r&&(n=i.value,i=i.title);let{childTemplate:s}=t,a={name:i.toString(),template:s&&((t,i,n)=>s(t,i,n,this)),exec:t.childExec?(i,n,o)=>{var r;return null==(r=t.childExec)?void 0:r.call(t,i,n,{...o,parentControl:t})}:t.exec,data:t.data,command:t.command,isActive:t.isChildActive,value:t.value,isDisabled:t.isChildDisabled,mode:t.mode,args:[...t.args?t.args:[],i,n]};return(0,f.isString)(n)&&(a.text=n),a};a.build((0,d.isArray)(r)?r.map(l):(0,w.keys)(r,!1).map(t=>l(t,r[t])),this.target),s.setContent(a).open(()=>(0,m.position)(this.container),!1,this.j.o.allowTabNavigation?this.container:void 0),this.state.activated=!0}onOutsideClick(t){this.openedPopup&&(t&&c.Dom.isNode(t.target)&&(c.Dom.isOrContains(this.container,t.target)||this.openedPopup.isOwnClick(t))||this.__closePopup())}openPopup(){return this.__closePopup(),this.openedPopup=new S.Popup(this.j,!1),this.j.e.on(this.ow,"mousedown touchstart",this.onOutsideClick).on("escape closeAllPopups",this.onOutsideClick),this.openedPopup}__closePopup(){this.openedPopup&&(this.j.e.off(this.ow,"mousedown touchstart",this.onOutsideClick).off("escape closeAllPopups",this.onOutsideClick),this.state.activated=!1,this.openedPopup.close(),this.openedPopup.destruct(),this.openedPopup=null,this.trigger&&(0,y.attr)(this.trigger,"aria-expanded",!1))}onClick(t){var i,n,o,r,s,a,l;let{control:c}=this;if((0,u.isFunction)(c.exec)){let d=null!=(o=null!=(n=null==(i=this.toolbar)?void 0:i.getTarget(this))?n:this.target)?o:null,u=c.exec(this.j,d,{control:c,originalEvent:t,button:this});if(!1!==u&&!0!==u&&(null==(s=null==(r=this.j)?void 0:r.e)||s.fire("synchro"),this.parentElement&&this.parentElement.update(),null==(l=null==(a=this.j)?void 0:a.e)||l.fire("closeAllPopups afterExec")),!1!==u)return}return c.list?this.__openControlList(c):(0,u.isFunction)(c.popup)?this.onTriggerClick(t):void((c.command||c.name)&&((0,w.call)((0,h.isJoditObject)(this.j)?this.j.execCommand.bind(this.j):this.j.od.execCommand.bind(this.j.od),c.command||c.name,!1,c.args&&c.args[0]),this.j.e.fire("closeAllPopups")))}destruct(){return this.__closePopup(),super.destruct()}constructor(t,i,n=null){super(t),this.control=i,this.target=n,this.state={...(0,_.UIButtonState)(),theme:"toolbar",currentValue:"",hasTrigger:!1},this.openedPopup=null;const r=this.getElm("button");(0,b.assert)(r,"Element button should exists"),this.button=r,Object.defineProperty(r,"component",{value:this,configurable:!0});const s=this.getElm("trigger");(0,b.assert)(s,"Element trigger should exists"),this.trigger=s,s.remove(),t.e.on([this.button,this.trigger],"mousedown",t=>t.preventDefault()),this.onAction(this.onClick),this.hookStatus(o.STATUSES.ready,()=>{this.__initFromControl(),this.update()}),i.mods&&Object.keys(i.mods).forEach(t=>{i.mods&&this.setMod(t,i.mods[t])})}};I([s.cacheHTML],E.prototype,"createContainer",null),I([(0,l.watch)("state.hasTrigger",{immediately:!1})],E.prototype,"onChangeHasTrigger",null),I([(0,l.watch)("trigger:click")],E.prototype,"onTriggerClick",null),I([r.autobind],E.prototype,"onOutsideClick",null),I([r.autobind],E.prototype,"__closePopup",null),E=I([a.component],E)},80319:function(t,i,n){"use strict";n.d(i,{ToolbarContent:function(){return l}});var o=n(65478),r=n(22732),s=n(21537),a=n(62843);let l=class t extends a.UIButton{className(){return"ToolbarContent"}update(){var t,i,n;let{control:o}=this,a=o.getContent(this.j,this);((0,s.isString)(a)||a.parentNode!==this.container)&&(r.Dom.detach(this.container),this.container.appendChild((0,s.isString)(a)?this.j.create.fromHTML(a):a)),this.state.disabled=!!(null==(t=o.isDisabled)?void 0:t.call(o,this.j,this)),this.state.activated=!!(null==(i=o.isActive)?void 0:i.call(o,this.j,this)),null==(n=o.update)||n.call(o,this.j,this),this.onChangeDisabled(),this.onChangeActivated(),super.update()}onChangeDisabled(){super.onChangeDisabled(),this.container.querySelectorAll("input,button,select,textarea").forEach(t=>(0,s.attr)(t,"disabled",this.state.disabled||null))}createContainer(){return this.j.c.span(this.componentName)}constructor(t,i,n=null){super(t),this.control=i,this.target=n,this.container.classList.add(`${this.componentName}_${this.clearName(i.name)}`),(0,s.attr)(this.container,"role","content")}};l=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a}([o.component],l)},36646:function(t,i,n){"use strict";n.d(i,{ToolbarButton:function(){return o.ToolbarButton},ToolbarContent:function(){return r.ToolbarContent},ToolbarSelect:function(){return s.ToolbarSelect}});var o=n(78644),r=n(80319),s=n(83111)},83111:function(t,i,n){"use strict";n.d(i,{ToolbarSelect:function(){return l}});var o=n(65478),r=n(72430),s=n(70799),a=n(78644);let l=class t extends a.ToolbarButton{className(){return"ToolbarSelect"}update(){var t,i,n;super.update(),this.state.icon.name="";let{list:o,data:a}=this.control;if(o){let l=this.state.value||(a&&(0,s.isString)(a.currentValue)?a.currentValue:void 0);l||(l=Object.keys(o)[0]);let c=((0,r.isPlainObject)(o)&&o[l.toString()]||l).toString();this.state.text=null!=(n=null==(i=(t=this.control).textTemplate)?void 0:i.call(t,this.jodit,c))?n:c}}};l=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a}([o.component],l)},11676:function(t,i,n){"use strict";n.d(i,{ToolbarCollection:function(){return p}});var o=n(65478),r=n(45219),s=n(87325),a=n(97357),l=n(37133),c=n(82760),d=n(24536),u=n(21491),h=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a};let p=class t extends d.UIList{className(){return"ToolbarCollection"}getRole(){return"toolbar"}get firstButton(){let[t]=this.buttons;return t||null}makeButton(t,i=null){return(0,u.makeButton)(this.j,t,i)}makeSelect(t,i=null){return(0,u.makeSelect)(this.j,t,i)}shouldBeActive(t){}shouldBeDisabled(t){}getTarget(t){return t.target||null}__immediateUpdate(){this.isDestructed||this.j.isLocked||(super.update(),this.j.e.fire("afterUpdateToolbar",this))}update(){this.__immediateUpdate()}setDirection(t){this.container.style.direction=t,this.container.setAttribute("dir",t)}__initEvents(){this.j.e.on(this.__listenEvents,this.update).on("afterSetMode focus",this.__immediateUpdate)}hide(){this.container.remove()}show(){this.appendTo(this.j.toolbarContainer)}showInline(t){throw(0,c.error)("The method is not implemented for this class.")}build(t,i=null){let n=this.j.e.fire("beforeToolbarBuild",t);return n&&(t=n),super.build(t,i),this}destruct(){this.isDestructed||(this.j.e.off(this.__listenEvents,this.update).off("afterSetMode focus",this.__immediateUpdate),super.destruct())}constructor(t){super(t),this.__listenEvents="updatePlugins updateToolbar changeStack mousedown mouseup keydown change readonly afterResize selectionchange changeSelection focus afterSetMode touchstart focus blur"}};h([(0,l.watch)(":afterInit"),r.autobind],p.prototype,"__immediateUpdate",null),h([(0,o.debounce)(t=>t.j.defaultTimeout,!0)],p.prototype,"update",null),h([(0,a.hook)("ready")],p.prototype,"__initEvents",null),p=h([s.component],p)},37426:function(t,i,n){"use strict";n.d(i,{ToolbarEditorCollection:function(){return c}});var o=n(82758),r=n(65478),s=n(22732),a=n(21537),l=n(11676);let c=class t extends l.ToolbarCollection{className(){return"ToolbarEditorCollection"}shouldBeDisabled(t){let i=super.shouldBeDisabled(t);if(void 0!==i)return i;let n=void 0===t.control.mode?o.MODE_WYSIWYG:t.control.mode;return n!==o.MODE_SPLIT&&n!==this.j.getRealMode()}shouldBeActive(t){let i,n=super.shouldBeActive(t);if(void 0!==n)return n;let o=this.j.selection?this.j.s.current():null;if(!o)return!1;if(t.control.tags){let n=t.control.tags;if(i=o,s.Dom.up(i,t=>{if(t&&-1!==n.indexOf(t.nodeName.toLowerCase()))return!0},this.j.editor))return!0}if(t.control.css){let n=t.control.css;if(i=o,s.Dom.up(i,t=>{if(t&&!s.Dom.isText(t)&&!s.Dom.isComment(t))return this.checkActiveStatus(n,t)},this.j.editor))return!0}return!1}getTarget(t){return t.target||this.j.s.current()||null}prependInvisibleInput(t){let i=this.j.create.element("input",{name:"jodit-toolbar-focus-helper_"+this.j.id,tabIndex:-1,disabled:!0,style:"width: 0; height:0; position: absolute; visibility: hidden;"});s.Dom.appendChildFirst(t,i)}showInline(t){this.jodit.e.fire("showInlineToolbar",t)}hide(){this.jodit.e.fire("hidePopup"),super.hide(),this.jodit.e.fire("toggleToolbar")}show(){super.show(),this.jodit.e.fire("toggleToolbar")}constructor(t){super(t),this.checkActiveStatus=(t,i)=>{let n=0,o=0;return Object.keys(t).forEach(r=>{let s=t[r];(0,a.isFunction)(s)?s(this.j,(0,a.css)(i,r).toString())&&(n+=1):-1!==s.indexOf((0,a.css)(i,r).toString())&&(n+=1),o+=1}),o===n},this.prependInvisibleInput(this.container)}};c=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a}([r.component],c)},21491:function(t,i,n){"use strict";n.d(i,{makeButton:function(){return l},makeCollection:function(){return a},makeSelect:function(){return c}});var o=n(87325),r=n(23282),s=n(19306);function a(t,i){let n=(0,o.getComponentClass)("ToolbarCollection"),r=(0,o.getComponentClass)("ToolbarEditorCollection"),a=(0,s.isJoditObject)(t)?new r(t):new n(t);return t.o.textIcons&&a.container.classList.add("jodit_text_icons"),i&&(a.parentElement=i),t.o.toolbarButtonSize&&(a.buttonSize=t.o.toolbarButtonSize),a}function l(t,i,n=null){if((0,r.isFunction)(i.getContent))return new((0,o.getComponentClass)("ToolbarContent"))(t,i,n);let s=new((0,o.getComponentClass)("ToolbarButton"))(t,i,n);return s.state.tabIndex=t.o.allowTabNavigation?0:-1,s}function c(t,i,n=null){return new((0,o.getComponentClass)("ToolbarSelect"))(t,i,n)}},80536:function(t,i,n){"use strict";var o=n(68345),r=n(19306),s=n(6441);s.Config.prototype.enableDragAndDropFileToEditor=!0,s.Config.prototype.uploader={url:"",insertImageAsBase64URI:!1,showTabInFileSelector:!0,imagesExtensions:["jpg","jpeg","png","gif","webp","bmp","svg","tiff","avif"],headers:null,data:null,filesVariableName:t=>`files[${t}]`,withCredentials:!1,pathVariableName:"path",format:"json",method:"POST",prepareData:t=>t,isSuccess:t=>t.success,getMessage:t=>void 0!==t.data.messages&&(0,o.isArray)(t.data.messages)?t.data.messages.join(" "):"",processFileName:(t,i,n)=>[t,i,n],process:t=>t.data,error(t){this.j.message.error(t.message,4e3)},getDisplayName:(t,i)=>t+i,defaultHandlerSuccess(t){let i=this.j||this;(0,r.isJoditObject)(i)&&t.files&&t.files.length&&t.files.forEach((n,o)=>{let[r,s]=t.isImages&&t.isImages[o]?["img","src"]:["a","href"],a=i.createInside.element(r);a.setAttribute(s,t.baseurl+n),"a"===r&&(a.textContent=i.o.uploader.getDisplayName.call(this,t.baseurl,n)),"img"===r?i.s.insertImage(a,null,i.o.imageDefaultWidth):i.s.insertNode(a)})},defaultHandlerError(t){this.j.message.error(t.message)},contentType(t){return(void 0===this.ow.FormData||"string"==typeof t)&&"application/x-www-form-urlencoded; charset=UTF-8"}}},83987:function(t,i,n){"use strict";n.d(i,{buildData:function(){return r}});var o=n(21537);function r(t,i){if((0,o.isFunction)(t.o.buildData))return t.o.buildData.call(t,i);let n=t.ow.FormData;if(void 0!==n){if(i instanceof n||(0,o.isString)(i))return i;let t=new n;return Object.keys(i).forEach(n=>{t.append(n,i[n])}),t}return i}},74569:function(t,i,n){"use strict";function o(t){let i=atob(t.split(",")[1]),n=t.split(",")[0].split(":")[1].split(";")[0],o=new Uint8Array(new ArrayBuffer(i.length));for(let t=0;t<i.length;t+=1)o[t]=i.charCodeAt(t);return new Blob([o.buffer],{type:n})}n.d(i,{dataURItoBlob:function(){return o}})},94122:function(t,i,n){"use strict";n.d(i,{ajaxInstances:function(){return r.ajaxInstances},hasFiles:function(){return a},hasItems:function(){return l},processOldBrowserDrag:function(){return o.processOldBrowserDrag},send:function(){return r.send},sendFiles:function(){return s.sendFiles}}),n(83987);var o=n(50373),r=n(71686),s=n(80020);function a(t){return!!(t&&t.files&&t.files.length>0)}function l(t){return!!(t&&t.items&&t.items.length>0)}},50373:function(t,i,n){"use strict";n.d(i,{processOldBrowserDrag:function(){return d}});var o=n(82758),r=n(22732),s=n(580),a=n(21537),l=n(74569),c=n(80020);function d(t,i,n,d,u){if(i&&(!i.types.length||i.types[0]!==o.TEXT_PLAIN)){let i=t.j.c.div("",{tabindex:-1,style:"left: -9999px; top: 0; width: 0; height: 100%;line-height: 140%; overflow: hidden; position: fixed; z-index: 2147483647; word-break: break-all;",contenteditable:!0});(0,s.getContainer)(t.j,t.constructor).appendChild(i);let o=(0,a.isJoditObject)(t.j)?t.j.s.save():null;i.focus(),t.j.async.setTimeout(()=>{let s=i.firstChild;if(r.Dom.safeRemove(i),s&&s.hasAttribute("src")){let i=(0,a.attr)(s,"src")||"";o&&(0,a.isJoditObject)(t.j)&&t.j.s.restore(),(0,c.sendFiles)(t,[(0,l.dataURItoBlob)(i)],n,d).finally(u)}},t.j.defaultTimeout)}}},80020:function(t,i,n){"use strict";n.d(i,{sendFiles:function(){return s}});var o=n(21537),r=n(71686);function s(t,i,n,s,a){if(!i)return Promise.reject((0,o.error)("Need files"));let{o:l}=t,c=(0,o.toArray)(i);if(!c.length)return Promise.reject((0,o.error)("Need files"));if((0,o.isFunction)(l.beforeUpload)&&!1===l.beforeUpload.call(t,c)){let i=(0,o.error)("Upload canceled");return(s||l.defaultHandlerError).call(t,i),Promise.reject(i)}let d=[];if(l.insertImageAsBase64URI&&function(t,i,n,r,s,a){let l,c,d=[];for(c=0;c<t.length;c+=1)if((l=t[c])&&l.type){let u=l.type.match(/\/([a-z0-9]+)/i),h=u[1]?u[1].toLowerCase():"";if(!i.includes(h))continue;let p=new FileReader,f=r.j.async.promise((t,i)=>{p.onerror=i,p.onloadend=()=>{let i={baseurl:"",files:[p.result],isImages:[!0]};((0,o.isFunction)(s)?s:a).call(r,i),t(i)},p.readAsDataURL(l)});d.push(f),n.push(f),t[c]=null}d.length&&Promise.all(d).then(()=>{r.j.events&&r.j.e.fire("filesWereUploaded")}).catch(()=>{})}(c,l.imagesExtensions,d,t,n,l.defaultHandlerSuccess),(c=c.filter(t=>t)).length){let i,u=new FormData;u.append(l.pathVariableName,t.path),u.append("source",t.source);for(let n=0;n<c.length;n+=1)if(i=c[n]){let o=/\.\w+$/.test(i.name),r=i.type.match(/\/([a-z0-9]+)/i),s=r&&r[1]?r[1].toLowerCase():"",a=c[n].name||Math.random().toString().replace(".","");if(!o&&s){let t=s;["jpeg","jpg"].includes(t)&&(t="jpeg|jpg"),RegExp(".("+t+")$","i").test(a)||(a+="."+s)}let[d,h,p]=l.processFileName.call(t,l.filesVariableName(n),c[n],a);u.append(d,h,p)}a&&a(u),l.data&&(0,o.isPlainObject)(l.data)&&Object.keys(l.data).forEach(t=>{u.append(t,l.data[t])}),l.prepareData.call(t,u),d.push((0,r.send)(t,u).then(i=>(l.isSuccess.call(t,i)?((0,o.isFunction)(n)?n:l.defaultHandlerSuccess).call(t,l.process.call(t,i)):((0,o.isFunction)(s)?s:l.defaultHandlerError).call(t,(0,o.error)(l.getMessage.call(t,i))),i)).then(()=>{t.j.events&&t.j.e.fire("filesWereUploaded")}))}return Promise.all(d)}},71686:function(t,i,n){"use strict";n.d(i,{ajaxInstances:function(){return a},send:function(){return l}});var o=n(21537),r=n(41601),s=n(83987);let a=new WeakMap;function l(t,i){let n=(0,s.buildData)(t,i),l=i=>{t.j.progressbar.show().progress(i),i>=100&&t.j.progressbar.hide()},c=(i,n)=>{let s=new r.Ajax({xhr(){let i=new XMLHttpRequest;return void 0!==t.j.ow.FormData&&i.upload?(n(10),i.upload.addEventListener("progress",t=>{if(t.lengthComputable){let i=t.loaded/t.total;n(i*=100)}},!1)):n(100),i},method:t.o.method||"POST",data:i,url:(0,o.isFunction)(t.o.url)?t.o.url(i):t.o.url,headers:t.o.headers,queryBuild:t.o.queryBuild,contentType:t.o.contentType.call(t,i),withCredentials:t.o.withCredentials||!1}),l=a.get(t);return l||(l=new Set,a.set(t,l)),l.add(s),t.j.e.one("beforeDestruct",s.destruct),s.send().then(t=>t.json()).catch(t=>({success:!1,data:{messages:[t]}})).finally(()=>{s.destruct(),null==l||l.delete(s)})};return((0,o.isFunction)(t.o.customUploadFunction)&&(c=t.o.customUploadFunction),(0,o.isPromise)(n))?n.then(t=>c(t,l)).catch(i=>{t.o.error.call(t,i)}):c(n,l)}},57380:function(t,i,n){"use strict";n.d(i,{Uploader:function(){return c}});var o=n(91907),r=n(82758),s=n(21537),a=n(6441),l=n(94122);n(80536);class c extends o.ViewComponent{get j(){return this.jodit}className(){return"Uploader"}get o(){return this.options}setPath(t){return this.path=t,this}setSource(t){return this.source=t,this}bind(t,i,n){let o=()=>{t.classList.remove("jodit_drag_hover")},s=this,a=t=>{let a,c,d,u=t.clipboardData,h=t=>{c&&(t.append("extension",d),t.append("mimetype",c.type))};if(!r.IS_IE&&(0,l.hasFiles)(u))return(0,l.sendFiles)(s,u.files,i,n).finally(o),!1;if(r.IS_IE&&!r.IS_ES_NEXT)return(0,l.processOldBrowserDrag)(s,u,i,n,o);if((0,l.hasItems)(u)){let{items:r}=u;for(a=0;a<r.length;a+=1)if("file"===r[a].kind&&"image/png"===r[a].type){if(c=r[a].getAsFile()){let t=c.type.match(/\/([a-z0-9]+)/i);d=t[1]?t[1].toLowerCase():"",(0,l.sendFiles)(s,[c],i,n,h).finally(o)}t.preventDefault();break}}};s.j&&s.j.editor!==t?s.j.e.on(t,"paste",a):s.j.e.on("beforePaste",a),this.attachEvents(t,i,n,o)}attachEvents(t,i,n,o){let r=this;r.j.e.on(t,"dragend dragover dragenter dragleave drop",t=>{t.preventDefault()}).on(t,"dragover",i=>{((0,l.hasFiles)(i.dataTransfer)||(0,l.hasItems)(i.dataTransfer))&&(t.classList.add("jodit_drag_hover"),i.preventDefault())}).on(t,"dragend dragleave",i=>{t.classList.remove("jodit_drag_hover"),(0,l.hasFiles)(i.dataTransfer)&&i.preventDefault()}).on(t,"drop",s=>{t.classList.remove("jodit_drag_hover"),(0,l.hasFiles)(s.dataTransfer)&&(s.preventDefault(),s.stopImmediatePropagation(),(0,l.sendFiles)(r,s.dataTransfer.files,i,n).finally(o))});let s=t.querySelector("input[type=file]");s&&r.j.e.on(s,"change",()=>{(0,l.sendFiles)(r,s.files,i,n).then(()=>{s.value="",/safari/i.test(navigator.userAgent)||(s.type="",s.type="file")}).finally(o)})}uploadRemoteImage(t,i,n){let o=this,{o:r}=o,a=(0,s.isFunction)(n)?n:r.defaultHandlerError;(0,l.send)(o,{action:"fileUploadRemote",url:t}).then(t=>{r.isSuccess.call(o,t)?((0,s.isFunction)(i)?i:r.defaultHandlerSuccess).call(o,r.process.call(o,t)):a.call(o,(0,s.error)(r.getMessage.call(o,t)))}).catch(t=>a.call(o,t))}upload(t){return this.async.promise((i,n)=>{(0,l.sendFiles)(this,t,i,n)})}destruct(){this.setStatus(o.STATUSES.beforeDestruct);let t=l.ajaxInstances.get(this);t&&(t.forEach(t=>{try{t.destruct()}catch(t){}}),t.clear()),super.destruct()}constructor(t,i){super(t),this.path="",this.source="default",this.options=(0,s.ConfigProto)(i||{},(0,s.ConfigProto)(a.Config.defaultOptions.uploader,(0,s.isJoditObject)(t)?t.o.uploader:{}))}}},22859:function(t,i,n){"use strict";n.d(i,{ColorPickerWidget:function(){return l}});var o=n(22732),r=n(21537),s=n(67510),a=n(37068);s.Icon.set("palette",a.default);let l=(t,i,n)=>{let a="jodit-color-picker",l=(0,r.normalizeColor)(n),c=t.c.div(a),d=t.o.textIcons?`<span>${t.i18n("palette")}</span>`:s.Icon.get("palette"),u=t=>{let i=[];return(0,r.isPlainObject)(t)?Object.keys(t).forEach(n=>{i.push(`<div class="${a}__group ${a}__group-${n}">`),i.push(u(t[n])),i.push("</div>")}):(0,r.isArray)(t)&&t.forEach(t=>{i.push(`<span class='${a}__color-item ${l===t?a+"__color-item_active_true":""}' title="${t}" style="background-color:${t}" data-color="${t}"></span>`)}),i.join("")};c.appendChild(t.c.fromHTML(`<div class="${a}__groups">${u(t.o.colors)}</div>`)),c.appendChild(t.c.fromHTML(`<div data-ref="extra" class="${a}__extra"></div>`));let{extra:h}=(0,r.refs)(c);h.appendChild(t.c.fromHTML(`<div class="${a}__hex"><input data-ref="hexInput" type="text" spellcheck="false" aria-label="HEX" placeholder="#FF0000" value="${l||""}"/></div>`));let{hexInput:p}=(0,r.refs)(c),f=()=>{let t=p.value.trim(),n=/^#?[0-9a-f]{3}(?:[0-9a-f]{3})?$/i.test(t),o=/^rgba?\([\d\s.,%]+\)$/i.test(t);if(!n&&!o)return;let s=(0,r.normalizeColor)(n&&!t.startsWith("#")?"#"+t:t);s&&(0,r.isFunction)(i)&&i(s)};return t.e.on(p,"keydown",t=>{t.stopPropagation(),"Enter"===t.key&&(t.preventDefault(),f())}).on(p,"change",t=>{t.stopPropagation(),f()}),t.o.showBrowserColorPicker&&(0,r.hasBrowserColorPicker)()&&(h.appendChild(t.c.fromHTML(`<div class="${a}__native">${d}<input type="color" value="#ffffff"/></div>`)),t.e.on(c,"change",t=>{t.stopPropagation();let n=t.target;if(!n||!n.tagName||!o.Dom.isTag(n,"input")||"color"!==n.type)return;let s=n.value||"";(0,r.isFunction)(i)&&i(s),t.preventDefault()})),t.e.on(c,"mousedown touchend",n=>{if(o.Dom.isTag(n.target,"input"))return void n.stopPropagation();n.stopPropagation(),n.preventDefault();let s=n.target;if((!s||!s.tagName||o.Dom.isTag(s,"svg")||o.Dom.isTag(s,"path"))&&s.parentNode&&(s=o.Dom.closest(s.parentNode,"span",t.editor)),!o.Dom.isTag(s,"span")||!s.classList.contains(a+"__color-item"))return;let l=(0,r.attr)(s,"-color")||"";i&&(0,r.isFunction)(i)&&i(l)}),t.e.fire("afterGenerateColorPicker",c,h,i,l),c}},37068:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' x="0px" y="0px" viewBox="0 0 459 459"> <g> <path d="M229.5,0C102,0,0,102,0,229.5S102,459,229.5,459c20.4,0,38.25-17.85,38.25-38.25c0-10.2-2.55-17.85-10.2-25.5 c-5.1-7.65-10.2-15.3-10.2-25.5c0-20.4,17.851-38.25,38.25-38.25h45.9c71.4,0,127.5-56.1,127.5-127.5C459,91.8,357,0,229.5,0z M89.25,229.5c-20.4,0-38.25-17.85-38.25-38.25S68.85,153,89.25,153s38.25,17.85,38.25,38.25S109.65,229.5,89.25,229.5z M165.75,127.5c-20.4,0-38.25-17.85-38.25-38.25S145.35,51,165.75,51S204,68.85,204,89.25S186.15,127.5,165.75,127.5z M293.25,127.5c-20.4,0-38.25-17.85-38.25-38.25S272.85,51,293.25,51s38.25,17.85,38.25,38.25S313.65,127.5,293.25,127.5z M369.75,229.5c-20.4,0-38.25-17.85-38.25-38.25S349.35,153,369.75,153S408,170.85,408,191.25S390.15,229.5,369.75,229.5z" /> </g> </svg> '},34793:function(t,i,n){"use strict";n.d(i,{FileSelectorWidget:function(){return l}});var o=n(2748),r=n(21537),s=n(67510),a=n(38927);let l=(t,i,n,l,d=!0)=>{let u,h=[],p=t.o.uploader;if(i.upload&&!1!==p.showTabInFileSelector&&(p.url||p.insertImageAsBase64URI||p.customUploadFunction)){let n=t.c.fromHTML(`<div class="jodit-drag-and-drop__file-box"><strong>${t.i18n(d?"Drop image":"Drop file")}</strong><span><br>${t.i18n("or click")}</span><input type="file" accept="${d?"image/*":"*"}" tabindex="-1" dir="auto" multiple=""/></div>`);t.uploader.bind(n,n=>{let o=(0,r.isFunction)(i.upload)?i.upload:p.defaultHandlerSuccess;(0,r.isFunction)(o)&&o.call(t,n),t.e.fire("closeAllPopups")},i=>{t.message.error(i.message),t.e.fire("closeAllPopups")}),h.push({icon:"upload",name:"Upload",content:n})}if(i.filebrowser&&(t.o.filebrowser.ajax.url||t.o.filebrowser.items.url)&&h.push({icon:"folder",name:"Browse",content(){l&&l(),i.filebrowser&&t.filebrowser.open(i.filebrowser,d)}}),i.url){let a=new s.UIButton(t,{type:"submit",variant:"primary",text:"Insert"}),l=new s.UIForm(t,[new s.UIInput(t,{required:!0,label:"URL",name:"url",type:"text",placeholder:"https://"}),new s.UIInput(t,{name:"text",label:"Alternative text"}),new s.UIBlock(t,[a])]);u=null,n&&!o.Dom.isText(n)&&!o.Dom.isComment(n)&&(o.Dom.isTag(n,"img")||(0,r.$$)("img",n).length)&&(u="IMG"===n.tagName?n:(0,r.$$)("img",n)[0],c(l.container,"input[name=url]",(0,r.attr)(u,"src")),c(l.container,"input[name=text]",(0,r.attr)(u,"alt")),a.state.text="Update"),n&&o.Dom.isTag(n,"a")&&(c(l.container,"input[name=url]",(0,r.attr)(n,"href")),c(l.container,"input[name=text]",(0,r.attr)(n,"title")),a.state.text="Update"),l.onSubmit(n=>{(0,r.isFunction)(i.url)&&i.url.call(t,n.url,n.text)}),h.push({icon:"link",name:"URL",content:l.container})}let f=(0,a.TabsWidget)(t,h);return f.classList.add("jodit-file-selector"),f};function c(t,i,n){let o=t.querySelector(i);return o?(n&&(o.value=n),o.value):""}},92762:function(t,i,n){"use strict";n.d(i,{ColorPickerWidget:function(){return o.ColorPickerWidget},FileSelectorWidget:function(){return r.FileSelectorWidget},TabsWidget:function(){return s.TabsWidget}});var o=n(22859),r=n(34793),s=n(38927)},38927:function(t,i,n){"use strict";n.d(i,{TabsWidget:function(){return c}});var o=n(91907),r=n(2748),s=n(23282),a=n(29960),l=n(67510);let c=(t,i,n)=>{let c=t.c.div("jodit-tabs"),d=t.c.div("jodit-tabs__wrapper"),u=t.c.div("jodit-tabs__buttons");(0,a.attr)(u,{role:"tablist","aria-orientation":"horizontal"});let h={},p=[],f="";c.appendChild(u),c.appendChild(d);let m=t=>{h[t]&&(p.forEach(t=>{t.state.activated=!1}),Object.values(h).forEach(({tab:t})=>t.classList.remove("jodit-tab_active")),h[t].button.state.activated=!0,h[t].tab.classList.add("jodit-tab_active"))};if(i.forEach(({icon:c,name:g,content:b})=>{let y=t.c.div("jodit-tab");(0,a.attr)(y,{role:"tabpanel"});let w=(0,l.Button)(t,c||g,g);w.state.role="tab",t.e.on(w.container,"pointerdown",t=>t.preventDefault()),f||(f=g),u.appendChild(w.container),p.push(w),w.container.classList.add("jodit-tabs__button","jodit-tabs__button_columns_"+i.length),(0,s.isFunction)(b)?y.classList.add("jodit-tab_empty"):y.appendChild(o.Component.isInstanceOf(b,l.UIElement)?b.container:b),d.appendChild(y),w.onAction(()=>(m(g),(0,s.isFunction)(b)&&!r.Dom.isElement(b)&&b.call(t),n&&(n.activeTab=g),!1)),h[g]={button:w,tab:y}}),m(n&&n.activeTab&&h[n.activeTab]?n.activeTab:f),n){let t=n.activeTab;Object.defineProperty(n,"activeTab",{configurable:!0,enumerable:!1,get:()=>t,set(i){t=i,m(i)}})}return c}},73391:function(t,i,n){"use strict";var o=n(82758),r=n(580),s=n(21537),a=n(12153),l=n(6441),c=n(49399);l.Config.prototype.controls.about={exec(t){let i=t.dlg({closeOnClickOverlay:!0}),n=t.i18n.bind(t);i.setMod("theme",t.o.theme).setHeader(n("About Jodit")).setContent(`<div class="jodit-about">
|
|
123
|
+
</form>`)}},41409:function(t,i,n){"use strict";n.r(i),n.d(i,{Ajax:function(){return f.Ajax},Alert:function(){return a.Alert},Async:function(){return c.Async},AsyncStorage:function(){return P.AsyncStorage},Button:function(){return m.Button},CommitStyle:function(){return A.CommitStyle},Component:function(){return o.Component},Confirm:function(){return a.Confirm},ContextMenu:function(){return s.ContextMenu},Create:function(){return d.Create},Dialog:function(){return a.Dialog},Dom:function(){return u.Dom},EventEmitter:function(){return h.EventEmitter},EventHandlersStore:function(){return h.EventHandlersStore},Eventify:function(){return h.Eventify},FileBrowser:function(){return l.FileBrowser},Helpers:function(){return r},History:function(){return y.History},Icon:function(){return m.Icon},ImageEditor:function(){return _.ImageEditor},IndexedDBProvider:function(){return P.IndexedDBProvider},LazyWalker:function(){return u.LazyWalker},LocalStorageProvider:function(){return P.LocalStorageProvider},MemoryStorageProvider:function(){return P.MemoryStorageProvider},Plugin:function(){return p.Plugin},PluginSystem:function(){return j.PluginSystem},Popup:function(){return m.Popup},ProgressBar:function(){return m.ProgressBar},Prompt:function(){return a.Prompt},Response:function(){return f.Response},STATUSES:function(){return o.STATUSES},Selection:function(){return A.Selection},Snapshot:function(){return w.Snapshot},StatusBar:function(){return k.StatusBar},Storage:function(){return P.Storage},StorageKey:function(){return P.StorageKey},Table:function(){return S.Table},ToolbarButton:function(){return x.ToolbarButton},ToolbarCollection:function(){return I.ToolbarCollection},ToolbarContent:function(){return x.ToolbarContent},ToolbarEditorCollection:function(){return E.ToolbarEditorCollection},ToolbarSelect:function(){return x.ToolbarSelect},UIBlock:function(){return m.UIBlock},UIButton:function(){return m.UIButton},UIButtonGroup:function(){return m.UIButtonGroup},UIButtonState:function(){return m.UIButtonState},UICheckbox:function(){return m.UICheckbox},UIElement:function(){return m.UIElement},UIFileInput:function(){return m.UIFileInput},UIForm:function(){return m.UIForm},UIGroup:function(){return m.UIGroup},UIInput:function(){return m.UIInput},UIList:function(){return m.UIList},UIMessages:function(){return C.UIMessages},UISelect:function(){return m.UISelect},UISeparator:function(){return m.UISeparator},UISpacer:function(){return m.UISpacer},UITextArea:function(){return m.UITextArea},UITooltip:function(){return m.UITooltip},Uploader:function(){return T.Uploader},View:function(){return g.View},ViewComponent:function(){return o.ViewComponent},ViewWithToolbar:function(){return b.ViewWithToolbar},canUseIndexedDB:function(){return P.canUseIndexedDB},canUsePersistentStorage:function(){return P.canUsePersistentStorage},clearUseIndexedDBCache:function(){return P.clearUseIndexedDBCache},defaultNameSpace:function(){return h.defaultNameSpace},observable:function(){return h.observable}});var o=n(91907),r=n(21537),s=n(80870),a=n(638),l=n(78513),c=n(8884),d=n(12060),u=n(22732),h=n(3827),p=n(50911),f=n(41601),m=n(67510),g=n(35608),b=n(84075),y=n(78818),w=n(52604),_=n(50050),C=n(1808),k=n(23512),S=n(76014),x=n(36646),I=n(11676),E=n(37426),T=n(57380),j=n(41876),A=n(59242),P=n(12081)},68389:function(t,i,n){"use strict";n.d(i,{UIMessage:function(){return s}});var o=n(87325),r=n(67510);let s=class t extends r.UIElement{className(){return"UIMessage"}constructor(t,i){super(t),this.setMod("active",!0),this.setMod("variant",i.variant),this.container.textContent=i.text}};s=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a}([o.component],s)},1808:function(t,i,n){"use strict";n.d(i,{UIMessages:function(){return l}});var o=n(87325),r=n(41180),s=n(62405),a=n(68389);let l=class t extends s.UIGroup{className(){return"UIMessages"}info(t,i){this.__message(t,"info",i)}success(t,i){this.__message(t,"success",i)}error(t,i){this.__message(t,"error",i)}message(t,i,n){this.__message(t,i,n)}__message(t,i="info",n){let o=t+":"+i;if(this.__messages.has(o))return void this.async.updateTimeout(o,n||this.options.defaultTimeout);if(!this.__box)throw Error("Container is not defined: "+o);this.__box.appendChild(this.container);let r=new a.UIMessage(this.j,{text:t,variant:i});this.append(r),this.__calcOffsets(),this.__messages.add(o);let s=this.__getRemoveCallback(r,o);this.j.e.on(r.container,"pointerdown",s),this.async.setTimeout(s,{label:o,timeout:n||this.options.defaultTimeout})}__getRemoveCallback(t,i){let n=o=>{o&&o.preventDefault(),t.isInDestruct||(this.async.clearTimeout(i),this.j.e.off(t.container,"pointerdown",n),this.__messages.delete(i),t.setMod("active",!1),this.async.setTimeout(()=>{this.remove(t),t.destruct(),this.__calcOffsets()},300))};return n}__calcOffsets(){let t=5;this.elements.forEach(i=>{(0,r.css)(i.container,"bottom",t+"px"),t+=i.container.offsetHeight+this.options.defaultOffset})}constructor(t,i,n={defaultTimeout:3e3,defaultOffset:5}){super(t),this.__box=i,this.options=n,this.__messages=new Set}};l=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a}([o.component],l)},23512:function(t,i,n){"use strict";n.d(i,{StatusBar:function(){return c}});var o=n(91907),r=n(65478),s=n(2748),a=n(14316),l=n(34176);let c=class t extends o.ViewComponent{className(){return"StatusBar"}hide(){this.container.classList.add("jodit_hidden")}show(){this.container.classList.remove("jodit_hidden")}get isShown(){return!this.container.classList.contains("jodit_hidden")}getHeight(){var t,i;return null!=(i=null==(t=this.container)?void 0:t.offsetHeight)?i:0}findEmpty(t=!1){let i=this.getElms(t?"item-right":"item");for(let t=0;t<i.length;t+=1)if(!i[t].innerHTML.trim().length)return i[t]}append(t,i=!1){var n;let o=this.findEmpty(i)||this.j.c.div(this.getFullElName("item"));i&&o.classList.add(this.getFullElName("item-right")),o.appendChild(t),null==(n=this.container)||n.appendChild(o),this.j.o.statusbar&&this.show(),this.j.e.fire("resize")}destruct(){this.isInDestruct||(this.setStatus(o.STATUSES.beforeDestruct),s.Dom.safeRemove(this.container),super.destruct())}constructor(t,i){super(t),this.target=i,this.mods={},this.container=t.c.div("jodit-status-bar"),i.appendChild(this.container),this.hide()}};c=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a}([r.component,(0,r.derive)(l.Mods,a.Elms)],c)},76014:function(t,i,n){"use strict";n.d(i,{Table:function(){return u}});var o=n(91907),r=n(82758),s=n(65478),a=n(22732),l=n(580),c=n(21537);let d=new WeakMap;class u extends o.ViewComponent{className(){return"Table"}__recalculateStyles(){let t=(0,l.getContainer)(this.j,u,"style",!0),i=[];this.selected.forEach(t=>{let n=(0,c.cssPath)(t);n&&i.push(n)}),t.innerHTML=i.length?i.join(",")+`{${this.jodit.options.table.selectionCellStyle}}`:""}addSelection(t){this.selected.add(t),this.__recalculateStyles();let i=a.Dom.closest(t,"table",this.j.editor);if(i){let n=u.__selectedByTable.get(i)||new Set;n.add(t),u.__selectedByTable.set(i,n)}}removeSelection(t){this.selected.delete(t),this.__recalculateStyles();let i=a.Dom.closest(t,"table",this.j.editor);if(i){let n=u.__selectedByTable.get(i);n&&(n.delete(t),n.size||u.__selectedByTable.delete(i))}}getAllSelectedCells(){return(0,c.toArray)(this.selected)}static __getSelectedCellsByTable(t){let i=u.__selectedByTable.get(t);return i?(0,c.toArray)(i):[]}destruct(){return this.selected.clear(),super.destruct()}static __getRowsCount(t){return t.rows.length}getRowsCount(t){return u.__getRowsCount(t)}static __getColumnsCount(t){return u.__formalMatrix(t).reduce((t,i)=>Math.max(t,i.length),0)}getColumnsCount(t){return u.__getColumnsCount(t)}static __formalMatrix(t,i){let n=[[]],o=(0,c.toArray)(t.rows),r=(t,o)=>{void 0===n[o]&&(n[o]=[]);let r=t.colSpan,s=t.rowSpan,a,l,c=0;for(;n[o][c];)c+=1;for(l=0;s>l;l+=1)for(a=0;a<r;a+=1){if(void 0===n[o+l]&&(n[o+l]=[]),i&&!1===i(t,o+l,c+a,r,s))return!1;n[o+l][c+a]=t}};for(let t=0;t<o.length;t+=1){let i=(0,c.toArray)(o[t].cells);for(let o=0;o<i.length;o+=1)if(!1===r(i[o],t))return n}return n}formalMatrix(t,i){return u.__formalMatrix(t,i)}static __formalCoordinate(t,i,n=!1){let o=0,r=0,s=1,a=1;return u.__formalMatrix(t,(t,l,c,d,u)=>{if(i===t)return o=l,r=c,s=d||1,a=u||1,n&&(r+=(d||1)-1,o+=(u||1)-1),!1}),[o,r,s,a]}formalCoordinate(t,i,n=!1){return u.__formalCoordinate(t,i,n)}static __appendRow(t,i,n,o){var r;let s;if(i)s=i.cloneNode(!0),(0,c.$$)("td,th",i).forEach(t=>{let i=(0,c.attr)(t,"rowspan");if(i&&parseInt(i,10)>1){let n=parseInt(i,10)-1;(0,c.attr)(t,"rowspan",n>1?n:null)}}),(0,c.$$)("td,th",s).forEach(t=>{t.innerHTML=""});else{let i=u.__getColumnsCount(t);s=o.element("tr");for(let t=0;t<i;t+=1)s.appendChild(o.element("td"))}n&&i&&i.nextSibling?i.parentNode&&i.parentNode.insertBefore(s,i.nextSibling):!n&&i?i.parentNode&&i.parentNode.insertBefore(s,i):((null==(r=t.getElementsByTagName("tbody"))?void 0:r[0])||t).appendChild(s)}appendRow(t,i,n){return u.__appendRow(t,i,n,this.j.createInside)}static __removeRow(t,i){let n,o=u.__formalMatrix(t),r=t.rows[i];o[i].forEach((s,l)=>{if(n=!1,i-1>=0&&o[i-1][l]===s)n=!0;else if(o[i+1]&&o[i+1][l]===s){if(s.parentNode===r&&s.parentNode.nextSibling){n=!0;let r=l+1;for(;o[i+1][r]===s;)r+=1;let c=a.Dom.next(s.parentNode,t=>a.Dom.isTag(t,"tr"),t);if(c){let t=null;for(let n=r;n<o[i+1].length;n+=1){let r=o[i+1][n];if(r&&r.parentNode===c){t=r;break}}t?c.insertBefore(s,t):c.appendChild(s)}}}else a.Dom.safeRemove(s);if(n&&(s.parentNode===r||s!==o[i][l-1])){let t=s.rowSpan;(0,c.attr)(s,"rowspan",t-1>1?t-1:null)}}),a.Dom.safeRemove(r)}removeRow(t,i){return u.__removeRow(t,i)}appendColumn(t,i,n=!0){let o=u.__formalMatrix(t);if(!n&&a.Dom.isCell(i.previousElementSibling))return this.appendColumn(t,i.previousElementSibling,!0);let[,r]=u.__formalCoordinate(t,i,n),s=n?r+1:r;for(let t=0;t<o.length;){let i=o[t];if(i[r]!==i[s]||r===s){let t=this.j.createInside.element("td");n?a.Dom.after(i[r],t):a.Dom.before(i[r],t),i[r].rowSpan>1&&(t.rowSpan=i[r].rowSpan)}else i[r].colSpan+=1;t+=i[r].rowSpan||1}}static __removeColumn(t,i){let n,o=u.__formalMatrix(t);o.forEach((t,r)=>{let s=t[i];if(n=!1,i-1>=0&&o[r][i-1]===s||i+1<t.length&&o[r][i+1]===s?n=!0:a.Dom.safeRemove(s),n&&(r-1<0||s!==o[r-1][i])){let t=s.colSpan;(0,c.attr)(s,"colspan",t-1>1?(t-1).toString():null)}})}removeColumn(t,i){return u.__removeColumn(t,i)}static __getSelectedBound(t,i){let n,o,r,s=[[1/0,1/0],[0,0]],a=u.__formalMatrix(t);for(n=0;n<a.length;n+=1)for(o=0;a[n]&&o<a[n].length;o+=1)i.includes(a[n][o])&&(s[0][0]=Math.min(n,s[0][0]),s[0][1]=Math.min(o,s[0][1]),s[1][0]=Math.max(n,s[1][0]),s[1][1]=Math.max(o,s[1][1]));for(n=s[0][0];n<=s[1][0];n+=1)for(r=1,o=s[0][1];o<=s[1][1];o+=1){for(;a[n]&&a[n][o-r]&&a[n][o]===a[n][o-r];)s[0][1]=Math.min(o-r,s[0][1]),s[1][1]=Math.max(o-r,s[1][1]),r+=1;for(r=1;a[n]&&a[n][o+r]&&a[n][o]===a[n][o+r];)s[0][1]=Math.min(o+r,s[0][1]),s[1][1]=Math.max(o+r,s[1][1]),r+=1;for(r=1;a[n-r]&&a[n][o]===a[n-r][o];)s[0][0]=Math.min(n-r,s[0][0]),s[1][0]=Math.max(n-r,s[1][0]),r+=1;for(r=1;a[n+r]&&a[n][o]===a[n+r][o];)s[0][0]=Math.min(n+r,s[0][0]),s[1][0]=Math.max(n+r,s[1][0]),r+=1}return s}getSelectedBound(t,i){return u.__getSelectedBound(t,i)}static __normalizeTable(t){let i=[],n=u.__formalMatrix(t);u.__removeExtraColspans(n,i),u.__removeExtraRowspans(n,i);for(let t=0;t<n.length;t+=1)for(let i=0;i<n[t].length;i+=1)void 0!==n[t][i]&&(n[t][i].hasAttribute("rowspan")&&1===n[t][i].rowSpan&&(0,c.attr)(n[t][i],"rowspan",null),n[t][i].hasAttribute("colspan")&&1===n[t][i].colSpan&&(0,c.attr)(n[t][i],"colspan",null),n[t][i].hasAttribute("class")&&!(0,c.attr)(n[t][i],"class")&&(0,c.attr)(n[t][i],"class",null));u.__unmark(i)}static __removeExtraColspans(t,i){for(let n=0;n<t[0].length;n+=1){let o=1e6,r=!1;for(let i=0;i<t.length;i+=1)if(void 0!==t[i][n]){if(t[i][n].colSpan<2){r=!0;break}o=Math.min(o,t[i][n].colSpan)}if(!r)for(let r=0;r<t.length;r+=1)void 0!==t[r][n]&&u.__mark(t[r][n],"colspan",t[r][n].colSpan-o+1,i)}}static __removeExtraRowspans(t,i){let n=0,o=0;for(n=0;n<t.length;n+=1){let r=1e6,s=!1;for(o=0;o<t[n].length;o+=1)if(void 0!==t[n][o]){if(t[n][o].rowSpan<2){s=!0;break}r=Math.min(r,t[n][o].rowSpan)}if(!s)for(o=0;o<t[n].length;o+=1)void 0!==t[n][o]&&u.__mark(t[n][o],"rowspan",t[n][o].rowSpan-r+1,i)}}normalizeTable(t){return u.__normalizeTable(t)}static __mergeSelected(t,i){let n=[],o=u.__getSelectedBound(t,u.__getSelectedCellsByTable(t)),s=0,l=null,d=0,p=0,f=0,m=new Set,g=[];o&&(o[0][0]-o[1][0]||o[0][1]-o[1][1])&&(u.__formalMatrix(t,(t,r,a,b,y)=>{r>=o[0][0]&&r<=o[1][0]&&a>=o[0][1]&&a<=o[1][1]&&(m.has(t)||(m.add(t),r===o[0][0]&&t.style.width&&(s+=t.offsetWidth),""!==(0,c.trim)(t.innerHTML.replace(/<br(\/)?>/g,""))&&n.push(t.innerHTML),b>1&&(p+=b-1),y>1&&(f+=y-1),l?(u.__mark(t,"remove",1,g),h(i).removeSelection(t)):(l=t,d=a)))}),p=o[1][1]-o[0][1]+1,f=o[1][0]-o[0][0]+1,l&&(p>1&&u.__mark(l,"colspan",p,g),f>1&&u.__mark(l,"rowspan",f,g),s&&(u.__mark(l,"width",(s/t.offsetWidth*100).toFixed(r.ACCURACY)+"%",g),d&&u.__setColumnWidthByDelta(t,d,0,!0,g)),l.innerHTML=n.join("<br/>"),h(i).addSelection(l),m.delete(l),u.__unmark(g),u.__normalizeTable(t),(0,c.toArray)(t.rows).forEach(t=>{t.cells.length||a.Dom.safeRemove(t)})))}mergeSelected(t){return u.__mergeSelected(t,this.j)}static __splitHorizontal(t,i){let n,o,r,s,l,c=[];u.__getSelectedCellsByTable(t).forEach(d=>{(o=i.createInside.element("td")).appendChild(i.createInside.element("br")),r=i.createInside.element("tr"),n=u.__formalCoordinate(t,d),d.rowSpan<2?(u.__formalMatrix(t,(t,i,o)=>{n[0]===i&&n[1]!==o&&t!==d&&u.__mark(t,"rowspan",t.rowSpan+1,c)}),a.Dom.after(a.Dom.closest(d,"tr",t),r),r.appendChild(o)):(u.__mark(d,"rowspan",d.rowSpan-1,c),u.__formalMatrix(t,(i,o,r)=>{o>n[0]&&o<n[0]+d.rowSpan&&n[1]>r&&i.parentNode.rowIndex===o&&(l=i),n[0]<o&&i===d&&(s=t.rows[o])}),l?a.Dom.after(l,o):s.insertBefore(o,s.firstChild)),d.colSpan>1&&u.__mark(o,"colspan",d.colSpan,c),u.__unmark(c),h(i).removeSelection(d)}),this.__normalizeTable(t)}splitHorizontal(t){return u.__splitHorizontal(t,this.j)}static __splitVertical(t,i){let n,o,s,l=[];u.__getSelectedCellsByTable(t).forEach(c=>{n=u.__formalCoordinate(t,c),c.colSpan<2?u.__formalMatrix(t,(t,i,o)=>{n[1]===o&&n[0]!==i&&t!==c&&u.__mark(t,"colspan",t.colSpan+1,l)}):u.__mark(c,"colspan",c.colSpan-1,l),(o=i.createInside.element("td")).appendChild(i.createInside.element("br")),c.rowSpan>1&&u.__mark(o,"rowspan",c.rowSpan,l);let d=c.offsetWidth;a.Dom.after(c,o),s=d/t.offsetWidth/2,u.__mark(c,"width",(100*s).toFixed(r.ACCURACY)+"%",l),u.__mark(o,"width",(100*s).toFixed(r.ACCURACY)+"%",l),u.__unmark(l),h(i).removeSelection(c)}),u.__normalizeTable(t)}splitVertical(t){return u.__splitVertical(t,this.j)}static __setColumnWidthByDelta(t,i,n,o,s){let a=u.__formalMatrix(t),l=0;for(let o=0;o<a.length;o+=1){let c=a[o][i];if(c.colSpan>1&&a.length>1)continue;let d=(c.offsetWidth+n)/t.offsetWidth*100;u.__mark(c,"width",d.toFixed(r.ACCURACY)+"%",s),l=o;break}for(let t=l+1;t<a.length;t+=1){let n=a[t][i];u.__mark(n,"width",null,s)}o||u.__unmark(s)}setColumnWidthByDelta(t,i,n,o,r){return u.__setColumnWidthByDelta(t,i,n,o,r)}static __mark(t,i,n,o){var r;o.push(t);let s=null!=(r=d.get(t))?r:{};s[i]=void 0===n?1:n,d.set(t,s)}static __unmark(t){t.forEach(t=>{let i=d.get(t);i&&(Object.keys(i).forEach(n=>{let o=i[n];switch(n){case"remove":a.Dom.safeRemove(t);break;case"rowspan":(0,c.attr)(t,"rowspan",(0,c.isNumber)(o)&&o>1?o:null);break;case"colspan":(0,c.attr)(t,"colspan",(0,c.isNumber)(o)&&o>1?o:null);break;case"width":null==o?(t.style.removeProperty("width"),(0,c.attr)(t,"style")||(0,c.attr)(t,"style",null)):t.style.width=o.toString()}delete i[n]}),d.delete(t))})}constructor(){super(...arguments),this.selected=new Set}}u.__selectedByTable=new WeakMap,function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);s>3&&a&&Object.defineProperty(i,n,a)}([(0,s.debounce)()],u.prototype,"__recalculateStyles",null);let h=t=>t.getInstance("Table",t.o)},78644:function(t,i,n){"use strict";n.d(i,{ToolbarButton:function(){return T}});var o=n(78213),r=n(82758),s=n(45219),a=n(33433),l=n(87325),c=n(37133),d=n(2748),u=n(68345),h=n(23282),p=n(19306),f=n(72430),m=n(70799),g=n(56175),b=n(87058),y=n(38837),w=n(29960),_=n(37790),C=n(62843),k=n(72157),S=n(12153),x=n(56917),I=n(21491),E=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a};let T=class t extends C.UIButton{className(){return"ToolbarButton"}getRole(){return"listitem"}updateAriaLabel(){if(super.updateAriaLabel(),this.trigger){let t=this.state.tooltip?this.jodit.i18n(this.state.tooltip):null;(0,w.attr)(this.trigger,"aria-label",t)}}get toolbar(){let t=(0,l.getComponentClass)("ToolbarCollection");return this.closest(t)}update(){var t,i;let{control:n,state:o}=this,r=this.toolbar;if(!r)return;let s=null==(t=n.value)?void 0:t.call(n,r.jodit,this);void 0!==s&&(o.value=s),o.disabled=this.__calculateDisabledStatus(r),o.activated=this.__calculateActivatedStatus(r),null==(i=n.update)||i.call(n,r.jodit,this)}__calculateActivatedStatus(t){var i,n;return(!(0,p.isJoditObject)(this.j)||!!this.j.editorIsActive)&&(null!=(n=(i=this.control).isActive)&&!!n.call(i,this.j,this)||!!(t&&t.shouldBeActive(this)))}__calculateDisabledStatus(t){var i,n;return!!(this.j.o.disabled||this.j.o.readonly&&(!this.j.o.activeButtonsInReadOnly||!this.j.o.activeButtonsInReadOnly.includes(this.control.name))||(null==(n=(i=this.control).isDisabled)?void 0:n.call(i,this.j,this)))||!!(t&&t.shouldBeDisabled(this))}onChangeActivated(){(0,w.attr)(this.button,"aria-pressed",this.state.activated),super.onChangeActivated()}onChangeText(){(0,h.isFunction)(this.control.template)?this.text.innerHTML=this.control.template(this.j,this.control.name,this.j.i18n(this.state.text)):super.onChangeText(),this.setMod("text-icons",!!this.text.innerText.trim().length)}onChangeTabIndex(){(0,w.attr)(this.button,"tabindex",this.state.tabIndex),(0,w.attr)(this.trigger,"tabindex",this.state.tabIndex)}createContainer(){let t=this.componentName,i=this.j.c.span(t),n=super.createContainer();n.classList.remove(t),n.classList.add(t+"__button"),Object.defineProperty(n,"component",{value:this,configurable:!0}),i.appendChild(n);let o=this.j.c.fromHTML(`<span role="button" aria-haspopup="true" aria-expanded="false" class="${t}__trigger">${S.Icon.get("chevron")}</span>`);return n.appendChild(o),i}focus(){var t;null==(t=this.container.querySelector("button"))||t.focus()}onChangeHasTrigger(){this.state.hasTrigger?this.container.appendChild(this.trigger):d.Dom.safeRemove(this.trigger),this.setMod("with-trigger",this.state.hasTrigger||null)}onChangeDisabled(){let t=this.state.disabled?"disabled":null;(0,w.attr)(this.trigger,"disabled",t),(0,w.attr)(this.button,"disabled",t),(0,w.attr)(this.container,"disabled",t)}__initFromControl(){let{control:t,state:i}=this;this.updateSize(),i.name=t.name,this.__initIconFromControl(),t.tooltip&&(i.tooltip=(0,h.isFunction)(t.tooltip)?t.tooltip(this.j,t,this):t.tooltip),i.hasTrigger=!!(t.list||t.popup&&t.exec)}__initIconFromControl(){var t;let{control:i,state:n}=this,{textIcons:o}=this.j.o;if(!0===o||(0,h.isFunction)(o)&&o(i.name)||i.template){n.icon=(0,C.UIButtonState)().icon,n.text=i.text||i.name;return}if(!(0,m.isString)(i.icon)&&null!=i.icon){n.icon={name:i.icon.name||i.name,iconURL:i.icon.iconURL||"",fill:i.icon.fill||"",scale:i.icon.scale};return}if(i.iconURL)n.icon.iconURL=i.iconURL;else{let o=i.icon||i.name;n.icon.name=S.Icon.exists(o)||(null==(t=this.j.o.extraIcons)?void 0:t[o])?o:""}i.iconURL||n.icon.name||(n.text=i.text||i.name)}onTriggerClick(t){var i,n,o;if(this.openedPopup)return void this.__closePopup();let{control:r}=this;if((0,w.attr)(this.trigger,"aria-expanded",!0),t.buffer={actionTrigger:this},r.list)return this.__openControlList(r);if((0,h.isFunction)(r.popup)){let t=this.openPopup();t.parentElement=this;try{if(!1!==this.j.e.fire((0,b.camelCase)(`before-${r.name}-open-popup`),this.target,r,t)){let s=null!=(o=null!=(n=null==(i=this.toolbar)?void 0:i.getTarget(this))?n:this.target)?o:null,a=r.popup(this.j,s,this.__closePopup,this);a?t.setContent((0,m.isString)(a)?this.j.c.fromHTML(a):a).open(()=>(0,g.position)(this.container),!1,this.j.o.allowTabNavigation?this.container:void 0):this.__closePopup()}}catch(t){throw this.__closePopup(),t}this.j.e.fire((0,b.camelCase)(`after-${r.name}-open-popup`),t.container)}}onTriggerKeyDown(t){!this.state.disabled&&[r.KEY_ENTER,r.KEY_SPACE," "].includes(t.key)&&(t.preventDefault(),this.trigger.click())}__openControlList(t){var i;let n=null!=(i=this.jodit.options.controls)?i:{},o=t=>(0,k.findControlType)(t,n),r=t.list,s=this.openPopup(),a=(0,I.makeCollection)(this.j);s.parentElement=this,a.parentElement=s,a.mode="vertical";let l=(i,n)=>{let r;if((0,m.isString)(n)&&o(n))return{name:n.toString(),...o(n)};if((0,m.isString)(i)&&o(i))return{name:i.toString(),...o(i),..."object"==typeof n?n:{}};r=i,(0,f.isPlainObject)(r)&&"title"in r&&"value"in r&&(n=i.value,i=i.title);let{childTemplate:s}=t,a={name:i.toString(),template:s&&((t,i,n)=>s(t,i,n,this)),exec:t.childExec?(i,n,o)=>{var r;return null==(r=t.childExec)?void 0:r.call(t,i,n,{...o,parentControl:t})}:t.exec,data:t.data,command:t.command,isActive:t.isChildActive,value:t.value,isDisabled:t.isChildDisabled,mode:t.mode,args:[...t.args?t.args:[],i,n]};return(0,m.isString)(n)&&(a.text=n),a};a.build((0,u.isArray)(r)?r.map(l):(0,_.keys)(r,!1).map(t=>l(t,r[t])),this.target),s.setContent(a).open(()=>(0,g.position)(this.container),!1,this.j.o.allowTabNavigation?this.container:void 0),this.state.activated=!0}onOutsideClick(t){this.openedPopup&&(t&&d.Dom.isNode(t.target)&&(d.Dom.isOrContains(this.container,t.target)||this.openedPopup.isOwnClick(t))||this.__closePopup())}openPopup(){return this.__closePopup(),this.openedPopup=new x.Popup(this.j,!1),this.j.e.on(this.ow,"mousedown touchstart",this.onOutsideClick).on("escape closeAllPopups",this.onOutsideClick),this.openedPopup}__closePopup(){this.openedPopup&&(this.j.e.off(this.ow,"mousedown touchstart",this.onOutsideClick).off("escape closeAllPopups",this.onOutsideClick),this.state.activated=!1,this.openedPopup.close(),this.openedPopup.destruct(),this.openedPopup=null,this.trigger&&(0,w.attr)(this.trigger,"aria-expanded",!1))}onClick(t){var i,n,o,r,s,a,l;let{control:c}=this;if((0,h.isFunction)(c.exec)){let d=null!=(o=null!=(n=null==(i=this.toolbar)?void 0:i.getTarget(this))?n:this.target)?o:null,u=c.exec(this.j,d,{control:c,originalEvent:t,button:this});if(!1!==u&&!0!==u&&(null==(s=null==(r=this.j)?void 0:r.e)||s.fire("synchro"),this.parentElement&&this.parentElement.update(),null==(l=null==(a=this.j)?void 0:a.e)||l.fire("closeAllPopups afterExec")),!1!==u)return}return c.list?this.__openControlList(c):(0,h.isFunction)(c.popup)?this.onTriggerClick(t):void((c.command||c.name)&&((0,_.call)((0,p.isJoditObject)(this.j)?this.j.execCommand.bind(this.j):this.j.od.execCommand.bind(this.j.od),c.command||c.name,!1,c.args&&c.args[0]),this.j.e.fire("closeAllPopups")))}destruct(){return this.__closePopup(),super.destruct()}constructor(t,i,n=null){super(t),this.control=i,this.target=n,this.state={...(0,C.UIButtonState)(),theme:"toolbar",currentValue:"",hasTrigger:!1},this.openedPopup=null;const r=this.getElm("button");(0,y.assert)(r,"Element button should exists"),this.button=r,Object.defineProperty(r,"component",{value:this,configurable:!0});const s=this.getElm("trigger");(0,y.assert)(s,"Element trigger should exists"),this.trigger=s,s.remove(),t.e.on([this.button,this.trigger],"mousedown",t=>t.preventDefault()),this.onAction(this.onClick),this.hookStatus(o.STATUSES.ready,()=>{this.__initFromControl(),this.update()}),i.mods&&Object.keys(i.mods).forEach(t=>{i.mods&&this.setMod(t,i.mods[t])})}};E([a.cacheHTML],T.prototype,"createContainer",null),E([(0,c.watch)("state.hasTrigger",{immediately:!1})],T.prototype,"onChangeHasTrigger",null),E([(0,c.watch)("trigger:click")],T.prototype,"onTriggerClick",null),E([(0,c.watch)("trigger:keydown")],T.prototype,"onTriggerKeyDown",null),E([s.autobind],T.prototype,"onOutsideClick",null),E([s.autobind],T.prototype,"__closePopup",null),T=E([l.component],T)},80319:function(t,i,n){"use strict";n.d(i,{ToolbarContent:function(){return l}});var o=n(65478),r=n(22732),s=n(21537),a=n(62843);let l=class t extends a.UIButton{className(){return"ToolbarContent"}update(){var t,i,n;let{control:o}=this,a=o.getContent(this.j,this);((0,s.isString)(a)||a.parentNode!==this.container)&&(r.Dom.detach(this.container),this.container.appendChild((0,s.isString)(a)?this.j.create.fromHTML(a):a)),this.state.disabled=!!(null==(t=o.isDisabled)?void 0:t.call(o,this.j,this)),this.state.activated=!!(null==(i=o.isActive)?void 0:i.call(o,this.j,this)),null==(n=o.update)||n.call(o,this.j,this),this.onChangeDisabled(),this.onChangeActivated(),super.update()}onChangeDisabled(){super.onChangeDisabled(),this.container.querySelectorAll("input,button,select,textarea").forEach(t=>(0,s.attr)(t,"disabled",this.state.disabled||null))}createContainer(){return this.j.c.span(this.componentName)}constructor(t,i,n=null){super(t),this.control=i,this.target=n,this.container.classList.add(`${this.componentName}_${this.clearName(i.name)}`),(0,s.attr)(this.container,"role","content")}};l=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a}([o.component],l)},36646:function(t,i,n){"use strict";n.d(i,{ToolbarButton:function(){return o.ToolbarButton},ToolbarContent:function(){return r.ToolbarContent},ToolbarSelect:function(){return s.ToolbarSelect}});var o=n(78644),r=n(80319),s=n(83111)},83111:function(t,i,n){"use strict";n.d(i,{ToolbarSelect:function(){return l}});var o=n(65478),r=n(72430),s=n(70799),a=n(78644);let l=class t extends a.ToolbarButton{className(){return"ToolbarSelect"}update(){var t,i,n;super.update(),this.state.icon.name="";let{list:o,data:a}=this.control;if(o){let l=this.state.value||(a&&(0,s.isString)(a.currentValue)?a.currentValue:void 0);l||(l=Object.keys(o)[0]);let c=((0,r.isPlainObject)(o)&&o[l.toString()]||l).toString();this.state.text=null!=(n=null==(i=(t=this.control).textTemplate)?void 0:i.call(t,this.jodit,c))?n:c}}};l=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a}([o.component],l)},11676:function(t,i,n){"use strict";n.d(i,{ToolbarCollection:function(){return p}});var o=n(65478),r=n(45219),s=n(87325),a=n(97357),l=n(37133),c=n(82760),d=n(24536),u=n(21491),h=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a};let p=class t extends d.UIList{className(){return"ToolbarCollection"}getRole(){return"toolbar"}get firstButton(){let[t]=this.buttons;return t||null}makeButton(t,i=null){return(0,u.makeButton)(this.j,t,i)}makeSelect(t,i=null){return(0,u.makeSelect)(this.j,t,i)}shouldBeActive(t){}shouldBeDisabled(t){}getTarget(t){return t.target||null}__immediateUpdate(){this.isDestructed||this.j.isLocked||(super.update(),this.j.e.fire("afterUpdateToolbar",this))}update(){this.__immediateUpdate()}setDirection(t){this.container.style.direction=t,this.container.setAttribute("dir",t)}__initEvents(){this.j.e.on(this.__listenEvents,this.update).on("afterSetMode focus",this.__immediateUpdate)}hide(){this.container.remove()}show(){this.appendTo(this.j.toolbarContainer)}showInline(t){throw(0,c.error)("The method is not implemented for this class.")}build(t,i=null){let n=this.j.e.fire("beforeToolbarBuild",t);return n&&(t=n),super.build(t,i),this}destruct(){this.isDestructed||(this.j.e.off(this.__listenEvents,this.update).off("afterSetMode focus",this.__immediateUpdate),super.destruct())}constructor(t){super(t),this.__listenEvents="updatePlugins updateToolbar changeStack mousedown mouseup keydown change readonly afterResize selectionchange changeSelection focus afterSetMode touchstart focus blur"}};h([(0,l.watch)(":afterInit"),r.autobind],p.prototype,"__immediateUpdate",null),h([(0,o.debounce)(t=>t.j.defaultTimeout,!0)],p.prototype,"update",null),h([(0,a.hook)("ready")],p.prototype,"__initEvents",null),p=h([s.component],p)},37426:function(t,i,n){"use strict";n.d(i,{ToolbarEditorCollection:function(){return c}});var o=n(82758),r=n(65478),s=n(22732),a=n(21537),l=n(11676);let c=class t extends l.ToolbarCollection{className(){return"ToolbarEditorCollection"}shouldBeDisabled(t){let i=super.shouldBeDisabled(t);if(void 0!==i)return i;let n=void 0===t.control.mode?o.MODE_WYSIWYG:t.control.mode;return n!==o.MODE_SPLIT&&n!==this.j.getRealMode()}shouldBeActive(t){let i,n=super.shouldBeActive(t);if(void 0!==n)return n;let o=this.j.selection?this.j.s.current():null;if(!o)return!1;if(t.control.tags){let n=t.control.tags;if(i=o,s.Dom.up(i,t=>{if(t&&-1!==n.indexOf(t.nodeName.toLowerCase()))return!0},this.j.editor))return!0}if(t.control.css){let n=t.control.css;if(i=o,s.Dom.up(i,t=>{if(t&&!s.Dom.isText(t)&&!s.Dom.isComment(t))return this.checkActiveStatus(n,t)},this.j.editor))return!0}return!1}getTarget(t){return t.target||this.j.s.current()||null}prependInvisibleInput(t){let i=this.j.create.element("input",{name:"jodit-toolbar-focus-helper_"+this.j.id,tabIndex:-1,disabled:!0,style:"width: 0; height:0; position: absolute; visibility: hidden;"});s.Dom.appendChildFirst(t,i)}showInline(t){this.jodit.e.fire("showInlineToolbar",t)}hide(){this.jodit.e.fire("hidePopup"),super.hide(),this.jodit.e.fire("toggleToolbar")}show(){super.show(),this.jodit.e.fire("toggleToolbar")}constructor(t){super(t),this.checkActiveStatus=(t,i)=>{let n=0,o=0;return Object.keys(t).forEach(r=>{let s=t[r];(0,a.isFunction)(s)?s(this.j,(0,a.css)(i,r).toString())&&(n+=1):-1!==s.indexOf((0,a.css)(i,r).toString())&&(n+=1),o+=1}),o===n},this.prependInvisibleInput(this.container)}};c=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a}([r.component],c)},21491:function(t,i,n){"use strict";n.d(i,{makeButton:function(){return l},makeCollection:function(){return a},makeSelect:function(){return c}});var o=n(87325),r=n(23282),s=n(19306);function a(t,i){let n=(0,o.getComponentClass)("ToolbarCollection"),r=(0,o.getComponentClass)("ToolbarEditorCollection"),a=(0,s.isJoditObject)(t)?new r(t):new n(t);return t.o.textIcons&&a.container.classList.add("jodit_text_icons"),i&&(a.parentElement=i),t.o.toolbarButtonSize&&(a.buttonSize=t.o.toolbarButtonSize),a}function l(t,i,n=null){if((0,r.isFunction)(i.getContent))return new((0,o.getComponentClass)("ToolbarContent"))(t,i,n);let s=new((0,o.getComponentClass)("ToolbarButton"))(t,i,n);return s.state.tabIndex=t.o.allowTabNavigation?0:-1,s}function c(t,i,n=null){return new((0,o.getComponentClass)("ToolbarSelect"))(t,i,n)}},80536:function(t,i,n){"use strict";var o=n(68345),r=n(19306),s=n(6441);s.Config.prototype.enableDragAndDropFileToEditor=!0,s.Config.prototype.uploader={url:"",insertImageAsBase64URI:!1,showTabInFileSelector:!0,imagesExtensions:["jpg","jpeg","png","gif","webp","bmp","svg","tiff","avif"],headers:null,data:null,filesVariableName:t=>`files[${t}]`,withCredentials:!1,pathVariableName:"path",format:"json",method:"POST",prepareData:t=>t,isSuccess:t=>t.success,getMessage:t=>void 0!==t.data.messages&&(0,o.isArray)(t.data.messages)?t.data.messages.join(" "):"",processFileName:(t,i,n)=>[t,i,n],process:t=>t.data,error(t){this.j.message.error(t.message,4e3)},getDisplayName:(t,i)=>t+i,defaultHandlerSuccess(t){let i=this.j||this;(0,r.isJoditObject)(i)&&t.files&&t.files.length&&t.files.forEach((n,o)=>{let[r,s]=t.isImages&&t.isImages[o]?["img","src"]:["a","href"],a=i.createInside.element(r);a.setAttribute(s,t.baseurl+n),"a"===r&&(a.textContent=i.o.uploader.getDisplayName.call(this,t.baseurl,n)),"img"===r?i.s.insertImage(a,null,i.o.imageDefaultWidth):i.s.insertNode(a)})},defaultHandlerError(t){this.j.message.error(t.message)},contentType(t){return(void 0===this.ow.FormData||"string"==typeof t)&&"application/x-www-form-urlencoded; charset=UTF-8"}}},83987:function(t,i,n){"use strict";n.d(i,{buildData:function(){return r}});var o=n(21537);function r(t,i){if((0,o.isFunction)(t.o.buildData))return t.o.buildData.call(t,i);let n=t.ow.FormData;if(void 0!==n){if(i instanceof n||(0,o.isString)(i))return i;let t=new n;return Object.keys(i).forEach(n=>{t.append(n,i[n])}),t}return i}},74569:function(t,i,n){"use strict";function o(t){let i=atob(t.split(",")[1]),n=t.split(",")[0].split(":")[1].split(";")[0],o=new Uint8Array(new ArrayBuffer(i.length));for(let t=0;t<i.length;t+=1)o[t]=i.charCodeAt(t);return new Blob([o.buffer],{type:n})}n.d(i,{dataURItoBlob:function(){return o}})},94122:function(t,i,n){"use strict";n.d(i,{ajaxInstances:function(){return r.ajaxInstances},hasFiles:function(){return a},hasItems:function(){return l},processOldBrowserDrag:function(){return o.processOldBrowserDrag},send:function(){return r.send},sendFiles:function(){return s.sendFiles}}),n(83987);var o=n(50373),r=n(71686),s=n(80020);function a(t){return!!(t&&t.files&&t.files.length>0)}function l(t){return!!(t&&t.items&&t.items.length>0)}},50373:function(t,i,n){"use strict";n.d(i,{processOldBrowserDrag:function(){return d}});var o=n(82758),r=n(22732),s=n(580),a=n(21537),l=n(74569),c=n(80020);function d(t,i,n,d,u){if(i&&(!i.types.length||i.types[0]!==o.TEXT_PLAIN)){let i=t.j.c.div("",{tabindex:-1,style:"left: -9999px; top: 0; width: 0; height: 100%;line-height: 140%; overflow: hidden; position: fixed; z-index: 2147483647; word-break: break-all;",contenteditable:!0});(0,s.getContainer)(t.j,t.constructor).appendChild(i);let o=(0,a.isJoditObject)(t.j)?t.j.s.save():null;i.focus(),t.j.async.setTimeout(()=>{let s=i.firstChild;if(r.Dom.safeRemove(i),s&&s.hasAttribute("src")){let i=(0,a.attr)(s,"src")||"";o&&(0,a.isJoditObject)(t.j)&&t.j.s.restore(),(0,c.sendFiles)(t,[(0,l.dataURItoBlob)(i)],n,d).finally(u)}},t.j.defaultTimeout)}}},80020:function(t,i,n){"use strict";n.d(i,{sendFiles:function(){return s}});var o=n(21537),r=n(71686);function s(t,i,n,s,a){if(!i)return Promise.reject((0,o.error)("Need files"));let{o:l}=t,c=(0,o.toArray)(i);if(!c.length)return Promise.reject((0,o.error)("Need files"));if((0,o.isFunction)(l.beforeUpload)&&!1===l.beforeUpload.call(t,c)){let i=(0,o.error)("Upload canceled");return(s||l.defaultHandlerError).call(t,i),Promise.reject(i)}let d=[];if(l.insertImageAsBase64URI&&function(t,i,n,r,s,a){let l,c,d=[];for(c=0;c<t.length;c+=1)if((l=t[c])&&l.type){let u=l.type.match(/\/([a-z0-9]+)/i),h=u[1]?u[1].toLowerCase():"";if(!i.includes(h))continue;let p=new FileReader,f=r.j.async.promise((t,i)=>{p.onerror=i,p.onloadend=()=>{let i={baseurl:"",files:[p.result],isImages:[!0]};((0,o.isFunction)(s)?s:a).call(r,i),t(i)},p.readAsDataURL(l)});d.push(f),n.push(f),t[c]=null}d.length&&Promise.all(d).then(()=>{r.j.events&&r.j.e.fire("filesWereUploaded")}).catch(()=>{})}(c,l.imagesExtensions,d,t,n,l.defaultHandlerSuccess),(c=c.filter(t=>t)).length){let i,u=new FormData;u.append(l.pathVariableName,t.path),u.append("source",t.source);for(let n=0;n<c.length;n+=1)if(i=c[n]){let o=/\.\w+$/.test(i.name),r=i.type.match(/\/([a-z0-9]+)/i),s=r&&r[1]?r[1].toLowerCase():"",a=c[n].name||Math.random().toString().replace(".","");if(!o&&s){let t=s;["jpeg","jpg"].includes(t)&&(t="jpeg|jpg"),RegExp(".("+t+")$","i").test(a)||(a+="."+s)}let[d,h,p]=l.processFileName.call(t,l.filesVariableName(n),c[n],a);u.append(d,h,p)}a&&a(u),l.data&&(0,o.isPlainObject)(l.data)&&Object.keys(l.data).forEach(t=>{u.append(t,l.data[t])}),l.prepareData.call(t,u),d.push((0,r.send)(t,u).then(i=>(l.isSuccess.call(t,i)?((0,o.isFunction)(n)?n:l.defaultHandlerSuccess).call(t,l.process.call(t,i)):((0,o.isFunction)(s)?s:l.defaultHandlerError).call(t,(0,o.error)(l.getMessage.call(t,i))),i)).then(()=>{t.j.events&&t.j.e.fire("filesWereUploaded")}))}return Promise.all(d)}},71686:function(t,i,n){"use strict";n.d(i,{ajaxInstances:function(){return a},send:function(){return l}});var o=n(21537),r=n(41601),s=n(83987);let a=new WeakMap;function l(t,i){let n=(0,s.buildData)(t,i),l=i=>{t.j.progressbar.show().progress(i),i>=100&&t.j.progressbar.hide()},c=(i,n)=>{let s=new r.Ajax({xhr(){let i=new XMLHttpRequest;return void 0!==t.j.ow.FormData&&i.upload?(n(10),i.upload.addEventListener("progress",t=>{if(t.lengthComputable){let i=t.loaded/t.total;n(i*=100)}},!1)):n(100),i},method:t.o.method||"POST",data:i,url:(0,o.isFunction)(t.o.url)?t.o.url(i):t.o.url,headers:t.o.headers,queryBuild:t.o.queryBuild,contentType:t.o.contentType.call(t,i),withCredentials:t.o.withCredentials||!1}),l=a.get(t);return l||(l=new Set,a.set(t,l)),l.add(s),t.j.e.one("beforeDestruct",s.destruct),s.send().then(t=>t.json()).catch(t=>({success:!1,data:{messages:[t]}})).finally(()=>{s.destruct(),null==l||l.delete(s)})};return((0,o.isFunction)(t.o.customUploadFunction)&&(c=t.o.customUploadFunction),(0,o.isPromise)(n))?n.then(t=>c(t,l)).catch(i=>{t.o.error.call(t,i)}):c(n,l)}},57380:function(t,i,n){"use strict";n.d(i,{Uploader:function(){return c}});var o=n(91907),r=n(82758),s=n(21537),a=n(6441),l=n(94122);n(80536);class c extends o.ViewComponent{get j(){return this.jodit}className(){return"Uploader"}get o(){return this.options}setPath(t){return this.path=t,this}setSource(t){return this.source=t,this}bind(t,i,n){let o=()=>{t.classList.remove("jodit_drag_hover")},s=this,a=t=>{let a,c,d,u=t.clipboardData,h=t=>{c&&(t.append("extension",d),t.append("mimetype",c.type))};if(!r.IS_IE&&(0,l.hasFiles)(u))return(0,l.sendFiles)(s,u.files,i,n).finally(o),!1;if(r.IS_IE&&!r.IS_ES_NEXT)return(0,l.processOldBrowserDrag)(s,u,i,n,o);if((0,l.hasItems)(u)){let{items:r}=u;for(a=0;a<r.length;a+=1)if("file"===r[a].kind&&"image/png"===r[a].type){if(c=r[a].getAsFile()){let t=c.type.match(/\/([a-z0-9]+)/i);d=t[1]?t[1].toLowerCase():"",(0,l.sendFiles)(s,[c],i,n,h).finally(o)}t.preventDefault();break}}};s.j&&s.j.editor!==t?s.j.e.on(t,"paste",a):s.j.e.on("beforePaste",a),this.attachEvents(t,i,n,o)}attachEvents(t,i,n,o){let r=this;r.j.e.on(t,"dragend dragover dragenter dragleave drop",t=>{t.preventDefault()}).on(t,"dragover",i=>{((0,l.hasFiles)(i.dataTransfer)||(0,l.hasItems)(i.dataTransfer))&&(t.classList.add("jodit_drag_hover"),i.preventDefault())}).on(t,"dragend dragleave",i=>{t.classList.remove("jodit_drag_hover"),(0,l.hasFiles)(i.dataTransfer)&&i.preventDefault()}).on(t,"drop",s=>{t.classList.remove("jodit_drag_hover"),(0,l.hasFiles)(s.dataTransfer)&&(s.preventDefault(),s.stopImmediatePropagation(),(0,l.sendFiles)(r,s.dataTransfer.files,i,n).finally(o))});let s=t.querySelector("input[type=file]");s&&r.j.e.on(s,"change",()=>{(0,l.sendFiles)(r,s.files,i,n).then(()=>{s.value="",/safari/i.test(navigator.userAgent)||(s.type="",s.type="file")}).finally(o)})}uploadRemoteImage(t,i,n){let o=this,{o:r}=o,a=(0,s.isFunction)(n)?n:r.defaultHandlerError;(0,l.send)(o,{action:"fileUploadRemote",url:t}).then(t=>{r.isSuccess.call(o,t)?((0,s.isFunction)(i)?i:r.defaultHandlerSuccess).call(o,r.process.call(o,t)):a.call(o,(0,s.error)(r.getMessage.call(o,t)))}).catch(t=>a.call(o,t))}upload(t){return this.async.promise((i,n)=>{(0,l.sendFiles)(this,t,i,n)})}destruct(){this.setStatus(o.STATUSES.beforeDestruct);let t=l.ajaxInstances.get(this);t&&(t.forEach(t=>{try{t.destruct()}catch(t){}}),t.clear()),super.destruct()}constructor(t,i){super(t),this.path="",this.source="default",this.options=(0,s.ConfigProto)(i||{},(0,s.ConfigProto)(a.Config.defaultOptions.uploader,(0,s.isJoditObject)(t)?t.o.uploader:{}))}}},22859:function(t,i,n){"use strict";n.d(i,{ColorPickerWidget:function(){return l}});var o=n(22732),r=n(21537),s=n(67510),a=n(37068);s.Icon.set("palette",a.default);let l=(t,i,n)=>{let a="jodit-color-picker",l=(0,r.normalizeColor)(n),c=t.c.div(a),d=t.o.textIcons?`<span>${t.i18n("palette")}</span>`:s.Icon.get("palette"),u=t=>{let i=[];return(0,r.isPlainObject)(t)?Object.keys(t).forEach(n=>{i.push(`<div class="${a}__group ${a}__group-${n}">`),i.push(u(t[n])),i.push("</div>")}):(0,r.isArray)(t)&&t.forEach(t=>{i.push(`<span class='${a}__color-item ${l===t?a+"__color-item_active_true":""}' title="${t}" style="background-color:${t}" data-color="${t}"></span>`)}),i.join("")};c.appendChild(t.c.fromHTML(`<div class="${a}__groups">${u(t.o.colors)}</div>`)),c.appendChild(t.c.fromHTML(`<div data-ref="extra" class="${a}__extra"></div>`));let{extra:h}=(0,r.refs)(c);h.appendChild(t.c.fromHTML(`<div class="${a}__hex"><input data-ref="hexInput" type="text" spellcheck="false" aria-label="HEX" placeholder="#FF0000" value="${l||""}"/></div>`));let{hexInput:p}=(0,r.refs)(c),f=()=>{let t=p.value.trim(),n=/^#?[0-9a-f]{3}(?:[0-9a-f]{3})?$/i.test(t),o=/^rgba?\([\d\s.,%]+\)$/i.test(t);if(!n&&!o)return;let s=(0,r.normalizeColor)(n&&!t.startsWith("#")?"#"+t:t);s&&(0,r.isFunction)(i)&&i(s)};return t.e.on(p,"keydown",t=>{t.stopPropagation(),"Enter"===t.key&&(t.preventDefault(),f())}).on(p,"change",t=>{t.stopPropagation(),f()}),t.o.showBrowserColorPicker&&(0,r.hasBrowserColorPicker)()&&(h.appendChild(t.c.fromHTML(`<div class="${a}__native">${d}<input type="color" value="#ffffff"/></div>`)),t.e.on(c,"change",t=>{t.stopPropagation();let n=t.target;if(!n||!n.tagName||!o.Dom.isTag(n,"input")||"color"!==n.type)return;let s=n.value||"";(0,r.isFunction)(i)&&i(s),t.preventDefault()})),t.e.on(c,"mousedown touchend",n=>{if(o.Dom.isTag(n.target,"input"))return void n.stopPropagation();n.stopPropagation(),n.preventDefault();let s=n.target;if((!s||!s.tagName||o.Dom.isTag(s,"svg")||o.Dom.isTag(s,"path"))&&s.parentNode&&(s=o.Dom.closest(s.parentNode,"span",t.editor)),!o.Dom.isTag(s,"span")||!s.classList.contains(a+"__color-item"))return;let l=(0,r.attr)(s,"-color")||"";i&&(0,r.isFunction)(i)&&i(l)}),t.e.fire("afterGenerateColorPicker",c,h,i,l),c}},37068:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' x="0px" y="0px" viewBox="0 0 459 459"> <g> <path d="M229.5,0C102,0,0,102,0,229.5S102,459,229.5,459c20.4,0,38.25-17.85,38.25-38.25c0-10.2-2.55-17.85-10.2-25.5 c-5.1-7.65-10.2-15.3-10.2-25.5c0-20.4,17.851-38.25,38.25-38.25h45.9c71.4,0,127.5-56.1,127.5-127.5C459,91.8,357,0,229.5,0z M89.25,229.5c-20.4,0-38.25-17.85-38.25-38.25S68.85,153,89.25,153s38.25,17.85,38.25,38.25S109.65,229.5,89.25,229.5z M165.75,127.5c-20.4,0-38.25-17.85-38.25-38.25S145.35,51,165.75,51S204,68.85,204,89.25S186.15,127.5,165.75,127.5z M293.25,127.5c-20.4,0-38.25-17.85-38.25-38.25S272.85,51,293.25,51s38.25,17.85,38.25,38.25S313.65,127.5,293.25,127.5z M369.75,229.5c-20.4,0-38.25-17.85-38.25-38.25S349.35,153,369.75,153S408,170.85,408,191.25S390.15,229.5,369.75,229.5z" /> </g> </svg> '},34793:function(t,i,n){"use strict";n.d(i,{FileSelectorWidget:function(){return l}});var o=n(2748),r=n(21537),s=n(67510),a=n(38927);let l=(t,i,n,l,d=!0)=>{let u,h=[],p=t.o.uploader;if(i.upload&&!1!==p.showTabInFileSelector&&(p.url||p.insertImageAsBase64URI||p.customUploadFunction)){let n=t.c.fromHTML(`<div class="jodit-drag-and-drop__file-box"><strong>${t.i18n(d?"Drop image":"Drop file")}</strong><span><br>${t.i18n("or click")}</span><input type="file" accept="${d?"image/*":"*"}" tabindex="-1" dir="auto" multiple=""/></div>`);t.uploader.bind(n,n=>{let o=(0,r.isFunction)(i.upload)?i.upload:p.defaultHandlerSuccess;(0,r.isFunction)(o)&&o.call(t,n),t.e.fire("closeAllPopups")},i=>{t.message.error(i.message),t.e.fire("closeAllPopups")}),h.push({icon:"upload",name:"Upload",content:n})}if(i.filebrowser&&(t.o.filebrowser.ajax.url||t.o.filebrowser.items.url)&&h.push({icon:"folder",name:"Browse",content(){l&&l(),i.filebrowser&&t.filebrowser.open(i.filebrowser,d)}}),i.url){let a=new s.UIButton(t,{type:"submit",variant:"primary",text:"Insert"}),l=new s.UIForm(t,[new s.UIInput(t,{required:!0,label:"URL",name:"url",type:"text",placeholder:"https://"}),new s.UIInput(t,{name:"text",label:"Alternative text"}),new s.UIBlock(t,[a])]);u=null,n&&!o.Dom.isText(n)&&!o.Dom.isComment(n)&&(o.Dom.isTag(n,"img")||(0,r.$$)("img",n).length)&&(u="IMG"===n.tagName?n:(0,r.$$)("img",n)[0],c(l.container,"input[name=url]",(0,r.attr)(u,"src")),c(l.container,"input[name=text]",(0,r.attr)(u,"alt")),a.state.text="Update"),n&&o.Dom.isTag(n,"a")&&(c(l.container,"input[name=url]",(0,r.attr)(n,"href")),c(l.container,"input[name=text]",(0,r.attr)(n,"title")),a.state.text="Update"),l.onSubmit(n=>{(0,r.isFunction)(i.url)&&i.url.call(t,n.url,n.text)}),h.push({icon:"link",name:"URL",content:l.container})}let f=(0,a.TabsWidget)(t,h);return f.classList.add("jodit-file-selector"),f};function c(t,i,n){let o=t.querySelector(i);return o?(n&&(o.value=n),o.value):""}},92762:function(t,i,n){"use strict";n.d(i,{ColorPickerWidget:function(){return o.ColorPickerWidget},FileSelectorWidget:function(){return r.FileSelectorWidget},TabsWidget:function(){return s.TabsWidget}});var o=n(22859),r=n(34793),s=n(38927)},38927:function(t,i,n){"use strict";n.d(i,{TabsWidget:function(){return c}});var o=n(91907),r=n(2748),s=n(23282),a=n(29960),l=n(67510);let c=(t,i,n)=>{let c=t.c.div("jodit-tabs"),d=t.c.div("jodit-tabs__wrapper"),u=t.c.div("jodit-tabs__buttons");(0,a.attr)(u,{role:"tablist","aria-orientation":"horizontal"});let h={},p=[],f="";c.appendChild(u),c.appendChild(d);let m=t=>{h[t]&&(p.forEach(t=>{t.state.activated=!1}),Object.values(h).forEach(({tab:t})=>t.classList.remove("jodit-tab_active")),h[t].button.state.activated=!0,h[t].tab.classList.add("jodit-tab_active"))};if(i.forEach(({icon:c,name:g,content:b})=>{let y=t.c.div("jodit-tab");(0,a.attr)(y,{role:"tabpanel"});let w=(0,l.Button)(t,c||g,g);w.state.role="tab",t.e.on(w.container,"pointerdown",t=>t.preventDefault()),f||(f=g),u.appendChild(w.container),p.push(w),w.container.classList.add("jodit-tabs__button","jodit-tabs__button_columns_"+i.length),(0,s.isFunction)(b)?y.classList.add("jodit-tab_empty"):y.appendChild(o.Component.isInstanceOf(b,l.UIElement)?b.container:b),d.appendChild(y),w.onAction(()=>(m(g),(0,s.isFunction)(b)&&!r.Dom.isElement(b)&&b.call(t),n&&(n.activeTab=g),!1)),h[g]={button:w,tab:y}}),m(n&&n.activeTab&&h[n.activeTab]?n.activeTab:f),n){let t=n.activeTab;Object.defineProperty(n,"activeTab",{configurable:!0,enumerable:!1,get:()=>t,set(i){t=i,m(i)}})}return c}},73391:function(t,i,n){"use strict";var o=n(82758),r=n(580),s=n(21537),a=n(12153),l=n(6441),c=n(49399);l.Config.prototype.controls.about={exec(t){let i=t.dlg({closeOnClickOverlay:!0}),n=t.i18n.bind(t);i.setMod("theme",t.o.theme).setHeader(n("About Jodit")).setContent(`<div class="jodit-about">
|
|
124
124
|
<div>${n("Jodit Editor")} v.${t.getVersion()}</div>
|
|
125
125
|
<div>${n("License: %s",!(0,s.isLicense)(t.o.license)?t.o.license||"MIT":(0,s.normalizeLicense)(t.o.license))}</div>
|
|
126
126
|
<div>
|
|
@@ -263,7 +263,7 @@
|
|
|
263
263
|
<button data-ref="replace-btn" tabindex="0" type="button" class="jodit-ui-button">~Replace~</button>
|
|
264
264
|
</div>
|
|
265
265
|
</div>
|
|
266
|
-
</div>`}get currentIndex(){return this._currentIndex}set currentIndex(t){this._currentIndex=t,this.currentBox.innerText=t.toString()}set count(t){this.countBox.innerText=t.toString()}get query(){return this.queryInput.value}get replace(){return this.replaceInput.value}onEditorKeyDown(t){if(!this.isOpened)return;let{j:i}=this;if(i.getRealMode()===o.MODE_WYSIWYG)switch(t.key){case o.KEY_ESC:this.close();break;case o.KEY_F3:this.queryInput.value&&(i.e.fire(t.shiftKey?"searchPrevious":"searchNext"),t.preventDefault())}}open(t,i,n=!1){this.isOpened||(this.j.workplace.appendChild(this.container),this.isOpened=!0),this.calcSticky(this.j.e.fire("getStickyState.sticky")||!1),this.j.e.fire("hidePopup"),this.setMod("replace",n);let o=null!=t?t:(this.j.s.sel||"").toString();o&&(this.queryInput.value=o),i&&(this.replaceInput.value=i),this.setMod("empty-query",!o.length),this.j.e.fire(this,"needUpdateCounters"),o?this.queryInput.select():this.queryInput.focus()}close(){this.isOpened&&(this.j.s.restore(),s.Dom.safeRemove(this.container),this.isOpened=!1,this.j.e.fire(this,"afterClose"))}calcSticky(t){if(this.isOpened)if(this.setMod("sticky",t),t){let t=(0,a.position)(this.j.toolbarContainer);(0,a.css)(this.container,{top:t.top+t.height,left:t.left+t.width})}else(0,a.css)(this.container,{top:null,left:null})}constructor(t){super(t),this.selInfo=null,this._currentIndex=0,this.isOpened=!1;const{query:i,replace:n,cancel:r,next:s,prev:l,replaceBtn:c,current:d,count:u}=(0,a.refs)(this.container);this.queryInput=i,this.replaceInput=n,this.closeButton=r,this.replaceButton=c,this.currentBox=d,this.countBox=u,t.e.on(this.closeButton,"pointerdown",()=>(this.close(),!1)).on(this.queryInput,"input",()=>{this.currentIndex=0}).on(this.queryInput,"pointerdown",()=>{t.s.isFocused()&&(t.s.removeMarkers(),this.selInfo=t.s.save())}).on(this.replaceButton,"pointerdown",()=>(t.e.fire(this,"pressReplaceButton"),!1)).on(s,"pointerdown",()=>(t.e.fire("searchNext"),!1)).on(l,"pointerdown",()=>(t.e.fire("searchPrevious"),!1)).on(this.queryInput,"input",()=>{this.setMod("empty-query",!(0,a.trim)(this.queryInput.value).length)}).on(this.queryInput,"keydown",(()=>{let i=this.j.async.debounce(async i=>{i.key===o.KEY_ENTER?await t.e.fire("searchNext")&&this.close():t.e.fire(this,"needUpdateCounters")},this.j.defaultTimeout);return t=>{t.key===o.KEY_ENTER&&(t.preventDefault(),t.stopImmediatePropagation()),i(t)}})())}};c([(0,r.watch)([":keydown","queryInput:keydown"])],d.prototype,"onEditorKeyDown",null),c([r.autobind],d.prototype,"open",null),c([r.autobind],d.prototype,"close",null),c([(0,r.watch)(":toggleSticky")],d.prototype,"calcSticky",null),d=c([r.component],d)},55311:function(t,i,n){"use strict";n(6441).Config.prototype.tableAllowCellSelection=!0},28545:function(t,i,n){"use strict";var o=n(82758),r=n(65478),s=n(2748),a=n(580),l=n(21537),c=n(50911),d=n(76014);n(55311);var u=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a};let h="table_processor_observer",p="onMoveTableSelectCell";class f extends c.Plugin{get __tableModule(){return this.j.getInstance(d.Table,this.j.o)}afterInit(t){t.o.tableAllowCellSelection&&t.e.on("keydown.select-cells",t=>{t.key===o.KEY_TAB&&this.unselectCells()}).on("beforeCommand.select-cells",this.onExecCommand).on("afterCommand.select-cells",this.onAfterCommand).on(["clickEditor","mousedownTd","mousedownTh","touchstartTd","touchstartTh"].map(t=>t+".select-cells").join(" "),this.onStartSelection).on("clickTr clickTbody",()=>{var t;let i=this.__tableModule.getAllSelectedCells().length;if(i)return i>1&&(null==(t=this.j.s.sel)||t.removeAllRanges()),!1})}onStartSelection(t,i){var n;if(this.j.o.readonly)return;let o=s.Dom.closest(t,"table",this.j.editor);return((null==i?void 0:i.ctrlKey)||(null==i?void 0:i.metaKey))&&t!==this.j.editor&&o&&s.Dom.isCell(t)?(this.__tableModule.getAllSelectedCells().includes(t)?this.__tableModule.removeSelection(t):(t.firstChild||t.appendChild(this.j.createInside.element("br")),this.__tableModule.addSelection(t)),this.__selectedCell=t,null==(n=this.j.s.sel)||n.removeAllRanges(),this.__tableModule.getAllSelectedCells().length?this.j.e.fire("showPopup",o,()=>(0,l.position)(t,this.j),"cells"):this.j.e.fire("hidePopup","cells"),!1):(this.unselectCells(),t===this.j.editor)?void 0:t&&o?(t.firstChild||t.appendChild(this.j.createInside.element("br")),this.__isSelectionMode=!0,this.__selectedCell=t,this.__tableModule.addSelection(t),this.j.e.on(o,"mousemove.select-cells touchmove.select-cells",this.j.async.throttle(this.__onMove.bind(this,o),{label:p,timeout:this.j.defaultTimeout/2})).on(o,"mouseup.select-cells touchend.select-cells",this.__onStopSelection.bind(this,o)),!1):void 0}onOutsideClick(){this.__selectedCell=null,this.__onRemoveSelection()}onChange(){this.j.isLocked||this.__isSelectionMode||this.__onRemoveSelection()}__onMove(t,i){var n,o;let r;if(this.j.o.readonly&&!this.j.isLocked||this.j.isLockedNotBy(h))return;let a=(null!=(n=this.j.o.shadowRoot)?n:this.j.ed).elementFromPoint(i.clientX,i.clientY);if(!a)return;let l=s.Dom.closest(a,["td","th"],t);if(!l||!this.__selectedCell)return;l!==this.__selectedCell&&this.j.lock(h),this.unselectCells();let c=this.__tableModule.getSelectedBound(t,[l,this.__selectedCell]),d=this.__tableModule.formalMatrix(t);for(let t=c[0][0];t<=c[1][0];t+=1)for(let i=c[0][1];i<=c[1][1];i+=1)this.__tableModule.addSelection(d[t][i]);this.__tableModule.getAllSelectedCells().length>1&&(null==(o=this.j.s.sel)||o.removeAllRanges()),this.j.e.fire("hidePopup"),i.stopPropagation(),r=this.j.createInside.fromHTML('<div style="color:rgba(0,0,0,0.01);width:0;height:0"> </div>'),l.appendChild(r),this.j.async.setTimeout(()=>{var t;null==(t=r.parentNode)||t.removeChild(r)},this.j.defaultTimeout/5)}__onRemoveSelection(t){var i;if(!(null==(i=null==t?void 0:t.buffer)?void 0:i.actionTrigger)&&!this.__selectedCell&&this.__tableModule.getAllSelectedCells().length){this.j.unlock(),this.unselectCells(),this.j.e.fire("hidePopup","cells");return}this.__isSelectionMode=!1,this.__selectedCell=null}__onStopSelection(t,i){var n,o,r;if(!this.__selectedCell)return;this.__isSelectionMode=!1,this.j.unlock();let a=(null!=(n=this.j.o.shadowRoot)?n:this.j.ed).elementFromPoint(i.clientX,i.clientY);if(!a)return;let c=s.Dom.closest(a,["td","th"],t);if(!c)return;let d=s.Dom.closest(c,"table",t);if(d&&d!==t)return;let u=this.__tableModule.getSelectedBound(t,[c,this.__selectedCell]),h=this.__tableModule.formalMatrix(t),f=null==(o=h[u[1][0]])?void 0:o[u[1][1]],m=null==(r=h[u[0][0]])?void 0:r[u[0][1]];m&&f&&(this.j.e.fire("showPopup",t,()=>{let t=(0,l.position)(m,this.j),i=(0,l.position)(f,this.j);return{left:t.left,top:t.top,width:i.left-t.left+i.width,height:i.top-t.top+i.height}},"cells"),(0,l.$$)("table",this.j.editor).forEach(t=>{this.j.e.off(t,"mousemove.select-cells touchmove.select-cells mouseup.select-cells touchend.select-cells")}),this.j.async.clearTimeout(p))}unselectCells(t){let i=this.__tableModule,n=i.getAllSelectedCells();n.length&&n.forEach(n=>{t&&t===n||i.removeSelection(n)})}onExecCommand(t){if(/^(delete|backspace)(word|sentence)?button$/.test(t)&&this.__tableModule.getAllSelectedCells().length>1){let t=this.__tableModule.getAllSelectedCells();return t.forEach(t=>{s.Dom.detach(t),t.appendChild(this.j.createInside.element("br"))}),this.unselectCells(),this.j.s.setCursorIn(t[0]),this.j.synchronizeValues(),!1}if(/table(splitv|splitg|merge|empty|bin|binrow|bincolumn|addcolumn|addrow)/.test(t)){t=t.replace("table","");let i=this.__tableModule.getAllSelectedCells();if(i.length){let[n]=i;if(!n)return;let o=s.Dom.closest(n,"table",this.j.editor);if(!o)return;switch(t){case"splitv":this.__tableModule.splitVertical(o);break;case"splitg":this.__tableModule.splitHorizontal(o);break;case"merge":this.__tableModule.mergeSelected(o);break;case"empty":i.forEach(t=>s.Dom.detach(t));break;case"bin":s.Dom.safeRemove(o);break;case"binrow":new Set(i.map(t=>t.parentNode)).forEach(t=>{this.__tableModule.removeRow(o,t.rowIndex)});break;case"bincolumn":{let t=new Set,n=[];i.forEach(i=>{let[,r]=this.__tableModule.formalCoordinate(o,i);t.has(r)||(n.push(r),t.add(r))}),n.sort((t,i)=>i-t).forEach(t=>{this.__tableModule.removeColumn(o,t)})}break;case"addcolumnafter":case"addcolumnbefore":this.__tableModule.appendColumn(o,n,"addcolumnafter"===t);break;case"addrowafter":case"addrowbefore":this.__tableModule.appendRow(o,n.parentNode,"addrowafter"===t)}}return!1}}onAfterCommand(t){/^justify/.test(t)&&this.__tableModule.getAllSelectedCells().forEach(i=>(0,l.alignElement)(t,i))}beforeDestruct(t){this.__onRemoveSelection(),t.e.off(".select-cells")}constructor(){super(...arguments),this.__selectedCell=null,this.__isSelectionMode=!1}}f.requires=["select"],u([r.autobind],f.prototype,"onStartSelection",null),u([(0,r.watch)(":outsideClick")],f.prototype,"onOutsideClick",null),u([(0,r.watch)(":change")],f.prototype,"onChange",null),u([r.autobind],f.prototype,"__onRemoveSelection",null),u([r.autobind],f.prototype,"__onStopSelection",null),u([r.autobind],f.prototype,"onExecCommand",null),u([r.autobind],f.prototype,"onAfterCommand",null),a.pluginSystem.add("selectCells",f)},67215:function(t,i,n){"use strict";n(6441).Config.prototype.select={normalizeSelectionBeforeCutAndCopy:!1,normalizeTripleClick:!0}},9881:function(t,i,n){"use strict";var o=n(82758),r=n(65478),s=n(2748),a=n(580),l=n(87058),c=n(50911),d=n(67510);n(67215);var u=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a};class h extends c.Plugin{afterInit(t){this.proxyEventsList.forEach(i=>{t.e.on(i+".select",this.onStartSelection)})}beforeDestruct(t){this.proxyEventsList.forEach(i=>{t.e.on(i+".select",this.onStartSelection)})}onStartSelection(t){let{j:i}=this,n,o=t.target;for(;void 0===n&&o&&o!==i.editor;)n=i.e.fire((0,l.camelCase)(t.type+"_"+o.nodeName.toLowerCase()),o,t),o=o.parentElement;"click"===t.type&&void 0===n&&o===i.editor&&i.e.fire(t.type+"Editor",o,t)}onOutsideClick(t){let i=t.target;s.Dom.up(i,t=>t===this.j.editor)||d.UIElement.closestElement(i,d.Popup)||this.j.e.fire("outsideClick",t)}beforeCommandCut(){let{s:t}=this.j;if(!t.isCollapsed()){let i=t.current();i&&s.Dom.isOrContains(this.j.editor,i)&&this.onCopyNormalizeSelectionBound()}}beforeCommandSelectAll(){let{s:t}=this.j;return t.focus(),t.select(this.j.editor,!0),t.expandSelection(),!1}onClickRightOfNestedListItem(t){let{s:i}=this.j,n=i.range;if(!n.collapsed||0!==n.startOffset||!s.Dom.isText(n.startContainer))return;let o=n.startContainer,r=o.parentNode;if(!s.Dom.isTag(r,"li")||!(r.querySelector("ul")||r.querySelector("ol")))return;let a=this.j.ed.createRange();a.selectNodeContents(o);let l=a.getBoundingClientRect();t.clientX>l.right&&i.setCursorAfter(o)}onClickKeepPendingFormat(){var t,i;let{s:n}=this.j,r=n.range;if(!r.collapsed||!s.Dom.isText(r.startContainer))return;let a=r.startContainer;if(r.startOffset!==(null!=(i=null==(t=a.nodeValue)?void 0:t.length)?i:0))return;let l=a.nextSibling;if(!s.Dom.isElement(l)||!l.nodeName.match(o.IS_INLINE)||!s.Dom.isEmpty(l))return;let c=l;for(;s.Dom.isElement(c.firstElementChild)&&c.firstElementChild.nodeName.match(o.IS_INLINE);)c=c.firstElementChild;n.setCursorIn(c)}onTripleClickNormalizeSelection(t){if(3!==t.detail||!this.j.o.select.normalizeTripleClick)return;let{s:i}=this.j,{startContainer:n,startOffset:o}=i.range;0===o&&s.Dom.isText(n)&&i.select(s.Dom.closest(n,s.Dom.isBlock,this.j.editor)||n,!0)}onCopyNormalizeSelectionBound(t){let{s:i,editor:n,o}=this.j;!o.select.normalizeSelectionBeforeCutAndCopy||i.isCollapsed()||(!t||t.isTrusted&&s.Dom.isNode(t.target)&&s.Dom.isOrContains(n,t.target))&&this.jodit.s.expandSelection()}constructor(){super(...arguments),this.proxyEventsList=["click","mousedown","touchstart","mouseup","touchend"]}}u([r.autobind],h.prototype,"onStartSelection",null),u([(0,r.watch)("ow:click")],h.prototype,"onOutsideClick",null),u([(0,r.watch)([":beforeCommandCut"])],h.prototype,"beforeCommandCut",null),u([(0,r.watch)([":beforeCommandSelectall"])],h.prototype,"beforeCommandSelectAll",null),u([(0,r.watch)([":click"])],h.prototype,"onClickRightOfNestedListItem",null),u([(0,r.watch)([":click"])],h.prototype,"onClickKeepPendingFormat",null),u([(0,r.watch)([":click"])],h.prototype,"onTripleClickNormalizeSelection",null),u([(0,r.watch)([":copy",":cut"])],h.prototype,"onCopyNormalizeSelectionBound",null),a.pluginSystem.add("select",h)},80792:function(t,i,n){"use strict";var o=n(6441);o.Config.prototype.minWidth=200,o.Config.prototype.maxWidth="100%",o.Config.prototype.minHeight=200,o.Config.prototype.maxHeight="auto",o.Config.prototype.saveHeightInStorage=!1},45927:function(t,i,n){"use strict";var o=n(65478),r=n(580),s=n(84767),a=n(41180),l=n(20356);n(80792);var c=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a};class d extends l.Plugin{afterInit(t){t.e.on("setHeight.size",this.__setHeight).on("setWidth.size",this.__setWidth).on("afterInit.size changePlace.size",this.__initialize,{top:!0}).on(t.ow,"load.size",this.__resizeWorkspaces).on("afterInit.size resize.size afterUpdateToolbar.size scroll.size afterResize.size",this.__resizeWorkspaces).on("toggleFullSize.size toggleToolbar.size",this.__resizeWorkspaceImd),this.__immediateInitialize()}__initialize(){this.__immediateInitialize()}__immediateInitialize(){let{j:t}=this;if(t.o.inline)return;let{height:i}=t.o;if(t.o.saveHeightInStorage&&"auto"!==i){let n=t.storage.get("height");n&&(i=n)}(0,a.css)(t.editor,{minHeight:"100%"}),(0,a.css)(t.container,{minHeight:t.o.minHeight,maxHeight:t.o.maxHeight,minWidth:t.o.minWidth,maxWidth:t.o.maxWidth}),t.isFullSize||(this.__setHeight(i),this.__setWidth(t.o.width))}__setHeight(t){let{clientHeight:i,clientWidth:n}=this.j.container;if((0,s.isNumber)(t)){let{minHeight:i,maxHeight:n}=this.j.o;(0,s.isNumber)(i)&&i>t&&(t=i),(0,s.isNumber)(n)&&n<t&&(t=n)}(0,a.css)(this.j.container,"height",t),this.j.o.saveHeightInStorage&&this.j.storage.set("height",t),this.__resizeWorkspaceImd({clientHeight:i,clientWidth:n})}__setWidth(t){let{clientHeight:i,clientWidth:n}=this.j.container;if((0,s.isNumber)(t)){let{minWidth:i,maxWidth:n}=this.j.o;(0,s.isNumber)(i)&&i>t&&(t=i),(0,s.isNumber)(n)&&t>n&&(t=n)}(0,a.css)(this.j.container,"width",t),this.__resizeWorkspaceImd({clientHeight:i,clientWidth:n})}__getNotWorkHeight(){var t;let i=this.j.toolbarContainer;return(i&&this.j.container.contains(i)?i.offsetHeight:0)+((null==(t=this.j.statusbar)?void 0:t.getHeight())||0)+2}__resizeWorkspaceImd({clientHeight:t,clientWidth:i}=this.j.container){if(!this.j||this.j.isDestructed||!this.j.o||this.j.o.inline||!this.j.container||!this.j.container.parentNode)return;let n=((0,a.css)(this.j.container,"minHeight")||0)-this.__getNotWorkHeight();if((0,s.isNumber)(n)&&n>0&&([this.j.workplace,this.j.currentPlace.slots.center,this.j.iframe,this.j.editor].map(t=>{t&&(0,a.css)(t,"minHeight",n)}),this.j.e.fire("setMinHeight",n)),(0,s.isNumber)(this.j.o.maxHeight)){let t=this.j.o.maxHeight-this.__getNotWorkHeight();[this.j.workplace,this.j.currentPlace.slots.center,this.j.iframe,this.j.editor].map(i=>{i&&(0,a.css)(i,"maxHeight",t)}),this.j.e.fire("setMaxHeight",t)}if(this.j.container){let t="auto"!==this.j.o.height||this.j.isFullSize?this.j.container.offsetHeight-this.__getNotWorkHeight():"auto";(0,a.css)(this.j.workplace,"height",t),this.j.container.style.setProperty("--jd-jodit-workplace-height",(0,s.isNumber)(t)?t+"px":t)}let{clientHeight:o,clientWidth:r}=this.j.container;(t!==o||i!==r)&&this.j.e.fire(this.j,"resize")}beforeDestruct(t){t.e.off(t.ow,"load.size",this.__resizeWorkspaces).off(".size")}constructor(){super(...arguments),this.__resizeWorkspaces=this.j.async.debounce(this.__resizeWorkspaceImd,this.j.defaultTimeout,!0)}}c([(0,o.throttle)()],d.prototype,"__initialize",null),c([o.autobind],d.prototype,"__setHeight",null),c([o.autobind],d.prototype,"__setWidth",null),c([o.autobind],d.prototype,"__resizeWorkspaceImd",null),r.pluginSystem.add("size",d)},36204:function(t,i,n){"use strict";var o=n(82758),r=n(12153),s=n(6441),a=n(35599);s.Config.prototype.beautifyHTML=!o.IS_IE,s.Config.prototype.sourceEditor="ace",s.Config.prototype.sourceEditorNativeOptions={showGutter:!0,theme:"ace/theme/idle_fingers",mode:"ace/mode/html",wrap:!0,highlightActiveLine:!0},s.Config.prototype.sourceEditorCDNUrlsJS=["https://cdnjs.cloudflare.com/ajax/libs/ace/1.43.3/ace.js"],s.Config.prototype.beautifyHTMLCDNUrlsJS=["https://cdnjs.cloudflare.com/ajax/libs/js-beautify/1.14.4/beautify.min.js","https://cdnjs.cloudflare.com/ajax/libs/js-beautify/1.14.4/beautify-html.min.js"],r.Icon.set("source",a.default),s.Config.prototype.controls.source={mode:o.MODE_SPLIT,exec(t){t.toggleMode()},isActive:t=>t.getRealMode()===o.MODE_SOURCE,tooltip:"Change mode"}},60031:function(t,i,n){"use strict";n.d(i,{AceEditor:function(){return a}});var o=n(82758),r=n(21537),s=n(23370);class a extends s.SourceEditor{aceExists(){return void 0!==this.j.ow.ace}getLastColumnIndex(t){return this.instance.session.getLine(t).length}getLastColumnIndices(){let t=this.instance.session.getLength(),i=[],n=0;for(let o=0;t>o;o++)n+=this.getLastColumnIndex(o),o>0&&(n+=1),i[o]=n;return i}getRowColumnIndices(t){let i=this.getLastColumnIndices();if(t<=i[0])return{row:0,column:t};let n=1;for(let o=1;o<i.length;o++)t>i[o]&&(n=o+1);let o=t-i[n-1]-1;return{row:n,column:o}}setSelectionRangeIndices(t,i){let n=this.getRowColumnIndices(t),o=this.getRowColumnIndices(i);this.instance.getSelection().setSelectionRange({start:n,end:o})}getIndexByRowColumn(t,i){return this.getLastColumnIndices()[t]-this.getLastColumnIndex(t)+i}init(t){let i=()=>{if(void 0!==this.instance||!this.aceExists())return;let i=this.j.c.div("jodit-source__mirror-fake");this.container.appendChild(i);let n=t.ow.ace;this.instance=n.edit(i),"rtl"===t.o.direction&&(this.instance.setOption("rtlText",!0),this.instance.setOption("rtl",!0)),this.instance.setOptions(t.o.sourceEditorNativeOptions),this.instance.setTheme(t.o.sourceEditorNativeOptions.theme),this.instance.renderer.setShowGutter(t.o.sourceEditorNativeOptions.showGutter),this.instance.getSession().setMode(t.o.sourceEditorNativeOptions.mode),this.instance.setHighlightActiveLine(t.o.sourceEditorNativeOptions.highlightActiveLine),this.instance.getSession().setUseWrapMode(!0),this.instance.setOption("indentedSoftWrap",!1),this.instance.setOption("wrap",t.o.sourceEditorNativeOptions.wrap),this.instance.getSession().setUseWorker(!1),this.instance.$blockScrolling=1/0,this.instance.on("change",this.toWYSIWYG),this.instance.on("focus",this.proxyOnFocus),this.instance.on("mousedown",this.proxyOnMouseDown),this.instance.on("blur",this.proxyOnBlur),t.getRealMode()!==o.MODE_WYSIWYG&&this.setValue(this.getValue());let r=this.j.async.throttle(()=>{if(t.isInDestruct||t.getMode()===o.MODE_WYSIWYG)return;let i=this.instance.isFocused();"auto"!==t.o.height?this.instance.setOption("maxLines",t.workplace.offsetHeight/this.instance.renderer.lineHeight):this.instance.setOption("maxLines",1/0),this.instance.resize(),i&&this.focus()},2*this.j.defaultTimeout);t.e.on(t,"resize",r).on("afterResize afterSetMode",r),r(),this.onReady()},n=()=>{t.isInDestruct||t.getRealMode()!==o.MODE_SOURCE&&t.getMode()!==o.MODE_SPLIT||(this.fromWYSIWYG(),i())};t.e.on("afterSetMode",n),n(),this.aceExists()||(0,r.loadNext)(t,t.o.sourceEditorCDNUrlsJS).then(n).catch(()=>null)}destruct(){var t,i;this.instance.off("change",this.toWYSIWYG),this.instance.off("focus",this.proxyOnFocus),this.instance.off("mousedown",this.proxyOnMouseDown),this.instance.destroy(),null==(i=null==(t=this.j)?void 0:t.events)||i.off("aceInited.source")}setValue(t){if(!this.j.o.editHTMLDocumentMode&&this.j.o.beautifyHTML){let i=this.j.e.fire("beautifyHTML",t);(0,r.isString)(i)&&(t=i)}this.instance.setValue(t),this.instance.clearSelection()}getValue(){return this.instance.getValue()}setReadOnly(t){this.instance.setReadOnly(t)}get isFocused(){return this.instance.isFocused()}focus(){this.instance.container.focus(),this.instance.focus()}blur(){this.instance.blur()}getSelectionStart(){let t=this.instance.selection.getRange();return this.getIndexByRowColumn(t.start.row,t.start.column)}getSelectionEnd(){let t=this.instance.selection.getRange();return this.getIndexByRowColumn(t.end.row,t.end.column)}selectAll(){this.instance.selection.selectAll()}insertRaw(t){let i=this.instance.selection.getCursor(),n=this.instance.session.insert(i,t);this.instance.selection.setRange({start:i,end:n},!1)}setSelectionRange(t,i){this.setSelectionRangeIndices(t,i)}setPlaceHolder(t){}replaceUndoManager(){let{history:t}=this.jodit;this.instance.commands.addCommand({name:"Undo",bindKey:{win:"Ctrl-Z",mac:"Command-Z"},exec(){t.undo()}}),this.instance.commands.addCommand({name:"Redo",bindKey:{win:"Ctrl-Shift-Z",mac:"Command-Shift-Z"},exec(){t.redo()}})}constructor(){super(...arguments),this.className="jodit_ace_editor",this.proxyOnBlur=t=>{this.j.e.fire("blur",t)},this.proxyOnFocus=t=>{this.j.e.fire("focus",t)},this.proxyOnMouseDown=t=>{this.j.e.fire("mousedown",t)}}}},7483:function(t,i,n){"use strict";n.d(i,{TextAreaEditor:function(){return l}});var o=n(2748),r=n(29960),s=n(41180),a=n(23370);class l extends a.SourceEditor{init(t){this.instance=t.c.element("textarea",{class:"jodit-source__mirror",dir:"rtl"===t.o.direction?"rtl":void 0}),this.container.appendChild(this.instance),t.e.on(this.instance,"mousedown keydown touchstart input",t.async.debounce(this.toWYSIWYG,t.defaultTimeout)).on("setMinHeight.source",t=>{(0,s.css)(this.instance,"minHeight",t)}).on(this.instance,"change keydown mousedown touchstart input",this.autosize).on("afterSetMode.source",this.autosize).on(this.instance,"mousedown focus blur",i=>{t.e.fire(i.type,i)}),this.autosize(),this.onReady()}destruct(){o.Dom.safeRemove(this.instance)}getValue(){return this.instance.value}setValue(t){this.instance.value=t}insertRaw(t){let i=this.getValue();if(this.getSelectionStart()>=0){let n=this.getSelectionStart(),o=this.getSelectionEnd();this.setValue(i.substring(0,n)+t+i.substring(o,i.length))}else this.setValue(i+t)}getSelectionStart(){return this.instance.selectionStart}getSelectionEnd(){return this.instance.selectionEnd}setSelectionRange(t,i=t){this.instance.setSelectionRange(t,i)}get isFocused(){return this.instance===this.j.od.activeElement}focus(){this.instance.focus()}blur(){this.instance.blur()}setPlaceHolder(t){(0,r.attr)(this.instance,"placeholder",t)}setReadOnly(t){(0,r.attr)(this.instance,"readonly",t?"true":null)}selectAll(){this.instance.select()}replaceUndoManager(){let{history:t}=this.jodit;this.j.e.on(this.instance,"keydown",i=>{if((i.ctrlKey||i.metaKey)&&"z"===i.key)return i.shiftKey?t.redo():t.undo(),this.setSelectionRange(this.getValue().length),!1})}constructor(){super(...arguments),this.autosize=this.j.async.debounce(()=>{this.instance.style.height="auto",this.instance.style.height=this.instance.scrollHeight+"px"},this.j.defaultTimeout,!0)}}},52968:function(t,i,n){"use strict";n.d(i,{AceEditor:function(){return o.AceEditor},TextAreaEditor:function(){return r.TextAreaEditor}});var o=n(60031),r=n(7483)},70022:function(t,i,n){"use strict";n.d(i,{createSourceEditor:function(){return s}});var o=n(21537),r=n(52968);function s(t,i,n,s,a){let l;if((0,o.isFunction)(t))l=t(i);else switch(t){case"ace":if(!i.o.shadowRoot){l=new r.AceEditor(i,n,s,a);break}default:l=new r.TextAreaEditor(i,n,s,a)}return l.init(i),l.onReadyAlways(()=>{l.setReadOnly(i.o.readonly)}),l}},23370:function(t,i,n){"use strict";n.d(i,{SourceEditor:function(){return o}});class o{get j(){return this.jodit}onReady(){this.replaceUndoManager(),this.isReady=!0,this.j.e.fire(this,"ready")}onReadyAlways(t){var i;this.isReady?t():null==(i=this.j.events)||i.on(this,"ready",t)}constructor(t,i,n,o){this.jodit=t,this.container=i,this.toWYSIWYG=n,this.fromWYSIWYG=o,this.className="",this.isReady=!1}}},52951:function(t,i,n){"use strict";var o=n(82758),r=n(65478),s=n(2748),a=n(580),l=n(21537),c=n(50911);n(36204);var d=n(70022),u=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a};class h extends c.Plugin{onInsertHTML(t){var i;if(!this.j.o.readonly&&!this.j.isEditorMode())return null==(i=this.sourceEditor)||i.insertRaw(t),this.toWYSIWYG(),!1}fromWYSIWYG(t=!1){if(!this.__lock||!0===t){this.__lock=!0;let t=this.j.getEditorValue(!1,o.SOURCE_CONSUMER);t!==this.getMirrorValue()&&this.setMirrorValue(t),this.__lock=!1}}toWYSIWYG(){if(this.__lock)return;let t=this.getMirrorValue();t!==this.__oldMirrorValue&&(this.__lock=!0,this.j.value=t,this.__lock=!1,this.__oldMirrorValue=t)}getNormalPosition(t,i){for(i=i.replace(/<(script|style|iframe)[^>]*>[^]*?<\/\1>/im,t=>{let i="";for(let n=0;n<t.length;n+=1)i+=o.INVISIBLE_SPACE;return i});t>0&&i[t]===o.INVISIBLE_SPACE;)t--;let n=t;for(;n>0;){if("<"===i[--n]&&void 0!==i[n+1]&&i[n+1].match(/[\w/]+/i))return n;if(">"===i[n])break}return t}clnInv(t){return t.replace(o.INVISIBLE_SPACE_REG_EXP(),"")}onSelectAll(t){var i;if("selectall"===t.toLowerCase()&&this.j.getRealMode()===o.MODE_SOURCE)return null==(i=this.sourceEditor)||i.selectAll(),!1}getMirrorValue(){var t;return(null==(t=this.sourceEditor)?void 0:t.getValue())||""}setMirrorValue(t){var i;null==(i=this.sourceEditor)||i.setValue(t)}setFocusToMirror(){var t;let i=this.j.od.activeElement;(!i||i===this.j.od.body||this.j.container.contains(i))&&(null==(t=this.sourceEditor)||t.focus())}saveSelection(){if(this.j.getRealMode()===o.MODE_WYSIWYG)this.j.s.save(),this.j.synchronizeValues(),this.fromWYSIWYG(!0);else{if(this.j.o.editHTMLDocumentMode)return;let t=this.getMirrorValue();if(this.getSelectionStart()===this.getSelectionEnd()){let i=this.j.s.marker(!0),n=this.getNormalPosition(this.getSelectionStart(),this.getMirrorValue());this.setMirrorValue(t.substring(0,n)+this.clnInv(i.outerHTML)+t.substring(n))}else{let i=this.j.s.marker(!0),n=this.j.s.marker(!1),o=this.getNormalPosition(this.getSelectionStart(),t),r=this.getNormalPosition(this.getSelectionEnd(),t);this.setMirrorValue(t.slice(0,o)+this.clnInv(i.outerHTML)+t.slice(o,r)+this.clnInv(n.outerHTML)+t.slice(r))}this.toWYSIWYG()}}removeSelection(){if(this.j.getRealMode()===o.MODE_WYSIWYG){this.__lock=!0,this.j.s.restore(),this.__lock=!1;return}let t=this.getMirrorValue(),i=0,n=0;try{if(t=t.replace(/<span[^>]+data-jodit-selection_marker=(["'])start\1[^>]*>[<>]*?<\/span>/gim,this.tempMarkerStart).replace(/<span[^>]+data-jodit-selection_marker=(["'])end\1[^>]*>[<>]*?<\/span>/gim,this.tempMarkerEnd),!this.j.o.editHTMLDocumentMode&&this.j.o.beautifyHTML){let i=this.j.e.fire("beautifyHTML",t);(0,l.isString)(i)&&(t=i)}if(n=i=t.indexOf(this.tempMarkerStart),t=t.replace(this.tempMarkerStartReg,""),-1!==i){let i=t.indexOf(this.tempMarkerEnd);-1!==i&&(n=i)}t=t.replace(this.tempMarkerEndReg,"")}finally{t=t.replace(this.tempMarkerEndReg,"").replace(this.tempMarkerStartReg,"")}this.setMirrorValue(t),this.setMirrorSelectionRange(i,n),this.toWYSIWYG(),this.setFocusToMirror()}setMirrorSelectionRange(t,i){var n;null==(n=this.sourceEditor)||n.setSelectionRange(t,i)}onReadonlyReact(){var t;null==(t=this.sourceEditor)||t.setReadOnly(this.j.o.readonly)}afterInit(t){if(this.mirrorContainer=t.c.div("jodit-source"),t.workplace.appendChild(this.mirrorContainer),t.e.on("afterAddPlace changePlace afterInit",()=>{t.workplace.appendChild(this.mirrorContainer)}),this.sourceEditor=(0,d.createSourceEditor)("area",t,this.mirrorContainer,this.toWYSIWYG,this.fromWYSIWYG),t.e.on(t.ow,"keydown",t=>{var i;t.key===o.KEY_ESC&&(null==(i=this.sourceEditor)?void 0:i.isFocused)&&this.sourceEditor.blur()}),this.onReadonlyReact(),t.e.on("placeholder.source",t=>{var i;null==(i=this.sourceEditor)||i.setPlaceHolder(t)}).on("change.source",this.syncValueFromWYSIWYG).on("beautifyHTML",t=>t),t.o.beautifyHTML){let i=()=>{var i;if(t.isInDestruct)return!1;let n=t.ow.html_beautify;return!!n&&!t.isInDestruct&&(null==(i=t.events)||i.off("beautifyHTML").on("beautifyHTML",t=>n(t)),!0)};i()||(0,l.loadNext)(t,t.o.beautifyHTMLCDNUrlsJS).then(i,()=>null)}this.syncValueFromWYSIWYG(!0),this.initSourceEditor(t)}syncValueFromWYSIWYG(t=!1){let i=this.j;(i.getMode()===o.MODE_SPLIT||i.getMode()===o.MODE_SOURCE)&&this.fromWYSIWYG(t)}initSourceEditor(t){var i;if("area"!==t.o.sourceEditor){let i=(0,d.createSourceEditor)(t.o.sourceEditor,t,this.mirrorContainer,this.toWYSIWYG,this.fromWYSIWYG);i.onReadyAlways(()=>{var n,o;null==(n=this.sourceEditor)||n.destruct(),this.sourceEditor=i,this.syncValueFromWYSIWYG(!0),null==(o=t.events)||o.fire("sourceEditorReady",t)})}else null==(i=this.sourceEditor)||i.onReadyAlways(()=>{var i;this.syncValueFromWYSIWYG(!0),null==(i=t.events)||i.fire("sourceEditorReady",t)})}beforeDestruct(){this.sourceEditor&&(this.sourceEditor.destruct(),delete this.sourceEditor),s.Dom.safeRemove(this.mirrorContainer)}constructor(){super(...arguments),this.buttons=[{name:"source",group:"source"}],this.__lock=!1,this.__oldMirrorValue="",this.tempMarkerStart="{start-jodit-selection}",this.tempMarkerStartReg=/{start-jodit-selection}/g,this.tempMarkerEnd="{end-jodit-selection}",this.tempMarkerEndReg=/{end-jodit-selection}/g,this.getSelectionStart=()=>{var t,i;return null!=(i=null==(t=this.sourceEditor)?void 0:t.getSelectionStart())?i:0},this.getSelectionEnd=()=>{var t,i;return null!=(i=null==(t=this.sourceEditor)?void 0:t.getSelectionEnd())?i:0}}}u([(0,r.watch)(":insertHTML.source")],h.prototype,"onInsertHTML",null),u([r.autobind],h.prototype,"fromWYSIWYG",null),u([r.autobind],h.prototype,"toWYSIWYG",null),u([r.autobind],h.prototype,"getNormalPosition",null),u([(0,r.watch)(":beforeCommand.source")],h.prototype,"onSelectAll",null),u([(0,r.watch)(":beforeSetMode.source")],h.prototype,"saveSelection",null),u([(0,r.watch)(":afterSetMode.source")],h.prototype,"removeSelection",null),u([r.autobind],h.prototype,"setMirrorSelectionRange",null),u([(0,r.watch)(":readonly.source")],h.prototype,"onReadonlyReact",null),u([r.autobind],h.prototype,"syncValueFromWYSIWYG",null),a.pluginSystem.add("source",h)},35599:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M553 1399l-50 50q-10 10-23 10t-23-10l-466-466q-10-10-10-23t10-23l466-466q10-10 23-10t23 10l50 50q10 10 10 23t-10 23l-393 393 393 393q10 10 10 23t-10 23zm591-1067l-373 1291q-4 13-15.5 19.5t-23.5 2.5l-62-17q-13-4-19.5-15.5t-2.5-24.5l373-1291q4-13 15.5-19.5t23.5-2.5l62 17q13 4 19.5 15.5t2.5 24.5zm657 651l-466 466q-10 10-23 10t-23-10l-50-50q-10-10-10-23t10-23l393-393-393-393q-10-10-10-23t10-23l50-50q10-10 23-10t23 10l466 466q10 10 10 23t-10 23z"/> </svg> '},46614:function(t,i,n){"use strict";var o=n(87612),r=n(70799),s=n(29960),a=n(86583),l=n(12153),c=n(6441),d=n(26532),u=n(93602),h=n(75259);c.Config.prototype.speechRecognize={api:void 0!==d.SpeechRecognition?d.SpeechRecognition:null,sound:!0,continuous:!1,interimResults:!0,commands:{"newline|enter":"enter","delete|remove word|delete word":"backspaceWordButton",comma:"inserthtml::,",underline:"inserthtml::_",hyphen:"inserthtml::-",space:"inserthtml:: ",question:"inserthtml::?",dot:"inserthtml::.","quote|quotes|open quote":"inserthtml::'","header|header h1":"formatblock::h1","select all":"selectall"}},l.Icon.set("speech-recognize",h.default),c.Config.prototype.controls.speechRecognize={isVisible:t=>!!t.o.speechRecognize.api,isActive(t,i){let n=(0,a.dataBind)(t,"speech");return!!(null==n?void 0:n.isEnabled)},isDisabled:t=>!t.o.speechRecognize.api,exec(t,i,{button:n,control:l}){var c;let{api:d,lang:h,continuous:p,interimResults:f,sound:m}=t.o.speechRecognize;if(!d)return void t.alert("Speech recognize API unsupported in your browser");let g=(0,a.dataBind)(t,"speech");if(!g){let i=new d;(g=new u.RecognizeManager(t.async,i)).lang=(0,r.isString)(h)?h:null!=(c=(0,s.attr)(t.od.documentElement,"lang"))?c:void 0,g.continuous=p,g.interimResults=f,g.sound=m,(0,a.dataBind)(t,"speech",g),g.on("pulse",t=>{n.setMod("pulse",t)}),g.on("result",i=>t.e.fire("speechRecognizeResult",i)),g.on("progress",i=>t.e.fire("speechRecognizeProgressResult",i)),g.on("error",i=>t.message.error(i)),t.hookStatus("beforeDestruct",()=>{(0,a.dataBind)(t,"speech",null),g.destruct()})}if(l.args){let t=l.args[0];if((0,o.isBoolean)(g[t])){g[t]=!g[t],g.isEnabled&&g.restart();return}}g.toggle(),g.isEnabled&&n.setMod("pulse",!0),n.state.activated=g.isEnabled},name:"speechRecognize",command:"toggleSpeechRecognize",tooltip:"Speech Recognize",list:{sound:"Sound",interimResults:"Interim Results"},childTemplate(t,i,n){var o;let r=(0,a.dataBind)(t,"speech"),s=null!=(o=null==r?void 0:r[i])?o:t.o.speechRecognize[i];return`<span class='jodit-speech-recognize__list-item'><input ${s?"checked":""} class='jodit-checkbox' type='checkbox'> ${n}</span>`},mods:{stroke:!1}}},85567:function(t,i,n){"use strict";n.d(i,{PII:function(){return o},WARN:function(){return r}});let o=440,r=940},26532:function(t,i,n){"use strict";n.d(i,{SpeechRecognition:function(){return r}});var o=n(82758);let r=o.globalWindow?o.globalWindow.SpeechRecognition||o.globalWindow.webkitSpeechRecognition:void 0},54076:function(t,i,n){"use strict";function o(t,i){let[n,o]=i.split("::");"open"===n.toLowerCase()&&o&&/^(javascript:|data:|vbscript:)/i.test(o.trim())||t.execCommand(n,null,o)}n.d(i,{execSpellCommand:function(){return o}})},93602:function(t,i,n){"use strict";n.d(i,{RecognizeManager:function(){return c}});var o=n(65478),r=n(72757),s=n(37643),a=n(85567),l=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a};class c extends r.Eventify{set lang(t){this._lang=t,this._api.lang=t}get lang(){return this._lang}set continuous(t){this._continuous=t,this._api.continuous=t}get continuous(){return this._continuous}set interimResults(t){this._interimResults=t,this._api.interimResults=t}get interimResults(){return this._interimResults}destruct(){this.stop(),(0,s.closeSound)(this),c._instances.delete(this),super.destruct()}get isEnabled(){return this._isEnabled}start(){if(!this._isEnabled){this._isEnabled=!0,c._instances.forEach(t=>{t!==this&&t.stop()});try{this._api.start()}catch(t){this._onError(t),this.stop();return}this.__on("speechstart",this._onSpeechStart).__on("error",this._onError).__on("result",this._onProgress).__on("end",this._onResults)}}stop(){this._isEnabled&&(this._api.abort(),this._api.stop(),this.__off("speechstart",this._onSpeechStart).__off("error",this._onError).__off("result",this._onProgress).__off("end",this._onResults),this.async.clearTimeout(this._restartTimeout),this._isEnabled=!1,this.emit("pulse",!1))}toggle(){this._isEnabled?this.stop():this.start()}restart(){this.stop(),this.start()}__on(t,i){return this._api.addEventListener(t,i),this}__off(t,i){return this._api.removeEventListener(t,i),this}_onResults(t){this.emit("pulse",!1),this.emit("result",this.__interimResults),this.__interimResults="",this._makeSound(a.PII),this.restart()}_onProgress(t){if(this._isEnabled&&(this.__interimResults="",t.results)){for(let i=0;i<t.results.length;i++){let n=t.results.item(i);if(n.length){let{transcript:t}=n.item(0);this.__interimResults+=t}}this.__interimResults&&this.emit("progress",this.__interimResults)}}_onError(t){"voice-unavailable"===t.error&&this.emit("error","Voice unavailable"),"not-allowed"===t.error&&this.emit("error","Not allowed"),("language-unavailable"===t.error||"language-not-supported"===t.error)&&this.emit("error","Language unavailable"),this._makeSound(a.WARN),this.emit("pulse",!1),this.stop()}_makeSound(t){this.sound&&(0,s.sound)(this,{frequency:t})}constructor(t,i){super(),this.async=t,this._continuous=!1,this._interimResults=!1,this.sound=!0,this._isEnabled=!1,this._restartTimeout=0,this._onSpeechStart=t=>{this._isEnabled&&(this.async.clearTimeout(this._restartTimeout),this._restartTimeout=this.async.setTimeout(()=>{this.restart(),this.emit("pulse",!1),this._makeSound(a.WARN)},5e3),this.emit("pulse",!0))},this.__interimResults="",this._api=i,c._instances.add(this)}}c._instances=new Set,l([o.autobind],c.prototype,"_onResults",null),l([o.autobind],c.prototype,"_onProgress",null),l([o.autobind],c.prototype,"_onError",null)},37643:function(t,i,n){"use strict";n.d(i,{closeSound:function(){return l},sound:function(){return a}});var o=n(82758),r=n(85567);let s=new WeakMap;function a(t,{sec:i=.1,frequency:n=r.PII,gain:l=.1,type:c="sine"}={}){let d=function(t){if(!o.globalWindow)return null;let i=s.get(t);if(i&&"closed"!==i.state)return i;let n=o.globalWindow.AudioContext||o.globalWindow.webkitAudioContext;if(!n)return null;let r=new n;return s.set(t,r),r}(t);if(!d)return;let u=d.createGain(),h=d.createOscillator();h.type=c,h.frequency.value=n,u.gain.value=l,h.connect(u),u.connect(d.destination),h.start(),h.stop(d.currentTime+i)}function l(t){let i=s.get(t);i&&(s.delete(t),"closed"!==i.state&&i.close())}},71705:function(t,i,n){"use strict";n.r(i),i.default={newline:"الخط الجديد",delete:"حذف",space:"الفضاء","Speech Recognize":"التعرف على الكلام",Sound:"الصوت","Interim Results":"النتائج المؤقتة"}},89930:function(t,i,n){"use strict";n.r(i),i.default={newline:"řádek",delete:"odstranit",space:"prostora","Speech Recognize":"Rozpoznání Řeči",Sound:"Zvuk","Interim Results":"Průběžné Výsledky"}},34945:function(t,i,n){"use strict";n.r(i),i.default={newline:"Zeilenumbruch",delete:"löschen",space:"Raum","Speech Recognize":"Sprache Erkennen",Sound:"Sound","Interim Results":"Zwischenergebnis"}},63134:function(t,i,n){"use strict";n.r(i),i.default={newline:"nueva línea",delete:"eliminar",space:"espacio","Speech Recognize":"Reconocimiento de Voz",Sound:"Sonido","Interim Results":"Resultados Provisionales"}},66835:function(t,i,n){"use strict";n.r(i),i.default={newline:"خط جدید",delete:"حذف",space:"فضا","Speech Recognize":"گفتار را تشخیص دهید",Sound:"صدا","Interim Results":"نتایج موقت"}},1115:function(t,i,n){"use strict";n.r(i),i.default={"Speech Recognize":"Puheentunnistus",newline:"uusi rivi",delete:"poistaa",space:"tilaa",Sound:"Ääni","Interim Results":"Välitulokset"}},59302:function(t,i,n){"use strict";n.r(i),i.default={newline:"nouvelle ligne",delete:"supprimer",space:"espace","Speech Recognize":"Reconnaissance Vocale",Sound:"Son","Interim Results":"Résultats Intermédiaires"}},94141:function(t,i,n){"use strict";n.r(i),i.default={newline:"חדשות",delete:"מחק",space:"שטח","Speech Recognize":"דיבור מזהה",Sound:"קול","Interim Results":"תוצאות ביניים"}},24877:function(t,i,n){"use strict";n.r(i),i.default={newline:"újsor",delete:"törlés",space:"tér","Speech Recognize":"A Beszéd Felismeri",Sound:"Hang","Interim Results":"Időközi Eredmények"}},80651:function(t,i,n){"use strict";n.r(i),i.default={newline:"newline",delete:"Hapus",space:"ruang","Speech Recognize":"Pidato Mengenali",Sound:"Suara","Interim Results":"Hasil Sementara"}},90492:function(t,i,n){"use strict";n.r(i),n.d(i,{ar:function(){return o},cs_cz:function(){return r},de:function(){return s},es:function(){return a},fa:function(){return l},fi:function(){return c},fr:function(){return d},he:function(){return u},hu:function(){return h},id:function(){return p},it:function(){return f},ja:function(){return m},ko:function(){return g},mn:function(){return b},nl:function(){return y},no:function(){return w},pl:function(){return _},pt_br:function(){return C},ru:function(){return k},sk:function(){return S},tr:function(){return x},ua:function(){return I},zh_cn:function(){return E},zh_tw:function(){return T}});var o=n(71705),r=n(89930),s=n(34945),a=n(63134),l=n(66835),c=n(1115),d=n(59302),u=n(94141),h=n(24877),p=n(80651),f=n(62395),m=n(16407),g=n(37272),b=n(22113),y=n(22432),w=n(17081),_=n(30798),C=n(8661),k=n(19147),S=n(76220),x=n(93620),I=n(40372),E=n(69874),T=n(88774)},62395:function(t,i,n){"use strict";n.r(i),i.default={newline:"nuova riga",delete:"eliminare",space:"spazio","Speech Recognize":"Discorso Riconoscere",Sound:"Suono","Interim Results":"Risultati intermedi"}},16407:function(t,i,n){"use strict";n.r(i),i.default={newline:"改行",delete:"削除",space:"スペース","Speech Recognize":"音声認識",Sound:"音","Interim Results":"中間結果"}},37272:function(t,i,n){"use strict";n.r(i),i.default={newline:"줄 바꿈",delete:"삭제",space:"공간","Speech Recognize":"음성 인식",Sound:"소리","Interim Results":"중간 결과"}},22113:function(t,i,n){"use strict";n.r(i),i.default={newline:"Шинэ мөр",delete:"Устгах",space:"Зай","Speech Recognize":"Дуу хоолой таних",Sound:"Дуу","Interim Results":"Түр зуурын үр дүн"}},22432:function(t,i,n){"use strict";n.r(i),i.default={newline:"regel",delete:"verwijderen",space:"ruimte","Speech Recognize":"Spraak Herkennen",Sound:"Geluid","Interim Results":"Tussentijdse Resultaten"}},17081:function(t,i,n){"use strict";n.r(i),i.default={newline:"nylinje",delete:"slette",space:"rom","Speech Recognize":"Talegjenkjenning",Sound:"Lyd","Interim Results":"Midlertidige resultater"}},30798:function(t,i,n){"use strict";n.r(i),i.default={newline:"newline",delete:"usunąć",space:"przestrzeń","Speech Recognize":"Rozpoznawanie Mowy",Sound:"Dźwięk","Interim Results":"Wyniki Okresowe"}},8661:function(t,i,n){"use strict";n.r(i),i.default={newline:"linha",delete:"excluir",space:"espaco","Speech Recognize":"Discurso Reconhecer",Sound:"Som","Interim Results":"Resultados Provisórios"}},19147:function(t,i,n){"use strict";n.r(i),i.default={newline:"новая строка|перенос|энтер",delete:"удалить",space:"пробел","Speech Recognize":"Распознавание речи",Sound:"Звук","Interim Results":"Промежуточные результаты"}},76220:function(t,i,n){"use strict";n.r(i),i.default={newline:"nový riadok",delete:"vymazať",space:"medzera","Speech Recognize":"Rozpoznávanie reči",Sound:"Zvuk","Interim Results":"Predbežné výsledky"}},93620:function(t,i,n){"use strict";n.r(i),i.default={newline:"yeni satır",delete:"silmek",space:"uzay","Speech Recognize":"Konuşma Tanıma",Sound:"Ses","Interim Results":"Ara Sonuçlar"}},40372:function(t,i,n){"use strict";n.r(i),i.default={newline:"новая строка|перенос|ентер",delete:"видалити",space:"пробел","Speech Recognize":"Распознавание речи",Sound:"Звук","Interim Results":"Проміжні результати"}},69874:function(t,i,n){"use strict";n.r(i),i.default={newline:"新行",delete:"删除",space:"空间","Speech Recognize":"言语识别",Sound:"声音","Interim Results":"中期业绩"}},88774:function(t,i,n){"use strict";n.r(i),i.default={newline:"換行",delete:"刪除",space:"空白","Speech Recognize":"語音辨識",Sound:"聲音","Interim Results":"階段性辨識結果"}},3115:function(t,i,n){"use strict";var o=n(37133),r=n(2748),s=n(580),a=n(37790),l=n(50911);n(46614);var c=n(2303),d=n(54076),u=n(90492),h=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a};class p extends l.Plugin{afterInit(t){let{commands:i}=t.o.speechRecognize;i&&((0,s.extendLang)(u),(0,a.keys)(i,!1).forEach(n=>{n.split("|").forEach(o=>{o=o.trim().toLowerCase(),this._commandToWord[o]=i[n];let r=t.i18n(o);r!==o&&r.split("|").forEach(t=>{this._commandToWord[t.trim().toLowerCase()]=i[n].trim()})})}))}beforeDestruct(t){r.Dom.safeRemove(this.messagePopup)}onSpeechRecognizeProgressResult(t){this.messagePopup||(this.messagePopup=this.j.create.div("jodit-speech-recognize__popup")),this.j.workplace.appendChild(this.messagePopup),this.j.async.clearTimeout(this.__hidePopupTimeout),this.__hidePopupTimeout=this.j.async.setTimeout(()=>{r.Dom.safeRemove(this.messagePopup)},1e3),this.messagePopup.innerText=t+"|"}onSpeechRecognizeResult(t){this.j.async.clearTimeout(this.__hidePopupTimeout),r.Dom.safeRemove(this.messagePopup);let{j:i}=this,{s:n}=i;if(!this._checkCommand(t)){let{range:o}=n,s=n.current();if(n.isCollapsed()&&r.Dom.isText(s)&&r.Dom.isOrContains(i.editor,s)&&s.nodeValue){let r=s.nodeValue;s.nodeValue=r+(/[\u00A0 ]\uFEFF*$/.test(r)?"":" ")+t,o.setStartAfter(s),n.selectRange(o),i.synchronizeValues()}else n.insertHTML(t)}}_checkCommand(t){return t=t.toLowerCase().replace(/\./g,""),!!this._commandToWord[t]&&((0,d.execSpellCommand)(this.j,this._commandToWord[t]),!0)}constructor(){super(...arguments),this.buttons=[{group:"state",name:"speechRecognize"}],this._commandToWord={}}}h([(0,o.watch)(":speechRecognizeProgressResult")],p.prototype,"onSpeechRecognizeProgressResult",null),h([(0,o.watch)(":speechRecognizeResult")],p.prototype,"onSpeechRecognizeResult",null),c.Jodit.plugins.add("speech-recognize",p)},75259:function(t,i){"use strict";i.default='<svg viewBox="0 0 16 16" xml:space="preserve" xmlns="http://www.w3.org/2000/svg"> <path d="M8,11c1.657,0,3-1.343,3-3V3c0-1.657-1.343-3-3-3S5,1.343,5,3v5C5,9.657,6.343,11,8,11z"/> <path d="M13,8V6h-1l0,1.844c0,1.92-1.282,3.688-3.164,4.071C6.266,12.438,4,10.479,4,8V6H3v2c0,2.414,1.721,4.434,4,4.899V15H5v1h6 v-1H9v-2.101C11.279,12.434,13,10.414,13,8z"/> </svg> '},99085:function(t,i,n){"use strict";var o=n(12153),r=n(6441),s=n(10937);r.Config.prototype.spellcheck=!1,o.Icon.set("spellcheck",s.default),r.Config.prototype.controls.spellcheck={isActive:t=>t.o.spellcheck,icon:s.default,name:"spellcheck",command:"toggleSpellcheck",tooltip:"Spellcheck"}},28906:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"التدقيق الإملائي"}},24351:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Kontrola pravopisu"}},32806:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Rechtschreibprüfung"}},77725:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Corrección ortográfica"}},26428:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"غلطیابی املایی"}},42820:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Oikeinkirjoituksen tarkistus"}},60373:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Vérification Orthographique"}},98370:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"בדיקת איות"}},44850:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Helyesírás-ellenőrzés"}},3636:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Spellchecking"}},26529:function(t,i,n){"use strict";n.r(i),n.d(i,{ar:function(){return o},cs_cz:function(){return r},de:function(){return s},es:function(){return a},fa:function(){return l},fi:function(){return c},fr:function(){return d},he:function(){return u},hu:function(){return h},id:function(){return p},it:function(){return f},ja:function(){return m},ko:function(){return g},mn:function(){return b},nl:function(){return y},no:function(){return w},pl:function(){return _},pt_br:function(){return C},ru:function(){return k},sk:function(){return S},tr:function(){return x},ua:function(){return I},zh_cn:function(){return E},zh_tw:function(){return T}});var o=n(28906),r=n(24351),s=n(32806),a=n(77725),l=n(26428),c=n(42820),d=n(60373),u=n(98370),h=n(44850),p=n(3636),f=n(73220),m=n(55776),g=n(13995),b=n(6402),y=n(1879),w=n(1322),_=n(53361),C=n(70824),k=n(65140),S=n(60407),x=n(42247),I=n(68891),E=n(63195),T=n(42107)},73220:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Controllo ortografico"}},55776:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"スペルチェック"}},13995:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"맞춤법 검사"}},6402:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Дүрмийн алдаа шалгах"}},1879:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Spellingcontrole"}},1322:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Stavekontroll"}},53361:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Sprawdzanie pisowni"}},70824:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Verificação ortográfica"}},65140:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Проверка орфографии"}},60407:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Kontrola pravopisu"}},42247:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Yazım denetimi"}},68891:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Перевірка орфографії"}},63195:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"拼写检查"}},42107:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"拼字檢查"}},43809:function(t,i,n){"use strict";var o=n(65478),r=n(580),s=n(29960),a=n(50911);n(99085);var l=n(26529);class c extends a.Plugin{afterInit(t){t.e.on("afterInit afterAddPlace prepareWYSIWYGEditor",this.toggleSpellcheck),this.toggleSpellcheck(),t.registerCommand("toggleSpellcheck",()=>{this.jodit.o.spellcheck=!this.jodit.o.spellcheck,this.toggleSpellcheck(),this.j.e.fire("updateToolbar")})}toggleSpellcheck(){(0,s.attr)(this.jodit.editor,"spellcheck",this.jodit.o.spellcheck)}beforeDestruct(t){}constructor(t){super(t),this.buttons=[{group:"state",name:"spellcheck"}],(0,r.extendLang)(l)}}!function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);s>3&&a&&Object.defineProperty(i,n,a)}([o.autobind],c.prototype,"toggleSpellcheck",null),r.pluginSystem.add("spellcheck",c)},10937:function(t,i){"use strict";i.default='<svg viewBox="0 0 48 48" xmlns="http://www.w3.org/2000/svg"> <path d="M24.89 32h4.18L18.86 6h-3.71L4.93 32h4.18l2.25-6h11.29l2.24 6zM12.86 22L17 10.95 21.14 22h-8.28zm30.31 1.17L27 39.34 19.66 32l-2.83 2.83L27 45l19-19-2.83-2.83z"/> </svg> '},99649:function(t,i,n){"use strict";var o=n(6441);o.Config.prototype.showCharsCounter=!0,o.Config.prototype.countHTMLChars=!1,o.Config.prototype.countTextSpaces=!1,o.Config.prototype.showWordsCounter=!0},7309:function(t,i,n){"use strict";var o=n(82758),r=n(2748),s=n(580),a=n(20356);n(99649);class l extends a.Plugin{afterInit(){this.charCounter=this.j.c.span(),this.wordCounter=this.j.c.span(),this.j.e.on("afterInit changePlace afterAddPlace",this.reInit),this.reInit()}beforeDestruct(){r.Dom.safeRemove(this.charCounter),r.Dom.safeRemove(this.wordCounter),this.j.e.off("afterInit changePlace afterAddPlace",this.reInit),this.charCounter=null,this.wordCounter=null}constructor(){super(...arguments),this.charCounter=null,this.wordCounter=null,this.reInit=()=>{this.j.o.showCharsCounter&&this.charCounter&&this.j.statusbar.append(this.charCounter,!0),this.j.o.showWordsCounter&&this.wordCounter&&this.j.statusbar.append(this.wordCounter,!0),this.j.e.off("change keyup",this.calc).on("change keyup",this.calc),this.calc()},this.calc=this.j.async.throttle(()=>{let t=this.j.text;if(this.j.o.showCharsCounter&&this.charCounter){let i;i=this.j.o.countHTMLChars?this.j.value:this.j.o.countTextSpaces?t.replace((0,o.INVISIBLE_SPACE_REG_EXP)(),"").replace(/[\r\n]/g,""):t.replace((0,o.SPACE_REG_EXP)(),""),this.charCounter.textContent=this.j.i18n("Chars: %d",i.length)}this.j.o.showWordsCounter&&this.wordCounter&&(this.wordCounter.textContent=this.j.i18n("Words: %d",t.replace((0,o.INVISIBLE_SPACE_REG_EXP)(),"").split((0,o.SPACE_REG_EXP)()).filter(t=>t.length).length))},this.j.defaultTimeout)}}s.pluginSystem.add("stat",l)},48038:function(t,i,n){"use strict";var o=n(6441);o.Config.prototype.toolbarSticky=!0,o.Config.prototype.toolbarDisableStickyForMobile=!0,o.Config.prototype.toolbarStickyOffset=0},68687:function(t,i,n){"use strict";var o=n(82758),r=n(65478),s=n(2748),a=n(580),l=n(21537),c=n(20356);n(48038);let d=!o.IS_ES_NEXT&&o.IS_IE;class u extends c.Plugin{afterInit(t){t.e.on(t.ow,"scroll.sticky wheel.sticky mousewheel.sticky resize.sticky",this.__onScroll).on("getStickyState.sticky",()=>this.__isToolbarStuck)}__onScroll(){let{jodit:t}=this;if(!t.o.toolbarSticky||!t.o.toolbar)return;let i=t.ow.pageYOffset||t.od.documentElement&&t.od.documentElement.scrollTop||0,n=(0,l.offset)(t.container,t,t.od,!0),r=t.getMode()===o.MODE_WYSIWYG&&i+t.o.toolbarStickyOffset>n.top&&i+t.o.toolbarStickyOffset<n.top+n.height&&!(t.o.toolbarDisableStickyForMobile&&this.__isMobile());if(this.__isToolbarStuck===r)return;let s=t.toolbarContainer;s&&(r?this.addSticky(s):this.removeSticky(s)),t.e.fire("toggleSticky",r)}__isMobile(){let{j:t}=this;return t&&t.options&&t.container&&t.options.sizeSM>=t.container.offsetWidth}beforeDestruct(t){s.Dom.safeRemove(this.__dummyBox),t.e.off(t.ow,"scroll.sticky wheel.sticky mousewheel.sticky resize.sticky",this.__onScroll).off(".sticky")}constructor(){super(...arguments),this.__isToolbarStuck=!1,this.__createDummy=t=>{this.__dummyBox=this.j.c.div(),this.__dummyBox.classList.add("jodit_sticky-dummy_toolbar"),this.j.container.insertBefore(this.__dummyBox,t)},this.addSticky=t=>{this.__isToolbarStuck||(d&&!this.__dummyBox&&this.__createDummy(t),this.j.container.classList.add("jodit_sticky"),this.__isToolbarStuck=!0),(0,l.css)(t,{top:this.j.o.toolbarStickyOffset||null,width:this.j.container.offsetWidth-2}),this.__dummyBox&&(0,l.css)(this.__dummyBox,{height:t.offsetHeight})},this.removeSticky=t=>{this.__isToolbarStuck&&((0,l.css)(t,{width:"",top:""}),this.j.container.classList.remove("jodit_sticky"),this.__isToolbarStuck=!1)}}}!function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);s>3&&a&&Object.defineProperty(i,n,a)}([(0,r.throttle)()],u.prototype,"__onScroll",null),a.pluginSystem.add("sticky",u)},87394:function(t,i,n){"use strict";var o=n(12153),r=n(6441),s=n(5119);r.Config.prototype.usePopupForSpecialCharacters=!1,r.Config.prototype.specialCharacters=["!",""","#","$","%","&","'","(",")","*","+","-",".","/","0","1","2","3","4","5","6","7","8","9",":",";","<","=",">","?","@","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z","[","]","^","_","`","a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z","{","|","}","~","€","‘","’","“","”","–","—","¡","¢","£","¤","¥","¦","§","¨","©","ª","«","»","¬","®","¯","°","²","³","´","µ","¶","·","¸","¹","º","¼","½","¾","¿","À","Á","Â","Ã","Ä","Å","Æ","Ç","È","É","Ê","Ë","Ì","Í","Î","Ï","Ð","Ñ","Ò","Ó","Ô","Õ","Ö","×","Ø","Ù","Ú","Û","Ü","Ý","Þ","ß","à","á","â","ã","ä","å","æ","ç","è","é","ê","ë","ì","í","î","ï","ð","ñ","ò","ó","ô","õ","ö","÷","ø","ù","ú","û","ü","ý","þ","ÿ","Œ","œ","Ŵ","Ŷ","ŵ","ŷ","‚","‛","„","…","™","►","•","→","⇒","⇔","♦","≈"],o.Icon.set("symbols",s.default),r.Config.prototype.controls.symbols={hotkeys:["ctrl+shift+i","cmd+shift+i"],tooltip:"Insert Special Character",popup(t,i,n){let o=t.e.fire("generateSpecialCharactersTable.symbols");if(o){if(t.o.usePopupForSpecialCharacters){let i=t.c.div();return i.classList.add("jodit-symbols"),i.appendChild(o),t.e.on(o,"close_dialog",n),i}t.alert(o,"Select Special Character",void 0,"jodit-symbols").bindDestruct(t);let i=o.querySelector("a");i&&i.focus()}}}},20741:function(t,i,n){"use strict";n.r(i),i.default={symbols:"رمز"}},3958:function(t,i,n){"use strict";n.r(i),i.default={symbols:"symbol"}},53437:function(t,i,n){"use strict";n.r(i),i.default={symbols:"Symbol"}},56882:function(t,i,n){"use strict";n.r(i),i.default={symbols:"Símbolo"}},75703:function(t,i,n){"use strict";n.r(i),i.default={symbols:"سمبل"}},49759:function(t,i,n){"use strict";n.r(i),i.default={symbols:"Symbolit"}},44730:function(t,i,n){"use strict";n.r(i),i.default={symbols:"caractère"}},70945:function(t,i,n){"use strict";n.r(i),i.default={symbols:"תו מיוחד"}},49841:function(t,i,n){"use strict";n.r(i),i.default={symbols:"Szimbólum"}},33295:function(t,i,n){"use strict";n.r(i),i.default={symbols:"simbol"}},32824:function(t,i,n){"use strict";n.r(i),n.d(i,{ar:function(){return o},cs_cz:function(){return r},de:function(){return s},es:function(){return a},fa:function(){return l},fi:function(){return c},fr:function(){return d},he:function(){return u},hu:function(){return h},id:function(){return p},it:function(){return f},ja:function(){return m},ko:function(){return g},mn:function(){return b},nl:function(){return y},pl:function(){return w},pt_br:function(){return _},ru:function(){return C},tr:function(){return k},ua:function(){return S},zh_cn:function(){return x},zh_tw:function(){return I}});var o=n(20741),r=n(3958),s=n(53437),a=n(56882),l=n(75703),c=n(49759),d=n(44730),u=n(70945),h=n(49841),p=n(33295),f=n(47615),m=n(83059),g=n(22396),b=n(58285),y=n(51804),w=n(53650),_=n(41369),C=n(57855),k=n(44328),S=n(91080),x=n(89702),I=n(66434)},47615:function(t,i,n){"use strict";n.r(i),i.default={symbols:"Simbolo"}},83059:function(t,i,n){"use strict";n.r(i),i.default={symbols:"symbol"}},22396:function(t,i,n){"use strict";n.r(i),i.default={symbols:"기호"}},58285:function(t,i,n){"use strict";n.r(i),i.default={symbols:"тэмдэгт"}},51804:function(t,i,n){"use strict";n.r(i),i.default={symbols:"symbool"}},53650:function(t,i,n){"use strict";n.r(i),i.default={symbols:"symbol"}},41369:function(t,i,n){"use strict";n.r(i),i.default={symbols:"Símbolo"}},57855:function(t,i,n){"use strict";n.r(i),i.default={symbols:"символ"}},44328:function(t,i,n){"use strict";n.r(i),i.default={symbols:"Sembol"}},91080:function(t,i,n){"use strict";n.r(i),i.default={symbols:"символ"}},89702:function(t,i,n){"use strict";n.r(i),i.default={symbols:"符号"}},66434:function(t,i,n){"use strict";n.r(i),i.default={symbols:"符號"}},59495:function(t,i,n){"use strict";var o=n(82758),r=n(2748),s=n(580),a=n(43555),l=n(20356);n(87394);var c=n(32824);class d extends l.Plugin{afterInit(t){t.e.on("generateSpecialCharactersTable.symbols",()=>{let i=t.c.fromHTML(`<div class="jodit-symbols__container">
|
|
266
|
+
</div>`}get currentIndex(){return this._currentIndex}set currentIndex(t){this._currentIndex=t,this.currentBox.innerText=t.toString()}set count(t){this.countBox.innerText=t.toString()}get query(){return this.queryInput.value}get replace(){return this.replaceInput.value}onEditorKeyDown(t){if(!this.isOpened)return;let{j:i}=this;if(i.getRealMode()===o.MODE_WYSIWYG)switch(t.key){case o.KEY_ESC:this.close();break;case o.KEY_F3:this.queryInput.value&&(i.e.fire(t.shiftKey?"searchPrevious":"searchNext"),t.preventDefault())}}open(t,i,n=!1){this.isOpened||(this.j.workplace.appendChild(this.container),this.isOpened=!0),this.calcSticky(this.j.e.fire("getStickyState.sticky")||!1),this.j.e.fire("hidePopup"),this.setMod("replace",n);let o=null!=t?t:(this.j.s.sel||"").toString();o&&(this.queryInput.value=o),i&&(this.replaceInput.value=i),this.setMod("empty-query",!o.length),this.j.e.fire(this,"needUpdateCounters"),o?this.queryInput.select():this.queryInput.focus()}close(){this.isOpened&&(this.j.s.restore(),s.Dom.safeRemove(this.container),this.isOpened=!1,this.j.e.fire(this,"afterClose"))}calcSticky(t){if(this.isOpened)if(this.setMod("sticky",t),t){let t=(0,a.position)(this.j.toolbarContainer);(0,a.css)(this.container,{top:t.top+t.height,left:t.left+t.width})}else(0,a.css)(this.container,{top:null,left:null})}constructor(t){super(t),this.selInfo=null,this._currentIndex=0,this.isOpened=!1;const{query:i,replace:n,cancel:r,next:s,prev:l,replaceBtn:c,current:d,count:u}=(0,a.refs)(this.container);this.queryInput=i,this.replaceInput=n,this.closeButton=r,this.replaceButton=c,this.currentBox=d,this.countBox=u;const h=()=>this.close(),p=()=>void t.e.fire(this,"pressReplaceButton"),f=()=>void t.e.fire("searchNext"),m=()=>void t.e.fire("searchPrevious"),g=t=>i=>{i.detail||(i.preventDefault(),t())};t.e.on(this.closeButton,"pointerdown",()=>(h(),!1)).on(this.closeButton,"click",g(h)).on(this.queryInput,"input",()=>{this.currentIndex=0}).on(this.queryInput,"pointerdown",()=>{t.s.isFocused()&&(t.s.removeMarkers(),this.selInfo=t.s.save())}).on(this.replaceButton,"pointerdown",()=>(p(),!1)).on(this.replaceButton,"click",g(p)).on(s,"pointerdown",()=>(f(),!1)).on(s,"click",g(f)).on(l,"pointerdown",()=>(m(),!1)).on(l,"click",g(m)).on(this.queryInput,"input",()=>{this.setMod("empty-query",!(0,a.trim)(this.queryInput.value).length)}).on(this.queryInput,"keydown",(()=>{let i=this.j.async.debounce(async i=>{i.key===o.KEY_ENTER?await t.e.fire("searchNext")&&this.close():t.e.fire(this,"needUpdateCounters")},this.j.defaultTimeout);return t=>{t.key===o.KEY_ENTER&&(t.preventDefault(),t.stopImmediatePropagation()),i(t)}})())}};c([(0,r.watch)([":keydown","queryInput:keydown"])],d.prototype,"onEditorKeyDown",null),c([r.autobind],d.prototype,"open",null),c([r.autobind],d.prototype,"close",null),c([(0,r.watch)(":toggleSticky")],d.prototype,"calcSticky",null),d=c([r.component],d)},55311:function(t,i,n){"use strict";n(6441).Config.prototype.tableAllowCellSelection=!0},28545:function(t,i,n){"use strict";var o=n(82758),r=n(65478),s=n(2748),a=n(580),l=n(21537),c=n(50911),d=n(76014);n(55311);var u=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a};let h="table_processor_observer",p="onMoveTableSelectCell";class f extends c.Plugin{get __tableModule(){return this.j.getInstance(d.Table,this.j.o)}afterInit(t){t.o.tableAllowCellSelection&&t.e.on("keydown.select-cells",t=>{t.key===o.KEY_TAB&&this.unselectCells()}).on("beforeCommand.select-cells",this.onExecCommand).on("afterCommand.select-cells",this.onAfterCommand).on(["clickEditor","mousedownTd","mousedownTh","touchstartTd","touchstartTh"].map(t=>t+".select-cells").join(" "),this.onStartSelection).on("clickTr clickTbody",()=>{var t;let i=this.__tableModule.getAllSelectedCells().length;if(i)return i>1&&(null==(t=this.j.s.sel)||t.removeAllRanges()),!1})}onStartSelection(t,i){var n;if(this.j.o.readonly)return;let o=s.Dom.closest(t,"table",this.j.editor);return((null==i?void 0:i.ctrlKey)||(null==i?void 0:i.metaKey))&&t!==this.j.editor&&o&&s.Dom.isCell(t)?(this.__tableModule.getAllSelectedCells().includes(t)?this.__tableModule.removeSelection(t):(t.firstChild||t.appendChild(this.j.createInside.element("br")),this.__tableModule.addSelection(t)),this.__selectedCell=t,null==(n=this.j.s.sel)||n.removeAllRanges(),this.__tableModule.getAllSelectedCells().length?this.j.e.fire("showPopup",o,()=>(0,l.position)(t,this.j),"cells"):this.j.e.fire("hidePopup","cells"),!1):(this.unselectCells(),t===this.j.editor)?void 0:t&&o?(t.firstChild||t.appendChild(this.j.createInside.element("br")),this.__isSelectionMode=!0,this.__selectedCell=t,this.__tableModule.addSelection(t),this.j.e.on(o,"mousemove.select-cells touchmove.select-cells",this.j.async.throttle(this.__onMove.bind(this,o),{label:p,timeout:this.j.defaultTimeout/2})).on(o,"mouseup.select-cells touchend.select-cells",this.__onStopSelection.bind(this,o)),!1):void 0}onOutsideClick(){this.__selectedCell=null,this.__onRemoveSelection()}onChange(){this.j.isLocked||this.__isSelectionMode||this.__onRemoveSelection()}__onMove(t,i){var n,o;let r;if(this.j.o.readonly&&!this.j.isLocked||this.j.isLockedNotBy(h))return;let a=(null!=(n=this.j.o.shadowRoot)?n:this.j.ed).elementFromPoint(i.clientX,i.clientY);if(!a)return;let l=s.Dom.closest(a,["td","th"],t);if(!l||!this.__selectedCell)return;l!==this.__selectedCell&&this.j.lock(h),this.unselectCells();let c=this.__tableModule.getSelectedBound(t,[l,this.__selectedCell]),d=this.__tableModule.formalMatrix(t);for(let t=c[0][0];t<=c[1][0];t+=1)for(let i=c[0][1];i<=c[1][1];i+=1)this.__tableModule.addSelection(d[t][i]);this.__tableModule.getAllSelectedCells().length>1&&(null==(o=this.j.s.sel)||o.removeAllRanges()),this.j.e.fire("hidePopup"),i.stopPropagation(),r=this.j.createInside.fromHTML('<div style="color:rgba(0,0,0,0.01);width:0;height:0"> </div>'),l.appendChild(r),this.j.async.setTimeout(()=>{var t;null==(t=r.parentNode)||t.removeChild(r)},this.j.defaultTimeout/5)}__onRemoveSelection(t){var i;if(!(null==(i=null==t?void 0:t.buffer)?void 0:i.actionTrigger)&&!this.__selectedCell&&this.__tableModule.getAllSelectedCells().length){this.j.unlock(),this.unselectCells(),this.j.e.fire("hidePopup","cells");return}this.__isSelectionMode=!1,this.__selectedCell=null}__onStopSelection(t,i){var n,o,r;if(!this.__selectedCell)return;this.__isSelectionMode=!1,this.j.unlock();let a=(null!=(n=this.j.o.shadowRoot)?n:this.j.ed).elementFromPoint(i.clientX,i.clientY);if(!a)return;let c=s.Dom.closest(a,["td","th"],t);if(!c)return;let d=s.Dom.closest(c,"table",t);if(d&&d!==t)return;let u=this.__tableModule.getSelectedBound(t,[c,this.__selectedCell]),h=this.__tableModule.formalMatrix(t),f=null==(o=h[u[1][0]])?void 0:o[u[1][1]],m=null==(r=h[u[0][0]])?void 0:r[u[0][1]];m&&f&&(this.j.e.fire("showPopup",t,()=>{let t=(0,l.position)(m,this.j),i=(0,l.position)(f,this.j);return{left:t.left,top:t.top,width:i.left-t.left+i.width,height:i.top-t.top+i.height}},"cells"),(0,l.$$)("table",this.j.editor).forEach(t=>{this.j.e.off(t,"mousemove.select-cells touchmove.select-cells mouseup.select-cells touchend.select-cells")}),this.j.async.clearTimeout(p))}unselectCells(t){let i=this.__tableModule,n=i.getAllSelectedCells();n.length&&n.forEach(n=>{t&&t===n||i.removeSelection(n)})}onExecCommand(t){if(/^(delete|backspace)(word|sentence)?button$/.test(t)&&this.__tableModule.getAllSelectedCells().length>1){let t=this.__tableModule.getAllSelectedCells();return t.forEach(t=>{s.Dom.detach(t),t.appendChild(this.j.createInside.element("br"))}),this.unselectCells(),this.j.s.setCursorIn(t[0]),this.j.synchronizeValues(),!1}if(/table(splitv|splitg|merge|empty|bin|binrow|bincolumn|addcolumn|addrow)/.test(t)){t=t.replace("table","");let i=this.__tableModule.getAllSelectedCells();if(i.length){let[n]=i;if(!n)return;let o=s.Dom.closest(n,"table",this.j.editor);if(!o)return;switch(t){case"splitv":this.__tableModule.splitVertical(o);break;case"splitg":this.__tableModule.splitHorizontal(o);break;case"merge":this.__tableModule.mergeSelected(o);break;case"empty":i.forEach(t=>s.Dom.detach(t));break;case"bin":s.Dom.safeRemove(o);break;case"binrow":new Set(i.map(t=>t.parentNode)).forEach(t=>{this.__tableModule.removeRow(o,t.rowIndex)});break;case"bincolumn":{let t=new Set,n=[];i.forEach(i=>{let[,r]=this.__tableModule.formalCoordinate(o,i);t.has(r)||(n.push(r),t.add(r))}),n.sort((t,i)=>i-t).forEach(t=>{this.__tableModule.removeColumn(o,t)})}break;case"addcolumnafter":case"addcolumnbefore":this.__tableModule.appendColumn(o,n,"addcolumnafter"===t);break;case"addrowafter":case"addrowbefore":this.__tableModule.appendRow(o,n.parentNode,"addrowafter"===t)}}return!1}}onAfterCommand(t){/^justify/.test(t)&&this.__tableModule.getAllSelectedCells().forEach(i=>(0,l.alignElement)(t,i))}beforeDestruct(t){this.__onRemoveSelection(),t.e.off(".select-cells")}constructor(){super(...arguments),this.__selectedCell=null,this.__isSelectionMode=!1}}f.requires=["select"],u([r.autobind],f.prototype,"onStartSelection",null),u([(0,r.watch)(":outsideClick")],f.prototype,"onOutsideClick",null),u([(0,r.watch)(":change")],f.prototype,"onChange",null),u([r.autobind],f.prototype,"__onRemoveSelection",null),u([r.autobind],f.prototype,"__onStopSelection",null),u([r.autobind],f.prototype,"onExecCommand",null),u([r.autobind],f.prototype,"onAfterCommand",null),a.pluginSystem.add("selectCells",f)},67215:function(t,i,n){"use strict";n(6441).Config.prototype.select={normalizeSelectionBeforeCutAndCopy:!1,normalizeTripleClick:!0}},9881:function(t,i,n){"use strict";var o=n(82758),r=n(65478),s=n(2748),a=n(580),l=n(87058),c=n(50911),d=n(67510);n(67215);var u=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a};class h extends c.Plugin{afterInit(t){this.proxyEventsList.forEach(i=>{t.e.on(i+".select",this.onStartSelection)})}beforeDestruct(t){this.proxyEventsList.forEach(i=>{t.e.on(i+".select",this.onStartSelection)})}onStartSelection(t){let{j:i}=this,n,o=t.target;for(;void 0===n&&o&&o!==i.editor;)n=i.e.fire((0,l.camelCase)(t.type+"_"+o.nodeName.toLowerCase()),o,t),o=o.parentElement;"click"===t.type&&void 0===n&&o===i.editor&&i.e.fire(t.type+"Editor",o,t)}onOutsideClick(t){let i=t.target;s.Dom.up(i,t=>t===this.j.editor)||d.UIElement.closestElement(i,d.Popup)||this.j.e.fire("outsideClick",t)}beforeCommandCut(){let{s:t}=this.j;if(!t.isCollapsed()){let i=t.current();i&&s.Dom.isOrContains(this.j.editor,i)&&this.onCopyNormalizeSelectionBound()}}beforeCommandSelectAll(){let{s:t}=this.j;return t.focus(),t.select(this.j.editor,!0),t.expandSelection(),!1}onClickRightOfNestedListItem(t){let{s:i}=this.j,n=i.range;if(!n.collapsed||0!==n.startOffset||!s.Dom.isText(n.startContainer))return;let o=n.startContainer,r=o.parentNode;if(!s.Dom.isTag(r,"li")||!(r.querySelector("ul")||r.querySelector("ol")))return;let a=this.j.ed.createRange();a.selectNodeContents(o);let l=a.getBoundingClientRect();t.clientX>l.right&&i.setCursorAfter(o)}onClickKeepPendingFormat(){var t,i;let{s:n}=this.j,r=n.range;if(!r.collapsed||!s.Dom.isText(r.startContainer))return;let a=r.startContainer;if(r.startOffset!==(null!=(i=null==(t=a.nodeValue)?void 0:t.length)?i:0))return;let l=a.nextSibling;if(!s.Dom.isElement(l)||!l.nodeName.match(o.IS_INLINE)||!s.Dom.isEmpty(l))return;let c=l;for(;s.Dom.isElement(c.firstElementChild)&&c.firstElementChild.nodeName.match(o.IS_INLINE);)c=c.firstElementChild;n.setCursorIn(c)}onTripleClickNormalizeSelection(t){if(3!==t.detail||!this.j.o.select.normalizeTripleClick)return;let{s:i}=this.j,{startContainer:n,startOffset:o}=i.range;0===o&&s.Dom.isText(n)&&i.select(s.Dom.closest(n,s.Dom.isBlock,this.j.editor)||n,!0)}onCopyNormalizeSelectionBound(t){let{s:i,editor:n,o}=this.j;!o.select.normalizeSelectionBeforeCutAndCopy||i.isCollapsed()||(!t||t.isTrusted&&s.Dom.isNode(t.target)&&s.Dom.isOrContains(n,t.target))&&this.jodit.s.expandSelection()}constructor(){super(...arguments),this.proxyEventsList=["click","mousedown","touchstart","mouseup","touchend"]}}u([r.autobind],h.prototype,"onStartSelection",null),u([(0,r.watch)("ow:click")],h.prototype,"onOutsideClick",null),u([(0,r.watch)([":beforeCommandCut"])],h.prototype,"beforeCommandCut",null),u([(0,r.watch)([":beforeCommandSelectall"])],h.prototype,"beforeCommandSelectAll",null),u([(0,r.watch)([":click"])],h.prototype,"onClickRightOfNestedListItem",null),u([(0,r.watch)([":click"])],h.prototype,"onClickKeepPendingFormat",null),u([(0,r.watch)([":click"])],h.prototype,"onTripleClickNormalizeSelection",null),u([(0,r.watch)([":copy",":cut"])],h.prototype,"onCopyNormalizeSelectionBound",null),a.pluginSystem.add("select",h)},80792:function(t,i,n){"use strict";var o=n(6441);o.Config.prototype.minWidth=200,o.Config.prototype.maxWidth="100%",o.Config.prototype.minHeight=200,o.Config.prototype.maxHeight="auto",o.Config.prototype.saveHeightInStorage=!1},45927:function(t,i,n){"use strict";var o=n(65478),r=n(580),s=n(84767),a=n(41180),l=n(20356);n(80792);var c=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a};class d extends l.Plugin{afterInit(t){t.e.on("setHeight.size",this.__setHeight).on("setWidth.size",this.__setWidth).on("afterInit.size changePlace.size",this.__initialize,{top:!0}).on(t.ow,"load.size",this.__resizeWorkspaces).on("afterInit.size resize.size afterUpdateToolbar.size scroll.size afterResize.size",this.__resizeWorkspaces).on("toggleFullSize.size toggleToolbar.size",this.__resizeWorkspaceImd),this.__immediateInitialize()}__initialize(){this.__immediateInitialize()}__immediateInitialize(){let{j:t}=this;if(t.o.inline)return;let{height:i}=t.o;if(t.o.saveHeightInStorage&&"auto"!==i){let n=t.storage.get("height");n&&(i=n)}(0,a.css)(t.editor,{minHeight:"100%"}),(0,a.css)(t.container,{minHeight:t.o.minHeight,maxHeight:t.o.maxHeight,minWidth:t.o.minWidth,maxWidth:t.o.maxWidth}),t.isFullSize||(this.__setHeight(i),this.__setWidth(t.o.width))}__setHeight(t){let{clientHeight:i,clientWidth:n}=this.j.container;if((0,s.isNumber)(t)){let{minHeight:i,maxHeight:n}=this.j.o;(0,s.isNumber)(i)&&i>t&&(t=i),(0,s.isNumber)(n)&&n<t&&(t=n)}(0,a.css)(this.j.container,"height",t),this.j.o.saveHeightInStorage&&this.j.storage.set("height",t),this.__resizeWorkspaceImd({clientHeight:i,clientWidth:n})}__setWidth(t){let{clientHeight:i,clientWidth:n}=this.j.container;if((0,s.isNumber)(t)){let{minWidth:i,maxWidth:n}=this.j.o;(0,s.isNumber)(i)&&i>t&&(t=i),(0,s.isNumber)(n)&&t>n&&(t=n)}(0,a.css)(this.j.container,"width",t),this.__resizeWorkspaceImd({clientHeight:i,clientWidth:n})}__getNotWorkHeight(){var t;let i=this.j.toolbarContainer;return(i&&this.j.container.contains(i)?i.offsetHeight:0)+((null==(t=this.j.statusbar)?void 0:t.getHeight())||0)+2}__resizeWorkspaceImd({clientHeight:t,clientWidth:i}=this.j.container){if(!this.j||this.j.isDestructed||!this.j.o||this.j.o.inline||!this.j.container||!this.j.container.parentNode)return;let n=((0,a.css)(this.j.container,"minHeight")||0)-this.__getNotWorkHeight();if((0,s.isNumber)(n)&&n>0&&([this.j.workplace,this.j.currentPlace.slots.center,this.j.iframe,this.j.editor].map(t=>{t&&(0,a.css)(t,"minHeight",n)}),this.j.e.fire("setMinHeight",n)),(0,s.isNumber)(this.j.o.maxHeight)){let t=this.j.o.maxHeight-this.__getNotWorkHeight();[this.j.workplace,this.j.currentPlace.slots.center,this.j.iframe,this.j.editor].map(i=>{i&&(0,a.css)(i,"maxHeight",t)}),this.j.e.fire("setMaxHeight",t)}if(this.j.container){let t="auto"!==this.j.o.height||this.j.isFullSize?this.j.container.offsetHeight-this.__getNotWorkHeight():"auto";(0,a.css)(this.j.workplace,"height",t),this.j.container.style.setProperty("--jd-jodit-workplace-height",(0,s.isNumber)(t)?t+"px":t)}let{clientHeight:o,clientWidth:r}=this.j.container;(t!==o||i!==r)&&this.j.e.fire(this.j,"resize")}beforeDestruct(t){t.e.off(t.ow,"load.size",this.__resizeWorkspaces).off(".size")}constructor(){super(...arguments),this.__resizeWorkspaces=this.j.async.debounce(this.__resizeWorkspaceImd,this.j.defaultTimeout,!0)}}c([(0,o.throttle)()],d.prototype,"__initialize",null),c([o.autobind],d.prototype,"__setHeight",null),c([o.autobind],d.prototype,"__setWidth",null),c([o.autobind],d.prototype,"__resizeWorkspaceImd",null),r.pluginSystem.add("size",d)},36204:function(t,i,n){"use strict";var o=n(82758),r=n(12153),s=n(6441),a=n(35599);s.Config.prototype.beautifyHTML=!o.IS_IE,s.Config.prototype.sourceEditor="ace",s.Config.prototype.sourceEditorNativeOptions={showGutter:!0,theme:"ace/theme/idle_fingers",mode:"ace/mode/html",wrap:!0,highlightActiveLine:!0},s.Config.prototype.sourceEditorCDNUrlsJS=["https://cdnjs.cloudflare.com/ajax/libs/ace/1.43.3/ace.js"],s.Config.prototype.beautifyHTMLCDNUrlsJS=["https://cdnjs.cloudflare.com/ajax/libs/js-beautify/1.14.4/beautify.min.js","https://cdnjs.cloudflare.com/ajax/libs/js-beautify/1.14.4/beautify-html.min.js"],r.Icon.set("source",a.default),s.Config.prototype.controls.source={mode:o.MODE_SPLIT,exec(t){t.toggleMode()},isActive:t=>t.getRealMode()===o.MODE_SOURCE,tooltip:"Change mode"}},60031:function(t,i,n){"use strict";n.d(i,{AceEditor:function(){return a}});var o=n(82758),r=n(21537),s=n(23370);class a extends s.SourceEditor{aceExists(){return void 0!==this.j.ow.ace}getLastColumnIndex(t){return this.instance.session.getLine(t).length}getLastColumnIndices(){let t=this.instance.session.getLength(),i=[],n=0;for(let o=0;t>o;o++)n+=this.getLastColumnIndex(o),o>0&&(n+=1),i[o]=n;return i}getRowColumnIndices(t){let i=this.getLastColumnIndices();if(t<=i[0])return{row:0,column:t};let n=1;for(let o=1;o<i.length;o++)t>i[o]&&(n=o+1);let o=t-i[n-1]-1;return{row:n,column:o}}setSelectionRangeIndices(t,i){let n=this.getRowColumnIndices(t),o=this.getRowColumnIndices(i);this.instance.getSelection().setSelectionRange({start:n,end:o})}getIndexByRowColumn(t,i){return this.getLastColumnIndices()[t]-this.getLastColumnIndex(t)+i}init(t){let i=()=>{if(void 0!==this.instance||!this.aceExists())return;let i=this.j.c.div("jodit-source__mirror-fake");this.container.appendChild(i);let n=t.ow.ace;this.instance=n.edit(i),"rtl"===t.o.direction&&(this.instance.setOption("rtlText",!0),this.instance.setOption("rtl",!0)),this.instance.setOptions(t.o.sourceEditorNativeOptions),this.instance.setTheme(t.o.sourceEditorNativeOptions.theme),this.instance.renderer.setShowGutter(t.o.sourceEditorNativeOptions.showGutter),this.instance.getSession().setMode(t.o.sourceEditorNativeOptions.mode),this.instance.setHighlightActiveLine(t.o.sourceEditorNativeOptions.highlightActiveLine),this.instance.getSession().setUseWrapMode(!0),this.instance.setOption("indentedSoftWrap",!1),this.instance.setOption("wrap",t.o.sourceEditorNativeOptions.wrap),this.instance.getSession().setUseWorker(!1),this.instance.$blockScrolling=1/0,this.instance.on("change",this.toWYSIWYG),this.instance.on("focus",this.proxyOnFocus),this.instance.on("mousedown",this.proxyOnMouseDown),this.instance.on("blur",this.proxyOnBlur),t.getRealMode()!==o.MODE_WYSIWYG&&this.setValue(this.getValue());let r=this.j.async.throttle(()=>{if(t.isInDestruct||t.getMode()===o.MODE_WYSIWYG)return;let i=this.instance.isFocused();"auto"!==t.o.height?this.instance.setOption("maxLines",t.workplace.offsetHeight/this.instance.renderer.lineHeight):this.instance.setOption("maxLines",1/0),this.instance.resize(),i&&this.focus()},2*this.j.defaultTimeout);t.e.on(t,"resize",r).on("afterResize afterSetMode",r),r(),this.onReady()},n=()=>{t.isInDestruct||t.getRealMode()!==o.MODE_SOURCE&&t.getMode()!==o.MODE_SPLIT||(this.fromWYSIWYG(),i())};t.e.on("afterSetMode",n),n(),this.aceExists()||(0,r.loadNext)(t,t.o.sourceEditorCDNUrlsJS).then(n).catch(()=>null)}destruct(){var t,i;this.instance.off("change",this.toWYSIWYG),this.instance.off("focus",this.proxyOnFocus),this.instance.off("mousedown",this.proxyOnMouseDown),this.instance.destroy(),null==(i=null==(t=this.j)?void 0:t.events)||i.off("aceInited.source")}setValue(t){if(!this.j.o.editHTMLDocumentMode&&this.j.o.beautifyHTML){let i=this.j.e.fire("beautifyHTML",t);(0,r.isString)(i)&&(t=i)}this.instance.setValue(t),this.instance.clearSelection()}getValue(){return this.instance.getValue()}setReadOnly(t){this.instance.setReadOnly(t)}get isFocused(){return this.instance.isFocused()}focus(){this.instance.container.focus(),this.instance.focus()}blur(){this.instance.blur()}getSelectionStart(){let t=this.instance.selection.getRange();return this.getIndexByRowColumn(t.start.row,t.start.column)}getSelectionEnd(){let t=this.instance.selection.getRange();return this.getIndexByRowColumn(t.end.row,t.end.column)}selectAll(){this.instance.selection.selectAll()}insertRaw(t){let i=this.instance.selection.getCursor(),n=this.instance.session.insert(i,t);this.instance.selection.setRange({start:i,end:n},!1)}setSelectionRange(t,i){this.setSelectionRangeIndices(t,i)}setPlaceHolder(t){}replaceUndoManager(){let{history:t}=this.jodit;this.instance.commands.addCommand({name:"Undo",bindKey:{win:"Ctrl-Z",mac:"Command-Z"},exec(){t.undo()}}),this.instance.commands.addCommand({name:"Redo",bindKey:{win:"Ctrl-Shift-Z",mac:"Command-Shift-Z"},exec(){t.redo()}})}constructor(){super(...arguments),this.className="jodit_ace_editor",this.proxyOnBlur=t=>{this.j.e.fire("blur",t)},this.proxyOnFocus=t=>{this.j.e.fire("focus",t)},this.proxyOnMouseDown=t=>{this.j.e.fire("mousedown",t)}}}},7483:function(t,i,n){"use strict";n.d(i,{TextAreaEditor:function(){return l}});var o=n(2748),r=n(29960),s=n(41180),a=n(23370);class l extends a.SourceEditor{init(t){this.instance=t.c.element("textarea",{class:"jodit-source__mirror",dir:"rtl"===t.o.direction?"rtl":void 0}),this.container.appendChild(this.instance),t.e.on(this.instance,"mousedown keydown touchstart input",t.async.debounce(this.toWYSIWYG,t.defaultTimeout)).on("setMinHeight.source",t=>{(0,s.css)(this.instance,"minHeight",t)}).on(this.instance,"change keydown mousedown touchstart input",this.autosize).on("afterSetMode.source",this.autosize).on(this.instance,"mousedown focus blur",i=>{t.e.fire(i.type,i)}),this.autosize(),this.onReady()}destruct(){o.Dom.safeRemove(this.instance)}getValue(){return this.instance.value}setValue(t){this.instance.value=t}insertRaw(t){let i=this.getValue();if(this.getSelectionStart()>=0){let n=this.getSelectionStart(),o=this.getSelectionEnd();this.setValue(i.substring(0,n)+t+i.substring(o,i.length))}else this.setValue(i+t)}getSelectionStart(){return this.instance.selectionStart}getSelectionEnd(){return this.instance.selectionEnd}setSelectionRange(t,i=t){this.instance.setSelectionRange(t,i)}get isFocused(){return this.instance===this.j.od.activeElement}focus(){this.instance.focus()}blur(){this.instance.blur()}setPlaceHolder(t){(0,r.attr)(this.instance,"placeholder",t)}setReadOnly(t){(0,r.attr)(this.instance,"readonly",t?"true":null)}selectAll(){this.instance.select()}replaceUndoManager(){let{history:t}=this.jodit;this.j.e.on(this.instance,"keydown",i=>{if((i.ctrlKey||i.metaKey)&&"z"===i.key)return i.shiftKey?t.redo():t.undo(),this.setSelectionRange(this.getValue().length),!1})}constructor(){super(...arguments),this.autosize=this.j.async.debounce(()=>{this.instance.style.height="auto",this.instance.style.height=this.instance.scrollHeight+"px"},this.j.defaultTimeout,!0)}}},52968:function(t,i,n){"use strict";n.d(i,{AceEditor:function(){return o.AceEditor},TextAreaEditor:function(){return r.TextAreaEditor}});var o=n(60031),r=n(7483)},70022:function(t,i,n){"use strict";n.d(i,{createSourceEditor:function(){return s}});var o=n(21537),r=n(52968);function s(t,i,n,s,a){let l;if((0,o.isFunction)(t))l=t(i);else switch(t){case"ace":if(!i.o.shadowRoot){l=new r.AceEditor(i,n,s,a);break}default:l=new r.TextAreaEditor(i,n,s,a)}return l.init(i),l.onReadyAlways(()=>{l.setReadOnly(i.o.readonly)}),l}},23370:function(t,i,n){"use strict";n.d(i,{SourceEditor:function(){return o}});class o{get j(){return this.jodit}onReady(){this.replaceUndoManager(),this.isReady=!0,this.j.e.fire(this,"ready")}onReadyAlways(t){var i;this.isReady?t():null==(i=this.j.events)||i.on(this,"ready",t)}constructor(t,i,n,o){this.jodit=t,this.container=i,this.toWYSIWYG=n,this.fromWYSIWYG=o,this.className="",this.isReady=!1}}},52951:function(t,i,n){"use strict";var o=n(82758),r=n(65478),s=n(2748),a=n(580),l=n(21537),c=n(50911);n(36204);var d=n(70022),u=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a};class h extends c.Plugin{onInsertHTML(t){var i;if(!this.j.o.readonly&&!this.j.isEditorMode())return null==(i=this.sourceEditor)||i.insertRaw(t),this.toWYSIWYG(),!1}fromWYSIWYG(t=!1){if(!this.__lock||!0===t){this.__lock=!0;let t=this.j.getEditorValue(!1,o.SOURCE_CONSUMER);t!==this.getMirrorValue()&&this.setMirrorValue(t),this.__lock=!1}}toWYSIWYG(){if(this.__lock)return;let t=this.getMirrorValue();t!==this.__oldMirrorValue&&(this.__lock=!0,this.j.value=t,this.__lock=!1,this.__oldMirrorValue=t)}getNormalPosition(t,i){for(i=i.replace(/<(script|style|iframe)[^>]*>[^]*?<\/\1>/im,t=>{let i="";for(let n=0;n<t.length;n+=1)i+=o.INVISIBLE_SPACE;return i});t>0&&i[t]===o.INVISIBLE_SPACE;)t--;let n=t;for(;n>0;){if("<"===i[--n]&&void 0!==i[n+1]&&i[n+1].match(/[\w/]+/i))return n;if(">"===i[n])break}return t}clnInv(t){return t.replace(o.INVISIBLE_SPACE_REG_EXP(),"")}onSelectAll(t){var i;if("selectall"===t.toLowerCase()&&this.j.getRealMode()===o.MODE_SOURCE)return null==(i=this.sourceEditor)||i.selectAll(),!1}getMirrorValue(){var t;return(null==(t=this.sourceEditor)?void 0:t.getValue())||""}setMirrorValue(t){var i;null==(i=this.sourceEditor)||i.setValue(t)}setFocusToMirror(){var t;let i=this.j.od.activeElement;(!i||i===this.j.od.body||this.j.container.contains(i))&&(null==(t=this.sourceEditor)||t.focus())}saveSelection(){if(this.j.getRealMode()===o.MODE_WYSIWYG)this.j.s.save(),this.j.synchronizeValues(),this.fromWYSIWYG(!0);else{if(this.j.o.editHTMLDocumentMode)return;let t=this.getMirrorValue();if(this.getSelectionStart()===this.getSelectionEnd()){let i=this.j.s.marker(!0),n=this.getNormalPosition(this.getSelectionStart(),this.getMirrorValue());this.setMirrorValue(t.substring(0,n)+this.clnInv(i.outerHTML)+t.substring(n))}else{let i=this.j.s.marker(!0),n=this.j.s.marker(!1),o=this.getNormalPosition(this.getSelectionStart(),t),r=this.getNormalPosition(this.getSelectionEnd(),t);this.setMirrorValue(t.slice(0,o)+this.clnInv(i.outerHTML)+t.slice(o,r)+this.clnInv(n.outerHTML)+t.slice(r))}this.toWYSIWYG()}}removeSelection(){if(this.j.getRealMode()===o.MODE_WYSIWYG){this.__lock=!0,this.j.s.restore(),this.__lock=!1;return}let t=this.getMirrorValue(),i=0,n=0;try{if(t=t.replace(/<span[^>]+data-jodit-selection_marker=(["'])start\1[^>]*>[<>]*?<\/span>/gim,this.tempMarkerStart).replace(/<span[^>]+data-jodit-selection_marker=(["'])end\1[^>]*>[<>]*?<\/span>/gim,this.tempMarkerEnd),!this.j.o.editHTMLDocumentMode&&this.j.o.beautifyHTML){let i=this.j.e.fire("beautifyHTML",t);(0,l.isString)(i)&&(t=i)}if(n=i=t.indexOf(this.tempMarkerStart),t=t.replace(this.tempMarkerStartReg,""),-1!==i){let i=t.indexOf(this.tempMarkerEnd);-1!==i&&(n=i)}t=t.replace(this.tempMarkerEndReg,"")}finally{t=t.replace(this.tempMarkerEndReg,"").replace(this.tempMarkerStartReg,"")}this.setMirrorValue(t),this.setMirrorSelectionRange(i,n),this.toWYSIWYG(),this.setFocusToMirror()}setMirrorSelectionRange(t,i){var n;null==(n=this.sourceEditor)||n.setSelectionRange(t,i)}onReadonlyReact(){var t;null==(t=this.sourceEditor)||t.setReadOnly(this.j.o.readonly)}afterInit(t){if(this.mirrorContainer=t.c.div("jodit-source"),t.workplace.appendChild(this.mirrorContainer),t.e.on("afterAddPlace changePlace afterInit",()=>{t.workplace.appendChild(this.mirrorContainer)}),this.sourceEditor=(0,d.createSourceEditor)("area",t,this.mirrorContainer,this.toWYSIWYG,this.fromWYSIWYG),t.e.on(t.ow,"keydown",t=>{var i;t.key===o.KEY_ESC&&(null==(i=this.sourceEditor)?void 0:i.isFocused)&&this.sourceEditor.blur()}),this.onReadonlyReact(),t.e.on("placeholder.source",t=>{var i;null==(i=this.sourceEditor)||i.setPlaceHolder(t)}).on("change.source",this.syncValueFromWYSIWYG).on("beautifyHTML",t=>t),t.o.beautifyHTML){let i=()=>{var i;if(t.isInDestruct)return!1;let n=t.ow.html_beautify;return!!n&&!t.isInDestruct&&(null==(i=t.events)||i.off("beautifyHTML").on("beautifyHTML",t=>n(t)),!0)};i()||(0,l.loadNext)(t,t.o.beautifyHTMLCDNUrlsJS).then(i,()=>null)}this.syncValueFromWYSIWYG(!0),this.initSourceEditor(t)}syncValueFromWYSIWYG(t=!1){let i=this.j;(i.getMode()===o.MODE_SPLIT||i.getMode()===o.MODE_SOURCE)&&this.fromWYSIWYG(t)}initSourceEditor(t){var i;if("area"!==t.o.sourceEditor){let i=(0,d.createSourceEditor)(t.o.sourceEditor,t,this.mirrorContainer,this.toWYSIWYG,this.fromWYSIWYG);i.onReadyAlways(()=>{var n,o;null==(n=this.sourceEditor)||n.destruct(),this.sourceEditor=i,this.syncValueFromWYSIWYG(!0),null==(o=t.events)||o.fire("sourceEditorReady",t)})}else null==(i=this.sourceEditor)||i.onReadyAlways(()=>{var i;this.syncValueFromWYSIWYG(!0),null==(i=t.events)||i.fire("sourceEditorReady",t)})}beforeDestruct(){this.sourceEditor&&(this.sourceEditor.destruct(),delete this.sourceEditor),s.Dom.safeRemove(this.mirrorContainer)}constructor(){super(...arguments),this.buttons=[{name:"source",group:"source"}],this.__lock=!1,this.__oldMirrorValue="",this.tempMarkerStart="{start-jodit-selection}",this.tempMarkerStartReg=/{start-jodit-selection}/g,this.tempMarkerEnd="{end-jodit-selection}",this.tempMarkerEndReg=/{end-jodit-selection}/g,this.getSelectionStart=()=>{var t,i;return null!=(i=null==(t=this.sourceEditor)?void 0:t.getSelectionStart())?i:0},this.getSelectionEnd=()=>{var t,i;return null!=(i=null==(t=this.sourceEditor)?void 0:t.getSelectionEnd())?i:0}}}u([(0,r.watch)(":insertHTML.source")],h.prototype,"onInsertHTML",null),u([r.autobind],h.prototype,"fromWYSIWYG",null),u([r.autobind],h.prototype,"toWYSIWYG",null),u([r.autobind],h.prototype,"getNormalPosition",null),u([(0,r.watch)(":beforeCommand.source")],h.prototype,"onSelectAll",null),u([(0,r.watch)(":beforeSetMode.source")],h.prototype,"saveSelection",null),u([(0,r.watch)(":afterSetMode.source")],h.prototype,"removeSelection",null),u([r.autobind],h.prototype,"setMirrorSelectionRange",null),u([(0,r.watch)(":readonly.source")],h.prototype,"onReadonlyReact",null),u([r.autobind],h.prototype,"syncValueFromWYSIWYG",null),a.pluginSystem.add("source",h)},35599:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M553 1399l-50 50q-10 10-23 10t-23-10l-466-466q-10-10-10-23t10-23l466-466q10-10 23-10t23 10l50 50q10 10 10 23t-10 23l-393 393 393 393q10 10 10 23t-10 23zm591-1067l-373 1291q-4 13-15.5 19.5t-23.5 2.5l-62-17q-13-4-19.5-15.5t-2.5-24.5l373-1291q4-13 15.5-19.5t23.5-2.5l62 17q13 4 19.5 15.5t2.5 24.5zm657 651l-466 466q-10 10-23 10t-23-10l-50-50q-10-10-10-23t10-23l393-393-393-393q-10-10-10-23t10-23l50-50q10-10 23-10t23 10l466 466q10 10 10 23t-10 23z"/> </svg> '},46614:function(t,i,n){"use strict";var o=n(87612),r=n(70799),s=n(29960),a=n(86583),l=n(12153),c=n(6441),d=n(26532),u=n(93602),h=n(75259);c.Config.prototype.speechRecognize={api:void 0!==d.SpeechRecognition?d.SpeechRecognition:null,sound:!0,continuous:!1,interimResults:!0,commands:{"newline|enter":"enter","delete|remove word|delete word":"backspaceWordButton",comma:"inserthtml::,",underline:"inserthtml::_",hyphen:"inserthtml::-",space:"inserthtml:: ",question:"inserthtml::?",dot:"inserthtml::.","quote|quotes|open quote":"inserthtml::'","header|header h1":"formatblock::h1","select all":"selectall"}},l.Icon.set("speech-recognize",h.default),c.Config.prototype.controls.speechRecognize={isVisible:t=>!!t.o.speechRecognize.api,isActive(t,i){let n=(0,a.dataBind)(t,"speech");return!!(null==n?void 0:n.isEnabled)},isDisabled:t=>!t.o.speechRecognize.api,exec(t,i,{button:n,control:l}){var c;let{api:d,lang:h,continuous:p,interimResults:f,sound:m}=t.o.speechRecognize;if(!d)return void t.alert("Speech recognize API unsupported in your browser");let g=(0,a.dataBind)(t,"speech");if(!g){let i=new d;(g=new u.RecognizeManager(t.async,i)).lang=(0,r.isString)(h)?h:null!=(c=(0,s.attr)(t.od.documentElement,"lang"))?c:void 0,g.continuous=p,g.interimResults=f,g.sound=m,(0,a.dataBind)(t,"speech",g),g.on("pulse",t=>{n.setMod("pulse",t)}),g.on("result",i=>t.e.fire("speechRecognizeResult",i)),g.on("progress",i=>t.e.fire("speechRecognizeProgressResult",i)),g.on("error",i=>t.message.error(i)),t.hookStatus("beforeDestruct",()=>{(0,a.dataBind)(t,"speech",null),g.destruct()})}if(l.args){let t=l.args[0];if((0,o.isBoolean)(g[t])){g[t]=!g[t],g.isEnabled&&g.restart();return}}g.toggle(),g.isEnabled&&n.setMod("pulse",!0),n.state.activated=g.isEnabled},name:"speechRecognize",command:"toggleSpeechRecognize",tooltip:"Speech Recognize",list:{sound:"Sound",interimResults:"Interim Results"},childTemplate(t,i,n){var o;let r=(0,a.dataBind)(t,"speech"),s=null!=(o=null==r?void 0:r[i])?o:t.o.speechRecognize[i];return`<span class='jodit-speech-recognize__list-item'><input ${s?"checked":""} class='jodit-checkbox' type='checkbox'> ${n}</span>`},mods:{stroke:!1}}},85567:function(t,i,n){"use strict";n.d(i,{PII:function(){return o},WARN:function(){return r}});let o=440,r=940},26532:function(t,i,n){"use strict";n.d(i,{SpeechRecognition:function(){return r}});var o=n(82758);let r=o.globalWindow?o.globalWindow.SpeechRecognition||o.globalWindow.webkitSpeechRecognition:void 0},54076:function(t,i,n){"use strict";function o(t,i){let[n,o]=i.split("::");"open"===n.toLowerCase()&&o&&/^(javascript:|data:|vbscript:)/i.test(o.trim())||t.execCommand(n,null,o)}n.d(i,{execSpellCommand:function(){return o}})},93602:function(t,i,n){"use strict";n.d(i,{RecognizeManager:function(){return c}});var o=n(65478),r=n(72757),s=n(37643),a=n(85567),l=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a};class c extends r.Eventify{set lang(t){this._lang=t,this._api.lang=t}get lang(){return this._lang}set continuous(t){this._continuous=t,this._api.continuous=t}get continuous(){return this._continuous}set interimResults(t){this._interimResults=t,this._api.interimResults=t}get interimResults(){return this._interimResults}destruct(){this.stop(),(0,s.closeSound)(this),c._instances.delete(this),super.destruct()}get isEnabled(){return this._isEnabled}start(){if(!this._isEnabled){this._isEnabled=!0,c._instances.forEach(t=>{t!==this&&t.stop()});try{this._api.start()}catch(t){this._onError(t),this.stop();return}this.__on("speechstart",this._onSpeechStart).__on("error",this._onError).__on("result",this._onProgress).__on("end",this._onResults)}}stop(){this._isEnabled&&(this._api.abort(),this._api.stop(),this.__off("speechstart",this._onSpeechStart).__off("error",this._onError).__off("result",this._onProgress).__off("end",this._onResults),this.async.clearTimeout(this._restartTimeout),this._isEnabled=!1,this.emit("pulse",!1))}toggle(){this._isEnabled?this.stop():this.start()}restart(){this.stop(),this.start()}__on(t,i){return this._api.addEventListener(t,i),this}__off(t,i){return this._api.removeEventListener(t,i),this}_onResults(t){this.emit("pulse",!1),this.emit("result",this.__interimResults),this.__interimResults="",this._makeSound(a.PII),this.restart()}_onProgress(t){if(this._isEnabled&&(this.__interimResults="",t.results)){for(let i=0;i<t.results.length;i++){let n=t.results.item(i);if(n.length){let{transcript:t}=n.item(0);this.__interimResults+=t}}this.__interimResults&&this.emit("progress",this.__interimResults)}}_onError(t){"voice-unavailable"===t.error&&this.emit("error","Voice unavailable"),"not-allowed"===t.error&&this.emit("error","Not allowed"),("language-unavailable"===t.error||"language-not-supported"===t.error)&&this.emit("error","Language unavailable"),this._makeSound(a.WARN),this.emit("pulse",!1),this.stop()}_makeSound(t){this.sound&&(0,s.sound)(this,{frequency:t})}constructor(t,i){super(),this.async=t,this._continuous=!1,this._interimResults=!1,this.sound=!0,this._isEnabled=!1,this._restartTimeout=0,this._onSpeechStart=t=>{this._isEnabled&&(this.async.clearTimeout(this._restartTimeout),this._restartTimeout=this.async.setTimeout(()=>{this.restart(),this.emit("pulse",!1),this._makeSound(a.WARN)},5e3),this.emit("pulse",!0))},this.__interimResults="",this._api=i,c._instances.add(this)}}c._instances=new Set,l([o.autobind],c.prototype,"_onResults",null),l([o.autobind],c.prototype,"_onProgress",null),l([o.autobind],c.prototype,"_onError",null)},37643:function(t,i,n){"use strict";n.d(i,{closeSound:function(){return l},sound:function(){return a}});var o=n(82758),r=n(85567);let s=new WeakMap;function a(t,{sec:i=.1,frequency:n=r.PII,gain:l=.1,type:c="sine"}={}){let d=function(t){if(!o.globalWindow)return null;let i=s.get(t);if(i&&"closed"!==i.state)return i;let n=o.globalWindow.AudioContext||o.globalWindow.webkitAudioContext;if(!n)return null;let r=new n;return s.set(t,r),r}(t);if(!d)return;let u=d.createGain(),h=d.createOscillator();h.type=c,h.frequency.value=n,u.gain.value=l,h.connect(u),u.connect(d.destination),h.start(),h.stop(d.currentTime+i)}function l(t){let i=s.get(t);i&&(s.delete(t),"closed"!==i.state&&i.close())}},71705:function(t,i,n){"use strict";n.r(i),i.default={newline:"الخط الجديد",delete:"حذف",space:"الفضاء","Speech Recognize":"التعرف على الكلام",Sound:"الصوت","Interim Results":"النتائج المؤقتة"}},89930:function(t,i,n){"use strict";n.r(i),i.default={newline:"řádek",delete:"odstranit",space:"prostora","Speech Recognize":"Rozpoznání Řeči",Sound:"Zvuk","Interim Results":"Průběžné Výsledky"}},34945:function(t,i,n){"use strict";n.r(i),i.default={newline:"Zeilenumbruch",delete:"löschen",space:"Raum","Speech Recognize":"Sprache Erkennen",Sound:"Sound","Interim Results":"Zwischenergebnis"}},63134:function(t,i,n){"use strict";n.r(i),i.default={newline:"nueva línea",delete:"eliminar",space:"espacio","Speech Recognize":"Reconocimiento de Voz",Sound:"Sonido","Interim Results":"Resultados Provisionales"}},66835:function(t,i,n){"use strict";n.r(i),i.default={newline:"خط جدید",delete:"حذف",space:"فضا","Speech Recognize":"گفتار را تشخیص دهید",Sound:"صدا","Interim Results":"نتایج موقت"}},1115:function(t,i,n){"use strict";n.r(i),i.default={"Speech Recognize":"Puheentunnistus",newline:"uusi rivi",delete:"poistaa",space:"tilaa",Sound:"Ääni","Interim Results":"Välitulokset"}},59302:function(t,i,n){"use strict";n.r(i),i.default={newline:"nouvelle ligne",delete:"supprimer",space:"espace","Speech Recognize":"Reconnaissance Vocale",Sound:"Son","Interim Results":"Résultats Intermédiaires"}},94141:function(t,i,n){"use strict";n.r(i),i.default={newline:"חדשות",delete:"מחק",space:"שטח","Speech Recognize":"דיבור מזהה",Sound:"קול","Interim Results":"תוצאות ביניים"}},24877:function(t,i,n){"use strict";n.r(i),i.default={newline:"újsor",delete:"törlés",space:"tér","Speech Recognize":"A Beszéd Felismeri",Sound:"Hang","Interim Results":"Időközi Eredmények"}},80651:function(t,i,n){"use strict";n.r(i),i.default={newline:"newline",delete:"Hapus",space:"ruang","Speech Recognize":"Pidato Mengenali",Sound:"Suara","Interim Results":"Hasil Sementara"}},90492:function(t,i,n){"use strict";n.r(i),n.d(i,{ar:function(){return o},cs_cz:function(){return r},de:function(){return s},es:function(){return a},fa:function(){return l},fi:function(){return c},fr:function(){return d},he:function(){return u},hu:function(){return h},id:function(){return p},it:function(){return f},ja:function(){return m},ko:function(){return g},mn:function(){return b},nl:function(){return y},no:function(){return w},pl:function(){return _},pt_br:function(){return C},ru:function(){return k},sk:function(){return S},tr:function(){return x},ua:function(){return I},zh_cn:function(){return E},zh_tw:function(){return T}});var o=n(71705),r=n(89930),s=n(34945),a=n(63134),l=n(66835),c=n(1115),d=n(59302),u=n(94141),h=n(24877),p=n(80651),f=n(62395),m=n(16407),g=n(37272),b=n(22113),y=n(22432),w=n(17081),_=n(30798),C=n(8661),k=n(19147),S=n(76220),x=n(93620),I=n(40372),E=n(69874),T=n(88774)},62395:function(t,i,n){"use strict";n.r(i),i.default={newline:"nuova riga",delete:"eliminare",space:"spazio","Speech Recognize":"Discorso Riconoscere",Sound:"Suono","Interim Results":"Risultati intermedi"}},16407:function(t,i,n){"use strict";n.r(i),i.default={newline:"改行",delete:"削除",space:"スペース","Speech Recognize":"音声認識",Sound:"音","Interim Results":"中間結果"}},37272:function(t,i,n){"use strict";n.r(i),i.default={newline:"줄 바꿈",delete:"삭제",space:"공간","Speech Recognize":"음성 인식",Sound:"소리","Interim Results":"중간 결과"}},22113:function(t,i,n){"use strict";n.r(i),i.default={newline:"Шинэ мөр",delete:"Устгах",space:"Зай","Speech Recognize":"Дуу хоолой таних",Sound:"Дуу","Interim Results":"Түр зуурын үр дүн"}},22432:function(t,i,n){"use strict";n.r(i),i.default={newline:"regel",delete:"verwijderen",space:"ruimte","Speech Recognize":"Spraak Herkennen",Sound:"Geluid","Interim Results":"Tussentijdse Resultaten"}},17081:function(t,i,n){"use strict";n.r(i),i.default={newline:"nylinje",delete:"slette",space:"rom","Speech Recognize":"Talegjenkjenning",Sound:"Lyd","Interim Results":"Midlertidige resultater"}},30798:function(t,i,n){"use strict";n.r(i),i.default={newline:"newline",delete:"usunąć",space:"przestrzeń","Speech Recognize":"Rozpoznawanie Mowy",Sound:"Dźwięk","Interim Results":"Wyniki Okresowe"}},8661:function(t,i,n){"use strict";n.r(i),i.default={newline:"linha",delete:"excluir",space:"espaco","Speech Recognize":"Discurso Reconhecer",Sound:"Som","Interim Results":"Resultados Provisórios"}},19147:function(t,i,n){"use strict";n.r(i),i.default={newline:"новая строка|перенос|энтер",delete:"удалить",space:"пробел","Speech Recognize":"Распознавание речи",Sound:"Звук","Interim Results":"Промежуточные результаты"}},76220:function(t,i,n){"use strict";n.r(i),i.default={newline:"nový riadok",delete:"vymazať",space:"medzera","Speech Recognize":"Rozpoznávanie reči",Sound:"Zvuk","Interim Results":"Predbežné výsledky"}},93620:function(t,i,n){"use strict";n.r(i),i.default={newline:"yeni satır",delete:"silmek",space:"uzay","Speech Recognize":"Konuşma Tanıma",Sound:"Ses","Interim Results":"Ara Sonuçlar"}},40372:function(t,i,n){"use strict";n.r(i),i.default={newline:"новая строка|перенос|ентер",delete:"видалити",space:"пробел","Speech Recognize":"Распознавание речи",Sound:"Звук","Interim Results":"Проміжні результати"}},69874:function(t,i,n){"use strict";n.r(i),i.default={newline:"新行",delete:"删除",space:"空间","Speech Recognize":"言语识别",Sound:"声音","Interim Results":"中期业绩"}},88774:function(t,i,n){"use strict";n.r(i),i.default={newline:"換行",delete:"刪除",space:"空白","Speech Recognize":"語音辨識",Sound:"聲音","Interim Results":"階段性辨識結果"}},3115:function(t,i,n){"use strict";var o=n(37133),r=n(2748),s=n(580),a=n(37790),l=n(50911);n(46614);var c=n(2303),d=n(54076),u=n(90492),h=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a};class p extends l.Plugin{afterInit(t){let{commands:i}=t.o.speechRecognize;i&&((0,s.extendLang)(u),(0,a.keys)(i,!1).forEach(n=>{n.split("|").forEach(o=>{o=o.trim().toLowerCase(),this._commandToWord[o]=i[n];let r=t.i18n(o);r!==o&&r.split("|").forEach(t=>{this._commandToWord[t.trim().toLowerCase()]=i[n].trim()})})}))}beforeDestruct(t){r.Dom.safeRemove(this.messagePopup)}onSpeechRecognizeProgressResult(t){this.messagePopup||(this.messagePopup=this.j.create.div("jodit-speech-recognize__popup")),this.j.workplace.appendChild(this.messagePopup),this.j.async.clearTimeout(this.__hidePopupTimeout),this.__hidePopupTimeout=this.j.async.setTimeout(()=>{r.Dom.safeRemove(this.messagePopup)},1e3),this.messagePopup.innerText=t+"|"}onSpeechRecognizeResult(t){this.j.async.clearTimeout(this.__hidePopupTimeout),r.Dom.safeRemove(this.messagePopup);let{j:i}=this,{s:n}=i;if(!this._checkCommand(t)){let{range:o}=n,s=n.current();if(n.isCollapsed()&&r.Dom.isText(s)&&r.Dom.isOrContains(i.editor,s)&&s.nodeValue){let r=s.nodeValue;s.nodeValue=r+(/[\u00A0 ]\uFEFF*$/.test(r)?"":" ")+t,o.setStartAfter(s),n.selectRange(o),i.synchronizeValues()}else n.insertHTML(t)}}_checkCommand(t){return t=t.toLowerCase().replace(/\./g,""),!!this._commandToWord[t]&&((0,d.execSpellCommand)(this.j,this._commandToWord[t]),!0)}constructor(){super(...arguments),this.buttons=[{group:"state",name:"speechRecognize"}],this._commandToWord={}}}h([(0,o.watch)(":speechRecognizeProgressResult")],p.prototype,"onSpeechRecognizeProgressResult",null),h([(0,o.watch)(":speechRecognizeResult")],p.prototype,"onSpeechRecognizeResult",null),c.Jodit.plugins.add("speech-recognize",p)},75259:function(t,i){"use strict";i.default='<svg viewBox="0 0 16 16" xml:space="preserve" xmlns="http://www.w3.org/2000/svg"> <path d="M8,11c1.657,0,3-1.343,3-3V3c0-1.657-1.343-3-3-3S5,1.343,5,3v5C5,9.657,6.343,11,8,11z"/> <path d="M13,8V6h-1l0,1.844c0,1.92-1.282,3.688-3.164,4.071C6.266,12.438,4,10.479,4,8V6H3v2c0,2.414,1.721,4.434,4,4.899V15H5v1h6 v-1H9v-2.101C11.279,12.434,13,10.414,13,8z"/> </svg> '},99085:function(t,i,n){"use strict";var o=n(12153),r=n(6441),s=n(10937);r.Config.prototype.spellcheck=!1,o.Icon.set("spellcheck",s.default),r.Config.prototype.controls.spellcheck={isActive:t=>t.o.spellcheck,icon:s.default,name:"spellcheck",command:"toggleSpellcheck",tooltip:"Spellcheck"}},28906:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"التدقيق الإملائي"}},24351:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Kontrola pravopisu"}},32806:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Rechtschreibprüfung"}},77725:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Corrección ortográfica"}},26428:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"غلطیابی املایی"}},42820:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Oikeinkirjoituksen tarkistus"}},60373:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Vérification Orthographique"}},98370:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"בדיקת איות"}},44850:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Helyesírás-ellenőrzés"}},3636:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Spellchecking"}},26529:function(t,i,n){"use strict";n.r(i),n.d(i,{ar:function(){return o},cs_cz:function(){return r},de:function(){return s},es:function(){return a},fa:function(){return l},fi:function(){return c},fr:function(){return d},he:function(){return u},hu:function(){return h},id:function(){return p},it:function(){return f},ja:function(){return m},ko:function(){return g},mn:function(){return b},nl:function(){return y},no:function(){return w},pl:function(){return _},pt_br:function(){return C},ru:function(){return k},sk:function(){return S},tr:function(){return x},ua:function(){return I},zh_cn:function(){return E},zh_tw:function(){return T}});var o=n(28906),r=n(24351),s=n(32806),a=n(77725),l=n(26428),c=n(42820),d=n(60373),u=n(98370),h=n(44850),p=n(3636),f=n(73220),m=n(55776),g=n(13995),b=n(6402),y=n(1879),w=n(1322),_=n(53361),C=n(70824),k=n(65140),S=n(60407),x=n(42247),I=n(68891),E=n(63195),T=n(42107)},73220:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Controllo ortografico"}},55776:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"スペルチェック"}},13995:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"맞춤법 검사"}},6402:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Дүрмийн алдаа шалгах"}},1879:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Spellingcontrole"}},1322:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Stavekontroll"}},53361:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Sprawdzanie pisowni"}},70824:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Verificação ortográfica"}},65140:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Проверка орфографии"}},60407:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Kontrola pravopisu"}},42247:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Yazım denetimi"}},68891:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"Перевірка орфографії"}},63195:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"拼写检查"}},42107:function(t,i,n){"use strict";n.r(i),i.default={Spellcheck:"拼字檢查"}},43809:function(t,i,n){"use strict";var o=n(65478),r=n(580),s=n(29960),a=n(50911);n(99085);var l=n(26529);class c extends a.Plugin{afterInit(t){t.e.on("afterInit afterAddPlace prepareWYSIWYGEditor",this.toggleSpellcheck),this.toggleSpellcheck(),t.registerCommand("toggleSpellcheck",()=>{this.jodit.o.spellcheck=!this.jodit.o.spellcheck,this.toggleSpellcheck(),this.j.e.fire("updateToolbar")})}toggleSpellcheck(){(0,s.attr)(this.jodit.editor,"spellcheck",this.jodit.o.spellcheck)}beforeDestruct(t){}constructor(t){super(t),this.buttons=[{group:"state",name:"spellcheck"}],(0,r.extendLang)(l)}}!function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);s>3&&a&&Object.defineProperty(i,n,a)}([o.autobind],c.prototype,"toggleSpellcheck",null),r.pluginSystem.add("spellcheck",c)},10937:function(t,i){"use strict";i.default='<svg viewBox="0 0 48 48" xmlns="http://www.w3.org/2000/svg"> <path d="M24.89 32h4.18L18.86 6h-3.71L4.93 32h4.18l2.25-6h11.29l2.24 6zM12.86 22L17 10.95 21.14 22h-8.28zm30.31 1.17L27 39.34 19.66 32l-2.83 2.83L27 45l19-19-2.83-2.83z"/> </svg> '},99649:function(t,i,n){"use strict";var o=n(6441);o.Config.prototype.showCharsCounter=!0,o.Config.prototype.countHTMLChars=!1,o.Config.prototype.countTextSpaces=!1,o.Config.prototype.showWordsCounter=!0},7309:function(t,i,n){"use strict";var o=n(82758),r=n(2748),s=n(580),a=n(20356);n(99649);class l extends a.Plugin{afterInit(){this.charCounter=this.j.c.span(),this.wordCounter=this.j.c.span(),this.j.e.on("afterInit changePlace afterAddPlace",this.reInit),this.reInit()}beforeDestruct(){r.Dom.safeRemove(this.charCounter),r.Dom.safeRemove(this.wordCounter),this.j.e.off("afterInit changePlace afterAddPlace",this.reInit),this.charCounter=null,this.wordCounter=null}constructor(){super(...arguments),this.charCounter=null,this.wordCounter=null,this.reInit=()=>{this.j.o.showCharsCounter&&this.charCounter&&this.j.statusbar.append(this.charCounter,!0),this.j.o.showWordsCounter&&this.wordCounter&&this.j.statusbar.append(this.wordCounter,!0),this.j.e.off("change keyup",this.calc).on("change keyup",this.calc),this.calc()},this.calc=this.j.async.throttle(()=>{let t=this.j.text;if(this.j.o.showCharsCounter&&this.charCounter){let i;i=this.j.o.countHTMLChars?this.j.value:this.j.o.countTextSpaces?t.replace((0,o.INVISIBLE_SPACE_REG_EXP)(),"").replace(/[\r\n]/g,""):t.replace((0,o.SPACE_REG_EXP)(),""),this.charCounter.textContent=this.j.i18n("Chars: %d",i.length)}this.j.o.showWordsCounter&&this.wordCounter&&(this.wordCounter.textContent=this.j.i18n("Words: %d",t.replace((0,o.INVISIBLE_SPACE_REG_EXP)(),"").split((0,o.SPACE_REG_EXP)()).filter(t=>t.length).length))},this.j.defaultTimeout)}}s.pluginSystem.add("stat",l)},48038:function(t,i,n){"use strict";var o=n(6441);o.Config.prototype.toolbarSticky=!0,o.Config.prototype.toolbarDisableStickyForMobile=!0,o.Config.prototype.toolbarStickyOffset=0},68687:function(t,i,n){"use strict";var o=n(82758),r=n(65478),s=n(2748),a=n(580),l=n(21537),c=n(20356);n(48038);let d=!o.IS_ES_NEXT&&o.IS_IE;class u extends c.Plugin{afterInit(t){t.e.on(t.ow,"scroll.sticky wheel.sticky mousewheel.sticky resize.sticky",this.__onScroll).on("getStickyState.sticky",()=>this.__isToolbarStuck)}__onScroll(){let{jodit:t}=this;if(!t.o.toolbarSticky||!t.o.toolbar)return;let i=t.ow.pageYOffset||t.od.documentElement&&t.od.documentElement.scrollTop||0,n=(0,l.offset)(t.container,t,t.od,!0),r=t.getMode()===o.MODE_WYSIWYG&&i+t.o.toolbarStickyOffset>n.top&&i+t.o.toolbarStickyOffset<n.top+n.height&&!(t.o.toolbarDisableStickyForMobile&&this.__isMobile());if(this.__isToolbarStuck===r)return;let s=t.toolbarContainer;s&&(r?this.addSticky(s):this.removeSticky(s)),t.e.fire("toggleSticky",r)}__isMobile(){let{j:t}=this;return t&&t.options&&t.container&&t.options.sizeSM>=t.container.offsetWidth}beforeDestruct(t){s.Dom.safeRemove(this.__dummyBox),t.e.off(t.ow,"scroll.sticky wheel.sticky mousewheel.sticky resize.sticky",this.__onScroll).off(".sticky")}constructor(){super(...arguments),this.__isToolbarStuck=!1,this.__createDummy=t=>{this.__dummyBox=this.j.c.div(),this.__dummyBox.classList.add("jodit_sticky-dummy_toolbar"),this.j.container.insertBefore(this.__dummyBox,t)},this.addSticky=t=>{this.__isToolbarStuck||(d&&!this.__dummyBox&&this.__createDummy(t),this.j.container.classList.add("jodit_sticky"),this.__isToolbarStuck=!0),(0,l.css)(t,{top:this.j.o.toolbarStickyOffset||null,width:this.j.container.offsetWidth-2}),this.__dummyBox&&(0,l.css)(this.__dummyBox,{height:t.offsetHeight})},this.removeSticky=t=>{this.__isToolbarStuck&&((0,l.css)(t,{width:"",top:""}),this.j.container.classList.remove("jodit_sticky"),this.__isToolbarStuck=!1)}}}!function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);s>3&&a&&Object.defineProperty(i,n,a)}([(0,r.throttle)()],u.prototype,"__onScroll",null),a.pluginSystem.add("sticky",u)},87394:function(t,i,n){"use strict";var o=n(12153),r=n(6441),s=n(5119);r.Config.prototype.usePopupForSpecialCharacters=!1,r.Config.prototype.specialCharacters=["!",""","#","$","%","&","'","(",")","*","+","-",".","/","0","1","2","3","4","5","6","7","8","9",":",";","<","=",">","?","@","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z","[","]","^","_","`","a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z","{","|","}","~","€","‘","’","“","”","–","—","¡","¢","£","¤","¥","¦","§","¨","©","ª","«","»","¬","®","¯","°","²","³","´","µ","¶","·","¸","¹","º","¼","½","¾","¿","À","Á","Â","Ã","Ä","Å","Æ","Ç","È","É","Ê","Ë","Ì","Í","Î","Ï","Ð","Ñ","Ò","Ó","Ô","Õ","Ö","×","Ø","Ù","Ú","Û","Ü","Ý","Þ","ß","à","á","â","ã","ä","å","æ","ç","è","é","ê","ë","ì","í","î","ï","ð","ñ","ò","ó","ô","õ","ö","÷","ø","ù","ú","û","ü","ý","þ","ÿ","Œ","œ","Ŵ","Ŷ","ŵ","ŷ","‚","‛","„","…","™","►","•","→","⇒","⇔","♦","≈"],o.Icon.set("symbols",s.default),r.Config.prototype.controls.symbols={hotkeys:["ctrl+shift+i","cmd+shift+i"],tooltip:"Insert Special Character",popup(t,i,n){let o=t.e.fire("generateSpecialCharactersTable.symbols");if(o){if(t.o.usePopupForSpecialCharacters){let i=t.c.div();return i.classList.add("jodit-symbols"),i.appendChild(o),t.e.on(o,"close_dialog",n),i}t.alert(o,"Select Special Character",void 0,"jodit-symbols").bindDestruct(t);let i=o.querySelector("a");i&&i.focus()}}}},20741:function(t,i,n){"use strict";n.r(i),i.default={symbols:"رمز"}},3958:function(t,i,n){"use strict";n.r(i),i.default={symbols:"symbol"}},53437:function(t,i,n){"use strict";n.r(i),i.default={symbols:"Symbol"}},56882:function(t,i,n){"use strict";n.r(i),i.default={symbols:"Símbolo"}},75703:function(t,i,n){"use strict";n.r(i),i.default={symbols:"سمبل"}},49759:function(t,i,n){"use strict";n.r(i),i.default={symbols:"Symbolit"}},44730:function(t,i,n){"use strict";n.r(i),i.default={symbols:"caractère"}},70945:function(t,i,n){"use strict";n.r(i),i.default={symbols:"תו מיוחד"}},49841:function(t,i,n){"use strict";n.r(i),i.default={symbols:"Szimbólum"}},33295:function(t,i,n){"use strict";n.r(i),i.default={symbols:"simbol"}},32824:function(t,i,n){"use strict";n.r(i),n.d(i,{ar:function(){return o},cs_cz:function(){return r},de:function(){return s},es:function(){return a},fa:function(){return l},fi:function(){return c},fr:function(){return d},he:function(){return u},hu:function(){return h},id:function(){return p},it:function(){return f},ja:function(){return m},ko:function(){return g},mn:function(){return b},nl:function(){return y},pl:function(){return w},pt_br:function(){return _},ru:function(){return C},tr:function(){return k},ua:function(){return S},zh_cn:function(){return x},zh_tw:function(){return I}});var o=n(20741),r=n(3958),s=n(53437),a=n(56882),l=n(75703),c=n(49759),d=n(44730),u=n(70945),h=n(49841),p=n(33295),f=n(47615),m=n(83059),g=n(22396),b=n(58285),y=n(51804),w=n(53650),_=n(41369),C=n(57855),k=n(44328),S=n(91080),x=n(89702),I=n(66434)},47615:function(t,i,n){"use strict";n.r(i),i.default={symbols:"Simbolo"}},83059:function(t,i,n){"use strict";n.r(i),i.default={symbols:"symbol"}},22396:function(t,i,n){"use strict";n.r(i),i.default={symbols:"기호"}},58285:function(t,i,n){"use strict";n.r(i),i.default={symbols:"тэмдэгт"}},51804:function(t,i,n){"use strict";n.r(i),i.default={symbols:"symbool"}},53650:function(t,i,n){"use strict";n.r(i),i.default={symbols:"symbol"}},41369:function(t,i,n){"use strict";n.r(i),i.default={symbols:"Símbolo"}},57855:function(t,i,n){"use strict";n.r(i),i.default={symbols:"символ"}},44328:function(t,i,n){"use strict";n.r(i),i.default={symbols:"Sembol"}},91080:function(t,i,n){"use strict";n.r(i),i.default={symbols:"символ"}},89702:function(t,i,n){"use strict";n.r(i),i.default={symbols:"符号"}},66434:function(t,i,n){"use strict";n.r(i),i.default={symbols:"符號"}},59495:function(t,i,n){"use strict";var o=n(82758),r=n(2748),s=n(580),a=n(43555),l=n(20356);n(87394);var c=n(32824);class d extends l.Plugin{afterInit(t){t.e.on("generateSpecialCharactersTable.symbols",()=>{let i=t.c.fromHTML(`<div class="jodit-symbols__container">
|
|
267
267
|
<div class="jodit-symbols__container_table">
|
|
268
268
|
<table class="jodit-symbols__table"><tbody></tbody></table>
|
|
269
269
|
</div>
|
|
@@ -275,10 +275,10 @@
|
|
|
275
275
|
data-index-j="${o}"
|
|
276
276
|
role="option"
|
|
277
277
|
tabindex="-1"
|
|
278
|
-
>${t.o.specialCharacters[i]}</a>`);l.push(s),r.appendChild(s),n.appendChild(r)}s.appendChild(n)}let c=this;return t.e.on(l,"focus",function(){n.innerHTML=this.innerHTML}).on(l,"mousedown",function(i){r.Dom.isTag(this,"a")&&(t.s.focus(),t.s.insertHTML(this.innerHTML),(null==i?void 0:i.shiftKey)||t.e.fire(this,"close_dialog"),i&&i.preventDefault(),i&&i.stopImmediatePropagation())}).on(l,"mouseenter",function(){r.Dom.isTag(this,"a")&&this.focus()}).on(l,"keydown",i=>{let n=i.target;if(r.Dom.isTag(n,"a")){let r,s=parseInt((0,a.attr)(n,"-index")||"0",10),d=parseInt((0,a.attr)(n,"data-index-j")||"0",10);switch(i.key){case o.KEY_UP:case o.KEY_DOWN:void 0===l[r=i.key===o.KEY_UP?s-c.__countInRow:s+c.__countInRow]&&(r=i.key===o.KEY_UP?Math.floor(l.length/c.__countInRow)*c.__countInRow+d:d)>l.length-1&&(r-=c.__countInRow),l[r]&&l[r].focus();break;case o.KEY_RIGHT:case o.KEY_LEFT:void 0===l[r=i.key===o.KEY_LEFT?s-1:s+1]&&(r=i.key===o.KEY_LEFT?l.length-1:0),l[r]&&l[r].focus();break;case o.KEY_ENTER:t.e.fire(n,"mousedown"),i.stopImmediatePropagation(),i.preventDefault()}}}),i})}beforeDestruct(t){t.e.off("generateSpecialCharactersTable.symbols")}constructor(t){super(t),this.buttons=[{name:"symbols",group:"insert"}],this.__countInRow=17,(0,s.extendLang)(c)}}s.pluginSystem.add("symbols",d)},5119:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 270 270"> <path d="m240.443652,220.45085l-47.410809,0l0,-10.342138c13.89973,-8.43655 25.752896,-19.844464 34.686646,-33.469923c11.445525,-17.455846 17.496072,-37.709239 17.496072,-58.570077c0,-59.589197 -49.208516,-108.068714 -109.693558,-108.068714s-109.69263,48.479517 -109.69263,108.069628c0,20.860839 6.050547,41.113316 17.497001,58.570077c8.93375,13.625459 20.787845,25.032458 34.686646,33.469008l0,10.342138l-47.412666,0c-10.256959,0 -18.571354,8.191376 -18.571354,18.296574c0,10.105198 8.314395,18.296574 18.571354,18.296574l65.98402,0c10.256959,0 18.571354,-8.191376 18.571354,-18.296574l0,-39.496814c0,-7.073455 -4.137698,-13.51202 -10.626529,-16.537358c-25.24497,-11.772016 -41.557118,-37.145704 -41.557118,-64.643625c0,-39.411735 32.545369,-71.476481 72.549922,-71.476481c40.004553,0 72.550851,32.064746 72.550851,71.476481c0,27.497006 -16.312149,52.87161 -41.557118,64.643625c-6.487902,3.026253 -10.6256,9.464818 -10.6256,16.537358l0,39.496814c0,10.105198 8.314395,18.296574 18.571354,18.296574l65.982163,0c10.256959,0 18.571354,-8.191376 18.571354,-18.296574c0,-10.105198 -8.314395,-18.296574 -18.571354,-18.296574z"/> </svg> '},47686:function(t,i,n){"use strict";n.d(i,{onTabInsideLi:function(){return o.onTabInsideLi}});var o=n(26658)},26658:function(t,i,n){"use strict";n.d(i,{onTabInsideLi:function(){return s}});var o=n(2748),r=n(38837);function s(t,i=!1){let n,a,l,c;if(!t.o.tab.tabInsideLiInsertNewList)return!1;let[d,u]=(n=t.createInside.fake(),a=t.createInside.fake(),(l=t.s.range.cloneRange()).collapse(!0),l.insertNode(n),(c=t.s.range.cloneRange()).collapse(!1),c.insertNode(a),[n,a]);try{let n,s,a,l,c,u=!!(n=o.Dom.closest(d,"li",t.editor))&&(!!i||!!o.Dom.isLeaf(n.previousElementSibling))&&(!i||!!o.Dom.closest(n,"li",t.editor))&&n;if(!u||!(s=o.Dom.closest(d,"li",t.editor))||s!==u&&!u.contains(s))return!1;let h=o.Dom.closest(u,["ol","ul"],t.editor);if(!h||i&&!o.Dom.closest(h,"li",t.editor))return!1;return i?function(t,i,n){let s=o.Dom.closest(i,"li",t.editor);(0,r.assert)(s,"tab parent li is null");let a=Array.from(i.children).filter(t=>o.Dom.isLeaf(t));o.Dom.after(s,n);let l=a.indexOf(n);if((0===l||1===a.length)&&o.Dom.safeRemove(i),l!==a.length-1){let t=i.cloneNode();o.Dom.append(n,t);for(let i=l+1;i<a.length;i+=1)o.Dom.append(t,a[i])}}(t,h,u):(a=u.previousElementSibling,(0,r.assert)(a,"tab previousElementSibling is null"),l=a.lastElementChild,(c=o.Dom.isTag(l,h.tagName)?l:t.createInside.element(h.tagName,Array.from(h.attributes).reduce((t,i)=>(t[i.name]=i.value,t),{}))).appendChild(u),l!==c&&a.appendChild(c)),!0}finally{let i=t.s.createRange();i.setStartAfter(d),i.setEndBefore(u),t.s.selectRange(i),o.Dom.safeRemove(d),o.Dom.safeRemove(u)}}},66288:function(t,i,n){"use strict";n(6441).Config.prototype.tab={tabInsideLiInsertNewList:!0}},767:function(t,i,n){"use strict";var o=n(82758),r=n(65478),s=n(580),a=n(50911);n(66288);var l=n(47686),c=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a};class d extends a.Plugin{afterInit(t){}__onTab(t){if(t.key===o.KEY_TAB&&this.__onShift(t.shiftKey))return!1}__onCommand(t){if(("indent"===t||"outdent"===t)&&this.__onShift("outdent"===t))return!1}__onShift(t){let i=(0,l.onTabInsideLi)(this.j,t);return i&&this.j.e.fire("afterTab",t),i}beforeDestruct(t){}}c([(0,r.watch)(":keydown.tab")],d.prototype,"__onTab",null),c([(0,r.watch)(":beforeCommand.tab")],d.prototype,"__onCommand",null),s.pluginSystem.add("tab",d)},72439:function(t,i,n){"use strict";var o=n(82758),r=n(2748),s=n(580),a=n(21537),l=n(76014);let c=new Set([o.KEY_TAB,o.KEY_LEFT,o.KEY_RIGHT,o.KEY_UP,o.KEY_DOWN]);s.pluginSystem.add("tableKeyboardNavigation",function(t){t.e.off(".tableKeyboardNavigation").on("keydown.tableKeyboardNavigation",i=>{let{key:n}=i,s=function(t,i){if(!c.has(i))return;let n=t.s.current();if(!n)return;let s=r.Dom.up(n,r.Dom.isCell,t.editor);if(!s)return;let{range:l}=t.s;if(i!==o.KEY_TAB&&n!==s){let t=i===o.KEY_RIGHT||i===o.KEY_DOWN,c=(0,a.call)(t?r.Dom.next:r.Dom.prev,n,t=>i===o.KEY_UP||i===o.KEY_DOWN?r.Dom.isTag(t,"br"):!!t,s);if(!t&&(c||i!==o.KEY_UP&&r.Dom.isText(n)&&0!==l.startOffset)||t&&(c||i!==o.KEY_DOWN&&r.Dom.isText(n)&&n.nodeValue&&l.startOffset!==n.nodeValue.length))return}return s}(t,n);if(!s)return;let d=t.getInstance(l.Table,t.o),u=r.Dom.closest(s,"table",t.editor),h=null,p=n===o.KEY_LEFT||i.shiftKey,f=()=>(0,a.call)(p?r.Dom.prev:r.Dom.next,s,r.Dom.isCell,u);switch(n){case o.KEY_TAB:case o.KEY_LEFT:(h=f())||(d.appendRow(u,!!p&&u.querySelector("tr"),!p),h=f());break;case o.KEY_UP:case o.KEY_DOWN:{let t=d.formalMatrix(u),[i,r]=d.formalCoordinate(u,s);n===o.KEY_UP?void 0!==t[i-1]&&(h=t[i-1][r]):void 0!==t[i+1]&&(h=t[i+1][r])}}if(h){if(t.e.fire("hidePopup hideResizer"),h.firstChild)n===o.KEY_TAB?t.s.select(h,!0):t.s.setCursorIn(h,n===o.KEY_RIGHT||n===o.KEY_DOWN);else{let i=t.createInside.element("br");h.appendChild(i),t.s.setCursorBefore(i)}return t.synchronizeValues(),!1}})})},40329:function(t,i,n){"use strict";var o=n(
|
|
279
|
-
`)),
|
|
280
|
-
`)),
|
|
281
|
-
`);if(t.o.table.splitBlockOnInsertTable){let n=t.s.range;n.collapse(!1),n.insertNode(i),n.collapse(!1),t.s.selectRange(n);let r=t.s.splitSelection(_,i);r?o.Dom.after(r,m):o.Dom.after(_,m)}else o.Dom.after(_,i),o.Dom.after(i,m)}else t.s.insertNode(m,!1);b&&(t.s.setCursorIn(b),(0,r.scrollIntoViewIfNeeded)(b,t.editor,t.ed)),n()}),a&&a.parentElement){for(let i=0;i<d;i+=1){let n=t.c.div();for(let t=0;t<u;t+=1)n.appendChild(b[i*u+t]);m.appendChild(n)}b[0]&&(b[0].className="hovered")}return h},tooltip:"Insert table"}},43003:function(t,i,n){"use strict";var o=n(580);n(40329),o.pluginSystem.add("table",function(t){t.registerButton({name:"table",group:"insert"})})},6091:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M576 1376v-192q0-14-9-23t-23-9h-320q-14 0-23 9t-9 23v192q0 14 9 23t23 9h320q14 0 23-9t9-23zm0-384v-192q0-14-9-23t-23-9h-320q-14 0-23 9t-9 23v192q0 14 9 23t23 9h320q14 0 23-9t9-23zm512 384v-192q0-14-9-23t-23-9h-320q-14 0-23 9t-9 23v192q0 14 9 23t23 9h320q14 0 23-9t9-23zm-512-768v-192q0-14-9-23t-23-9h-320q-14 0-23 9t-9 23v192q0 14 9 23t23 9h320q14 0 23-9t9-23zm512 384v-192q0-14-9-23t-23-9h-320q-14 0-23 9t-9 23v192q0 14 9 23t23 9h320q14 0 23-9t9-23zm512 384v-192q0-14-9-23t-23-9h-320q-14 0-23 9t-9 23v192q0 14 9 23t23 9h320q14 0 23-9t9-23zm-512-768v-192q0-14-9-23t-23-9h-320q-14 0-23 9t-9 23v192q0 14 9 23t23 9h320q14 0 23-9t9-23zm512 384v-192q0-14-9-23t-23-9h-320q-14 0-23 9t-9 23v192q0 14 9 23t23 9h320q14 0 23-9t9-23zm0-384v-192q0-14-9-23t-23-9h-320q-14 0-23 9t-9 23v192q0 14 9 23t23 9h320q14 0 23-9t9-23zm128-320v1088q0 66-47 113t-113 47h-1344q-66 0-113-47t-47-113v-1088q0-66 47-113t113-47h1344q66 0 113 47t47 113z"/> </svg> '},14984:function(t,i,n){"use strict";var o=n(21537),r=n(62843),s=n(2525),a=n(12153),l=n(6441),c=n(92762),d=n(37775);l.Config.prototype.video={parseUrlToVideoEmbed:o.convertMediaUrlToVideoEmbed,defaultWidth:400,defaultHeight:345},a.Icon.set("video",d.default),l.Config.prototype.controls.video={popup(t,i,n){let a=new s.UIForm(t,[new s.UIBlock(t,[new s.UIInput(t,{name:"url",required:!0,label:"URL",placeholder:"https://",validators:["url"]})]),new s.UIBlock(t,[(0,r.Button)(t,"","Insert","primary").onAction(()=>a.submit())])]),l=new s.UIForm(t,[new s.UIBlock(t,[new s.UITextArea(t,{name:"code",required:!0,label:"Embed code"})]),new s.UIBlock(t,[(0,r.Button)(t,"","Insert","primary").onAction(()=>l.submit())])]),d=[],u=i=>{t.s.restore(),t.s.insertHTML(i),n()};return t.s.save(),d.push({icon:"link",name:"Link",content:a.container},{icon:"source",name:"Code",content:l.container}),a.onSubmit(i=>{var n,r,s,a;u((0,o.call)(null!=(r=null==(n=t.o.video)?void 0:n.parseUrlToVideoEmbed)?r:o.convertMediaUrlToVideoEmbed,i.url,{width:null==(s=t.o.video)?void 0:s.defaultWidth,height:null==(a=t.o.video)?void 0:a.defaultHeight}))}),l.onSubmit(t=>{u(t.code)}),(0,c.TabsWidget)(t,d)},tags:["iframe"],tooltip:"Insert youtube/vimeo video"}},26551:function(t,i,n){"use strict";var o=n(580);n(14984),o.pluginSystem.add("video",function(t){t.registerButton({name:"video",group:"media"})})},37775:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1792 352v1088q0 42-39 59-13 5-25 5-27 0-45-19l-403-403v166q0 119-84.5 203.5t-203.5 84.5h-704q-119 0-203.5-84.5t-84.5-203.5v-704q0-119 84.5-203.5t203.5-84.5h704q119 0 203.5 84.5t84.5 203.5v165l403-402q18-19 45-19 12 0 25 5 39 17 39 59z"/> </svg> '},96967:function(t,i,n){"use strict";n(6441).Config.prototype.wrapNodes={exclude:new Set(["hr","style","br"]),emptyBlockAfterInit:!0}},72253:function(t,i,n){"use strict";var o=n(65478),r=n(22732),s=n(580),a=n(70799),l=n(50911);n(96967);var c=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a};class d extends l.Plugin{afterInit(t){"br"!==t.o.enter.toLowerCase()&&t.e.on("drop.wtn focus.wtn keydown.wtn mousedown.wtn afterInit.wtn backSpaceAfterDelete.wtn",this.preprocessInput,{top:!0}).on("afterInit.wtn postProcessSetEditorValue.wtn afterCommitStyle.wtn backSpaceAfterDelete.wtn",this.postProcessSetEditorValue)}beforeDestruct(t){t.e.off(".wtn")}postProcessSetEditorValue(){let{jodit:t}=this;if(!t.isEditorMode())return;let i=t.editor.firstChild,n=!1;for(;i;){if(i=function(t,i){let n=t,o=t;do if(r.Dom.isElement(o)&&r.Dom.isLeaf(o)&&!r.Dom.isList(o.parentElement)){let t=r.Dom.findNotEmptySibling(o,!1);r.Dom.isTag(n,"ul")?n.appendChild(o):n=r.Dom.wrap(o,"ul",i.createInside),o=t}else break;while(o)return n}(i,t),this.isSuitableStart(i)){n||t.s.save(),n=!0;let o=t.createInside.element(t.o.enter);for(r.Dom.before(i,o);i&&this.isSuitable(i);){let t=i.nextSibling;o.appendChild(i),i=t}o.normalize(),i=o}i=i&&i.nextSibling}n&&(t.s.restore(),"afterInit"===t.e.current&&t.e.fire("internalChange"))}preprocessInput(){let{jodit:t}=this,i="afterInit"===t.e.current;if(!t.isEditorMode()||t.editor.firstChild||!t.o.wrapNodes.emptyBlockAfterInit&&i)return;let n=t.createInside.element(t.o.enter),o=t.createInside.element("br");r.Dom.append(n,o),r.Dom.append(t.editor,n),(t.s.isFocused()||"backSpaceAfterDelete"===t.e.current)&&t.s.setCursorBefore(o),t.e.fire("internalChange")}constructor(){super(...arguments),this.isSuitableStart=t=>{var i;return r.Dom.isText(t)&&(0,a.isString)(t.nodeValue)&&(/[^\s]/.test(t.nodeValue)||(null==(i=t.parentNode)?void 0:i.firstChild)===t&&this.isSuitable(t.nextSibling))||this.isNotWrapped(t)&&!r.Dom.isTemporary(t)},this.isSuitable=t=>r.Dom.isText(t)||this.isNotWrapped(t),this.isNotWrapped=t=>r.Dom.isElement(t)&&!(r.Dom.isBlock(t)||r.Dom.isTag(t,this.j.o.wrapNodes.exclude))}}c([o.autobind],d.prototype,"postProcessSetEditorValue",null),c([o.autobind],d.prototype,"preprocessInput",null),s.pluginSystem.add("wrapNodes",d)},86012:function(t,i,n){"use strict";n(6441).Config.prototype.showXPathInStatusbar=!0},83671:function(t,i,n){"use strict";var o=n(82758),r=n(22732),s=n(580),a=n(49055),l=n(29960),c=n(76078),d=n(50911),u=n(80870),h=n(21491);n(86012);class p extends d.Plugin{afterInit(){if(this.j.o.showXPathInStatusbar){this.container=this.j.c.div("jodit-xpath"),(0,l.attr)(this.container,"role","list");let t=()=>{this.j.o.showXPathInStatusbar&&this.container&&(this.j.statusbar.append(this.container),this.j.getRealMode()===o.MODE_WYSIWYG?this.calcPath():(this.container&&(this.container.innerHTML=o.INVISIBLE_SPACE),this.appendSelectAll()))};this.j.e.off(".xpath").on("pointerup.xpath change.xpath keydown.xpath changeSelection.xpath",this.calcPath).on("afterSetMode.xpath afterInit.xpath changePlace.xpath",t),t(),this.calcPath()}}beforeDestruct(){this.j&&this.j.events&&this.j.e.off(".xpath"),this.removeSelectAll(),this.menu&&this.menu.destruct(),r.Dom.safeRemove(this.container),delete this.menu,delete this.container}constructor(){super(...arguments),this.onContext=(t,i)=>(this.menu||(this.menu=new u.ContextMenu(this.j)),this.menu.show(i.clientX,i.clientY,[{icon:"bin",title:t===this.j.editor?"Clear":"Remove",exec:()=>{t!==this.j.editor?r.Dom.safeRemove(t):this.j.value="",this.j.synchronizeValues()}},{icon:"select-all",title:"Select",exec:()=>{this.j.s.select(t)}}]),!1),this.onSelectPath=(t,i)=>{this.j.s.focus();let n=(0,l.attr)(i.target,"-path")||"/";if("/"===n)return this.j.execCommand("selectall"),!1;try{let t=this.j.ed.evaluate(n,this.j.editor,null,XPathResult.ANY_TYPE,null).iterateNext();if(t)return this.j.s.select(t),!1}catch(t){}return this.j.s.select(t),!1},this.tpl=(t,i,n,o)=>{let r=this.j.c.fromHTML(`<span class="jodit-xpath__item"><a role="button" data-path="${i}" title="${o}" tabindex="-1"'>${(0,a.trim)(n)}</a></span>`),s=r.firstChild;return this.j.e.on(s,"click",this.onSelectPath.bind(this,t)).on(s,"contextmenu",this.onContext.bind(this,t)),r},this.removeSelectAll=()=>{this.selectAllButton&&(this.selectAllButton.destruct(),delete this.selectAllButton)},this.appendSelectAll=()=>{this.removeSelectAll(),this.selectAllButton=(0,h.makeButton)(this.j,{name:"selectall",...this.j.o.controls.selectall}),this.selectAllButton.state.size="tiny",this.container&&this.container.insertBefore(this.selectAllButton.container,this.container.firstChild)},this.calcPathImd=()=>{if(this.isDestructed)return;let t=this.j.s.current();if(this.container&&(this.container.innerHTML=o.INVISIBLE_SPACE),t){let i,n,o;r.Dom.up(t,t=>{t&&this.j.editor!==t&&!r.Dom.isText(t)&&!r.Dom.isComment(t)&&(i=t.nodeName.toLowerCase(),n=(0,c.getXPathByElement)(t,this.j.editor).replace(/^\//,""),o=this.tpl(t,n,i,this.j.i18n("Select %s",i)),this.container&&this.container.insertBefore(o,this.container.firstChild))},this.j.editor)}this.appendSelectAll()},this.calcPath=this.j.async.debounce(this.calcPathImd,2*this.j.defaultTimeout,!0)}}s.pluginSystem.add("xpath",p)},78173:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1395 736q0 13-10 23l-466 466q-10 10-23 10t-23-10l-466-466q-10-10-10-23t10-23l50-50q10-10 23-10t23 10l393 393 393-393q10-10 23-10t23 10l50 50q10 10 10 23z"/> </svg> '},16260:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1203 544q0 13-10 23l-393 393 393 393q10 10 10 23t-10 23l-50 50q-10 10-23 10t-23-10l-466-466q-10-10-10-23t10-23l466-466q10-10 23-10t23 10l50 50q10 10 10 23z"/> </svg> '},37663:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1171 960q0 13-10 23l-466 466q-10 10-23 10t-23-10l-50-50q-10-10-10-23t10-23l393-393-393-393q-10-10-10-23t10-23l50-50q10-10 23-10t23 10l466 466q10 10 10 23z"/> </svg> '},51036:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1395 1184q0 13-10 23l-50 50q-10 10-23 10t-23-10l-393-393-393 393q-10 10-23 10t-23-10l-50-50q-10-10-10-23t10-23l466-466q10-10 23-10t23 10l466 466q10 10 10 23z"/> </svg> '},31554:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M704 1376v-704q0-14-9-23t-23-9h-64q-14 0-23 9t-9 23v704q0 14 9 23t23 9h64q14 0 23-9t9-23zm256 0v-704q0-14-9-23t-23-9h-64q-14 0-23 9t-9 23v704q0 14 9 23t23 9h64q14 0 23-9t9-23zm256 0v-704q0-14-9-23t-23-9h-64q-14 0-23 9t-9 23v704q0 14 9 23t23 9h64q14 0 23-9t9-23zm-544-992h448l-48-117q-7-9-17-11h-317q-10 2-17 11zm928 32v64q0 14-9 23t-23 9h-96v948q0 83-47 143.5t-113 60.5h-832q-66 0-113-58.5t-47-141.5v-952h-96q-14 0-23-9t-9-23v-64q0-14 9-23t23-9h309l70-167q15-37 54-63t79-26h320q40 0 79 26t54 63l70 167h309q14 0 23 9t9 23z"/> </svg> '},18309:function(t,i){"use strict";i.default='<svg viewBox="0 0 14 14" xmlns="http://www.w3.org/2000/svg"> <g stroke="none" stroke-width="1"> <path d="M14,1.4 L12.6,0 L7,5.6 L1.4,0 L0,1.4 L5.6,7 L0,12.6 L1.4,14 L7,8.4 L12.6,14 L14,12.6 L8.4,7 L14,1.4 Z"/> </g> </svg> '},99762:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1792 1344v128q0 26-19 45t-45 19h-1664q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1664q26 0 45 19t19 45zm-384-384v128q0 26-19 45t-45 19h-896q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h896q26 0 45 19t19 45zm256-384v128q0 26-19 45t-45 19h-1408q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1408q26 0 45 19t19 45zm-384-384v128q0 26-19 45t-45 19h-640q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h640q26 0 45 19t19 45z"/> </svg> '},7903:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1472 930v318q0 119-84.5 203.5t-203.5 84.5h-832q-119 0-203.5-84.5t-84.5-203.5v-832q0-119 84.5-203.5t203.5-84.5h832q63 0 117 25 15 7 18 23 3 17-9 29l-49 49q-10 10-23 10-3 0-9-2-23-6-45-6h-832q-66 0-113 47t-47 113v832q0 66 47 113t113 47h832q66 0 113-47t47-113v-254q0-13 9-22l64-64q10-10 23-10 6 0 12 3 20 8 20 29zm231-489l-814 814q-24 24-57 24t-57-24l-430-430q-24-24-24-57t24-57l110-110q24-24 57-24t57 24l263 263 647-647q24-24 57-24t57 24l110 110q24 24 24 57t-24 57z"/> </svg> '},58032:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 10 10"> <path d="M.941 4.523a.75.75 0 1 1 1.06-1.06l3.006 3.005 3.005-3.005a.75.75 0 1 1 1.06 1.06l-3.549 3.55a.75.75 0 0 1-1.168-.136L.941 4.523z"/> </svg> '},52507:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 24 24" > <circle cx="12" cy="12" r="2.2"/> <circle cx="12" cy="5" r="2.2"/> <circle cx="12" cy="19" r="2.2"/> </svg> '},43478:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1664 960q-152-236-381-353 61 104 61 225 0 185-131.5 316.5t-316.5 131.5-316.5-131.5-131.5-316.5q0-121 61-225-229 117-381 353 133 205 333.5 326.5t434.5 121.5 434.5-121.5 333.5-326.5zm-720-384q0-20-14-34t-34-14q-125 0-214.5 89.5t-89.5 214.5q0 20 14 34t34 14 34-14 14-34q0-86 61-147t147-61q20 0 34-14t14-34zm848 384q0 34-20 69-140 230-376.5 368.5t-499.5 138.5-499.5-139-376.5-368q-20-35-20-69t20-69q140-229 376.5-368t499.5-139 499.5 139 376.5 368q20 35 20 69z"/> </svg> '},60097:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1152 512v-472q22 14 36 28l408 408q14 14 28 36h-472zm-128 32q0 40 28 68t68 28h544v1056q0 40-28 68t-68 28h-1344q-40 0-68-28t-28-68v-1600q0-40 28-68t68-28h800v544z"/> </svg> '},49155:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1728 608v704q0 92-66 158t-158 66h-1216q-92 0-158-66t-66-158v-960q0-92 66-158t158-66h320q92 0 158 66t66 158v32h672q92 0 158 66t66 158z"/> </svg> '},17555:function(t,i,n){"use strict";n.r(i),n.d(i,{angle_down:function(){return o.default},angle_left:function(){return r.default},angle_right:function(){return s.default},angle_up:function(){return a.default},bin:function(){return l.default},cancel:function(){return c.default},center:function(){return d.default},check:function(){return u.default},chevron:function(){return h.default},dots:function(){return p.default},eye:function(){return f.default},file:function(){return m.default},folder:function(){return g.default},info_circle:function(){return b.default},left:function(){return y.default},lock:function(){return w.default},ok:function(){return _.default},pencil:function(){return C.default},plus:function(){return k.default},resize_handler:function(){return S.default},right:function(){return x.default},save:function(){return I.default},settings:function(){return E.default},unlock:function(){return T.default},update:function(){return j.default},upload:function(){return A.default},valign:function(){return P.default}});var o=n(78173),r=n(16260),s=n(37663),a=n(51036),l=n(31554),c=n(18309),d=n(99762),u=n(7903),h=n(58032),p=n(52507),f=n(43478),m=n(60097),g=n(49155),b=n(17176),y=n(57882),w=n(58908),_=n(24829),C=n(4038),k=n(45575),S=n(84858),x=n(445),I=n(36886),E=n(10766),T=n(33651),j=n(20362),A=n(12202),P=n(80152)},17176:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1152 1376v-160q0-14-9-23t-23-9h-96v-512q0-14-9-23t-23-9h-320q-14 0-23 9t-9 23v160q0 14 9 23t23 9h96v320h-96q-14 0-23 9t-9 23v160q0 14 9 23t23 9h448q14 0 23-9t9-23zm-128-896v-160q0-14-9-23t-23-9h-192q-14 0-23 9t-9 23v160q0 14 9 23t23 9h192q14 0 23-9t9-23zm640 416q0 209-103 385.5t-279.5 279.5-385.5 103-385.5-103-279.5-279.5-103-385.5 103-385.5 279.5-279.5 385.5-103 385.5 103 279.5 279.5 103 385.5z"/> </svg> '},57882:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1792 1344v128q0 26-19 45t-45 19h-1664q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1664q26 0 45 19t19 45zm-384-384v128q0 26-19 45t-45 19h-1280q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1280q26 0 45 19t19 45zm256-384v128q0 26-19 45t-45 19h-1536q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1536q26 0 45 19t19 45zm-384-384v128q0 26-19 45t-45 19h-1152q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1152q26 0 45 19t19 45z"/> </svg> '},58908:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"><path d="M640 768h512v-192q0-106-75-181t-181-75-181 75-75 181v192zm832 96v576q0 40-28 68t-68 28h-960q-40 0-68-28t-28-68v-576q0-40 28-68t68-28h32v-192q0-184 132-316t316-132 316 132 132 316v192h32q40 0 68 28t28 68z"/></svg> '},24829:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 32 32"> <path d="M27 4l-15 15-7-7-5 5 12 12 20-20z"/> </svg> '},4038:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"><path d="M491 1536l91-91-235-235-91 91v107h128v128h107zm523-928q0-22-22-22-10 0-17 7l-542 542q-7 7-7 17 0 22 22 22 10 0 17-7l542-542q7-7 7-17zm-54-192l416 416-832 832h-416v-416zm683 96q0 53-37 90l-166 166-416-416 166-165q36-38 90-38 53 0 91 38l235 234q37 39 37 91z"/></svg> '},45575:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"><path d="M1600 736v192q0 40-28 68t-68 28h-416v416q0 40-28 68t-68 28h-192q-40 0-68-28t-28-68v-416h-416q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h416v-416q0-40 28-68t68-28h192q40 0 68 28t28 68v416h416q40 0 68 28t28 68z"/></svg> '},84858:function(t,i){"use strict";i.default='<svg viewBox="0 0 13 13" xmlns="http://www.w3.org/2000/svg"> <path d="M5.9814 11.8049C5.59087 11.4144 5.59087 10.7812 5.9814 10.3907L10.224 6.14806C10.6146 5.75754 11.2477 5.75754 11.6383 6.14806C12.0288 6.53859 12.0288 7.17175 11.6383 7.56228L7.39561 11.8049C7.00509 12.1954 6.37192 12.1954 5.9814 11.8049Z"/> <path d="M0.707107 12.0208C0.316582 11.6303 0.316582 10.9971 0.707107 10.6066L10.6066 0.707121C10.9971 0.316597 11.6303 0.316596 12.0208 0.707121C12.4113 1.09764 12.4113 1.73081 12.0208 2.12133L2.12132 12.0208C1.7308 12.4114 1.09763 12.4114 0.707107 12.0208Z"/> </svg> '},445:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1792 1344v128q0 26-19 45t-45 19h-1664q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1664q26 0 45 19t19 45zm0-384v128q0 26-19 45t-45 19h-1280q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1280q26 0 45 19t19 45zm0-384v128q0 26-19 45t-45 19h-1536q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1536q26 0 45 19t19 45zm0-384v128q0 26-19 45t-45 19h-1152q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1152q26 0 45 19t19 45z"/> </svg> '},36886:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M512 1536h768v-384h-768v384zm896 0h128v-896q0-14-10-38.5t-20-34.5l-281-281q-10-10-34-20t-39-10v416q0 40-28 68t-68 28h-576q-40 0-68-28t-28-68v-416h-128v1280h128v-416q0-40 28-68t68-28h832q40 0 68 28t28 68v416zm-384-928v-320q0-13-9.5-22.5t-22.5-9.5h-192q-13 0-22.5 9.5t-9.5 22.5v320q0 13 9.5 22.5t22.5 9.5h192q13 0 22.5-9.5t9.5-22.5zm640 32v928q0 40-28 68t-68 28h-1344q-40 0-68-28t-28-68v-1344q0-40 28-68t68-28h928q40 0 88 20t76 48l280 280q28 28 48 76t20 88z"/> </svg> '},10766:function(t,i){"use strict";i.default='<svg viewBox="0 0 48 48" xmlns="http://www.w3.org/2000/svg"> <path stroke="null" d="m42.276011,26.302547c0.098397,-0.76605 0.172194,-1.54407 0.172194,-2.33406s-0.073797,-1.56801 -0.172194,-2.33406l5.202718,-3.961917c0.467384,-0.359086 0.602679,-1.005441 0.29519,-1.532101l-4.919828,-8.29489c-0.307489,-0.51469 -0.947067,-0.730142 -1.500548,-0.51469l-6.125186,2.405877c-1.266856,-0.945594 -2.656707,-1.747553 -4.157255,-2.357999l-0.922468,-6.343855c-0.110696,-0.562568 -0.614979,-1.005441 -1.229957,-1.005441l-9.839656,0c-0.614979,0 -1.119261,0.442873 -1.217657,1.005441l-0.922468,6.343855c-1.500548,0.610446 -2.890399,1.400436 -4.157255,2.357999l-6.125186,-2.405877c-0.553481,-0.203482 -1.193058,0 -1.500548,0.51469l-4.919828,8.29489c-0.307489,0.51469 -0.172194,1.161045 0.29519,1.532101l5.190419,3.961917c-0.098397,0.76605 -0.172194,1.54407 -0.172194,2.33406s0.073797,1.56801 0.172194,2.33406l-5.190419,3.961917c-0.467384,0.359086 -0.602679,1.005441 -0.29519,1.532101l4.919828,8.29489c0.307489,0.51469 0.947067,0.730142 1.500548,0.51469l6.125186,-2.405877c1.266856,0.945594 2.656707,1.747553 4.157255,2.357999l0.922468,6.343855c0.098397,0.562568 0.602679,1.005441 1.217657,1.005441l9.839656,0c0.614979,0 1.119261,-0.442873 1.217657,-1.005441l0.922468,-6.343855c1.500548,-0.610446 2.890399,-1.400436 4.157255,-2.357999l6.125186,2.405877c0.553481,0.203482 1.193058,0 1.500548,-0.51469l4.919828,-8.29489c0.307489,-0.51469 0.172194,-1.161045 -0.29519,-1.532101l-5.190419,-3.961917zm-18.277162,6.044617c-4.759934,0 -8.609699,-3.746465 -8.609699,-8.378677s3.849766,-8.378677 8.609699,-8.378677s8.609699,3.746465 8.609699,8.378677s-3.849766,8.378677 -8.609699,8.378677z"/> </svg> '},33651:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1728 576v256q0 26-19 45t-45 19h-64q-26 0-45-19t-19-45v-256q0-106-75-181t-181-75-181 75-75 181v192h96q40 0 68 28t28 68v576q0 40-28 68t-68 28h-960q-40 0-68-28t-28-68v-576q0-40 28-68t68-28h672v-192q0-185 131.5-316.5t316.5-131.5 316.5 131.5 131.5 316.5z"/> </svg> '},20362:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1639 1056q0 5-1 7-64 268-268 434.5t-478 166.5q-146 0-282.5-55t-243.5-157l-129 129q-19 19-45 19t-45-19-19-45v-448q0-26 19-45t45-19h448q26 0 45 19t19 45-19 45l-137 137q71 66 161 102t187 36q134 0 250-65t186-179q11-17 53-117 8-23 30-23h192q13 0 22.5 9.5t9.5 22.5zm25-800v448q0 26-19 45t-45 19h-448q-26 0-45-19t-19-45 19-45l138-138q-148-137-349-137-134 0-250 65t-186 179q-11 17-53 117-8 23-30 23h-199q-13 0-22.5-9.5t-9.5-22.5v-7q65-268 270-434.5t480-166.5q146 0 284 55.5t245 156.5l130-129q19-19 45-19t45 19 19 45z"/> </svg> '},12202:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1344 1472q0-26-19-45t-45-19-45 19-19 45 19 45 45 19 45-19 19-45zm256 0q0-26-19-45t-45-19-45 19-19 45 19 45 45 19 45-19 19-45zm128-224v320q0 40-28 68t-68 28h-1472q-40 0-68-28t-28-68v-320q0-40 28-68t68-28h427q21 56 70.5 92t110.5 36h256q61 0 110.5-36t70.5-92h427q40 0 68 28t28 68zm-325-648q-17 40-59 40h-256v448q0 26-19 45t-45 19h-256q-26 0-45-19t-19-45v-448h-256q-42 0-59-40-17-39 14-69l448-448q18-19 45-19t45 19l448 448q31 30 14 69z"/> </svg> '},80152:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1216 320q0 26-19 45t-45 19h-128v1024h128q26 0 45 19t19 45-19 45l-256 256q-19 19-45 19t-45-19l-256-256q-19-19-19-45t19-45 45-19h128v-1024h-128q-26 0-45-19t-19-45 19-45l256-256q19-19 45-19t45 19l256 256q19 19 19 45z"/> </svg> '},62357:function(t,i,n){"use strict";n.d(i,{UIRange:function(){return c}});var o=n(82749),r=n(31635),s=n(65478),a=n(21537),l=n(67510);class c extends l.UIInput{className(){return"UIRange"}appendUIRange(){let t=this.j.create.div(this.getFullElName("slider"));this.container.appendChild(t);let i=this.j.create.div(this.getFullElName("handle"));t.appendChild(i);let n=this.j.create.div(this.getFullElName("log")),o=this.getElm("label");o&&o.appendChild(n)}onDragStart(t){this.startValue=parseFloat(this.value)||0,this.startX=t.clientX;let i=this.getElm("slider");(0,a.assert)(null!=i,"slider element does not exists"),this.width=i.offsetWidth,this.j.e.on(this.j.ow,"mousemove",this.onDrag)}onDrag(t){let{min:i,max:n,step:o=1}=this.state,r=(t.clientX-this.startX)/this.width*(this.state.max-this.state.min),s=this.startValue+r;s<i&&(s=i),s>n&&(s=n),s=Math.round(s/o)*o,this.value=s.toFixed(10)}onDragEnd(){this.j.e.off(this.j.ow,"mousemove",this.onDrag)}onChangeSelfValue(){let t=this.getElm("handle"),i=parseFloat(this.value)||0;(0,a.assert)(null!=t,"Handle element does not exist"),(0,a.css)(t,{left:(i-this.state.min)/(this.state.max-this.state.min)*100+"%"});let n=this.getElm("log");(0,a.assert)(null!=n,"log element does not exist"),n.innerText=i.toString()}destruct(){return this.onDragEnd(),super.destruct()}constructor(t,i){super(t,{...i,type:"hidden"}),(0,o._)(this,"state",{...l.UIInput.defaultState,min:0,max:100,step:1}),(0,o._)(this,"startValue",0),(0,o._)(this,"startX",0),(0,o._)(this,"width",100),Object.assign(this.state,i),this.appendUIRange(),this.onChangeSelfValue()}}(0,r.__decorate)([(0,s.watch)(["handle:mousedown","handle:touchstart"])],c.prototype,"onDragStart",null),(0,r.__decorate)([s.autobind],c.prototype,"onDrag",null),(0,r.__decorate)([(0,s.watch)(["j.ow:mouseup","j.ow:touchend"])],c.prototype,"onDragEnd",null),(0,r.__decorate)([(0,s.watch)(":change")],c.prototype,"onChangeSelfValue",null),c=(0,r.__decorate)([s.component],c)},31356:function(t,i,n){"use strict";n.d(i,{ListReconciler:function(){return o}});class o{static reconcile(t,i,n){let{getId:o,isEqual:r=(t,i)=>o(t)===o(i),preserveOrder:s=!0}=n,a=new Map,l=new Map;t.forEach((t,i)=>{let n=o(t);a.set(n,t),l.set(n,i)});let c=new Map,d=new Map;i.forEach((t,i)=>{let n=o(t);c.set(n,t),d.set(n,i)});let u=[],h=[],p=[],f=[];return i.forEach((t,i)=>{let n=o(t),c=a.get(n);c?!r(c,t)||s&&l.get(n)!==i?h.push({oldItem:c,newItem:t,index:s?i:l.get(n)}):f.push(c):u.push(t)}),t.forEach(t=>{let i=o(t);c.has(i)||p.push(t)}),{toCreate:u,toUpdate:h,toRemove:p,unchanged:f}}static applyResult(t,i,n={}){i.toRemove.forEach(i=>{let o=t.indexOf(i);-1!==o&&(n.onRemove?.(i,o),t.splice(o,1))}),i.toUpdate.forEach(({oldItem:i,newItem:o,index:r})=>{let s=t.indexOf(i);-1!==s&&(n.onUpdate?.(i,o,r),t[s]=o)}),i.toCreate.forEach(i=>{n.onCreate?.(i,t.length),t.push(i)})}}},2692:function(t,i,n){"use strict";n.d(i,{JoditPro:function(){return l}});var o=n(82758),r=n(63799),s=n(41180),a=n(86019);class l extends a.Jodit{static make(t,i){return new this(t,i)}beforeInitHook(){if(o.IS_PROD&&!o.IS_TEST&&this.o.loadExternalConfig)return(0,r.appendScriptAsync)(this,this.basePath+"config.js")}afterInitHook(){(async()=>{if(await this.e.fire("checkReserve",location.host)!=="normal"){if(this.isInDestruct)return;let t=this.c.div("",'Trial version. Buy <a href="https://xdsoft.net/jodit/pro/">Jodit Pro</a>');o.IS_TEST||o.IS_PROD,(0,s.css)(t,{position:"absolute",color:"red",right:10,bottom:10}),this.addDisclaimer(t)}})().catch(()=>null),super.afterInitHook()}getVersion(){return"PRO "+o.APP_VERSION}}},41810:function(t,i,n){"use strict";var o=n(82749),r=n(31635);n(66645);var s=n(86449),a=n(21020),l=n(46166),c=n(62895),d=n(55487),u=n(27769),h=n(58579),p=n(63805),f=n(82758),m=n(65478),g=n(580),b=n(21537),y=n(50911),w=n(2692),_=n(18549),C=n(54747);class k extends y.Plugin{get state(){return this.stateManager.state}get toolRegistry(){return new d.ToolRegistry(this.j)}get permissionManager(){return new a.PermissionManager(this.j,this.toolRegistry)}get apiClient(){return new s.APIClient(this.j,this.toolRegistry)}get storage(){let{storage:t,storageKey:i,maxConversations:n}=this.j.o.aiAssistantPro;if("string"==typeof t){let o=(0,c.createStorageProvider)(t,i);return new c.WebStorageConversationStorage(o,n)}return t}get stateManager(){return new l.StateManager(this.j)}get mainPanel(){return new u.UIMainPanel(this.j,this.stateManager.state,this.j.o.aiAssistantPro,t=>{let i=this.stateManager.getCurrentConversation();i&&this.stateManager.setCurrentConversation({...i,...t})})}get dialog(){let t=this.j.dlg({resizable:this.j.o.aiAssistantPro.resizable,eventEmmiter:this.j.e});return t.e.on(t,"afterClose",()=>{this.j.e.fire("closeAIAssistantPro.ai-assistant-pro")}),t}setupTextAutocomplete(){let{textAutocompleteEnabled:t,textAutocompleteApiRequest:i,textAutocompleteMinQueryLength:n,textAutocompleteMaxSuggestions:o,textAutocompleteDebounceMs:r,textAutocompleteCacheTTL:s,textAutocompleteCacheMaxSize:a}=this.j.o.aiAssistantPro;if(!t||!i)return;this.j.o.autocomplete={...this.j.o.autocomplete,displayMode:"inline"};let l=this.textAutocompleteCache,c=null;this.textAutocompleteSource=t=>{if(t.length<n)return[];let d=`${t}:${o}`;if(s>0){let t=l.get(d);if(t&&Date.now()-t.ts<s)return t.data.map(t=>({value:t,title:t}))}c&&clearTimeout(c);let u=new AbortController;return new Promise(n=>{c=setTimeout(async()=>{try{let r=await i(t,o,u.signal);if(Array.isArray(r)){let t=r.slice(0,o);if(s>0){if(l.size>=a){let t=l.keys().next().value;null!=t&&l.delete(t)}l.set(d,{ts:Date.now(),data:t})}n(t.map(t=>({value:t,title:t})));return}n([])}catch{n([])}},r)})},this.j.e.fire("registerAutocompleteSource",this.textAutocompleteSource)}afterInit(){(0,g.extendLang)(p),this.setupEventListeners(),this.setupTextAutocomplete(),this.j.async.promise(t=>{let{initiallyOpened:i,persistOpenState:n}=this.j.o.aiAssistantPro,o=i;n?this.storage.getGlobalSettings().then(t=>{if(t?.isOpen!=null&&(o=t.isOpen),o)return this.openAssistant()}).catch(()=>null).finally(()=>t(void 0)):t(void 0)}).catch(()=>null)}__loadData(){return this.__initedPromise?this.__initedPromise:this.isDestructed?Promise.reject():(this.__initedPromise=this.j.async.promise(t=>{this.loadInitialData().then(t)}).catch(()=>null),this.__initedPromise)}async loadInitialData(){this.mainPanel.setMod("ready",!0),await (0,h.loadInitialData)(this.j,this.storage,this.stateManager),await this.restorePendingToolCalls()}async restorePendingToolCalls(){let t=this.stateManager.getCurrentConversation();if(!t)return;let i=(0,h.findMessagesWithPendingToolCalls)(t);if(0!==i.length)for(let t of i)await this.handleToolCalls(t.id)}setupEventListeners(){this.j.e.on("selectConversation.ai-assistant-pro",async t=>{try{await this.__loadData(),await (0,h.handleConversationSelect)(t,this.storage,this.stateManager)}catch(t){f.IS_PROD}}),this.j.e.on("newConversation.ai-assistant-pro",async()=>{await this.__loadData();let t=(0,h.createNewConversation)(this.j,this.state.defaultModel,this.state.defaultTemperature);this.stateManager.setCurrentConversation(t)}),this.j.e.on("deleteConversation.ai-assistant-pro",async t=>{await this.__loadData(),await this.deleteConversation(t)}),this.j.e.on("renameConversation.ai-assistant-pro",async(t,i)=>{await this.__loadData(),await this.renameConversation(t,i)}),this.j.e.on("backToList.ai-assistant-pro",async()=>{await this.__loadData(),await (0,h.handleBackToList)(this.storage,this.stateManager)}),this.j.e.on("removeContext.ai-assistant-pro",async t=>{await this.__loadData(),this.stateManager.removeSelectionContext(t)}),this.j.e.on("approveToolCall.ai-assistant-pro",async(t,i)=>{try{await this.__loadData();let n=await (0,h.handleToolApproval)(t,i,this.stateManager,this.permissionManager,this.storage);if(n){let t=this.stateManager.getCurrentConversation();if(!t)return;let i=t.messages.find(t=>t.toolCalls?.some(t=>t.id===n.id));if(!i)return;await this.executeToolCall(i.id,n)}}catch(t){if((0,b.isAbortError)(t))return;this.stateManager.setError(t instanceof Error?t.message:t+"")}}),this.j.e.on("denyToolCall.ai-assistant-pro",async t=>{await this.__loadData(),await (0,h.handleToolDenial)(this.j,t,this.stateManager,this.storage)}),this.j.e.on("abortRequest.ai-assistant-pro",async()=>{await this.__loadData(),this.apiClient.abort(),this.stateManager.setLoading(!1)})}__applyTheme(){(0,h.applyTheme)(this.j,this.stateManager.state.theme,this.stateManager.state.displayMode,this.mainPanel.container,this.dialog)}async openAssistant(){if(this.stateManager.isOpen()){this.stateManager.close(),await this.__closeInContainer();return}await this.__loadData(),this.isDestructed||(this.stateManager.open(),await this.__openInContainer(),this.j.o.aiAssistantPro.includeSelectionByDefault&&!this.j.s.isCollapsed()&&this.addCurrentSelectionToContext())}async __openInContainer(){let{resizable:t,allowClose:i,flightPanelHeight:n}=this.j.o.aiAssistantPro,{displayMode:o="right",panelWidth:r,panelHeight:s}=this.stateManager.state;switch(this.__applyTheme(),this.mainPanel.setMod("displayMode",o),this.mainPanel.setMod("allowClose",i),this.mainPanel.setParentView("dialog"===o||"flight"===o?this.dialog:this.j),this.__openedMode=o,o){case"dialog":this.dialog.setSize(r,s).open().setContent(this.mainPanel.container);break;case"flight":_.UIFlightPosition.install(this.mainPanel,this.j.container,{panelHeight:n,containerClassName:this.getFullElName("flight-container")});break;default:t&&(C.UIResize.remove(this.mainPanel),C.UIResize.install(this.mainPanel,(0,h.invertMode)(o),{handleClassName:this.getFullElName("ai-assistent-resize-handle"),onResize:({newSize:t})=>{let i="left"===o||"right"===o?t:r,n="top"===o||"bottom"===o?t:s;return this.stateManager.state.panelWidth=i,this.stateManager.state.panelHeight=n,!0}})),this.j.currentPlace.slots[o].appendChild(this.mainPanel.container),(0,h.resizeInPanelView)(this.j,o,r,s)}}__onResizeInPanelView(){let{displayMode:t,panelWidth:i,panelHeight:n}=this.stateManager.state;(0,h.resizeInPanelView)(this.j,t,i,n)}async __closeInContainer(){let{displayMode:t}=await this.stateManager.state;switch(this.__openedMode!==t&&"dialog"===this.__openedMode&&this.dialog.close(),this.__openedMode!==t&&"flight"===this.__openedMode&&this.__closeFlightMode(),t){case"dialog":this.dialog.close();break;case"flight":this.__closeFlightMode();break;default:this.mainPanel.container.remove()}}__closeFlightMode(){_.UIFlightPosition.remove(this.mainPanel)}__onSavedStateChange(){let t=this.stateManager.state;return this.storage.saveGlobalSettings({displayMode:t.displayMode,panelWidth:t.panelWidth,panelHeight:t.panelHeight,theme:t.theme,defaultModel:t.defaultModel,defaultTemperature:t.defaultTemperature,currentConversationId:t.currentConversation?.id,...this.j.o.aiAssistantPro.persistOpenState?{isOpen:t.isOpen}:{}})}async closeAssistant(){this.stateManager.isOpen()&&(await this.__loadData(),this.stateManager.close(),this.__closeInContainer())}async addCurrentSelectionToContext(){await this.__loadData();let t=(0,h.getCurrentSelectionContext)(this.j);t&&this.stateManager.addSelectionContext(t)}async executeQuickCommand(t){let i,{quickCommandsSilentMode:n,quickCommandsDisplayMode:o}=this.j.o.aiAssistantPro,r=this.j.o.aiAssistant;if(r&&r[t]&&(0,b.isString)(r[t])&&(i=r[t]),!i)return void this.j.e.fire("error","Command not found: "+t);let s=this.j.s.isCollapsed()?this.j.value:this.j.s.html;if(!s)return;let a=r?.aiCommonPrefixPrompt||"",l=r?.aiCommonSuffixPrompt||"",c=`${a}${i}${l}
|
|
278
|
+
>${t.o.specialCharacters[i]}</a>`);l.push(s),r.appendChild(s),n.appendChild(r)}s.appendChild(n)}let c=this;return t.e.on(l,"focus",function(){n.innerHTML=this.innerHTML}).on(l,"mousedown",function(i){r.Dom.isTag(this,"a")&&(t.s.focus(),t.s.insertHTML(this.innerHTML),(null==i?void 0:i.shiftKey)||t.e.fire(this,"close_dialog"),i&&i.preventDefault(),i&&i.stopImmediatePropagation())}).on(l,"mouseenter",function(){r.Dom.isTag(this,"a")&&this.focus()}).on(l,"keydown",i=>{let n=i.target;if(r.Dom.isTag(n,"a")){let r,s=parseInt((0,a.attr)(n,"-index")||"0",10),d=parseInt((0,a.attr)(n,"data-index-j")||"0",10);switch(i.key){case o.KEY_UP:case o.KEY_DOWN:void 0===l[r=i.key===o.KEY_UP?s-c.__countInRow:s+c.__countInRow]&&(r=i.key===o.KEY_UP?Math.floor(l.length/c.__countInRow)*c.__countInRow+d:d)>l.length-1&&(r-=c.__countInRow),l[r]&&l[r].focus();break;case o.KEY_RIGHT:case o.KEY_LEFT:void 0===l[r=i.key===o.KEY_LEFT?s-1:s+1]&&(r=i.key===o.KEY_LEFT?l.length-1:0),l[r]&&l[r].focus();break;case o.KEY_ENTER:t.e.fire(n,"mousedown"),i.stopImmediatePropagation(),i.preventDefault()}}}),i})}beforeDestruct(t){t.e.off("generateSpecialCharactersTable.symbols")}constructor(t){super(t),this.buttons=[{name:"symbols",group:"insert"}],this.__countInRow=17,(0,s.extendLang)(c)}}s.pluginSystem.add("symbols",d)},5119:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 270 270"> <path d="m240.443652,220.45085l-47.410809,0l0,-10.342138c13.89973,-8.43655 25.752896,-19.844464 34.686646,-33.469923c11.445525,-17.455846 17.496072,-37.709239 17.496072,-58.570077c0,-59.589197 -49.208516,-108.068714 -109.693558,-108.068714s-109.69263,48.479517 -109.69263,108.069628c0,20.860839 6.050547,41.113316 17.497001,58.570077c8.93375,13.625459 20.787845,25.032458 34.686646,33.469008l0,10.342138l-47.412666,0c-10.256959,0 -18.571354,8.191376 -18.571354,18.296574c0,10.105198 8.314395,18.296574 18.571354,18.296574l65.98402,0c10.256959,0 18.571354,-8.191376 18.571354,-18.296574l0,-39.496814c0,-7.073455 -4.137698,-13.51202 -10.626529,-16.537358c-25.24497,-11.772016 -41.557118,-37.145704 -41.557118,-64.643625c0,-39.411735 32.545369,-71.476481 72.549922,-71.476481c40.004553,0 72.550851,32.064746 72.550851,71.476481c0,27.497006 -16.312149,52.87161 -41.557118,64.643625c-6.487902,3.026253 -10.6256,9.464818 -10.6256,16.537358l0,39.496814c0,10.105198 8.314395,18.296574 18.571354,18.296574l65.982163,0c10.256959,0 18.571354,-8.191376 18.571354,-18.296574c0,-10.105198 -8.314395,-18.296574 -18.571354,-18.296574z"/> </svg> '},47686:function(t,i,n){"use strict";n.d(i,{onTabInsideLi:function(){return o.onTabInsideLi}});var o=n(26658)},26658:function(t,i,n){"use strict";n.d(i,{onTabInsideLi:function(){return s}});var o=n(2748),r=n(38837);function s(t,i=!1){let n,a,l,c;if(!t.o.tab.tabInsideLiInsertNewList)return!1;let[d,u]=(n=t.createInside.fake(),a=t.createInside.fake(),(l=t.s.range.cloneRange()).collapse(!0),l.insertNode(n),(c=t.s.range.cloneRange()).collapse(!1),c.insertNode(a),[n,a]);try{let n,s,a,l,c,u=!!(n=o.Dom.closest(d,"li",t.editor))&&(!!i||!!o.Dom.isLeaf(n.previousElementSibling))&&(!i||!!o.Dom.closest(n,"li",t.editor))&&n;if(!u||!(s=o.Dom.closest(d,"li",t.editor))||s!==u&&!u.contains(s))return!1;let h=o.Dom.closest(u,["ol","ul"],t.editor);if(!h||i&&!o.Dom.closest(h,"li",t.editor))return!1;return i?function(t,i,n){let s=o.Dom.closest(i,"li",t.editor);(0,r.assert)(s,"tab parent li is null");let a=Array.from(i.children).filter(t=>o.Dom.isLeaf(t));o.Dom.after(s,n);let l=a.indexOf(n);if((0===l||1===a.length)&&o.Dom.safeRemove(i),l!==a.length-1){let t=i.cloneNode();o.Dom.append(n,t);for(let i=l+1;i<a.length;i+=1)o.Dom.append(t,a[i])}}(t,h,u):(a=u.previousElementSibling,(0,r.assert)(a,"tab previousElementSibling is null"),l=a.lastElementChild,(c=o.Dom.isTag(l,h.tagName)?l:t.createInside.element(h.tagName,Array.from(h.attributes).reduce((t,i)=>(t[i.name]=i.value,t),{}))).appendChild(u),l!==c&&a.appendChild(c)),!0}finally{let i=t.s.createRange();i.setStartAfter(d),i.setEndBefore(u),t.s.selectRange(i),o.Dom.safeRemove(d),o.Dom.safeRemove(u)}}},66288:function(t,i,n){"use strict";n(6441).Config.prototype.tab={tabInsideLiInsertNewList:!0}},767:function(t,i,n){"use strict";var o=n(82758),r=n(65478),s=n(580),a=n(50911);n(66288);var l=n(47686),c=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a};class d extends a.Plugin{afterInit(t){}__onTab(t){if(t.key===o.KEY_TAB&&this.__onShift(t.shiftKey))return!1}__onCommand(t){if(("indent"===t||"outdent"===t)&&this.__onShift("outdent"===t))return!1}__onShift(t){let i=(0,l.onTabInsideLi)(this.j,t);return i&&this.j.e.fire("afterTab",t),i}beforeDestruct(t){}}c([(0,r.watch)(":keydown.tab")],d.prototype,"__onTab",null),c([(0,r.watch)(":beforeCommand.tab")],d.prototype,"__onCommand",null),s.pluginSystem.add("tab",d)},72439:function(t,i,n){"use strict";var o=n(82758),r=n(2748),s=n(580),a=n(21537),l=n(76014);let c=new Set([o.KEY_TAB,o.KEY_LEFT,o.KEY_RIGHT,o.KEY_UP,o.KEY_DOWN]);s.pluginSystem.add("tableKeyboardNavigation",function(t){t.e.off(".tableKeyboardNavigation").on("keydown.tableKeyboardNavigation",i=>{let{key:n}=i,s=function(t,i){if(!c.has(i))return;let n=t.s.current();if(!n)return;let s=r.Dom.up(n,r.Dom.isCell,t.editor);if(!s)return;let{range:l}=t.s;if(i!==o.KEY_TAB&&n!==s){let t=i===o.KEY_RIGHT||i===o.KEY_DOWN,c=(0,a.call)(t?r.Dom.next:r.Dom.prev,n,t=>i===o.KEY_UP||i===o.KEY_DOWN?r.Dom.isTag(t,"br"):!!t,s);if(!t&&(c||i!==o.KEY_UP&&r.Dom.isText(n)&&0!==l.startOffset)||t&&(c||i!==o.KEY_DOWN&&r.Dom.isText(n)&&n.nodeValue&&l.startOffset!==n.nodeValue.length))return}return s}(t,n);if(!s)return;let d=t.getInstance(l.Table,t.o),u=r.Dom.closest(s,"table",t.editor),h=null,p=n===o.KEY_LEFT||i.shiftKey,f=()=>(0,a.call)(p?r.Dom.prev:r.Dom.next,s,r.Dom.isCell,u);switch(n){case o.KEY_TAB:case o.KEY_LEFT:(h=f())||(d.appendRow(u,!!p&&u.querySelector("tr"),!p),h=f());break;case o.KEY_UP:case o.KEY_DOWN:{let t=d.formalMatrix(u),[i,r]=d.formalCoordinate(u,s);n===o.KEY_UP?void 0!==t[i-1]&&(h=t[i-1][r]):void 0!==t[i+1]&&(h=t[i+1][r])}}if(h){if(t.e.fire("hidePopup hideResizer"),h.firstChild)n===o.KEY_TAB?t.s.select(h,!0):t.s.setCursorIn(h,n===o.KEY_RIGHT||n===o.KEY_DOWN);else{let i=t.createInside.element("br");h.appendChild(i),t.s.setCursorBefore(i)}return t.synchronizeValues(),!1}})})},40329:function(t,i,n){"use strict";var o=n(82758),r=n(22732),s=n(21537),a=n(43555),l=n(12153),c=n(6441),d=n(6091);c.Config.prototype.table={splitBlockOnInsertTable:!0,selectionCellStyle:"border: 1px double #1e88e5 !important;",useExtraClassesOptions:!1},l.Icon.set("table",d.default),c.Config.prototype.controls.table={data:{cols:10,rows:10,classList:{"table table-bordered":"Bootstrap Bordered","table table-striped":"Bootstrap Striped","table table-dark":"Bootstrap Dark"}},popup(t,i,n,l){t.editor.normalize();let c=t.history.snapshot.make(),d=l.control,u=d.data&&d.data.rows?d.data.rows:10,h=d.data&&d.data.cols?d.data.cols:10,p=t.c.fromHTML('<form class="jodit-form jodit-form__inserter"><div class="jodit-form__table-creator-box"><div class="jodit-form__container"></div><div class="jodit-form__options">'+(()=>{if(!t.o.table.useExtraClassesOptions)return"";let i=[];if(d.data){let t=d.data.classList;Object.keys(t).forEach(n=>{i.push(`<label class="jodit_vertical_middle"><input class="jodit-checkbox" value="${n}" type="checkbox"/>${t[n]}</label>`)})}return i.join("")})()+'</div></div><label class="jodit-form__center"><span>1</span> × <span>1</span></label></form>'),f=p.querySelectorAll("span")[0],m=p.querySelectorAll("span")[1],g=p.querySelector(".jodit-form__container"),b=p.querySelector(".jodit-form__options"),y=[],w=u*h;(0,a.attr)(g,{role:"grid",ariaLabel:"Table size",ariaRowcount:u,ariaColcount:h});for(let i=0;i<w;i+=1)if(!y[i]){let n=Math.floor(i/h)+1,o=i%h+1;y.push(t.c.element("span",{dataIndex:i,role:"gridcell",tabindex:0===i?0:-1,ariaLabel:`${n} by ${o}`}))}let _=t=>{let i=parseInt((0,a.attr)(t,"-index")||"0",10),n=Math.ceil((i+1)/h),o=i%h+1;for(let t=0;t<y.length;t+=1)o>=t%h+1&&n>=Math.ceil((t+1)/h)?y[t].className="jodit_hovered":y[t].className="";m.textContent=o.toString(),f.textContent=n.toString()},C=i=>{let o=parseInt((0,a.attr)(i,"-index")||"0",10),l=Math.ceil((o+1)/h),d=o%h+1,u=t.createInside,p=u.element("tbody"),f=u.element("table");f.appendChild(p);let m=null,g,y;for(let t=1;l>=t;t+=1){g=u.element("tr");for(let t=1;t<=d;t+=1)y=u.element("td"),m||(m=y),(0,s.css)(y,"width",(100/d).toFixed(4)+"%"),y.appendChild(u.element("br")),g.appendChild(u.text(`
|
|
279
|
+
`)),g.appendChild(u.text(" ")),g.appendChild(y);p.appendChild(u.text(`
|
|
280
|
+
`)),p.appendChild(g)}(0,s.$$)("input[type=checkbox]:checked",b).forEach(t=>{t.value.split(/[\s]+/).forEach(t=>{f.classList.add(t)})}),t.s.restore(),t.s.removeMarkers(),t.editor.normalize(),t.history.snapshot.restore(c);let w=r.Dom.furthest(t.s.current(),r.Dom.isBlock,t.editor);if(w&&r.Dom.isEmpty(w))r.Dom.replace(w,f,void 0,!1,!0);else if(w){let i=u.text(`
|
|
281
|
+
`);if(t.o.table.splitBlockOnInsertTable){let n=t.s.range;n.collapse(!1),n.insertNode(i),n.collapse(!1),t.s.selectRange(n);let o=t.s.splitSelection(w,i);o?r.Dom.after(o,f):r.Dom.after(w,f)}else r.Dom.after(w,i),r.Dom.after(i,f)}else t.s.insertNode(f,!1);m&&(t.s.setCursorIn(m),(0,s.scrollIntoViewIfNeeded)(m,t.editor,t.ed)),n()};if(t.e.on(g,"mousemove",t=>{r.Dom.isTag(t.target,"span")&&_(t.target)}).on(g,"touchstart mousedown",t=>{r.Dom.isTag(t.target,"span")&&(t.preventDefault(),t.stopImmediatePropagation(),C(t.target))}).on(g,"keydown",t=>{if(!r.Dom.isTag(t.target,"span"))return;if(t.key===o.KEY_ENTER){t.preventDefault(),t.stopImmediatePropagation(),C(t.target);return}if(t.key===o.KEY_ESC){t.preventDefault(),t.stopImmediatePropagation(),n();return}let i=parseInt((0,a.attr)(t.target,"-index")||"0",10),s=Math.floor(i/h),l=i%h,c=i;switch(t.key){case o.KEY_LEFT:c=l>0?i-1:i;break;case o.KEY_RIGHT:c=l<h-1?i+1:i;break;case o.KEY_UP:c=s>0?i-h:i;break;case o.KEY_DOWN:c=s<u-1?i+h:i;break;default:return}t.preventDefault(),t.stopImmediatePropagation(),c!==i&&(y[i].tabIndex=-1,y[c].tabIndex=0,y[c].focus(),_(y[c]))}),l&&l.parentElement){for(let i=0;i<u;i+=1){let n=t.c.div();(0,a.attr)(n,"role","row");for(let t=0;t<h;t+=1)n.appendChild(y[i*h+t]);g.appendChild(n)}y[0]&&(y[0].className="hovered")}return p},tooltip:"Insert table"}},43003:function(t,i,n){"use strict";var o=n(580);n(40329),o.pluginSystem.add("table",function(t){t.registerButton({name:"table",group:"insert"})})},6091:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M576 1376v-192q0-14-9-23t-23-9h-320q-14 0-23 9t-9 23v192q0 14 9 23t23 9h320q14 0 23-9t9-23zm0-384v-192q0-14-9-23t-23-9h-320q-14 0-23 9t-9 23v192q0 14 9 23t23 9h320q14 0 23-9t9-23zm512 384v-192q0-14-9-23t-23-9h-320q-14 0-23 9t-9 23v192q0 14 9 23t23 9h320q14 0 23-9t9-23zm-512-768v-192q0-14-9-23t-23-9h-320q-14 0-23 9t-9 23v192q0 14 9 23t23 9h320q14 0 23-9t9-23zm512 384v-192q0-14-9-23t-23-9h-320q-14 0-23 9t-9 23v192q0 14 9 23t23 9h320q14 0 23-9t9-23zm512 384v-192q0-14-9-23t-23-9h-320q-14 0-23 9t-9 23v192q0 14 9 23t23 9h320q14 0 23-9t9-23zm-512-768v-192q0-14-9-23t-23-9h-320q-14 0-23 9t-9 23v192q0 14 9 23t23 9h320q14 0 23-9t9-23zm512 384v-192q0-14-9-23t-23-9h-320q-14 0-23 9t-9 23v192q0 14 9 23t23 9h320q14 0 23-9t9-23zm0-384v-192q0-14-9-23t-23-9h-320q-14 0-23 9t-9 23v192q0 14 9 23t23 9h320q14 0 23-9t9-23zm128-320v1088q0 66-47 113t-113 47h-1344q-66 0-113-47t-47-113v-1088q0-66 47-113t113-47h1344q66 0 113 47t47 113z"/> </svg> '},14984:function(t,i,n){"use strict";var o=n(21537),r=n(62843),s=n(2525),a=n(12153),l=n(6441),c=n(92762),d=n(37775);l.Config.prototype.video={parseUrlToVideoEmbed:o.convertMediaUrlToVideoEmbed,defaultWidth:400,defaultHeight:345},a.Icon.set("video",d.default),l.Config.prototype.controls.video={popup(t,i,n){let a=new s.UIForm(t,[new s.UIBlock(t,[new s.UIInput(t,{name:"url",required:!0,label:"URL",placeholder:"https://",validators:["url"]})]),new s.UIBlock(t,[(0,r.Button)(t,"","Insert","primary").onAction(()=>a.submit())])]),l=new s.UIForm(t,[new s.UIBlock(t,[new s.UITextArea(t,{name:"code",required:!0,label:"Embed code"})]),new s.UIBlock(t,[(0,r.Button)(t,"","Insert","primary").onAction(()=>l.submit())])]),d=[],u=i=>{t.s.restore(),t.s.insertHTML(i),n()};return t.s.save(),d.push({icon:"link",name:"Link",content:a.container},{icon:"source",name:"Code",content:l.container}),a.onSubmit(i=>{var n,r,s,a;u((0,o.call)(null!=(r=null==(n=t.o.video)?void 0:n.parseUrlToVideoEmbed)?r:o.convertMediaUrlToVideoEmbed,i.url,{width:null==(s=t.o.video)?void 0:s.defaultWidth,height:null==(a=t.o.video)?void 0:a.defaultHeight}))}),l.onSubmit(t=>{u(t.code)}),(0,c.TabsWidget)(t,d)},tags:["iframe"],tooltip:"Insert youtube/vimeo video"}},26551:function(t,i,n){"use strict";var o=n(580);n(14984),o.pluginSystem.add("video",function(t){t.registerButton({name:"video",group:"media"})})},37775:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1792 352v1088q0 42-39 59-13 5-25 5-27 0-45-19l-403-403v166q0 119-84.5 203.5t-203.5 84.5h-704q-119 0-203.5-84.5t-84.5-203.5v-704q0-119 84.5-203.5t203.5-84.5h704q119 0 203.5 84.5t84.5 203.5v165l403-402q18-19 45-19 12 0 25 5 39 17 39 59z"/> </svg> '},96967:function(t,i,n){"use strict";n(6441).Config.prototype.wrapNodes={exclude:new Set(["hr","style","br"]),emptyBlockAfterInit:!0}},72253:function(t,i,n){"use strict";var o=n(65478),r=n(22732),s=n(580),a=n(70799),l=n(50911);n(96967);var c=function(t,i,n,o){var r,s=arguments.length,a=s<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,n,o);else for(var l=t.length-1;l>=0;l--)(r=t[l])&&(a=(s<3?r(a):s>3?r(i,n,a):r(i,n))||a);return s>3&&a&&Object.defineProperty(i,n,a),a};class d extends l.Plugin{afterInit(t){"br"!==t.o.enter.toLowerCase()&&t.e.on("drop.wtn focus.wtn keydown.wtn mousedown.wtn afterInit.wtn backSpaceAfterDelete.wtn",this.preprocessInput,{top:!0}).on("afterInit.wtn postProcessSetEditorValue.wtn afterCommitStyle.wtn backSpaceAfterDelete.wtn",this.postProcessSetEditorValue)}beforeDestruct(t){t.e.off(".wtn")}postProcessSetEditorValue(){let{jodit:t}=this;if(!t.isEditorMode())return;let i=t.editor.firstChild,n=!1;for(;i;){if(i=function(t,i){let n=t,o=t;do if(r.Dom.isElement(o)&&r.Dom.isLeaf(o)&&!r.Dom.isList(o.parentElement)){let t=r.Dom.findNotEmptySibling(o,!1);r.Dom.isTag(n,"ul")?n.appendChild(o):n=r.Dom.wrap(o,"ul",i.createInside),o=t}else break;while(o)return n}(i,t),this.isSuitableStart(i)){n||t.s.save(),n=!0;let o=t.createInside.element(t.o.enter);for(r.Dom.before(i,o);i&&this.isSuitable(i);){let t=i.nextSibling;o.appendChild(i),i=t}o.normalize(),i=o}i=i&&i.nextSibling}n&&(t.s.restore(),"afterInit"===t.e.current&&t.e.fire("internalChange"))}preprocessInput(){let{jodit:t}=this,i="afterInit"===t.e.current;if(!t.isEditorMode()||t.editor.firstChild||!t.o.wrapNodes.emptyBlockAfterInit&&i)return;let n=t.createInside.element(t.o.enter),o=t.createInside.element("br");r.Dom.append(n,o),r.Dom.append(t.editor,n),(t.s.isFocused()||"backSpaceAfterDelete"===t.e.current)&&t.s.setCursorBefore(o),t.e.fire("internalChange")}constructor(){super(...arguments),this.isSuitableStart=t=>{var i;return r.Dom.isText(t)&&(0,a.isString)(t.nodeValue)&&(/[^\s]/.test(t.nodeValue)||(null==(i=t.parentNode)?void 0:i.firstChild)===t&&this.isSuitable(t.nextSibling))||this.isNotWrapped(t)&&!r.Dom.isTemporary(t)},this.isSuitable=t=>r.Dom.isText(t)||this.isNotWrapped(t),this.isNotWrapped=t=>r.Dom.isElement(t)&&!(r.Dom.isBlock(t)||r.Dom.isTag(t,this.j.o.wrapNodes.exclude))}}c([o.autobind],d.prototype,"postProcessSetEditorValue",null),c([o.autobind],d.prototype,"preprocessInput",null),s.pluginSystem.add("wrapNodes",d)},86012:function(t,i,n){"use strict";n(6441).Config.prototype.showXPathInStatusbar=!0},83671:function(t,i,n){"use strict";var o=n(82758),r=n(22732),s=n(580),a=n(49055),l=n(29960),c=n(76078),d=n(50911),u=n(80870),h=n(21491);n(86012);class p extends d.Plugin{afterInit(){if(this.j.o.showXPathInStatusbar){this.container=this.j.c.div("jodit-xpath"),(0,l.attr)(this.container,"role","list");let t=()=>{this.j.o.showXPathInStatusbar&&this.container&&(this.j.statusbar.append(this.container),this.j.getRealMode()===o.MODE_WYSIWYG?this.calcPath():(this.container&&(this.container.innerHTML=o.INVISIBLE_SPACE),this.appendSelectAll()))};this.j.e.off(".xpath").on("pointerup.xpath change.xpath keydown.xpath changeSelection.xpath",this.calcPath).on("afterSetMode.xpath afterInit.xpath changePlace.xpath",t),t(),this.calcPath()}}beforeDestruct(){this.j&&this.j.events&&this.j.e.off(".xpath"),this.removeSelectAll(),this.menu&&this.menu.destruct(),r.Dom.safeRemove(this.container),delete this.menu,delete this.container}constructor(){super(...arguments),this.onContext=(t,i)=>(this.menu||(this.menu=new u.ContextMenu(this.j)),this.menu.show(i.clientX,i.clientY,[{icon:"bin",title:t===this.j.editor?"Clear":"Remove",exec:()=>{t!==this.j.editor?r.Dom.safeRemove(t):this.j.value="",this.j.synchronizeValues()}},{icon:"select-all",title:"Select",exec:()=>{this.j.s.select(t)}}]),!1),this.onSelectPath=(t,i)=>{this.j.s.focus();let n=(0,l.attr)(i.target,"-path")||"/";if("/"===n)return this.j.execCommand("selectall"),!1;try{let t=this.j.ed.evaluate(n,this.j.editor,null,XPathResult.ANY_TYPE,null).iterateNext();if(t)return this.j.s.select(t),!1}catch(t){}return this.j.s.select(t),!1},this.tpl=(t,i,n,o)=>{let r=this.j.c.fromHTML(`<span class="jodit-xpath__item"><a role="button" data-path="${i}" title="${o}" tabindex="-1"'>${(0,a.trim)(n)}</a></span>`),s=r.firstChild;return this.j.e.on(s,"click",this.onSelectPath.bind(this,t)).on(s,"contextmenu",this.onContext.bind(this,t)),r},this.removeSelectAll=()=>{this.selectAllButton&&(this.selectAllButton.destruct(),delete this.selectAllButton)},this.appendSelectAll=()=>{this.removeSelectAll(),this.selectAllButton=(0,h.makeButton)(this.j,{name:"selectall",...this.j.o.controls.selectall}),this.selectAllButton.state.size="tiny",this.container&&this.container.insertBefore(this.selectAllButton.container,this.container.firstChild)},this.calcPathImd=()=>{if(this.isDestructed)return;let t=this.j.s.current();if(this.container&&(this.container.innerHTML=o.INVISIBLE_SPACE),t){let i,n,o;r.Dom.up(t,t=>{t&&this.j.editor!==t&&!r.Dom.isText(t)&&!r.Dom.isComment(t)&&(i=t.nodeName.toLowerCase(),n=(0,c.getXPathByElement)(t,this.j.editor).replace(/^\//,""),o=this.tpl(t,n,i,this.j.i18n("Select %s",i)),this.container&&this.container.insertBefore(o,this.container.firstChild))},this.j.editor)}this.appendSelectAll()},this.calcPath=this.j.async.debounce(this.calcPathImd,2*this.j.defaultTimeout,!0)}}s.pluginSystem.add("xpath",p)},78173:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1395 736q0 13-10 23l-466 466q-10 10-23 10t-23-10l-466-466q-10-10-10-23t10-23l50-50q10-10 23-10t23 10l393 393 393-393q10-10 23-10t23 10l50 50q10 10 10 23z"/> </svg> '},16260:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1203 544q0 13-10 23l-393 393 393 393q10 10 10 23t-10 23l-50 50q-10 10-23 10t-23-10l-466-466q-10-10-10-23t10-23l466-466q10-10 23-10t23 10l50 50q10 10 10 23z"/> </svg> '},37663:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1171 960q0 13-10 23l-466 466q-10 10-23 10t-23-10l-50-50q-10-10-10-23t10-23l393-393-393-393q-10-10-10-23t10-23l50-50q10-10 23-10t23 10l466 466q10 10 10 23z"/> </svg> '},51036:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1395 1184q0 13-10 23l-50 50q-10 10-23 10t-23-10l-393-393-393 393q-10 10-23 10t-23-10l-50-50q-10-10-10-23t10-23l466-466q10-10 23-10t23 10l466 466q10 10 10 23z"/> </svg> '},31554:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M704 1376v-704q0-14-9-23t-23-9h-64q-14 0-23 9t-9 23v704q0 14 9 23t23 9h64q14 0 23-9t9-23zm256 0v-704q0-14-9-23t-23-9h-64q-14 0-23 9t-9 23v704q0 14 9 23t23 9h64q14 0 23-9t9-23zm256 0v-704q0-14-9-23t-23-9h-64q-14 0-23 9t-9 23v704q0 14 9 23t23 9h64q14 0 23-9t9-23zm-544-992h448l-48-117q-7-9-17-11h-317q-10 2-17 11zm928 32v64q0 14-9 23t-23 9h-96v948q0 83-47 143.5t-113 60.5h-832q-66 0-113-58.5t-47-141.5v-952h-96q-14 0-23-9t-9-23v-64q0-14 9-23t23-9h309l70-167q15-37 54-63t79-26h320q40 0 79 26t54 63l70 167h309q14 0 23 9t9 23z"/> </svg> '},18309:function(t,i){"use strict";i.default='<svg viewBox="0 0 14 14" xmlns="http://www.w3.org/2000/svg"> <g stroke="none" stroke-width="1"> <path d="M14,1.4 L12.6,0 L7,5.6 L1.4,0 L0,1.4 L5.6,7 L0,12.6 L1.4,14 L7,8.4 L12.6,14 L14,12.6 L8.4,7 L14,1.4 Z"/> </g> </svg> '},99762:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1792 1344v128q0 26-19 45t-45 19h-1664q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1664q26 0 45 19t19 45zm-384-384v128q0 26-19 45t-45 19h-896q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h896q26 0 45 19t19 45zm256-384v128q0 26-19 45t-45 19h-1408q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1408q26 0 45 19t19 45zm-384-384v128q0 26-19 45t-45 19h-640q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h640q26 0 45 19t19 45z"/> </svg> '},7903:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1472 930v318q0 119-84.5 203.5t-203.5 84.5h-832q-119 0-203.5-84.5t-84.5-203.5v-832q0-119 84.5-203.5t203.5-84.5h832q63 0 117 25 15 7 18 23 3 17-9 29l-49 49q-10 10-23 10-3 0-9-2-23-6-45-6h-832q-66 0-113 47t-47 113v832q0 66 47 113t113 47h832q66 0 113-47t47-113v-254q0-13 9-22l64-64q10-10 23-10 6 0 12 3 20 8 20 29zm231-489l-814 814q-24 24-57 24t-57-24l-430-430q-24-24-24-57t24-57l110-110q24-24 57-24t57 24l263 263 647-647q24-24 57-24t57 24l110 110q24 24 24 57t-24 57z"/> </svg> '},58032:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 10 10"> <path d="M.941 4.523a.75.75 0 1 1 1.06-1.06l3.006 3.005 3.005-3.005a.75.75 0 1 1 1.06 1.06l-3.549 3.55a.75.75 0 0 1-1.168-.136L.941 4.523z"/> </svg> '},52507:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 24 24" > <circle cx="12" cy="12" r="2.2"/> <circle cx="12" cy="5" r="2.2"/> <circle cx="12" cy="19" r="2.2"/> </svg> '},43478:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1664 960q-152-236-381-353 61 104 61 225 0 185-131.5 316.5t-316.5 131.5-316.5-131.5-131.5-316.5q0-121 61-225-229 117-381 353 133 205 333.5 326.5t434.5 121.5 434.5-121.5 333.5-326.5zm-720-384q0-20-14-34t-34-14q-125 0-214.5 89.5t-89.5 214.5q0 20 14 34t34 14 34-14 14-34q0-86 61-147t147-61q20 0 34-14t14-34zm848 384q0 34-20 69-140 230-376.5 368.5t-499.5 138.5-499.5-139-376.5-368q-20-35-20-69t20-69q140-229 376.5-368t499.5-139 499.5 139 376.5 368q20 35 20 69z"/> </svg> '},60097:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1152 512v-472q22 14 36 28l408 408q14 14 28 36h-472zm-128 32q0 40 28 68t68 28h544v1056q0 40-28 68t-68 28h-1344q-40 0-68-28t-28-68v-1600q0-40 28-68t68-28h800v544z"/> </svg> '},49155:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1728 608v704q0 92-66 158t-158 66h-1216q-92 0-158-66t-66-158v-960q0-92 66-158t158-66h320q92 0 158 66t66 158v32h672q92 0 158 66t66 158z"/> </svg> '},17555:function(t,i,n){"use strict";n.r(i),n.d(i,{angle_down:function(){return o.default},angle_left:function(){return r.default},angle_right:function(){return s.default},angle_up:function(){return a.default},bin:function(){return l.default},cancel:function(){return c.default},center:function(){return d.default},check:function(){return u.default},chevron:function(){return h.default},dots:function(){return p.default},eye:function(){return f.default},file:function(){return m.default},folder:function(){return g.default},info_circle:function(){return b.default},left:function(){return y.default},lock:function(){return w.default},ok:function(){return _.default},pencil:function(){return C.default},plus:function(){return k.default},resize_handler:function(){return S.default},right:function(){return x.default},save:function(){return I.default},settings:function(){return E.default},unlock:function(){return T.default},update:function(){return j.default},upload:function(){return A.default},valign:function(){return P.default}});var o=n(78173),r=n(16260),s=n(37663),a=n(51036),l=n(31554),c=n(18309),d=n(99762),u=n(7903),h=n(58032),p=n(52507),f=n(43478),m=n(60097),g=n(49155),b=n(17176),y=n(57882),w=n(58908),_=n(24829),C=n(4038),k=n(45575),S=n(84858),x=n(445),I=n(36886),E=n(10766),T=n(33651),j=n(20362),A=n(12202),P=n(80152)},17176:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1152 1376v-160q0-14-9-23t-23-9h-96v-512q0-14-9-23t-23-9h-320q-14 0-23 9t-9 23v160q0 14 9 23t23 9h96v320h-96q-14 0-23 9t-9 23v160q0 14 9 23t23 9h448q14 0 23-9t9-23zm-128-896v-160q0-14-9-23t-23-9h-192q-14 0-23 9t-9 23v160q0 14 9 23t23 9h192q14 0 23-9t9-23zm640 416q0 209-103 385.5t-279.5 279.5-385.5 103-385.5-103-279.5-279.5-103-385.5 103-385.5 279.5-279.5 385.5-103 385.5 103 279.5 279.5 103 385.5z"/> </svg> '},57882:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1792 1344v128q0 26-19 45t-45 19h-1664q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1664q26 0 45 19t19 45zm-384-384v128q0 26-19 45t-45 19h-1280q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1280q26 0 45 19t19 45zm256-384v128q0 26-19 45t-45 19h-1536q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1536q26 0 45 19t19 45zm-384-384v128q0 26-19 45t-45 19h-1152q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1152q26 0 45 19t19 45z"/> </svg> '},58908:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"><path d="M640 768h512v-192q0-106-75-181t-181-75-181 75-75 181v192zm832 96v576q0 40-28 68t-68 28h-960q-40 0-68-28t-28-68v-576q0-40 28-68t68-28h32v-192q0-184 132-316t316-132 316 132 132 316v192h32q40 0 68 28t28 68z"/></svg> '},24829:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 32 32"> <path d="M27 4l-15 15-7-7-5 5 12 12 20-20z"/> </svg> '},4038:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"><path d="M491 1536l91-91-235-235-91 91v107h128v128h107zm523-928q0-22-22-22-10 0-17 7l-542 542q-7 7-7 17 0 22 22 22 10 0 17-7l542-542q7-7 7-17zm-54-192l416 416-832 832h-416v-416zm683 96q0 53-37 90l-166 166-416-416 166-165q36-38 90-38 53 0 91 38l235 234q37 39 37 91z"/></svg> '},45575:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"><path d="M1600 736v192q0 40-28 68t-68 28h-416v416q0 40-28 68t-68 28h-192q-40 0-68-28t-28-68v-416h-416q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h416v-416q0-40 28-68t68-28h192q40 0 68 28t28 68v416h416q40 0 68 28t28 68z"/></svg> '},84858:function(t,i){"use strict";i.default='<svg viewBox="0 0 13 13" xmlns="http://www.w3.org/2000/svg"> <path d="M5.9814 11.8049C5.59087 11.4144 5.59087 10.7812 5.9814 10.3907L10.224 6.14806C10.6146 5.75754 11.2477 5.75754 11.6383 6.14806C12.0288 6.53859 12.0288 7.17175 11.6383 7.56228L7.39561 11.8049C7.00509 12.1954 6.37192 12.1954 5.9814 11.8049Z"/> <path d="M0.707107 12.0208C0.316582 11.6303 0.316582 10.9971 0.707107 10.6066L10.6066 0.707121C10.9971 0.316597 11.6303 0.316596 12.0208 0.707121C12.4113 1.09764 12.4113 1.73081 12.0208 2.12133L2.12132 12.0208C1.7308 12.4114 1.09763 12.4114 0.707107 12.0208Z"/> </svg> '},445:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1792 1344v128q0 26-19 45t-45 19h-1664q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1664q26 0 45 19t19 45zm0-384v128q0 26-19 45t-45 19h-1280q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1280q26 0 45 19t19 45zm0-384v128q0 26-19 45t-45 19h-1536q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1536q26 0 45 19t19 45zm0-384v128q0 26-19 45t-45 19h-1152q-26 0-45-19t-19-45v-128q0-26 19-45t45-19h1152q26 0 45 19t19 45z"/> </svg> '},36886:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M512 1536h768v-384h-768v384zm896 0h128v-896q0-14-10-38.5t-20-34.5l-281-281q-10-10-34-20t-39-10v416q0 40-28 68t-68 28h-576q-40 0-68-28t-28-68v-416h-128v1280h128v-416q0-40 28-68t68-28h832q40 0 68 28t28 68v416zm-384-928v-320q0-13-9.5-22.5t-22.5-9.5h-192q-13 0-22.5 9.5t-9.5 22.5v320q0 13 9.5 22.5t22.5 9.5h192q13 0 22.5-9.5t9.5-22.5zm640 32v928q0 40-28 68t-68 28h-1344q-40 0-68-28t-28-68v-1344q0-40 28-68t68-28h928q40 0 88 20t76 48l280 280q28 28 48 76t20 88z"/> </svg> '},10766:function(t,i){"use strict";i.default='<svg viewBox="0 0 48 48" xmlns="http://www.w3.org/2000/svg"> <path stroke="null" d="m42.276011,26.302547c0.098397,-0.76605 0.172194,-1.54407 0.172194,-2.33406s-0.073797,-1.56801 -0.172194,-2.33406l5.202718,-3.961917c0.467384,-0.359086 0.602679,-1.005441 0.29519,-1.532101l-4.919828,-8.29489c-0.307489,-0.51469 -0.947067,-0.730142 -1.500548,-0.51469l-6.125186,2.405877c-1.266856,-0.945594 -2.656707,-1.747553 -4.157255,-2.357999l-0.922468,-6.343855c-0.110696,-0.562568 -0.614979,-1.005441 -1.229957,-1.005441l-9.839656,0c-0.614979,0 -1.119261,0.442873 -1.217657,1.005441l-0.922468,6.343855c-1.500548,0.610446 -2.890399,1.400436 -4.157255,2.357999l-6.125186,-2.405877c-0.553481,-0.203482 -1.193058,0 -1.500548,0.51469l-4.919828,8.29489c-0.307489,0.51469 -0.172194,1.161045 0.29519,1.532101l5.190419,3.961917c-0.098397,0.76605 -0.172194,1.54407 -0.172194,2.33406s0.073797,1.56801 0.172194,2.33406l-5.190419,3.961917c-0.467384,0.359086 -0.602679,1.005441 -0.29519,1.532101l4.919828,8.29489c0.307489,0.51469 0.947067,0.730142 1.500548,0.51469l6.125186,-2.405877c1.266856,0.945594 2.656707,1.747553 4.157255,2.357999l0.922468,6.343855c0.098397,0.562568 0.602679,1.005441 1.217657,1.005441l9.839656,0c0.614979,0 1.119261,-0.442873 1.217657,-1.005441l0.922468,-6.343855c1.500548,-0.610446 2.890399,-1.400436 4.157255,-2.357999l6.125186,2.405877c0.553481,0.203482 1.193058,0 1.500548,-0.51469l4.919828,-8.29489c0.307489,-0.51469 0.172194,-1.161045 -0.29519,-1.532101l-5.190419,-3.961917zm-18.277162,6.044617c-4.759934,0 -8.609699,-3.746465 -8.609699,-8.378677s3.849766,-8.378677 8.609699,-8.378677s8.609699,3.746465 8.609699,8.378677s-3.849766,8.378677 -8.609699,8.378677z"/> </svg> '},33651:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1728 576v256q0 26-19 45t-45 19h-64q-26 0-45-19t-19-45v-256q0-106-75-181t-181-75-181 75-75 181v192h96q40 0 68 28t28 68v576q0 40-28 68t-68 28h-960q-40 0-68-28t-28-68v-576q0-40 28-68t68-28h672v-192q0-185 131.5-316.5t316.5-131.5 316.5 131.5 131.5 316.5z"/> </svg> '},20362:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1639 1056q0 5-1 7-64 268-268 434.5t-478 166.5q-146 0-282.5-55t-243.5-157l-129 129q-19 19-45 19t-45-19-19-45v-448q0-26 19-45t45-19h448q26 0 45 19t19 45-19 45l-137 137q71 66 161 102t187 36q134 0 250-65t186-179q11-17 53-117 8-23 30-23h192q13 0 22.5 9.5t9.5 22.5zm25-800v448q0 26-19 45t-45 19h-448q-26 0-45-19t-19-45 19-45l138-138q-148-137-349-137-134 0-250 65t-186 179q-11 17-53 117-8 23-30 23h-199q-13 0-22.5-9.5t-9.5-22.5v-7q65-268 270-434.5t480-166.5q146 0 284 55.5t245 156.5l130-129q19-19 45-19t45 19 19 45z"/> </svg> '},12202:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1344 1472q0-26-19-45t-45-19-45 19-19 45 19 45 45 19 45-19 19-45zm256 0q0-26-19-45t-45-19-45 19-19 45 19 45 45 19 45-19 19-45zm128-224v320q0 40-28 68t-68 28h-1472q-40 0-68-28t-28-68v-320q0-40 28-68t68-28h427q21 56 70.5 92t110.5 36h256q61 0 110.5-36t70.5-92h427q40 0 68 28t28 68zm-325-648q-17 40-59 40h-256v448q0 26-19 45t-45 19h-256q-26 0-45-19t-19-45v-448h-256q-42 0-59-40-17-39 14-69l448-448q18-19 45-19t45 19l448 448q31 30 14 69z"/> </svg> '},80152:function(t,i){"use strict";i.default='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 1792 1792"> <path d="M1216 320q0 26-19 45t-45 19h-128v1024h128q26 0 45 19t19 45-19 45l-256 256q-19 19-45 19t-45-19l-256-256q-19-19-19-45t19-45 45-19h128v-1024h-128q-26 0-45-19t-19-45 19-45l256-256q19-19 45-19t45 19l256 256q19 19 19 45z"/> </svg> '},62357:function(t,i,n){"use strict";n.d(i,{UIRange:function(){return c}});var o=n(82749),r=n(31635),s=n(65478),a=n(21537),l=n(67510);class c extends l.UIInput{className(){return"UIRange"}appendUIRange(){let t=this.j.create.div(this.getFullElName("slider"));this.container.appendChild(t);let i=this.j.create.div(this.getFullElName("handle"));t.appendChild(i);let n=this.j.create.div(this.getFullElName("log")),o=this.getElm("label");o&&o.appendChild(n)}onDragStart(t){this.startValue=parseFloat(this.value)||0,this.startX=t.clientX;let i=this.getElm("slider");(0,a.assert)(null!=i,"slider element does not exists"),this.width=i.offsetWidth,this.j.e.on(this.j.ow,"mousemove",this.onDrag)}onDrag(t){let{min:i,max:n,step:o=1}=this.state,r=(t.clientX-this.startX)/this.width*(this.state.max-this.state.min),s=this.startValue+r;s<i&&(s=i),s>n&&(s=n),s=Math.round(s/o)*o,this.value=s.toFixed(10)}onDragEnd(){this.j.e.off(this.j.ow,"mousemove",this.onDrag)}onChangeSelfValue(){let t=this.getElm("handle"),i=parseFloat(this.value)||0;(0,a.assert)(null!=t,"Handle element does not exist"),(0,a.css)(t,{left:(i-this.state.min)/(this.state.max-this.state.min)*100+"%"});let n=this.getElm("log");(0,a.assert)(null!=n,"log element does not exist"),n.innerText=i.toString()}destruct(){return this.onDragEnd(),super.destruct()}constructor(t,i){super(t,{...i,type:"hidden"}),(0,o._)(this,"state",{...l.UIInput.defaultState,min:0,max:100,step:1}),(0,o._)(this,"startValue",0),(0,o._)(this,"startX",0),(0,o._)(this,"width",100),Object.assign(this.state,i),this.appendUIRange(),this.onChangeSelfValue()}}(0,r.__decorate)([(0,s.watch)(["handle:mousedown","handle:touchstart"])],c.prototype,"onDragStart",null),(0,r.__decorate)([s.autobind],c.prototype,"onDrag",null),(0,r.__decorate)([(0,s.watch)(["j.ow:mouseup","j.ow:touchend"])],c.prototype,"onDragEnd",null),(0,r.__decorate)([(0,s.watch)(":change")],c.prototype,"onChangeSelfValue",null),c=(0,r.__decorate)([s.component],c)},31356:function(t,i,n){"use strict";n.d(i,{ListReconciler:function(){return o}});class o{static reconcile(t,i,n){let{getId:o,isEqual:r=(t,i)=>o(t)===o(i),preserveOrder:s=!0}=n,a=new Map,l=new Map;t.forEach((t,i)=>{let n=o(t);a.set(n,t),l.set(n,i)});let c=new Map,d=new Map;i.forEach((t,i)=>{let n=o(t);c.set(n,t),d.set(n,i)});let u=[],h=[],p=[],f=[];return i.forEach((t,i)=>{let n=o(t),c=a.get(n);c?!r(c,t)||s&&l.get(n)!==i?h.push({oldItem:c,newItem:t,index:s?i:l.get(n)}):f.push(c):u.push(t)}),t.forEach(t=>{let i=o(t);c.has(i)||p.push(t)}),{toCreate:u,toUpdate:h,toRemove:p,unchanged:f}}static applyResult(t,i,n={}){i.toRemove.forEach(i=>{let o=t.indexOf(i);-1!==o&&(n.onRemove?.(i,o),t.splice(o,1))}),i.toUpdate.forEach(({oldItem:i,newItem:o,index:r})=>{let s=t.indexOf(i);-1!==s&&(n.onUpdate?.(i,o,r),t[s]=o)}),i.toCreate.forEach(i=>{n.onCreate?.(i,t.length),t.push(i)})}}},2692:function(t,i,n){"use strict";n.d(i,{JoditPro:function(){return l}});var o=n(82758),r=n(63799),s=n(41180),a=n(86019);class l extends a.Jodit{static make(t,i){return new this(t,i)}beforeInitHook(){if(o.IS_PROD&&!o.IS_TEST&&this.o.loadExternalConfig)return(0,r.appendScriptAsync)(this,this.basePath+"config.js")}afterInitHook(){(async()=>{if(await this.e.fire("checkReserve",location.host)!=="normal"){if(this.isInDestruct)return;let t=this.c.div("",'Trial version. Buy <a href="https://xdsoft.net/jodit/pro/">Jodit Pro</a>');o.IS_TEST||o.IS_PROD,(0,s.css)(t,{position:"absolute",color:"red",right:10,bottom:10}),this.addDisclaimer(t)}})().catch(()=>null),super.afterInitHook()}getVersion(){return"PRO "+o.APP_VERSION}}},41810:function(t,i,n){"use strict";var o=n(82749),r=n(31635);n(66645);var s=n(86449),a=n(21020),l=n(46166),c=n(62895),d=n(55487),u=n(27769),h=n(58579),p=n(63805),f=n(82758),m=n(65478),g=n(580),b=n(21537),y=n(50911),w=n(2692),_=n(18549),C=n(54747);class k extends y.Plugin{get state(){return this.stateManager.state}get toolRegistry(){return new d.ToolRegistry(this.j)}get permissionManager(){return new a.PermissionManager(this.j,this.toolRegistry)}get apiClient(){return new s.APIClient(this.j,this.toolRegistry)}get storage(){let{storage:t,storageKey:i,maxConversations:n}=this.j.o.aiAssistantPro;if("string"==typeof t){let o=(0,c.createStorageProvider)(t,i);return new c.WebStorageConversationStorage(o,n)}return t}get stateManager(){return new l.StateManager(this.j)}get mainPanel(){return new u.UIMainPanel(this.j,this.stateManager.state,this.j.o.aiAssistantPro,t=>{let i=this.stateManager.getCurrentConversation();i&&this.stateManager.setCurrentConversation({...i,...t})})}get dialog(){let t=this.j.dlg({resizable:this.j.o.aiAssistantPro.resizable,eventEmmiter:this.j.e});return t.e.on(t,"afterClose",()=>{this.j.e.fire("closeAIAssistantPro.ai-assistant-pro")}),t}setupTextAutocomplete(){let{textAutocompleteEnabled:t,textAutocompleteApiRequest:i,textAutocompleteMinQueryLength:n,textAutocompleteMaxSuggestions:o,textAutocompleteDebounceMs:r,textAutocompleteCacheTTL:s,textAutocompleteCacheMaxSize:a}=this.j.o.aiAssistantPro;if(!t||!i)return;this.j.o.autocomplete={...this.j.o.autocomplete,displayMode:"inline"};let l=this.textAutocompleteCache,c=null;this.textAutocompleteSource=t=>{if(t.length<n)return[];let d=`${t}:${o}`;if(s>0){let t=l.get(d);if(t&&Date.now()-t.ts<s)return t.data.map(t=>({value:t,title:t}))}c&&clearTimeout(c);let u=new AbortController;return new Promise(n=>{c=setTimeout(async()=>{try{let r=await i(t,o,u.signal);if(Array.isArray(r)){let t=r.slice(0,o);if(s>0){if(l.size>=a){let t=l.keys().next().value;null!=t&&l.delete(t)}l.set(d,{ts:Date.now(),data:t})}n(t.map(t=>({value:t,title:t})));return}n([])}catch{n([])}},r)})},this.j.e.fire("registerAutocompleteSource",this.textAutocompleteSource)}afterInit(){(0,g.extendLang)(p),this.setupEventListeners(),this.setupTextAutocomplete(),this.j.async.promise(t=>{let{initiallyOpened:i,persistOpenState:n}=this.j.o.aiAssistantPro,o=i;n?this.storage.getGlobalSettings().then(t=>{if(t?.isOpen!=null&&(o=t.isOpen),o)return this.openAssistant()}).catch(()=>null).finally(()=>t(void 0)):t(void 0)}).catch(()=>null)}__loadData(){return this.__initedPromise?this.__initedPromise:this.isDestructed?Promise.reject():(this.__initedPromise=this.j.async.promise(t=>{this.loadInitialData().then(t)}).catch(()=>null),this.__initedPromise)}async loadInitialData(){this.mainPanel.setMod("ready",!0),await (0,h.loadInitialData)(this.j,this.storage,this.stateManager),await this.restorePendingToolCalls()}async restorePendingToolCalls(){let t=this.stateManager.getCurrentConversation();if(!t)return;let i=(0,h.findMessagesWithPendingToolCalls)(t);if(0!==i.length)for(let t of i)await this.handleToolCalls(t.id)}setupEventListeners(){this.j.e.on("selectConversation.ai-assistant-pro",async t=>{try{await this.__loadData(),await (0,h.handleConversationSelect)(t,this.storage,this.stateManager)}catch(t){f.IS_PROD}}),this.j.e.on("newConversation.ai-assistant-pro",async()=>{await this.__loadData();let t=(0,h.createNewConversation)(this.j,this.state.defaultModel,this.state.defaultTemperature);this.stateManager.setCurrentConversation(t)}),this.j.e.on("deleteConversation.ai-assistant-pro",async t=>{await this.__loadData(),await this.deleteConversation(t)}),this.j.e.on("renameConversation.ai-assistant-pro",async(t,i)=>{await this.__loadData(),await this.renameConversation(t,i)}),this.j.e.on("backToList.ai-assistant-pro",async()=>{await this.__loadData(),await (0,h.handleBackToList)(this.storage,this.stateManager)}),this.j.e.on("removeContext.ai-assistant-pro",async t=>{await this.__loadData(),this.stateManager.removeSelectionContext(t)}),this.j.e.on("approveToolCall.ai-assistant-pro",async(t,i)=>{try{await this.__loadData();let n=await (0,h.handleToolApproval)(t,i,this.stateManager,this.permissionManager,this.storage);if(n){let t=this.stateManager.getCurrentConversation();if(!t)return;let i=t.messages.find(t=>t.toolCalls?.some(t=>t.id===n.id));if(!i)return;await this.executeToolCall(i.id,n)}}catch(t){if((0,b.isAbortError)(t))return;this.stateManager.setError(t instanceof Error?t.message:t+"")}}),this.j.e.on("denyToolCall.ai-assistant-pro",async t=>{await this.__loadData(),await (0,h.handleToolDenial)(this.j,t,this.stateManager,this.storage)}),this.j.e.on("abortRequest.ai-assistant-pro",async()=>{await this.__loadData(),this.apiClient.abort(),this.stateManager.setLoading(!1)})}__applyTheme(){(0,h.applyTheme)(this.j,this.stateManager.state.theme,this.stateManager.state.displayMode,this.mainPanel.container,this.dialog)}async openAssistant(){if(this.stateManager.isOpen()){this.stateManager.close(),await this.__closeInContainer();return}await this.__loadData(),this.isDestructed||(this.stateManager.open(),await this.__openInContainer(),this.j.o.aiAssistantPro.includeSelectionByDefault&&!this.j.s.isCollapsed()&&this.addCurrentSelectionToContext())}async __openInContainer(){let{resizable:t,allowClose:i,flightPanelHeight:n}=this.j.o.aiAssistantPro,{displayMode:o="right",panelWidth:r,panelHeight:s}=this.stateManager.state;switch(this.__applyTheme(),this.mainPanel.setMod("displayMode",o),this.mainPanel.setMod("allowClose",i),this.mainPanel.setParentView("dialog"===o||"flight"===o?this.dialog:this.j),this.__openedMode=o,o){case"dialog":this.dialog.setSize(r,s).open().setContent(this.mainPanel.container);break;case"flight":_.UIFlightPosition.install(this.mainPanel,this.j.container,{panelHeight:n,containerClassName:this.getFullElName("flight-container")});break;default:t&&(C.UIResize.remove(this.mainPanel),C.UIResize.install(this.mainPanel,(0,h.invertMode)(o),{handleClassName:this.getFullElName("ai-assistent-resize-handle"),onResize:({newSize:t})=>{let i="left"===o||"right"===o?t:r,n="top"===o||"bottom"===o?t:s;return this.stateManager.state.panelWidth=i,this.stateManager.state.panelHeight=n,!0}})),this.j.currentPlace.slots[o].appendChild(this.mainPanel.container),(0,h.resizeInPanelView)(this.j,o,r,s)}}__onResizeInPanelView(){let{displayMode:t,panelWidth:i,panelHeight:n}=this.stateManager.state;(0,h.resizeInPanelView)(this.j,t,i,n)}async __closeInContainer(){let{displayMode:t}=await this.stateManager.state;switch(this.__openedMode!==t&&"dialog"===this.__openedMode&&this.dialog.close(),this.__openedMode!==t&&"flight"===this.__openedMode&&this.__closeFlightMode(),t){case"dialog":this.dialog.close();break;case"flight":this.__closeFlightMode();break;default:this.mainPanel.container.remove()}}__closeFlightMode(){_.UIFlightPosition.remove(this.mainPanel)}__onSavedStateChange(){let t=this.stateManager.state;return this.storage.saveGlobalSettings({displayMode:t.displayMode,panelWidth:t.panelWidth,panelHeight:t.panelHeight,theme:t.theme,defaultModel:t.defaultModel,defaultTemperature:t.defaultTemperature,currentConversationId:t.currentConversation?.id,...this.j.o.aiAssistantPro.persistOpenState?{isOpen:t.isOpen}:{}})}async closeAssistant(){this.stateManager.isOpen()&&(await this.__loadData(),this.stateManager.close(),this.__closeInContainer())}async addCurrentSelectionToContext(){await this.__loadData();let t=(0,h.getCurrentSelectionContext)(this.j);t&&this.stateManager.addSelectionContext(t)}async executeQuickCommand(t){let i,{quickCommandsSilentMode:n,quickCommandsDisplayMode:o}=this.j.o.aiAssistantPro,r=this.j.o.aiAssistant;if(r&&r[t]&&(0,b.isString)(r[t])&&(i=r[t]),!i)return void this.j.e.fire("error","Command not found: "+t);let s=this.j.s.isCollapsed()?this.j.value:this.j.s.html;if(!s)return;let a=r?.aiCommonPrefixPrompt||"",l=r?.aiCommonSuffixPrompt||"",c=`${a}${i}${l}
|
|
282
282
|
|
|
283
283
|
${s}`.trim();n?await this.__executeQuickCommandSilent(c,s):await this.__executeQuickCommandWithPanel(c,o)}async __executeQuickCommandSilent(t,i){await this.__loadData(),this.j.progressbar.show().progress(100);try{let i=(0,h.createUserMessage)(t),n=(0,h.createNewConversation)(this.j,this.state.defaultModel,this.state.defaultTemperature,[i]),o=await this.apiClient.sendRequest(n.id,n.messages,null,[],n.options);if("final"===o.mode){let t=o.response.content;t&&this.j.s.insertHTML(t)}}catch(t){(0,b.isAbortError)(t)||this.j.e.fire("error",t)}finally{this.j.progressbar.hide()}}async __executeQuickCommandWithPanel(t,i){await this.__loadData();let n=this.stateManager.state.displayMode;this.stateManager.state.displayMode=i;let o=(0,h.getCurrentSelectionContext)(this.j);o&&this.stateManager.addSelectionContext(o),this.stateManager.isOpen()||await this.openAssistant(),await this.sendMessage(t),this.stateManager.state.displayMode=n}async sendMessage(t){await this.__loadData();let i=this.stateManager.getCurrentConversation(),n=this.stateManager.getEditingMessageId();if(n&&i){let t=i.messages.findIndex(t=>t.id===n);if(-1!==t){let n=i.messages.slice(0,t),o={...i,messages:n,updatedAt:Date.now()};this.stateManager.setCurrentConversation(o),await this.storage.save(o),this.stateManager.clearEditingMessage(),i=o}}i||(i=(0,h.createNewConversation)(this.j,this.state.defaultModel,this.state.defaultTemperature),this.stateManager.setCurrentConversation(i));let o=null;t.trim()&&(o=(0,h.createUserMessage)(t),i.title||(i={...i,title:t}),i={...i,updated:Date.now(),messages:[...i.messages,o]}),this.stateManager.setCurrentConversation({...i}),o&&this.j.e.fire("messageSent.ai-assistant-pro",o),this.stateManager.setLoading(!0),this.stateManager.clearError();try{await this.sendRequestToAI(0),this.stateManager.clearSelectionContexts()}catch(t){if((0,b.isAbortError)(t))return;this.stateManager.setError(t instanceof Error?t.message:t+"")}finally{this.stateManager.setLoading(!1)}}async sendRequestToAI(t=0){let i,n,o=this.j.o.aiAssistantPro.maxRecursionToolCallDepth;if(t>=o)throw Error(`Max recursion depth ${o} reached for tool calls`);let r=this.stateManager.getCurrentConversation();if(!r)return;let s=(0,h.findParentMessageId)(r),[a]=await Promise.all([this.apiClient.sendRequest(r.id,r.messages,s,this.stateManager.getSelectionContexts(),r.options),this.storage.save(r)]);if("stream"===a.mode){let t=await (0,h.processStreamingResponse)(this.stateManager,a,r);i=t.aiMessage,n=t.index,r=t.conversation}else{let t=(0,h.processFinalResponse)(a,r);i=t.aiMessage,n=t.index,r=t.conversation}r=await (0,h.processArtifacts)(this.j,i,r,n),this.j.e.fire("messageReceived.ai-assistant-pro",i),this.stateManager.setCurrentConversation({...r}),await this.storage.save(r),await this.handleToolCalls(i.id,t)}async deleteConversation(t){await this.__loadData(),await (0,h.deleteConversationWithCleanup)(this.j,t,this.storage,this.stateManager,this.permissionManager)}async renameConversation(t,i){let n=await this.storage.get(t);if(!n)return;let o={...n,title:i,updated:Date.now()};await this.storage.save(o),this.state.currentConversation?.id===t&&this.stateManager.setCurrentConversation(o);let r=await this.storage.list();this.stateManager.setConversations(r)}async searchConversations(t){await this.__loadData(),await (0,h.handleConversationSearch)(t,this.storage,this.stateManager)}async handleToolCalls(t,i=0){let n=this.stateManager.getCurrentConversation();if(!n)return;let o=n.messages.find(i=>i.id===t);if(!o)return;let r=o.toolCalls;if(!r||0===r.length)return;let s=r.filter(t=>!(0,h.isTerminalToolCallStatus)(t.status));if(0===s.length)return;let{approved:a,needsPermission:l}=this.permissionManager.filterToolCalls(s,n.permissions);for(let n of(this.stateManager.setPendingToolCalls(l),a))await this.executeToolCall(t,n,i)}async executeToolCall(t,i,n=0){let o=this.stateManager.getCurrentConversation();if(!o)return;let r=await (0,h.executeToolCall)(this.j,i,this.toolRegistry),s=o.messages.findIndex(i=>i.id===t);if(-1===s)return;let a=o.messages[s],l=o.messages.slice();l[s]=(0,h.updateToolCallInMessage)(a,r),o={...o,messages:l,updated:Date.now()},this.stateManager.setCurrentConversation(o),(0,h.areAllToolCallsExecuted)(o)&&await this.sendRequestToAI(n+1)}async copyMessage(t){let i=this.stateManager.getCurrentConversation();if(!i)return;let n=i.messages.find(i=>i.id===t);if(n)try{await navigator.clipboard.writeText(n.content),this.j.message.success("Message copied to clipboard")}catch(t){this.j.e.fire("error",Error("Failed to copy message"))}}async restartFromMessage(t){let i=this.stateManager.getCurrentConversation();if(!i)return;let n=i.messages.findIndex(i=>i.id===t);if(-1===n)return;let o=i.messages[n];if("user"!==o.role)return;await this.__loadData();let r=i.messages.slice(0,n),s={...i,messages:r,updatedAt:Date.now()};this.stateManager.setCurrentConversation(s),await this.storage.save(s),await this.sendMessage(o.content)}async editMessage(t){let i=this.stateManager.getCurrentConversation();if(!i)return;let n=i.messages.find(i=>i.id===t);n&&"user"===n.role&&(this.stateManager.setEditingMessageId(t),this.mainPanel.inputArea.setValue(n.content),this.mainPanel.inputArea.focus())}cancelEditMessage(){this.stateManager.isEditingMessage()&&(this.stateManager.clearEditingMessage(),this.mainPanel.inputArea.setValue(""))}async deleteMessage(t){await this.__loadData();let i=this.stateManager.getCurrentConversation();if(!i||-1===i.messages.findIndex(i=>i.id===t))return;let n=i.messages.filter(i=>i.id!==t),o={...i,messages:n,updatedAt:Date.now()};this.stateManager.setCurrentConversation(o),await this.storage.save(o)}beforeDestruct(){this.textAutocompleteSource&&(this.j.e.fire("unregisterAutocompleteSource",this.textAutocompleteSource),this.textAutocompleteSource=null),this.textAutocompleteCache.clear(),this.__closeFlightMode(),(0,m.cached)(this,"toolRegistry")?.destruct(),(0,m.cached)(this,"permissionManager")?.destruct(),(0,m.cached)(this,"apiClient")?.destruct(),(0,m.cached)(this,"stateManager")?.destruct(),(0,m.cached)(this,"mainPanel")?.destruct(),(0,m.cached)(this,"dialog")?.destruct(),(0,m.cached)(this,"storage")?.close?.()}constructor(...t){super(...t),(0,o._)(this,"buttons",[{name:"aiAssistantPro",group:"insert"},{name:"aiCommandsPro",group:"insert"}]),(0,o._)(this,"textAutocompleteSource",null),(0,o._)(this,"textAutocompleteCache",new Map),(0,o._)(this,"__initedPromise",null),(0,o._)(this,"__openedMode",null)}}(0,o._)(k,"requires",["license","autocomplete"]),(0,r.__decorate)([m.cache],k.prototype,"toolRegistry",null),(0,r.__decorate)([m.cache],k.prototype,"permissionManager",null),(0,r.__decorate)([m.cache],k.prototype,"apiClient",null),(0,r.__decorate)([m.cache],k.prototype,"storage",null),(0,r.__decorate)([m.cache],k.prototype,"stateManager",null),(0,r.__decorate)([m.cache],k.prototype,"mainPanel",null),(0,r.__decorate)([m.cache],k.prototype,"dialog",null),(0,r.__decorate)([(0,m.watch)("state.theme")],k.prototype,"__applyTheme",null),(0,r.__decorate)([(0,m.watch)(":openAIAssistantPro.ai-assistant-pro")],k.prototype,"openAssistant",null),(0,r.__decorate)([(0,m.watch)([":resize","state.panelWidth","state.panelHeight"])],k.prototype,"__onResizeInPanelView",null),(0,r.__decorate)([(0,m.watch)(["state.isOpen","state.displayMode","state.panelWidth","state.panelHeight","state.theme","state.defaultModel","state.defaultTemperature","state.currentConversation"]),(0,m.debounce)()],k.prototype,"__onSavedStateChange",null),(0,r.__decorate)([(0,m.watch)(":closeAIAssistantPro.ai-assistant-pro")],k.prototype,"closeAssistant",null),(0,r.__decorate)([(0,m.watch)(":addContextToAIAssistant.ai-assistant-pro")],k.prototype,"addCurrentSelectionToContext",null),(0,r.__decorate)([(0,m.watch)(":executeQuickCommand.ai-assistant-pro")],k.prototype,"executeQuickCommand",null),(0,r.__decorate)([(0,m.watch)(":sendMessage.ai-assistant-pro")],k.prototype,"sendMessage",null),(0,r.__decorate)([(0,m.watch)(":searchConversations.ai-assistant-pro")],k.prototype,"searchConversations",null),(0,r.__decorate)([(0,m.watch)(":copyMessage.ai-assistant-pro")],k.prototype,"copyMessage",null),(0,r.__decorate)([(0,m.watch)(":restartFromMessage.ai-assistant-pro")],k.prototype,"restartFromMessage",null),(0,r.__decorate)([(0,m.watch)(":editMessage.ai-assistant-pro")],k.prototype,"editMessage",null),(0,r.__decorate)([(0,m.watch)(":cancelEditMessage.ai-assistant-pro")],k.prototype,"cancelEditMessage",null),(0,r.__decorate)([(0,m.watch)(":deleteMessage.ai-assistant-pro")],k.prototype,"deleteMessage",null),k=(0,r.__decorate)([m.component],k),w.JoditPro.plugins.add("aiAssistantPro",k)},66645:function(t,i,n){"use strict";var o=n(47373),r=n(94668),s=n.n(r),a=n(86428),l=n.n(a),c=n(75966),d=n.n(c),u=n(83207),h=n.n(u),p=n(99293),f=n.n(p),m=n(99219),g=n.n(m),b=n(63674),y=n.n(b),w=n(4133),_=n.n(w),C=n(94454),k=n(53835),S=n(6441),x=n(12153),I=n(31974),E=n(72573);x.Icon.set("ai-assistant-pro",l()).set("ai-commands-pro",d()).set("ai-add-context",s()).set("send",g()).set("microphone",f()).set("tool-bolt",_()).set("chevron-right",h()).set("shield",y()),S.Config.prototype.aiAssistantPro={displayMode:"right",panelWidth:400,panelHeight:500,flightPanelHeight:250,dialogFullSize:!1,resizable:!0,apiMode:"incremental",apiRequest:null,maxRetries:3,requestTimeout:3e5,retryDelay:1e3,maxRecursionToolCallDepth:1e3,enabledTools:(0,k.getToolNames)(),customTools:[],toolPermissions:{},autoApproveTools:["readDocument","readBlocks","readSelection","insertHTML","addHTML"],alwaysDenyTools:[],defaultPermissionScope:"conversation",storage:"indexedDB",maxConversations:50,storageKey:"jodit-ai-assistant-pro",showConversationList:!0,enableMarkdown:!0,enableCodeHighlight:!0,maxMessageHeight:400,placeholderText:"Ask AI assistant...",sendShortcut:"Ctrl+Enter",showTimestamps:!0,formatTimestamp(t,i){let n=new Date(t),o=new Date().getTime()-n.getTime();return o<6e4?i("Just now"):o<36e5?i("%dm ago",Math.floor(o/6e4)):o<864e5?i("%dh ago",Math.floor(o/36e5)):n.toLocaleTimeString([],{hour:"2-digit",minute:"2-digit"})},formatMessageContent:(t,i)=>E.marked.parse(t,{breaks:!0,gfm:!0}),showAvatars:!0,showTypingIndicator:!0,includeSelectionByDefault:!0,maxContextRanges:5,showContextPreview:!0,sendOnEnter:!0,instructions:void 0,includeEditorMetadata:!1,autoOpen:!0,rememberLastConversation:!0,autoFocusInput:!0,voiceInputEnabled:!1,closeAfterInsert:!1,enableSoundNotifications:!1,debug:!1,textAutocompleteEnabled:!1,textAutocompleteApiRequest:null,textAutocompleteMinQueryLength:3,textAutocompleteMaxSuggestions:3,textAutocompleteDebounceMs:500,textAutocompleteCacheTTL:3e4,textAutocompleteCacheMaxSize:50,quickCommandsSilentMode:!1,quickCommandsDisplayMode:"flight",showCopyMessageAction:!0,showRestartMessageAction:!0,showEditMessageAction:!0,showDeleteMessageAction:!0,dialogSettings:{},allowEditDialogSettings:!1,allowEditDisplayMode:!0,allowEditPanelWidth:!0,initiallyOpened:!1,allowClose:!0,persistOpenState:!0,theme:"parent",allowEditTheme:!0,async uploadBase64Artifact(t,i){if("image"===t.type&&t.data&&"base64"===t.data.kind)try{let n=(0,o.base64ToFile)(t.data.base64,t.id,t.mimeType),r=await i.uploader.upload([n]);return{...t,data:{kind:"url",url:r.baseurl+r.files[0]},metadata:{...t.metadata,filename:r.files[0]}}}catch(t){i.e.fire("error",t)}return t},getAIProviderOptions:(t,i)=>(0,C.getAIProviderOptions)(t,i),registerAIProvider(t,i){(0,C.registerAIProvider)(t,i)}},S.Config.prototype.controls.aiAssistantPro={icon:"ai-assistant-pro",tooltip:"AI Assistant",hotkeys:["ctrl+shift+a","cmd+shift+a"],exec(t){t.e.fire("openAIAssistantPro.ai-assistant-pro")},isDisabled:t=>!t.o.aiAssistantPro.apiRequest,getLabel:t=>t.o.aiAssistantPro.apiRequest?"AI Assistant":"AI Assistant (not configured)"},S.Config.prototype.controls.aiAddContext={icon:"ai-add-context",tooltip:"Add to AI Context",exec(t){t.e.fire("addContextToAIAssistant")},isDisabled:t=>!t.o.aiAssistantPro.apiRequest||t.s.isCollapsed()},S.Config.prototype.controls.aiCommandsPro={icon:"ai-commands-pro",tooltip:"AI Commands",isDisabled:t=>!t.o.aiAssistantPro.apiRequest,list:I.aiAssitentCommands,exec(t,i,{control:n}){t.e.fire("executeQuickCommand.ai-assistant-pro",n.name)}};let T=S.Config.prototype.tuneBlock?.popup||{},j={};["p","h1","h2","h3","h4","h5","h6","div","section","article","pre","blockquote","ul","ol","li","table","tr","td","th","img","figure"].forEach(t=>{let i=T[t]||["tune.up","tune.remove","tune.down"];j[t]=[...i,"|","aiAddContext"]}),S.Config.prototype.tuneBlock&&(S.Config.prototype.tuneBlock.popup={...T,...j})},6689:function(t,i,n){"use strict";n.d(i,{throwIfAborted:function(){return r}});var o=n(93661);function r(t){if(t.aborted)throw(0,o.abort)()}},61872:function(t,i,n){"use strict";n.d(i,{processArtifacts:function(){return a},processFinalResponse:function(){return s},processStreamingResponse:function(){return r}});var o=n(61558);async function r(t,i,n){let r=(0,o.createAIMessage)(),s=-1;for await(let a of i.stream){switch(a.type){case"created":r={...r,id:a.response.responseId,content:""},s=n.messages.length;break;case"text-delta":r={...r,content:r.content+a.delta};break;case"completed":r={...r,id:a.response.responseId,toolCalls:a.response.toolCalls||[],artifacts:a.response.artifacts||[]};break;case"error":{let t=(0,o.createErrorMessage)(a.error);r={...r,id:t.id,content:t.content}}}if(r.id){let i=n.messages.slice();i[s>=0?s:n.messages.length]=r,n={...n,messages:i,updated:Date.now()},t.setCurrentConversation(n)}}return{aiMessage:r,index:s,conversation:n}}function s(t,i){let n={...(0,o.createAIMessage)(),id:t.response.responseId,content:t.response.content,toolCalls:t.response.toolCalls||[],artifacts:t.response.artifacts||[]},r=i.messages.slice();return r.push(n),{aiMessage:n,index:(i={...i,messages:r,updated:Date.now()}).messages.length-1,conversation:i}}async function a(t,i,n,r){if(i.artifacts&&i.artifacts.length>0){let s=n.messages.slice();return s[r]={...s[r],artifacts:await (0,o.uploadArtifacts)(t,i.artifacts)},{...n,messages:s,updated:Date.now()}}return n}},49459:function(t,i,n){"use strict";function o(t,i,n={}){let r=t[i];if("string"!=typeof r||!n.allowEmpty&&""===r)throw Error(`Parameter "${i}" is required and must be a${n.allowEmpty?"":" non-empty"} string`);return r}n.d(i,{requireString:function(){return o}})},44526:function(t,i,n){"use strict";n.d(i,{resolveBlock:function(){return r}});var o=n(22732);function r(t,{selector:i,index:n,requireExactlyOne:s=!1}={}){let a=null!=i&&""!==i.trim(),l=null!=n;if(s&&a===l)throw Error("Either index or selector must be provided, but not both");if(!a&&!l)throw Error("Block identifier is required");if(a){if("string"!=typeof i)throw Error("Selector must be a string");let n=t.editor.querySelector(i);if(!n)throw Error(`No element found matching selector "${i}"`);if(!o.Dom.isElement(n))throw Error(`Selector "${i}" does not point to an element node`);return{element:n,identifier:`with selector "${i}"`}}if("number"!=typeof n)throw Error("Block index must be a number");let c=Array.from(t.editor.children);if(n<0||n>=c.length)throw Error(`Block index ${n} is out of range. Document has ${c.length} blocks`);let d=c[n];if(!o.Dom.isElement(d))throw Error(`Block at index ${n} is not a valid element`);return{element:d,identifier:"at index "+n}}},70308:function(t,i,n){"use strict";n.d(i,{areAllToolCallsExecuted:function(){return c},createNewConversation:function(){return r},findMessagesWithPendingToolCalls:function(){return d},findParentMessageId:function(){return s},isTerminalToolCallStatus:function(){return l}});var o=n(21064);function r(t,i,n,s=[]){let a=t.o.aiAssistantPro,l={id:(0,o.generateConversationId)(),created:Date.now(),updated:Date.now(),messages:s,permissions:[],options:{model:i??a.defaultModel,temperature:n??a.defaultTemperature}};return t.e.fire("conversationCreated.ai-assistant-pro",l),l}function s(t){for(let i=t.messages.length-1;i>=0;i--){let n=t.messages[i];if("assistant"===n.role&&!n.id.startsWith("error_"))return n.id}return null}let a=new Set(["executed","denied","error"]);function l(t){return a.has(t)}function c(t){let i=t.messages[t.messages.length-1];return!!i?.toolCalls&&i.toolCalls.every(t=>l(t.status))}function d(t){return t.messages.filter(t=>t.toolCalls&&t.toolCalls.length>0&&t.toolCalls.some(t=>!l(t.status)))}},473:function(t,i,n){"use strict";n.d(i,{handleBackToList:function(){return c},handleConversationSearch:function(){return d},handleConversationSelect:function(){return l},handleToolApproval:function(){return s},handleToolDenial:function(){return a}});var o=n(79078),r=n(82758);async function s(t,i,n,o,r){let s=n.getPendingToolCalls().find(i=>i.id===t);if(!s)return null;let a=o.grantPermission(s.name,i),l=n.getCurrentConversation();return l&&(l.permissions.push(a),await r.save(l)),n.removePendingToolCall(t),{...s,status:"approved"}}async function a(t,i,n,r){let s=n.getPendingToolCalls().find(t=>t.id===i);if(!s)return;let a=n.getCurrentConversation();if(!a)return;let l=a.messages.findIndex(t=>t.toolCalls?.find(t=>t.id===i));if(-1===l)return;let c=a.messages[l],d={...s,result:{error:"Tool call denied by user."},status:"denied"},u=(0,o.updateToolCallInMessage)(c,d),h=[...a.messages];h[l]=u,a={...a,messages:h,updated:Date.now()},n.setCurrentConversation(a),await r.save(a),t.e.fire("toolCallDenied.ai-assistant-pro",s),n.removePendingToolCall(i)}async function l(t,i,n){try{n.setLoading(!0);let o=await i.get(t);if(!o)throw Error("Conversation not found: "+t);n.setCurrentConversation({...o})}catch(t){r.IS_PROD}finally{n.setLoading(!1)}}async function c(t,i){i.setView("conversationList");try{i.setLoading(!0);let n=await t.list().catch(()=>[]);i.setConversations(n)}finally{i.setLoading(!1)}}async function d(t,i,n){n.setLoading(!0);try{let o=await i.list(t||void 0);n.setConversations(o),n.setView("conversationList")}finally{n.setLoading(!1)}}},58579:function(t,i,n){"use strict";n.d(i,{applyTheme:function(){return u.applyTheme},areAllToolCallsExecuted:function(){return r.areAllToolCallsExecuted},createNewConversation:function(){return r.createNewConversation},createUserMessage:function(){return a.createUserMessage},deleteConversationWithCleanup:function(){return d.deleteConversationWithCleanup},executeToolCall:function(){return h.executeToolCall},findMessagesWithPendingToolCalls:function(){return r.findMessagesWithPendingToolCalls},findParentMessageId:function(){return r.findParentMessageId},getCurrentSelectionContext:function(){return c.getCurrentSelectionContext},handleBackToList:function(){return s.handleBackToList},handleConversationSearch:function(){return s.handleConversationSearch},handleConversationSelect:function(){return s.handleConversationSelect},handleToolApproval:function(){return s.handleToolApproval},handleToolDenial:function(){return s.handleToolDenial},invertMode:function(){return l.invertMode},isTerminalToolCallStatus:function(){return r.isTerminalToolCallStatus},loadInitialData:function(){return d.loadInitialData},processArtifacts:function(){return o.processArtifacts},processFinalResponse:function(){return o.processFinalResponse},processStreamingResponse:function(){return o.processStreamingResponse},resizeInPanelView:function(){return l.resizeInPanelView},updateToolCallInMessage:function(){return h.updateToolCallInMessage}});var o=n(61872),r=n(70308),s=n(473),a=n(61558),l=n(71050),c=n(15927),d=n(56110),u=n(53014),h=n(79078)},61558:function(t,i,n){"use strict";n.d(i,{createAIMessage:function(){return s},createErrorMessage:function(){return a},createUserMessage:function(){return r},uploadArtifacts:function(){return l}});var o=n(21064);function r(t){return{id:(0,o.generateMessageId)(),role:"user",content:t,timestamp:Date.now()}}function s(){return{id:"",role:"assistant",content:"",artifacts:[],timestamp:Date.now(),toolCalls:[]}}function a(t){return{id:"error_"+(0,o.generateMessageId)(),role:"assistant",content:"❌ Error: "+t.message,timestamp:Date.now(),toolCalls:[],artifacts:[]}}async function l(t,i){if(!i||0===i.length)return i;let n=t.o.aiAssistantPro.uploadBase64Artifact;return n?Promise.all(i.map(async i=>n(i,t)??i)):i}},71050:function(t,i,n){"use strict";n.d(i,{invertMode:function(){return r},resizeInPanelView:function(){return s}});var o=n(41180);function r(t){switch(t){case"left":return"right";case"right":return"left";case"top":return"bottom";case"bottom":return"top"}}function s(t,i,n,s){if("dialog"===i||"flight"===i)return;("left"===i||"right"===i)&&(t.currentPlace.slots[r(i)]?.style.setProperty(`--jd-slot-${r(i)}-width`,"auto"),t.currentPlace.slots[i]?.style.setProperty(`--jd-slot-${i}-width`,`${n}px`));let a=(0,o.css)(t.currentPlace.workplace,"height")??0;t.currentPlace.slots[i]?.style.setProperty("min-height",`${Math.min(a,s)}px`)}},15927:function(t,i,n){"use strict";function o(t){if(t.s.isCollapsed())return null;let i=t.s.html,n=t.s.range;return{html:i,rangeInfo:{startContainer:n.startContainer.nodeName,startOffset:n.startOffset,endContainer:n.endContainer.nodeName,endOffset:n.endOffset}}}n.d(i,{getCurrentSelectionContext:function(){return o}})},56110:function(t,i,n){"use strict";n.d(i,{deleteConversationWithCleanup:function(){return r},loadInitialData:function(){return s}});var o=n(82758);async function r(t,i,n,o,r){try{o.setLoading(!0),await n.delete(i),o.removeConversation(i),r.clearConversationPermissions(i);let s=o.getCurrentConversation();s?.id===i&&o.setCurrentConversation(null);let a=await n.list();o.setConversations(a),o.setView(0===a.length?"welcome":"conversationList"),t.e.fire("conversationDeleted.ai-assistant-pro",i)}catch(i){t.alert(t.i18n("Failed to delete conversation")+": "+(i?.message||"Unknown error"))}finally{o.setLoading(!1)}}async function s(t,i,n){n.setLoading(!0);try{let[o,r]=await Promise.all([i.list().catch(()=>[]),i.getGlobalSettings().catch(()=>null)]);if(n.setConversations(o),r&&n.setSavedState(r),0===o.length)n.setView("welcome");else if(t.o.aiAssistantPro.rememberLastConversation&&r?.currentConversationId){let t=o.find(t=>t.id===r.currentConversationId)??o[0],s=await i.get(t.id);s?n.setCurrentConversation(s):n.setView("conversationList")}else n.setView("conversationList")}catch(t){o.IS_PROD,n.setView("welcome")}finally{n.setLoading(!1)}}},53014:function(t,i,n){"use strict";n.d(i,{applyTheme:function(){return s}});let o=["jodit_theme_dark","jodit-ai-assistant-pro_theme_dark","jodit-dialog_theme_dark"],r=["jodit_theme_light","jodit-ai-assistant-pro_theme_light","jodit-dialog_theme_light"];function s(t,i,n,s,a){let l;if(s?.classList.remove(...o),s?.classList.remove(...r),"dialog"===n){let t=a?.container;t?.classList.remove(...o),t?.classList.remove(...r)}if(l="dark"===i?o:r,s?.classList.add(...l),"dialog"===n){let t=a?.container;t?.classList.add(...l)}}},79078:function(t,i,n){"use strict";async function o(t,i,n){let o;try{let t=new AbortController().signal,r=await n.executeTool(i.name,i.arguments,t);o={...i,result:{result:r},status:"executed"}}catch(n){o={...i,result:{error:n instanceof Error?n.message:n+""},status:"error"},t.e.fire("toolCallFailed.ai-assistant-pro",o)}return t.e.fire("toolCallExecuted.ai-assistant-pro",o,{toolCallId:o.id,result:o.result}),o}function r(t,i){let n=t.toolCalls?.findIndex(t=>t.id===i.id);if(null==n||-1===n)return t;let o=[...t?.toolCalls??[]];return o[n]=i,{...t,toolCalls:o}}n.d(i,{executeToolCall:function(){return o},updateToolCallInMessage:function(){return r}})},86449:function(t,i,n){"use strict";n.d(i,{APIClient:function(){return a}});var o=n(82749),r=n(82758),s=n(21537);class a{async sendRequest(t,i,n,o,a){let{apiRequest:l,requestTimeout:c,maxRetries:d}=this.jodit.o.aiAssistantPro;if(!l)throw Error("AI Assistant Pro callback is not configured");let u=new AbortController;this.abortControllers.add(u);try{let h=this.buildRequestContext(t,i,n,o,a),p=null;for(let t=0;d>=t;t++)try{if(u.signal.aborted)throw(0,s.abort)();let t=setTimeout(()=>{u.abort()},c);try{let i=await l(h,u.signal);return clearTimeout(t),this.validateResponse(i),i}catch(i){throw clearTimeout(t),i}}catch(i){if(p=i,r.IS_PROD,d>t){let i=this.calculateRetryDelay(t);await this.sleep(i)}else throw i}throw p||Error("API request failed after all retries")}finally{this.abortControllers.delete(u)}}abort(){this.abortControllers.forEach(t=>{t.abort()}),this.abortControllers.clear()}isInProgress(){return this.abortControllers.size>0}buildRequestContext(t,i,n,o,r){let s,{apiMode:a,instructions:l}=this.jodit.o.aiAssistantPro,c={mode:a,conversationId:t,tools:this.toolRegistry.getAllTools(),selectionContexts:o,conversationOptions:r,instructions:l};if("full"===a)s=i;else if(n){let t=i.findIndex(t=>t.id===n);s=-1!==t?i.slice(t+1):i,c={...c,parentMessageId:n}}else s=i;return{...c,messages:this.expandToolMessages(s,i.find(t=>t.id===n))}}expandToolMessages(t,i){let n=[];for(let i of t)n.push(i),this.expandToolResultsMessage(i,n);return i&&this.expandToolResultsMessage(i,n),n}expandToolResultsMessage(t,i){if(t.toolCalls&&t.toolCalls.length>0)for(let n of t.toolCalls){let o=n.result??{error:"result not found"};if(i.find(t=>t.id===`${n.id}-result`))continue;let r={id:`${n.id}-result`,role:"tool",content:o.error?"Error: "+o.error:JSON.stringify(o.result),timestamp:t.timestamp,toolResults:[{toolCallId:n.id,result:o}]};i.push(r)}}validateResponse(t){if("final"!==t.mode)return;let i=t.response;if(!i)throw Error("API returned empty response");if(!i.responseId)throw Error("API response missing responseId");if(void 0===i.content)throw Error("API response missing content");if(void 0===i.finished)throw Error("API response missing finished flag");if(i.toolCalls){if(!Array.isArray(i.toolCalls))throw Error("API response toolCalls must be an array");i.toolCalls.forEach((t,i)=>{if(!t.id)throw Error(`Tool call at index ${i} is missing id`);if(!t.name)throw Error(`Tool call at index ${i} is missing name`);if(!t.arguments||"object"!=typeof t.arguments)throw Error(`Tool call at index ${i} has invalid arguments`)})}}calculateRetryDelay(t){let{retryDelay:i}=this.jodit.o.aiAssistantPro;return i*Math.pow(2,t)+Math.random()*i}sleep(t){return new Promise(i=>setTimeout(i,t))}destruct(){this.abort()}constructor(t,i){(0,o._)(this,"jodit",void 0),(0,o._)(this,"toolRegistry",void 0),(0,o._)(this,"abortControllers",void 0),this.jodit=t,this.toolRegistry=i,this.abortControllers=new Set}}},47373:function(t,i,n){"use strict";function o(t,i,n="image/png"){let r=atob(t),s=r.length,a=new Uint8Array(s);for(let t=0;s>t;t++)a[t]=r.charCodeAt(t);return new File([new Blob([a],{type:n})],i,{type:n})}n.d(i,{base64ToFile:function(){return o}})},21020:function(t,i,n){"use strict";n.d(i,{PermissionManager:function(){return r}});var o=n(82749);class r{requiresPermission(t){let{autoApproveTools:i,alwaysDenyTools:n}=this.jodit.o.aiAssistantPro;if(n.includes(t))return!0;if(i.includes(t))return!1;let o=this.toolRegistry.getTool(t);return!o||o.requiresPermission}isAutoDenied(t){let{alwaysDenyTools:i}=this.jodit.o.aiAssistantPro;return i.includes(t)}isAutoApproved(t){let{autoApproveTools:i}=this.jodit.o.aiAssistantPro;return i.includes(t)}checkPermission(t,i){if(this.isAutoApproved(t))return{toolName:t,granted:!0,grantedAt:Date.now(),scope:"once"};if(this.isAutoDenied(t))return null;let n=this.permanentPermissions.get(t);return n&&n.granted?n:i.find(i=>i.toolName===t&&i.granted)||null}grantPermission(t,i){let n={toolName:t,granted:!0,grantedAt:Date.now(),scope:i};return"forever"===i&&(this.permanentPermissions.set(t,n),this.savePermanentPermissions()),n}denyPermission(t){return{toolName:t,granted:!1,grantedAt:Date.now(),scope:"once"}}filterToolCalls(t,i){let n=[],o=[],r=[];for(let s of t){if(this.isAutoDenied(s.name)){r.push({...s,status:"denied"});continue}if(this.isAutoApproved(s.name)){n.push({...s,status:"approved"});continue}let t=this.checkPermission(s.name,i);t&&t.granted?n.push({...s,status:"approved"}):this.requiresPermission(s.name)?(this.jodit.e.fire("permissionRequested.ai-assistant-pro",s.name),o.push({...s,status:"pending"})):n.push({...s,status:"approved"})}return{approved:n,needsPermission:o,denied:r}}clearConversationPermissions(t){}loadPermanentPermissions(){try{let t=localStorage.getItem(this.PERMANENT_PERMISSIONS_KEY);t&&JSON.parse(t).forEach(t=>{"forever"===t.scope&&t.granted&&this.permanentPermissions.set(t.toolName,t)})}catch(t){}}savePermanentPermissions(){try{let t=Array.from(this.permanentPermissions.values());localStorage.setItem(this.PERMANENT_PERMISSIONS_KEY,JSON.stringify(t))}catch(t){}}clearPermanentPermissions(){this.permanentPermissions.clear(),localStorage.removeItem(this.PERMANENT_PERMISSIONS_KEY)}getPermanentPermissions(){return Array.from(this.permanentPermissions.values())}revokePermanentPermission(t){this.permanentPermissions.delete(t),this.savePermanentPermissions()}destruct(){this.permanentPermissions.clear()}constructor(t,i){(0,o._)(this,"jodit",void 0),(0,o._)(this,"toolRegistry",void 0),(0,o._)(this,"permanentPermissions",void 0),(0,o._)(this,"PERMANENT_PERMISSIONS_KEY",void 0),this.jodit=t,this.toolRegistry=i,this.permanentPermissions=new Map,this.PERMANENT_PERMISSIONS_KEY="jodit-permissions.ai-assistant-pro",this.loadPermanentPermissions()}}},46166:function(t,i,n){"use strict";n.d(i,{StateManager:function(){return r}});var o=n(82749);class r{createInitialState(){return{isOpen:!1,currentView:"welcome",currentConversation:null,conversations:[],isLoading:!1,error:null,pendingToolCalls:[],selectionContexts:[],abortController:null,editingMessageId:null,theme:this.jodit.o.aiAssistantPro.theme||"parent",displayMode:this.jodit.o.aiAssistantPro.displayMode,panelWidth:this.jodit.o.aiAssistantPro.panelWidth,panelHeight:this.jodit.o.aiAssistantPro.panelHeight,defaultModel:this.jodit.o.aiAssistantPro.defaultModel,defaultTemperature:this.jodit.o.aiAssistantPro.defaultTemperature}}open(){this.state.isOpen=!0,this.jodit.e.fire("open.ai-assistant-pro",this.state.currentConversation)}close(){this.state.isOpen=!1,this.jodit.e.fire("close.ai-assistant-pro")}isOpen(){return this.state.isOpen}setView(t){this.state.currentView=t,this.jodit.e.fire("viewChanged.ai-assistant-pro",t)}getView(){return this.state.currentView}setConversations(t){this.state.conversations=t}setSavedState(t){t.theme&&(this.state.theme=t.theme),t.displayMode&&(this.state.displayMode=t.displayMode),t.panelWidth&&(this.state.panelWidth=t.panelWidth),t.panelHeight&&(this.state.panelHeight=t.panelHeight),t.defaultModel&&(this.state.defaultModel=t.defaultModel),t.defaultTemperature&&(this.state.defaultTemperature=t.defaultTemperature)}getConversations(){return this.state.conversations}setCurrentConversation(t){if(this.state.currentConversation===t)throw Error("Conversation is already current");this.state.currentConversation=t||null,t&&(this.setView("conversation"),this.jodit.e.fire("conversationSwitched.ai-assistant-pro",t))}getCurrentConversation(){return this.state.currentConversation}removeConversation(t){let i=this.state.conversations.filter(i=>i.id!==t);this.setConversations(i)}setLoading(t){this.state.isLoading=t}isLoading(){return this.state.isLoading}setError(t){this.state.error=t,t&&this.jodit.e.fire("error.ai-assistant-pro",Error(t))}getError(){return this.state.error}clearError(){this.setError(null)}setPendingToolCalls(t){this.state.pendingToolCalls=t}getPendingToolCalls(){return this.state.pendingToolCalls}addPendingToolCall(t){let i=[...this.state.pendingToolCalls,t];this.setPendingToolCalls(i)}removePendingToolCall(t){let i=this.state.pendingToolCalls.filter(i=>i.id!==t);this.setPendingToolCalls(i)}updateToolCallStatus(t,i){let n=this.state.pendingToolCalls.map(n=>n.id===t?{...n,status:i}:n);this.setPendingToolCalls(n)}setSelectionContexts(t){this.state.selectionContexts=t}getSelectionContexts(){return this.state.selectionContexts}addSelectionContext(t){let{maxContextRanges:i}=this.jodit.o.aiAssistantPro,n=[...this.state.selectionContexts,t];n.length>i&&(n=n.slice(-i)),this.setSelectionContexts(n),this.jodit.e.fire("contextAdded.ai-assistant-pro",t)}removeSelectionContext(t){let i=this.state.selectionContexts.filter((i,n)=>n!==t);this.setSelectionContexts(i),this.jodit.e.fire("contextRemoved.ai-assistant-pro",t)}clearSelectionContexts(){this.setSelectionContexts([])}setAbortController(t){this.state.abortController=t}getAbortController(){return this.state.abortController}setEditingMessageId(t){this.state.editingMessageId=t}getEditingMessageId(){return this.state.editingMessageId}isEditingMessage(){return null!=this.state.editingMessageId}clearEditingMessage(){this.setEditingMessageId(null)}reset(){this.state=this.createInitialState()}destruct(){this.state.abortController&&this.state.abortController.abort(),this.reset()}constructor(t){(0,o._)(this,"jodit",void 0),(0,o._)(this,"state",void 0),this.jodit=t,this.state=this.createInitialState()}}},62895:function(t,i,n){"use strict";n.d(i,{WebStorageConversationStorage:function(){return o.WebStorageConversationStorage},createStorageProvider:function(){return o.createStorageProvider}});var o=n(21064)},21064:function(t,i,n){"use strict";n.d(i,{WebStorageConversationStorage:function(){return s},createStorageProvider:function(){return a},generateConversationId:function(){return l},generateMessageId:function(){return c}});var o=n(82749),r=n(97333);class s{close(){return this.storage.close()}getConversationKey(t){return"conv:"+t}async getAllKeys(){let t=await this.storage.get("__conversation_index__");return t&&Array.isArray(t)?t:[]}async updateIndex(t){await this.storage.set("__conversation_index__",t)}async addToIndex(t){let i=await this.getAllKeys();i.includes(t)||(i.push(t),await this.updateIndex(i))}async removeFromIndex(t){let i=(await this.getAllKeys()).filter(i=>i!==t);await this.updateIndex(i)}async list(t){try{let i=await this.getAllKeys(),n=[],o=t?.toLowerCase().trim();for(let t of i){let i=await this.get(t);if(i){if(o){let t=i.title?.toLowerCase().includes(o),n=!t&&i.messages.some(t=>t.content.toLowerCase().includes(o));if(!t&&!n)continue}n.push({id:i.id,title:i.title??"",created:i.created,updated:i.updated,messageCount:i.messages.length})}}return n.sort((t,i)=>i.updated-t.updated),n}catch(t){return[]}}async get(t){try{let i=this.getConversationKey(t);return await this.storage.get(i)||null}catch(t){return null}}async save(t){try{if(0===t.messages.length)throw Error("Conversation must have at least one message.");let i=await this.getAllKeys();i.length>=this.maxConversations&&!i.includes(t.id)&&await this.evictOldest();let n=this.getConversationKey(t.id);await this.storage.set(n,t),await this.addToIndex(t.id)}catch(i){if(i?.name==="QuotaExceededError"||i?.code===22||i?.code===1014){await this.evictOldest();try{let i=this.getConversationKey(t.id);await this.storage.set(i,t),await this.addToIndex(t.id)}catch{throw Error("Storage quota exceeded. Please delete some conversations.")}}else throw Error("Failed to save conversation: "+(i?.message||"Unknown error"))}}async delete(t){try{let i=this.getConversationKey(t);await this.storage.delete(i),await this.removeFromIndex(t)}catch(t){}}async clear(){try{for(let t of(await this.getAllKeys())){let i=this.getConversationKey(t);await this.storage.delete(i)}await this.updateIndex([])}catch(t){}}async evictOldest(){try{let t=await this.list();if(0===t.length)return;t.sort((t,i)=>t.updated-i.updated);let i=t[0];await this.delete(i.id)}catch(t){}}async getGlobalSettings(){try{return await this.storage.get("global-settings")||null}catch(t){return null}}async saveGlobalSettings(t){try{let i={...await this.getGlobalSettings(),...t};await this.storage.set("global-settings",i)}catch{throw Error("Failed to save global settings")}}constructor(t,i){(0,o._)(this,"storage",void 0),(0,o._)(this,"maxConversations",void 0),this.storage=t,this.maxConversations=i}}function a(t,i){return r.AsyncStorage.makeStorage(t,i)}function l(){return`conv_${Date.now()}_${Math.random().toString(36).substring(2,11)}`}function c(){return`msg_${Date.now()}_${Math.random().toString(36).substring(2,11)}`}},55487:function(t,i,n){"use strict";n.d(i,{ToolRegistry:function(){return s}});var o=n(82749),r=n(53835);class s{registerBuiltInTools(t){t.forEach(t=>{let i=r.BUILT_IN_TOOLS[t];i&&this.tools.set(t,i)})}registerCustomTools(t){t.forEach(t=>{this.validateToolDefinition(t),this.tools.set(t.name,t)})}validateToolDefinition(t){if(!t.name||"string"!=typeof t.name)throw Error("Tool must have a valid name");if(!t.description||"string"!=typeof t.description)throw Error(`Tool "${t.name}" must have a description`);if(!Array.isArray(t.parameters))throw Error(`Tool "${t.name}" must have a parameters array`);if("function"!=typeof t.execute)throw Error(`Tool "${t.name}" must have an execute function`);t.parameters.forEach(i=>{if(!i.name||"string"!=typeof i.name)throw Error(`Tool "${t.name}" has a parameter without a valid name`);if(!i.type)throw Error(`Tool "${t.name}" parameter "${i.name}" must have a type`);if("boolean"!=typeof i.required)throw Error(`Tool "${t.name}" parameter "${i.name}" must specify if it's required`)})}getAllTools(){return Array.from(this.tools.values())}getTool(t){return this.tools.get(t)}hasTool(t){return this.tools.has(t)}getToolNames(){return Array.from(this.tools.keys())}async executeTool(t,i,n){let o=this.getTool(t);if(!o)throw Error(`Tool "${t}" not found`);let r=this.applyDefaults(o,i);this.validateArguments(o,r);try{return await o.execute(this.jodit,r,n)}catch(t){if(t?.name==="AbortError"||n.aborted)throw Error("Tool execution was aborted");throw t}}validateArguments(t,i){let n=Object.keys(i);for(let i of t.parameters.filter(t=>t.required).map(t=>t.name))if(!n.includes(i))throw Error(`Tool "${t.name}" requires parameter "${i}"`);for(let[n,o]of Object.entries(i)){let i=t.parameters.find(t=>t.name===n);if(!i){this.jodit.o.aiAssistantPro.debug;continue}let r=Array.isArray(o)?"array":"object"==typeof o&&null!=o?"object":typeof o;if(i.type!==r&&!("number"===i.type&&"string"===r&&!isNaN(Number(o))))throw Error(`Tool "${t.name}" parameter "${n}" expects type "${i.type}" but got "${r}"`);if(i.enum&&i.enum.length>0&&!i.enum.includes(o))throw Error(`Tool "${t.name}" parameter "${n}" must be one of: ${i.enum.join(", ")}`)}}applyDefaults(t,i){let n={...i};for(let i of t.parameters)void 0===n[i.name]&&void 0!==i.default&&(n[i.name]=i.default);return n}destruct(){this.tools.clear()}constructor(t){(0,o._)(this,"jodit",void 0),(0,o._)(this,"tools",void 0),this.jodit=t,this.tools=new Map,this.registerBuiltInTools(t.o.aiAssistantPro.enabledTools||[]),this.registerCustomTools(t.o.aiAssistantPro.customTools||[])}}},26612:function(t){t.exports={"AI Assistant":"AI Assistant","AI Assistant Pro":"AI Assistant Pro","Welcome to AI Assistant":"Welcome to AI Assistant","Start your first conversation":"Start your first conversation","Tip: Select text in editor to add context":"Tip: Select text in editor to add context","New Chat":"New Chat","Search conversations...":"Search conversations...","No conversations yet":"No conversations yet","Ask me anything...":"Ask me anything...","Ask a follow-up...":"Ask a follow-up...","Reply...":"Reply...","Type your message...":"Type your message...",Send:"Send",Cancel:"Cancel",Retry:"Retry",Insert:"Insert",Copy:"Copy",Edit:"Edit",Delete:"Delete",New:"New",Back:"Back","Permission Required":"Permission Required",Approve:"Approve",Deny:"Deny",Once:"Once","This conversation":"This conversation",Always:"Always","The AI wants to execute:":"The AI wants to execute:","This will modify your document content.":"This will modify your document content.","Executing...":"Executing...","Completed successfully":"Completed successfully",Failed:"Failed","Pending approval":"Pending approval","Denied by user":"Denied by user","Tool Result":"Tool Result","Tool Execution Error":"Tool Execution Error",Context:"Context",Contexts:"Contexts","Add to AI Context":"Add to AI Context",Remove:"Remove","Clear all":"Clear all","An error occurred":"An error occurred","Request failed":"Request failed","Connection error":"Connection error","AI Assistant is not configured":"AI Assistant is not configured","Thinking...":"Thinking...","Generating response...":"Generating response...",insertHTML:"Insert HTML",readDocument:"Read Document",readBlock:"Read Block",replaceInDocument:"Replace in Document",replaceInBlock:"Replace in Block",getSelection:"Get Selection","Just now":"Just now",Conversation:"Conversation","New Conversation":"New Conversation",Yesterday:"Yesterday","Delete conversation":"Delete conversation","Are you sure you want to delete this conversation?":"Are you sure you want to delete this conversation?","Failed to delete conversation":"Failed to delete conversation"}},63805:function(t,i,n){"use strict";n.r(i),n.d(i,{en:function(){return r.a},ru:function(){return a.a}});var o=n(26612),r=n.n(o),s=n(55790),a=n.n(s)},55790:function(t){t.exports={"AI Assistant":"AI Ассистент","AI Assistant Pro":"AI Ассистент Pro","Welcome to AI Assistant":"Добро пожаловать в AI Ассистент","Start your first conversation":"Начните первый диалог","Tip: Select text in editor to add context":"Подсказка: Выделите текст в редакторе для добавления контекста","New chat":"Новый чат","Search conversations...":"Поиск диалогов...","No conversations yet":"Пока нет диалогов","Ask me anything...":"Спросите меня о чем угодно...","Ask a follow-up...":"Задайте дополнительный вопрос...","Reply...":"Ответить...","Type your message...":"Введите ваше сообщение...",Send:"Отправить",Cancel:"Отмена",Retry:"Повторить",Insert:"Вставить",Copy:"Копировать",Edit:"Редактировать",Delete:"Удалить",New:"Новый",Back:"Назад","Permission Required":"Требуется разрешение",Approve:"Разрешить",Deny:"Отклонить",Once:"Один раз","This conversation":"Этот диалог",Always:"Всегда","The AI wants to execute:":"AI хочет выполнить:","This will modify your document content.":"Это изменит содержимое вашего документа.","Executing...":"Выполняется...","Completed successfully":"Успешно выполнено",Failed:"Ошибка","Pending approval":"Ожидает разрешения","Denied by user":"Отклонено пользователем","Tool Result":"Результат инструмента","Tool Execution Error":"Ошибка выполнения инструмента",Context:"Контекст",Contexts:"Контексты","Add to AI Context":"Добавить в контекст AI",Remove:"Удалить","Clear all":"Очистить все","An error occurred":"Произошла ошибка","Request failed":"Запрос не выполнен","Connection error":"Ошибка соединения","AI Assistant is not configured":"AI Ассистент не настроен","Thinking...":"Думаю...","Generating response...":"Генерирую ответ...",insertHTML:"Вставить HTML",readDocument:"Прочитать документ",readBlock:"Прочитать блок",replaceInDocument:"Заменить в документе",replaceInBlock:"Заменить в блоке",getSelection:"Получить выделение","Just now":"Только что",Conversation:"Диалог","New Conversation":"Новый диалог",Yesterday:"Вчера","Delete conversation":"Удалить диалог","Are you sure you want to delete this conversation?":"Вы уверены, что хотите удалить этот диалог?","Failed to delete conversation":"Не удалось удалить диалог",Settings:"Настройки","General Settings":"Общие настройки","Conversation Settings":"Настройки диалога","Display Mode":"Режим отображения","Panel Width":"Ширина панели",Theme:"Тема",Model:"Модель",Temperature:"Температура",Close:"Закрыть",Dialog:"Модальное окно",Left:"Левая панель",Right:"Правая панель",Top:"Верхняя панель",Bottom:"Нижняя панель",Inherit:"Наследовать от редактора",Light:"Светлая тема",Dark:"Тёмная тема","%dm ago":"%dм назад","%dh ago":"%dч назад"}},94454:function(t,i,n){"use strict";n.d(i,{getAIProviderOptions:function(){return o.getAIProviderOptions},registerAIProvider:function(){return o.registerAIProvider}}),n(82923);var o=n(58211)},82923:function(t,i,n){"use strict";var o=n(58211),r=n(54079);(0,o.registerAIProvider)("jodit-ai-adapter",t=>{let i=t.url.replace(/\/+$/,""),n=t.provider??"openai",o=!1!==t.stream;return{apiMode:"incremental",maxRetries:0,voiceInputEnabled:!0,voiceInputUrl:`${i.replace(/^http/,"ws")}/v1/ai/transcribe`,voiceInputApiKey:t.apiKey,textAutocompleteEnabled:!0,async textAutocompleteApiRequest(o,s,a){let l=new r.Ajax({url:`${i}/ai/autocomplete?query=${encodeURIComponent(o)}&key=${encodeURIComponent(t.apiKey)}`,method:"POST",contentType:"application/json",data:{provider:n,context:{maxSuggestions:s}}});a.addEventListener("abort",()=>l.abort(),{once:!0});let c=await l.send(),d=await c.json();return d.success&&d.result?.suggestions?d.result.suggestions:[]},async apiRequest(s,a){let l=new r.Ajax({url:`${i}/ai/request?key=${encodeURIComponent(t.apiKey)}`,method:"POST",contentType:"application/json",data:{provider:n,context:o?{...s,metadata:{...s.metadata,stream:!0}}:s}});if(a&&a.addEventListener("abort",()=>l.abort(),{once:!0}),!o){let t=await l.send();return{mode:"final",response:(await t.json()).result}}let c=l.stream();return{mode:"stream",stream:async function*(){for await(let t of c)yield JSON.parse(t)}()}}}})},58211:function(t,i,n){"use strict";n.d(i,{getAIProviderOptions:function(){return r},registerAIProvider:function(){return s}});let o=new Map;function r(t,i){let n=o.get(t);if(!n)throw Error(`AI provider "${t}" is not registered. Available providers: `+[...o.keys()].join(", "));return n(i)}function s(t,i){o.set(t,i)}},65374:function(t,i,n){"use strict";n.r(i),n.d(i,{description:function(){return r},name:function(){return o},parameters:function(){return s},requiresPermission:function(){return a}});let o="addHTML",r="Add HTML content to the beginning or end of the document",s=[{name:"html",type:"string",description:"HTML content to add",required:!0},{name:"position",type:"string",description:'Where to add: "start" adds at the beginning of the document, "end" appends to the end',required:!1,default:"end"}],a=!0},686:function(t,i,n){"use strict";n.d(i,{execute:function(){return a}});var o=n(6689),r=n(49459),s=n(22732);async function a(t,i,n){let a=(0,r.requireString)(i,"html",{allowEmpty:!0}),{position:l="end"}=i;if(!a.trim())return{success:!0,message:"Nothing to add: HTML is empty"};(0,o.throwIfAborted)(n);try{let i=t.createInside.fragment(),n=t.createInside.div();for(n.innerHTML=a;n.firstChild;)i.appendChild(n.firstChild);return"start"===l?s.Dom.prepend(t.editor,i):s.Dom.append(t.editor,i),t.synchronizeValues(),{success:!0,message:`Added ${a.length} characters of HTML at the ${"start"===l?"beginning":"end"} of the document`}}catch(t){throw Error("Failed to add HTML: "+(t?.message||"Unknown error"))}}},78907:function(t,i,n){"use strict";var o=n(65374),r=n(686);i.default={...o,execute:r.execute}},73943:function(t,i,n){"use strict";n.r(i),n.d(i,{description:function(){return r},name:function(){return o},parameters:function(){return s},requiresPermission:function(){return a}});let o="applyFormat",r="Apply or remove inline formatting to the current selection (bold, italic, underline, etc.) or to a specific block",s=[{name:"element",type:"string",description:'HTML element to wrap selection (e.g., "strong", "em", "u", "span")',required:!1},{name:"attributes",type:"object",description:'Attributes to apply (e.g., {"className": "highlight"}, {"style": {"color": "red"}})',required:!1},{name:"remove",type:"boolean",description:"If true, remove the formatting instead of applying it",required:!1,default:!1},{name:"blockIndex",type:"number",description:"Zero-based index of the block to format (if not using current selection)",required:!1},{name:"selector",type:"string",description:"CSS selector to find the block to format (if not using current selection)",required:!1}],a=!0},19127:function(t,i,n){"use strict";n.d(i,{execute:function(){return s}});var o=n(6689),r=n(44526);async function s(t,i,n){let{element:s,attributes:a,remove:l,blockIndex:c,selector:d}=i;if((0,o.throwIfAborted)(n),!s&&!a)throw Error('Either "element" or "attributes" must be provided');if(t.s.restore(),void 0!==c||d){let{element:i}=(0,r.resolveBlock)(t,{selector:d,index:c});t.s.select(i)}if(t.s.isCollapsed())throw Error("No selection found. Please select text to format");try{let i={};return s&&(i.element=s),a&&(i.attributes=a),l?t.s.commitStyle({...i,mode:"remove"}):t.s.commitStyle(i),t.synchronizeValues(),{success:!0,message:l?"Formatting removed successfully":"Formatting applied successfully"}}catch(t){throw Error(`Failed to ${l?"remove":"apply"} formatting: ${t.message}`)}}},39296:function(t,i,n){"use strict";var o=n(73943),r=n(19127);i.default={...o,execute:r.execute}},53835:function(t,i,n){"use strict";n.d(i,{BUILT_IN_TOOLS:function(){return f},getToolNames:function(){return m}});var o=n(78907),r=n(39296),s=n(16745),a=n(78717),l=n(5618),c=n(90991),d=n(2020),u=n(12570),h=n(95323),p=n(97603);let f={readDocument:l.default,readBlocks:a.default,readSelection:c.default,writeDocument:p.default,replaceSelection:h.default,replaceBlock:d.default,replaceInDocument:u.default,insertHTML:s.default,addHTML:o.default,applyFormat:r.default};function m(){return Object.keys(f)}},56732:function(t,i,n){"use strict";n.r(i),n.d(i,{description:function(){return r},name:function(){return o},parameters:function(){return s},requiresPermission:function(){return a}});let o="insertHTML",r="Insert or replace HTML content at the current cursor position in the editor",s=[{name:"html",type:"string",description:"HTML content to insert",required:!0},{name:"replace",type:"boolean",description:"If true, replaces current selection. If false, inserts at cursor",required:!1,default:!1}],a=!0},39592:function(t,i,n){"use strict";n.d(i,{execute:function(){return s}});var o=n(6689),r=n(49459);async function s(t,i,n){let s=(0,r.requireString)(i,"html",{allowEmpty:!0}),{replace:a}=i;if(!s.trim())return{success:!0,message:"Nothing to insert: HTML is empty"};(0,o.throwIfAborted)(n);try{return t.s.focus(),a&&!t.s.isCollapsed()&&t.s.remove(),t.s.insertHTML(s),t.synchronizeValues(),{success:!0,message:`Inserted ${s.length} characters of HTML`}}catch(t){throw Error("Failed to insert HTML: "+(t?.message||"Unknown error"))}}},16745:function(t,i,n){"use strict";var o=n(56732),r=n(39592);i.default={...o,execute:r.execute}},75352:function(t,i,n){"use strict";n.r(i),n.d(i,{description:function(){return r},name:function(){return o},parameters:function(){return s},requiresPermission:function(){return a}});let o="readBlocks",r="Read blocks from the editor with optional filtering and pagination",s=[{name:"offset",type:"number",description:"Number of blocks to skip from the beginning (default: 0)",required:!1,default:0},{name:"limit",type:"number",description:"Maximum number of blocks to return (default: all)",required:!1},{name:"query",type:"string",description:"Filter blocks by text content",required:!1}],a=!1},91140:function(t,i,n){"use strict";n.d(i,{execute:function(){return s}});var o=n(6689),r=n(22732);async function s(t,i,n){let{offset:s,limit:a,query:l}=i;(0,o.throwIfAborted)(n);let c=[];Array.from(t.editor.children).forEach((t,i)=>{r.Dom.isElement(t)&&c.push({blockIndex:i,tagName:t.tagName.toLowerCase(),content:t.innerHTML,textContent:t.textContent||"",classList:Array.from(t.classList)})});let d=c;if(l&&"string"==typeof l){let t=l.toLowerCase();d=c.filter(i=>i.textContent.toLowerCase().includes(t)||i.tagName.includes(t)||i.content.toLowerCase().includes(t))}let u=Math.max(0,Math.min("number"==typeof s?s:0,d.length)),h=void 0!==a?Math.min(u+a,d.length):d.length;return{blocks:d.slice(u,h),total:c.length,offset:u,limit:void 0!==a?a:void 0}}},78717:function(t,i,n){"use strict";var o=n(75352),r=n(91140);i.default={...o,execute:r.execute}},93809:function(t,i,n){"use strict";n.r(i),n.d(i,{description:function(){return r},name:function(){return o},parameters:function(){return s},requiresPermission:function(){return a}});let o="readDocument",r="Read the entire content of the editor document in HTML format",s=[{name:"start",type:"number",description:"Start character position (default: 0)",required:!1,default:0},{name:"end",type:"number",description:"End character position (default: length of document)",required:!1},{name:"aroundSelection",type:"boolean",description:"If true, return only the maximum block around the current selection",required:!1,default:!1}],a=!1},28157:function(t,i,n){"use strict";n.d(i,{execute:function(){return s}});var o=n(6689),r=n(22732);async function s(t,i,n){let{start:s,end:a,aroundSelection:l}=i;(0,o.throwIfAborted)(n);let c=t.value,d=c.length;if(l&&!t.s.isCollapsed()){let i=t.s.range.commonAncestorContainer;for(;i&&i!==t.editor;){if(r.Dom.isElement(i)&&i.parentNode===t.editor){c=i.outerHTML;break}i=i.parentNode}return{html:c,length:d}}let u=void 0!==a?Math.min(a,d):d,h=Math.max(0,Math.min("number"==typeof s?s:0,d));return(h>0||d>u)&&(c=c.substring(h,u)),{html:c,length:d,start:h,end:u}}},5618:function(t,i,n){"use strict";var o=n(93809),r=n(28157);i.default={...o,execute:r.execute}},52826:function(t,i,n){"use strict";n.r(i),n.d(i,{description:function(){return r},name:function(){return o},parameters:function(){return s},requiresPermission:function(){return a}});let o="readSelection",r="Get information about the current selection including HTML content and optional context",s=[{name:"contextCharsBefore",type:"number",description:"Number of characters to include before the selection",required:!1,default:0},{name:"contextCharsAfter",type:"number",description:"Number of characters to include after the selection",required:!1,default:0}],a=!1},85130:function(t,i,n){"use strict";n.d(i,{execute:function(){return r}});var o=n(6689);async function r(t,i,n){let{contextCharsBefore:r,contextCharsAfter:s}=i;if((0,o.throwIfAborted)(n),t.s.restore(),t.s.isCollapsed())return{hasSelection:!1};let a=t.s.html,l=t.s.range,c=l.toString(),d={hasSelection:!0,html:a,text:c,startContainer:l.startContainer.nodeName,endContainer:l.endContainer.nodeName};if(r>0||s>0){let i=t.editor.textContent||"",n=i.substring(0,i.indexOf(c)),o=i.substring(i.indexOf(c)+c.length);r>0&&(d.contextBefore=n.slice(-r)),s>0&&(d.contextAfter=o.slice(0,s))}return d}},90991:function(t,i,n){"use strict";var o=n(52826),r=n(85130);i.default={...o,execute:r.execute}},96675:function(t,i,n){"use strict";n.r(i),n.d(i,{description:function(){return r},name:function(){return o},parameters:function(){return s},requiresPermission:function(){return a}});let o="replaceBlock",r="Replace a specific block in the document by its index or CSS selector with new HTML content",s=[{name:"index",type:"number",description:"Zero-based index of the block to replace (use either index or selector, not both)",required:!1},{name:"selector",type:"string",description:'CSS selector to find the block to replace (e.g., "h1", ".my-class", "#my-id"). Use either selector or index, not both',required:!1},{name:"html",type:"string",description:"HTML content for the new block",required:!0}],a=!0},3091:function(t,i,n){"use strict";n.d(i,{execute:function(){return l}});var o=n(6689),r=n(49459),s=n(44526),a=n(22732);async function l(t,i,n){let{index:l,selector:c}=i,d=(0,r.requireString)(i,"html");if((0,o.throwIfAborted)(n),void 0===l&&!c||void 0!==l&&c)throw Error("Either index or selector must be provided, but not both");let{element:u,identifier:h}=(0,s.resolveBlock)(t,{selector:c,index:l,requireExactlyOne:!0});try{let i=t.createInside.div();i.innerHTML=d;let n=i.firstChild;if(!n||!a.Dom.isElement(n))throw Error("Invalid HTML: must contain at least one element");return u.parentNode?.replaceChild(n,u),t.synchronizeValues(),{success:!0,message:`Block ${h} replaced successfully`}}catch(t){throw Error(`Failed to replace block ${h}: ${t.message}`)}}},2020:function(t,i,n){"use strict";var o=n(96675),r=n(3091);i.default={...o,execute:r.execute}},62553:function(t,i,n){"use strict";n.r(i),n.d(i,{description:function(){return r},name:function(){return o},parameters:function(){return s},requiresPermission:function(){return a}});let o="replaceInDocument",r="Find and replace text or HTML patterns throughout the entire document",s=[{name:"search",type:"string",description:"Text or pattern to search for",required:!0},{name:"replace",type:"string",description:"Replacement text or HTML",required:!0},{name:"useRegex",type:"boolean",description:"If true, treats search as a regular expression",required:!1,default:!1},{name:"useSelector",type:"string",description:"CSS selector to narrow down the search scope to specific elements",required:!1}],a=!0},56293:function(t,i,n){"use strict";n.d(i,{execute:function(){return s}});var o=n(6689),r=n(49459);async function s(t,i,n){let s=(0,r.requireString)(i,"search"),a=(0,r.requireString)(i,"replace",{allowEmpty:!0}),{useRegex:l,useSelector:c}=i;(0,o.throwIfAborted)(n);try{let i;t.s.focus(),t.s.save();let r=0;if(c){let d=function(t,i,n,r,s,a){let l=t.editor.querySelectorAll(s);if(0===l.length)return{replacements:0,message:`No elements found matching selector "${s}"`};let c=0;return l.forEach(t=>{(0,o.throwIfAborted)(a);let s=t.innerHTML,l=s;if(r)try{let t=RegExp(i,"g");s=s.replace(t,()=>(c++,n))}catch(t){throw Error("Invalid regex pattern: "+(t?.message||"Unknown error"))}else{let t=i.length,r=0;for(;-1!==(r=s.indexOf(i,r));)(0,o.throwIfAborted)(a),s=s.substring(0,r)+n+s.substring(r+t),r+=n.length,c++}s!==l&&(t.innerHTML=s)}),c>0&&(t.synchronizeValues(),t.s.restore()),{replacements:c}}(t,s,a,l,c,n);r=d.replacements,i=d.message}else r=function(t,i,n,r,s,a){let l=0,c=i;if(s)try{let t=RegExp(n,"g");c=c.replace(t,()=>(l++,r))}catch(t){throw Error("Invalid regex pattern: "+(t?.message||"Unknown error"))}else{let t=n.length,i=0;for(;-1!==(i=c.indexOf(n,i));)(0,o.throwIfAborted)(a),c=c.substring(0,i)+r+c.substring(i+t),i+=r.length,l++}return l>0&&(t.value=c,t.s.restore(),t.synchronizeValues()),l}(t,t.value,s,a,l,n);return{replacements:r,message:i||(r>0?`Replaced ${r} occurrence(s)`:"No matches found")}}catch(i){throw t.s.restore(),Error("Failed to replace in document: "+(i?.message||"Unknown error"))}}},12570:function(t,i,n){"use strict";var o=n(62553),r=n(56293);i.default={...o,execute:r.execute}},70750:function(t,i,n){"use strict";n.r(i),n.d(i,{description:function(){return r},name:function(){return o},parameters:function(){return s},requiresPermission:function(){return a}});let o="replaceSelection",r="Replace the current selection with new HTML content",s=[{name:"html",type:"string",description:"HTML content to insert in place of the selection",required:!0},{name:"collapseToEnd",type:"boolean",description:"Move cursor to the end of the inserted content",required:!1,default:!0}],a=!0},36142:function(t,i,n){"use strict";n.d(i,{execute:function(){return s}});var o=n(6689),r=n(49459);async function s(t,i,n){let s=(0,r.requireString)(i,"html"),{collapseToEnd:a}=i;(0,o.throwIfAborted)(n);try{if(t.s.restore(),t.s.insertHTML(s),a){let i=t.s.range;i.collapse(!1),t.s.selectRange(i)}return t.e.fire("change"),{success:!0,message:"Selection replaced successfully"}}catch(t){throw Error("Failed to replace selection: "+t.message)}}},95323:function(t,i,n){"use strict";var o=n(70750),r=n(36142);i.default={...o,execute:r.execute}},90022:function(t,i,n){"use strict";n.r(i),n.d(i,{description:function(){return r},name:function(){return o},parameters:function(){return s},requiresPermission:function(){return a}});let o="writeDocument",r="Write (replace) the entire document content with new HTML",s=[{name:"html",type:"string",description:"HTML content to set as the document",required:!0}],a=!0},79766:function(t,i,n){"use strict";n.d(i,{execute:function(){return s}});var o=n(6689),r=n(49459);async function s(t,i,n){let s=(0,r.requireString)(i,"html",{allowEmpty:!0});(0,o.throwIfAborted)(n);try{return t.s.focus(),t.value=s,t.synchronizeValues(),{success:!0,message:`Document content was replaced with provided HTML(${s.length} characters)`}}catch(t){throw Error("Failed to replace HTML: "+(t?.message||"Unknown error"))}}},97603:function(t,i,n){"use strict";var o=n(90022),r=n(79766);i.default={...o,execute:r.execute}},80453:function(t,i,n){"use strict";n.d(i,{UIConversationListItem:function(){return d}});var o=n(82749),r=n(31635),s=n(65478),a=n(67510),l=n(62843),c=n(80870);class d extends a.UIElement{className(){return"UIConversationListItem"}render(){return'<div class="jodit-ui-conversation-list__item"></div>'}setActive(t){this.isActive=t,this.updateContent()}updateContent(){let t=this.container;t.innerHTML="",t.setAttribute("data-id",this.conversation.id),this.isActive?t.classList.add("jodit-ui-conversation-list__item_active"):t.classList.remove("jodit-ui-conversation-list__item_active");let i=this.j.c.div("jodit-ui-conversation-list__item-avatar");i.textContent="AI",t.appendChild(i);let n=this.j.c.div("jodit-ui-conversation-list__item-wrapper"),o=this.j.c.div("jodit-ui-conversation-list__item-content"),r=this.j.c.div("jodit-ui-conversation-list__item-title");if(r.textContent=this.conversation.title,this.titleElement=r,o.appendChild(r),this.opts.showTimestamps){let t=this.j.c.div("jodit-ui-conversation-list__item-meta");t.textContent=this.opts.formatTimestamp(this.conversation.updated,this.j.i18n.bind(this.j)),o.appendChild(t)}if(n.appendChild(o),this.conversation.messageCount>0){let t=this.j.c.div("jodit-ui-conversation-list__item-badge");t.textContent=this.conversation.messageCount+"",n.appendChild(t)}t.appendChild(n),this.actionsButton||(this.actionsButton=new l.UIButton(this.j,{icon:{name:"dots"},tooltip:"Actions",name:"conversationActions",size:"tiny"}),this.actionsButton.container.classList.add("jodit-ui-conversation-list__item-actions"),this.actionsButton.onAction(t=>{t.stopPropagation(),this.showActionsMenu(t)})),t.appendChild(this.actionsButton.container)}onClick(){this.isRenaming||this.j.e.fire("selectConversation.ai-assistant-pro",this.conversation.id)}showActionsMenu(t){if(!this.contextMenu||!this.actionsButton)return;let i=this.actionsButton.container.getBoundingClientRect();this.contextMenu.show(i.left,i.bottom,[{title:"Rename",icon:"pencil",exec:()=>{this.startInlineRename()}},{title:"Delete",icon:"bin",exec:()=>{this.onDelete()}}]),t.stopPropagation()}startInlineRename(){if(this.isRenaming||!this.titleElement)return;this.isRenaming=!0;let t=this.titleElement,i=this.conversation.title,n=this.j.c.element("input");n.type="text",n.value=i,n.className="jodit-ui-conversation-list__item-title-input",t.textContent="",t.appendChild(n),n.focus(),n.select();let o=()=>{if(!this.isRenaming)return;let o=n.value.trim();this.isRenaming=!1,o&&o!==i?(t.textContent=o,this.j.e.fire("renameConversation.ai-assistant-pro",this.conversation.id,o)):t.textContent=i};this.j.e.on(n,"blur",o),this.j.e.on(n,"keydown",o=>{"Enter"===o.key&&(o.preventDefault(),n.blur()),"Escape"===o.key&&(this.isRenaming=!1,t.textContent=i)}),this.j.e.on(n,"click",t=>{t.stopPropagation()})}onDelete(){this.j.e.fire("deleteConversation.ai-assistant-pro",this.conversation.id)}destruct(){this.actionsButton?.destruct(),this.contextMenu?.destruct(),super.destruct()}constructor(t,i,n=!1,r){super(t),(0,o._)(this,"opts",void 0),(0,o._)(this,"conversation",void 0),(0,o._)(this,"isActive",void 0),(0,o._)(this,"actionsButton",void 0),(0,o._)(this,"contextMenu",void 0),(0,o._)(this,"titleElement",void 0),(0,o._)(this,"isRenaming",void 0),this.opts=r,this.actionsButton=null,this.contextMenu=null,this.titleElement=null,this.isRenaming=!1,this.conversation=i,this.isActive=n,this.contextMenu=new c.ContextMenu(this.j),this.updateContent()}}(0,r.__decorate)([(0,s.watch)("container:click")],d.prototype,"onClick",null),(0,r.__decorate)([s.autobind],d.prototype,"showActionsMenu",null),(0,r.__decorate)([s.autobind],d.prototype,"startInlineRename",null),(0,r.__decorate)([s.autobind],d.prototype,"onDelete",null),d=(0,r.__decorate)([s.component],d)},68365:function(t,i,n){"use strict";n.d(i,{UIConversationList:function(){return u}});var o=n(82749),r=n(31635),s=n(31356),a=n(80453),l=n(65478),c=n(80256),d=n(62405);class u extends d.UIGroup{className(){return"UIConversationList"}render(){return`<div class="&__container">
|
|
284
284
|
<div class="&__header"></div>
|